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
038ef99b85316638a984dc40c5ae5b2e3a1c26ce
20
py
Python
pyasf/__init__.py
blanzer/pyasf
8363b410788701938d76008a78928a324e724a94
[ "MIT" ]
null
null
null
pyasf/__init__.py
blanzer/pyasf
8363b410788701938d76008a78928a324e724a94
[ "MIT" ]
null
null
null
pyasf/__init__.py
blanzer/pyasf
8363b410788701938d76008a78928a324e724a94
[ "MIT" ]
null
null
null
from .pyasf import *
20
20
0.75
3
20
5
1
0
0
0
0
0
0
0
0
0
0
0
0.15
20
1
20
20
0.882353
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
1
0
0
6
03ba64b89c279fa392b252596f6790fb70fea065
31
py
Python
src/eye_tools/__init__.py
jpcurrea/eye_tools
004c8ab774a6b27c021a628ae8f7fe8dc45e5e1e
[ "MIT" ]
null
null
null
src/eye_tools/__init__.py
jpcurrea/eye_tools
004c8ab774a6b27c021a628ae8f7fe8dc45e5e1e
[ "MIT" ]
null
null
null
src/eye_tools/__init__.py
jpcurrea/eye_tools
004c8ab774a6b27c021a628ae8f7fe8dc45e5e1e
[ "MIT" ]
null
null
null
from .analysis_tools import *
10.333333
29
0.774194
4
31
5.75
1
0
0
0
0
0
0
0
0
0
0
0
0.16129
31
2
30
15.5
0.884615
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
1
0
0
6
03ec683e444b42deb0a1705026a3a8000713a847
72
py
Python
tests/samples/project/vendor/fooba/experiments/start.py
machinable-org/machinable
9d96e942dde05d68699bc7bc0c3d062ee18652ad
[ "MIT" ]
23
2020-02-28T14:29:04.000Z
2021-12-23T20:50:54.000Z
tests/samples/project/vendor/fooba/experiments/start.py
machinable-org/machinable
9d96e942dde05d68699bc7bc0c3d062ee18652ad
[ "MIT" ]
172
2020-02-24T12:12:11.000Z
2022-03-29T03:08:24.000Z
tests/samples/project/vendor/fooba/experiments/start.py
machinable-org/machinable
9d96e942dde05d68699bc7bc0c3d062ee18652ad
[ "MIT" ]
1
2020-11-23T22:42:20.000Z
2020-11-23T22:42:20.000Z
from machinable import Component class TestNode(Component): pass
10.285714
32
0.763889
8
72
6.875
0.875
0
0
0
0
0
0
0
0
0
0
0
0.194444
72
6
33
12
0.948276
0
0
0
0
0
0
0
0
0
0
0
0
1
0
true
0.333333
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
1
1
1
0
1
0
0
6
03ec722f0056221e6c01f870196ed0de49a38e25
37
py
Python
src/fate_of_dice/system/__init__.py
bonczeq/FateOfDice
ce1704ac490f55bc600c0963958d4175104e85e5
[ "MIT" ]
null
null
null
src/fate_of_dice/system/__init__.py
bonczeq/FateOfDice
ce1704ac490f55bc600c0963958d4175104e85e5
[ "MIT" ]
null
null
null
src/fate_of_dice/system/__init__.py
bonczeq/FateOfDice
ce1704ac490f55bc600c0963958d4175104e85e5
[ "MIT" ]
null
null
null
from .basic_result import DiceResult
18.5
36
0.864865
5
37
6.2
1
0
0
0
0
0
0
0
0
0
0
0
0.108108
37
1
37
37
0.939394
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
1
0
0
6
03fbee0dff32602e0b0af605e1a44fa00a2dc027
3,474
py
Python
seismicpro/src/utils/normalization.py
janwillembuist/SeismicPro
5431bf800c06a44fd5b3c0553d98040147ecb176
[ "Apache-2.0" ]
97
2019-09-17T08:49:32.000Z
2022-03-20T02:11:16.000Z
seismicpro/src/utils/normalization.py
janwillembuist/SeismicPro
5431bf800c06a44fd5b3c0553d98040147ecb176
[ "Apache-2.0" ]
59
2019-09-09T20:42:07.000Z
2022-03-31T09:41:49.000Z
seismicpro/src/utils/normalization.py
janwillembuist/SeismicPro
5431bf800c06a44fd5b3c0553d98040147ecb176
[ "Apache-2.0" ]
45
2019-10-17T07:56:24.000Z
2022-03-23T16:18:03.000Z
"""Implements optimized functions for various gather normalizations""" import numpy as np from numba import njit from . import general_utils @njit(nogil=True) def scale_standard(data, mean, std, eps): r"""Scale `data` using the following formula: :math:`S = \frac{data - mean}{std + eps}` Parameters ---------- data : np.ndarray Data to scale. mean : float or np.ndarray Mean value. Must be broadcastable to `data.shape`. std : float or np.ndarray Standard deviation. Must be broadcastable to `data.shape`. eps : float A constant to be added to the denominator to avoid division by zero. Returns ------- data : np.ndarray Scaled data with unchanged shape. """ data = (data - mean) / (std + eps) return data @njit(nogil=True) def scale_maxabs(data, min_value, max_value, clip, eps): r"""Scale `data` using the following formula: :math:`S = \frac{data}{max(|min_value|, |max_value|) + eps}` Parameters ---------- data : 2d np.ndarray Data to scale. min_value : int, float, 1d or 2d array-like Minimum value. Dummy trailing axes are added to the array to have at least 2 dimensions, the result must be broadcastable to `data.shape`. max_value : int, float, 1d or 2d array-like Maximum value. Dummy trailing axes are added to the array to have at least 2 dimensions, the result must be broadcastable to `data.shape`. clip : bool Whether to clip scaled data to the [-1, 1] range. eps : float A constant to be added to the denominator to avoid division by zero. Returns ------- data : np.ndarray Scaled data with unchanged shape. """ max_abs = np.maximum(np.abs(min_value), np.abs(max_value)) # Use np.atleast_2d(array).T to make the array 2-dimentional by adding dummy trailing axes # for further broadcasting to work tracewise data /= np.atleast_2d(np.asarray(max_abs)).T + eps if clip: data = general_utils.clip(data, np.float32(-1), np.float32(1)) return data @njit(nogil=True) def scale_minmax(data, min_value, max_value, clip, eps): r"""Scale `data` using the following formula: :math:`S = \frac{data - min_value}{max_value - min_value + eps}` Parameters ---------- data : 2d np.ndarray Data to scale. min_value : int, float, 1d or 2d array-like Minimum value. Dummy trailing axes are added to the array to have at least 2 dimensions, the result must be broadcastable to `data.shape`. max_value : int, float, 1d or 2d array-like Maximum value. Dummy trailing axes are added to the array to have at least 2 dimensions, the result must be broadcastable to `data.shape`. clip : bool Whether to clip scaled data to the [0, 1] range. eps : float A constant to be added to the denominator to avoid division by zero. Returns ------- data : np.ndarray Scaled data with unchanged shape. """ # Use np.atleast_2d(array).T to make the array 2-dimentional by adding dummy trailing axes # for further broadcasting to work tracewise min_value = np.atleast_2d(np.asarray(min_value)).T max_value = np.atleast_2d(np.asarray(max_value)).T data = (data - min_value) / (max_value - min_value + eps) if clip: data = general_utils.clip(data, np.float32(0), np.float32(1)) return data
33.403846
115
0.651123
515
3,474
4.324272
0.190291
0.043107
0.031432
0.056578
0.845532
0.813651
0.752582
0.724742
0.703637
0.703637
0
0.014198
0.249856
3,474
103
116
33.728155
0.840368
0.677029
0
0.32
0
0
0
0
0
0
0
0
0
1
0.12
false
0
0.12
0
0.36
0
0
0
0
null
0
0
0
1
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
6
03fe20b8c0bc22bd5edb566c11970ead6a47beca
358
py
Python
models/__init__.py
StephenCurry-LH/ecg
f6dffeb108515d7307773112482d4d8f81ba9442
[ "Apache-2.0" ]
null
null
null
models/__init__.py
StephenCurry-LH/ecg
f6dffeb108515d7307773112482d4d8f81ba9442
[ "Apache-2.0" ]
null
null
null
models/__init__.py
StephenCurry-LH/ecg
f6dffeb108515d7307773112482d4d8f81ba9442
[ "Apache-2.0" ]
null
null
null
# -*- coding: utf-8 -*- ''' @time: 2019/9/8 20:13 @ author: javis ''' from .resnet import resnet34,resnet18 # from .resnet import resnet34, resnet50, resnet101, resnet152 from .ResNext import ResNeXt50_2x16d, ResNeXt50_2x32d, ResNeXt50_4x64d from .ResNext import ResNeXt101_2x64d, ResNeXt101_4x64d from .ResNext import ResNeXt152_2x64d, ResNeXt152_4x64d
25.571429
71
0.773743
46
358
5.869565
0.565217
0.122222
0.188889
0.177778
0
0
0
0
0
0
0
0.204473
0.125698
358
13
72
27.538462
0.658147
0.340782
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
1
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
6
ff03d7bbce770765b24a0f0985e393abfbc3a328
99
py
Python
kubectlfr/__init__.py
theophanevie/kubectlfr
4705182b85991db4f008eedd5604e72fe4dfc045
[ "MIT" ]
7
2022-01-21T20:40:51.000Z
2022-01-22T08:46:17.000Z
kubectlfr/__init__.py
theophanevie/kubectlfr
4705182b85991db4f008eedd5604e72fe4dfc045
[ "MIT" ]
1
2022-01-22T15:07:50.000Z
2022-01-22T15:07:50.000Z
kubectlfr/__init__.py
theophanevie/kubectlfr
4705182b85991db4f008eedd5604e72fe4dfc045
[ "MIT" ]
1
2022-01-22T00:19:13.000Z
2022-01-22T00:19:13.000Z
import sys from kubectlfr.main import kubectlfr def main() -> None: kubectlfr(sys.argv[1:])
12.375
36
0.69697
14
99
4.928571
0.642857
0
0
0
0
0
0
0
0
0
0
0.012346
0.181818
99
7
37
14.142857
0.839506
0
0
0
0
0
0
0
0
0
0
0
0
1
0.25
true
0
0.5
0
0.75
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
1
0
1
0
1
0
0
6
ff0c299dbab4e5cc2d241e52ffb7a9e88d1da4c3
90
py
Python
mmorpg/old/Model/Direction/CardinalDirection/cardinaldirection.py
InnovAnon-Inc/MAiZE
6b7b266d85f8932557013e3c32bcc728c53f616f
[ "Unlicense" ]
null
null
null
mmorpg/old/Model/Direction/CardinalDirection/cardinaldirection.py
InnovAnon-Inc/MAiZE
6b7b266d85f8932557013e3c32bcc728c53f616f
[ "Unlicense" ]
null
null
null
mmorpg/old/Model/Direction/CardinalDirection/cardinaldirection.py
InnovAnon-Inc/MAiZE
6b7b266d85f8932557013e3c32bcc728c53f616f
[ "Unlicense" ]
null
null
null
from Model.Direction.direction import Direction class CardinalDirection (Direction): pass
30
47
0.855556
10
90
7.7
0.7
0
0
0
0
0
0
0
0
0
0
0
0.088889
90
3
48
30
0.939024
0
0
0
0
0
0
0
0
0
0
0
0
1
0
true
0.5
0.5
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
1
1
0
1
0
0
6
45849f0e73cff4de058afc952b55b6eca429e343
95
py
Python
992020.py
veolex123/John2020
892c4476e7a786e8f1691d0d092fcb8fba0761f2
[ "MIT" ]
null
null
null
992020.py
veolex123/John2020
892c4476e7a786e8f1691d0d092fcb8fba0761f2
[ "MIT" ]
null
null
null
992020.py
veolex123/John2020
892c4476e7a786e8f1691d0d092fcb8fba0761f2
[ "MIT" ]
null
null
null
for i in range(9,0, -1): for j in range(9,0, -1): print(i*j, end=' ') print(' ')
15.833333
29
0.452632
19
95
2.263158
0.526316
0.325581
0.372093
0.418605
0.465116
0
0
0
0
0
0
0.090909
0.305263
95
5
30
19
0.560606
0
0
0
0
0
0.021277
0
0
0
0
0
0
1
0
false
0
0
0
0
0.5
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
1
0
6
45b0924cd7a1b71a14678e72725f8f28d7b6953a
32
py
Python
src/stateful/__init__.py
DataAsCode/stateful
7c461589090ca9fabfbb97d3d17d34a6a2c7a185
[ "MIT" ]
null
null
null
src/stateful/__init__.py
DataAsCode/stateful
7c461589090ca9fabfbb97d3d17d34a6a2c7a185
[ "MIT" ]
null
null
null
src/stateful/__init__.py
DataAsCode/stateful
7c461589090ca9fabfbb97d3d17d34a6a2c7a185
[ "MIT" ]
1
2020-11-24T12:32:48.000Z
2020-11-24T12:32:48.000Z
from stateful.state import State
32
32
0.875
5
32
5.6
0.8
0
0
0
0
0
0
0
0
0
0
0
0.09375
32
1
32
32
0.965517
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
1
0
0
6
45c44cfe2e2fb35b7c6ebf8c2c63b5e586fa844f
96
py
Python
venv/lib/python3.8/site-packages/pyflakes/test/test_other.py
Retraces/UkraineBot
3d5d7f8aaa58fa0cb8b98733b8808e5dfbdb8b71
[ "MIT" ]
2
2022-03-13T01:58:52.000Z
2022-03-31T06:07:54.000Z
venv/lib/python3.8/site-packages/pyflakes/test/test_other.py
DesmoSearch/Desmobot
b70b45df3485351f471080deb5c785c4bc5c4beb
[ "MIT" ]
19
2021-11-20T04:09:18.000Z
2022-03-23T15:05:55.000Z
venv/lib/python3.8/site-packages/pyflakes/test/test_other.py
DesmoSearch/Desmobot
b70b45df3485351f471080deb5c785c4bc5c4beb
[ "MIT" ]
null
null
null
/home/runner/.cache/pip/pool/16/69/cf/58bf4e618e97dbda6f7079f2c1356d63520f1b32bca29056c48b486566
96
96
0.895833
9
96
9.555556
1
0
0
0
0
0
0
0
0
0
0
0.447917
0
96
1
96
96
0.447917
0
0
0
0
0
0
0
0
1
0
0
0
0
null
null
0
0
null
null
0
1
0
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
1
0
0
0
1
0
0
0
0
0
0
0
0
6
45cafc27dbbcaabf1011aedd832b2441db304380
41
py
Python
Programs/RandomNumber.py
GopinathBalaji/Basic-Programs-Python
8993e73428f1b6d4e2e601983c9c0f1bd0f92935
[ "MIT" ]
5
2021-07-20T08:12:29.000Z
2022-01-18T20:00:50.000Z
Programs/random_number.py
Janhavi-2001/Basic-Programs-Python
1bba988d77e962ddd4c78fb1beb9bf00798423c9
[ "MIT" ]
26
2020-12-26T14:42:05.000Z
2021-12-04T09:23:41.000Z
Programs/random_number.py
Janhavi-2001/Basic-Programs-Python
1bba988d77e962ddd4c78fb1beb9bf00798423c9
[ "MIT" ]
14
2021-04-01T19:24:35.000Z
2022-01-10T11:29:28.000Z
import random print(random.randint(0,9))
13.666667
26
0.780488
7
41
4.571429
0.857143
0
0
0
0
0
0
0
0
0
0
0.052632
0.073171
41
3
26
13.666667
0.789474
0
0
0
0
0
0
0
0
0
0
0
0
1
0
true
0
0.5
0
0.5
0.5
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
1
0
6
45d74eb0e1a07748d97c065151b2d241aa15656f
18
py
Python
pylsd/__init__.py
cshields143/pylsd
921873a4f4ccbb96859ebb80dbe7f6d99839529e
[ "BSD-2-Clause" ]
null
null
null
pylsd/__init__.py
cshields143/pylsd
921873a4f4ccbb96859ebb80dbe7f6d99839529e
[ "BSD-2-Clause" ]
null
null
null
pylsd/__init__.py
cshields143/pylsd
921873a4f4ccbb96859ebb80dbe7f6d99839529e
[ "BSD-2-Clause" ]
null
null
null
from . import lsd
9
17
0.722222
3
18
4.333333
1
0
0
0
0
0
0
0
0
0
0
0
0.222222
18
1
18
18
0.928571
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
1
0
0
6
affcd9beff3bce518ae956aed818bc824a90d989
189
py
Python
3rd/mujoco/python/gym-baxter/gym_baxter/envs/__init__.py
Tadinu/my_arm
ac4fb295ddad7c7ee999a03d2e7d229802b64226
[ "BSD-3-Clause" ]
4
2021-02-20T15:59:42.000Z
2022-03-25T04:04:21.000Z
3rd/mujoco/python/gym-baxter/gym_baxter/envs/__init__.py
Tadinu/my_arm
ac4fb295ddad7c7ee999a03d2e7d229802b64226
[ "BSD-3-Clause" ]
1
2021-04-14T04:12:48.000Z
2021-04-14T04:12:48.000Z
3rd/mujoco/python/gym-baxter/gym_baxter/envs/__init__.py
Tadinu/my_arm
ac4fb295ddad7c7ee999a03d2e7d229802b64226
[ "BSD-3-Clause" ]
2
2019-10-29T12:41:16.000Z
2021-03-22T16:38:27.000Z
from gym_baxter.envs.baxter_env import BaxterEnv #from gym_baxter.envs.soccer_empty_goal import SoccerEmptyGoalEnv #from gym_baxter.envs.soccer_against_keeper import SoccerAgainstKeeperEnv
47.25
73
0.89418
26
189
6.192308
0.538462
0.130435
0.242236
0.31677
0.285714
0
0
0
0
0
0
0
0.063492
189
3
74
63
0.909605
0.719577
0
0
0
0
0
0
0
0
0
0
0
1
0
true
0
1
0
1
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
1
0
1
0
0
0
0
6
b30d2dee6480d58c395b798d67f63af39bf93877
40
py
Python
src/vox/linty/__init__.py
Peilonrayz/vox
026a82bb3c0d47988cd20d18639bcb0e249ee211
[ "MIT" ]
null
null
null
src/vox/linty/__init__.py
Peilonrayz/vox
026a82bb3c0d47988cd20d18639bcb0e249ee211
[ "MIT" ]
null
null
null
src/vox/linty/__init__.py
Peilonrayz/vox
026a82bb3c0d47988cd20d18639bcb0e249ee211
[ "MIT" ]
null
null
null
from . import display, from_str, to_str
20
39
0.775
7
40
4.142857
0.714286
0
0
0
0
0
0
0
0
0
0
0
0.15
40
1
40
40
0.852941
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
1
0
0
6
b31f348931552bf0dde374a25cc878db5614511c
8,723
py
Python
trackeval/baselines/pascal_colormap.py
AlexanderSing/TrackEval
373e643f8989445f0253af6748e9e247d6ae6322
[ "MIT" ]
325
2021-02-25T19:00:23.000Z
2022-03-31T14:30:42.000Z
trackeval/baselines/pascal_colormap.py
AlexanderSing/TrackEval
373e643f8989445f0253af6748e9e247d6ae6322
[ "MIT" ]
49
2021-03-26T14:40:28.000Z
2022-03-27T17:33:13.000Z
trackeval/baselines/pascal_colormap.py
AlexanderSing/TrackEval
373e643f8989445f0253af6748e9e247d6ae6322
[ "MIT" ]
93
2021-02-26T09:05:37.000Z
2022-03-30T11:44:01.000Z
pascal_colormap = [ 0 , 0, 0, 0.5020, 0, 0, 0, 0.5020, 0, 0.5020, 0.5020, 0, 0, 0, 0.5020, 0.5020, 0, 0.5020, 0, 0.5020, 0.5020, 0.5020, 0.5020, 0.5020, 0.2510, 0, 0, 0.7529, 0, 0, 0.2510, 0.5020, 0, 0.7529, 0.5020, 0, 0.2510, 0, 0.5020, 0.7529, 0, 0.5020, 0.2510, 0.5020, 0.5020, 0.7529, 0.5020, 0.5020, 0, 0.2510, 0, 0.5020, 0.2510, 0, 0, 0.7529, 0, 0.5020, 0.7529, 0, 0, 0.2510, 0.5020, 0.5020, 0.2510, 0.5020, 0, 0.7529, 0.5020, 0.5020, 0.7529, 0.5020, 0.2510, 0.2510, 0, 0.7529, 0.2510, 0, 0.2510, 0.7529, 0, 0.7529, 0.7529, 0, 0.2510, 0.2510, 0.5020, 0.7529, 0.2510, 0.5020, 0.2510, 0.7529, 0.5020, 0.7529, 0.7529, 0.5020, 0, 0, 0.2510, 0.5020, 0, 0.2510, 0, 0.5020, 0.2510, 0.5020, 0.5020, 0.2510, 0, 0, 0.7529, 0.5020, 0, 0.7529, 0, 0.5020, 0.7529, 0.5020, 0.5020, 0.7529, 0.2510, 0, 0.2510, 0.7529, 0, 0.2510, 0.2510, 0.5020, 0.2510, 0.7529, 0.5020, 0.2510, 0.2510, 0, 0.7529, 0.7529, 0, 0.7529, 0.2510, 0.5020, 0.7529, 0.7529, 0.5020, 0.7529, 0, 0.2510, 0.2510, 0.5020, 0.2510, 0.2510, 0, 0.7529, 0.2510, 0.5020, 0.7529, 0.2510, 0, 0.2510, 0.7529, 0.5020, 0.2510, 0.7529, 0, 0.7529, 0.7529, 0.5020, 0.7529, 0.7529, 0.2510, 0.2510, 0.2510, 0.7529, 0.2510, 0.2510, 0.2510, 0.7529, 0.2510, 0.7529, 0.7529, 0.2510, 0.2510, 0.2510, 0.7529, 0.7529, 0.2510, 0.7529, 0.2510, 0.7529, 0.7529, 0.7529, 0.7529, 0.7529, 0.1255, 0, 0, 0.6275, 0, 0, 0.1255, 0.5020, 0, 0.6275, 0.5020, 0, 0.1255, 0, 0.5020, 0.6275, 0, 0.5020, 0.1255, 0.5020, 0.5020, 0.6275, 0.5020, 0.5020, 0.3765, 0, 0, 0.8784, 0, 0, 0.3765, 0.5020, 0, 0.8784, 0.5020, 0, 0.3765, 0, 0.5020, 0.8784, 0, 0.5020, 0.3765, 0.5020, 0.5020, 0.8784, 0.5020, 0.5020, 0.1255, 0.2510, 0, 0.6275, 0.2510, 0, 0.1255, 0.7529, 0, 0.6275, 0.7529, 0, 0.1255, 0.2510, 0.5020, 0.6275, 0.2510, 0.5020, 0.1255, 0.7529, 0.5020, 0.6275, 0.7529, 0.5020, 0.3765, 0.2510, 0, 0.8784, 0.2510, 0, 0.3765, 0.7529, 0, 0.8784, 0.7529, 0, 0.3765, 0.2510, 0.5020, 0.8784, 0.2510, 0.5020, 0.3765, 0.7529, 0.5020, 0.8784, 0.7529, 0.5020, 0.1255, 0, 0.2510, 0.6275, 0, 0.2510, 0.1255, 0.5020, 0.2510, 0.6275, 0.5020, 0.2510, 0.1255, 0, 0.7529, 0.6275, 0, 0.7529, 0.1255, 0.5020, 0.7529, 0.6275, 0.5020, 0.7529, 0.3765, 0, 0.2510, 0.8784, 0, 0.2510, 0.3765, 0.5020, 0.2510, 0.8784, 0.5020, 0.2510, 0.3765, 0, 0.7529, 0.8784, 0, 0.7529, 0.3765, 0.5020, 0.7529, 0.8784, 0.5020, 0.7529, 0.1255, 0.2510, 0.2510, 0.6275, 0.2510, 0.2510, 0.1255, 0.7529, 0.2510, 0.6275, 0.7529, 0.2510, 0.1255, 0.2510, 0.7529, 0.6275, 0.2510, 0.7529, 0.1255, 0.7529, 0.7529, 0.6275, 0.7529, 0.7529, 0.3765, 0.2510, 0.2510, 0.8784, 0.2510, 0.2510, 0.3765, 0.7529, 0.2510, 0.8784, 0.7529, 0.2510, 0.3765, 0.2510, 0.7529, 0.8784, 0.2510, 0.7529, 0.3765, 0.7529, 0.7529, 0.8784, 0.7529, 0.7529, 0, 0.1255, 0, 0.5020, 0.1255, 0, 0, 0.6275, 0, 0.5020, 0.6275, 0, 0, 0.1255, 0.5020, 0.5020, 0.1255, 0.5020, 0, 0.6275, 0.5020, 0.5020, 0.6275, 0.5020, 0.2510, 0.1255, 0, 0.7529, 0.1255, 0, 0.2510, 0.6275, 0, 0.7529, 0.6275, 0, 0.2510, 0.1255, 0.5020, 0.7529, 0.1255, 0.5020, 0.2510, 0.6275, 0.5020, 0.7529, 0.6275, 0.5020, 0, 0.3765, 0, 0.5020, 0.3765, 0, 0, 0.8784, 0, 0.5020, 0.8784, 0, 0, 0.3765, 0.5020, 0.5020, 0.3765, 0.5020, 0, 0.8784, 0.5020, 0.5020, 0.8784, 0.5020, 0.2510, 0.3765, 0, 0.7529, 0.3765, 0, 0.2510, 0.8784, 0, 0.7529, 0.8784, 0, 0.2510, 0.3765, 0.5020, 0.7529, 0.3765, 0.5020, 0.2510, 0.8784, 0.5020, 0.7529, 0.8784, 0.5020, 0, 0.1255, 0.2510, 0.5020, 0.1255, 0.2510, 0, 0.6275, 0.2510, 0.5020, 0.6275, 0.2510, 0, 0.1255, 0.7529, 0.5020, 0.1255, 0.7529, 0, 0.6275, 0.7529, 0.5020, 0.6275, 0.7529, 0.2510, 0.1255, 0.2510, 0.7529, 0.1255, 0.2510, 0.2510, 0.6275, 0.2510, 0.7529, 0.6275, 0.2510, 0.2510, 0.1255, 0.7529, 0.7529, 0.1255, 0.7529, 0.2510, 0.6275, 0.7529, 0.7529, 0.6275, 0.7529, 0, 0.3765, 0.2510, 0.5020, 0.3765, 0.2510, 0, 0.8784, 0.2510, 0.5020, 0.8784, 0.2510, 0, 0.3765, 0.7529, 0.5020, 0.3765, 0.7529, 0, 0.8784, 0.7529, 0.5020, 0.8784, 0.7529, 0.2510, 0.3765, 0.2510, 0.7529, 0.3765, 0.2510, 0.2510, 0.8784, 0.2510, 0.7529, 0.8784, 0.2510, 0.2510, 0.3765, 0.7529, 0.7529, 0.3765, 0.7529, 0.2510, 0.8784, 0.7529, 0.7529, 0.8784, 0.7529, 0.1255, 0.1255, 0, 0.6275, 0.1255, 0, 0.1255, 0.6275, 0, 0.6275, 0.6275, 0, 0.1255, 0.1255, 0.5020, 0.6275, 0.1255, 0.5020, 0.1255, 0.6275, 0.5020, 0.6275, 0.6275, 0.5020, 0.3765, 0.1255, 0, 0.8784, 0.1255, 0, 0.3765, 0.6275, 0, 0.8784, 0.6275, 0, 0.3765, 0.1255, 0.5020, 0.8784, 0.1255, 0.5020, 0.3765, 0.6275, 0.5020, 0.8784, 0.6275, 0.5020, 0.1255, 0.3765, 0, 0.6275, 0.3765, 0, 0.1255, 0.8784, 0, 0.6275, 0.8784, 0, 0.1255, 0.3765, 0.5020, 0.6275, 0.3765, 0.5020, 0.1255, 0.8784, 0.5020, 0.6275, 0.8784, 0.5020, 0.3765, 0.3765, 0, 0.8784, 0.3765, 0, 0.3765, 0.8784, 0, 0.8784, 0.8784, 0, 0.3765, 0.3765, 0.5020, 0.8784, 0.3765, 0.5020, 0.3765, 0.8784, 0.5020, 0.8784, 0.8784, 0.5020, 0.1255, 0.1255, 0.2510, 0.6275, 0.1255, 0.2510, 0.1255, 0.6275, 0.2510, 0.6275, 0.6275, 0.2510, 0.1255, 0.1255, 0.7529, 0.6275, 0.1255, 0.7529, 0.1255, 0.6275, 0.7529, 0.6275, 0.6275, 0.7529, 0.3765, 0.1255, 0.2510, 0.8784, 0.1255, 0.2510, 0.3765, 0.6275, 0.2510, 0.8784, 0.6275, 0.2510, 0.3765, 0.1255, 0.7529, 0.8784, 0.1255, 0.7529, 0.3765, 0.6275, 0.7529, 0.8784, 0.6275, 0.7529, 0.1255, 0.3765, 0.2510, 0.6275, 0.3765, 0.2510, 0.1255, 0.8784, 0.2510, 0.6275, 0.8784, 0.2510, 0.1255, 0.3765, 0.7529, 0.6275, 0.3765, 0.7529, 0.1255, 0.8784, 0.7529, 0.6275, 0.8784, 0.7529, 0.3765, 0.3765, 0.2510, 0.8784, 0.3765, 0.2510, 0.3765, 0.8784, 0.2510, 0.8784, 0.8784, 0.2510, 0.3765, 0.3765, 0.7529, 0.8784, 0.3765, 0.7529, 0.3765, 0.8784, 0.7529, 0.8784, 0.8784, 0.7529]
33.941634
33
0.38324
1,410
8,723
2.370213
0.007092
0.076601
0.229803
0.041891
0.994614
0.728007
0.728007
0.669659
0.652902
0.486535
0
0.700189
0.455119
8,723
257
34
33.941634
0.002946
0
0
0
0
0
0
0
0
0
0
0
0
1
0
false
0
0
0
0
0
0
0
0
null
0
1
0
1
1
1
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
6
b3752c432aadccc554ead7ac68bb6dbd18cb3da5
35
py
Python
__init__.py
lbk0116/Inventory
ad9ff0b5ddf8550a0375971a34d6c820252121fd
[ "Apache-2.0" ]
3
2018-11-22T11:38:56.000Z
2022-03-22T03:55:57.000Z
__init__.py
lbk0116/Inventory
ad9ff0b5ddf8550a0375971a34d6c820252121fd
[ "Apache-2.0" ]
null
null
null
__init__.py
lbk0116/Inventory
ad9ff0b5ddf8550a0375971a34d6c820252121fd
[ "Apache-2.0" ]
3
2016-11-14T06:58:15.000Z
2020-03-12T12:49:06.000Z
from . import models import wizard
11.666667
20
0.8
5
35
5.6
0.8
0
0
0
0
0
0
0
0
0
0
0
0.171429
35
3
21
11.666667
0.965517
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
1
0
0
6
2fea72589bfbaa29e9fc970aba6af3301f9f5fc2
20
py
Python
geolearn/__init__.py
Guoyinzh/geolearn
564a103246c1fd326f8b2b7d8d8c88ab391e2450
[ "Apache-2.0" ]
1
2020-07-06T17:32:44.000Z
2020-07-06T17:32:44.000Z
geolearn/__init__.py
Guoyinzh/geolearn
564a103246c1fd326f8b2b7d8d8c88ab391e2450
[ "Apache-2.0" ]
null
null
null
geolearn/__init__.py
Guoyinzh/geolearn
564a103246c1fd326f8b2b7d8d8c88ab391e2450
[ "Apache-2.0" ]
null
null
null
from . import test
6.666667
18
0.7
3
20
4.666667
1
0
0
0
0
0
0
0
0
0
0
0
0.25
20
2
19
10
0.933333
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
1
0
0
6
2ff3d1cc544686c2e39737e3bc1efd77dd54010c
163
py
Python
app/location/admin.py
maro99/yapen
0de7aa9d4b152aadd18511be6e536e89645452d9
[ "MIT" ]
1
2019-04-28T12:21:51.000Z
2019-04-28T12:21:51.000Z
app/location/admin.py
maro99/yapen
0de7aa9d4b152aadd18511be6e536e89645452d9
[ "MIT" ]
5
2018-07-30T05:44:44.000Z
2020-06-05T18:56:41.000Z
app/location/admin.py
maro99/yapen
0de7aa9d4b152aadd18511be6e536e89645452d9
[ "MIT" ]
5
2018-07-23T05:21:41.000Z
2018-08-08T05:00:42.000Z
from django.contrib import admin from .models import Location, Pension, Room admin.site.register(Location) admin.site.register(Pension) admin.site.register(Room)
23.285714
43
0.815951
23
163
5.782609
0.478261
0.203008
0.383459
0
0
0
0
0
0
0
0
0
0.08589
163
7
44
23.285714
0.892617
0
0
0
0
0
0
0
0
0
0
0
0
1
0
true
0
0.4
0
0.4
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
1
0
1
0
0
0
0
6
ff4c68831d8defaece370c6ad91a7c475163247e
270
py
Python
{{cookiecutter.project_slug}}/{{cookiecutter.project_slug}}/frontend_templates/skeleton/api.py
chrishavlin/dxlcookiecuttertest
b297760506d65e42f546a2051c3b8d2f1e7167b7
[ "BSD-3-Clause" ]
null
null
null
{{cookiecutter.project_slug}}/{{cookiecutter.project_slug}}/frontend_templates/skeleton/api.py
chrishavlin/dxlcookiecuttertest
b297760506d65e42f546a2051c3b8d2f1e7167b7
[ "BSD-3-Clause" ]
1
2022-03-23T23:22:54.000Z
2022-03-23T23:22:54.000Z
{{cookiecutter.project_slug}}/{{cookiecutter.project_slug}}/frontend_templates/skeleton/api.py
chrishavlin/dxlcookiecuttertest
b297760506d65e42f546a2051c3b8d2f1e7167b7
[ "BSD-3-Clause" ]
1
2021-10-20T19:37:13.000Z
2021-10-20T19:37:13.000Z
from .data_structures import {{ cookiecutter.frontend_name }}Dataset, {{ cookiecutter.frontend_name }}Grid, {{ cookiecutter.frontend_name }}Hierarchy from .fields import {{ cookiecutter.frontend_name }}FieldInfo from .io import {{ cookiecutter.frontend_name }}IOHandler
67.5
149
0.8
30
270
7
0.466667
0.47619
0.571429
0.428571
0
0
0
0
0
0
0
0
0.088889
270
3
150
90
0.853659
0
0
0
0
0
0
0
0
0
0
0
0
0
null
null
0
1
null
null
0
0
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
1
0
0
0
1
0
0
0
0
6
ff896dcbaaf6e9f26d02be8d236e46952d348d93
872
py
Python
2017/day05.py
ardavast/AdventOfCode
2c5062e182122a08c10491a5a149286b90ae8688
[ "MIT" ]
null
null
null
2017/day05.py
ardavast/AdventOfCode
2c5062e182122a08c10491a5a149286b90ae8688
[ "MIT" ]
null
null
null
2017/day05.py
ardavast/AdventOfCode
2c5062e182122a08c10491a5a149286b90ae8688
[ "MIT" ]
null
null
null
#!/usr/bin/env python3 def part1(filename): l = [] ip = 0 count = 0 with open(filename) as f: for line in f: l.append(int(line)) while True: try: oldIp = ip ip += l[ip] l[oldIp] += 1 count += 1 except IndexError: print(count) break def part2(filename): l = [] ip = 0 count = 0 with open(filename) as f: for line in f: l.append(int(line)) while True: try: oldIp = ip ip += l[ip] if l[oldIp] >= 3: l[oldIp] -= 1 else: l[oldIp] += 1 count += 1 except IndexError: print(count) break if __name__ == '__main__': part1('day05input.txt') part2('day05input.txt')
17.44
31
0.417431
99
872
3.59596
0.373737
0.033708
0.058989
0.067416
0.724719
0.724719
0.724719
0.724719
0.724719
0.724719
0
0.041304
0.472477
872
50
32
17.44
0.732609
0.024083
0
0.789474
0
0
0.042303
0
0
0
0
0
0
1
0.052632
false
0
0
0
0.052632
0.052632
0
0
0
null
0
0
0
0
1
1
1
1
1
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
6
ffa93a5b82410c0b0e6a689d63d713327a494ed1
122
py
Python
sample_prj/__main__.py
stdtom/sample_prj
18070bc2a21244854b692fb9e048cba71a17f98e
[ "Apache-2.0" ]
null
null
null
sample_prj/__main__.py
stdtom/sample_prj
18070bc2a21244854b692fb9e048cba71a17f98e
[ "Apache-2.0" ]
null
null
null
sample_prj/__main__.py
stdtom/sample_prj
18070bc2a21244854b692fb9e048cba71a17f98e
[ "Apache-2.0" ]
null
null
null
import sys if __name__ == "__main__": import sample_prj.cli sys.exit(sample_prj.cli.main()) # pragma: no cover
17.428571
55
0.680328
18
122
4.055556
0.666667
0.246575
0.328767
0
0
0
0
0
0
0
0
0
0.196721
122
6
56
20.333333
0.744898
0.131148
0
0
0
0
0.076923
0
0
0
0
0
0
1
0
true
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
1
0
1
0
0
0
0
6
ffb113153c13d33cca3df295a01ea6e53111a559
23
py
Python
er1_robot/devel/lib/python2.7/dist-packages/er1_motor_driver/msg/__init__.py
arvindpereira/clover_hack_day
f8f49d7401b21c3932bd09dd58d7f2b9ba33ea6b
[ "MIT" ]
2
2015-10-13T18:12:30.000Z
2015-10-24T19:03:21.000Z
er1_robot/devel/lib/python2.7/dist-packages/er1_motor_driver/msg/__init__.py
arvindpereira/clover_hack_day
f8f49d7401b21c3932bd09dd58d7f2b9ba33ea6b
[ "MIT" ]
null
null
null
er1_robot/devel/lib/python2.7/dist-packages/er1_motor_driver/msg/__init__.py
arvindpereira/clover_hack_day
f8f49d7401b21c3932bd09dd58d7f2b9ba33ea6b
[ "MIT" ]
1
2020-05-08T23:13:28.000Z
2020-05-08T23:13:28.000Z
from ._Motors import *
11.5
22
0.73913
3
23
5.333333
1
0
0
0
0
0
0
0
0
0
0
0
0.173913
23
1
23
23
0.842105
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
1
0
0
6
442e6ef248fb4debacebd00e87b8518578ca93e2
4,247
py
Python
tests/components/shelly/test_button.py
MrDelik/core
93a66cc357b226389967668441000498a10453bb
[ "Apache-2.0" ]
30,023
2016-04-13T10:17:53.000Z
2020-03-02T12:56:31.000Z
tests/components/shelly/test_button.py
MrDelik/core
93a66cc357b226389967668441000498a10453bb
[ "Apache-2.0" ]
31,101
2020-03-02T13:00:16.000Z
2022-03-31T23:57:36.000Z
tests/components/shelly/test_button.py
MrDelik/core
93a66cc357b226389967668441000498a10453bb
[ "Apache-2.0" ]
11,956
2016-04-13T18:42:31.000Z
2020-03-02T09:32:12.000Z
"""Tests for Shelly button platform.""" from homeassistant.components.button import DOMAIN as BUTTON_DOMAIN from homeassistant.components.button.const import SERVICE_PRESS from homeassistant.components.shelly.const import DOMAIN from homeassistant.const import ATTR_ENTITY_ID, STATE_UNKNOWN from homeassistant.core import HomeAssistant from homeassistant.helpers.entity_registry import async_get async def test_block_button(hass: HomeAssistant, coap_wrapper): """Test block device OTA button.""" assert coap_wrapper entity_registry = async_get(hass) entity_registry.async_get_or_create( BUTTON_DOMAIN, DOMAIN, "test_name_ota_update_beta", suggested_object_id="test_name_ota_update_beta", disabled_by=None, ) hass.async_create_task( hass.config_entries.async_forward_entry_setup(coap_wrapper.entry, BUTTON_DOMAIN) ) await hass.async_block_till_done() # stable channel button state = hass.states.get("button.test_name_ota_update") assert state assert state.state == STATE_UNKNOWN await hass.services.async_call( BUTTON_DOMAIN, SERVICE_PRESS, {ATTR_ENTITY_ID: "button.test_name_ota_update"}, blocking=True, ) await hass.async_block_till_done() assert coap_wrapper.device.trigger_ota_update.call_count == 1 coap_wrapper.device.trigger_ota_update.assert_called_with(beta=False) # beta channel button state = hass.states.get("button.test_name_ota_update_beta") assert state assert state.state == STATE_UNKNOWN await hass.services.async_call( BUTTON_DOMAIN, SERVICE_PRESS, {ATTR_ENTITY_ID: "button.test_name_ota_update_beta"}, blocking=True, ) await hass.async_block_till_done() assert coap_wrapper.device.trigger_ota_update.call_count == 2 coap_wrapper.device.trigger_ota_update.assert_called_with(beta=True) # reboot button state = hass.states.get("button.test_name_reboot") assert state assert state.state == STATE_UNKNOWN await hass.services.async_call( BUTTON_DOMAIN, SERVICE_PRESS, {ATTR_ENTITY_ID: "button.test_name_reboot"}, blocking=True, ) await hass.async_block_till_done() assert coap_wrapper.device.trigger_reboot.call_count == 1 async def test_rpc_button(hass: HomeAssistant, rpc_wrapper): """Test rpc device OTA button.""" assert rpc_wrapper entity_registry = async_get(hass) entity_registry.async_get_or_create( BUTTON_DOMAIN, DOMAIN, "test_name_ota_update_beta", suggested_object_id="test_name_ota_update_beta", disabled_by=None, ) hass.async_create_task( hass.config_entries.async_forward_entry_setup(rpc_wrapper.entry, BUTTON_DOMAIN) ) await hass.async_block_till_done() # stable channel button state = hass.states.get("button.test_name_ota_update") assert state assert state.state == STATE_UNKNOWN await hass.services.async_call( BUTTON_DOMAIN, SERVICE_PRESS, {ATTR_ENTITY_ID: "button.test_name_ota_update"}, blocking=True, ) await hass.async_block_till_done() assert rpc_wrapper.device.trigger_ota_update.call_count == 1 rpc_wrapper.device.trigger_ota_update.assert_called_with(beta=False) # beta channel button state = hass.states.get("button.test_name_ota_update_beta") assert state assert state.state == STATE_UNKNOWN await hass.services.async_call( BUTTON_DOMAIN, SERVICE_PRESS, {ATTR_ENTITY_ID: "button.test_name_ota_update_beta"}, blocking=True, ) await hass.async_block_till_done() assert rpc_wrapper.device.trigger_ota_update.call_count == 2 rpc_wrapper.device.trigger_ota_update.assert_called_with(beta=True) # reboot button state = hass.states.get("button.test_name_reboot") assert state assert state.state == STATE_UNKNOWN await hass.services.async_call( BUTTON_DOMAIN, SERVICE_PRESS, {ATTR_ENTITY_ID: "button.test_name_reboot"}, blocking=True, ) await hass.async_block_till_done() assert rpc_wrapper.device.trigger_reboot.call_count == 1
31
88
0.724276
553
4,247
5.191682
0.122966
0.062696
0.045977
0.071055
0.823058
0.823058
0.823058
0.811912
0.810519
0.810519
0
0.001759
0.196609
4,247
136
89
31.227941
0.839683
0.034377
0
0.692308
0
0
0.106415
0.106415
0
0
0
0
0.230769
1
0
false
0
0.057692
0
0.057692
0
0
0
0
null
0
0
0
1
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
6
448bc3f126a69a907adcc735a65603294cbbec79
185
py
Python
books/models.py
f4ww4z/my_library_django_emberjs
1cf563bdcdbbe585c1716c79f87d803119bbc840
[ "MIT" ]
null
null
null
books/models.py
f4ww4z/my_library_django_emberjs
1cf563bdcdbbe585c1716c79f87d803119bbc840
[ "MIT" ]
null
null
null
books/models.py
f4ww4z/my_library_django_emberjs
1cf563bdcdbbe585c1716c79f87d803119bbc840
[ "MIT" ]
null
null
null
from django.db import models class Book(models.Model): title = models.CharField(max_length=500) author = models.CharField(max_length=100) description = models.TextField()
23.125
45
0.740541
24
185
5.625
0.708333
0.222222
0.266667
0.355556
0
0
0
0
0
0
0
0.038462
0.156757
185
7
46
26.428571
0.826923
0
0
0
0
0
0
0
0
0
0
0
0
1
0
false
0
0.2
0
1
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
1
0
0
6
92643cd1a7b4ee7a4afe054d0f5cdb695fbb4009
5,976
py
Python
test/test_generate_buildspec.py
exasol/script-languages-container-ci-setup
f08a692c2f79a071df3f9240b2754279dc7edaba
[ "MIT" ]
null
null
null
test/test_generate_buildspec.py
exasol/script-languages-container-ci-setup
f08a692c2f79a071df3f9240b2754279dc7edaba
[ "MIT" ]
2
2022-03-16T19:43:11.000Z
2022-03-18T06:31:26.000Z
test/test_generate_buildspec.py
exasol/script-languages-container-ci-setup
f08a692c2f79a071df3f9240b2754279dc7edaba
[ "MIT" ]
null
null
null
import json import jsonschema import pytest from exasol_script_languages_container_ci_setup.lib.render_template import render_template from exasol_script_languages_container_ci_setup.lib.run_generate_buildspec import run_generate_buildspec, \ get_config_file_parameter from exasol_script_languages_container_ci_setup.lib.run_generate_release_buildspec import run_generate_release_buildspec expected_result_root_buildspec = """version: 0.2 # ---- AUTOMATICALLY GENERATED FILE -------- # ---- DO NOT EDIT MANUALLY, BUT USE PYTHON MODULE "script-languages-container-ci-setup" TO UPDATE --- batch: fast-fail: false build-graph: - identifier: build_test_flavor env: variables: FLAVOR: test-flavor buildspec: {location}/build_buildspec.yaml privileged-mode: true type: BUILD_GENERAL1_MEDIUM """ def test_buildspec(tmp_path): """ Run run_generate_buildspec() for one flavor and compare result! """ root_path = tmp_path / "flavors" test_flavor = root_path / "test-flavor" test_flavor.mkdir(parents=True, exist_ok=False) out_path = tmp_path / "out" out_path.mkdir(parents=False, exist_ok=False) run_generate_buildspec((str(root_path),), str(out_path.absolute()), config_file=None) with open(out_path / "buildspec.yaml", "r") as res_file: res = res_file.read() assert res == expected_result_root_buildspec.format(location=str(out_path)) with open(out_path / "build_buildspec.yaml", "r") as res_file: res = res_file.read() # For build_buildspec.yaml we re-use the template for testing expected_result_build_buildspec = render_template("build_buildspec.yaml", config_file_parameter="") assert res == expected_result_build_buildspec def test_release_buildspec(tmp_path): """ Run run_generate_release_buildspec() for one flavor and compare result! """ root_path = tmp_path / "flavors" test_flavor = root_path / "test-flavor" test_flavor.mkdir(parents=True, exist_ok=False) out_path = tmp_path / "out" out_path.mkdir(parents=False, exist_ok=False) run_generate_release_buildspec((str(root_path),), str(out_path.absolute()), config_file=None) with open(out_path / "buildspec.yaml", "r") as res_file: res = res_file.read() assert res == expected_result_root_buildspec.format(location=str(out_path)) with open(out_path / "build_buildspec.yaml", "r") as res_file: res = res_file.read() # For build_buildspec.yaml we re-use the template for testing expected_result_build_buildspec = render_template("release_build_buildspec.yaml", config_file_parameter="") assert res == expected_result_build_buildspec def test_buildspec_with_valid_config_file(tmp_path): """ Run run_generate_buildspec() for one flavor with a valid config file and compare result! """ root_path = tmp_path / "flavors" test_flavor = root_path / "test-flavor" test_flavor.mkdir(parents=True, exist_ok=False) out_path = tmp_path / "out" out_path.mkdir(parents=False, exist_ok=False) a_folder = tmp_path / "a_folder" a_folder.mkdir(parents=False, exist_ok=False) config_file_path = tmp_path / "build_config.json" config = {"build_ignore": {"ignored_paths": [str(a_folder)]}} with open(config_file_path, "w") as f: json.dump(config, f) run_generate_buildspec((str(root_path),), str(out_path.absolute()), config_file=str(config_file_path.absolute())) with open(out_path / "buildspec.yaml", "r") as res_file: res = res_file.read() assert res == expected_result_root_buildspec.format(location=str(out_path)) with open(out_path / "build_buildspec.yaml", "r") as res_file: res = res_file.read() # For build_buildspec.yaml we re-use the template for testing expected_result_build_buildspec = render_template("build_buildspec.yaml", config_file_parameter= get_config_file_parameter(config_file_path)) assert res == expected_result_build_buildspec def test_buildspec_with_invalid_config_file(tmp_path): """ Run run_generate_buildspec() for one flavor with an invalid config file and check for correct exception! """ root_path = tmp_path / "flavors" test_flavor = root_path / "test-flavor" test_flavor.mkdir(parents=True, exist_ok=False) out_path = tmp_path / "out" out_path.mkdir(parents=False, exist_ok=False) config_file_path = tmp_path / "build_config.json" # Incorrect config ('ignored_path' instead of 'ignored_paths') config = {"build_ignore": {"ignored_path": ["a_folder"]}} with open(config_file_path, "w") as f: json.dump(config, f) with pytest.raises(jsonschema.exceptions.ValidationError): run_generate_buildspec((str(root_path),), str(out_path.absolute()), config_file=str(config_file_path.absolute())) def test_buildspec_with_invalid_folder(tmp_path): """ Run run_generate_buildspec() for one flavor with a valid config file, but invalid content and check for correct exception! """ root_path = tmp_path / "flavors" test_flavor = root_path / "test-flavor" test_flavor.mkdir(parents=True, exist_ok=False) out_path = tmp_path / "out" out_path.mkdir(parents=False, exist_ok=False) config_file_path = tmp_path / "build_config.json" a_folder = tmp_path / "a_folder" # Incorrect config (tmp_path/a_folder does not exists) config = {"build_ignore": {"ignored_paths": [str(a_folder)]}} with open(config_file_path, "w") as f: json.dump(config, f) with pytest.raises(ValueError): run_generate_buildspec((str(root_path),), str(out_path.absolute()), config_file=str(config_file_path.absolute()))
37.822785
120
0.695281
800
5,976
4.86375
0.13875
0.064251
0.036751
0.033924
0.813159
0.796453
0.775636
0.775636
0.764328
0.758931
0
0.000629
0.201305
5,976
157
121
38.063694
0.814582
0.125
0
0.626263
0
0.010101
0.164043
0.022741
0
0
0
0
0.060606
1
0.050505
false
0
0.060606
0
0.111111
0
0
0
0
null
0
0
0
1
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
6
2b983d86724398a1a40618c665f018d5f35181b4
4,533
py
Python
tests/why_test.py
DataCanvasIO/YLearn
d65b5afb83deed154c710de9096317165d95014a
[ "Apache-2.0" ]
3
2022-03-28T07:41:28.000Z
2022-03-29T06:24:52.000Z
tests/why_test.py
DataCanvasIO/YLearn
d65b5afb83deed154c710de9096317165d95014a
[ "Apache-2.0" ]
null
null
null
tests/why_test.py
DataCanvasIO/YLearn
d65b5afb83deed154c710de9096317165d95014a
[ "Apache-2.0" ]
null
null
null
import numpy as np import pytest from ylearn import Why from . import _dgp def _validate_it(cc, test_data): print('-' * 30) e = cc.causal_effect() print('causal effect:', e, sep='\n') print('-' * 30) e = cc.cohort_causal_effect(test_data) print('cohort causal effect:', e, sep='\n') print('-' * 30) e = cc.local_causal_effect(test_data) print('local causal effect:', e, sep='\n') if cc.scorers_ is not None: score = cc.score() print("score:", score) def test_basis(): data, test_data, outcome, treatment, adjustment, covariate = _dgp.generate_data_x2b_y1() cc = Why() cc.fit(data, outcome[0], treatment=treatment, adjustment=adjustment, covariate=covariate) _validate_it(cc, test_data) def test_identify_treatment(): data, test_data, outcome, treatment, adjustment, covariate = _dgp.generate_data_x2b_y1() cc = Why() # cc.fit(data, outcome[0], treatment=treatment, adjustment=adjustment, covariate=covariate) cc.fit(data, outcome[0], treatment=None, adjustment=adjustment, covariate=covariate) _validate_it(cc, test_data) def test_whatif_discrete(): data, test_data, outcome, treatment, adjustment, covariate = _dgp.generate_data_x2b_y1() cc = Why() cc.fit(data, outcome[0], treatment=treatment, adjustment=adjustment, covariate=covariate) new_value = np.ones_like(test_data[treatment[0]]) new_y = cc.whatif(test_data, new_value, treatment[0]) assert new_y is not None print(new_y.shape, new_y) def test_whatif_continuous(): data, test_data, outcome, treatment, adjustment, covariate = _dgp.generate_data_x1m_y1() data[treatment] = data[treatment].astype('float32') test_data[treatment] = test_data[treatment].astype('float32') cc = Why() cc.fit(data, outcome[0], treatment=treatment, adjustment=adjustment, covariate=covariate) new_value = np.ones_like(test_data[treatment[0]]) new_y = cc.whatif(test_data, new_value, treatment[0]) assert new_y is not None print(new_y.shape, new_y) def test_policy_tree(): data, test_data, outcome, treatment, adjustment, covariate = _dgp.generate_data_x1m_y1() # data[treatment] = data[treatment].astype('float32') # test_data[treatment] = test_data[treatment].astype('float32') cc = Why() cc.fit(data, outcome[0], treatment=treatment, adjustment=adjustment, covariate=covariate) ptree = cc.policy_tree(test_data) assert ptree is not None def test_policy_tree_dml(): data, test_data, outcome, treatment, adjustment, covariate = _dgp.generate_data_x1m_y1() # data[treatment] = data[treatment].astype('float32') # test_data[treatment] = test_data[treatment].astype('float32') cc = Why(estimator='dml') # cc.fit(data, outcome[0], treatment=treatment, adjustment=adjustment, covariate=covariate) cc.fit(data, treatment[0], treatment=outcome, adjustment=adjustment, covariate=covariate) ptree = cc.policy_tree(test_data) assert ptree is not None def test_policy_interpreter(): data, test_data, outcome, treatment, adjustment, covariate = _dgp.generate_data_x1m_y1() # data[treatment] = data[treatment].astype('float32') # test_data[treatment] = test_data[treatment].astype('float32') cc = Why() cc.fit(data, outcome[0], treatment=treatment, adjustment=adjustment, covariate=covariate) pi = cc.policy_interpreter(test_data) assert pi is not None @pytest.mark.xfail(reason='to be fixed') def test_discovery_treatment(): data, test_data, outcome, treatment, adjustment, covariate = _dgp.generate_data_x2b_y1() cc = Why(identify='discovery') # cc.fit(data, outcome[0], treatment=treatment, adjustment=adjustment, covariate=covariate) cc.fit(data, outcome[0], treatment=None, adjustment=adjustment, covariate=covariate) _validate_it(cc, test_data) @pytest.mark.xfail(reason='to be fixed') def test_discovery_taci(): data, test_data, outcome, treatment, adjustment, covariate = _dgp.generate_data_x2b_y1() cc = Why(identify='discovery') # cc.fit(data, outcome[0], treatment=treatment, adjustment=adjustment, covariate=covariate) cc.fit(data, outcome[0]) _validate_it(cc, test_data) @pytest.mark.xfail(reason='to be fixed') def test_score(): data, test_data, outcome, treatment, adjustment, covariate = _dgp.generate_data_x2b_y1() cc = Why(scorer='auto') cc.fit(data, outcome[0], treatment=treatment, adjustment=adjustment, covariate=covariate) _validate_it(cc, test_data)
35.414063
95
0.716744
607
4,533
5.14168
0.116969
0.084588
0.040372
0.066645
0.891381
0.863505
0.863505
0.863505
0.863505
0.846203
0
0.015649
0.154203
4,533
127
96
35.692913
0.798383
0.154644
0
0.604938
0
0
0.037163
0
0
0
0
0
0.061728
1
0.135802
false
0
0.049383
0
0.185185
0.111111
0
0
0
null
0
0
0
1
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
6
2bbcdcdc6de71119b96227a5b497b519f08a3c45
214
py
Python
conftest.py
gis-ops/pyvroom
b7d23e405b8734c5672eecf6f394b6364103cbf1
[ "BSD-2-Clause" ]
13
2021-12-28T13:04:45.000Z
2022-01-06T22:05:51.000Z
conftest.py
gis-ops/pyvroom
b7d23e405b8734c5672eecf6f394b6364103cbf1
[ "BSD-2-Clause" ]
26
2022-01-06T09:36:45.000Z
2022-03-26T11:43:14.000Z
conftest.py
gis-ops/pyvroom
b7d23e405b8734c5672eecf6f394b6364103cbf1
[ "BSD-2-Clause" ]
4
2022-01-06T14:34:56.000Z
2022-03-29T11:53:48.000Z
"""Global configuration.""" import pytest import vroom @pytest.fixture(autouse=True) def global_setup(doctest_namespace, monkeypatch): """Global configuration setup.""" doctest_namespace["vroom"] = vroom
21.4
49
0.747664
23
214
6.826087
0.565217
0.242038
0.267516
0
0
0
0
0
0
0
0
0
0.121495
214
9
50
23.777778
0.835106
0.228972
0
0
0
0
0.032468
0
0
0
0
0
0
1
0.2
false
0
0.4
0
0.6
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
1
0
0
6
2bc343abf90757353d1b70330baa2d21aeff8153
77
py
Python
katas/beta/strange_strings_parser.py
the-zebulan/CodeWars
1eafd1247d60955a5dfb63e4882e8ce86019f43a
[ "MIT" ]
40
2016-03-09T12:26:20.000Z
2022-03-23T08:44:51.000Z
katas/beta/strange_strings_parser.py
akalynych/CodeWars
1eafd1247d60955a5dfb63e4882e8ce86019f43a
[ "MIT" ]
null
null
null
katas/beta/strange_strings_parser.py
akalynych/CodeWars
1eafd1247d60955a5dfb63e4882e8ce86019f43a
[ "MIT" ]
36
2016-11-07T19:59:58.000Z
2022-03-31T11:18:27.000Z
import re def parser(strng): return re.split(r'[!#%&*+:;=>?|]', strng)
12.833333
45
0.532468
10
77
4.1
0.8
0
0
0
0
0
0
0
0
0
0
0
0.168831
77
5
46
15.4
0.640625
0
0
0
0
0
0.181818
0
0
0
0
0
0
1
0.333333
false
0
0.333333
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
1
1
1
0
0
6
2bca8a2db048e3f61a09f989ebd1167e223f41e3
5,002
py
Python
wdae/wdae/family_api/tests/test_family_api.py
iossifovlab/gpf
e556243d29666179dbcb72859845b4d6c011af2b
[ "MIT" ]
null
null
null
wdae/wdae/family_api/tests/test_family_api.py
iossifovlab/gpf
e556243d29666179dbcb72859845b4d6c011af2b
[ "MIT" ]
82
2019-07-22T11:44:23.000Z
2022-01-13T15:27:33.000Z
wdae/wdae/family_api/tests/test_family_api.py
iossifovlab/gpf
e556243d29666179dbcb72859845b4d6c011af2b
[ "MIT" ]
null
null
null
import pytest from rest_framework import status from dae.variants.attributes import Sex, Role, Status pytestmark = pytest.mark.usefixtures( "wdae_gpf_instance", "dae_calc_gene_sets") def test_list_families_view(admin_client): url = "/api/v3/families/Study1" response = admin_client.get(url) assert response.status_code == status.HTTP_200_OK assert list(response.data) == [ "f1", "f3", "f4", "f5", "f6", "f7", "f8", "f9", "f10", "f11" ] def test_list_families_view_nonexistent(admin_client): url = "/api/v3/families/Study123123123" response = admin_client.get(url) assert response.status_code == status.HTTP_404_NOT_FOUND def test_family_details_view(admin_client): url = "/api/v3/families/Study1/f6" response = admin_client.get(url) assert response.status_code == status.HTTP_200_OK assert response.data == { "family_id": "f6", "family_type": "TRIO", "person_ids": ["mom6", "dad6", "ch6"], "samples_index": None } def test_family_details_view_nonexistent(admin_client): url = "/api/v3/families/Study1/f654654654" response = admin_client.get(url) assert response.status_code == status.HTTP_404_NOT_FOUND def test_list_members_view(admin_client): url = "/api/v3/families/Study1/f6/members" response = admin_client.get(url) assert response.status_code == status.HTTP_200_OK assert response.data == ["mom6", "dad6", "ch6"] def test_list_members_view_nonexistent(admin_client): url = "/api/v3/families/Study1/f654654654/members" response = admin_client.get(url) assert response.status_code == status.HTTP_404_NOT_FOUND def test_member_details_view(admin_client): url = "/api/v3/families/Study1/f6/members/ch6" response = admin_client.get(url) assert response.status_code == status.HTTP_200_OK assert response.data == { "person_id": "ch6", "family_id": "f6", "dad_id": "dad6", "mom_id": "mom6", "sample_id": "ch6", "index": 2, "sex": str(Sex.male), "role": str(Role.prb), "status": str(Status.affected), "layout": None, "generated": None, "family_bin": None, "not_sequenced": None, "missing": False, } def test_member_details_view_nonexistent(admin_client): url = "/api/v3/families/Study1/f6/members/ch456456" response = admin_client.get(url) assert response.status_code == status.HTTP_404_NOT_FOUND def test_full_family_details_view(admin_client): url = "/api/v3/families/Study1/f6/members/all" response = admin_client.get(url) assert response.status_code == status.HTTP_200_OK assert len(response.data) == 3 assert response.data[0] == { "person_id": "mom6", "family_id": "f6", "dad_id": None, "mom_id": None, "sample_id": "mom6", "index": 0, "sex": str(Sex.female), "role": str(Role.mom), "status": str(Status.unaffected), "layout": None, "generated": None, "family_bin": None, "not_sequenced": None, "missing": False, } assert response.data[1] == { "person_id": "dad6", "family_id": "f6", "dad_id": None, "mom_id": None, "sample_id": "dad6", "index": 1, "sex": str(Sex.male), "role": str(Role.dad), "status": str(Status.unaffected), "layout": None, "generated": None, "family_bin": None, "not_sequenced": None, "missing": False, } assert response.data[2] == { "person_id": "ch6", "family_id": "f6", "dad_id": "dad6", "mom_id": "mom6", "sample_id": "ch6", "index": 2, "sex": str(Sex.male), "role": str(Role.prb), "status": str(Status.affected), "layout": None, "generated": None, "family_bin": None, "not_sequenced": None, "missing": False, } def test_full_study_families_view(admin_client): url = "/api/v3/families/Study1/all" response = admin_client.get(url) assert response.status_code == status.HTTP_200_OK assert len(response.data) == 10 f6_idx = -1 for idx, fam in enumerate(response.data): if fam["family_id"] == "f6": f6_idx = idx break f6 = response.data[f6_idx] assert f6["family_id"] == "f6" assert f6["family_type"] == "TRIO" assert f6["person_ids"] == ["mom6", "dad6", "ch6"] assert len(f6["members"]) == 3 assert f6["members"][2] == { "person_id": "ch6", "family_id": "f6", "dad_id": "dad6", "mom_id": "mom6", "sample_id": "ch6", "index": 2, "sex": str(Sex.male), "role": str(Role.prb), "status": str(Status.affected), "layout": None, "generated": None, "family_bin": None, "not_sequenced": None, "missing": False, }
29.251462
68
0.595162
619
5,002
4.579968
0.164782
0.077601
0.049383
0.059965
0.809877
0.766138
0.766138
0.757672
0.742857
0.707937
0
0.041667
0.251499
5,002
170
69
29.423529
0.715545
0
0
0.571429
0
0
0.222711
0.067173
0
0
0
0
0.163265
1
0.068027
false
0
0.020408
0
0.088435
0
0
0
0
null
0
0
0
1
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
6
2bd216c676218c14da6852516f534f704dff9f8f
95
py
Python
tg-launchbot/permissions.py
499602D2/tg-launchbot
9a947590b3095dece9171bc8e15fd857f4e3fccb
[ "MIT" ]
13
2020-11-05T12:53:31.000Z
2022-02-21T14:27:51.000Z
tg-launchbot/permissions.py
499602D2/tg-launchbot
9a947590b3095dece9171bc8e15fd857f4e3fccb
[ "MIT" ]
3
2021-03-03T20:46:47.000Z
2022-02-11T17:25:50.000Z
tg-launchbot/permissions.py
499602D2/tg-launchbot
9a947590b3095dece9171bc8e15fd857f4e3fccb
[ "MIT" ]
4
2020-11-05T14:07:04.000Z
2022-02-21T14:27:53.000Z
# load the current status of the permissions into memory def load_permissions_status(): return
31.666667
56
0.821053
14
95
5.428571
0.714286
0
0
0
0
0
0
0
0
0
0
0
0.136842
95
3
57
31.666667
0.926829
0.568421
0
0
0
0
0
0
0
0
0
0
0
1
0.5
true
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
1
0
0
1
1
0
0
6
921d5bbf4c214e03fc1118b76c9c57d483e2f065
6,527
py
Python
tests/test_transform.py
tulibraries/tulflow
652957d079c481a84b3602932ed86f3b2b21e3e9
[ "Apache-2.0" ]
1
2022-03-04T18:27:06.000Z
2022-03-04T18:27:06.000Z
tests/test_transform.py
tulibraries/tulflow
652957d079c481a84b3602932ed86f3b2b21e3e9
[ "Apache-2.0" ]
117
2019-08-29T21:34:53.000Z
2022-03-31T22:11:58.000Z
tests/test_transform.py
tulibraries/tulflow
652957d079c481a84b3602932ed86f3b2b21e3e9
[ "Apache-2.0" ]
1
2021-09-22T20:40:12.000Z
2021-09-22T20:40:12.000Z
"""Tests suite for tulflow.transform (functions for transforming XML or JSON in Airflow Tasks).""" import unittest import boto3 from lxml import etree from moto import mock_s3 from tulflow import transform import logging from mock import patch class TestXSLTransform(unittest.TestCase): """Test Class for functions that transform XML from S3 with XSL.""" maxDiff = None kwargs = { "source_prefix": "dpla_test/new-updated-filtered", "destination_prefix": "dpla_test/transformed", "bucket": "tulib-airflow-test", "schematron_filename": "transforms/dplah.xsl", "access_id": "kittens", "access_secret": "puppies" } def setUp(self): transform.prepare_saxon_engine() @mock_s3 @patch('subprocess.check_output') def test_transform_s3_xml_simple(self, mocked_subprocess): """Test Pulling S3 XML, Transforming with XSLT, & Writing to S3.""" # setup kwargs for test runs access_id = self.kwargs.get("access_id") access_secret = self.kwargs.get("access_secret") bucket = self.kwargs.get("bucket") test_key = self.kwargs.get("source_prefix") + "/xsl-sample.xml" # create expected mocked s3 resources conn = boto3.client("s3", aws_access_key_id=access_id, aws_secret_access_key=access_secret) conn.create_bucket(Bucket=bucket) conn.put_object(Bucket=bucket, Key=test_key, Body=open("tests/fixtures/xsl-sample.xml").read()) test_content_exists = conn.get_object(Bucket=bucket, Key=test_key) test_object_exists = conn.list_objects(Bucket=bucket) self.assertEqual(test_content_exists["Body"].read(), open("tests/fixtures/xsl-sample.xml", "rb").read()) self.assertEqual(test_content_exists["ResponseMetadata"]["HTTPStatusCode"], 200) self.assertEqual(test_object_exists["Contents"][0]["Key"], test_key) # setup mocked subprocess result mocked_subprocess.side_effect = [ open("tests/fixtures/xsl-sample-simple-output-record1.xml", "rb").read(), open("tests/fixtures/xsl-sample-simple-output-record2.xml", "rb").read(), open("tests/fixtures/xsl-sample-simple-output-record3.xml", "rb").read() ] # run tests with self.assertLogs() as log: transform.transform_s3_xsl(**self.kwargs) self.assertIn("INFO:root:Transforming File dpla_test/new-updated-filtered/xsl-sample.xml", log.output) self.assertIn("INFO:root:Transforming Record oai:digital.library.villanova.edu:vudl:293113", log.output) self.assertIn("INFO:root:Transforming Record oai:digital.library.villanova.edu:vudl:469533", log.output) self.assertIn("INFO:root:Transforming Record oai:digital.library.villanova.edu:vudl:469545", log.output) test_output_objects = conn.list_objects(Bucket=bucket, Prefix=self.kwargs.get("destination_prefix")) self.assertEqual(test_output_objects["ResponseMetadata"]["HTTPStatusCode"], 200) test_output_objects_ar = [object.get("Key") for object in test_output_objects["Contents"]] self.assertEqual(test_output_objects_ar, ["dpla_test/transformed/xsl-sample.xml"]) test_output_content = etree.fromstring(conn.get_object(Bucket=bucket, Key="dpla_test/transformed/xsl-sample.xml")["Body"].read()) should_match_output = etree.fromstring(open("tests/fixtures/xsl-sample-simple-output-all.xml", "rb").read()) self.assertEqual( etree.tostring(test_output_content, pretty_print=True), etree.tostring(should_match_output, pretty_print=True) ) @mock_s3 @patch('subprocess.check_output') def test_transform_s3_xml_complex(self, mocked_subprocess): """Test Pulling S3 XML, Transforming with Complex XSLT, & Writing to S3.""" # setup kwargs for test runs access_id = self.kwargs.get("access_id") access_secret = self.kwargs.get("access_secret") bucket = self.kwargs.get("bucket") test_key = self.kwargs.get("source_prefix") + "/xsl-sample.xml" # create expected mocked s3 resources conn = boto3.client("s3", aws_access_key_id=access_id, aws_secret_access_key=access_secret) conn.create_bucket(Bucket=bucket) conn.put_object(Bucket=bucket, Key=test_key, Body=open("tests/fixtures/xsl-sample.xml").read()) test_content_exists = conn.get_object(Bucket=bucket, Key=test_key) test_object_exists = conn.list_objects(Bucket=bucket) self.assertEqual(test_content_exists["Body"].read(), open("tests/fixtures/xsl-sample.xml", "rb").read()) self.assertEqual(test_content_exists["ResponseMetadata"]["HTTPStatusCode"], 200) self.assertEqual(test_object_exists["Contents"][0]["Key"], test_key) # setup mocked subprocess result mocked_subprocess.side_effect = [ open("tests/fixtures/xsl-sample-complex-output-record1.xml", "rb").read(), open("tests/fixtures/xsl-sample-complex-output-record2.xml", "rb").read(), open("tests/fixtures/xsl-sample-complex-output-record3.xml", "rb").read() ] # run tests with self.assertLogs() as log: transform.transform_s3_xsl(**self.kwargs) self.assertIn("INFO:root:Transforming File dpla_test/new-updated-filtered/xsl-sample.xml", log.output) self.assertIn("INFO:root:Transforming Record oai:digital.library.villanova.edu:vudl:293113", log.output) self.assertIn("INFO:root:Transforming Record oai:digital.library.villanova.edu:vudl:469533", log.output) self.assertIn("INFO:root:Transforming Record oai:digital.library.villanova.edu:vudl:469545", log.output) test_output_objects = conn.list_objects(Bucket=bucket, Prefix=self.kwargs.get("destination_prefix")) self.assertEqual(test_output_objects["ResponseMetadata"]["HTTPStatusCode"], 200) test_output_objects_ar = [object.get("Key") for object in test_output_objects["Contents"]] self.assertEqual(test_output_objects_ar, ["dpla_test/transformed/xsl-sample.xml"]) test_output_content = etree.fromstring(conn.get_object(Bucket=bucket, Key="dpla_test/transformed/xsl-sample.xml")["Body"].read()) should_match_output = etree.fromstring(open("tests/fixtures/xsl-sample-complex-output-all.xml", "rb").read()) self.assertEqual( etree.tostring(test_output_content, pretty_print=True), etree.tostring(should_match_output, pretty_print=True) )
56.756522
137
0.700322
828
6,527
5.339372
0.155797
0.040715
0.032572
0.054286
0.886677
0.880796
0.880796
0.874915
0.874915
0.851391
0
0.01383
0.169144
6,527
114
138
57.254386
0.801401
0.075839
0
0.637363
0
0
0.306296
0.216023
0
0
0
0
0.241758
1
0.032967
false
0
0.076923
0
0.142857
0.043956
0
0
0
null
0
0
0
1
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
6
a65dcd00bf345f07f44980c401a3295f844e34fd
154
py
Python
Scalability_Security/security/xss/views.py
fangyiyu/CS50_web_programming
8d6f304772ae8bd8cd373f17545d507c6e55768e
[ "MIT" ]
2
2021-04-05T15:29:08.000Z
2022-03-08T11:07:21.000Z
Lecture 8 : Scalability and Security/src8/security/xss/views.py
Sumanth-Talluri/CS50-Web-Programming-with-Python-and-JavaScript
8d5f83f4354f1f27138a2a9c40317d358f3b2f9a
[ "MIT" ]
null
null
null
Lecture 8 : Scalability and Security/src8/security/xss/views.py
Sumanth-Talluri/CS50-Web-Programming-with-Python-and-JavaScript
8d5f83f4354f1f27138a2a9c40317d358f3b2f9a
[ "MIT" ]
null
null
null
from django.shortcuts import HttpResponse, render # Create your views here. def index(request, path): return HttpResponse(f"Requested Path: {path}")
25.666667
50
0.75974
20
154
5.85
0.85
0
0
0
0
0
0
0
0
0
0
0
0.142857
154
5
51
30.8
0.886364
0.149351
0
0
0
0
0.170543
0
0
0
0
0
0
1
0.333333
false
0
0.333333
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
1
1
1
0
0
6
a66fe52c8e7fb866a303fd8d8eff87cd588894fa
163
py
Python
geneblocks/DiffBlocks/__init__.py
Edinburgh-Genome-Foundry/Geneblocks
87a8df33fab2295e357884fa2742d3e03e98d9a5
[ "MIT" ]
26
2018-02-12T13:14:14.000Z
2021-08-06T16:51:46.000Z
geneblocks/DiffBlocks/__init__.py
Edinburgh-Genome-Foundry/Geneblocks
87a8df33fab2295e357884fa2742d3e03e98d9a5
[ "MIT" ]
6
2020-05-20T20:26:08.000Z
2022-02-15T11:39:35.000Z
geneblocks/DiffBlocks/__init__.py
Edinburgh-Genome-Foundry/Geneblocks
87a8df33fab2295e357884fa2742d3e03e98d9a5
[ "MIT" ]
3
2019-11-04T23:00:17.000Z
2021-10-06T23:45:25.000Z
from .DiffBlocks import DiffBlocks, DiffBlock from .DiffRecordTranslator import DiffRecordTranslator __all__ = ['DiffBlocks', 'DiffBlock', 'DiffRecordTranslator']
40.75
61
0.828221
13
163
10.076923
0.461538
0.290076
0
0
0
0
0
0
0
0
0
0
0.08589
163
4
61
40.75
0.879195
0
0
0
0
0
0.237805
0
0
0
0
0
0
1
0
false
0
0.666667
0
0.666667
0
1
0
1
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
0
0
1
0
1
0
0
6
a67781273c77691913764977aa04f24ea1da6fb0
32
py
Python
clash-of-code/shortest/mens_wifes_kids.py
jonasnic/codingame
f1a7fe8007b9ca63bdf30cd72f4d6ac41a5ac721
[ "MIT" ]
30
2016-04-30T01:56:05.000Z
2022-03-09T22:19:12.000Z
clash-of-code/shortest/mens_wifes_kids.py
jonasnic/codingame
f1a7fe8007b9ca63bdf30cd72f4d6ac41a5ac721
[ "MIT" ]
1
2021-05-19T19:36:45.000Z
2021-05-19T19:36:45.000Z
clash-of-code/shortest/mens_wifes_kids.py
jonasnic/codingame
f1a7fe8007b9ca63bdf30cd72f4d6ac41a5ac721
[ "MIT" ]
17
2020-01-28T13:54:06.000Z
2022-03-26T09:49:27.000Z
x=int(input()) print(x+x*x+x**3)
16
17
0.59375
9
32
2.111111
0.555556
0.315789
0.315789
0
0
0
0
0
0
0
0
0.032258
0.03125
32
2
17
16
0.580645
0
0
0
0
0
0
0
0
0
0
0
0
1
0
false
0
0
0
0
0.5
1
1
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
6
a67f2918d8953fae3b2e515dd8382a32e71a5cd5
9,508
py
Python
repro_eval/test/test_path_param.py
irgroup/repro_eval
35a4cf083dbb5f4b29d6ef602a604f0686a537c9
[ "MIT" ]
8
2020-10-27T02:11:53.000Z
2022-03-02T11:00:10.000Z
repro_eval/test/test_path_param.py
irgroup/repro_eval
35a4cf083dbb5f4b29d6ef602a604f0686a537c9
[ "MIT" ]
2
2021-01-25T19:59:39.000Z
2021-12-07T09:29:01.000Z
repro_eval/test/test_path_param.py
irgroup/repro_eval
35a4cf083dbb5f4b29d6ef602a604f0686a537c9
[ "MIT" ]
1
2021-04-16T16:21:16.000Z
2021-04-16T16:21:16.000Z
import pytest from repro_eval.Evaluator import RpdEvaluator, RplEvaluator import numpy as np rpd_eval = RpdEvaluator(qrel_orig_path='./example/data/qrels/core17.txt', run_b_orig_path='./example/orig_b.txt', run_a_orig_path='./example/orig_a.txt', run_b_rep_path='./example/rpd_b.txt', run_a_rep_path='./example/rpd_a.txt') rpd_eval.trim() rpd_eval.evaluate() def test_ktu_path_param(): ktu = rpd_eval.ktau_union() assert 'baseline' in ktu.keys() assert 'advanced' in ktu.keys() _rpd_eval = RpdEvaluator(qrel_orig_path='./example/data/qrels/core17.txt', run_b_orig_path='./example/orig_b.txt', run_a_orig_path='./example/orig_a.txt') _rpd_eval.trim() _rpd_eval.evaluate() _ktu = _rpd_eval.ktau_union(run_b_path='./example/rpd_b.txt') assert 'baseline' in _ktu.keys() assert ktu.get('baseline') == _ktu.get('baseline') _ktu = _rpd_eval.ktau_union(run_b_path='./example/rpd_b.txt', run_a_path='./example/rpd_a.txt') assert 'advanced' in _ktu.keys() assert ktu.get('advanced') == _ktu.get('advanced') def test_rbo_path_param(): rbo = rpd_eval.rbo() assert 'baseline' in rbo.keys() assert 'advanced' in rbo.keys() _rpd_eval = RpdEvaluator(qrel_orig_path='./example/data/qrels/core17.txt', run_b_orig_path='./example/orig_b.txt', run_a_orig_path='./example/orig_a.txt') _rpd_eval.trim() _rpd_eval.evaluate() _rbo = _rpd_eval.rbo(run_b_path='./example/rpd_b.txt') assert 'baseline' in _rbo.keys() assert rbo.get('baseline') == _rbo.get('baseline') _rbo = _rpd_eval.rbo(run_b_path='./example/rpd_b.txt', run_a_path='./example/rpd_a.txt') assert 'advanced' in _rbo.keys() assert rbo.get('advanced') == _rbo.get('advanced') def test_rmse_path_param(): rmse = rpd_eval.rmse() assert 'baseline' in rmse.keys() assert 'advanced' in rmse.keys() _rpd_eval = RpdEvaluator(qrel_orig_path='./example/data/qrels/core17.txt', run_b_orig_path='./example/orig_b.txt', run_a_orig_path='./example/orig_a.txt') _rpd_eval.trim() _rpd_eval.evaluate() _rmse = _rpd_eval.rmse(run_b_path='./example/rpd_b.txt') assert 'baseline' in _rmse.keys() assert rmse.get('baseline') == _rmse.get('baseline') _rmse = _rpd_eval.rmse(run_b_path='./example/rpd_b.txt', run_a_path='./example/rpd_a.txt') assert 'advanced' in _rmse.keys() assert rmse.get('advanced') == _rmse.get('advanced') def test_rpd_ttest_path_param(): pval = rpd_eval.ttest() assert 'baseline' in pval.keys() assert 'advanced' in pval.keys() _rpd_eval = RpdEvaluator(qrel_orig_path='./example/data/qrels/core17.txt', run_b_orig_path='./example/orig_b.txt', run_a_orig_path='./example/orig_a.txt') _rpd_eval.trim() _rpd_eval.evaluate() _pval = _rpd_eval.ttest(run_b_path='./example/rpd_b.txt') assert 'baseline' in _pval.keys() # pick a few samples here since nan comparisons cause problems in combination with assert assert pval.get('baseline').get('ndcg') == _pval.get('baseline').get('ndcg') assert pval.get('baseline').get('P_10') == _pval.get('baseline').get('P_10') assert pval.get('baseline').get('map') == _pval.get('baseline').get('map') _pval = _rpd_eval.ttest(run_b_path='./example/rpd_b.txt', run_a_path='./example/rpd_a.txt') assert 'advanced' in _pval.keys() # pick a few samples here since nan comparisons cause problems in combination with assert assert pval.get('advanced').get('ndcg') == _pval.get('advanced').get('ndcg') assert pval.get('advanced').get('P_10') == _pval.get('advanced').get('P_10') assert pval.get('advanced').get('map') == _pval.get('advanced').get('map') def test_rpl_ttest_path_param(): rpl_eval = RplEvaluator(qrel_orig_path='./example/data/qrels/core17.txt', run_b_orig_path='./example/orig_b.txt', run_a_orig_path='./example/orig_a.txt', run_b_rep_path='./example/rpl_b.txt', run_a_rep_path='./example/rpl_a.txt', qrel_rpl_path='./example/data/qrels/core18.txt') rpl_eval.trim() rpl_eval.evaluate() pval = rpl_eval.ttest() assert 'baseline' in pval.keys() assert 'advanced' in pval.keys() _rpl_eval = RplEvaluator(qrel_orig_path='./example/data/qrels/core17.txt', run_b_orig_path='./example/orig_b.txt', run_a_orig_path='./example/orig_a.txt', qrel_rpl_path='./example/data/qrels/core18.txt') _rpl_eval.trim() _rpl_eval.evaluate() _pval = _rpl_eval.ttest(run_b_path='./example/rpl_b.txt') assert 'baseline' in _pval.keys() # pick a few samples here since nan comparisons cause problems in combination with assert assert pval.get('baseline').get('ndcg') == _pval.get('baseline').get('ndcg') assert pval.get('baseline').get('P_10') == _pval.get('baseline').get('P_10') assert pval.get('baseline').get('map') == _pval.get('baseline').get('map') _pval = _rpl_eval.ttest(run_b_path='./example/rpl_b.txt', run_a_path='./example/rpl_a.txt') assert 'advanced' in _pval.keys() # pick a few samples here since nan comparisons cause problems in combination with assert assert pval.get('advanced').get('ndcg') == _pval.get('advanced').get('ndcg') assert pval.get('advanced').get('P_10') == _pval.get('advanced').get('P_10') assert pval.get('advanced').get('map') == _pval.get('advanced').get('map') def test_rpd_er_path_param(): er = rpd_eval.er() _rpd_eval = RpdEvaluator(qrel_orig_path='./example/data/qrels/core17.txt', run_b_orig_path='./example/orig_b.txt', run_a_orig_path='./example/orig_a.txt') _rpd_eval.trim() _rpd_eval.evaluate() _er = _rpd_eval.er(run_b_path='./example/rpd_b.txt', run_a_path='./example/rpd_a.txt') # pick a few samples here since nan comparisons cause problems in combination with assert assert er.get('ndcg') == _er.get('ndcg') assert er.get('P_10') == _er.get('P_10') assert er.get('map') == _er.get('map') def test_rpl_er_path_param(): rpl_eval = RplEvaluator(qrel_orig_path='./example/data/qrels/core17.txt', run_b_orig_path='./example/orig_b.txt', run_a_orig_path='./example/orig_a.txt', run_b_rep_path='./example/rpl_b.txt', run_a_rep_path='./example/rpl_a.txt', qrel_rpl_path='./example/data/qrels/core18.txt') rpl_eval.trim() rpl_eval.evaluate() er = rpl_eval.er() _rpl_eval = RplEvaluator(qrel_orig_path='./example/data/qrels/core17.txt', run_b_orig_path='./example/orig_b.txt', run_a_orig_path='./example/orig_a.txt', qrel_rpl_path='./example/data/qrels/core18.txt') _rpl_eval.trim() _rpl_eval.evaluate() _er = _rpl_eval.er(run_b_path='./example/rpl_b.txt', run_a_path='./example/rpl_a.txt') # pick a few samples here since nan comparisons cause problems in combination with assert assert er.get('ndcg') == _er.get('ndcg') assert er.get('P_10') == _er.get('P_10') assert er.get('map') == _er.get('map') def test_rpd_dri_path_param(): dri = rpd_eval.dri() _rpd_eval = RpdEvaluator(qrel_orig_path='./example/data/qrels/core17.txt', run_b_orig_path='./example/orig_b.txt', run_a_orig_path='./example/orig_a.txt') _rpd_eval.trim() _rpd_eval.evaluate() _dri = _rpd_eval.dri(run_b_path='./example/rpd_b.txt', run_a_path='./example/rpd_a.txt') # pick a few samples here since nan comparisons cause problems in combination with assert assert dri.get('ndcg') == _dri.get('ndcg') assert dri.get('P_10') == _dri.get('P_10') assert dri.get('map') == _dri.get('map') def test_rpl_dri_path_param(): rpl_eval = RplEvaluator(qrel_orig_path='./example/data/qrels/core17.txt', run_b_orig_path='./example/orig_b.txt', run_a_orig_path='./example/orig_a.txt', run_b_rep_path='./example/rpl_b.txt', run_a_rep_path='./example/rpl_a.txt', qrel_rpl_path='./example/data/qrels/core18.txt') rpl_eval.trim() rpl_eval.evaluate() dri = rpl_eval.dri() _rpl_eval = RplEvaluator(qrel_orig_path='./example/data/qrels/core17.txt', run_b_orig_path='./example/orig_b.txt', run_a_orig_path='./example/orig_a.txt', qrel_rpl_path='./example/data/qrels/core18.txt') _rpl_eval.trim() _rpl_eval.evaluate() _dri = _rpl_eval.dri(run_b_path='./example/rpl_b.txt', run_a_path='./example/rpl_a.txt') # pick a few samples here since nan comparisons cause problems in combination with assert assert dri.get('ndcg') == _dri.get('ndcg') assert dri.get('P_10') == _dri.get('P_10') assert dri.get('map') == _dri.get('map')
42.070796
99
0.619163
1,347
9,508
4.03415
0.045286
0.153846
0.107656
0.090909
0.926757
0.911299
0.870997
0.866397
0.860876
0.860876
0
0.009547
0.22886
9,508
225
100
42.257778
0.731588
0.073938
0
0.646341
0
0
0.263984
0.066962
0
0
0
0
0.304878
1
0.054878
false
0
0.018293
0
0.073171
0
0
0
0
null
0
0
0
1
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
6
a6b2a6846ae0a40cf789c750b9c56a17601f744b
20,301
py
Python
controller/CutCaptcha.py
wudinaonao/FlaskMark12306Captcha
c03550dc5583b435192f220f871c71cabadd3e39
[ "Apache-2.0" ]
1
2020-07-21T06:41:07.000Z
2020-07-21T06:41:07.000Z
controller/CutCaptcha.py
wudinaonao/FlaskMark12306Captcha
c03550dc5583b435192f220f871c71cabadd3e39
[ "Apache-2.0" ]
6
2020-11-13T18:45:19.000Z
2022-03-12T00:22:18.000Z
controller/CutCaptcha.py
wudinaonao/FlaskMark12306Captcha
c03550dc5583b435192f220f871c71cabadd3e39
[ "Apache-2.0" ]
null
null
null
from io import BytesIO from PIL import Image from entities import ResultCutCaptcha from controller.utils import Base64 from typing import Tuple from typing import Any class CutCaptcha(object): @classmethod def _imageToBytes(cls, image: Image) -> bytes: imageIO = BytesIO() image.save(imageIO, format="PNG") return imageIO.getvalue() @classmethod def _cutLabel(cls, imageByte: bytes) -> bytes: """return Image object""" label = Image.open(BytesIO(imageByte)).convert("RGB") x = 117 y = 0 w = 180 h = 30 label = label.crop((x, y, w, h)) return cls._imageToBytes(label) @classmethod def _cutImage(cls, imageByte: bytes) -> Tuple[bytes, bytes, bytes, bytes, bytes, bytes, bytes, bytes]: """return Image object tuple""" image = Image.open(BytesIO(imageByte)).convert("RGB") space = 67 + 5 x0, y0, w0, h0 = 0 * space + 5, 0 * space + 41, 1 * space, 0 * space + 41 + 67 x1, y1, w1, h1 = 0 * space + 5, 1 * space + 41, 1 * space, 1 * space + 41 + 67 x2, y2, w2, h2 = 1 * space + 5, 0 * space + 41, 2 * space, 0 * space + 41 + 67 x3, y3, w3, h3 = 1 * space + 5, 1 * space + 41, 2 * space, 1 * space + 41 + 67 x4, y4, w4, h4 = 2 * space + 5, 0 * space + 41, 3 * space, 0 * space + 41 + 67 x5, y5, w5, h5 = 2 * space + 5, 1 * space + 41, 3 * space, 1 * space + 41 + 67 x6, y6, w6, h6 = 3 * space + 5, 0 * space + 41, 4 * space, 0 * space + 41 + 67 x7, y7, w7, h7 = 3 * space + 5, 1 * space + 41, 4 * space, 1 * space + 41 + 67 image0 = image.crop((x0, y0, w0, h0)) image1 = image.crop((x1, y1, w1, h1)) image2 = image.crop((x2, y2, w2, h2)) image3 = image.crop((x3, y3, w3, h3)) image4 = image.crop((x4, y4, w4, h4)) image5 = image.crop((x5, y5, w5, h5)) image6 = image.crop((x6, y6, w6, h6)) image7 = image.crop((x7, y7, w7, h7)) return (cls._imageToBytes(image0), cls._imageToBytes(image1), cls._imageToBytes(image2), cls._imageToBytes(image3), cls._imageToBytes(image4), cls._imageToBytes(image5), cls._imageToBytes(image6), cls._imageToBytes(image7)) @classmethod def cut(cls, imageByte: bytes) -> ResultCutCaptcha: return ResultCutCaptcha( label=cls._cutLabel(imageByte), images=cls._cutImage(imageByte) ) if __name__ == '__main__': base64_str = "/9j/4AAQSkZJRgABAgAAAQABAAD/2wBDAAgGBgcGBQgHBwcJCQgKDBQNDAsLDBkSEw8UHRofHh0aHBwgJC4nICIsIxwcKDcpLDAxNDQ0Hyc5PTgyPC4zNDL/2wBDAQkJCQwLDBgNDRgyIRwhMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjL/wAARCAC+ASUDASIAAhEBAxEB/8QAHwAAAQUBAQEBAQEAAAAAAAAAAAECAwQFBgcICQoL/8QAtRAAAgEDAwIEAwUFBAQAAAF9AQIDAAQRBRIhMUEGE1FhByJxFDKBkaEII0KxwRVS0fAkM2JyggkKFhcYGRolJicoKSo0NTY3ODk6Q0RFRkdISUpTVFVWV1hZWmNkZWZnaGlqc3R1dnd4eXqDhIWGh4iJipKTlJWWl5iZmqKjpKWmp6ipqrKztLW2t7i5usLDxMXGx8jJytLT1NXW19jZ2uHi4+Tl5ufo6erx8vP09fb3+Pn6/8QAHwEAAwEBAQEBAQEBAQAAAAAAAAECAwQFBgcICQoL/8QAtREAAgECBAQDBAcFBAQAAQJ3AAECAxEEBSExBhJBUQdhcRMiMoEIFEKRobHBCSMzUvAVYnLRChYkNOEl8RcYGRomJygpKjU2Nzg5OkNERUZHSElKU1RVVldYWVpjZGVmZ2hpanN0dXZ3eHl6goOEhYaHiImKkpOUlZaXmJmaoqOkpaanqKmqsrO0tba3uLm6wsPExcbHyMnK0tPU1dbX2Nna4uPk5ebn6Onq8vP09fb3+Pn6/9oADAMBAAIRAxEAPwD3+ivPNS1bUJdPlW2XWIJZ550EExgZ4mwMplZDkA5IIJwGA7Vd8P63d2Wi39zqC3k32C3VmR9gYkKSQPmJyeMZxQB21FcPqV14igvb/Vfs2qWlklsh8qKS1fGzeWbDk9iOnpU+r6tqVsohtdYij2W48w3GiT3DuxGdweJ0QcEcAcEHnsADsaK4Xwrq2p3un6fBd6zHIk1oqjydGuIpQxQYbzndkyPUrg0zXZdR0fxLpVqmq65c2k9rdTTpbpC8i+W0IDAbMkASNkAEnjAoA72iuH1C6iNlpk1tr11d2lxcPula7WDpE+FLoF24YDIIyCMYzxXKXOoapB4f1W4k1PUY5LfT7qaOctcxqZlVygjJkZWA25ywGRt4OTgA9jorh/Eev3507xBFb3OnWwtN0S75mWU/u1bcMdPvcfSpdS8RahBZ6lEtxYNLHps1zHNZuWKMm0DIOR/F+lKTsrl04OpNQW7djs6K8t/te+WGCAXOvLM9zsuws0MsxHkGUeWfuKMEE+2e9Ra/4hktvDVguma1qkEt+gWOC9MJdkZjmV5D90EHAO4AYHTBrneJik3Y9eOSVZTjBSXvPz89dL9vu7Hq9FeZaHrl5LqmnaWNcvCsjeWn76yuOFUthim5uQOp596ojxbq41DUzFqFrK90lwDAWZfsQh+VW64GRljgZJFH1mNr2BZHWcnFSW1+vd+Wmz+63VHrdFcp4RvdSN5eaVfXsF6ljb25iuY1bModWO5iWOThRz711dbwlzK55mIoOhUdNu+33NXX4MQsqkAkAngZPWgkKpZiAAMkntXm97qkz63Al3eMyWc09wVOwmJtzJEMHBJKk+vJ4FbF3d6tc+GbGz1DEd1ehEvZYyEESOPmVSf4sd8dAfaqMDoJ9c023sBfSXSeQ2dhHJfBx8o6n8KvedH5HnFgse3eWbgAYzk15paEwa/DHDfNGbwotvcyMCVt0zwM/c3EnCjAwR6VvfEGC4vNMsbCO4mjgvLyKG48vhfKJy5Zuw2g0AdNFqVjPbG4ivIHhC7jIsgKgeuaNP1G11WyS8spfNt3J2SAcNg4yPavFrue4k8R3VvpuklrRrcsyJswsKDaoiJXK8lskAE9q9X8IW0tp4WsIpUmjIiGIZl2tEvQLjnGAB15oA3KKKKACiiigAooooAKKKKACiiigAooooAKKKKACiiigDkbjwfcXuo+bd3kTWv2uW4WIQI2wMuB99WDE9zgY4x3Jh03wrqMWnalaXEWnRJqE6LLEu2VPIAw4wIo1LMMjBXAznJxiuu86T/n2l/Nf/iqPOk/59pfzX/4qgDjR8NdFJKPpOiGJmuFJGlwBgj8xkEJ95PujsR1ya0zp+vxypOh0+aV7CO2nDSPGokUsSygKeDu6e1b/nSf8+0v5r/8VR50n/PtL+a//FUAc/pGl61bXekrerZC2sLJ7ctBM7M7YjAJUqB/Ae/er13pU8/izS9VVoxBaWl1A6kncWkaEqQMYx+7bPPcda0vOk/59pfzX/4qjzpP+faX81/+KoAytb0u8u5LF9ONvE0E0jyeYWXIaN1JBXndlgc1zN94M1+XTtYt7e/si2o2M1oyzKMEupAYuE38ZPUkc9K7vzpP+faX81/+Ko86T/n2l/Nf/iqAMrXPD9rqOk6jFBZ2v2q6jYeY8YyXIABJxnoBz7U3WfD0N7o99bWENra3VzbtAJvKAwrYyDjscVr+dJ/z7S/mv/xVHnSf8+0v5r/8VSaurMunN05qcd1qc6/hK3h1G2lsILa2tbeCbEUabS8zqEDHHbbu/Oq9x4SmufDGjaaWhS5tGthPKpIJSM/MFOOvJxkV1XnSf8+0v5r/APFUedJ/z7S/mv8A8VUexhqdSzDELlfNqv8Ag/5s5KHwheQeKrK9S5DWFo7OvmzF5GJQrjbtAHJPOTUOm+EdXs9Vt7ie5sJraE3m2EI2R5xyAT/EPXpjtmuz86T/AJ9pfzX/AOKo86T/AJ9pfzX/AOKqfYQ/r+vIt5piGrO21tvX8feZg+GNCvNLur+6vVsonuFhijgst3lxpGCBgsAcnca6SofOk/59pfzX/wCKo86T/n2l/Nf/AIqtIxUVZHJXrSrzdSe+n4Kxm6ppFzcXYvbCe2iuNixutzAZUdVYsvAZSCCSQffpVY+HJ7+GBdZv2uDHM0xSIbEJIKgeuACcc9Tn0rb86T/n2l/Nf/iqPOk/59pfzX/4qqMipNoWl3FqbaWxhaIuJCu3Hzjo2R3rK1/RNTvp7STTms43tARbyzNITHkYJKg4bp3/AEroPOk/59pfzX/4qjzpP+faX81/+KoA8+T4faxpT6aNG1WArb8yNdozHeT8zrg8nk4DZAya9FjQpEqM7SMAAXbGW9zjio/Ok/59pfzX/wCKo86T/n2l/Nf/AIqgCaiofOk/59pfzX/4qjzpP+faX81/+KoAmoqHzpP+faX81/8AiqPOk/59pfzX/wCKoAmoqHzpP+faX81/+Ko86T/n2l/Nf/iqAJqKh86T/n2l/Nf/AIqjzpP+faX81/8AiqAJqKh86T/n2l/Nf/iqPOk/59pfzX/4qgCaiofOk/59pfzX/wCKo86T/n2l/Nf/AIqgCaiofOk/59pfzX/4qjzpP+faX81/+KoAmoqHzpP+faX81/8AiqKAJqKo6rK0VqrIzKS4GVOOxqC2eV1+aV/xY1m6iTsBq0VgazrdvosAlvLoxKzbVGT8xPYdcmvK9S+LV1dPcRWBYRhjGTvYH2IIwVPGaPaIdj3OivnFfinrlrMu/UZHfO0xueD6D26iu+8J+PINXYW013cfbC2MMx2569fwNDmI9QorEhNxcIXhujIgOCVc9e9WN04X70n/AH1S9qh2NOiuU1K+uI2k2XEqhVxw5HNM+ImoyaZ4egniu5LVjdKu9JChI2scZB9v0ojVUr26D5dbHXUV4Qvii+kO5dbvuO32lj/I1J/wkepluNYv+ewnk/xo9o+xp7F9z3OivCf+Eh1bAUavqOR1PnSVIfE2p5A/tPUjjuJZDR7R9g9i+57lRXhr+ItWdSE1PU8+0ktZdzrfiZ7qPytU1YRg8/6RIB/OtE7iqU1DZ3PoaivFU1vV/LA/tS93Y/5+Hz/Opf7c1UKD/ad4f+27/wCNMyPZaK4H4uahe6b4UtZrC8uLWVr5FLwSsjFdkhxkHpwPyrxxfFPiP/oP6r/4GSf413YfAyrQ507HNVxKpy5Wj6hor5iXxR4i/wCg9qn/AIGSf41KvifxCf8AmPap/wCBkn+Nb/2VP+ZGX16PY+mKK+bU8R+IT/zHdT/8C5P8apa9r/if+zvNt/EGsIUYE+XeSA498HpWVXL504uV7lwxkZSSsfT9FfJOk+OPEn2uNZfEeqOd4ID3kpDDpj73vn6gV6UNU1pCM6tflWAZSLl8EEZBHPf/AArnoUPa7M0q1vZ9LntlFeOJq2rY51S+/wDAh/8AGux+Jd9dWHhy3ls7qa3kN2ql4ZChI2PxkduBTq4d05JX3FDEKUXK2x2VFfPB8S65/wBBrUf/AAKf/Gs/V/Fuu21qso1zU1wwB23cn+NZzouKuEMQpNKx9L0V8fy+OPFlzJlfEOrIOcKl7IOPf5vakh8U+MZCMeJdYAPrqEv/AMVXPzpbndGjKWx9g0V8mJ4i8TggP4r1cN6fb5f57q0bXxH4hYlf+Em1cuqlsG9kIOOf71S6sUbRwc2fUVFfNk2sa2tss/8AwmF95jA4hF5OWA5GePl7Z61ai1nXrQFT4j1C5VvmSVb2R1YdOpP+FXSnGo7JmNehOjHmaPomiiiqMTN1p9lrETz+9H8jVaKQLEWyQAMnjOKsa2pa0iAGf3o/kaybyRItKuHmICBSDvOAe3NcddtSbLirtI4fxbql1qim1vLdk0+SQNDypZMf3uDgNzgenfqBzUun2VtZOufLWQsm/cCUByBk5Oeefxpuq6jLHcJbWYaWWRvkVOh9ST2Hrmpp7d201ZLtGmc5Z3VTtJyOOoA+73Ppz1B89Ocne52uEIow9I0DT7h7trkNKomKowz8pX/IH4VD/Yd7p0r3ySG1Ai8z7PCSEjQEhVOOW3ce5znvWzBAsks0sBKI33YwuC2AuWI4wWHzeo57jm7Gtvqlt++JktiR5rMxUv2GNp6deT7dMDOqqyjqzFxi9j1TwHfLe+FrXZGUSFfKVSOcDoT9Rg10MyEqQpAJ6ZFcj8P1gtrOa1tJLiSANlBJKrqo4+7zuHGOG/DNdoR1ruXvRuc+zOUu9PkaV90W4McnnrVb4o7f+EatdxABvV6/7j11ktskg+YKfqK5H4qAN4ZtAf8An+T8PkeqoQ5WwbPJgQDhyCc8gdqVZ1b7oPY9DwDj0+tMlGZB+6GT3B6mljdwSREq47HjjpXQ7DRY819pk4Vf9oEd8elSW96SxVQXHqOMdcHvxx3/ACqrJLKUBSVBznG7pxUiZW4LG5RcgDP51Oo2W1uncBkkXoOM56/hUqeeTlm4PJxjgflWe08J/ePIG2gAkk5OPpQbkKqszhUY424IH59qEyWi+32pRuySOcgY/wAKfaO5VlOcjHU//WrPMqM2zzUGeenQe3rWlaAJC4WQOTyTjB9se1UI7T4zDPg+0/6/0/8ARcleIKte5fGJd3hG0H/T+n/ouSvFUjr6DLf4HzZ5GM/ijUSrEceSOKfHDkjirsMGe1dzdjlGwwe1XktVkQq65UjBFSwW/Tir0UQA6VzzmrWKSPNdZ8NXGn3zSQKxhblWHQV1PgzWGuHGmXxJlc4hkP8Ae/uk+/PPrXTyRwtGsM+wrMwjVWONzHoB71zF3pH2K8cSIyvG345HQj+deJVj7GfNA9OlJ1I2Z2IjKnBGCDgg9q6v4tME8K2pJx/pqf8AoD1zVvc2+qwQXFpIJHf5ZFYYYOMZJxgc8frW98ZDjwhaf9f6f+i5KdWam4smEOWMkzx17lR0NZ97OJYJEcAqwwc0jGqs43RsvqKJ7MmnFKSIIoY44/kQO4GXI9f/AK39ahS5iSWMOrLFkltnUg1d0vT5ZR5rXKwRg8E8n3qzcWWkwSFYBJcnI+djxnv6fyrx6klzan0tC8kvZxuZYyVMkatsz1IrS0u1mupQsUbO3YqDnP0FOuYIUnBjR4IGX5YwcA+/b+VauhX5sNTtZYCUKSA5KgjsM479aym/5T0adGta9hP7M1i0WC5NlOquDGGaMg9eT7YyKlilibzNsbwtkYiP8Ix/+qujm1C61azEF7JhFkdSXRV2swGP1Wqk1hbNYvNatwn3RkZ25PXFVhk1UTkYYuhWdCSZ9DUUUV3Hz5Q1aQx2qMEZzv6D6GuM8dySnw8FiBHzDcinDOPTNdrqjbbZTjPzf0NedeL72VbmGOMcLzleuenHU+h45rz8bJpWR0UFqcpEfs2i3LWohguncqjyJuQDAILEAHAJGTzwDwailW9Ok21ldTZuHZlmVgOGErquCGII2qW4479xW1BbRTaNeG8DBI5FaGI4LMCNvzYxjPXaOgxnOc1Vl2rITcxsCwd93TLYOO2QOQRk965oO6SNKj1uVLzV7W0tbS1mRYpJSwRYxl8biA20c7d3HXrg1V062+w6hMWk3Wd6hYruwQzLzx6Hr+lSWkUzrPOrq0cmRO6nAIUkKD7Dnj3+tR2+bi/jaQ4jXAyeAB2rWaVrGcG3qep/DzRb7SdDQX0paWQBuvXPOfc9Of8A9Z7H1qK1QR2sSAYCoBge1S5wK7Yq0UjF7iZrhPi9IY/CdqR1+3IP/Icld0CvpWD41msINGifUZZ44ftAAMPXdtbr7dauPUR88SXs0gAB6fhzUJe43DEWcdCEJz+VekPr+hW8J8u5vZWzwBIE4z3OaiPiXQzbxNLDqDSFQxRbtgFJ6jO4ZpXkNSRwMZ1Bf+WEjHHTyTzTmfU95ItZw5HQRt/Su5TxB4blLNLb36MRgFrxjnnof3lEd94NcfvYb5VPXZeOOx54k9eP88v3ti001c41RrZhCmxuXRmOVMDE/n26mpCuqNGClnd7x95RA5ArbWPS7qdktrfUnUHgDUGHb08yp20e2lgdoY7qFFyWkk1Bjs4z0+bP5+tElZXudLw8VG/Mjn4k1did1ld475genyXl/a2rboXgGNokmBUL+Y/SuotPDVlJZQTiSd1mXzPmkJ69O/8Anmqmp+EIZLctbPiRfmAdQ4P1BBrH21nZnM4HffF1d3hS1H/T8n/oElePRwZ7V7P8U03+GbUf9Pqf+gPXlkNv7V9Rl7tQ+Z4mM/ikMNv04rQit8dqmit8DpVuOLHat5TMEhkcWB0qykdNd4oInllcJGoyzHsK5fVPFzM/k6apGTjzD3+lcdWvGJvTpOR0184hspHMhiZBuVh1DDkfrUdt4oik2m7Me5R8xcgZJ788etcGb67upvndncn1JrrdD8PfaIhPqVsBGFBQNncx9cCvOqN1JXR20l7NanTrfXTeQ0C+aqAloY12HOcgqGIAGARg469eDnV+M5x4PtP+v9P/AEXJWLeabbX9m1pPGDERjC9V7Aj09K2fjSceDrT/ALCCf+i5KTpuE0V7SM4O254Wx4qCQ8GpSeKhfoa3exgnZl6ys1nhbDDzgw2xuQFOffI/mKskW6zvuwEEYzlRu3YzyCRk7mxjpgHris2BxjMhZY/vNjnAHfFKZ91jcPApAeJgC7bduCO+ec4IHXJ7YNeVUjeR9bQqqFJXfTYsO5unjO/auVXrwMsF4/E4x71ZFokHzSMz7UMrJvwwUZyQcEchSRn0NJp1vcXxuILO3JnXbiQZjzHlcsM7gDyec5G0cA1pJMYSkWBJLHboLkhiWLqwZd29B0wQDnJ4545zUUtzarjZKSjSWljcitHu0v4bCOSVhJ5gjVfmZd7AHHYfXn2AwTQg0+XCb3jXfn5c5PH04/Wr+m3pt4BGQ6RJaqq7CFZdpXL9Qc/KRnin299/bKz2935pu9/mQyhDvkIAyhAPzccjPTkUk1e6Lo4qsqTpzej8j3uiiiuw+XKGrMFtFyergdcZ4NeTeP7qSz1TTokMZMwIVWY7i25eSPQAHn6V61qrbbZDz/rB0+hrzH4kabLJpttqyoJPsLqyxAgE88kE+2fb8q48RFNmtN2KNq1taWtxbzMNnyK9xISYwfm+9g4HY5PH8PbAyjbajcyXDaf4lgvLCEqhxsmk3Y5UuR2/vZ7jIzmub0XxPqTeJ7yCLTcW8sZZoWzkqD6nv/8Aq9auTarotujXV34fQ3DklSgDLnPBzjOB8v5+1c8YcrszSd2bd4gjhNksit5mWkEbD0xjHUHAJx6nPpUFhEmta5a6DbuuJGHmyKu4KiHJGR3IHFcXbajq3iTUhHpsItleX5QnDBmyAB3zggDHfmvcfhn4RPhXSrn7Vsa7mncMQmMKrFRyeSG27h/vVoqV3dkSlZWR6CpAAHHTp6UMyjjIqs0w6ZqJ/mOc103Mi716EVznjyKKbRLcSrCyi6Q4ltjOD8rdh0Pv/jWorMOjGsD4m6la6X4etJ7uSRIzeoo2LnJ2OcH2wDVw6lwipSSlsecXs+mx6lHbSnSLdeGmxahHibGQpXcOoPb8q07e3X7JNLd2NnbKq7j/AKCeg5JLE4HHf071iTeM/DNxIJpixdQFLmNh+mOewqa68e6BdWkkAvCjOQNxif5cHPPHTjGPejlVzrVCioyu0zRl1WyaCOK2uND4jwcwFZPwAJz9fr7Z2IJLW4CWiX+nJtwEkNgQM5PXDAAVwi+IvD2TnUogCO1u3P8A47UyeKtDQjbq/fAAicZ/8dqko3vqcLXRI2dSsdPvfE/2eSa1NtFEZPtttYuVZyfuEqXycZPX8Km+xXBVo0Ejw5I5cqGHP8Pp9aXTLn/hIbF7uynNxBG+x2EPO7APQcnrVmMSPIyC8wy9QV5H4Z4/GoquMdhxu9yhb2lxbosFuNsUfCxpIRx6AU2aC+eBmSd+OTmQ9PTFahtJAR/pByOQduKje1YKf3/bHCispVIjsdj8R08zw9bj/p7U/wDjj15zFBjtXpvjxd2hwD/p5X/0Fq4FY6+gwkrUTycVG9QjSOpAYUeJJpkhWRwgkk4UE9AT2z0HuQOpAqZUp4SrlJszirHD+MtQgkZYbfUIhbnGXRw3mcnOMZyBhh0J9Qfk3y+HvDImgiuJWzE43lioBYEAgr6jkj04yOtdbHpOnpL5yWFqsuzy94hUNtxjbnHTAAx6VfCcVyewu7yZ0+2srJFS30uxtJRJbWqxspyAOx/n+fNXQp79qcF6VIq8Vqko7ENtjVTirHxqOPBtn/2EE/8ARclMC0742f8AIm2f/YQT/wBFyVhVd5RNafwSPCN1Rueadmo2qyCSBwuCw3AdQSP68VKXwMKCAp3BQTgEc8dhyAeOOlLp1q93KUSOSRgchUwv45PQe9dCmkSWgRpZo4AeSttywAHdz938yDXmV7qVj6jB4ijGjGc91oJobSWOka2STBcNAGjJX5mAzkgHnHIGRXNPfeRcFA6O2CcgghW64rtkudA0O6QQNE1wVOZZC0hBxzjAI5BPIFVNRv8AwlqFy8s+lzXDbRmW3Xyv68n64rG0UtSamLcqrlSWjILPVZr3y4mkzM4OAMqwLE8Y4Hf0rd0KJxqNjew6ip+zTPLM0bhjsIXfuGCQRgjnqW471l6LYeFnha5e8ubaKF1CpJIJHOc8gBcj/PNXLvxUfD93c2GltALdJiS0EB+bHAJ3cN+HFZRqQ5tB1KlWa5bH0PRRRXeeOUdVZUtVdiAFcHJOMcGuE1rVotQdLS1RpWwyquMBgByR68Bvyrv7+zN7CsYk8va+7O3PYj+tZsXhuGEsY3jXfw22EDd9ea5a1OUpXRpBpbngltpsF5rFpG42NPIsCuAcqGbaOARnGcgdQcVf1DTE8NyzabLIryqu1d2CuxsHcDgZx0zgcg45Ga9Li+GUEeoQ3h1Is8U6zAGDqQwP97261v3nha11Eob1be5MeSnnW6vtJ9M9Og/Ks/Yz7F+0R5h8OLK0s9Re4VAJQmYFUcDPDMeOvH4cj0r0SbVJIQPkD4/2u1X4vD6wxJFHMqJGuxFWLAVewAzwKqv4U3sT9txn/pl/9eqdOp2ITiZ//CRruI+yuW9smlHiKMu2+N1UdO5/LrVpvB7kkjUihzkFYACP1oHhCQk79RVgT2t8E/X5v5YoVOqO8RYtZtZCF80BiM4b5T+VXPFSW76ZEtzdJboZhhnl2Ana3Gf89Kp/8IcvP+m8egix/wCzVp6/ocWv2CWkzqqrIJAWjDjOCOh+tbUlKN7kSt0ODurXwp/qdQ1LQ2yMmO5vFOfqCar/ANk/D+Qff8In2F0n9Grf/wCFaWgQgXMGSDgmzXj070+P4cWqA7riB+uP9EA/k1a80hadznP7A8CNkqPCjE8/8fY/+Kph0PwgpPlweDpRg4BvBnP47v5V1sfgG0jUL5sPU/8ALv2/FquW3g6zt+hjP/bED+tK8gsjiItL0pLZYYF8MQRCQuy210uCeMfweg/pXOubhL+eGF4ZURzh0Y7SPY4wcY7fXvXrZ8JWpuJJd8eH/h8kcfrUy+GbdANrJuHcxA/1rOpTc9xppHkhW/C5IXH+y5/wqlc6ldwR58m4f/rmrGvaf+EdTBHnjrx+7/8Ar1PFoqxReWJs++z/AOvWSwq6jczO8bjOjQ/9fC/+gtXDKlema1pX9sWaW/neTtkD7tu7PBGOo9axB4I/6iP/AJB/+yr16NaMYWbOCtSnKd0jkgtPC11f/CFf9RD/AMg//ZUv/CF/9RD/AMg//ZVp7en3I9hPscuFAFPrp/8AhDf+n/8A8g//AGVL/wAId/0//wDkH/7Kl7aHcfsZ9jmRTxXSf8Ih/wBP3/kH/wCypf8AhEf+n7/yF/8AZUvbQ7j9lPsc4KPjb/yJln/2EE/9FyV0v/CJ/wDT7/5C/wDr0njbwn/wmOiw6d9t+yeXcLP5nleZnCsuMZH97r7VlOpFyTRrCnJRaZ8w5prHg17H/wAKJ/6mP/yR/wDtlIfgRn/mZP8AyR/+2VTqxJVOXY8WLCOUN6elXbPUr12CG52IcZPlqeK9ZPwEU5z4kzxx/oPT/wAiVPa/AqO3lVm18SKOqmyxn/yJXFW953R6GHcIwtPc8Yl82e5l23Esg5IO4jj6VX8pnfD/ADEDqxr24fApVIMfiLaw7/Ys8f8Afyo3+AqmbzE8Rlc9QbLOT9fMrldOd9j1KWJw0ev4M800COOSaeBtuWiBRTyCwIP8gT+Famr2v2gxXzlB5sKq4jBAUqAhHX/ZB/GvQLX4JNayB08RnO3bxZYyCCD/AMtO4NXpPhEWhEA10iEEkI1rkAkDJ+/7Co9jVN1jMMpcyl+D/wAj02iiiu8+eK18WWFSrlfm6g47GqJuCAf37H/gRqfWJDFYGQbjtOSq9W4PFYum3sGp2EFzEhCuPmU5OD05P4UNpblKLauTzXNwrhY53Y/7xqC01W5ZvvuxBIwW644rCsvELza3fWp2JBl4YOMtvQ4Jznv8x9sCqtzLaaKhvr/UFihh5JY7c46D8a+fzT6xiuSOGb0ZvhJUpKXMdf4m8Tx+GfDraxcWs80SFVZYyAVycAkk8DOB+Irze38YeMtS1K31GS2NpZNk/Y/NCnYd2CctnOQOw4z0rk9X+KTeIfEUMd5JJaaHp8nmJF5ZLzOOAzDPBGcgdu9UrPX7/wAQNcJZM6iCPZGs8hPnHp2BIJzk4PPtyR7lGVeMY04xvK2rZmue7jTjds9W0vx3e30zpPbTWxUBwTIHjZfQSKSpPU8GoPEmqeLdaEMHheV4WHMh8zGfTB9K8VS71/w9FcAP5iEOoV4vmTAB3A8kDJ/EA+4Ptfwa1+PU/C8i3WoQ3GotO25ANpVQBhegz3Pfqa6XUlRd6sLC55QlacUdlpsOvHTrVLyaEXSoBOQ5Pzd66GuK1291/Tre4n0WSGYx4dbOeIszgEllVt4PPb0wcZBGO1rgw2NpYvmdN3s9QqQlGzfUKKKK6jMKKKKACiiigAooooAQnFG6hulNoAdmj8apTahFESFBkYf3e1c/qvi8WDhFSPze8Y+c/nkAfr9KAOuorzu18d6ndXiR+RYwIf4pi4z7ZHAP1rWj8bQKs5uIVHlAZENwrn82Cg/8ALH2FAHXUVj6f4k0rVHCWl9G0m7b5b5RicdgQCfwrWDfSgB1FN3U6gAqGe5htk3zSpGnYswANF1N9ntZZQASilsE4zj37V5DF40tNb8641CSa3uYSRLbSROzQt/cCqCc8enPXvVRVwPSJfFOnqQI/Olz3RcY/wC+sVNZ6pJey7Whkth1BYg5/wAPyrkYdOuJkDpbXADf89Ld0PtnIH8qZe61Lo7K13q9nZoDtIvmUbj6ZYg5FXyx6E6nW3es3Np5jCxMkMZwZGmUE/gBUEXiiNs+ZbSKO2xg39BXK6fra69I0VpqE+oRs2CbeF3hQ+hdFKj8Tmr2qxrodg15fRTFQwVVQKd5J7fNwAMkk9h+FCUeoanaWd9b3yFoJQ4HUdx9as15lpGoavfeIbRrG1e1sky00sgOJ128BScbgc5yBgbcZycV6WpJPOfxrOSsUOooopAZPiKf7NpZlxna449eDXmd38QtL8JQpFcGSUfNtWJOQTk9yP8AJrv/ABtbG48OSMN2IG85gpIyFUnnHb/Jrww6Np/xCuzYLJJDdWDN511EvmRNGfunOQAxPG32zxg45cRhacmsRUm0odOh0UJ6OFr3OAg8VanaTrcw3su55WkZNwGMn29j/Oq91rNzf+TFc3Mrxrl3Z2Jy+OnJ+n516J4q+G3hnSfKurTVLmzcylvs8w3Ky5GdpwCuF3H5s9uh609fOn6laWOm3qmF1hBSbaQySHrkE8jAX6/hUUMzpTinRWj8jCrP2D5bHm9vHLLmTd8oIB55zg//AKq9R0v4fa9caEl7aPaRiaESeWJD5xUKMKAFIDH69xnHIrW+GnwtuLbz9Y1qGCWIgLZREh1kBz+8K46Yxtye5OOlerWNo5ugynao4ZmOOK58fmuJw9aFLCQu3u3+h6OHqQjDmvY8l05LjWPBXlwyKbjgYfABI4x0PBXC/ia85tLzUPC2uPLa+ZayK6+dbjGAuQflJz+B9D1Pfutf8MXsuraytvPex28t408TxJJLbujbmBBTdnA49s1i32ha2uuxz6iy3dlCVtxctKpxGWCqdudw5Yds19DiJxqQSk1f1Co6VW0JNWf3nqXh7x5FrEFu16RE5XDSTKUzxnnsT78Z9K9er5n+F+gDxHq9zbXsKtp2nMJHkB2uHyQEBBzhsHPX5QRwWFfTFeNhsBTwtWpKH2rfhf8AzOGopRfI3dLYKKKK7TMKKKKACiikPTigBaKozajDFIYlZ5phx5UK7iD74+79W4qxbXEdzEJI3DA56exIP5EEfgaAJW6Vl3d00zvDEcIvDMO9aNw4it5JCM7VJrmg8tvEML5mF3FAQGJwTgZ4z9aQ0Tsyx4LDC45J4ArCuPDEN5NJPbXobzGLFeG5+ua1jforYDlHLbQD8u44zx2PHPFTJqiBvnH0xQOxiw+DIgVM92Sn8QRcH881q23hjS7faTbCVl/ilOc/0rTjvoHwQBn6VMJlI+UCgCvDpltApEVtFEO4RAKtxgwKAGyvoe1MNwg+8QPeoZbnKMUBPuO5pgaX06U+qtpNJPbRySxGKRlBZCc7TirJoJM/Wri1stNmvr2dILa3UySSSDIAHtnk9gO+cV5nYPp3iNor17MCKZd1uZI1MkUbfMApOSvB/hIzzya7TxppUniXQrzQzKYIrhVzOgyVZWDKcdxlRkdxkcda8RttM+IngGZYI9LXUrBWbYyI08PGCWyhV0HUYbA6nFXETPb7ewe2tRHa30sceOPMklkb9XNcN4l8EaJq2rvf6rH9uuXwGkLyLwOgxnpWZZ/GGSWACTw1K4Th3tr0Oob2Hl/+zfjWdqfxZ0kuCunakhHVWWPA/HfVLcR6R4Q8N6RpcJg0qH7GGO6TyXcM31O45/EV1j6bbj9+6l5lH+tPDY9yOTXh+lfGiO3kxbeH55v9trsRj8Rsb+ddCfGnj7xFbr/ZOlW1pBOwEU8UZuCh925UfUrSluBp+KvETeGYBqFuIfNWVFSNjgOGYbhwQT8pY57YJ6A132jalDrGk2uoW+fJuIxIoPbPb6g5H4V4/p3wl1/XtRGo+L9VkVMZaJZPMlI3MdgPKxr3AG7gnhTXslhaQWNrDbWqbIIo1jjTJwqgAADPtUyaY0i3RRRUjOc8cq8vhW5to3WN7grCHfopY4yfb3wcVR8HaFoWh6C66W9vM0x8y7uEbeZHxznrgD+7xj6kk6Xi2eKDTbdpk3objBT+98j/AMsZ/CvnbXfCF9PqAudKMN2c5JZwpXHch8DBA6fzpT+Gz2M3JqWhs/ELWtP1PxUogmtbmC2t5Q8YcFS5HQ7T7CuStNPGt6zdTLqIhuradI4iGYMMMQCGzxjGc8+tXT4SmtraMx3djbSRhm8qV2ZQSQcZCnI4I59veqVh4ThsXMp8VpDORjdYp5rDnsdyn8hXEqWr5XbsL2cqsr3O38QeK9Qs7E22pXllfxW6nIkuHSSZwR8pCbNx56gbRjk5rn4/Gv8AaVlc2tlo1xcXJRlCNMxWMnIDKpLE9hWWvhvw7bH7RdalqN1IDlyq+ST/AN9K386uWdr4einF1aWt1JMhzmac8Z46oUP6VpGhCMk6upSpqEv3iuijZ6v4ovFm04LLBKAHRNrY69R19/QdfxyJ9W1WGR4pnuVHlCQRXC4bcCDkDA6EZr03+07GKKG6gsrcSKmxwBv2gZ4IbPqfzNXI/GenO8T3CKt1GMLKoAKj2xUOrTo1fdjdEJxjU5kdH8FtPhi+GltLEx8y8mlllBbowYx/yQfrXq1eJ+GPHUFhqrDUZDPaufluyS7IOBg44xxXr2qatZaNbLc30rRws4TcI2fkgnooJ7V0wmp3kbc/NqXqKq2V/bahAs9pOk0Z7qf5+n0NSzSpEmZHCg+p6+wrQCWormeO2geaV1SNBlmboKonUJJziyiZxnHmtwo5wTj25yDjpSPp0t3t+13TZVlcJGBhSO3I5HocA8UAUn8S/aE3abbmaM8LcStsjP0zyeeMHFN+y6nqP/H1O4iJGUA8tcdCMfePQnB454JrZtrG1tZMwwqrckHqQCckDPQZ7VaxQBl2mi20ERjdRKrAbkK4Q8YxjuPrnrWlgde/rTsUUAZuuzCHTTzjewXOcY6n+lcRf+KrbSWmW9sJFjjPl71Yb3fAYD6d8/T1rtPEEIuLBIzjBlHBxg8H1rmNT02z1G3eO/jSRSwQh2OT83GWwGHJHHHf8QZUtvEWk6rG/wBgvY5WwQYJBsfHHY/XHfnvVRJY5JUkiBj2AoI1Yqo74IBxn+VZVv4dtNDjvpbR5HE0aKH+VnXnPykYwGB9z8ue9UNMunGptEzht5KsSMZwOuOPTHT+dS3rYuy5bnYWq3PmFjfT4/ugJgf+O5/Wtm1acMGa6kYD+E7cH8hWRZMe3StWJsGmSSXc32WDzkt5Jy0iKQA0gQEgFsZ5x14/TrV2GZppI44lIydpeQfP2ycdv0PHIqIEbe2T0zUlrL/xMYUVHY4L9OAMY6/jQBtqABgVJTPXNPpkjJYo5V2yRo49GUGsO1c/ZUZj/ACSfYVvHpXLz+Td2V1amTy0yVVuxUEYxyMjPB5H1q4CZbubaC9UR3VvFcIONsqBh+R6dapJ4V8OE5Ph/Sc56/Yo/wDCnafHND5qy5KhsRu7N5jD/byBz9D0xwOa1Y0PlNKd21BkhFLHjngDk/gD9Kp6EoksLCysl22lnb2646QxKn8hVuaWOGPdJIqL3ZjjFZ2m38d7b2s6LKiTpuUSrhh9cZH4gkHqDgip9SgmuLNkgZQ/cMu4MMEEYyOoNQ9Rongniu7fzIZFdG6EVOOKwLWe2trSW30wRrKZXZ4y2SGDYcBQc9iBjjit5Dnnmk1YodRRRSA434lxNL4bt9shRku1YEd8I/FeZ26z30JSMs5YkbUOSPbH+c16r4/hln8NlYfM3+YSPLj3t/q36D+ftkDBII8psbTUdF1Br1Uu1YWwc2xDuJDuwWdgpAIznCjd97jH3oe5SWhyWofaIJrq2lQKyAgqcg5+lc5HG8cwnQ4ZTwT1HevTdR0eG91b7XFMkckif6sqzFjnnjHuOfzx3zYvCatF5f205J5CJ0xxzuKjt61ilNTutjKMpKWhzc2u3upacbNxHDbFiWEald/HfPPb6VnxwPGcRsVwOx4rrBomnLerbmVmBYJuBBXcfXBJ6g9CaszaDZx3iWrxpM7MBhXOBuI55UE43Dv3rZy5tGypSlI5EXrIvlm4BKHOAuf16VLAPPPzuwOM7SP51qat4ftUuI5YLiURzxKwgNvsxlc/fDk5rpdG0SwvtOjcCSOZQoyyoxYk4x90e1ZuCXUh05HDpYyGV3RfvAZLNgH8q+p9dt0ubBY3AI8wHn6GvnbUrlbbV5NPt4kEaJGVl3PuOVB5+bHf07V9Jagkj26iKJpG3jgY4GDzyRV00uhUYuO5zVhYHT5jJaExueCVGc/h3rct9OWVfNvP3rtk7WOQAR0I7jnp0oispyQGKovU85bNaSqFAAHAGBWhQKMY+nFOxRRQAUUUUAFFFFAGbrhddP3ojOEcMwXqBg1yz3ryEBZVJUY6Zzz+Y7//AF67pulY+oeH7O+y6ZglP8UY4P1H+TSHc4PW4EuLdtgYtuzgyhccEcd+/wBayLG08m5eaQqZXySVBAySSev1/Wuq1Hwxq6Ei32XI6ZjYAj6hjx+Ga5eVpdPnRbyJ7Utkqs0bJux1Iz/SlbW4XOmsBxWmmMmsLSrp7lxFaRNcu3aNSVH1PYfiK6a10W9lYPcyLAvdVIZvoew+vNOw7jUl6LyWPAA5JrX020khLyTqFdugB5A96ms7C3sx+6Q7iMF25Y/j+FWqYmFPplPoEIa5NoQs7wSZKpIwKdiueM/nu/EeldYelY2sWbj/AEqCNnbP7xFGSeOoHftVQdnqBViYbwq52KAFySTj6nrWtakC2fPHzY647CsU+bbSEzxOnOM8YORnr/hU8t7ZyWht5UklDHOERmH48cj26HoeKueq0IjuXLVfItLQMJtyYQid98gJOPmPc+/etHHyiuetmtkUG2jESh0Z9wCZCnPCgbc+/wCfStkTvKo8uJ+ecn6/l+tZpWKZHdW0UhMvKuF2qVcjHpxV2NQqADsAM1BHHI0xMuzYB8uOpPr7VaobBXCiiikMqX9kb4W6+aY1jl3sBn5xtYYyCMckHPtVG48PQzLhHCHcWJKbicjpya2aKVkO72ONuvAKXLlhqAQmMJ/qM9Cxz97/AGv0qGL4d+VZrbjVM7c/N9n7ZJ/ve9dxRS5UF2eYr8IFW6M39t/8tfNVfsnQ7s/3/r+dW5fhe0upLef21jCBdn2XqQQc53+wr0OijkiF2edXvwrF5JCw1gIIxtA+y5yMtx9/0IH4Vb0v4cLp1rBCdU83yixz9n25y6sP4j024/Gu6oo5Ij5meW6l8G1v9TW9TXPKIjSMr9k3Z2987xXqVFFNRS2E3cKKKKYgooooAKKKKACiiigAIzSYpaKAG7ar3mm2eoQiK8tYbiMHIWVAwB9RnoeTzVqigCpZaZZ6bCIbO3jgj64RcZNWSvHB/SnUUARqjBmLOCCeBjpT9vvS0UAJt96WiigAoxRRQAU1oo3+8it9RmnUUAIEVRgKAPQCloooAKKKKACiiigDAJAbAJEbG+kNExooHYEOH78A/9kKCg==" result = CutCaptcha.cut(Base64.convertToBytes(base64_str)) print(result)
285.929577
17,631
0.906753
996
20,301
18.457831
0.683735
0.006092
0.003481
0.00544
0.027633
0.01262
0.008812
0.006636
0.006636
0.006636
0
0.154918
0.041968
20,301
70
17,632
290.014286
0.790323
0.002217
0
0.067797
0
0.016949
0.870783
0.869943
0
1
0
0
0
1
0.067797
false
0
0.101695
0.016949
0.254237
0.016949
0
0
1
null
0
0
0
0
0
0
0
0
0
0
0
0
0
0
1
1
0
0
0
0
0
0
1
1
null
1
0
0
0
0
0
0
0
0
0
0
0
0
6
5b60d5bfcd3dfd26a7686efecee6577269dc8e42
159
py
Python
news/admin.py
ArRosid/djangorestframework-newsapi
2abf69fe2e7e91b3b0434c1e1f5f2e921da9802f
[ "MIT" ]
null
null
null
news/admin.py
ArRosid/djangorestframework-newsapi
2abf69fe2e7e91b3b0434c1e1f5f2e921da9802f
[ "MIT" ]
6
2020-06-05T22:39:47.000Z
2022-02-10T08:22:14.000Z
news/admin.py
ArRosid/djangorestframework-newsapi
2abf69fe2e7e91b3b0434c1e1f5f2e921da9802f
[ "MIT" ]
1
2022-02-19T20:44:21.000Z
2022-02-19T20:44:21.000Z
from django.contrib import admin from . import models admin.site.register(models.Article) admin.site.register(models.Journalist) # Register your models here.
22.714286
38
0.811321
22
159
5.863636
0.545455
0.139535
0.263566
0.356589
0
0
0
0
0
0
0
0
0.100629
159
6
39
26.5
0.902098
0.163522
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
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
6
5b77158ebdcf10a010ded8ad1303ed94f607cc96
5,959
py
Python
API/main.py
BigDataArchitecture/Assignment-3-4
f4c87dadf443273ed532a8f9ea3c364b9fda75eb
[ "MIT" ]
null
null
null
API/main.py
BigDataArchitecture/Assignment-3-4
f4c87dadf443273ed532a8f9ea3c364b9fda75eb
[ "MIT" ]
null
null
null
API/main.py
BigDataArchitecture/Assignment-3-4
f4c87dadf443273ed532a8f9ea3c364b9fda75eb
[ "MIT" ]
null
null
null
from typing import Optional import uvicorn from fastapi import FastAPI, File,HTTPException from pydantic import BaseModel import tensorflow as tf import input_main # from Functions import make_gif import os import h5py import io from fastapi.responses import FileResponse from starlette.responses import StreamingResponse import numpy as np import glob from PIL import Image from matplotlib import pyplot as plt import json app = FastAPI() @app.get("/") def welcome(): return FileResponse('/Users/parthshah/Downloads/international-Container-Cargo-ship-in-the-ocean.jpg') # Api root or home endpoint @app.get('/nowcast_results/backtest/') def nowcast_backtest_function(begin_location,begin_yearmonth:int,begin_day:int,begin_time:int,model: Optional[str] = None,index: Optional[str] = None): output = {} if model== "": model = "gan_generator" if index == "": index = 24 output['Model'] = model output['Index'] = index print("model",model) try: path,describe,y_pred = input_main.input(begin_location,begin_yearmonth,begin_day,begin_time,model,int(index)) if path == 1: raise HTTPException(status_code=404, detail="Event not found") else: for i in range(12): output[i] = y_pred[:,:,:,i].tolist() return output # return {"Model": model, "Index":index,"Main":path, "Y Preds":"/Prediction/Array/Y_Pred.h5","Y Preds Analyse Image":"/Prediction/Image/Prediction.png","describe":describe} except IndexError as error: print(error) raise HTTPException(status_code=404, detail=str(error)) except UnboundLocalError as error: raise HTTPException(status_code=406, detail="No such Model Please select any of following ['gan_generator','mse_and_style','style','mse_file']") @app.get('/nowcast_results/forecast/') def nowcast_forecast_function(begin_location,begin_yearmonth:int,begin_day:int,begin_time:int,model: Optional[str] = None,index: Optional[str] = None): print("index",index) if model== "": model = "gan_generator" if index == "": index = 24 output = {} try: output['Model'] = model output['Index'] = index path,describe,y_pred = input_main.input(begin_location,begin_yearmonth,begin_day,begin_time,model,int(index)) if path == 1: raise HTTPException(status_code=404, detail="Event not found") else: for i in range(12): output[i] = y_pred[:,:,:,i].tolist() return output # {"Y Pred":y_pred.shape,"Model": model, "Index":index,"Main":path, "Y Preds":"/Prediction/Array/Y_Pred.h5","Y Preds 12 Image":"/Prediction/Image/12Images/","Describe":describe} except IndexError as error: print(error) raise HTTPException(status_code=404, detail=str(error)) except UnboundLocalError as error: raise HTTPException(status_code=406, detail="No such Model Please select any of following ['gan_generator','mse_and_style','style','mse_file']") @app.get('/nowcast_results/backtest/latlong/') def nowcast_backtest_analysis_function(lat:float,lon:float,distance:int,model: Optional[str] = None,index: Optional[str] = None): output = {} if model== "": model = "gan_generator" if index == "": index = 1 output['Model'] = model output['Index'] = index try: path,describe,y_pred = input_main.input_latlong(lat,lon,distance,model,index) if path == 1: raise HTTPException(status_code=404, detail="Event not found") else: for i in range(12): output[i] = y_pred[:,:,:,i].tolist() return output # return {"Model": model, "Index":index,"Main":path, "Y Preds":"/Prediction/Array/Y_Pred.h5","Y Preds Analyse Image":"/Prediction/Image/Prediction.png","describe":describe} except IndexError as error: print(error) raise HTTPException(status_code=404, detail=str(error)) except UnboundLocalError as error: raise HTTPException(status_code=406, detail="No such Model Please select any of following ['gan_generator','mse_and_style','style','mse_file']") @app.get('/nowcast_results/forecast/latlong/') def nowcast_forecast_gif_function(lat:float,lon:float,distance:int,model: Optional[str] = None,index: Optional[str] = None): output = {} if model== "": model = "gan_generator" if index == "": index = 24 print("model",model) output['Model'] = model output['Index'] = index try: path,describe,y_pred = input_main.input_latlong(lat,lon,distance,model,index) if path == 1: raise HTTPException(status_code=404, detail="Event not found") else: for i in range(12): output[i] = y_pred[:,:,:,i].tolist() return output # return {"Model": model, "Index":index,"Main":path, "Y Preds":"/Prediction/Array/Y_Pred.h5","Y Preds 12 Image":"/Prediction/Image/12Images/","Describe":describe} except IndexError as error: print(error) output["Error"] = str(error) raise HTTPException(status_code=404, detail=str(error)) except UnboundLocalError as error: raise HTTPException(status_code=406, detail="No such Model Please select any of following ['gan_generator','mse_and_style','style','mse_file']") # @app.get('/nowcast_results/try/') # def nowcast_forecast_gif_function1(): # a = h5py.File('/Users/parthshah/Documents/Northeastern/Spring2022/BigDataAnalytics/Assignment3/API/Intermediate_Files/694474/Prediction/Array/Y_Pred.h5','r') # dict1 = {} # dict1[1] = a['Pred'][:,:,:,11] # print(type(dict1)) # str1 = str(dict1) # print(json.dumps(dict1[1].tolist())) # return dict1[1].tolist() if __name__ == '__main__': uvicorn.run("main:app", host="127.0.0.1", port=8001, reload=True)
41.964789
189
0.659003
765
5,959
5.006536
0.196078
0.019582
0.075196
0.087728
0.751958
0.736815
0.721671
0.721671
0.720888
0.720888
0
0.021886
0.202551
5,959
141
190
42.262411
0.784091
0.1903
0
0.710526
0
0.008772
0.163028
0.084425
0
0
0
0
0
1
0.04386
false
0
0.140351
0.008772
0.22807
0.061404
0
0
0
null
0
0
0
0
1
1
1
1
1
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
6
7508bc2cb094b04485ac93c65383a13a0840f001
195
py
Python
{{cookiecutter.project_name}}/{{cookiecutter.app_name}}/models/{{cookiecutter.domain_name}}.py
kristianmandrup/cookiecutter-flask-restful
2ac8b429ea35e849455d231b2fac45fe642ff10d
[ "MIT" ]
null
null
null
{{cookiecutter.project_name}}/{{cookiecutter.app_name}}/models/{{cookiecutter.domain_name}}.py
kristianmandrup/cookiecutter-flask-restful
2ac8b429ea35e849455d231b2fac45fe642ff10d
[ "MIT" ]
null
null
null
{{cookiecutter.project_name}}/{{cookiecutter.app_name}}/models/{{cookiecutter.domain_name}}.py
kristianmandrup/cookiecutter-flask-restful
2ac8b429ea35e849455d231b2fac45fe642ff10d
[ "MIT" ]
null
null
null
class {{cookiecutter.domain_name|title}}(): """Basic {{cookiecutter.domain_name|title}} model""" def __repr__(self): return "<{{cookiecutter.domain_name|title}} %s>" % self.name
32.5
68
0.661538
22
195
5.545455
0.545455
0.442623
0.540984
0.663934
0
0
0
0
0
0
0
0
0.148718
195
5
69
39
0.73494
0
0
0
0
0
0.272727
0.244755
0
0
0
0
0
0
null
null
0
0
null
null
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
1
0
0
0
0
0
0
0
0
6
75136d175ae5866c4329c9646df3ed928bff57e4
33
py
Python
snuggle/scores/__init__.py
halfak/snuggle
384818aaf8a783013b076ada3c74226f10e5dc18
[ "MIT" ]
2
2021-04-26T20:34:25.000Z
2021-11-12T11:26:57.000Z
snuggle/scores/__init__.py
halfak/snuggle
384818aaf8a783013b076ada3c74226f10e5dc18
[ "MIT" ]
null
null
null
snuggle/scores/__init__.py
halfak/snuggle
384818aaf8a783013b076ada3c74226f10e5dc18
[ "MIT" ]
null
null
null
from .stiki import STiki, NoScore
33
33
0.818182
5
33
5.4
0.8
0
0
0
0
0
0
0
0
0
0
0
0.121212
33
1
33
33
0.931034
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
1
0
0
6
f33483f3125c6e6d2ef9d0bbf29c10d835994e8b
64
py
Python
judge/__init__.py
despawnerer/judge
e7f0a8ec8346bca67f5c01fe5ac0447a75bf9a23
[ "MIT" ]
1
2016-05-18T17:05:12.000Z
2016-05-18T17:05:12.000Z
judge/__init__.py
despawnerer/judge
e7f0a8ec8346bca67f5c01fe5ac0447a75bf9a23
[ "MIT" ]
null
null
null
judge/__init__.py
despawnerer/judge
e7f0a8ec8346bca67f5c01fe5ac0447a75bf9a23
[ "MIT" ]
null
null
null
from .decide import * # noqa from .predicates import * # noqa
21.333333
33
0.6875
8
64
5.5
0.625
0.454545
0
0
0
0
0
0
0
0
0
0
0.21875
64
2
34
32
0.88
0.140625
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
1
0
0
6
f3a3e5805eff5286e6c1fd4563c3ba2c6fc770cc
130
py
Python
gcn/graph/__init__.py
icoxfog417/graph-convolution-nlp
2f15da072e401528d9faf76985d05afce336798f
[ "MIT" ]
233
2018-09-27T15:43:56.000Z
2022-02-22T16:57:50.000Z
gcn/graph/__init__.py
dubeyakshat07/graph-convolution-nlp
2f15da072e401528d9faf76985d05afce336798f
[ "MIT" ]
7
2019-12-16T21:10:24.000Z
2022-02-10T00:17:05.000Z
gcn/graph/__init__.py
dubeyakshat07/graph-convolution-nlp
2f15da072e401528d9faf76985d05afce336798f
[ "MIT" ]
40
2019-01-21T03:05:19.000Z
2021-10-05T20:15:14.000Z
from .similarity_graph import SimilarityGraph from .dependency_graph import DependencyGraph from .static_graph import StaticGraph
32.5
45
0.884615
15
130
7.466667
0.6
0.294643
0
0
0
0
0
0
0
0
0
0
0.092308
130
3
46
43.333333
0.949153
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
1
0
0
6
3437196767acddf185451a0ddfdc7aaaa76c2ee8
67
py
Python
networks/__init__.py
marsggbo/CovidNet3D
0aeca91a775f938a0e568dd88d8162473dacf3ce
[ "MIT" ]
5
2021-02-23T06:43:31.000Z
2021-07-05T15:24:05.000Z
networks/__init__.py
etherx-dev/CovidNet3D
b107d7d965cad07f1890ee492857273f3468cc01
[ "MIT" ]
1
2021-06-08T21:06:10.000Z
2021-06-08T21:06:10.000Z
networks/__init__.py
etherx-dev/CovidNet3D
b107d7d965cad07f1890ee492857273f3468cc01
[ "MIT" ]
4
2021-02-01T03:29:16.000Z
2021-08-05T09:13:37.000Z
from .build import * from .ops import * from .mobile3d_net import *
22.333333
27
0.746269
10
67
4.9
0.6
0.408163
0
0
0
0
0
0
0
0
0
0.017857
0.164179
67
3
27
22.333333
0.857143
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
1
0
0
6
34792013794787bf1b5517d6cc66a5bf031f8125
24,635
py
Python
cottonformation/res/managedblockchain.py
gitter-badger/cottonformation-project
354f1dce7ea106e209af2d5d818b6033a27c193c
[ "BSD-2-Clause" ]
null
null
null
cottonformation/res/managedblockchain.py
gitter-badger/cottonformation-project
354f1dce7ea106e209af2d5d818b6033a27c193c
[ "BSD-2-Clause" ]
null
null
null
cottonformation/res/managedblockchain.py
gitter-badger/cottonformation-project
354f1dce7ea106e209af2d5d818b6033a27c193c
[ "BSD-2-Clause" ]
null
null
null
# -*- coding: utf-8 -*- """ This module """ import attr import typing from ..core.model import ( Property, Resource, Tag, GetAtt, TypeHint, TypeCheck, ) from ..core.constant import AttrMeta #--- Property declaration --- @attr.s class NodeNodeConfiguration(Property): """ AWS Object Type = "AWS::ManagedBlockchain::Node.NodeConfiguration" Resource Document: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-managedblockchain-node-nodeconfiguration.html Property Document: - ``rp_AvailabilityZone``: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-managedblockchain-node-nodeconfiguration.html#cfn-managedblockchain-node-nodeconfiguration-availabilityzone - ``rp_InstanceType``: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-managedblockchain-node-nodeconfiguration.html#cfn-managedblockchain-node-nodeconfiguration-instancetype """ AWS_OBJECT_TYPE = "AWS::ManagedBlockchain::Node.NodeConfiguration" rp_AvailabilityZone: TypeHint.intrinsic_str = attr.ib( default=None, validator=attr.validators.instance_of(TypeCheck.intrinsic_str_type), metadata={AttrMeta.PROPERTY_NAME: "AvailabilityZone"}, ) """Doc: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-managedblockchain-node-nodeconfiguration.html#cfn-managedblockchain-node-nodeconfiguration-availabilityzone""" rp_InstanceType: TypeHint.intrinsic_str = attr.ib( default=None, validator=attr.validators.instance_of(TypeCheck.intrinsic_str_type), metadata={AttrMeta.PROPERTY_NAME: "InstanceType"}, ) """Doc: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-managedblockchain-node-nodeconfiguration.html#cfn-managedblockchain-node-nodeconfiguration-instancetype""" @attr.s class MemberNetworkFabricConfiguration(Property): """ AWS Object Type = "AWS::ManagedBlockchain::Member.NetworkFabricConfiguration" Resource Document: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-managedblockchain-member-networkfabricconfiguration.html Property Document: - ``rp_Edition``: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-managedblockchain-member-networkfabricconfiguration.html#cfn-managedblockchain-member-networkfabricconfiguration-edition """ AWS_OBJECT_TYPE = "AWS::ManagedBlockchain::Member.NetworkFabricConfiguration" rp_Edition: TypeHint.intrinsic_str = attr.ib( default=None, validator=attr.validators.instance_of(TypeCheck.intrinsic_str_type), metadata={AttrMeta.PROPERTY_NAME: "Edition"}, ) """Doc: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-managedblockchain-member-networkfabricconfiguration.html#cfn-managedblockchain-member-networkfabricconfiguration-edition""" @attr.s class MemberApprovalThresholdPolicy(Property): """ AWS Object Type = "AWS::ManagedBlockchain::Member.ApprovalThresholdPolicy" Resource Document: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-managedblockchain-member-approvalthresholdpolicy.html Property Document: - ``p_ProposalDurationInHours``: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-managedblockchain-member-approvalthresholdpolicy.html#cfn-managedblockchain-member-approvalthresholdpolicy-proposaldurationinhours - ``p_ThresholdComparator``: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-managedblockchain-member-approvalthresholdpolicy.html#cfn-managedblockchain-member-approvalthresholdpolicy-thresholdcomparator - ``p_ThresholdPercentage``: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-managedblockchain-member-approvalthresholdpolicy.html#cfn-managedblockchain-member-approvalthresholdpolicy-thresholdpercentage """ AWS_OBJECT_TYPE = "AWS::ManagedBlockchain::Member.ApprovalThresholdPolicy" p_ProposalDurationInHours: int = attr.ib( default=None, validator=attr.validators.optional(attr.validators.instance_of(int)), metadata={AttrMeta.PROPERTY_NAME: "ProposalDurationInHours"}, ) """Doc: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-managedblockchain-member-approvalthresholdpolicy.html#cfn-managedblockchain-member-approvalthresholdpolicy-proposaldurationinhours""" p_ThresholdComparator: TypeHint.intrinsic_str = attr.ib( default=None, validator=attr.validators.optional(attr.validators.instance_of(TypeCheck.intrinsic_str_type)), metadata={AttrMeta.PROPERTY_NAME: "ThresholdComparator"}, ) """Doc: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-managedblockchain-member-approvalthresholdpolicy.html#cfn-managedblockchain-member-approvalthresholdpolicy-thresholdcomparator""" p_ThresholdPercentage: int = attr.ib( default=None, validator=attr.validators.optional(attr.validators.instance_of(int)), metadata={AttrMeta.PROPERTY_NAME: "ThresholdPercentage"}, ) """Doc: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-managedblockchain-member-approvalthresholdpolicy.html#cfn-managedblockchain-member-approvalthresholdpolicy-thresholdpercentage""" @attr.s class MemberVotingPolicy(Property): """ AWS Object Type = "AWS::ManagedBlockchain::Member.VotingPolicy" Resource Document: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-managedblockchain-member-votingpolicy.html Property Document: - ``p_ApprovalThresholdPolicy``: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-managedblockchain-member-votingpolicy.html#cfn-managedblockchain-member-votingpolicy-approvalthresholdpolicy """ AWS_OBJECT_TYPE = "AWS::ManagedBlockchain::Member.VotingPolicy" p_ApprovalThresholdPolicy: typing.Union['MemberApprovalThresholdPolicy', dict] = attr.ib( default=None, converter=MemberApprovalThresholdPolicy.from_dict, validator=attr.validators.optional(attr.validators.instance_of(MemberApprovalThresholdPolicy)), metadata={AttrMeta.PROPERTY_NAME: "ApprovalThresholdPolicy"}, ) """Doc: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-managedblockchain-member-votingpolicy.html#cfn-managedblockchain-member-votingpolicy-approvalthresholdpolicy""" @attr.s class MemberMemberFabricConfiguration(Property): """ AWS Object Type = "AWS::ManagedBlockchain::Member.MemberFabricConfiguration" Resource Document: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-managedblockchain-member-memberfabricconfiguration.html Property Document: - ``rp_AdminPassword``: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-managedblockchain-member-memberfabricconfiguration.html#cfn-managedblockchain-member-memberfabricconfiguration-adminpassword - ``rp_AdminUsername``: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-managedblockchain-member-memberfabricconfiguration.html#cfn-managedblockchain-member-memberfabricconfiguration-adminusername """ AWS_OBJECT_TYPE = "AWS::ManagedBlockchain::Member.MemberFabricConfiguration" rp_AdminPassword: TypeHint.intrinsic_str = attr.ib( default=None, validator=attr.validators.instance_of(TypeCheck.intrinsic_str_type), metadata={AttrMeta.PROPERTY_NAME: "AdminPassword"}, ) """Doc: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-managedblockchain-member-memberfabricconfiguration.html#cfn-managedblockchain-member-memberfabricconfiguration-adminpassword""" rp_AdminUsername: TypeHint.intrinsic_str = attr.ib( default=None, validator=attr.validators.instance_of(TypeCheck.intrinsic_str_type), metadata={AttrMeta.PROPERTY_NAME: "AdminUsername"}, ) """Doc: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-managedblockchain-member-memberfabricconfiguration.html#cfn-managedblockchain-member-memberfabricconfiguration-adminusername""" @attr.s class MemberNetworkFrameworkConfiguration(Property): """ AWS Object Type = "AWS::ManagedBlockchain::Member.NetworkFrameworkConfiguration" Resource Document: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-managedblockchain-member-networkframeworkconfiguration.html Property Document: - ``p_NetworkFabricConfiguration``: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-managedblockchain-member-networkframeworkconfiguration.html#cfn-managedblockchain-member-networkframeworkconfiguration-networkfabricconfiguration """ AWS_OBJECT_TYPE = "AWS::ManagedBlockchain::Member.NetworkFrameworkConfiguration" p_NetworkFabricConfiguration: typing.Union['MemberNetworkFabricConfiguration', dict] = attr.ib( default=None, converter=MemberNetworkFabricConfiguration.from_dict, validator=attr.validators.optional(attr.validators.instance_of(MemberNetworkFabricConfiguration)), metadata={AttrMeta.PROPERTY_NAME: "NetworkFabricConfiguration"}, ) """Doc: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-managedblockchain-member-networkframeworkconfiguration.html#cfn-managedblockchain-member-networkframeworkconfiguration-networkfabricconfiguration""" @attr.s class MemberNetworkConfiguration(Property): """ AWS Object Type = "AWS::ManagedBlockchain::Member.NetworkConfiguration" Resource Document: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-managedblockchain-member-networkconfiguration.html Property Document: - ``rp_Framework``: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-managedblockchain-member-networkconfiguration.html#cfn-managedblockchain-member-networkconfiguration-framework - ``rp_FrameworkVersion``: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-managedblockchain-member-networkconfiguration.html#cfn-managedblockchain-member-networkconfiguration-frameworkversion - ``rp_Name``: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-managedblockchain-member-networkconfiguration.html#cfn-managedblockchain-member-networkconfiguration-name - ``rp_VotingPolicy``: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-managedblockchain-member-networkconfiguration.html#cfn-managedblockchain-member-networkconfiguration-votingpolicy - ``p_Description``: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-managedblockchain-member-networkconfiguration.html#cfn-managedblockchain-member-networkconfiguration-description - ``p_NetworkFrameworkConfiguration``: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-managedblockchain-member-networkconfiguration.html#cfn-managedblockchain-member-networkconfiguration-networkframeworkconfiguration """ AWS_OBJECT_TYPE = "AWS::ManagedBlockchain::Member.NetworkConfiguration" rp_Framework: TypeHint.intrinsic_str = attr.ib( default=None, validator=attr.validators.instance_of(TypeCheck.intrinsic_str_type), metadata={AttrMeta.PROPERTY_NAME: "Framework"}, ) """Doc: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-managedblockchain-member-networkconfiguration.html#cfn-managedblockchain-member-networkconfiguration-framework""" rp_FrameworkVersion: TypeHint.intrinsic_str = attr.ib( default=None, validator=attr.validators.instance_of(TypeCheck.intrinsic_str_type), metadata={AttrMeta.PROPERTY_NAME: "FrameworkVersion"}, ) """Doc: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-managedblockchain-member-networkconfiguration.html#cfn-managedblockchain-member-networkconfiguration-frameworkversion""" rp_Name: TypeHint.intrinsic_str = attr.ib( default=None, validator=attr.validators.instance_of(TypeCheck.intrinsic_str_type), metadata={AttrMeta.PROPERTY_NAME: "Name"}, ) """Doc: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-managedblockchain-member-networkconfiguration.html#cfn-managedblockchain-member-networkconfiguration-name""" rp_VotingPolicy: typing.Union['MemberVotingPolicy', dict] = attr.ib( default=None, converter=MemberVotingPolicy.from_dict, validator=attr.validators.instance_of(MemberVotingPolicy), metadata={AttrMeta.PROPERTY_NAME: "VotingPolicy"}, ) """Doc: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-managedblockchain-member-networkconfiguration.html#cfn-managedblockchain-member-networkconfiguration-votingpolicy""" p_Description: TypeHint.intrinsic_str = attr.ib( default=None, validator=attr.validators.optional(attr.validators.instance_of(TypeCheck.intrinsic_str_type)), metadata={AttrMeta.PROPERTY_NAME: "Description"}, ) """Doc: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-managedblockchain-member-networkconfiguration.html#cfn-managedblockchain-member-networkconfiguration-description""" p_NetworkFrameworkConfiguration: typing.Union['MemberNetworkFrameworkConfiguration', dict] = attr.ib( default=None, converter=MemberNetworkFrameworkConfiguration.from_dict, validator=attr.validators.optional(attr.validators.instance_of(MemberNetworkFrameworkConfiguration)), metadata={AttrMeta.PROPERTY_NAME: "NetworkFrameworkConfiguration"}, ) """Doc: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-managedblockchain-member-networkconfiguration.html#cfn-managedblockchain-member-networkconfiguration-networkframeworkconfiguration""" @attr.s class MemberMemberFrameworkConfiguration(Property): """ AWS Object Type = "AWS::ManagedBlockchain::Member.MemberFrameworkConfiguration" Resource Document: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-managedblockchain-member-memberframeworkconfiguration.html Property Document: - ``p_MemberFabricConfiguration``: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-managedblockchain-member-memberframeworkconfiguration.html#cfn-managedblockchain-member-memberframeworkconfiguration-memberfabricconfiguration """ AWS_OBJECT_TYPE = "AWS::ManagedBlockchain::Member.MemberFrameworkConfiguration" p_MemberFabricConfiguration: typing.Union['MemberMemberFabricConfiguration', dict] = attr.ib( default=None, converter=MemberMemberFabricConfiguration.from_dict, validator=attr.validators.optional(attr.validators.instance_of(MemberMemberFabricConfiguration)), metadata={AttrMeta.PROPERTY_NAME: "MemberFabricConfiguration"}, ) """Doc: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-managedblockchain-member-memberframeworkconfiguration.html#cfn-managedblockchain-member-memberframeworkconfiguration-memberfabricconfiguration""" @attr.s class MemberMemberConfiguration(Property): """ AWS Object Type = "AWS::ManagedBlockchain::Member.MemberConfiguration" Resource Document: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-managedblockchain-member-memberconfiguration.html Property Document: - ``rp_Name``: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-managedblockchain-member-memberconfiguration.html#cfn-managedblockchain-member-memberconfiguration-name - ``p_Description``: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-managedblockchain-member-memberconfiguration.html#cfn-managedblockchain-member-memberconfiguration-description - ``p_MemberFrameworkConfiguration``: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-managedblockchain-member-memberconfiguration.html#cfn-managedblockchain-member-memberconfiguration-memberframeworkconfiguration """ AWS_OBJECT_TYPE = "AWS::ManagedBlockchain::Member.MemberConfiguration" rp_Name: TypeHint.intrinsic_str = attr.ib( default=None, validator=attr.validators.instance_of(TypeCheck.intrinsic_str_type), metadata={AttrMeta.PROPERTY_NAME: "Name"}, ) """Doc: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-managedblockchain-member-memberconfiguration.html#cfn-managedblockchain-member-memberconfiguration-name""" p_Description: TypeHint.intrinsic_str = attr.ib( default=None, validator=attr.validators.optional(attr.validators.instance_of(TypeCheck.intrinsic_str_type)), metadata={AttrMeta.PROPERTY_NAME: "Description"}, ) """Doc: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-managedblockchain-member-memberconfiguration.html#cfn-managedblockchain-member-memberconfiguration-description""" p_MemberFrameworkConfiguration: typing.Union['MemberMemberFrameworkConfiguration', dict] = attr.ib( default=None, converter=MemberMemberFrameworkConfiguration.from_dict, validator=attr.validators.optional(attr.validators.instance_of(MemberMemberFrameworkConfiguration)), metadata={AttrMeta.PROPERTY_NAME: "MemberFrameworkConfiguration"}, ) """Doc: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-managedblockchain-member-memberconfiguration.html#cfn-managedblockchain-member-memberconfiguration-memberframeworkconfiguration""" #--- Resource declaration --- @attr.s class Member(Resource): """ AWS Object Type = "AWS::ManagedBlockchain::Member" Resource Document: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-managedblockchain-member.html Property Document: - ``rp_MemberConfiguration``: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-managedblockchain-member.html#cfn-managedblockchain-member-memberconfiguration - ``p_InvitationId``: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-managedblockchain-member.html#cfn-managedblockchain-member-invitationid - ``p_NetworkConfiguration``: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-managedblockchain-member.html#cfn-managedblockchain-member-networkconfiguration - ``p_NetworkId``: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-managedblockchain-member.html#cfn-managedblockchain-member-networkid """ AWS_OBJECT_TYPE = "AWS::ManagedBlockchain::Member" rp_MemberConfiguration: typing.Union['MemberMemberConfiguration', dict] = attr.ib( default=None, converter=MemberMemberConfiguration.from_dict, validator=attr.validators.instance_of(MemberMemberConfiguration), metadata={AttrMeta.PROPERTY_NAME: "MemberConfiguration"}, ) """Doc: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-managedblockchain-member.html#cfn-managedblockchain-member-memberconfiguration""" p_InvitationId: TypeHint.intrinsic_str = attr.ib( default=None, validator=attr.validators.optional(attr.validators.instance_of(TypeCheck.intrinsic_str_type)), metadata={AttrMeta.PROPERTY_NAME: "InvitationId"}, ) """Doc: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-managedblockchain-member.html#cfn-managedblockchain-member-invitationid""" p_NetworkConfiguration: typing.Union['MemberNetworkConfiguration', dict] = attr.ib( default=None, converter=MemberNetworkConfiguration.from_dict, validator=attr.validators.optional(attr.validators.instance_of(MemberNetworkConfiguration)), metadata={AttrMeta.PROPERTY_NAME: "NetworkConfiguration"}, ) """Doc: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-managedblockchain-member.html#cfn-managedblockchain-member-networkconfiguration""" p_NetworkId: TypeHint.intrinsic_str = attr.ib( default=None, validator=attr.validators.optional(attr.validators.instance_of(TypeCheck.intrinsic_str_type)), metadata={AttrMeta.PROPERTY_NAME: "NetworkId"}, ) """Doc: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-managedblockchain-member.html#cfn-managedblockchain-member-networkid""" @property def rv_MemberId(self) -> GetAtt: """Doc: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-managedblockchain-member.html#aws-resource-managedblockchain-member-return-values""" return GetAtt(resource=self, attr_name="MemberId") @property def rv_NetworkId(self) -> GetAtt: """Doc: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-managedblockchain-member.html#aws-resource-managedblockchain-member-return-values""" return GetAtt(resource=self, attr_name="NetworkId") @attr.s class Node(Resource): """ AWS Object Type = "AWS::ManagedBlockchain::Node" Resource Document: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-managedblockchain-node.html Property Document: - ``rp_NetworkId``: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-managedblockchain-node.html#cfn-managedblockchain-node-networkid - ``rp_NodeConfiguration``: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-managedblockchain-node.html#cfn-managedblockchain-node-nodeconfiguration - ``p_MemberId``: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-managedblockchain-node.html#cfn-managedblockchain-node-memberid """ AWS_OBJECT_TYPE = "AWS::ManagedBlockchain::Node" rp_NetworkId: TypeHint.intrinsic_str = attr.ib( default=None, validator=attr.validators.instance_of(TypeCheck.intrinsic_str_type), metadata={AttrMeta.PROPERTY_NAME: "NetworkId"}, ) """Doc: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-managedblockchain-node.html#cfn-managedblockchain-node-networkid""" rp_NodeConfiguration: typing.Union['NodeNodeConfiguration', dict] = attr.ib( default=None, converter=NodeNodeConfiguration.from_dict, validator=attr.validators.instance_of(NodeNodeConfiguration), metadata={AttrMeta.PROPERTY_NAME: "NodeConfiguration"}, ) """Doc: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-managedblockchain-node.html#cfn-managedblockchain-node-nodeconfiguration""" p_MemberId: TypeHint.intrinsic_str = attr.ib( default=None, validator=attr.validators.optional(attr.validators.instance_of(TypeCheck.intrinsic_str_type)), metadata={AttrMeta.PROPERTY_NAME: "MemberId"}, ) """Doc: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-managedblockchain-node.html#cfn-managedblockchain-node-memberid""" @property def rv_MemberId(self) -> GetAtt: """Doc: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-managedblockchain-node.html#aws-resource-managedblockchain-node-return-values""" return GetAtt(resource=self, attr_name="MemberId") @property def rv_NodeId(self) -> GetAtt: """Doc: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-managedblockchain-node.html#aws-resource-managedblockchain-node-return-values""" return GetAtt(resource=self, attr_name="NodeId") @property def rv_Arn(self) -> GetAtt: """Doc: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-managedblockchain-node.html#aws-resource-managedblockchain-node-return-values""" return GetAtt(resource=self, attr_name="Arn") @property def rv_NetworkId(self) -> GetAtt: """Doc: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-managedblockchain-node.html#aws-resource-managedblockchain-node-return-values""" return GetAtt(resource=self, attr_name="NetworkId")
62.209596
262
0.782951
2,377
24,635
8.030711
0.040808
0.143381
0.040914
0.06323
0.86521
0.86521
0.841846
0.774635
0.774635
0.773692
0
0.000045
0.09933
24,635
395
263
62.367089
0.860285
0.377715
0
0.39801
0
0
0.128758
0.09548
0
0
0
0
0
1
0.029851
false
0.00995
0.019901
0
0.323383
0
0
0
0
null
0
0
0
1
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
6
cae123dd1aba9de60a95bd77b8df87f3ec9aabad
35
py
Python
users/models/__init__.py
sharif-42/Personal_Website
7c385bec272ec7b5c816eab92e3b5bfb8cd80016
[ "MIT" ]
null
null
null
users/models/__init__.py
sharif-42/Personal_Website
7c385bec272ec7b5c816eab92e3b5bfb8cd80016
[ "MIT" ]
9
2021-03-30T13:41:09.000Z
2022-03-12T00:32:50.000Z
users/models/__init__.py
abheist/goldenSwan-backend
153e16bb829f113fb429131436324631f15ae064
[ "MIT" ]
null
null
null
from users.models.user import User
17.5
34
0.828571
6
35
4.833333
0.833333
0
0
0
0
0
0
0
0
0
0
0
0.114286
35
1
35
35
0.935484
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
1
0
0
6
cae16d560475d9885ce8c229f41e64b052bd67bd
124
py
Python
src/domain/errors/unable_to_convert_image_to_grayscale_failure.py
OzielFilho/ProjetoFinalPdi
c9e6fe415f1a985d6eeac204580d3ab623026665
[ "MIT" ]
null
null
null
src/domain/errors/unable_to_convert_image_to_grayscale_failure.py
OzielFilho/ProjetoFinalPdi
c9e6fe415f1a985d6eeac204580d3ab623026665
[ "MIT" ]
null
null
null
src/domain/errors/unable_to_convert_image_to_grayscale_failure.py
OzielFilho/ProjetoFinalPdi
c9e6fe415f1a985d6eeac204580d3ab623026665
[ "MIT" ]
null
null
null
from domain.errors.image_failure import ImageFailure class UnableToConvertImageToGrayscaleFailure(ImageFailure): pass
20.666667
59
0.854839
11
124
9.545455
0.909091
0
0
0
0
0
0
0
0
0
0
0
0.104839
124
5
60
24.8
0.945946
0
0
0
0
0
0
0
0
0
0
0
0
1
0
true
0.333333
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
1
1
1
0
1
0
0
6
1b1742827867f1f6cbdba562ecb2b003c0353235
27
py
Python
taattack/_datasets/ag_news/__init__.py
linerxliner/ValCAT
e62985c6c64f6415bb2bb4716bd02d9686badd47
[ "MIT" ]
null
null
null
taattack/_datasets/ag_news/__init__.py
linerxliner/ValCAT
e62985c6c64f6415bb2bb4716bd02d9686badd47
[ "MIT" ]
null
null
null
taattack/_datasets/ag_news/__init__.py
linerxliner/ValCAT
e62985c6c64f6415bb2bb4716bd02d9686badd47
[ "MIT" ]
null
null
null
from .ag_news import AgNews
27
27
0.851852
5
27
4.4
1
0
0
0
0
0
0
0
0
0
0
0
0.111111
27
1
27
27
0.916667
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
1
0
0
6
1b393b5eae4b55fa61b83e57ade5a59893eb4d5d
9,874
py
Python
Tests/test_rest_api.py
James-Chapman/Python_REST_API
d15d39f1c3fd07f18651a94325efb250290c2601
[ "BSD-3-Clause" ]
null
null
null
Tests/test_rest_api.py
James-Chapman/Python_REST_API
d15d39f1c3fd07f18651a94325efb250290c2601
[ "BSD-3-Clause" ]
null
null
null
Tests/test_rest_api.py
James-Chapman/Python_REST_API
d15d39f1c3fd07f18651a94325efb250290c2601
[ "BSD-3-Clause" ]
null
null
null
import http.client import json import threading import time import pytest from RESTfulHTTPRequestHandler import RESTfulHTTPRequestHandler @pytest.fixture(scope="module", autouse=True) def start_rest_service(): print("Starting server") SERVER_IP = "0.0.0.0" SERVER_PORT = 8080 SERVER = http.server.ThreadingHTTPServer((SERVER_IP, SERVER_PORT), RESTfulHTTPRequestHandler) thread1 = threading.Thread(target=SERVER.serve_forever, args=()) thread1.daemon = True thread1.start() time.sleep(5) # Give server a chance to start yield SERVER def test_POST_api_job_start(): testData = {"command": "ping -n 5 127.0.0.1"} jsonString = json.dumps(testData) restConn = http.client.HTTPConnection("127.0.0.1", 8080) headers = {'Content-type': 'application/json;charset=utf-8', 'Content-length': len(jsonString)} # Create 101 jobs for i in range(101): restConn.connect() restConn.request('POST', '/api/jobs', jsonString, headers) resp = restConn.getresponse() restConn.close() assert(resp.status == 200) def test_PUT_api_job_stop(): time.sleep(1) # Sleep while server starts restConn = http.client.HTTPConnection("127.0.0.1", 8080) headers = {'Content-type': 'application/json;charset=utf-8'} restConn.connect() restConn.request("PUT", "/api/jobs/100/stop", headers=headers) resp = restConn.getresponse() assert(resp.status == 200) resp.close() restConn.close() # Now check that the job has been stopped. def test_GET_api_job_100(): restConn = http.client.HTTPConnection("127.0.0.1", 8080) headers = {'Content-type': 'application/json;charset=utf-8'} restConn.connect() restConn.request("GET", "/api/jobs/100", headers=headers) resp = restConn.getresponse() assert(resp.status == 200) bytedata = resp.read() data = json.loads(bytes.decode(bytedata, "utf-8")) restConn.close() assert (data["id"] == 100) assert (data["status"] == "stopped") assert (data["command"] == "ping -n 5 127.0.0.1") def test_GET_api_job_99(): restConn = http.client.HTTPConnection("127.0.0.1", 8080) restConn.connect() headers = {'Content-type': 'application/json;charset=utf-8', 'Content-length': 0} restConn.request('GET', '/api/jobs/99', "", headers) resp = restConn.getresponse() assert (resp.status == 200) bytedata = resp.read() data = json.loads(bytes.decode(bytedata, "utf-8")) restConn.close() assert (data["id"] == 99) assert (data["status"] == "running") assert (data["command"] == "ping -n 5 127.0.0.1") def test_GET_api_job_0(): time.sleep(4) # Give jobs time to complete restConn = http.client.HTTPConnection("127.0.0.1", 8080) restConn.connect() restConn.putrequest("GET", "/api/jobs/0") restConn.putheader("content-type", "application/json;charset=utf-8") restConn.endheaders() resp = restConn.getresponse() assert(resp.status == 200) bytedata = resp.read() data = json.loads(bytes.decode(bytedata, "utf-8")) restConn.close() assert (data["id"] == 0) assert (data["status"] == "completed") assert (data["command"] == "ping -n 5 127.0.0.1") assert(data["stdout"] != "") def test_GET_api_job_5(): restConn = http.client.HTTPConnection("127.0.0.1", 8080) restConn.connect() headers = {'Content-type': 'application/json;charset=utf-8', 'Content-length': 0} restConn.request('GET', '/api/jobs/5', "", headers) resp = restConn.getresponse() assert(resp.status == 200) bytedata = resp.read() data = json.loads(bytes.decode(bytedata, "utf-8")) restConn.close() assert (data["id"] == 5) assert (data["status"] == "completed") assert (data["command"] == "ping -n 5 127.0.0.1") assert (data["stdout"] != "") def test_GET_api_job_9999(): restConn = http.client.HTTPConnection("127.0.0.1", 8080) restConn.connect() headers = {'Content-type': 'application/json;charset=utf-8', 'Content-length': 0} restConn.request('GET', '/api/jobs/9999', "", headers) resp = restConn.getresponse() assert(resp.status == 404) bytedata = resp.read() data = json.loads(bytes.decode(bytedata, "utf-8")) restConn.close() assert(data["id"] == -1) def test_GET_api_jobs(): restConn = http.client.HTTPConnection("127.0.0.1", 8080) restConn.connect() restConn.putrequest("GET", "/api/jobs") restConn.putheader("content-type", "application/json;charset=utf-8") restConn.endheaders() resp = restConn.getresponse() assert(resp.status == 200) bytedata = resp.read() data = json.loads(bytes.decode(bytedata, "utf-8")) restConn.close() assert (len(data["jobs"]) > 0) def test_GET_api_jobs_running(): restConn = http.client.HTTPConnection("127.0.0.1", 8080) restConn.connect() restConn.putrequest("GET", "/api/jobs?status=running") restConn.putheader("content-type", "application/json;charset=utf-8") restConn.endheaders() resp = restConn.getresponse() assert(resp.status == 200) bytedata = resp.read() data = json.loads(bytes.decode(bytedata, "utf-8")) restConn.close() assert (len(data["jobs"]) > 0) def test_GET_api_jobs_stopped(): restConn = http.client.HTTPConnection("127.0.0.1", 8080) restConn.connect() restConn.putrequest("GET", "/api/jobs?status=stopped") restConn.putheader("content-type", "application/json;charset=utf-8") restConn.endheaders() resp = restConn.getresponse() assert(resp.status == 200) bytedata = resp.read() data = json.loads(bytes.decode(bytedata, "utf-8")) restConn.close() assert (len(data["jobs"]) > 0) def test_GET_api_jobs_completed(): restConn = http.client.HTTPConnection("127.0.0.1", 8080) restConn.connect() restConn.putrequest("GET", "/api/jobs?status=completed") restConn.putheader("content-type", "application/json;charset=utf-8") restConn.endheaders() resp = restConn.getresponse() assert(resp.status == 200) bytedata = resp.read() data = json.loads(bytes.decode(bytedata, "utf-8")) restConn.close() assert (len(data["jobs"]) > 0) def test_POST_api_job_start_empty_command(): testData = {"command": ""} jsonString = json.dumps(testData) restConn = http.client.HTTPConnection("127.0.0.1", 8080) headers = {'Content-type': 'application/json;charset=utf-8', 'Content-length': len(jsonString)} restConn.connect() restConn.request('POST', '/api/jobs', jsonString, headers) resp = restConn.getresponse() assert(resp.status == 200) bytedata = resp.read() restConn.close() data = json.loads(bytes.decode(bytedata, "utf-8")) assert(data["id"] == -1) def test_rest_api_with_garbage_command(): testData = {"command": "this_command_doesnt_exist even with args"} jsonString = json.dumps(testData) restConn = http.client.HTTPConnection("127.0.0.1", 8080) headers = {'Content-type': 'application/json;charset=utf-8', 'Content-length': len(jsonString)} restConn.connect() restConn.request('POST', '/api/jobs', jsonString, headers) resp = restConn.getresponse() assert(resp.status == 200) bytedata = resp.read() restConn.close() data = json.loads(bytes.decode(bytedata, "utf-8")) time.sleep(1) # server needs time to work out the command is garbage restConn1 = http.client.HTTPConnection("127.0.0.1", 8080) headers = {'Content-type': 'application/json;charset=utf-8'} restConn1.connect() path = "/api/jobs/{}".format(data["id"]) restConn1.request("GET", path, headers=headers) resp = restConn1.getresponse() assert (resp.status == 200) bytedata = resp.read() data = json.loads(bytes.decode(bytedata, "utf-8")) restConn1.close() assert(data["status"] == "stopped") def test_rest_api_false_path_GET(): restConn = http.client.HTTPConnection("127.0.0.1", 8080) restConn.connect() headers = {'Content-type': 'application/json;charset=utf-8', 'Content-length': 0} restConn.request('GET', '/api/doesnt-exist', "", headers) resp = restConn.getresponse() assert (resp.status == 404) def test_rest_api_false_path_POST(): restConn = http.client.HTTPConnection("127.0.0.1", 8080) restConn.connect() headers = {'Content-type': 'application/json;charset=utf-8', 'Content-length': 0} restConn.request('POST', '/api/rubbish', "", headers) resp = restConn.getresponse() assert (resp.status == 404) def test_rest_api_false_path_PUT(): restConn = http.client.HTTPConnection("127.0.0.1", 8080) restConn.connect() headers = {'Content-type': 'application/json;charset=utf-8', 'Content-length': 0} restConn.request('PUT', '/api/rubbish', "", headers) resp = restConn.getresponse() assert (resp.status == 404) def test_rest_api_false_path_DELETE(): restConn = http.client.HTTPConnection("127.0.0.1", 8080) restConn.connect() headers = {'Content-type': 'application/json;charset=utf-8', 'Content-length': 0} restConn.request('DELETE', '/api/rubbish', "", headers) resp = restConn.getresponse() assert (resp.status == 404) def test_rest_api_OPTIONS(): restConn = http.client.HTTPConnection("127.0.0.1", 8080) restConn.connect() headers = {'Content-type': 'application/json;charset=utf-8', 'Content-length': 0} restConn.request('OPTIONS', '/path/doesnt/matter', "", headers) resp = restConn.getresponse() assert (resp.status == 200) def test_rest_api_false_path_NON_EXISTANT(): restConn = http.client.HTTPConnection("127.0.0.1", 8080) restConn.connect() headers = {'Content-type': 'application/json;charset=utf-8', 'Content-length': 0} restConn.request('NON_EXISTANT', '/api/rubbish', "", headers) resp = restConn.getresponse() assert (resp.status == 501)
35.517986
99
0.664371
1,255
9,874
5.152191
0.104382
0.019796
0.019332
0.023198
0.826013
0.820445
0.799258
0.799258
0.781163
0.762759
0
0.04855
0.165586
9,874
277
100
35.646209
0.736254
0.019445
0
0.698276
0
0
0.200103
0.072248
0
0
0
0
0.176724
1
0.086207
false
0
0.025862
0
0.112069
0.00431
0
0
0
null
0
0
0
1
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
6
1b67b132fc1368f011ffbedb258e5d0877bb1539
36
py
Python
simple.py
javakung/masahiro
bf107b8a75103258c44fd5adde78043399d3216c
[ "MIT" ]
null
null
null
simple.py
javakung/masahiro
bf107b8a75103258c44fd5adde78043399d3216c
[ "MIT" ]
null
null
null
simple.py
javakung/masahiro
bf107b8a75103258c44fd5adde78043399d3216c
[ "MIT" ]
null
null
null
def say(text): print('say',text)
18
21
0.611111
6
36
3.666667
0.666667
0.636364
0
0
0
0
0
0
0
0
0
0
0.166667
36
2
21
18
0.733333
0
0
0
0
0
0.081081
0
0
0
0
0
0
1
0.5
false
0
0
0
0.5
0.5
1
1
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
0
1
0
6
1b6a2ea5c1d11720d01b9c747c696b1eb195433d
28
py
Python
nba_ss_db/scrape/__init__.py
jsonchin/nba_stats_scraper_db_storage
33f33d89c5c76db9625f4973db8afdbbd7045263
[ "Apache-2.0" ]
4
2017-11-04T05:03:57.000Z
2022-01-30T13:24:15.000Z
nba_ss_db/scrape/__init__.py
jsonchin/nba_stats_scraper_db_storage
33f33d89c5c76db9625f4973db8afdbbd7045263
[ "Apache-2.0" ]
1
2021-06-01T22:05:19.000Z
2021-06-01T22:05:19.000Z
nba_ss_db/scrape/__init__.py
jsonchin/nba_stats_scraper_db_storage
33f33d89c5c76db9625f4973db8afdbbd7045263
[ "Apache-2.0" ]
2
2017-11-26T18:59:59.000Z
2018-07-05T18:05:09.000Z
from . import scraper, utils
28
28
0.785714
4
28
5.5
1
0
0
0
0
0
0
0
0
0
0
0
0.142857
28
1
28
28
0.916667
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
1
0
0
6
1b98e8fc5e5f8bd6d9e2a5fd5c1f9e6b7068b730
858
py
Python
Search/Modes.py
jbzdarkid/TwitchLink
c7bae13b46c7e6af7dc74539fdbca9cbb01f4778
[ "MIT" ]
26
2021-02-04T00:29:21.000Z
2022-03-25T17:14:43.000Z
Search/Modes.py
jbzdarkid/TwitchLink
c7bae13b46c7e6af7dc74539fdbca9cbb01f4778
[ "MIT" ]
19
2021-02-04T01:27:07.000Z
2022-03-19T16:22:46.000Z
Search/Modes.py
jbzdarkid/TwitchLink
c7bae13b46c7e6af7dc74539fdbca9cbb01f4778
[ "MIT" ]
10
2021-06-08T17:41:40.000Z
2022-03-28T22:38:40.000Z
class SearchModes: class MODES: CHANNEL = "channel" VIDEO = "video" CLIP = "clip" URL = "url" CHANNEL = lambda: SearchModes(SearchModes.MODES.CHANNEL) VIDEO = lambda: SearchModes(SearchModes.MODES.VIDEO) CLIP = lambda: SearchModes(SearchModes.MODES.CLIP) URL = lambda: SearchModes(SearchModes.MODES.URL) def __init__(self, searchMode): self.setMode(searchMode) def setMode(self, searchMode): self._searchMode = searchMode def getMode(self): return self._searchMode def isChannel(self): return self._searchMode == self.MODES.CHANNEL def isVideo(self): return self._searchMode == self.MODES.VIDEO def isClip(self): return self._searchMode == self.MODES.CLIP def isUrl(self): return self._searchMode == self.MODES.URL
26.8125
60
0.65035
92
858
5.956522
0.206522
0.20438
0.19708
0.218978
0.240876
0.240876
0
0
0
0
0
0
0.248252
858
32
61
26.8125
0.849612
0
0
0
0
0
0.022119
0
0
0
0
0
0
1
0.291667
false
0
0
0.208333
0.75
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
1
0
0
0
1
1
0
0
6
1ba715107051878654d614c0563409a55f9d55d0
117
py
Python
expects/factory.py
danibaena/expects
296203a3fb07cf3061b8f7b348136c9208195d93
[ "Apache-2.0" ]
189
2015-01-05T13:26:40.000Z
2021-09-27T12:44:48.000Z
expects/factory.py
danibaena/expects
296203a3fb07cf3061b8f7b348136c9208195d93
[ "Apache-2.0" ]
38
2015-02-13T16:08:23.000Z
2022-02-14T12:14:28.000Z
expects/factory.py
danibaena/expects
296203a3fb07cf3061b8f7b348136c9208195d93
[ "Apache-2.0" ]
32
2015-03-12T08:06:47.000Z
2022-03-08T18:16:28.000Z
# -*- coding: utf-8 -* from .expectations import Expectation def expect(subject): return Expectation(subject)
14.625
37
0.709402
13
117
6.384615
0.846154
0
0
0
0
0
0
0
0
0
0
0.010309
0.17094
117
7
38
16.714286
0.845361
0.17094
0
0
0
0
0
0
0
0
0
0
0
1
0.333333
false
0
0.333333
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
1
1
1
0
0
6
1bc0dee6512dee5dd396b980936f3c7be2910e24
21
py
Python
tasks/snli/third_party/models/__init__.py
etri-edgeai/nn-comp-discblock
6e00a019c223508797ca91a7d5ffec7917b12c6d
[ "Apache-2.0" ]
10
2021-11-19T06:24:51.000Z
2022-02-09T15:44:00.000Z
tasks/snli/third_party/models/__init__.py
etri-edgeai/nn-comp-discblock
6e00a019c223508797ca91a7d5ffec7917b12c6d
[ "Apache-2.0" ]
9
2021-10-01T11:06:27.000Z
2021-12-23T02:10:52.000Z
tasks/snli/third_party/models/__init__.py
etri-edgeai/nn-comp-discblock
6e00a019c223508797ca91a7d5ffec7917b12c6d
[ "Apache-2.0" ]
2
2021-09-14T04:08:36.000Z
2021-11-19T06:24:54.000Z
from .bilstm import *
21
21
0.761905
3
21
5.333333
1
0
0
0
0
0
0
0
0
0
0
0
0.142857
21
1
21
21
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
1
0
0
6
1bc765756d526736cf6a3bc250962a905c74a2fe
96
py
Python
venv/lib/python3.8/site-packages/debugpy/_vendored/pydevd/pydevd_attach_to_process/winappdbg/search.py
Retraces/UkraineBot
3d5d7f8aaa58fa0cb8b98733b8808e5dfbdb8b71
[ "MIT" ]
2
2022-03-13T01:58:52.000Z
2022-03-31T06:07:54.000Z
venv/lib/python3.8/site-packages/debugpy/_vendored/pydevd/pydevd_attach_to_process/winappdbg/search.py
DesmoSearch/Desmobot
b70b45df3485351f471080deb5c785c4bc5c4beb
[ "MIT" ]
19
2021-11-20T04:09:18.000Z
2022-03-23T15:05:55.000Z
venv/lib/python3.8/site-packages/debugpy/_vendored/pydevd/pydevd_attach_to_process/winappdbg/search.py
DesmoSearch/Desmobot
b70b45df3485351f471080deb5c785c4bc5c4beb
[ "MIT" ]
null
null
null
/home/runner/.cache/pip/pool/36/e5/28/ca853b94c668be26e06488e44cab51b31595b98dc54587ce26270cefe9
96
96
0.895833
9
96
9.555556
1
0
0
0
0
0
0
0
0
0
0
0.4375
0
96
1
96
96
0.458333
0
0
0
0
0
0
0
0
1
0
0
0
0
null
null
0
0
null
null
0
1
0
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
1
0
0
0
1
0
0
0
0
0
0
0
0
6
8473e79ce1dc30c2604853fa5480c0867b6a4485
325
py
Python
alphatwirl/selection/factories/LambdaStrFromDictFactory.py
benkrikler/alphatwirl
cda7d12fec21291ea33af23234fc08be19430934
[ "BSD-3-Clause" ]
null
null
null
alphatwirl/selection/factories/LambdaStrFromDictFactory.py
benkrikler/alphatwirl
cda7d12fec21291ea33af23234fc08be19430934
[ "BSD-3-Clause" ]
7
2018-02-26T10:32:26.000Z
2018-03-19T12:27:12.000Z
alphatwirl/selection/factories/LambdaStrFromDictFactory.py
benkrikler/alphatwirl
cda7d12fec21291ea33af23234fc08be19430934
[ "BSD-3-Clause" ]
null
null
null
# Tai Sakuma <tai.sakuma@gmail.com> ##__________________________________________________________________|| def LambdaStrFromDictFactory(key, **kargs): return kargs['LambdaStrClass'](lambda_str = kargs['aliasDict'][key].format(**kargs), name = key) ##__________________________________________________________________||
40.625
100
0.809231
22
325
5.909091
0.681818
0.138462
0
0
0
0
0
0
0
0
0
0
0.067692
325
7
101
46.428571
0.429043
0.52
0
0
0
0
0.153333
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
1
0
0
0
0
0
0
0
null
0
0
0
0
0
1
0
0
0
1
1
0
0
6
8478fa34761867d4aaa7f45e3eb24d07c46e332b
26
py
Python
feeder/__init__.py
niais/mv-ignet
903dd4e48971b2c165269820fa8679b354dd41a2
[ "BSD-2-Clause" ]
18
2021-01-07T12:38:58.000Z
2021-09-26T11:36:03.000Z
feeder/__init__.py
niais/mv-ignet
903dd4e48971b2c165269820fa8679b354dd41a2
[ "BSD-2-Clause" ]
8
2021-04-16T11:55:44.000Z
2022-01-10T11:52:07.000Z
feeder/__init__.py
niais/mv-ignet
903dd4e48971b2c165269820fa8679b354dd41a2
[ "BSD-2-Clause" ]
1
2021-01-20T07:33:03.000Z
2021-01-20T07:33:03.000Z
from . import NTUDatasets
13
25
0.807692
3
26
7
1
0
0
0
0
0
0
0
0
0
0
0
0.153846
26
1
26
26
0.954545
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
1
0
0
6
8491a870b91029a54a432db42dfaf63a43ed2b93
41
py
Python
src/workflowtools/scripts/rmbmenuhook/__init__.py
bohdon/maya-workflowtools
11587464a4f253eb4d8ab5d034fc93676d726414
[ "MIT" ]
null
null
null
src/workflowtools/scripts/rmbmenuhook/__init__.py
bohdon/maya-workflowtools
11587464a4f253eb4d8ab5d034fc93676d726414
[ "MIT" ]
null
null
null
src/workflowtools/scripts/rmbmenuhook/__init__.py
bohdon/maya-workflowtools
11587464a4f253eb4d8ab5d034fc93676d726414
[ "MIT" ]
null
null
null
from .core import * from .menu import *
10.25
19
0.682927
6
41
4.666667
0.666667
0
0
0
0
0
0
0
0
0
0
0
0.219512
41
3
20
13.666667
0.875
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
1
0
0
6
84920797588f00f8d38dad60680dd7cd78500eed
26
py
Python
kpireport/tests/test_view.py
diurnalist/kpireporter
b3ce9ca52567405557ea12f45c1a7fda076d746a
[ "BlueOak-1.0.0", "Apache-2.0" ]
9
2021-05-17T05:32:46.000Z
2022-03-16T22:49:26.000Z
kpireport/tests/test_view.py
diurnalist/kpireporter
b3ce9ca52567405557ea12f45c1a7fda076d746a
[ "BlueOak-1.0.0", "Apache-2.0" ]
4
2020-10-10T23:38:20.000Z
2020-11-08T22:41:24.000Z
kpireport/tests/test_view.py
diurnalist/kpireporter
b3ce9ca52567405557ea12f45c1a7fda076d746a
[ "BlueOak-1.0.0", "Apache-2.0" ]
1
2021-01-12T02:49:04.000Z
2021-01-12T02:49:04.000Z
def test_view(): pass
8.666667
16
0.615385
4
26
3.75
1
0
0
0
0
0
0
0
0
0
0
0
0.269231
26
2
17
13
0.789474
0
0
0
0
0
0
0
0
0
0
0
0
1
0.5
true
0.5
0
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
1
1
1
0
0
0
0
0
6
849b8cb8e6ac933479473dc8dde8c9dbfe4f015c
19
py
Python
src/bread/cli/__init__.py
ninivert/bread
9f8502574312d702fee9910130cffe3d876efced
[ "MIT" ]
null
null
null
src/bread/cli/__init__.py
ninivert/bread
9f8502574312d702fee9910130cffe3d876efced
[ "MIT" ]
null
null
null
src/bread/cli/__init__.py
ninivert/bread
9f8502574312d702fee9910130cffe3d876efced
[ "MIT" ]
null
null
null
from ._cli import *
19
19
0.736842
3
19
4.333333
1
0
0
0
0
0
0
0
0
0
0
0
0.157895
19
1
19
19
0.8125
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
1
0
0
6
170381d9e841911c723fa6202b20829ff06d7d9a
1,783
py
Python
PB_Conversores.py
angatu0/python_level0
365bb78d71e212b51d985edfd71c342d1fddca18
[ "MIT" ]
1
2019-07-24T02:38:50.000Z
2019-07-24T02:38:50.000Z
PB_Conversores.py
angatu0/python_level0
365bb78d71e212b51d985edfd71c342d1fddca18
[ "MIT" ]
null
null
null
PB_Conversores.py
angatu0/python_level0
365bb78d71e212b51d985edfd71c342d1fddca18
[ "MIT" ]
null
null
null
# The goal is load menu with two options for choose which convert mode. # In addition to humanize more the interaction. print('Hi, How to help you?') menu = input('Choose the convert mode:: \n [A] Fahrenheit > Celsius. \n [B] Seconds > Hours.\n Enter your option: ') if menu == 'A': # Choose temperature, ask the value. F = float(input('Entering the temperature in Fahrenheit for convert in Celsius: ')) C = (F - 32) * 5 / 9 print('The temperature is {:.2f}ºC'.format(C)) elif menu == 'B': segt = int(input('What is the total time in seconds: ')) h = segt // 3600 sr = segt % 3600 min = sr // 60 srf = sr % 60 if h == 0: print('{}min {}s'.format(min,srf)) else: print('{}h {}min {}s'.format(h,min,srf)) print('Hope this helps. I see you later.') else: while menu != 'A' and 'B': print('Invalid option. Entering "A" or "B".') menu = input('Choose what you would like to convert:' '\n [A] Fahrenheit > Celsius.' '\n [B] Seconds > Hours.' '\n Entering thr option here: ') if menu == 'A': # Choose temperature, ask the value. F = float(input('Entering the temperature in Fahrenheit for convert in Celsius: ')) C = (F - 32) * 5 / 9 print('The temperature is {:.2f}ºC'.format(C)) elif menu == 'B': segt = int(input('What is the total time in seconds: ')) h = segt // 3600 sr = segt % 3600 min = sr // 60 srf = sr % 60 if h == 0: print('{}min {}s'.format(min, srf)) else: print('{}h {}min {}s'.format(h, min, srf)) print('Hope this helps. I see you later.')
43.487805
116
0.523836
247
1,783
3.781377
0.315789
0.059957
0.042827
0.040685
0.715203
0.715203
0.715203
0.715203
0.715203
0.642398
0
0.030227
0.332025
1,783
41
117
43.487805
0.753988
0.103758
0
0.794872
0
0.025641
0.401506
0
0
0
0
0
0
1
0
false
0
0
0
0
0.25641
0
0
0
null
0
0
0
0
1
1
1
1
1
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
6
ca247fe08a53942f8642aef605773c5c41a6be1c
143
py
Python
cfgov/v1/admin.py
m3brown/cfgov-refresh
9582dccc97498a27fcf78a70bb50ef06efa2ce74
[ "CC0-1.0" ]
null
null
null
cfgov/v1/admin.py
m3brown/cfgov-refresh
9582dccc97498a27fcf78a70bb50ef06efa2ce74
[ "CC0-1.0" ]
null
null
null
cfgov/v1/admin.py
m3brown/cfgov-refresh
9582dccc97498a27fcf78a70bb50ef06efa2ce74
[ "CC0-1.0" ]
null
null
null
from django.contrib import admin from models.snippets import Contact @admin.register(Contact) class ContactAdmin(admin.ModelAdmin): pass
17.875
37
0.804196
18
143
6.388889
0.722222
0
0
0
0
0
0
0
0
0
0
0
0.125874
143
7
38
20.428571
0.92
0
0
0
0
0
0
0
0
0
0
0
0
1
0
true
0.2
0.4
0
0.6
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
1
1
0
1
0
0
6
ca5a0852a6312a3e102d090203e4ab6039779046
29,392
py
Python
nas_bench/cell.py
ntienvu/TW_NAS
72a6d3c933978663c583661eee765bc316f66572
[ "Apache-2.0" ]
4
2021-11-01T14:01:39.000Z
2022-02-28T03:04:27.000Z
nas_bench/cell.py
ntienvu/TW_NAS
72a6d3c933978663c583661eee765bc316f66572
[ "Apache-2.0" ]
null
null
null
nas_bench/cell.py
ntienvu/TW_NAS
72a6d3c933978663c583661eee765bc316f66572
[ "Apache-2.0" ]
2
2021-06-08T09:13:03.000Z
2021-11-01T14:01:45.000Z
import sys sys.path.insert(0,'..') sys.path.insert(0,'../../') import numpy as np import copy import random import ot from nasbench import api as nb101_api #import time from scipy.sparse.csgraph import shortest_path from nas_201_api import NASBench201API as API from tw_2g_v2b import TW_2G_NB201,TW_2G_NB101,TW_NASBENCH201,TW_NASBENCH101 #from tw_2g_v2b import TW_Operations_NB101, TW_InDegrees_NASBENCH,TW_OutDegrees_NASBENCH class Cell: def __init__(self, matrix, ops): self.matrix = matrix self.ops = ops self.get_infor() def get_infor(self): self.INPUT = 'input' self.OUTPUT = 'output' self.CONV3X3 = 'conv3x3-bn-relu' self.CONV1X1 = 'conv1x1-bn-relu' self.MAXPOOL3X3 = 'maxpool3x3' self.OPS = [self.CONV3X3, self.CONV1X1, self.MAXPOOL3X3] self.OPS_2Gram=[] self.NUM_VERTICES = 7 self.OP_SPOTS = self.NUM_VERTICES - 2 self.MAX_EDGES = 9 def serialize(self): return { 'matrix': self.matrix, 'ops': self.ops } def modelspec(self): return nb101_api.ModelSpec(matrix=self.matrix, ops=self.ops) @classmethod def random_cell(cls, nasbench): """ From the NASBench repository https://github.com/google-research/nasbench """ INPUT = 'input' OUTPUT = 'output' CONV3X3 = 'conv3x3-bn-relu' CONV1X1 = 'conv1x1-bn-relu' MAXPOOL3X3 = 'maxpool3x3' OPS = [CONV3X3, CONV1X1, MAXPOOL3X3] #OPS_2Gram=[] NUM_VERTICES = 7 #OP_SPOTS = NUM_VERTICES - 2 #MAX_EDGES = 9 while True: matrix = np.random.choice( [0, 1], size=(NUM_VERTICES, NUM_VERTICES)) matrix = np.triu(matrix, 1) ops = np.random.choice(OPS, size=NUM_VERTICES).tolist() ops[0] = INPUT ops[-1] = OUTPUT spec = nb101_api.ModelSpec(matrix=matrix, ops=ops) if nasbench.is_valid(spec): return { 'matrix': matrix, 'ops': ops } def get_val_loss(self, nasbench, deterministic=1, patience=50): if not deterministic: # output one of the three validation accuracies at random return (100*(1 - nasbench.query(nb101_api.ModelSpec(matrix=self.matrix, ops=self.ops))['validation_accuracy'])) else: # query the api until we see all three accuracies, then average them # a few architectures only have two accuracies, so we use patience to avoid an infinite loop accs = [] while len(accs) < 3 and patience > 0: patience -= 1 acc = nasbench.query(nb101_api.ModelSpec(matrix=self.matrix, ops=self.ops))['validation_accuracy'] if acc not in accs: accs.append(acc) return round(100*(1-np.mean(accs)), 3) def get_test_loss(self, nasbench, patience=50): """ query the api until we see all three accuracies, then average them a few architectures only have two accuracies, so we use patience to avoid an infinite loop """ accs = [] while len(accs) < 3 and patience > 0: patience -= 1 acc = nasbench.query(nb101_api.ModelSpec(matrix=self.matrix, ops=self.ops))['test_accuracy'] if acc not in accs: accs.append(acc) return round(100*(1-np.mean(accs)), 3) def perturb(self, nasbench, edits=1): """ create new perturbed cell inspird by https://github.com/google-research/nasbench """ new_matrix = copy.deepcopy(self.matrix) new_ops = copy.deepcopy(self.ops) for _ in range(edits): while True: if np.random.random() < 0.5: for src in range(0, self.NUM_VERTICES - 1): for dst in range(src+1, self.NUM_VERTICES): new_matrix[src][dst] = 1 - new_matrix[src][dst] else: for ind in range(1, self.NUM_VERTICES - 1): available = [op for op in self.OPS if op != new_ops[ind]] new_ops[ind] = np.random.choice(available) new_spec = nb101_api.ModelSpec(new_matrix, new_ops) if nasbench.is_valid(new_spec): break return { 'matrix': new_matrix, 'ops': new_ops } def mutate(self, nasbench, mutation_rate=1.0): """ similar to perturb. A stochastic approach to perturbing the cell inspird by https://github.com/google-research/nasbench """ while True: new_matrix = copy.deepcopy(self.matrix) new_ops = copy.deepcopy(self.ops) edge_mutation_prob = mutation_rate / self.NUM_VERTICES for src in range(0, self.NUM_VERTICES - 1): for dst in range(src + 1, self.NUM_VERTICES): if random.random() < edge_mutation_prob: new_matrix[src, dst] = 1 - new_matrix[src, dst] op_mutation_prob = mutation_rate / self.OP_SPOTS for ind in range(1, self.OP_SPOTS + 1): if random.random() < op_mutation_prob: available = [o for o in self.OPS if o != new_ops[ind]] new_ops[ind] = random.choice(available) new_spec = nb101_api.ModelSpec(new_matrix, new_ops) if nasbench.is_valid(new_spec): return { 'matrix': new_matrix, 'ops': new_ops } def encode_cell(self): """ compute the "standard" encoding, i.e. adjacency matrix + op list encoding """ encoding_length = (self.NUM_VERTICES ** 2 - self.NUM_VERTICES) // 2 + self.OP_SPOTS encoding = np.zeros((encoding_length)) dic = {self.CONV1X1: 0., self.CONV3X3: 0.5, self.MAXPOOL3X3: 1.0} n = 0 for i in range(self.NUM_VERTICES - 1): for j in range(i+1, self.NUM_VERTICES): encoding[n] = self.matrix[i][j] n += 1 for i in range(1, self.NUM_VERTICES - 1): encoding[-i] = dic[self.ops[i]] return tuple(encoding) def get_paths(self): """ return all paths from input to output """ paths = [] for j in range(0, self.NUM_VERTICES): paths.append([[]]) if self.matrix[0][j] else paths.append([]) # create paths sequentially for i in range(1, self.NUM_VERTICES - 1): for j in range(1, self.NUM_VERTICES): if self.matrix[i][j]: for path in paths[i]: paths[j].append([*path, self.ops[i]]) return paths[-1] def get_path_indices(self): """ compute the index of each path There are 3^0 + ... + 3^5 paths total. (Paths can be length 0 to 5, and for each path, for each node, there are three choices for the operation.) """ paths = self.get_paths() mapping = {self.CONV3X3: 0, self.CONV1X1: 1, self.MAXPOOL3X3: 2} path_indices = [] for path in paths: index = 0 for i in range(self.NUM_VERTICES - 1): if i == len(path): path_indices.append(index) break else: index += len(self.OPS) ** i * (mapping[path[i]] + 1) return tuple(path_indices) def encode_paths(self): """ output one-hot encoding of paths """ num_paths = sum([len(self.OPS) ** i for i in range(self.OP_SPOTS + 1)]) path_indices = self.get_path_indices() path_encoding = np.zeros(num_paths) for index in path_indices: path_encoding[index] = 1 return path_encoding def path_distance(self, other): """ compute the distance between two architectures by comparing their path encodings """ return np.sum(np.array(self.encode_paths() != np.array(other.encode_paths()))) def ot_distance(self, other): # distance based on OTMANN distance adapted to cell-based search spaces # see our arxiv paper for more details MAXVAL = 10000; MX=self.matrix MY=other.matrix opX=self.get_1gram_count_vector(MX,self.ops,self.OPS) opY=self.get_1gram_count_vector(MY,other.ops,self.OPS) Mcost = np.asarray([[0,0.2,MAXVAL],[0.2,0,MAXVAL],[MAXVAL,MAXVAL,0]]) # from Table 1 in https://arxiv.org/pdf/1802.07191.pdf Wd=ot.emd2(opX,opY,Mcost) return Wd def gwot_distance(self, other): # distance based on OTMANN distance adapted to cell-based search spaces # see our arxiv paper for more details row_sums = sorted(np.array(self.matrix).sum(axis=0)) col_sums = sorted(np.array(self.matrix).sum(axis=1)) other_row_sums = sorted(np.array(other.matrix).sum(axis=0)) other_col_sums = sorted(np.array(other.matrix).sum(axis=1)) row_dist = np.sum(np.abs(np.subtract(row_sums, other_row_sums))) col_dist = np.sum(np.abs(np.subtract(col_sums, other_col_sums))) counts = [self.ops.count(op) for op in self.OPS] other_counts = [other.ops.count(op) for op in self.OPS] ops_dist = np.sum(np.abs(np.subtract(counts, other_counts))) n=self.matrix.shape[0] p = ot.unif(n) q = ot.unif(n) C1=self.matrix C2=other.matrix C1=C1+1e-8 C2=C2+1e-8 C1 /= C1.max() C2 /= C2.max() #start = time.time() #gw, log = ot.gromov.entropic_gromov_wasserstein( #C1, C2, p, q, 'kl_loss', epsilon=1e-3, log=True, verbose=False) gw, log = ot.gromov.gromov_wasserstein( C1, C2, p, q, 'square_loss', log=True, verbose=False) dist1=(row_dist + col_dist + ops_dist)/(np.sum(self.matrix)+np.sum(other.matrix)) #end = time.time() #print(end - start) dist2=(log['gw_dist']-0.05)/0.4 return dist1+dist2 def gw_distance(self, other): # George Andrew D Briggs # 0.48 - 0.08 n=self.matrix.shape[0] p = ot.unif(n) q = ot.unif(n) C1=self.matrix C2=other.matrix C1=C1+1e-8 C2=C2+1e-8 C1 /= C1.max() C2 /= C2.max() #gw, log = ot.gromov.entropic_gromov_wasserstein( #C1, C2, p, q, 'square_loss', epsilon=1e-3, log=True, verbose=False) gw, log = ot.gromov.gromov_wasserstein( C1, C2, p, q, 'square_loss', log=True, verbose=False) #dist=(log['gw_dist']-0.05)/0.4 dist=(log['gw_dist']) return dist def get_1gram_count_vector(self,MX,ops,OPS): tempX=np.sum(MX,axis=1) idxRow= set(np.argwhere(tempX).ravel()) #idxRow=set(np.argwhere(tempX==0)) countX=np.sum(MX,axis=0) idxCol= set(np.argwhere(countX).ravel()) idx= list(idxRow.union(idxCol)) myops=[ops[ii] for ii in idx] opX = [myops.count(op) for op in OPS] return opX def tw_distance(self, other,lamb=0.5): MX=self.matrix MY=other.matrix #Xops=self.ops[1:-1] #Yops=other.ops[1:-1] #MX=MX[1:-1,1:-1] # crop 7x7 to 5x5 #MY=MY[1:-1,1:-1] # crop 7x7 to 5x5 # remove empty row and empty col opX=self.get_1gram_count_vector(MX,self.ops,self.OPS) opY=self.get_1gram_count_vector(MY,other.ops,self.OPS) # get layer order using shortest path layerX=shortest_path(MX,method="D") layerX[layerX==np.inf]=-1 layerX=layerX[0,:] #layerXOut=layerX[:,0] layerY=shortest_path(MY,method="D") layerY[layerY==np.inf]=-1 layerY=layerY[0,:] #layerYOut=layerY[:,0] #opX = [self.ops.count(op) for op in OPS] #opY = [other.ops.count(op) for op in OPS] return TW_NASBENCH101(MX,MY,opX,opY,layerX,layerY) def mapping_operation(self,opsrow,opscol,OPS): if opsrow==OPS[0]:# cov3x3 uu=1 if opsrow==OPS[1]:# cov 1x1 uu=2 if opsrow==OPS[2]:# max pooling uu=3 if opscol==OPS[0]:# cov3x3 index=3*uu return index if opscol==OPS[1]:#cov 1x1 index=3*uu+1 return index if opscol==OPS[2]:#max pooling index=3*uu+2 return index return -1 def count_operation_2gram(self,MX,ops): count=[0]*12 # first three dimension 1gram count[:3]=self.get_1gram_count_vector(MX,ops,self.OPS) MX=MX[1:-1,1:-1] # crop 7x7 to 5x5 ops=ops[1:-1] # remove INPUT, OUTPUT # process 9 remaining dimension for ii in range(MX.shape[0]): # each row for jj in range(MX.shape[1]): # each column if MX[ii,jj]>0: index=self.mapping_operation(ops[ii],ops[jj],self.OPS) count[index]+=1 return count def tw_2g_distance(self,other): MX=self.matrix MY=other.matrix # remove empty row #tempX=np.sum(MX,axis=1) #idx= np.argwhere(tempX).ravel() #opX=[self.ops[ii] for ii in idx] #tempY=np.sum(MY,axis=1) #idx= np.argwhere(tempY).ravel() #opY=[other.ops[ii] for ii in idx] opX = self.count_operation_2gram(MX,self.ops) opY = self.count_operation_2gram(MY,other.ops) layerX=shortest_path(MX,method="D") layerX[layerX==np.inf]=-1 layerX=layerX[0,:] #layerXOut=layerX[:,0] layerY=shortest_path(MY,method="D") layerY[layerY==np.inf]=-1 layerY=layerY[0,:] #print(opX,opY) #print(dd) return TW_2G_NB101(MX,MY,opX,opY,layerX,layerY) # return 3 elements dataset_nasbench201 = 'to_be_specified' class Cell_NB201(Cell): def set_dataset(dataset_nb201): global dataset_nasbench201 dataset_nasbench201=dataset_nb201 print('dataset for nasbench201 is ',dataset_nasbench201) def __init__(self, matrix, ops): #self.dataset='cifar100' #self.dataset='ImageNet16-120' self.dataset=dataset_nasbench201 self.matrix = matrix self.ops = ops self.matrix = matrix self.ops = ops self.INPUT = 'input' self.OUTPUT = 'output' self.CONV3X3 = 'nor_conv_3x3' self.CONV1X1 = 'nor_conv_1x1' self.AVEPOOL3X3='avg_pool_3x3' self.SKIPCONNECT='skip_connect' self.NONE='none' self.OPS = [self.CONV3X3, self.CONV1X1, self.AVEPOOL3X3,self.SKIPCONNECT,self.NONE] self.OPS_TW = [self.CONV3X3, self.CONV1X1, self.AVEPOOL3X3,self.SKIPCONNECT] #self.OPS = [self.CONV3X3, self.CONV1X1, self.AVEPOOL3X3,self.SKIPCONNECT] self.OPS_2Gram=[] self.NUM_VERTICES = 8 self.OP_SPOTS = self.NUM_VERTICES - 2 self.MAX_EDGES = 10 def serialize(self): return { 'matrix': self.matrix, 'ops': self.ops } def modelspec(self): print("not implemented") return API.ModelSpec(matrix=self.matrix, ops=self.ops) def Nas201_String_To_OpsMatrix(self,mystr): tokenCell = mystr.split("+") nOperation=8 listOperation=[0]*int(nOperation) #listOperation = cell(length(tokenCell)*(length(tokenCell)+1)/2, 1); curID = 0 listOperation[0] = 'input'; for ii in range(len(tokenCell)): tmpCell = tokenCell[ii].split('|') strimTmpCell = tmpCell[1:-1] for jj in range(len(strimTmpCell)): opTmpCell = strimTmpCell[jj].split('~') curID = curID + 1; listOperation[curID] = opTmpCell[0]; curID = curID + 1 listOperation[curID] = 'output' adjacencyMatrix = np.asarray([[0, 0, 0, 0, 0, 0, 0, 0], [1, 0, 0, 0, 0, 0, 0, 0], [1, 0, 0, 0, 0, 0, 0, 0], [0, 1, 0, 0, 0, 0, 0, 0], [1, 0, 0, 0, 0, 0, 0, 0], [0, 1, 0, 0, 0, 0, 0, 0], [0, 0, 1, 1, 0, 0, 0, 0], [0, 0, 0, 0, 1, 1, 1, 0]]) adjacencyMatrix=adjacencyMatrix.T return listOperation,adjacencyMatrix def Nas201_OpsMatrix_To_String(self,listOperation,Mat): ss = "|" + listOperation[1] + "~0|"; ss = ss + "+|" + listOperation[2] + "~0|" + listOperation[3] + "~1|"; ss = ss + "+|" + listOperation[4] + "~0|" + listOperation[5] + "~1|" + listOperation[6] + "~2|"; return ss def is_valid(self): return 1 @classmethod def random_cell(cls, nasbench): """ From the NASBench repository https://github.com/google-research/nasbench """ INPUT = 'input' OUTPUT = 'output' CONV3X3 = 'nor_conv_3x3' CONV1X1 = 'nor_conv_1x1' AVEPOOL3X3='avg_pool_3x3' SKIPCONNECT='skip_connect' NONE='none' OPS = [CONV3X3, CONV1X1, AVEPOOL3X3,SKIPCONNECT,NONE] #OPS_2Gram=[] NUM_VERTICES = 8 #OP_SPOTS = NUM_VERTICES - 2 #MAX_EDGES = 10 matrix = np.random.choice( [0, 1], size=(NUM_VERTICES, NUM_VERTICES)) matrix = np.triu(matrix, 1) ops = np.random.choice(OPS, size=NUM_VERTICES).tolist() ops[0] = INPUT ops[-1] = OUTPUT return { 'matrix': matrix, 'ops': ops} def get_val_loss(self, nasbench): # output one of the three validation accuracies at random #return (100*(1 - nasbench.query(api.ModelSpec(matrix=self.matrix, ops=self.ops))['validation_accuracy'])) # get index based on the matrix and operation ss_query=self.Nas201_OpsMatrix_To_String(self.ops,self.matrix) index = nasbench.query_index_by_arch(ss_query) #mystr="|avg_pool_3x3~0|+|nor_conv_3x3~0|nor_conv_3x3~1|+|none~0|nor_conv_3x3~1|none~2|" #index = nasbench.query_index_by_arch(mystr) results = nasbench.query_by_index(index, self.dataset) # a dict of all trials for 1st net on cifar100, where the key is the seed #results=results[888] results=results[111] try: accuracy=np.round(results.get_eval('x-valid')['accuracy'],decimals=4) except: #print(ss_query) accuracy=np.round(results.get_eval('ori-test')['accuracy'],decimals=4) return 100-accuracy def get_test_loss(self, nasbench, patience=50): """ query the api until we see all three accuracies, then average them a few architectures only have two accuracies, so we use patience to avoid an infinite loop """ ss_query=self.Nas201_OpsMatrix_To_String(self.ops,self.matrix) index = nasbench.query_index_by_arch(ss_query) results = nasbench.query_by_index(index, self.dataset) # a dict of all trials for 1st net on cifar100, where the key is the seed #results=results[888] results=results[111] try: accuracy=np.round(results.get_eval('x-test')['accuracy'],decimals=4) except: #print(ss_query) accuracy=np.round(results.get_eval('ori-test')['accuracy'],decimals=4) return 100-accuracy def perturb(self, nasbench, edits=1): """ create new perturbed cell inspird by https://github.com/google-research/nasbench """ new_matrix = copy.deepcopy(self.matrix) new_ops = copy.deepcopy(self.ops) for _ in range(edits): while True: if np.random.random() < 0.5: for src in range(0, self.NUM_VERTICES - 1): for dst in range(src+1, self.NUM_VERTICES): new_matrix[src][dst] = 1 - new_matrix[src][dst] else: for ind in range(1, self.NUM_VERTICES - 1): available = [op for op in self.OPS if op != new_ops[ind]] new_ops[ind] = np.random.choice(available) new_spec = API.ModelSpec(new_matrix, new_ops) if nasbench.is_valid(new_spec): break return { 'matrix': new_matrix, 'ops': new_ops } def mutate(self, nasbench, mutation_rate=1.0): """ similar to perturb. A stochastic approach to perturbing the cell inspird by https://github.com/google-research/nasbench """ while True: new_matrix = copy.deepcopy(self.matrix) new_ops = copy.deepcopy(self.ops) edge_mutation_prob = mutation_rate / self.NUM_VERTICES for src in range(0, self.NUM_VERTICES - 1): for dst in range(src + 1, self.NUM_VERTICES): if random.random() < edge_mutation_prob: new_matrix[src, dst] = 1 - new_matrix[src, dst] op_mutation_prob = mutation_rate / self.OP_SPOTS for ind in range(1, self.OP_SPOTS + 1): if random.random() < op_mutation_prob: available = [o for o in self.OPS if o != new_ops[ind]] new_ops[ind] = random.choice(available) return { 'matrix': new_matrix, 'ops': new_ops } def encode_cell(self): """ compute the "standard" encoding, i.e. adjacency matrix + op list encoding """ encoding_length = (self.NUM_VERTICES ** 2 - self.NUM_VERTICES) // 2 + self.OP_SPOTS encoding = np.zeros((encoding_length)) dic = {self.CONV3X3: 0, self.CONV1X1: 1, self.AVEPOOL3X3: 2, self.SKIPCONNECT:3, self.NONE:4} n = 0 for i in range(self.NUM_VERTICES - 1): for j in range(i+1, self.NUM_VERTICES): encoding[n] = self.matrix[i][j] n += 1 for i in range(1, self.NUM_VERTICES - 1): encoding[-i] = dic[self.ops[i]] return tuple(encoding) def get_paths(self): """ return all paths from input to output """ paths = [] for j in range(0, self.NUM_VERTICES): paths.append([[]]) if self.matrix[0][j] else paths.append([]) # create paths sequentially for i in range(1, self.NUM_VERTICES - 1): for j in range(1, self.NUM_VERTICES): if self.matrix[i][j]: for path in paths[i]: paths[j].append([*path, self.ops[i]]) return paths[-1] def get_path_indices(self): """ compute the index of each path There are 3^0 + ... + 3^5 paths total. (Paths can be length 0 to 5, and for each path, for each node, there are three choices for the operation.) """ paths = self.get_paths() mapping = {self.CONV3X3: 0, self.CONV1X1: 1, self.AVEPOOL3X3: 2, self.SKIPCONNECT:3,self.NONE:4} path_indices = [] for path in paths: index = 0 for i in range(self.NUM_VERTICES - 1): if i == len(path): path_indices.append(index) break else: index += len(self.OPS) ** i * (mapping[path[i]] + 1) return tuple(path_indices) def encode_paths(self): """ output one-hot encoding of paths """ num_paths = sum([len(self.OPS) ** i for i in range(self.OP_SPOTS + 1)]) path_indices = self.get_path_indices() path_encoding = np.zeros(num_paths) try: for index in path_indices: path_encoding[index] = 1 except: print("bug") for index in path_indices: path_encoding[index] = 1 return path_encoding def path_distance(self, other): """ compute the distance between two architectures by comparing their path encodings """ return np.sum(np.array(self.encode_paths() != np.array(other.encode_paths()))) def edit_distance(self, other): return super(Cell_NB201, self).edit_distance(other) def nasbot_distance(self, other): return super(Cell_NB201, self).nasbot_distance(other) def ot_distance(self, other): # distance based on OTMANN distance adapted to cell-based search spaces # see our arxiv paper for more details MAXVAL = 10000; MX=self.matrix MY=other.matrix opX=super(Cell_NB201, self).get_1gram_count_vector(MX,self.ops,self.OPS_TW) opY=super(Cell_NB201, self).get_1gram_count_vector(MY,other.ops,self.OPS_TW) Mcost = np.asarray([[0,0.2,MAXVAL],[0.2,0,MAXVAL],[MAXVAL,MAXVAL,0]]) # from Table 1 in https://arxiv.org/pdf/1802.07191.pdf Wd=ot.emd2(opX,opY,Mcost) return Wd def gw_distance(self, other): return super(Cell_NB201, self).gw_distance(other) #def get_1gram_count_vector(self,MX,ops): #return super(Cell_NB201, self).get_1gram_count_vector(MX,ops) def tw_distance(self, other,lamb=0.5): MX=self.matrix MY=other.matrix #Xops=self.ops[1:-1] #Yops=other.ops[1:-1] #MX=MX[1:-1,1:-1] # crop 7x7 to 5x5 #MY=MY[1:-1,1:-1] # crop 7x7 to 5x5 # remove empty row and empty col opX=self.get_1gram_count_vector(MX,self.ops,self.OPS_TW) opY=self.get_1gram_count_vector(MY,other.ops,self.OPS_TW) #opX = [self.ops.count(op) for op in OPS] #opY = [other.ops.count(op) for op in OPS] layerX=shortest_path(MX,method="D") layerX[layerX==np.inf]=-1 layerX=layerX[0,:] #layerXOut=layerX[:,0] layerY=shortest_path(MY,method="D") layerY[layerY==np.inf]=-1 layerY=layerY[0,:] return TW_NASBENCH201(MX, MY, opX, opY, layerX,layerY) def mapping_operation(self,opsrow,opscol,OPS): if opsrow==OPS[0]:# cov3x3 uu=1 if opsrow==OPS[1]:# cov 1x1 uu=2 if opsrow==OPS[2]:# ave pooling uu=3 if opsrow==OPS[3]:# skip connect uu=4 if opscol==OPS[0]:# cov3x3 index=4*uu return index if opscol==OPS[1]:#cov 1x1 index=4*uu+1 return index if opscol==OPS[2]:#ave pooling index=4*uu+2 return index if opscol==OPS[3]:#skip connect index=4*uu+3 return index return -1 def count_operation_2gram(self,MX,ops): count=[0]*20 # first three dimension 1gram count[:4]=self.get_1gram_count_vector(MX,ops,self.OPS_TW) # remove None MX=MX[1:-1,1:-1] # crop 7x7 to 5x5 ops=ops[1:-1] # remove INPUT, OUTPUT idx=[ii for ii, val in enumerate(ops) if val in self.OPS_TW] temp=MX[idx,:] MX=temp[:,idx] ops = [ops[ii] for ii in idx] #ops=ops[idx] # process 9 remaining dimension for ii in range(MX.shape[0]): # each row for jj in range(MX.shape[1]): # each column if MX[ii,jj]>0: index=self.mapping_operation(ops[ii],ops[jj],self.OPS_TW) count[index]+=1 return count # def tw_2gram_distance(self,other,lamb=0.5): # return super(Cell_NB201, self).tw_2gram_distance(other,lamb) def tw_2g_distance(self,other): MX=self.matrix MY=other.matrix # remove empty row #tempX=np.sum(MX,axis=1) #idx= np.argwhere(tempX).ravel() #opX=[self.ops[ii] for ii in idx] #tempY=np.sum(MY,axis=1) #idx= np.argwhere(tempY).ravel() #opY=[other.ops[ii] for ii in idx] opX = self.count_operation_2gram(MX,self.ops) opY = self.count_operation_2gram(MY,other.ops) layerX=shortest_path(MX,method="D") layerX[layerX==np.inf]=-1 layerX=layerX[0,:] #layerXOut=layerX[:,0] layerY=shortest_path(MY,method="D") layerY[layerY==np.inf]=-1 layerY=layerY[0,:] return TW_2G_NB201(MX,MY,opX,opY,layerX,layerY) # return 3 elements
33.629291
136
0.547462
3,829
29,392
4.087229
0.095586
0.028179
0.007476
0.008179
0.835911
0.815911
0.797508
0.776997
0.737061
0.719233
0
0.043028
0.335806
29,392
874
137
33.629291
0.758631
0.181036
0
0.696629
0
0
0.023957
0
0
0
0
0
0
1
0.088015
false
0
0.016854
0.013109
0.20412
0.005618
0
0
0
null
0
0
0
1
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
6
04ab597c11ecf11c46bef12dc7c165f7ca2b4157
277
py
Python
TradovatePy/config.py
antonio-hickey/TradovatePy
fe7a917a49d291bd42585f4cd0268fe223923ecf
[ "MIT" ]
2
2022-01-17T03:20:41.000Z
2022-03-23T02:21:52.000Z
TradovatePy/config.py
antonio-hickey/TradovatePy
fe7a917a49d291bd42585f4cd0268fe223923ecf
[ "MIT" ]
null
null
null
TradovatePy/config.py
antonio-hickey/TradovatePy
fe7a917a49d291bd42585f4cd0268fe223923ecf
[ "MIT" ]
null
null
null
URLs = { "DEMO": "https://demo.tradovateapi.com/v1", "LIVE": "https://live.tradovateapi.com/v1", "MD": "wss://md.tradovateapi.com/v1/websocket", "WS_DEMO": "wss://demo.tradovateapi.com/v1/websocket", "WS_LIVE": "wss://live.tradovateapi.com/v1/websocket", }
34.625
58
0.638989
36
277
4.861111
0.305556
0.428571
0.485714
0.445714
0.32
0
0
0
0
0
0
0.020576
0.122744
277
7
59
39.571429
0.699588
0
0
0
0
0
0.743682
0.425993
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
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
6
04b5594286e21ce09c40aadef5825b36606c4165
27
py
Python
Author/tests/__init__.py
CMPUT404-Fa21-Organization/CMPUT404-Project-Social-Distribution
63c0ba2a03f0b462e3673ce7a4bf6bae7999440c
[ "Apache-2.0" ]
3
2021-12-11T13:43:56.000Z
2022-03-31T02:36:05.000Z
Author/tests/__init__.py
CMPUT404-Fa21-Organization/CMPUT404-Project-Social-Distribution
63c0ba2a03f0b462e3673ce7a4bf6bae7999440c
[ "Apache-2.0" ]
9
2021-10-01T22:46:57.000Z
2021-12-16T18:01:31.000Z
Author/tests/__init__.py
CMPUT404-Fa21-Organization/CMPUT404-Project-Social-Distribution
63c0ba2a03f0b462e3673ce7a4bf6bae7999440c
[ "Apache-2.0" ]
2
2021-12-16T16:37:10.000Z
2021-12-16T20:30:12.000Z
from .test_author import *
13.5
26
0.777778
4
27
5
1
0
0
0
0
0
0
0
0
0
0
0
0.148148
27
1
27
27
0.869565
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
1
0
0
6
6d35d2449e02d409eeff6e3e01beb2778ffe0222
120
py
Python
pybankreader/formats/__init__.py
baldman/pybankreader
3a96d6c89e408a315ccb4f7e7a3c63325c347d2d
[ "BSD-3-Clause" ]
1
2022-03-29T14:09:41.000Z
2022-03-29T14:09:41.000Z
pybankreader/formats/__init__.py
baldman/pybankreader
3a96d6c89e408a315ccb4f7e7a3c63325c347d2d
[ "BSD-3-Clause" ]
null
null
null
pybankreader/formats/__init__.py
baldman/pybankreader
3a96d6c89e408a315ccb4f7e7a3c63325c347d2d
[ "BSD-3-Clause" ]
null
null
null
from .bbf.reports import AdvmulReport as BBFAdvmul # NOQA from .gpc.reports import AccountReport as GPCAccount # NOQA
40
60
0.8
16
120
6
0.6875
0.270833
0
0
0
0
0
0
0
0
0
0
0.15
120
2
61
60
0.941176
0.075
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
1
0
0
6
6d602b53f1d0aa49db96d15dfc23e57df4676a19
128
py
Python
base/model/__init__.py
stevenchen521/quant_ml
f7d5efc49c934724f97fcafacc560f4a35b24551
[ "MIT" ]
5
2019-02-14T03:12:22.000Z
2022-01-24T18:43:07.000Z
base/model/__init__.py
stevenchen521/quant_ml
f7d5efc49c934724f97fcafacc560f4a35b24551
[ "MIT" ]
null
null
null
base/model/__init__.py
stevenchen521/quant_ml
f7d5efc49c934724f97fcafacc560f4a35b24551
[ "MIT" ]
2
2019-11-13T18:56:13.000Z
2021-12-31T01:25:22.000Z
import mongoengine mongoengine.connect(db="doricapital", host="localhost") # mongoengine.connect(db="Mongo", host="doricapital")
42.666667
55
0.789063
14
128
7.214286
0.571429
0.356436
0.39604
0
0
0
0
0
0
0
0
0
0.046875
128
3
56
42.666667
0.827869
0.398438
0
0
0
0
0.263158
0
0
0
0
0
0
1
0
true
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
1
0
1
0
0
0
0
6
eda07dec9154f18254f30d2fcac734310c5a71db
23,175
py
Python
alembic/versions/6a16d2aa6b6a_add_huawei_4g_managedobjects.py
bodastage/bts-database
96df7915621dd46daf55016eedf5cfc84dd0e3a2
[ "Apache-2.0" ]
1
2019-08-30T01:20:14.000Z
2019-08-30T01:20:14.000Z
alembic/versions/6a16d2aa6b6a_add_huawei_4g_managedobjects.py
bodastage/bts-database
96df7915621dd46daf55016eedf5cfc84dd0e3a2
[ "Apache-2.0" ]
1
2018-05-30T09:29:24.000Z
2018-05-30T10:04:37.000Z
alembic/versions/6a16d2aa6b6a_add_huawei_4g_managedobjects.py
bodastage/bts-database
96df7915621dd46daf55016eedf5cfc84dd0e3a2
[ "Apache-2.0" ]
3
2018-03-10T23:29:30.000Z
2019-02-19T22:11:09.000Z
"""Add Huawei 4G managedobjects Revision ID: 6a16d2aa6b6a Revises: 805d9d91ef77 Create Date: 2018-02-13 01:44:09.030000 """ from alembic import op import sqlalchemy as sa import datetime # revision identifiers, used by Alembic. revision = '6a16d2aa6b6a' down_revision = '805d9d91ef77' branch_labels = None depends_on = None def upgrade(): managedobjects = sa.sql.table( 'managedobjects', sa.Column('pk', sa.Integer, sa.Sequence('seq_managedobjects_pk', ), primary_key=True, nullable=False), sa.Column('name', sa.String(50), nullable=False), sa.Column('notes', sa.Text), sa.Column('label', sa.String(200)), sa.Column('parent_pk', sa.Integer), sa.Column('tech_pk', sa.Integer), sa.Column('vendor_pk', sa.Integer), sa.Column('modified_by', sa.Integer), sa.Column('added_by', sa.Integer), sa.Column('date_added', sa.TIMESTAMP, default=datetime.datetime.utcnow, onupdate=datetime.datetime.utcnow), sa.Column('date_modified', sa.TIMESTAMP, default=datetime.datetime.utcnow) ) op.bulk_insert(managedobjects, [ {'name': 'ALGODEFAULTPARA', 'parent_pk': 0, 'vendor_pk': 2, 'tech_pk': 3, 'modified_by': 0, 'added_by': 0}, {'name': 'ANR', 'parent_pk': 0, 'vendor_pk': 2, 'tech_pk': 3, 'modified_by': 0, 'added_by': 0}, {'name': 'APPCERT', 'parent_pk': 0, 'vendor_pk': 2, 'tech_pk': 3, 'modified_by': 0, 'added_by': 0}, {'name': 'BASEBANDEQM', 'parent_pk': 0, 'vendor_pk': 2, 'tech_pk': 3, 'modified_by': 0, 'added_by': 0}, {'name': 'BASEBANDEQMBOARDREF', 'parent_pk': 0, 'vendor_pk': 2, 'tech_pk': 3, 'modified_by': 0, 'added_by': 0}, {'name': 'BCCHCFG', 'parent_pk': 0, 'vendor_pk': 2, 'tech_pk': 3, 'modified_by': 0, 'added_by': 0}, {'name': 'BFMIMOADAPTIVEPARACFG', 'parent_pk': 0, 'vendor_pk': 2, 'tech_pk': 3, 'modified_by': 0, 'added_by': 0}, {'name': 'CAMGTCFG', 'parent_pk': 0, 'vendor_pk': 2, 'tech_pk': 3, 'modified_by': 0, 'added_by': 0}, {'name': 'CELL', 'parent_pk': 0, 'vendor_pk': 2, 'tech_pk': 3, 'modified_by': 0, 'added_by': 0}, {'name': 'CELLACBAR', 'parent_pk': 0, 'vendor_pk': 2, 'tech_pk': 3, 'modified_by': 0, 'added_by': 0}, {'name': 'CELLACCESS', 'parent_pk': 0, 'vendor_pk': 2, 'tech_pk': 3, 'modified_by': 0, 'added_by': 0}, {'name': 'CELLALGOSWITCH', 'parent_pk': 0, 'vendor_pk': 2, 'tech_pk': 3, 'modified_by': 0, 'added_by': 0}, {'name': 'CELLBF', 'parent_pk': 0, 'vendor_pk': 2, 'tech_pk': 3, 'modified_by': 0, 'added_by': 0}, {'name': 'CELLBFMIMOPARACFG', 'parent_pk': 0, 'vendor_pk': 2, 'tech_pk': 3, 'modified_by': 0, 'added_by': 0}, {'name': 'CELLCHPWRCFG', 'parent_pk': 0, 'vendor_pk': 2, 'tech_pk': 3, 'modified_by': 0, 'added_by': 0}, {'name': 'CELLCSPCPARA', 'parent_pk': 0, 'vendor_pk': 2, 'tech_pk': 3, 'modified_by': 0, 'added_by': 0}, {'name': 'CELLDLCOMPALGO', 'parent_pk': 0, 'vendor_pk': 2, 'tech_pk': 3, 'modified_by': 0, 'added_by': 0}, {'name': 'CELLDLICIC', 'parent_pk': 0, 'vendor_pk': 2, 'tech_pk': 3, 'modified_by': 0, 'added_by': 0}, {'name': 'CELLDLICICMCPARA', 'parent_pk': 0, 'vendor_pk': 2, 'tech_pk': 3, 'modified_by': 0, 'added_by': 0}, {'name': 'CELLDLPCPDCCH', 'parent_pk': 0, 'vendor_pk': 2, 'tech_pk': 3, 'modified_by': 0, 'added_by': 0}, {'name': 'CELLDLPCPDSCH', 'parent_pk': 0, 'vendor_pk': 2, 'tech_pk': 3, 'modified_by': 0, 'added_by': 0}, {'name': 'CELLDLPCPDSCHPA', 'parent_pk': 0, 'vendor_pk': 2, 'tech_pk': 3, 'modified_by': 0, 'added_by': 0}, {'name': 'CELLDLPCPHICH', 'parent_pk': 0, 'vendor_pk': 2, 'tech_pk': 3, 'modified_by': 0, 'added_by': 0}, {'name': 'CELLDLSCHALGO', 'parent_pk': 0, 'vendor_pk': 2, 'tech_pk': 3, 'modified_by': 0, 'added_by': 0}, {'name': 'CELLDRXPARA', 'parent_pk': 0, 'vendor_pk': 2, 'tech_pk': 3, 'modified_by': 0, 'added_by': 0}, {'name': 'CELLDSS', 'parent_pk': 0, 'vendor_pk': 2, 'tech_pk': 3, 'modified_by': 0, 'added_by': 0}, {'name': 'CELLDYNACBARALGOPARA', 'parent_pk': 0, 'vendor_pk': 2, 'tech_pk': 3, 'modified_by': 0, 'added_by': 0}, {'name': 'CELLHOPARACFG', 'parent_pk': 0, 'vendor_pk': 2, 'tech_pk': 3, 'modified_by': 0, 'added_by': 0}, {'name': 'CELLIDPRDUPT', 'parent_pk': 0, 'vendor_pk': 2, 'tech_pk': 3, 'modified_by': 0, 'added_by': 0}, {'name': 'CELLLOWPOWER', 'parent_pk': 0, 'vendor_pk': 2, 'tech_pk': 3, 'modified_by': 0, 'added_by': 0}, {'name': 'CELLMBMSCFG', 'parent_pk': 0, 'vendor_pk': 2, 'tech_pk': 3, 'modified_by': 0, 'added_by': 0}, {'name': 'CELLMCPARA', 'parent_pk': 0, 'vendor_pk': 2, 'tech_pk': 3, 'modified_by': 0, 'added_by': 0}, {'name': 'CELLMIMOPARACFG', 'parent_pk': 0, 'vendor_pk': 2, 'tech_pk': 3, 'modified_by': 0, 'added_by': 0}, {'name': 'CELLMLB', 'parent_pk': 0, 'vendor_pk': 2, 'tech_pk': 3, 'modified_by': 0, 'added_by': 0}, {'name': 'CELLMLBHO', 'parent_pk': 0, 'vendor_pk': 2, 'tech_pk': 3, 'modified_by': 0, 'added_by': 0}, {'name': 'CELLMRO', 'parent_pk': 0, 'vendor_pk': 2, 'tech_pk': 3, 'modified_by': 0, 'added_by': 0}, {'name': 'CELLNOACCESSALMPARA', 'parent_pk': 0, 'vendor_pk': 2, 'tech_pk': 3, 'modified_by': 0, 'added_by': 0}, {'name': 'CELLOP', 'parent_pk': 0, 'vendor_pk': 2, 'tech_pk': 3, 'modified_by': 0, 'added_by': 0}, {'name': 'CELLPCALGO', 'parent_pk': 0, 'vendor_pk': 2, 'tech_pk': 3, 'modified_by': 0, 'added_by': 0}, {'name': 'CELLPDCCHALGO', 'parent_pk': 0, 'vendor_pk': 2, 'tech_pk': 3, 'modified_by': 0, 'added_by': 0}, {'name': 'CELLPUCCHALGO', 'parent_pk': 0, 'vendor_pk': 2, 'tech_pk': 3, 'modified_by': 0, 'added_by': 0}, {'name': 'CELLRACHALGO', 'parent_pk': 0, 'vendor_pk': 2, 'tech_pk': 3, 'modified_by': 0, 'added_by': 0}, {'name': 'CELLRACTHD', 'parent_pk': 0, 'vendor_pk': 2, 'tech_pk': 3, 'modified_by': 0, 'added_by': 0}, {'name': 'CELLRESEL', 'parent_pk': 0, 'vendor_pk': 2, 'tech_pk': 3, 'modified_by': 0, 'added_by': 0}, {'name': 'CELLRESELGERAN', 'parent_pk': 0, 'vendor_pk': 2, 'tech_pk': 3, 'modified_by': 0, 'added_by': 0}, {'name': 'CELLRESELUTRAN', 'parent_pk': 0, 'vendor_pk': 2, 'tech_pk': 3, 'modified_by': 0, 'added_by': 0}, {'name': 'CELLRFSHUTDOWN', 'parent_pk': 0, 'vendor_pk': 2, 'tech_pk': 3, 'modified_by': 0, 'added_by': 0}, {'name': 'CELLRICALGO', 'parent_pk': 0, 'vendor_pk': 2, 'tech_pk': 3, 'modified_by': 0, 'added_by': 0}, {'name': 'CELLSEL', 'parent_pk': 0, 'vendor_pk': 2, 'tech_pk': 3, 'modified_by': 0, 'added_by': 0}, {'name': 'CELLSERVICEDIFFCFG', 'parent_pk': 0, 'vendor_pk': 2, 'tech_pk': 3, 'modified_by': 0, 'added_by': 0}, {'name': 'CELLSHUTDOWN', 'parent_pk': 0, 'vendor_pk': 2, 'tech_pk': 3, 'modified_by': 0, 'added_by': 0}, {'name': 'CELLSIMAP', 'parent_pk': 0, 'vendor_pk': 2, 'tech_pk': 3, 'modified_by': 0, 'added_by': 0}, {'name': 'CELLSTANDARDQCI', 'parent_pk': 0, 'vendor_pk': 2, 'tech_pk': 3, 'modified_by': 0, 'added_by': 0}, {'name': 'CELLULCOMPALGO', 'parent_pk': 0, 'vendor_pk': 2, 'tech_pk': 3, 'modified_by': 0, 'added_by': 0}, {'name': 'CELLULICIC', 'parent_pk': 0, 'vendor_pk': 2, 'tech_pk': 3, 'modified_by': 0, 'added_by': 0}, {'name': 'CELLULICICMCPARA', 'parent_pk': 0, 'vendor_pk': 2, 'tech_pk': 3, 'modified_by': 0, 'added_by': 0}, {'name': 'CELLULPCCOMM', 'parent_pk': 0, 'vendor_pk': 2, 'tech_pk': 3, 'modified_by': 0, 'added_by': 0}, {'name': 'CELLULPCDEDIC', 'parent_pk': 0, 'vendor_pk': 2, 'tech_pk': 3, 'modified_by': 0, 'added_by': 0}, {'name': 'CELLULSCHALGO', 'parent_pk': 0, 'vendor_pk': 2, 'tech_pk': 3, 'modified_by': 0, 'added_by': 0}, {'name': 'CERTCHKTSK', 'parent_pk': 0, 'vendor_pk': 2, 'tech_pk': 3, 'modified_by': 0, 'added_by': 0}, {'name': 'CERTDEPLOY', 'parent_pk': 0, 'vendor_pk': 2, 'tech_pk': 3, 'modified_by': 0, 'added_by': 0}, {'name': 'CERTMK', 'parent_pk': 0, 'vendor_pk': 2, 'tech_pk': 3, 'modified_by': 0, 'added_by': 0}, {'name': 'CERTREQ', 'parent_pk': 0, 'vendor_pk': 2, 'tech_pk': 3, 'modified_by': 0, 'added_by': 0}, {'name': 'CNOPERATOR', 'parent_pk': 0, 'vendor_pk': 2, 'tech_pk': 3, 'modified_by': 0, 'added_by': 0}, {'name': 'CNOPERATORHOCFG', 'parent_pk': 0, 'vendor_pk': 2, 'tech_pk': 3, 'modified_by': 0, 'added_by': 0}, {'name': 'CNOPERATORIPPATH', 'parent_pk': 0, 'vendor_pk': 2, 'tech_pk': 3, 'modified_by': 0, 'added_by': 0}, {'name': 'CNOPERATORSTANDARDQCI', 'parent_pk': 0, 'vendor_pk': 2, 'tech_pk': 3, 'modified_by': 0, 'added_by': 0}, {'name': 'CNOPERATORTA', 'parent_pk': 0, 'vendor_pk': 2, 'tech_pk': 3, 'modified_by': 0, 'added_by': 0}, {'name': 'COUNTERCHECKPARA', 'parent_pk': 0, 'vendor_pk': 2, 'tech_pk': 3, 'modified_by': 0, 'added_by': 0}, {'name': 'CPBEARER', 'parent_pk': 0, 'vendor_pk': 2, 'tech_pk': 3, 'modified_by': 0, 'added_by': 0}, {'name': 'CQIADAPTIVECFG', 'parent_pk': 0, 'vendor_pk': 2, 'tech_pk': 3, 'modified_by': 0, 'added_by': 0}, {'name': 'CRLPOLICY', 'parent_pk': 0, 'vendor_pk': 2, 'tech_pk': 3, 'modified_by': 0, 'added_by': 0}, {'name': 'CSFALLBACKBLINDHOCFG', 'parent_pk': 0, 'vendor_pk': 2, 'tech_pk': 3, 'modified_by': 0, 'added_by': 0}, {'name': 'CSFALLBACKHO', 'parent_pk': 0, 'vendor_pk': 2, 'tech_pk': 3, 'modified_by': 0, 'added_by': 0}, {'name': 'CSFALLBACKPOLICYCFG', 'parent_pk': 0, 'vendor_pk': 2, 'tech_pk': 3, 'modified_by': 0, 'added_by': 0}, {'name': 'CSPCALGOPARA', 'parent_pk': 0, 'vendor_pk': 2, 'tech_pk': 3, 'modified_by': 0, 'added_by': 0}, {'name': 'DEVIP', 'parent_pk': 0, 'vendor_pk': 2, 'tech_pk': 3, 'modified_by': 0, 'added_by': 0}, {'name': 'DHCPRELAYSWITCH', 'parent_pk': 0, 'vendor_pk': 2, 'tech_pk': 3, 'modified_by': 0, 'added_by': 0}, {'name': 'DIFPRI', 'parent_pk': 0, 'vendor_pk': 2, 'tech_pk': 3, 'modified_by': 0, 'added_by': 0}, {'name': 'DISTBASEDHO', 'parent_pk': 0, 'vendor_pk': 2, 'tech_pk': 3, 'modified_by': 0, 'added_by': 0}, {'name': 'DRX', 'parent_pk': 0, 'vendor_pk': 2, 'tech_pk': 3, 'modified_by': 0, 'added_by': 0}, {'name': 'DRXPARAGROUP', 'parent_pk': 0, 'vendor_pk': 2, 'tech_pk': 3, 'modified_by': 0, 'added_by': 0}, {'name': 'DSCPMAP', 'parent_pk': 0, 'vendor_pk': 2, 'tech_pk': 3, 'modified_by': 0, 'added_by': 0}, {'name': 'EMC', 'parent_pk': 0, 'vendor_pk': 2, 'tech_pk': 3, 'modified_by': 0, 'added_by': 0}, {'name': 'ENODEBALGOSWITCH', 'parent_pk': 0, 'vendor_pk': 2, 'tech_pk': 3, 'modified_by': 0, 'added_by': 0}, {'name': 'ENODEBAUTOPOWEROFF', 'parent_pk': 0, 'vendor_pk': 2, 'tech_pk': 3, 'modified_by': 0, 'added_by': 0}, {'name': 'ENODEBCIPHERCAP', 'parent_pk': 0, 'vendor_pk': 2, 'tech_pk': 3, 'modified_by': 0, 'added_by': 0}, {'name': 'ENODEBCONNSTATETIMER', 'parent_pk': 0, 'vendor_pk': 2, 'tech_pk': 3, 'modified_by': 0, 'added_by': 0}, {'name': 'ENODEBFUNCTION', 'parent_pk': 0, 'vendor_pk': 2, 'tech_pk': 3, 'modified_by': 0, 'added_by': 0}, {'name': 'ENODEBINTEGRITYCAP', 'parent_pk': 0, 'vendor_pk': 2, 'tech_pk': 3, 'modified_by': 0, 'added_by': 0}, {'name': 'ENODEBMLB', 'parent_pk': 0, 'vendor_pk': 2, 'tech_pk': 3, 'modified_by': 0, 'added_by': 0}, {'name': 'ENODEBPATH', 'parent_pk': 0, 'vendor_pk': 2, 'tech_pk': 3, 'modified_by': 0, 'added_by': 0}, {'name': 'ENODEBSHARINGMODE', 'parent_pk': 0, 'vendor_pk': 2, 'tech_pk': 3, 'modified_by': 0, 'added_by': 0}, {'name': 'EPGROUP', 'parent_pk': 0, 'vendor_pk': 2, 'tech_pk': 3, 'modified_by': 0, 'added_by': 0}, {'name': 'ETHPORT', 'parent_pk': 0, 'vendor_pk': 2, 'tech_pk': 3, 'modified_by': 0, 'added_by': 0}, {'name': 'EUCELLSECTOREQM', 'parent_pk': 0, 'vendor_pk': 2, 'tech_pk': 3, 'modified_by': 0, 'added_by': 0}, {'name': 'EUCOSCHCFG', 'parent_pk': 0, 'vendor_pk': 2, 'tech_pk': 3, 'modified_by': 0, 'added_by': 0}, {'name': 'EUTRANEXTERNALCELL', 'parent_pk': 0, 'vendor_pk': 2, 'tech_pk': 3, 'modified_by': 0, 'added_by': 0}, {'name': 'EUTRANINTRAFREQNCELL', 'parent_pk': 0, 'vendor_pk': 2, 'tech_pk': 3, 'modified_by': 0, 'added_by': 0}, {'name': 'FDDRESMODE', 'parent_pk': 0, 'vendor_pk': 2, 'tech_pk': 3, 'modified_by': 0, 'added_by': 0}, {'name': 'filefooter', 'parent_pk': 0, 'vendor_pk': 2, 'tech_pk': 3, 'modified_by': 0, 'added_by': 0}, {'name': 'GERANEXTERNALCELL', 'parent_pk': 0, 'vendor_pk': 2, 'tech_pk': 3, 'modified_by': 0, 'added_by': 0}, {'name': 'GERANINTERFCFG', 'parent_pk': 0, 'vendor_pk': 2, 'tech_pk': 3, 'modified_by': 0, 'added_by': 0}, {'name': 'GERANNCELL', 'parent_pk': 0, 'vendor_pk': 2, 'tech_pk': 3, 'modified_by': 0, 'added_by': 0}, {'name': 'GERANNFREQGROUP', 'parent_pk': 0, 'vendor_pk': 2, 'tech_pk': 3, 'modified_by': 0, 'added_by': 0}, {'name': 'GERANNFREQGROUPARFCN', 'parent_pk': 0, 'vendor_pk': 2, 'tech_pk': 3, 'modified_by': 0, 'added_by': 0}, {'name': 'GLOBALPROCSWITCH', 'parent_pk': 0, 'vendor_pk': 2, 'tech_pk': 3, 'modified_by': 0, 'added_by': 0}, {'name': 'GTPU', 'parent_pk': 0, 'vendor_pk': 2, 'tech_pk': 3, 'modified_by': 0, 'added_by': 0}, {'name': 'GTRANSPARA', 'parent_pk': 0, 'vendor_pk': 2, 'tech_pk': 3, 'modified_by': 0, 'added_by': 0}, {'name': 'HOMEASCOMM', 'parent_pk': 0, 'vendor_pk': 2, 'tech_pk': 3, 'modified_by': 0, 'added_by': 0}, {'name': 'IKECFG', 'parent_pk': 0, 'vendor_pk': 2, 'tech_pk': 3, 'modified_by': 0, 'added_by': 0}, {'name': 'INTERFREQHOGROUP', 'parent_pk': 0, 'vendor_pk': 2, 'tech_pk': 3, 'modified_by': 0, 'added_by': 0}, {'name': 'INTERRATCELLSHUTDOWN', 'parent_pk': 0, 'vendor_pk': 2, 'tech_pk': 3, 'modified_by': 0, 'added_by': 0}, {'name': 'INTERRATHOCDMA1XRTTGROUP', 'parent_pk': 0, 'vendor_pk': 2, 'tech_pk': 3, 'modified_by': 0, 'added_by': 0}, {'name': 'INTERRATHOCDMAHRPDGROUP', 'parent_pk': 0, 'vendor_pk': 2, 'tech_pk': 3, 'modified_by': 0, 'added_by': 0}, {'name': 'INTERRATHOCOMM', 'parent_pk': 0, 'vendor_pk': 2, 'tech_pk': 3, 'modified_by': 0, 'added_by': 0}, {'name': 'INTERRATHOCOMMGROUP', 'parent_pk': 0, 'vendor_pk': 2, 'tech_pk': 3, 'modified_by': 0, 'added_by': 0}, {'name': 'INTERRATHOGERANGROUP', 'parent_pk': 0, 'vendor_pk': 2, 'tech_pk': 3, 'modified_by': 0, 'added_by': 0}, {'name': 'INTERRATHOUTRANGROUP', 'parent_pk': 0, 'vendor_pk': 2, 'tech_pk': 3, 'modified_by': 0, 'added_by': 0}, {'name': 'INTERRATPOLICYCFGGROUP', 'parent_pk': 0, 'vendor_pk': 2, 'tech_pk': 3, 'modified_by': 0, 'added_by': 0}, {'name': 'INTRAFREQHOGROUP', 'parent_pk': 0, 'vendor_pk': 2, 'tech_pk': 3, 'modified_by': 0, 'added_by': 0}, {'name': 'INTRARATHOCOMM', 'parent_pk': 0, 'vendor_pk': 2, 'tech_pk': 3, 'modified_by': 0, 'added_by': 0}, {'name': 'IPGUARD', 'parent_pk': 0, 'vendor_pk': 2, 'tech_pk': 3, 'modified_by': 0, 'added_by': 0}, {'name': 'IPPATH', 'parent_pk': 0, 'vendor_pk': 2, 'tech_pk': 3, 'modified_by': 0, 'added_by': 0}, {'name': 'IPRT', 'parent_pk': 0, 'vendor_pk': 2, 'tech_pk': 3, 'modified_by': 0, 'added_by': 0}, {'name': 'LOCATION', 'parent_pk': 0, 'vendor_pk': 2, 'tech_pk': 3, 'modified_by': 0, 'added_by': 0}, {'name': 'MIMOADAPTIVEPARACFG', 'parent_pk': 0, 'vendor_pk': 2, 'tech_pk': 3, 'modified_by': 0, 'added_by': 0}, {'name': 'MMEFEATURECFG', 'parent_pk': 0, 'vendor_pk': 2, 'tech_pk': 3, 'modified_by': 0, 'added_by': 0}, {'name': 'MRO', 'parent_pk': 0, 'vendor_pk': 2, 'tech_pk': 3, 'modified_by': 0, 'added_by': 0}, {'name': 'NE', 'parent_pk': 0, 'vendor_pk': 2, 'tech_pk': 3, 'modified_by': 0, 'added_by': 0}, {'name': 'NODE', 'parent_pk': 0, 'vendor_pk': 2, 'tech_pk': 3, 'modified_by': 0, 'added_by': 0}, {'name': 'OMCH', 'parent_pk': 0, 'vendor_pk': 2, 'tech_pk': 3, 'modified_by': 0, 'added_by': 0}, {'name': 'PCCHCFG', 'parent_pk': 0, 'vendor_pk': 2, 'tech_pk': 3, 'modified_by': 0, 'added_by': 0}, {'name': 'PDCPROHCPARA', 'parent_pk': 0, 'vendor_pk': 2, 'tech_pk': 3, 'modified_by': 0, 'added_by': 0}, {'name': 'PDSCHCFG', 'parent_pk': 0, 'vendor_pk': 2, 'tech_pk': 3, 'modified_by': 0, 'added_by': 0}, {'name': 'PHICHCFG', 'parent_pk': 0, 'vendor_pk': 2, 'tech_pk': 3, 'modified_by': 0, 'added_by': 0}, {'name': 'PUCCHCFG', 'parent_pk': 0, 'vendor_pk': 2, 'tech_pk': 3, 'modified_by': 0, 'added_by': 0}, {'name': 'PUSCHCFG', 'parent_pk': 0, 'vendor_pk': 2, 'tech_pk': 3, 'modified_by': 0, 'added_by': 0}, {'name': 'PUSCHPARAM', 'parent_pk': 0, 'vendor_pk': 2, 'tech_pk': 3, 'modified_by': 0, 'added_by': 0}, {'name': 'RACHCFG', 'parent_pk': 0, 'vendor_pk': 2, 'tech_pk': 3, 'modified_by': 0, 'added_by': 0}, {'name': 'RET', 'parent_pk': 0, 'vendor_pk': 2, 'tech_pk': 3, 'modified_by': 0, 'added_by': 0}, {'name': 'RETDEVICEDATA', 'parent_pk': 0, 'vendor_pk': 2, 'tech_pk': 3, 'modified_by': 0, 'added_by': 0}, {'name': 'RETSUBUNIT', 'parent_pk': 0, 'vendor_pk': 2, 'tech_pk': 3, 'modified_by': 0, 'added_by': 0}, {'name': 'RLCPDCPPARAGROUP', 'parent_pk': 0, 'vendor_pk': 2, 'tech_pk': 3, 'modified_by': 0, 'added_by': 0}, {'name': 'RRCCONNSTATETIMER', 'parent_pk': 0, 'vendor_pk': 2, 'tech_pk': 3, 'modified_by': 0, 'added_by': 0}, {'name': 'RRUJOINTCALPARACFG', 'parent_pk': 0, 'vendor_pk': 2, 'tech_pk': 3, 'modified_by': 0, 'added_by': 0}, {'name': 'S1', 'parent_pk': 0, 'vendor_pk': 2, 'tech_pk': 3, 'modified_by': 0, 'added_by': 0}, {'name': 'S1INTERFACE', 'parent_pk': 0, 'vendor_pk': 2, 'tech_pk': 3, 'modified_by': 0, 'added_by': 0}, {'name': 'S1REESTTIMER', 'parent_pk': 0, 'vendor_pk': 2, 'tech_pk': 3, 'modified_by': 0, 'added_by': 0}, {'name': 'SCTPHOST', 'parent_pk': 0, 'vendor_pk': 2, 'tech_pk': 3, 'modified_by': 0, 'added_by': 0}, {'name': 'SCTPHOSTREF', 'parent_pk': 0, 'vendor_pk': 2, 'tech_pk': 3, 'modified_by': 0, 'added_by': 0}, {'name': 'SCTPLNK', 'parent_pk': 0, 'vendor_pk': 2, 'tech_pk': 3, 'modified_by': 0, 'added_by': 0}, {'name': 'SCTPPEER', 'parent_pk': 0, 'vendor_pk': 2, 'tech_pk': 3, 'modified_by': 0, 'added_by': 0}, {'name': 'SCTPPEERREF', 'parent_pk': 0, 'vendor_pk': 2, 'tech_pk': 3, 'modified_by': 0, 'added_by': 0}, {'name': 'SECTOR', 'parent_pk': 0, 'vendor_pk': 2, 'tech_pk': 3, 'modified_by': 0, 'added_by': 0}, {'name': 'SECTORANTENNAREF', 'parent_pk': 0, 'vendor_pk': 2, 'tech_pk': 3, 'modified_by': 0, 'added_by': 0}, {'name': 'SECTOREQM', 'parent_pk': 0, 'vendor_pk': 2, 'tech_pk': 3, 'modified_by': 0, 'added_by': 0}, {'name': 'SECTOREQMANTENNAREF', 'parent_pk': 0, 'vendor_pk': 2, 'tech_pk': 3, 'modified_by': 0, 'added_by': 0}, {'name': 'SERVICEIFDLEARFCNGRP', 'parent_pk': 0, 'vendor_pk': 2, 'tech_pk': 3, 'modified_by': 0, 'added_by': 0}, {'name': 'SERVICEIFHOCFGGROUP', 'parent_pk': 0, 'vendor_pk': 2, 'tech_pk': 3, 'modified_by': 0, 'added_by': 0}, {'name': 'SERVICEIRHOCFGGROUP', 'parent_pk': 0, 'vendor_pk': 2, 'tech_pk': 3, 'modified_by': 0, 'added_by': 0}, {'name': 'SIMULOAD', 'parent_pk': 0, 'vendor_pk': 2, 'tech_pk': 3, 'modified_by': 0, 'added_by': 0}, {'name': 'SRSADAPTIVECFG', 'parent_pk': 0, 'vendor_pk': 2, 'tech_pk': 3, 'modified_by': 0, 'added_by': 0}, {'name': 'SRSCFG', 'parent_pk': 0, 'vendor_pk': 2, 'tech_pk': 3, 'modified_by': 0, 'added_by': 0}, {'name': 'STANDARDQCI', 'parent_pk': 0, 'vendor_pk': 2, 'tech_pk': 3, 'modified_by': 0, 'added_by': 0}, {'name': 'SUBSESSION_NE', 'parent_pk': 0, 'vendor_pk': 2, 'tech_pk': 3, 'modified_by': 0, 'added_by': 0}, {'name': 'TACALG', 'parent_pk': 0, 'vendor_pk': 2, 'tech_pk': 3, 'modified_by': 0, 'added_by': 0}, {'name': 'TCEIPMAPPING', 'parent_pk': 0, 'vendor_pk': 2, 'tech_pk': 3, 'modified_by': 0, 'added_by': 0}, {'name': 'TCPACKCTRLALGO', 'parent_pk': 0, 'vendor_pk': 2, 'tech_pk': 3, 'modified_by': 0, 'added_by': 0}, {'name': 'TCPACKLIMITALG', 'parent_pk': 0, 'vendor_pk': 2, 'tech_pk': 3, 'modified_by': 0, 'added_by': 0}, {'name': 'TCPMSSCTRL', 'parent_pk': 0, 'vendor_pk': 2, 'tech_pk': 3, 'modified_by': 0, 'added_by': 0}, {'name': 'TDDFRAMEOFFSET', 'parent_pk': 0, 'vendor_pk': 2, 'tech_pk': 3, 'modified_by': 0, 'added_by': 0}, {'name': 'TDDRESMODESWITCH', 'parent_pk': 0, 'vendor_pk': 2, 'tech_pk': 3, 'modified_by': 0, 'added_by': 0}, {'name': 'TIMEALIGNMENTTIMER', 'parent_pk': 0, 'vendor_pk': 2, 'tech_pk': 3, 'modified_by': 0, 'added_by': 0}, {'name': 'TOLCALG', 'parent_pk': 0, 'vendor_pk': 2, 'tech_pk': 3, 'modified_by': 0, 'added_by': 0}, {'name': 'TPEALGO', 'parent_pk': 0, 'vendor_pk': 2, 'tech_pk': 3, 'modified_by': 0, 'added_by': 0}, {'name': 'TRUSTCERT', 'parent_pk': 0, 'vendor_pk': 2, 'tech_pk': 3, 'modified_by': 0, 'added_by': 0}, {'name': 'TYPDRBBSR', 'parent_pk': 0, 'vendor_pk': 2, 'tech_pk': 3, 'modified_by': 0, 'added_by': 0}, {'name': 'UDT', 'parent_pk': 0, 'vendor_pk': 2, 'tech_pk': 3, 'modified_by': 0, 'added_by': 0}, {'name': 'UDTPARAGRP', 'parent_pk': 0, 'vendor_pk': 2, 'tech_pk': 3, 'modified_by': 0, 'added_by': 0}, {'name': 'UETIMERCONST', 'parent_pk': 0, 'vendor_pk': 2, 'tech_pk': 3, 'modified_by': 0, 'added_by': 0}, {'name': 'USERPLANEHOST', 'parent_pk': 0, 'vendor_pk': 2, 'tech_pk': 3, 'modified_by': 0, 'added_by': 0}, {'name': 'USERPLANEHOSTREF', 'parent_pk': 0, 'vendor_pk': 2, 'tech_pk': 3, 'modified_by': 0, 'added_by': 0}, {'name': 'USERPLANEPEER', 'parent_pk': 0, 'vendor_pk': 2, 'tech_pk': 3, 'modified_by': 0, 'added_by': 0}, {'name': 'USERPLANEPEERREF', 'parent_pk': 0, 'vendor_pk': 2, 'tech_pk': 3, 'modified_by': 0, 'added_by': 0}, {'name': 'UTRANEXTERNALCELL', 'parent_pk': 0, 'vendor_pk': 2, 'tech_pk': 3, 'modified_by': 0, 'added_by': 0}, {'name': 'UTRANNCELL', 'parent_pk': 0, 'vendor_pk': 2, 'tech_pk': 3, 'modified_by': 0, 'added_by': 0}, {'name': 'UTRANNFREQ', 'parent_pk': 0, 'vendor_pk': 2, 'tech_pk': 3, 'modified_by': 0, 'added_by': 0}, {'name': 'VLANMAP', 'parent_pk': 0, 'vendor_pk': 2, 'tech_pk': 3, 'modified_by': 0, 'added_by': 0}, {'name': 'VQMALGO', 'parent_pk': 0, 'vendor_pk': 2, 'tech_pk': 3, 'modified_by': 0, 'added_by': 0}, {'name': 'VRF', 'parent_pk': 0, 'vendor_pk': 2, 'tech_pk': 3, 'modified_by': 0, 'added_by': 0}, {'name': 'X2', 'parent_pk': 0, 'vendor_pk': 2, 'tech_pk': 3, 'modified_by': 0, 'added_by': 0}, {'name': 'X2BLACKWHITELIST', 'parent_pk': 0, 'vendor_pk': 2, 'tech_pk': 3, 'modified_by': 0, 'added_by': 0}, {'name': 'X2INTERFACE', 'parent_pk': 0, 'vendor_pk': 2, 'tech_pk': 3, 'modified_by': 0, 'added_by': 0}, ]) def downgrade(): op.execute("""DELETE FROM managedobjects WHERE vendor_pk = {0} AND tech_pk = {1}""".format(2, 3))
96.161826
120
0.578943
3,460
23,175
3.592486
0.078324
0.093644
0.140467
0.234111
0.763234
0.755591
0.749155
0.749155
0.749155
0.749155
0
0.054391
0.1789
23,175
240
121
96.5625
0.598823
0.006775
0
0.022222
0
0
0.513255
0.005737
0
0
0
0
0
1
0.008889
false
0
0.013333
0
0.022222
0
0
0
0
null
0
0
1
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
6
edf4523f8f3aecff7f3e36d6a0922689ade1ff3a
167
py
Python
Chapter 10/10-1.py
lzhang1/BeginningPygame
c239925041a6fa361386f65316ef4bea12c3b482
[ "MIT" ]
43
2015-09-20T02:05:48.000Z
2022-03-01T22:00:43.000Z
Chapter 10/10-1.py
lzhang1/BeginningPygame
c239925041a6fa361386f65316ef4bea12c3b482
[ "MIT" ]
null
null
null
Chapter 10/10-1.py
lzhang1/BeginningPygame
c239925041a6fa361386f65316ef4bea12c3b482
[ "MIT" ]
40
2015-05-19T06:51:13.000Z
2022-03-27T18:11:16.000Z
def stereo_pan(x_coord, screen_width): right_volume = float(x_coord) / screen_width left_volume = 1.0 - right_volume return (left_volume, right_volume)
23.857143
49
0.730539
25
167
4.48
0.56
0.294643
0.214286
0.303571
0
0
0
0
0
0
0
0.014706
0.185629
167
6
50
27.833333
0.808824
0
0
0
0
0
0
0
0
0
0
0
0
1
0.25
false
0
0
0
0.5
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
1
0
0
0
0
0
0
0
6
edfa7d04143dd4c7c060f92b8cca61144c0d8ed3
16,960
py
Python
tests/chemplot_visualize_plot_unittest.py
mcsorkun/ChemPlot
bb5002558c47b15a4d501f839a6de0de9a44586d
[ "BSD-3-Clause" ]
32
2021-07-14T16:31:42.000Z
2022-03-30T09:19:10.000Z
tests/chemplot_visualize_plot_unittest.py
ergroup/ChemPlot
d5d439ef877f6b1fe6b8245efe7c69a4c206bb56
[ "BSD-3-Clause" ]
1
2021-12-07T17:06:00.000Z
2022-01-14T03:26:45.000Z
tests/chemplot_visualize_plot_unittest.py
ergroup/ChemPlot
d5d439ef877f6b1fe6b8245efe7c69a4c206bb56
[ "BSD-3-Clause" ]
7
2021-07-15T14:02:39.000Z
2022-03-31T15:44:49.000Z
import unittest from unittest.mock import patch from chemplot import Plotter import pandas as pd import numpy as np import os from scipy import stats from matplotlib import pyplot from io import StringIO class TestVisualizePlot(unittest.TestCase): @classmethod def setUpClass(cls): file_LOGS = os.path.join('test_data', 'R_1291_LOGS.csv') cls.data_LOGS = pd.read_csv(file_LOGS) file_BBBP = os.path.join('test_data', 'C_2039_BBBP_2.csv') cls.data_BBBP = pd.read_csv(file_BBBP) cls.plotter_pca_LOGS = Plotter.from_smiles(cls.data_LOGS["smiles"], target=cls.data_LOGS["target"], target_type="R", sim_type="tailored") cls.plotter_pca_BBBP = Plotter.from_smiles(cls.data_BBBP["smiles"], target=cls.data_BBBP["target"], target_type="C", sim_type="tailored") cls.plotter_pca_LOGS.pca() cls.plotter_pca_BBBP.pca() def test_default_kind_none(self): """ 1. Test checks if default kind is assigned """ result = self.plotter_pca_LOGS.visualize_plot(size=20, remove_outliers=False, is_colored=True, colorbar=False) self.assertEqual(result.get_label(), "scatter") pyplot.close() def test_default_kind(self): """ 2. Test checks if default kind is assigned with anytext """ result = self.plotter_pca_LOGS.visualize_plot(kind='anytext', size=20, remove_outliers=False, is_colored=True, colorbar=False) self.assertEqual(result.get_label(), "scatter") pyplot.close() @patch('sys.stdout', new_callable=StringIO) def test_INFO_kind_with_anytext(self, mock_stdout): """ 3. Test checks if user is informed about kind """ self.plotter_pca_LOGS.visualize_plot(kind='anytext', size=20, remove_outliers=False, is_colored=True, colorbar=False) assert str('kind indicates which type of plot must be visualized. Currently supported static visualization are:\n'+ '-scatter plot (scatter)\n'+ '-hexagon plot (hex)\n'+ '-kernel density estimation plot (kde)\n'+ 'Please input one between scatter, hex or kde for parameter kind.\n'+ 'As default scatter has been taken.') in mock_stdout.getvalue() pyplot.close() def test_default_is_colored(self): """ 4. Test checks if default is_colored is assigned """ result = self.plotter_pca_LOGS.visualize_plot(kind='scatter', size=20, remove_outliers=False, colorbar=False) self.assertTrue(len(result.collections)>1) pyplot.close() def test_default_remove_outliers(self): """ 5. Test checks if default remove_outliers is assigned """ self.plotter_pca_LOGS.visualize_plot(kind='scatter', size=20, is_colored=True, colorbar=False) x = self.plotter_pca_LOGS._Plotter__df_2_components.columns[0] y = self.plotter_pca_LOGS._Plotter__df_2_components.columns[1] self.assertTrue(self.plotter_pca_LOGS.df_plot_xy.equals(self.plotter_pca_LOGS._Plotter__df_2_components[[x,y]])) pyplot.close() def test_default_size(self): """ 6. Test checks if default size is assigned """ result = self.plotter_pca_LOGS.visualize_plot(kind='scatter', remove_outliers=False, is_colored=True, colorbar=False) self.assertEqual(result.figure.get_size_inches()[0], 20) self.assertEqual(result.figure.get_size_inches()[1], 20) pyplot.close() def test_kind_scatter(self): """ 7. Test checks if kind is assigned """ result = self.plotter_pca_LOGS.visualize_plot(kind='scatter', size=20, remove_outliers=False, is_colored=True, colorbar=False) self.assertEqual(result.get_label(), "scatter") pyplot.close() def test_is_colored_true_scatter(self): """ 8. Test checks if is_colored is assigned """ result = self.plotter_pca_LOGS.visualize_plot(kind='scatter', size=20, remove_outliers=False, is_colored=True, colorbar=False) self.assertTrue(len(result.collections)>1) pyplot.close() def test_is_colored_false_scatter(self): """ 9. Test checks if is_colored is assigned """ result = self.plotter_pca_LOGS.visualize_plot(kind='scatter', size=20, remove_outliers=False, is_colored=False, colorbar=False) self.assertTrue(len(result.collections) == 1) pyplot.close() def test_remove_outliers_false_scatter(self): """ 10. Test checks if remove_outliers is assigned """ self.plotter_pca_LOGS.visualize_plot(kind='scatter', size=20, remove_outliers=False, is_colored=True, colorbar=False) x = self.plotter_pca_LOGS._Plotter__df_2_components.columns[0] y = self.plotter_pca_LOGS._Plotter__df_2_components.columns[1] self.assertTrue(self.plotter_pca_LOGS.df_plot_xy.equals(self.plotter_pca_LOGS._Plotter__df_2_components[[x,y]])) pyplot.close() def test_remove_outliers_true_scatter(self): """ 11. Test checks if remove_outliers is assigned """ self.plotter_pca_LOGS.visualize_plot(kind='scatter', size=20, remove_outliers=True, is_colored=True, colorbar=False) df_no_outliers = self.plotter_pca_LOGS._Plotter__df_2_components.copy() x = self.plotter_pca_LOGS._Plotter__df_2_components.columns[0] y = self.plotter_pca_LOGS._Plotter__df_2_components.columns[1] df_no_outliers = df_no_outliers[[x,y]] df_no_outliers= df_no_outliers[(np.abs(stats.zscore(df_no_outliers))<3).all(axis=1)] self.assertTrue(self.plotter_pca_LOGS.df_plot_xy.equals(df_no_outliers)) pyplot.close() def test_size_scatter(self): """ 12. Test checks if size is assigned """ result = self.plotter_pca_LOGS.visualize_plot(kind='scatter', size=20, remove_outliers=False, is_colored=True, colorbar=False) self.assertEqual(result.figure.get_size_inches()[0], 20) self.assertEqual(result.figure.get_size_inches()[1], 20) pyplot.close() def test_kind_hex(self): """ 13. Test checks if kind is assigned """ result = self.plotter_pca_LOGS.visualize_plot(kind='hex', size=20, remove_outliers=False, is_colored=True, colorbar=False) self.assertEqual(result.get_label(), "hex") pyplot.close() def test_remove_outliers_false_hex(self): """ 14. Test checks if remove_outliers is assigned """ self.plotter_pca_LOGS.visualize_plot(kind='hex', size=20, remove_outliers=False, is_colored=True, colorbar=False) x = self.plotter_pca_LOGS._Plotter__df_2_components.columns[0] y = self.plotter_pca_LOGS._Plotter__df_2_components.columns[1] self.assertTrue(self.plotter_pca_LOGS.df_plot_xy.equals(self.plotter_pca_LOGS._Plotter__df_2_components[[x,y]])) pyplot.close() def test_remove_outliers_true_hex(self): """ 15. Test checks if remove_outliers is assigned """ self.plotter_pca_LOGS.visualize_plot(kind='hex', size=20, remove_outliers=True, is_colored=True, colorbar=False) df_no_outliers = self.plotter_pca_LOGS._Plotter__df_2_components.copy() x = self.plotter_pca_LOGS._Plotter__df_2_components.columns[0] y = self.plotter_pca_LOGS._Plotter__df_2_components.columns[1] df_no_outliers = df_no_outliers[[x,y]] df_no_outliers= df_no_outliers[(np.abs(stats.zscore(df_no_outliers))<3).all(axis=1)] self.assertTrue(self.plotter_pca_LOGS.df_plot_xy.equals(df_no_outliers)) pyplot.close() def test_size_hex(self): """ 16. Test checks if size is assigned """ result = self.plotter_pca_LOGS.visualize_plot(kind='hex', size=20, remove_outliers=False, is_colored=True, colorbar=False) self.assertEqual(result.figure.get_size_inches()[0], 20) self.assertEqual(result.figure.get_size_inches()[1], 20) pyplot.close() def test_kind_kde(self): """ 17. Test checks if kind is assigned """ result = self.plotter_pca_LOGS.visualize_plot(kind='kde', size=20, remove_outliers=False, is_colored=True, colorbar=False) self.assertEqual(result.get_label(), "kde") pyplot.close() def test_remove_outliers_false_kde(self): """ 18. Test checks if remove_outliers is assigned """ self.plotter_pca_LOGS.visualize_plot(kind='kde', size=20, remove_outliers=False, is_colored=True, colorbar=False) x = self.plotter_pca_LOGS._Plotter__df_2_components.columns[0] y = self.plotter_pca_LOGS._Plotter__df_2_components.columns[1] self.assertTrue(self.plotter_pca_LOGS.df_plot_xy.equals(self.plotter_pca_LOGS._Plotter__df_2_components[[x,y]])) pyplot.close() def test_remove_outliers_true_kde(self): """ 19. Test checks if remove_outliers is assigned """ self.plotter_pca_LOGS.visualize_plot(kind='kde', size=20, remove_outliers=True, is_colored=True, colorbar=False) df_no_outliers = self.plotter_pca_LOGS._Plotter__df_2_components.copy() x = self.plotter_pca_LOGS._Plotter__df_2_components.columns[0] y = self.plotter_pca_LOGS._Plotter__df_2_components.columns[1] df_no_outliers = df_no_outliers[[x,y]] df_no_outliers= df_no_outliers[(np.abs(stats.zscore(df_no_outliers))<3).all(axis=1)] self.assertTrue(self.plotter_pca_LOGS.df_plot_xy.equals(df_no_outliers)) pyplot.close() def test_size_kde(self): """ 20. Test checks if size is assigned """ result = self.plotter_pca_LOGS.visualize_plot(kind='kde', size=20, remove_outliers=False, is_colored=True, colorbar=False) self.assertEqual(result.figure.get_size_inches()[0], 20) self.assertEqual(result.figure.get_size_inches()[1], 20) pyplot.close() def test_default_colorbar(self): """ 21. Test checks if default value of colorbar is assigned """ result = self.plotter_pca_LOGS.visualize_plot(kind='scatter', size=20, remove_outliers=False, is_colored=True) self.assertNotIsInstance(result.get_legend(), type(None)) self.assertEqual(len(result.figure.axes), 1) pyplot.close() def test_colorbar_R_remove_legend(self): """ 22. Test checks if colorbar is assigned when target type is R and therefore legend removed """ result = self.plotter_pca_LOGS.visualize_plot(kind='scatter', size=20, remove_outliers=False, is_colored=True, colorbar=True) self.assertIsInstance(result.get_legend(), type(None)) pyplot.close() def test_colorbar_C_keep_legend(self): """ 23. Test checks if colorbar is ignored when target type is C and therefore legend kept """ result = self.plotter_pca_BBBP.visualize_plot(kind='scatter', size=20, remove_outliers=False, is_colored=True, colorbar=True) self.assertNotIsInstance(result.get_legend(), type(None)) pyplot.close() def test_colorbar_R_add_colorbar(self): """ 24. Test checks if colorbar is assigned when target type is R """ result = self.plotter_pca_LOGS.visualize_plot(kind='scatter', size=20, remove_outliers=False, is_colored=True, colorbar=True) self.assertTrue(len(result.figure.axes)>=1) pyplot.close() def test_colorbar_C_ignore_colorbar(self): """ 25. Test checks if colorbar is ignored when target type is C """ result = self.plotter_pca_BBBP.visualize_plot(kind='scatter', size=20, remove_outliers=False, is_colored=True, colorbar=True) self.assertTrue(len(result.figure.axes)==1) pyplot.close() def test_default_title(self): """ 26. Test checks if the default title is assigned """ result = self.plotter_pca_BBBP.visualize_plot(kind='scatter', size=20, remove_outliers=False, is_colored=True, colorbar=True) self.assertEqual(result.get_title(), self.plotter_pca_BBBP._Plotter__plot_title) pyplot.close() def test_assigned_title(self): """ 27. Test checks if title is assigned """ result = self.plotter_pca_BBBP.visualize_plot(kind='scatter', size=20, remove_outliers=False, is_colored=True, colorbar=True, title="title") self.assertTrue(result.get_title()=="title") pyplot.close() @patch('sys.stdout', new_callable=StringIO) def test_INFO_call_without_reduction(self, mock_stdout): """ 28. Test checks if user is informed a plot cannot be created without reducing the dimensions first """ file_SAMPL = os.path.join('test_data', 'R_642_SAMPL.csv') data_SAMPL = pd.read_csv(file_SAMPL) cp = Plotter.from_smiles(data_SAMPL["smiles"], target=data_SAMPL["target"], target_type="R", sim_type="tailored") result = cp.visualize_plot() assert result is None assert 'Reduce the dimensions of your molecules before creating a plot.' in mock_stdout.getvalue() def test_default_filename_scatter(self): """ 29. Test checks if the default value of filename is assigned with scatter """ try: os.remove("scatter_test.png") except FileNotFoundError: pass expected = len([name for name in os.listdir('.') if os.path.isfile(name)]) self.plotter_pca_BBBP.visualize_plot(kind='scatter') result = len([name for name in os.listdir('.') if os.path.isfile(name)]) self.assertEqual(expected, result) pyplot.close() def test_filename_scatter(self): """ 30. Test checks if the value of filename is assigned with scatter """ try: os.remove("scatter_test.png") except FileNotFoundError: pass expected = len([name for name in os.listdir('.') if os.path.isfile(name)]) self.plotter_pca_BBBP.visualize_plot(kind='scatter', filename="scatter_test.png") result = len([name for name in os.listdir('.') if os.path.isfile(name)]) self.assertEqual(expected, result - 1) os.remove("scatter_test.png") pyplot.close() def test_default_filename_hex(self): """ 31. Test checks if the default value of filename is assigned with hex """ try: os.remove("hex_test.png") except FileNotFoundError: pass expected = len([name for name in os.listdir('.') if os.path.isfile(name)]) self.plotter_pca_BBBP.visualize_plot(kind='hex') result = len([name for name in os.listdir('.') if os.path.isfile(name)]) self.assertEqual(expected, result) pyplot.close() def test_filename_hex(self): """ 32. Test checks if the value of filename is assigned with hex """ try: os.remove("hex_test.png") except FileNotFoundError: pass expected = len([name for name in os.listdir('.') if os.path.isfile(name)]) self.plotter_pca_BBBP.visualize_plot(kind='hex', filename="hex_test.png") result = len([name for name in os.listdir('.') if os.path.isfile(name)]) self.assertEqual(expected, result - 1) os.remove("hex_test.png") pyplot.close() def test_default_filename_kde(self): """ 33. Test checks if the default value of filename is assigned with kde """ try: os.remove("kde_test.png") except FileNotFoundError: pass expected = len([name for name in os.listdir('.') if os.path.isfile(name)]) self.plotter_pca_BBBP.visualize_plot(kind='kde') result = len([name for name in os.listdir('.') if os.path.isfile(name)]) self.assertEqual(expected, result) pyplot.close() def test_filename_kde(self): """ 34. Test checks if the value of filename is assigned with kde """ try: os.remove("kde_test.png") except FileNotFoundError: pass expected = len([name for name in os.listdir('.') if os.path.isfile(name)]) self.plotter_pca_BBBP.visualize_plot(kind='kde', filename="kde_test.png") result = len([name for name in os.listdir('.') if os.path.isfile(name)]) self.assertEqual(expected, result - 1) os.remove("kde_test.png") pyplot.close() if __name__ == '__main__': unittest.main()
44.631579
148
0.653774
2,240
16,960
4.689286
0.092411
0.062833
0.082635
0.087395
0.821592
0.806931
0.791032
0.771135
0.756759
0.756759
0
0.015204
0.236026
16,960
379
149
44.74934
0.795477
0.107134
0
0.582979
0
0
0.062604
0
0
0
0
0
0.170213
1
0.148936
false
0.025532
0.038298
0
0.191489
0
0
0
0
null
0
0
0
1
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
6
612d7a01c79b0f454bfe10f8b7ebc46682bb874b
58
py
Python
arkfbp/state/app_state.py
arkfbp/arkfbp-py
2444736462e8b4f09ae1ffe56779d9f515deb39f
[ "MIT" ]
2
2020-09-11T09:26:43.000Z
2020-12-17T07:32:38.000Z
arkfbp/state/app_state.py
arkfbp/arkfbp-py
2444736462e8b4f09ae1ffe56779d9f515deb39f
[ "MIT" ]
4
2020-12-02T03:42:38.000Z
2020-12-14T07:56:06.000Z
arkfbp/state/app_state.py
arkfbp/arkfbp-py
2444736462e8b4f09ae1ffe56779d9f515deb39f
[ "MIT" ]
2
2020-12-08T01:11:54.000Z
2021-01-25T04:29:15.000Z
from .base import State class AppState(State): pass
9.666667
23
0.706897
8
58
5.125
0.875
0
0
0
0
0
0
0
0
0
0
0
0.224138
58
5
24
11.6
0.911111
0
0
0
0
0
0
0
0
0
0
0
0
1
0
true
0.333333
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
1
1
1
0
1
0
0
6
b628bb783b94c3cb2f0789db1db071b46283f7b7
124
py
Python
packages/python/readme_metrics/__init__.py
mderazon/metrics-sdks
ea2ee94af06ee1b01a2c2ac8f69bd97d2ce1956a
[ "ISC" ]
null
null
null
packages/python/readme_metrics/__init__.py
mderazon/metrics-sdks
ea2ee94af06ee1b01a2c2ac8f69bd97d2ce1956a
[ "ISC" ]
null
null
null
packages/python/readme_metrics/__init__.py
mderazon/metrics-sdks
ea2ee94af06ee1b01a2c2ac8f69bd97d2ce1956a
[ "ISC" ]
null
null
null
from readme_metrics.MetricsApiConfig import MetricsApiConfig from readme_metrics.MetricsMiddleware import MetricsMiddleware
41.333333
62
0.919355
12
124
9.333333
0.5
0.178571
0.303571
0
0
0
0
0
0
0
0
0
0.064516
124
2
63
62
0.965517
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
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
1
0
0
6
b62e4f59e1d8bada115ab401007610bf728370d5
107
py
Python
_modules/utils/cache/add_never_cache_headers/views.py
looking-for-a-job/django-examples
dfafa450668cac5c0351f6c7238b8886511229bf
[ "Unlicense" ]
null
null
null
_modules/utils/cache/add_never_cache_headers/views.py
looking-for-a-job/django-examples
dfafa450668cac5c0351f6c7238b8886511229bf
[ "Unlicense" ]
null
null
null
_modules/utils/cache/add_never_cache_headers/views.py
looking-for-a-job/django-examples
dfafa450668cac5c0351f6c7238b8886511229bf
[ "Unlicense" ]
null
null
null
from django.http import HttpResponse def my_view(request): return HttpResponse("return this string")
17.833333
45
0.775701
14
107
5.857143
0.857143
0
0
0
0
0
0
0
0
0
0
0
0.149533
107
5
46
21.4
0.901099
0
0
0
0
0
0.168224
0
0
0
0
0
0
1
0.333333
false
0
0.333333
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
1
1
1
0
0
6
b630a931514cf715f2e798d4bc551facd74cdc79
40
py
Python
rcnn/modeling/fpn/__init__.py
rs9899/Parsing-R-CNN
a0c9ed8850abe740eedf8bfc6e1577cc0aa3fc7b
[ "MIT" ]
289
2018-10-25T09:42:57.000Z
2022-03-30T08:31:50.000Z
rcnn/modeling/fpn/__init__.py
qzane/Parsing-R-CNN
8c4d940dcd322bf7a8671f8b0faaabb3259bd384
[ "MIT" ]
28
2019-01-07T02:39:49.000Z
2022-01-25T08:54:36.000Z
rcnn/modeling/fpn/__init__.py
qzane/Parsing-R-CNN
8c4d940dcd322bf7a8671f8b0faaabb3259bd384
[ "MIT" ]
44
2018-12-20T07:36:46.000Z
2022-03-16T14:30:20.000Z
from .FPN import * from .HRFPN import *
13.333333
20
0.7
6
40
4.666667
0.666667
0
0
0
0
0
0
0
0
0
0
0
0.2
40
2
21
20
0.875
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
1
0
0
6
b688896a480940b8e027f9d12bd81a451a05da85
44
py
Python
authlib/specs/rfc6749/grants.py
tk193192/authlib
4c60a628f64c6d385a06ea55e416092726b94d07
[ "BSD-3-Clause" ]
2
2021-04-26T18:17:37.000Z
2021-04-28T21:39:45.000Z
authlib/specs/rfc6749/grants.py
tk193192/authlib
4c60a628f64c6d385a06ea55e416092726b94d07
[ "BSD-3-Clause" ]
4
2021-03-19T08:17:59.000Z
2021-06-10T19:34:36.000Z
authlib/specs/rfc6749/grants.py
tk193192/authlib
4c60a628f64c6d385a06ea55e416092726b94d07
[ "BSD-3-Clause" ]
2
2021-05-24T20:34:12.000Z
2022-03-26T07:46:17.000Z
from authlib.oauth2.rfc6749.grants import *
22
43
0.818182
6
44
6
1
0
0
0
0
0
0
0
0
0
0
0.125
0.090909
44
1
44
44
0.775
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
1
0
0
6
b6a7bc989a31733384f3a7535fc6e100b741cee6
168
py
Python
skil/__init__.py
farizrahman4u/skil-python
1e9d411c70e20b3748a184e80d17a5ef98e83260
[ "Apache-2.0" ]
1
2020-08-12T22:52:07.000Z
2020-08-12T22:52:07.000Z
skil/__init__.py
farizrahman4u/skil-python
1e9d411c70e20b3748a184e80d17a5ef98e83260
[ "Apache-2.0" ]
null
null
null
skil/__init__.py
farizrahman4u/skil-python
1e9d411c70e20b3748a184e80d17a5ef98e83260
[ "Apache-2.0" ]
null
null
null
from skil.base import * from skil.deployments import * from skil.experiments import * from skil.models import * from skil.workspaces import * from skil.context import *
28
30
0.791667
24
168
5.541667
0.375
0.360902
0.526316
0
0
0
0
0
0
0
0
0
0.136905
168
6
31
28
0.917241
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
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
6
fcb7ef7c102863d83ffcb6e3c6f6c171d0d64d3c
236
py
Python
ai/domain_adaptation/utils/system.py
aayushkafle/implicit_alignment
4835a8a5acc4b30daf7e1c95195f160e76306cd1
[ "Apache-2.0" ]
null
null
null
ai/domain_adaptation/utils/system.py
aayushkafle/implicit_alignment
4835a8a5acc4b30daf7e1c95195f160e76306cd1
[ "Apache-2.0" ]
null
null
null
ai/domain_adaptation/utils/system.py
aayushkafle/implicit_alignment
4835a8a5acc4b30daf7e1c95195f160e76306cd1
[ "Apache-2.0" ]
1
2021-04-15T13:29:34.000Z
2021-04-15T13:29:34.000Z
import warnings def filter_deprecation_warning(): print('Caution: deprecation warnings are filtered!') warnings.filterwarnings("ignore", category=DeprecationWarning) warnings.filterwarnings("ignore", category=UserWarning)
29.5
66
0.788136
22
236
8.363636
0.681818
0.23913
0.304348
0.391304
0
0
0
0
0
0
0
0
0.114407
236
7
67
33.714286
0.880383
0
0
0
0
0
0.233051
0
0
0
0
0
0
1
0.2
true
0
0.2
0
0.4
0.2
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
1
0
0
0
0
0
0
6
1e09aab77a57cc78115698f09d148fdc98208e35
28,116
py
Python
apps/events/tests/view_tests.py
Nicolaad/onlineweb4
5942eaf907d6824d5384147627def9edefdb9946
[ "MIT" ]
null
null
null
apps/events/tests/view_tests.py
Nicolaad/onlineweb4
5942eaf907d6824d5384147627def9edefdb9946
[ "MIT" ]
null
null
null
apps/events/tests/view_tests.py
Nicolaad/onlineweb4
5942eaf907d6824d5384147627def9edefdb9946
[ "MIT" ]
null
null
null
from datetime import timedelta from unittest.mock import patch from captcha.client import RecaptchaResponse from django.contrib.auth.models import Group from django.core import mail from django.test import TestCase from django.urls import reverse from django.utils import timezone from django_dynamic_fixture import G from freezegun import freeze_time from rest_framework import status from apps.authentication.models import AllowedUsername, OnlineGroup from apps.marks.models import MarkRuleSet from apps.payment.models import PaymentDelay, PaymentPrice from ..models import TYPE_CHOICES, AttendanceEvent, Event, Extras, GroupRestriction from .utils import ( add_payment_delay, add_to_arrkom, add_to_bedkom, add_to_trikom, attend_user_to_event, generate_attendee, generate_event, generate_payment, generate_user, pay_for_event, ) class EventsTestMixin: def setUp(self): G(Group, pk=1, name="arrKom") G(Group, pk=3, name="bedKom") G(Group, pk=8, name="triKom") G(Group, pk=12, name="Komiteer") self.user = generate_user("test") self.client.force_login(self.user) self.mark_rule_set = G(MarkRuleSet) self.event = generate_event() self.event_url = reverse( "events_details", args=(self.event.id, self.event.slug) ) def assertInMessages(self, message_text, response): messages = [str(message) for message in response.context["messages"]] self.assertIn(message_text, messages) class EventsDetailRestricted(EventsTestMixin, TestCase): def test_ok(self): response = self.client.get(self.event_url) self.assertEqual(response.status_code, status.HTTP_200_OK) def test_404(self): event = generate_event() url = reverse("events_details", args=(event.id + 10, event.slug)) response = self.client.get(url) self.assertEqual(response.status_code, status.HTTP_404_NOT_FOUND) def test_group_restricted_access(self): add_to_trikom(self.user) trikom = Group.objects.get(name__iexact="trikom") G(GroupRestriction, event=self.event, groups=[trikom]) response = self.client.get(self.event_url) messages = list(response.context["messages"]) self.assertEqual(response.status_code, status.HTTP_200_OK) self.assertEqual(len(messages), 0) def test_group_restricted_no_access(self): add_to_trikom(self.user) arrkom = Group.objects.get(name__iexact="arrkom") G(GroupRestriction, event=self.event, groups=[arrkom]) response = self.client.get(self.event_url) self.assertEqual(response.status_code, status.HTTP_200_OK) self.assertInMessages("Du har ikke tilgang til dette arrangementet.", response) def test_group_hidden_no_access(self): self.event = G(Event, visible=False) self.event_url = reverse( "events_details", args=(self.event.id, self.event.slug) ) response = self.client.get(self.event_url) self.assertEqual(response.status_code, status.HTTP_200_OK) self.assertInMessages("Du har ikke tilgang til dette arrangementet.", response) class EventsDetailPayment(EventsTestMixin, TestCase): def test_payment_logged_out(self): payment = generate_payment(self.event) self.client.logout() response = self.client.get(self.event_url) context = response.context self.assertEqual(response.status_code, status.HTTP_200_OK) self.assertEqual(context["payment"], payment) self.assertEqual(context["user_paid"], False) self.assertEqual(context["payment_delay"], None) self.assertEqual(context["payment_relation_id"], None) def test_payment_not_attended(self): payment = generate_payment(self.event) response = self.client.get(self.event_url) context = response.context self.assertEqual(response.status_code, status.HTTP_200_OK) self.assertEqual(context["payment"], payment) self.assertEqual(context["user_attending"], False) self.assertEqual(context["user_paid"], False) self.assertEqual(context["payment_delay"], None) self.assertEqual(context["payment_relation_id"], None) def test_payment_attended(self): payment = generate_payment(self.event) attend_user_to_event(self.event, self.user) response = self.client.get(self.event_url) context = response.context self.assertEqual(response.status_code, status.HTTP_200_OK) self.assertEqual(context["payment"], payment) self.assertEqual(context["user_attending"], True) self.assertEqual(context["user_paid"], False) self.assertEqual(context["payment_delay"], None) self.assertEqual(context["payment_relation_id"], None) def test_payment_paid(self): payment = generate_payment(self.event) attend_user_to_event(self.event, self.user) payment_relation = pay_for_event(self.event, self.user) response = self.client.get(self.event_url) context = response.context self.assertEqual(response.status_code, status.HTTP_200_OK) self.assertEqual(context["payment"], payment) self.assertEqual(context["user_attending"], True) self.assertEqual(context["user_paid"], True) self.assertEqual(context["payment_delay"], None) self.assertEqual(context["payment_relation_id"], payment_relation.id) def test_payment_attended_with_delay(self): payment = generate_payment(self.event) payment_delay = add_payment_delay(payment, self.user) attend_user_to_event(self.event, self.user) response = self.client.get(self.event_url) context = response.context self.assertEqual(response.status_code, status.HTTP_200_OK) self.assertEqual(context["payment"], payment) self.assertEqual(context["user_attending"], True) self.assertEqual(context["user_paid"], False) self.assertEqual(context["payment_delay"], payment_delay) self.assertEqual(context["payment_relation_id"], None) class EventsDetailExtras(EventsTestMixin, TestCase): def extras_post(self, event_url, extras_id): return self.client.post( event_url, {"action": "extras", "extras_id": extras_id}, HTTP_X_REQUESTED_WITH="XMLHttpRequest", ) def test_extras_on_non_attendance_event(self): event = G(Event) extras = G(Extras) event_url = reverse("events_details", args=(event.id, event.slug)) response = self.extras_post(event_url, extras.id) self.assertEqual(response.status_code, status.HTTP_200_OK) self.assertEqual( response.json()["message"], "Dette er ikke et påmeldingsarrangement." ) def test_extras_on_not_attended_event(self): extras = G(Extras) response = self.extras_post(self.event_url, extras.id) self.assertEqual(response.status_code, status.HTTP_200_OK) self.assertEqual( response.json()["message"], "Du er ikke påmeldt dette arrangementet." ) def test_invalid_extras(self): attend_user_to_event(self.event, self.user) response = self.extras_post(self.event_url, 1000) self.assertEqual(response.status_code, status.HTTP_200_OK) self.assertEqual(response.json()["message"], "Ugyldig valg") def test_extras_success(self): extras = G(Extras) event = G(Event) G(AttendanceEvent, event=event, extras=[extras]) attend_user_to_event(event, self.user) event_url = reverse("events_details", args=(event.id, event.slug)) response = self.extras_post(event_url, extras.id) self.assertEqual(response.status_code, status.HTTP_200_OK) self.assertEqual(response.json()["message"], "Lagret ditt valg") class EventsAttend(EventsTestMixin, TestCase): def test_attend_404(self): url = reverse("attend_event", args=(1000,)) response = self.client.post(url) self.assertEqual(response.status_code, status.HTTP_404_NOT_FOUND) def test_attend_not_attendance_event(self): event = G(Event) url = reverse("attend_event", args=(event.id,)) response = self.client.post(url, follow=True) self.assertRedirects(response, event.get_absolute_url()) self.assertInMessages("Dette er ikke et påmeldingsarrangement.", response) def test_attend_get(self): url = reverse("attend_event", args=(self.event.id,)) response = self.client.get(url, follow=True) self.assertRedirects(response, self.event.get_absolute_url()) self.assertInMessages("Vennligst fyll ut skjemaet.", response) def test_attend_missing_note(self): form_params = {"g-recaptcha-response": "PASSED"} url = reverse("attend_event", args=(self.event.id,)) response = self.client.post(url, form_params, follow=True) self.assertRedirects(response, self.event.get_absolute_url()) self.assertInMessages("Du må fylle inn et notat!", response) def test_attend_not_accepted_rules(self): form_params = {"g-recaptcha-response": "PASSED"} url = reverse("attend_event", args=(self.event.id,)) G( AllowedUsername, username=self.user.ntnu_username, expiration_date=timezone.now() + timedelta(days=1), ) response = self.client.post(url, form_params, follow=True) self.assertRedirects(response, self.event.get_absolute_url()) self.assertInMessages("Du må godta prikkereglene!", response) @patch("captcha.fields.client.submit") def test_attend_invalid_captcha(self, mocked_submit): mocked_submit.return_value = RecaptchaResponse(is_valid=False) url = reverse("attend_event", args=(self.event.id,)) form_params = {"g-recaptcha-response": "WRONG"} G( AllowedUsername, username=self.user.ntnu_username, expiration_date=timezone.now() + timedelta(days=1), ) MarkRuleSet.accept_mark_rules(self.user) response = self.client.post(url, form_params, follow=True) self.assertRedirects(response, self.event.get_absolute_url()) self.assertInMessages("Du klarte ikke captchaen! Er du en bot?", response) @patch("captcha.fields.client.submit") def test_attend_before_registration_start(self, mocked_submit): mocked_submit.return_value = RecaptchaResponse(is_valid=True) event = G(Event) G( AttendanceEvent, event=event, registration_start=timezone.now() + timedelta(days=1), registration_end=timezone.now() + timedelta(days=2), ) url = reverse("attend_event", args=(event.id,)) form_params = {"g-recaptcha-response": "PASSED"} G( AllowedUsername, username=self.user.ntnu_username, expiration_date=timezone.now() + timedelta(days=1), ) MarkRuleSet.accept_mark_rules(self.user) response = self.client.post(url, form_params, follow=True) self.assertRedirects(response, event.get_absolute_url()) self.assertInMessages("Påmeldingen har ikke åpnet enda.", response) @patch("captcha.fields.client.submit") def test_attend_successfully(self, mocked_submit): mocked_submit.return_value = RecaptchaResponse(is_valid=True) event = G(Event) G( AttendanceEvent, event=event, registration_start=timezone.now() - timedelta(days=1), registration_end=timezone.now() + timedelta(days=1), ) url = reverse("attend_event", args=(event.id,)) form_params = {"g-recaptcha-response": "PASSED"} G( AllowedUsername, username=self.user.ntnu_username, expiration_date=timezone.now() + timedelta(days=1), ) MarkRuleSet.accept_mark_rules(self.user) response = self.client.post(url, form_params, follow=True) self.assertRedirects(response, event.get_absolute_url()) self.assertInMessages("Du er nå meldt på arrangementet.", response) @patch("captcha.fields.client.submit") def test_attend_twice(self, mocked_submit): mocked_submit.return_value = RecaptchaResponse(is_valid=True) event = G(Event) G( AttendanceEvent, event=event, registration_start=timezone.now() - timedelta(days=1), registration_end=timezone.now() + timedelta(days=1), ) url = reverse("attend_event", args=(event.id,)) form_params = {"g-recaptcha-response": "PASSED"} G( AllowedUsername, username=self.user.ntnu_username, expiration_date=timezone.now() + timedelta(days=1), ) MarkRuleSet.accept_mark_rules(self.user) self.client.post(url, form_params, follow=True) response = self.client.post(url, form_params, follow=True) self.assertRedirects(response, event.get_absolute_url()) self.assertInMessages("Du er allerede meldt på dette arrangementet.", response) @patch("captcha.fields.client.submit") def test_attend_with_payment_creates_paymentdelay(self, mocked_submit): mocked_submit.return_value = RecaptchaResponse(is_valid=True) event = G(Event) G( AttendanceEvent, event=event, registration_start=timezone.now() - timedelta(days=1), registration_end=timezone.now() + timedelta(days=1), ) self.event_payment = generate_payment( event, payment_type=3, delay=timedelta(days=2) ) G(PaymentPrice, price=200, payment=self.event_payment) url = reverse("attend_event", args=(event.id,)) form_params = {"g-recaptcha-response": "PASSED"} G( AllowedUsername, username=self.user.ntnu_username, expiration_date=timezone.now() + timedelta(days=1), ) MarkRuleSet.accept_mark_rules(self.user) self.client.post(url, form_params, follow=True) self.assertTrue(PaymentDelay.objects.filter(user=self.user).exists()) class EventsUnattend(EventsTestMixin, TestCase): def test_unattend_not_attended(self): url = reverse("unattend_event", args=(self.event.id,)) response = self.client.post(url, follow=True) self.assertRedirects(response, self.event.get_absolute_url()) self.assertInMessages("Du er ikke påmeldt dette arrangementet.", response) def test_unattend_not_attendance_event(self): event = G(Event) url = reverse("unattend_event", args=(event.id,)) response = self.client.post(url, follow=True) self.assertRedirects(response, event.get_absolute_url()) self.assertInMessages("Dette er ikke et påmeldingsarrangement.", response) def test_unattend_deadline_yesterday(self): event = G(Event) G( AttendanceEvent, event=event, unattend_deadline=timezone.now() - timedelta(days=1), ) attend_user_to_event(event, self.user) url = reverse("unattend_event", args=(event.id,)) response = self.client.post(url, follow=True) self.assertRedirects(response, event.get_absolute_url()) self.assertInMessages( "Avmeldingsfristen for dette arrangementet har utløpt.", response ) def test_unattend_event_started(self): event = G(Event, event_start=timezone.now() - timedelta(days=1)) G( AttendanceEvent, event=event, unattend_deadline=timezone.now() + timedelta(days=1), ) attend_user_to_event(event, self.user) url = reverse("unattend_event", args=(event.id,)) response = self.client.post(url, follow=True) self.assertRedirects(response, event.get_absolute_url()) self.assertInMessages("Dette arrangementet har allerede startet.", response) def test_unattend_successfully(self): event = G(Event, event_start=timezone.now() + timedelta(days=1)) G( AttendanceEvent, event=event, unattend_deadline=timezone.now() + timedelta(days=1), ) attend_user_to_event(event, self.user) url = reverse("unattend_event", args=(event.id,)) response = self.client.post(url, follow=True, HTTP_HOST="example.com") self.assertRedirects(response, event.get_absolute_url()) self.assertInMessages("Du ble meldt av arrangementet.", response) def test_unattend_payment_not_refunded(self): event = G(Event, event_start=timezone.now() + timedelta(days=1)) G( AttendanceEvent, event=event, unattend_deadline=timezone.now() + timedelta(days=1), ) attend_user_to_event(event, self.user) generate_payment(event) pay_for_event(event, self.user) url = reverse("unattend_event", args=(event.id,)) response = self.client.post(url, follow=True, HTTP_HOST="example.com") self.assertRedirects(response, event.get_absolute_url()) self.assertInMessages( "Du har betalt for arrangementet og må refundere før du kan melde deg av", response, ) def test_unattend_payment_removes_payment_delays(self): event = G(Event, event_start=timezone.now() + timedelta(days=1)) G( AttendanceEvent, event=event, unattend_deadline=timezone.now() + timedelta(days=1), ) attend_user_to_event(event, self.user) payment = generate_payment(event) pay_for_event(event, self.user, refunded=True) payment_delay = add_payment_delay(payment, self.user) url = reverse("unattend_event", args=(event.id,)) response = self.client.post(url, follow=True, HTTP_HOST="example.com") self.assertRedirects(response, event.get_absolute_url()) self.assertInMessages("Du ble meldt av arrangementet.", response) self.assertEqual(PaymentDelay.objects.filter(id=payment_delay.id).count(), 0) class EventsUnattendWaitlist(TestCase): def setUp(self): self.event = G(Event, event_start=timezone.now() + timedelta(days=1)) G( AttendanceEvent, event=self.event, unattend_deadline=timezone.now() + timedelta(days=1), max_capacity=2, waitlist=True, ) self.user = generate_user("test") self.client.force_login(self.user) self.other_user = generate_user("other") self.url = reverse("unattend_event", args=(self.event.id,)) def test_unattend_notifies_waitlist_when_attending(self): generate_attendee(self.event, "user1") attend_user_to_event(self.event, self.user) generate_attendee(self.event, "user2") generate_attendee(self.event, "user3") self.client.post(self.url, follow=True, HTTP_HOST="example.com") self.assertEqual(len(mail.outbox), 1) self.assertIn("Du har fått plass på", mail.outbox[0].subject) def test_unattend_does_not_notify_waitlist_when_on_waitlist(self): generate_attendee(self.event, "user1") generate_attendee(self.event, "user2") attend_user_to_event(self.event, self.user) generate_attendee(self.event, "user3") self.client.post(self.url, follow=True, HTTP_HOST="example.com") self.assertEqual(len(mail.outbox), 0) @freeze_time("2017-01-01 12:00") def test_payment_type_instant_uses_extended(self): generate_payment(self.event, payment_type=1) generate_attendee(self.event, "user1") attend_user_to_event(self.event, self.user) attend_user_to_event(self.event, self.other_user) generate_attendee(self.event, "user3") payment_delay_time = timedelta(days=2) self.client.post(self.url, follow=True, HTTP_HOST="example.com") self.assertEqual(len(mail.outbox), 1) self.assertIn("Du har fått plass på", mail.outbox[0].subject) payment_delay = PaymentDelay.objects.get(user=self.other_user) self.assertEqual(payment_delay.valid_to, timezone.now() + payment_delay_time) def test_payment_delay_is_not_created_if_deadline_over_48_hours(self): generate_payment( self.event, payment_type=2, deadline=timezone.now() + timedelta(days=3) ) generate_attendee(self.event, "user1") attend_user_to_event(self.event, self.user) attend_user_to_event(self.event, self.other_user) generate_attendee(self.event, "user3") self.client.post(self.url, follow=True, HTTP_HOST="example.com") self.assertEqual(len(mail.outbox), 1) self.assertIn("Du har fått plass på", mail.outbox[0].subject) payment_delay = PaymentDelay.objects.filter(user=self.other_user) self.assertFalse(payment_delay.exists()) @freeze_time("2017-01-01 12:00") def test_payment_delay_is_created_if_deadline_under_48_hours(self): generate_payment( self.event, payment_type=2, deadline=timezone.now() + timedelta(hours=47) ) generate_attendee(self.event, "user1") attend_user_to_event(self.event, self.user) attend_user_to_event(self.event, self.other_user) generate_attendee(self.event, "user3") payment_delay_time = timedelta(days=2) self.client.post(self.url, follow=True, HTTP_HOST="example.com") self.assertEqual(len(mail.outbox), 1) self.assertIn("Du har fått plass på", mail.outbox[0].subject) payment_delay = PaymentDelay.objects.get(user=self.other_user) self.assertEqual(payment_delay.valid_to, timezone.now() + payment_delay_time) @freeze_time("2017-01-01 12:00") def test_payment_type_delay_uses_payment_delay(self): delay_days = 4 payment_delay_time = timedelta(days=delay_days) generate_payment(self.event, payment_type=3, delay=payment_delay_time) generate_attendee(self.event, "user1") attend_user_to_event(self.event, self.user) attend_user_to_event(self.event, self.other_user) generate_attendee(self.event, "user3") self.client.post(self.url, follow=True, HTTP_HOST="example.com") self.assertEqual(len(mail.outbox), 1) self.assertIn("Du har fått plass på", mail.outbox[0].subject) payment_delay = PaymentDelay.objects.get(user=self.other_user) self.assertEqual(payment_delay.valid_to, timezone.now() + payment_delay_time) class EventMailParticipates(EventsTestMixin, TestCase): def setUp(self): super().setUp() self.mail_url = reverse("event_mail_participants", args=(self.event.id,)) def test_not_attendance_event(self): event = G(Event) url = reverse("event_mail_participants", args=(event.id,)) response = self.client.get(url, follow=True) self.assertInMessages("Dette er ikke et påmeldingsarrangement.", response) self.assertEqual(len(mail.outbox), 0) def test_missing_access(self): response = self.client.get(self.mail_url, follow=True) self.assertInMessages("Du har ikke tilgang til å vise denne siden.", response) self.assertEqual(len(mail.outbox), 0) def test_get_own_social_event_as_bedkom(self): add_to_bedkom(self.user) bedkom = Group.objects.get(name__iexact="bedkom") event = generate_event(TYPE_CHOICES[0][0], organizer=bedkom) url = reverse("event_mail_participants", args=(event.id,)) response = self.client.get(url) self.assertEqual(response.context["event"], event) self.assertEqual(len(mail.outbox), 0) def test_get_as_arrkom(self): add_to_arrkom(self.user) event = generate_event(TYPE_CHOICES[0][0]) url = reverse("event_mail_participants", args=(event.id,)) response = self.client.get(url) self.assertEqual(response.context["event"], event) self.assertEqual(len(mail.outbox), 0) def test_post_as_arrkom_missing_data(self): add_to_arrkom(self.user) event = generate_event(TYPE_CHOICES[0][0]) url = reverse("event_mail_participants", args=(event.id,)) response = self.client.post(url) self.assertEqual(response.context["event"], event) self.assertInMessages( "Vi klarte ikke å sende mailene dine. Prøv igjen", response ) self.assertEqual(len(mail.outbox), 0) def test_post_as_arrkom_successfully(self): organizer_email = "arrkom@online.ntnu.no" add_to_arrkom(self.user) event = generate_event(TYPE_CHOICES[0][0]) G(OnlineGroup, email=organizer_email, group=event.organizer) url = reverse("event_mail_participants", args=(event.id,)) response = self.client.post( url, {"to_email": "1", "subject": "Test", "message": "Test message"} ) self.assertEqual(response.context["event"], event) self.assertInMessages("Mailen ble sendt", response) self.assertEqual(mail.outbox[0].from_email, "arrkom@online.ntnu.no") self.assertEqual(mail.outbox[0].subject, "Test") self.assertIn("Test message", mail.outbox[0].body) def test_post_as_arrkom_invalid_from_email_defaults_to_kontakt(self): add_to_arrkom(self.user) event = generate_event(TYPE_CHOICES[0][0]) G(OnlineGroup, email="", group=event.organizer) url = reverse("event_mail_participants", args=(event.id,)) response = self.client.post( url, {"to_email": "1", "subject": "Test", "message": "Test message"} ) self.assertEqual(response.context["event"], event) self.assertInMessages("Mailen ble sendt", response) self.assertEqual(len(mail.outbox), 1) self.assertEqual(mail.outbox[0].from_email, "kontakt@online.ntnu.no") self.assertEqual(mail.outbox[0].subject, "Test") self.assertIn("Test message", mail.outbox[0].body) def test_post_as_arrkom_invalid_to_email(self): add_to_arrkom(self.user) event = generate_event(TYPE_CHOICES[0][0]) url = reverse("event_mail_participants", args=(event.id,)) response = self.client.post( url, {"to_email": "1000", "subject": "Test", "message": "Test message"} ) self.assertEqual(response.context["event"], event) self.assertInMessages( "Vi klarte ikke å sende mailene dine. Prøv igjen", response ) self.assertEqual(len(mail.outbox), 0) class EventsArchive(TestCase): def test_events_index_empty(self): url = reverse("events_index") response = self.client.get(url) self.assertEqual(response.status_code, status.HTTP_200_OK) def test_events_index_exists(self): generate_event() url = reverse("events_index") response = self.client.get(url) self.assertEqual(response.status_code, status.HTTP_200_OK) class EventsSearch(TestCase): def test_search_events(self): query = "" _url_pre_get_param = reverse("search_events") url = _url_pre_get_param + "?query=%s" % query response = self.client.get(url) self.assertEqual(response.status_code, status.HTTP_200_OK) class EventsCalendar(TestCase): def test_events_ics_all(self): url = reverse("events_ics") response = self.client.get(url) self.assertEqual(response.status_code, status.HTTP_200_OK) def test_events_ics_specific_event(self): event = generate_event() url = reverse("event_ics", args=(event.id,)) response = self.client.get(url) self.assertEqual(response.status_code, status.HTTP_200_OK)
37.289125
87
0.668303
3,377
28,116
5.356233
0.090613
0.043288
0.03881
0.034498
0.807331
0.782287
0.754976
0.724403
0.709863
0.68211
0
0.01
0.217492
28,116
753
88
37.338645
0.812145
0
0
0.625
0
0
0.100868
0.01693
0
0
0
0
0.217014
1
0.095486
false
0.010417
0.027778
0.001736
0.144097
0
0
0
0
null
0
0
0
1
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
6
1e5af2e842580f1e1bcdbbfe8f75509632242dbb
118
py
Python
Boatman_webserver/lights/tests.py
sjefferson99/Boatman-webserver
5a0416c1835fe1a8b7119d7e36a42e02c4cbf6d2
[ "MIT" ]
null
null
null
Boatman_webserver/lights/tests.py
sjefferson99/Boatman-webserver
5a0416c1835fe1a8b7119d7e36a42e02c4cbf6d2
[ "MIT" ]
1
2022-02-20T12:32:51.000Z
2022-02-20T12:32:51.000Z
Boatman_webserver/lights/tests.py
sjefferson99/Boatman-webserver
5a0416c1835fe1a8b7119d7e36a42e02c4cbf6d2
[ "MIT" ]
null
null
null
from django.test import TestCase from .models import light, group from django.core.exceptions import ValidationError
23.6
50
0.838983
16
118
6.1875
0.6875
0.20202
0
0
0
0
0
0
0
0
0
0
0.118644
118
4
51
29.5
0.951923
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
1
0
0
6
1e76557735b7d3d154f0f84ac5bcc02689e6bdf7
25
py
Python
quick_easy/__init__.py
araile/anki-quick-easy
53fbbb22491aca2b7dd863c620de1deea7a07f60
[ "MIT" ]
3
2018-07-01T20:14:12.000Z
2018-07-16T03:47:20.000Z
quick_easy/__init__.py
araile/anki-quick-easy
53fbbb22491aca2b7dd863c620de1deea7a07f60
[ "MIT" ]
1
2018-04-05T10:28:16.000Z
2018-04-05T10:28:16.000Z
quick_easy/__init__.py
araile/anki-quick-easy
53fbbb22491aca2b7dd863c620de1deea7a07f60
[ "MIT" ]
3
2018-02-27T02:08:35.000Z
2019-05-11T13:51:13.000Z
from . import quick_easy
12.5
24
0.8
4
25
4.75
1
0
0
0
0
0
0
0
0
0
0
0
0.16
25
1
25
25
0.904762
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
1
0
0
6
1eb4d01cafe8f5a3c5a9759dabb638851f372c39
257,344
py
Python
instances/passenger_demand/pas-20210422-1717-int8e-1/51.py
LHcau/scheduling-shared-passenger-and-freight-transport-on-a-fixed-infrastructure
bba1e6af5bc8d9deaa2dc3b83f6fe9ddf15d2a11
[ "BSD-3-Clause" ]
null
null
null
instances/passenger_demand/pas-20210422-1717-int8e-1/51.py
LHcau/scheduling-shared-passenger-and-freight-transport-on-a-fixed-infrastructure
bba1e6af5bc8d9deaa2dc3b83f6fe9ddf15d2a11
[ "BSD-3-Clause" ]
null
null
null
instances/passenger_demand/pas-20210422-1717-int8e-1/51.py
LHcau/scheduling-shared-passenger-and-freight-transport-on-a-fixed-infrastructure
bba1e6af5bc8d9deaa2dc3b83f6fe9ddf15d2a11
[ "BSD-3-Clause" ]
null
null
null
""" PASSENGERS """ numPassengers = 15308 passenger_arriving = ( (3, 5, 6, 5, 3, 2, 3, 1, 0, 0, 1, 0, 0, 5, 2, 0, 3, 1, 0, 2, 3, 2, 1, 1, 1, 0), # 0 (3, 6, 4, 1, 1, 4, 5, 2, 2, 2, 0, 0, 0, 2, 2, 1, 2, 3, 1, 1, 0, 0, 3, 0, 1, 0), # 1 (3, 3, 3, 6, 5, 0, 1, 2, 4, 1, 2, 0, 0, 9, 3, 5, 1, 1, 2, 4, 1, 1, 3, 0, 0, 0), # 2 (3, 6, 9, 5, 5, 3, 0, 3, 0, 2, 1, 0, 0, 3, 4, 6, 6, 1, 2, 0, 4, 2, 2, 1, 1, 0), # 3 (2, 3, 3, 2, 6, 4, 2, 3, 1, 2, 2, 1, 0, 8, 4, 2, 3, 10, 2, 1, 1, 2, 0, 1, 0, 0), # 4 (8, 7, 6, 6, 3, 1, 2, 0, 3, 0, 2, 0, 0, 7, 4, 4, 3, 4, 3, 3, 3, 2, 4, 2, 0, 0), # 5 (7, 7, 2, 8, 0, 1, 4, 2, 0, 1, 4, 0, 0, 5, 2, 3, 5, 5, 3, 1, 1, 2, 4, 1, 1, 0), # 6 (3, 8, 3, 4, 7, 1, 2, 3, 1, 2, 3, 0, 0, 2, 3, 2, 1, 4, 3, 1, 0, 1, 3, 2, 0, 0), # 7 (5, 6, 5, 4, 3, 3, 5, 3, 6, 1, 1, 0, 0, 7, 8, 1, 5, 1, 3, 5, 2, 2, 3, 3, 0, 0), # 8 (6, 8, 8, 9, 1, 3, 5, 2, 2, 0, 1, 2, 0, 11, 6, 5, 4, 3, 0, 5, 1, 1, 3, 1, 0, 0), # 9 (3, 5, 5, 5, 4, 0, 2, 2, 3, 0, 1, 0, 0, 7, 4, 4, 2, 5, 6, 2, 3, 3, 2, 4, 4, 0), # 10 (7, 5, 6, 5, 6, 6, 0, 1, 1, 1, 1, 0, 0, 8, 5, 5, 3, 8, 3, 0, 2, 1, 0, 0, 0, 0), # 11 (12, 6, 5, 4, 8, 1, 3, 2, 5, 1, 1, 1, 0, 7, 4, 8, 2, 6, 4, 3, 1, 1, 2, 2, 1, 0), # 12 (7, 10, 7, 3, 8, 4, 5, 1, 5, 2, 3, 0, 0, 11, 5, 6, 2, 7, 3, 0, 3, 2, 0, 1, 0, 0), # 13 (7, 7, 6, 5, 3, 3, 2, 1, 4, 4, 2, 0, 0, 9, 5, 4, 3, 9, 4, 2, 1, 3, 4, 3, 1, 0), # 14 (6, 10, 1, 10, 4, 3, 1, 2, 2, 4, 1, 0, 0, 6, 10, 2, 3, 5, 4, 4, 0, 3, 2, 2, 2, 0), # 15 (10, 11, 10, 6, 9, 5, 3, 1, 1, 1, 2, 1, 0, 11, 1, 4, 6, 9, 4, 4, 1, 0, 2, 2, 0, 0), # 16 (8, 8, 7, 10, 5, 1, 1, 6, 3, 1, 0, 1, 0, 7, 5, 3, 6, 6, 6, 2, 4, 2, 1, 2, 0, 0), # 17 (5, 10, 10, 6, 2, 4, 2, 1, 1, 4, 2, 1, 0, 12, 8, 5, 5, 6, 5, 4, 0, 5, 3, 1, 1, 0), # 18 (10, 11, 3, 7, 4, 1, 5, 5, 2, 5, 2, 0, 0, 7, 9, 8, 7, 4, 5, 2, 2, 5, 3, 1, 0, 0), # 19 (10, 10, 9, 6, 4, 3, 0, 2, 6, 1, 1, 0, 0, 7, 5, 5, 3, 4, 3, 3, 0, 4, 1, 3, 0, 0), # 20 (11, 11, 4, 8, 10, 2, 1, 5, 5, 1, 2, 1, 0, 4, 5, 2, 6, 6, 8, 3, 1, 4, 4, 1, 0, 0), # 21 (11, 12, 5, 10, 5, 4, 7, 4, 2, 2, 0, 1, 0, 6, 7, 8, 4, 8, 4, 5, 3, 2, 0, 1, 1, 0), # 22 (8, 6, 10, 5, 5, 4, 2, 1, 7, 5, 0, 0, 0, 15, 3, 5, 7, 1, 1, 5, 3, 4, 4, 0, 0, 0), # 23 (8, 6, 12, 9, 8, 0, 4, 1, 4, 3, 0, 1, 0, 7, 9, 4, 3, 5, 8, 7, 2, 2, 5, 0, 2, 0), # 24 (10, 8, 8, 7, 4, 4, 1, 3, 2, 1, 0, 0, 0, 8, 12, 3, 7, 6, 3, 2, 1, 3, 1, 1, 1, 0), # 25 (5, 7, 11, 9, 4, 3, 1, 2, 1, 2, 0, 2, 0, 9, 6, 4, 2, 5, 6, 4, 8, 5, 1, 2, 1, 0), # 26 (14, 11, 9, 4, 7, 2, 3, 3, 2, 2, 2, 1, 0, 5, 5, 3, 4, 4, 5, 4, 2, 3, 3, 1, 0, 0), # 27 (13, 9, 7, 8, 4, 2, 4, 2, 4, 4, 1, 0, 0, 11, 11, 6, 5, 5, 4, 8, 3, 3, 3, 0, 0, 0), # 28 (4, 8, 13, 9, 4, 5, 1, 2, 2, 1, 0, 1, 0, 6, 8, 6, 6, 4, 5, 6, 3, 4, 1, 2, 2, 0), # 29 (7, 6, 0, 5, 2, 4, 3, 1, 7, 3, 0, 0, 0, 11, 8, 10, 5, 9, 1, 3, 2, 5, 3, 2, 2, 0), # 30 (13, 12, 5, 4, 1, 3, 2, 3, 2, 5, 1, 2, 0, 8, 10, 8, 4, 8, 5, 5, 1, 1, 2, 2, 1, 0), # 31 (8, 7, 5, 11, 8, 1, 4, 4, 3, 1, 1, 3, 0, 8, 3, 4, 2, 7, 5, 1, 0, 2, 2, 2, 0, 0), # 32 (8, 9, 7, 5, 1, 2, 2, 2, 6, 3, 0, 1, 0, 4, 9, 9, 1, 6, 4, 3, 2, 2, 7, 2, 0, 0), # 33 (8, 15, 4, 8, 3, 2, 6, 4, 4, 2, 4, 0, 0, 12, 6, 8, 8, 7, 6, 2, 5, 1, 2, 1, 0, 0), # 34 (8, 8, 6, 7, 5, 4, 3, 2, 2, 1, 0, 1, 0, 8, 7, 4, 5, 6, 4, 6, 6, 2, 4, 1, 1, 0), # 35 (8, 6, 6, 9, 6, 4, 6, 7, 0, 1, 0, 2, 0, 5, 9, 5, 4, 8, 5, 3, 3, 4, 0, 1, 3, 0), # 36 (10, 9, 9, 6, 3, 1, 6, 0, 3, 3, 0, 3, 0, 8, 8, 4, 7, 5, 5, 5, 3, 4, 2, 2, 0, 0), # 37 (8, 7, 6, 6, 6, 2, 5, 2, 5, 2, 1, 0, 0, 8, 6, 5, 5, 6, 3, 4, 5, 2, 1, 3, 1, 0), # 38 (12, 10, 7, 7, 4, 2, 5, 6, 4, 0, 0, 1, 0, 5, 6, 5, 8, 4, 3, 3, 0, 2, 0, 2, 1, 0), # 39 (11, 8, 5, 8, 7, 6, 2, 1, 2, 2, 1, 1, 0, 8, 6, 2, 3, 9, 4, 1, 0, 2, 1, 4, 3, 0), # 40 (4, 7, 10, 7, 6, 5, 2, 7, 3, 3, 0, 0, 0, 6, 13, 2, 4, 2, 5, 9, 2, 1, 0, 1, 1, 0), # 41 (12, 11, 1, 6, 3, 2, 2, 4, 4, 0, 0, 1, 0, 11, 8, 2, 5, 6, 0, 2, 4, 3, 4, 1, 1, 0), # 42 (6, 8, 10, 6, 8, 4, 3, 2, 5, 4, 0, 0, 0, 15, 5, 6, 1, 4, 3, 1, 2, 5, 5, 3, 0, 0), # 43 (11, 6, 8, 8, 2, 1, 2, 4, 2, 0, 0, 1, 0, 6, 4, 5, 5, 9, 8, 2, 3, 1, 0, 0, 2, 0), # 44 (11, 8, 9, 8, 9, 2, 2, 4, 1, 0, 1, 0, 0, 6, 8, 10, 4, 10, 4, 4, 4, 1, 2, 1, 3, 0), # 45 (5, 5, 9, 10, 2, 2, 4, 4, 1, 2, 2, 0, 0, 12, 9, 5, 8, 5, 3, 3, 0, 3, 3, 4, 1, 0), # 46 (9, 8, 5, 9, 3, 2, 2, 2, 7, 4, 1, 1, 0, 11, 5, 4, 5, 5, 3, 6, 1, 6, 6, 2, 2, 0), # 47 (3, 8, 4, 4, 4, 2, 1, 2, 4, 2, 2, 1, 0, 7, 3, 3, 3, 5, 4, 4, 1, 1, 0, 0, 0, 0), # 48 (9, 10, 6, 7, 4, 0, 6, 2, 5, 2, 2, 1, 0, 11, 7, 5, 3, 10, 5, 4, 2, 2, 3, 1, 0, 0), # 49 (11, 3, 15, 5, 10, 4, 3, 4, 0, 0, 2, 0, 0, 8, 10, 3, 4, 4, 5, 0, 2, 3, 2, 1, 0, 0), # 50 (9, 6, 6, 8, 6, 6, 4, 3, 1, 1, 1, 0, 0, 5, 4, 11, 6, 6, 3, 1, 4, 1, 2, 1, 1, 0), # 51 (11, 6, 6, 10, 6, 6, 1, 0, 3, 1, 4, 1, 0, 10, 9, 5, 2, 11, 3, 3, 0, 4, 2, 2, 0, 0), # 52 (9, 9, 5, 7, 7, 4, 7, 1, 2, 2, 1, 2, 0, 13, 7, 5, 5, 3, 8, 2, 3, 5, 2, 0, 1, 0), # 53 (5, 7, 8, 3, 6, 3, 4, 4, 4, 1, 2, 0, 0, 7, 8, 10, 4, 11, 2, 6, 3, 3, 2, 3, 1, 0), # 54 (5, 10, 6, 8, 7, 3, 2, 2, 2, 1, 2, 0, 0, 13, 3, 7, 8, 8, 4, 1, 1, 2, 1, 1, 2, 0), # 55 (9, 10, 6, 9, 4, 4, 1, 0, 4, 3, 0, 0, 0, 6, 9, 8, 1, 9, 3, 1, 1, 2, 2, 1, 1, 0), # 56 (11, 11, 8, 9, 8, 5, 7, 5, 5, 1, 2, 0, 0, 8, 6, 2, 6, 7, 4, 2, 3, 2, 4, 2, 1, 0), # 57 (7, 4, 6, 8, 4, 1, 1, 2, 2, 1, 0, 2, 0, 6, 9, 7, 4, 2, 4, 3, 0, 5, 1, 2, 0, 0), # 58 (11, 7, 6, 4, 6, 1, 5, 2, 3, 1, 1, 0, 0, 5, 5, 7, 5, 6, 5, 2, 2, 3, 4, 1, 0, 0), # 59 (12, 6, 1, 5, 6, 2, 3, 4, 2, 1, 1, 1, 0, 6, 5, 3, 5, 9, 2, 7, 1, 1, 1, 0, 0, 0), # 60 (7, 7, 6, 11, 5, 0, 4, 5, 2, 3, 1, 0, 0, 7, 7, 8, 5, 11, 4, 3, 1, 3, 2, 6, 0, 0), # 61 (14, 11, 7, 10, 5, 0, 4, 3, 6, 3, 1, 1, 0, 7, 8, 5, 3, 11, 6, 4, 2, 1, 3, 2, 0, 0), # 62 (4, 9, 1, 5, 12, 4, 2, 3, 5, 0, 0, 0, 0, 13, 8, 11, 6, 10, 2, 3, 1, 5, 3, 1, 0, 0), # 63 (11, 3, 5, 6, 4, 4, 3, 3, 3, 2, 1, 0, 0, 8, 8, 1, 0, 8, 3, 3, 2, 2, 2, 1, 2, 0), # 64 (12, 10, 3, 7, 13, 3, 4, 0, 2, 1, 0, 0, 0, 5, 5, 9, 7, 4, 3, 2, 2, 4, 2, 0, 0, 0), # 65 (13, 8, 7, 7, 9, 5, 0, 1, 6, 1, 1, 0, 0, 8, 3, 3, 8, 4, 2, 2, 1, 3, 2, 3, 1, 0), # 66 (10, 8, 3, 5, 11, 1, 4, 3, 4, 0, 0, 0, 0, 5, 15, 7, 5, 11, 3, 2, 3, 4, 2, 1, 0, 0), # 67 (15, 10, 14, 14, 11, 2, 3, 6, 8, 2, 0, 0, 0, 8, 10, 6, 5, 4, 3, 3, 4, 0, 3, 4, 0, 0), # 68 (9, 7, 6, 7, 4, 0, 1, 3, 0, 2, 0, 0, 0, 9, 4, 2, 5, 6, 4, 4, 4, 4, 3, 2, 0, 0), # 69 (8, 9, 7, 4, 8, 1, 7, 4, 3, 1, 0, 0, 0, 11, 9, 6, 4, 7, 1, 2, 1, 1, 1, 2, 0, 0), # 70 (7, 8, 7, 4, 5, 2, 2, 1, 2, 3, 0, 1, 0, 8, 5, 1, 4, 7, 2, 0, 1, 2, 2, 1, 0, 0), # 71 (6, 6, 6, 4, 6, 6, 3, 2, 5, 0, 0, 0, 0, 8, 7, 8, 4, 5, 1, 5, 0, 4, 9, 1, 0, 0), # 72 (6, 4, 8, 10, 5, 4, 3, 3, 0, 1, 0, 1, 0, 6, 7, 5, 4, 6, 3, 3, 3, 5, 0, 0, 1, 0), # 73 (10, 11, 11, 4, 6, 3, 4, 4, 2, 1, 2, 0, 0, 5, 1, 2, 3, 9, 3, 5, 4, 1, 2, 2, 0, 0), # 74 (7, 3, 9, 10, 7, 4, 0, 0, 1, 1, 0, 0, 0, 8, 5, 5, 4, 7, 2, 2, 5, 0, 3, 1, 0, 0), # 75 (11, 10, 5, 14, 8, 4, 5, 2, 2, 0, 2, 1, 0, 8, 2, 8, 5, 10, 4, 0, 1, 2, 2, 3, 1, 0), # 76 (8, 4, 5, 9, 7, 6, 3, 0, 3, 3, 0, 0, 0, 7, 3, 9, 0, 4, 4, 3, 1, 2, 1, 4, 1, 0), # 77 (6, 1, 4, 7, 4, 5, 2, 6, 2, 0, 3, 0, 0, 9, 7, 6, 2, 8, 5, 2, 1, 4, 3, 2, 3, 0), # 78 (12, 5, 8, 12, 3, 3, 9, 4, 5, 1, 1, 1, 0, 5, 11, 4, 4, 6, 3, 3, 3, 6, 1, 2, 1, 0), # 79 (4, 4, 8, 11, 7, 5, 0, 2, 5, 2, 1, 1, 0, 3, 10, 2, 10, 9, 3, 0, 3, 2, 1, 2, 0, 0), # 80 (10, 4, 9, 10, 10, 0, 2, 3, 4, 1, 1, 0, 0, 6, 3, 6, 2, 4, 4, 1, 3, 5, 3, 1, 1, 0), # 81 (12, 11, 7, 6, 2, 1, 2, 3, 1, 3, 3, 1, 0, 8, 12, 2, 3, 2, 2, 2, 0, 1, 2, 1, 2, 0), # 82 (11, 8, 7, 6, 9, 5, 2, 0, 4, 1, 1, 2, 0, 7, 5, 7, 3, 6, 5, 4, 2, 2, 3, 3, 1, 0), # 83 (6, 10, 2, 7, 2, 2, 2, 3, 2, 3, 1, 1, 0, 13, 8, 8, 5, 7, 3, 4, 1, 6, 3, 0, 1, 0), # 84 (10, 6, 10, 6, 5, 2, 2, 6, 5, 2, 1, 1, 0, 12, 6, 4, 1, 6, 1, 1, 1, 3, 3, 2, 0, 0), # 85 (10, 6, 5, 5, 7, 3, 2, 5, 5, 1, 1, 0, 0, 4, 9, 4, 5, 3, 8, 3, 1, 5, 4, 1, 1, 0), # 86 (14, 3, 7, 8, 7, 2, 3, 2, 2, 1, 0, 1, 0, 7, 4, 8, 3, 11, 2, 2, 1, 2, 2, 3, 1, 0), # 87 (10, 7, 6, 9, 4, 5, 2, 4, 4, 1, 0, 1, 0, 8, 11, 8, 6, 5, 3, 4, 0, 1, 1, 1, 0, 0), # 88 (7, 8, 4, 3, 9, 1, 1, 3, 4, 0, 0, 0, 0, 11, 6, 10, 3, 2, 2, 1, 0, 2, 2, 2, 0, 0), # 89 (9, 6, 8, 6, 4, 2, 1, 7, 3, 0, 0, 1, 0, 11, 5, 5, 4, 7, 3, 3, 0, 0, 5, 1, 2, 0), # 90 (7, 3, 4, 5, 5, 4, 2, 1, 3, 1, 1, 0, 0, 8, 8, 6, 1, 9, 4, 2, 3, 4, 3, 1, 2, 0), # 91 (6, 5, 4, 4, 4, 2, 4, 3, 1, 0, 0, 1, 0, 12, 2, 4, 2, 6, 4, 1, 2, 4, 3, 0, 2, 0), # 92 (6, 2, 3, 8, 7, 2, 7, 3, 2, 0, 1, 1, 0, 7, 1, 9, 3, 5, 3, 0, 2, 2, 1, 2, 0, 0), # 93 (12, 8, 3, 3, 7, 2, 2, 0, 1, 0, 0, 0, 0, 9, 4, 3, 6, 5, 3, 0, 1, 3, 4, 1, 1, 0), # 94 (11, 5, 8, 6, 5, 1, 2, 2, 2, 2, 3, 1, 0, 9, 8, 6, 3, 5, 4, 4, 3, 3, 1, 3, 0, 0), # 95 (4, 7, 6, 9, 2, 7, 3, 6, 4, 5, 1, 0, 0, 8, 7, 5, 6, 5, 2, 3, 2, 3, 5, 0, 0, 0), # 96 (10, 4, 8, 7, 6, 3, 1, 4, 1, 0, 1, 0, 0, 11, 6, 3, 5, 6, 7, 3, 3, 6, 2, 0, 0, 0), # 97 (3, 7, 6, 6, 12, 2, 2, 2, 6, 3, 0, 0, 0, 11, 6, 6, 3, 5, 2, 4, 2, 1, 4, 1, 3, 0), # 98 (17, 6, 1, 13, 5, 5, 3, 0, 3, 1, 1, 0, 0, 10, 10, 6, 3, 3, 5, 4, 0, 2, 2, 0, 0, 0), # 99 (8, 6, 5, 9, 5, 5, 4, 2, 2, 3, 1, 0, 0, 6, 6, 7, 4, 6, 4, 1, 5, 2, 2, 4, 0, 0), # 100 (5, 6, 6, 5, 5, 0, 3, 0, 2, 2, 1, 2, 0, 17, 3, 5, 1, 5, 6, 6, 2, 3, 2, 1, 2, 0), # 101 (5, 5, 5, 4, 9, 1, 2, 4, 1, 1, 1, 1, 0, 8, 5, 6, 4, 7, 3, 4, 2, 3, 3, 1, 0, 0), # 102 (4, 6, 5, 7, 10, 3, 2, 3, 4, 0, 0, 0, 0, 4, 4, 7, 3, 3, 3, 2, 1, 1, 1, 0, 0, 0), # 103 (7, 8, 6, 7, 5, 0, 4, 1, 0, 0, 0, 0, 0, 5, 4, 6, 3, 8, 4, 3, 4, 3, 1, 2, 1, 0), # 104 (9, 7, 4, 5, 4, 4, 0, 5, 1, 3, 0, 0, 0, 7, 6, 5, 4, 7, 2, 1, 2, 2, 0, 0, 1, 0), # 105 (7, 2, 5, 5, 6, 2, 2, 1, 2, 1, 0, 1, 0, 10, 5, 3, 5, 9, 3, 2, 1, 3, 3, 2, 1, 0), # 106 (6, 10, 6, 8, 5, 2, 3, 2, 6, 1, 0, 0, 0, 9, 6, 8, 3, 9, 4, 3, 3, 2, 1, 3, 0, 0), # 107 (4, 6, 7, 7, 6, 4, 2, 2, 4, 1, 1, 0, 0, 10, 3, 2, 3, 5, 6, 1, 2, 2, 1, 2, 0, 0), # 108 (8, 6, 2, 9, 4, 4, 2, 5, 1, 1, 1, 0, 0, 9, 6, 6, 1, 3, 1, 4, 2, 3, 2, 1, 1, 0), # 109 (4, 8, 9, 4, 6, 0, 6, 1, 3, 1, 1, 2, 0, 10, 6, 7, 5, 6, 3, 4, 4, 3, 2, 1, 1, 0), # 110 (8, 3, 8, 7, 7, 3, 6, 3, 3, 1, 1, 0, 0, 11, 8, 3, 7, 9, 5, 5, 1, 5, 1, 3, 0, 0), # 111 (7, 3, 7, 7, 3, 3, 2, 2, 3, 0, 0, 0, 0, 9, 5, 4, 5, 11, 4, 3, 2, 4, 0, 1, 0, 0), # 112 (5, 4, 5, 4, 4, 4, 4, 1, 3, 2, 0, 1, 0, 5, 5, 3, 7, 3, 5, 4, 2, 5, 2, 1, 0, 0), # 113 (2, 4, 5, 5, 3, 1, 2, 1, 0, 1, 2, 0, 0, 11, 6, 9, 3, 10, 2, 4, 4, 4, 3, 2, 1, 0), # 114 (8, 11, 11, 8, 5, 4, 3, 0, 5, 2, 2, 2, 0, 8, 8, 3, 6, 5, 2, 6, 1, 1, 5, 0, 0, 0), # 115 (5, 5, 8, 4, 4, 1, 1, 6, 5, 3, 0, 1, 0, 5, 6, 6, 4, 6, 2, 2, 1, 4, 2, 1, 0, 0), # 116 (12, 5, 4, 5, 1, 8, 3, 0, 6, 2, 0, 0, 0, 8, 8, 2, 1, 6, 3, 2, 2, 4, 2, 1, 0, 0), # 117 (6, 8, 4, 10, 5, 1, 0, 1, 4, 2, 2, 0, 0, 7, 6, 6, 2, 10, 1, 3, 3, 2, 1, 2, 0, 0), # 118 (13, 8, 3, 5, 8, 2, 2, 2, 3, 0, 0, 0, 0, 12, 3, 1, 6, 12, 3, 1, 7, 3, 2, 0, 0, 0), # 119 (7, 5, 6, 11, 4, 2, 3, 4, 2, 3, 0, 0, 0, 8, 8, 5, 5, 3, 4, 3, 2, 2, 2, 0, 2, 0), # 120 (8, 2, 9, 8, 8, 3, 4, 2, 2, 1, 2, 0, 0, 7, 4, 3, 2, 7, 1, 3, 0, 1, 3, 0, 0, 0), # 121 (4, 4, 9, 2, 6, 3, 1, 2, 6, 0, 0, 0, 0, 6, 10, 6, 1, 6, 3, 1, 0, 3, 1, 0, 0, 0), # 122 (8, 5, 3, 6, 4, 4, 2, 1, 2, 3, 1, 0, 0, 5, 5, 4, 1, 6, 1, 3, 0, 2, 2, 1, 0, 0), # 123 (9, 4, 2, 11, 8, 0, 1, 1, 1, 3, 0, 0, 0, 7, 6, 3, 3, 7, 4, 1, 3, 3, 1, 2, 1, 0), # 124 (3, 7, 3, 8, 6, 2, 0, 1, 4, 2, 2, 1, 0, 9, 3, 3, 5, 4, 1, 2, 1, 6, 2, 2, 1, 0), # 125 (8, 2, 5, 8, 5, 1, 2, 0, 5, 4, 0, 0, 0, 6, 6, 4, 1, 5, 3, 3, 1, 2, 2, 1, 0, 0), # 126 (5, 7, 4, 9, 7, 1, 1, 2, 2, 2, 4, 0, 0, 7, 1, 3, 1, 8, 1, 2, 1, 8, 3, 0, 0, 0), # 127 (6, 8, 9, 8, 5, 0, 2, 1, 2, 2, 1, 0, 0, 7, 9, 2, 2, 7, 2, 0, 1, 3, 2, 2, 1, 0), # 128 (7, 8, 5, 5, 4, 3, 5, 2, 3, 3, 1, 0, 0, 10, 6, 2, 2, 3, 5, 1, 0, 3, 2, 0, 1, 0), # 129 (5, 5, 5, 11, 4, 2, 2, 0, 2, 0, 1, 1, 0, 11, 3, 3, 4, 4, 2, 1, 1, 3, 1, 2, 0, 0), # 130 (9, 2, 5, 9, 7, 1, 0, 0, 0, 2, 0, 1, 0, 5, 6, 4, 1, 7, 3, 2, 1, 3, 2, 1, 0, 0), # 131 (3, 2, 10, 4, 12, 1, 1, 3, 3, 1, 1, 0, 0, 3, 7, 6, 4, 4, 5, 0, 4, 3, 1, 2, 0, 0), # 132 (9, 4, 5, 7, 5, 2, 3, 0, 5, 1, 1, 0, 0, 12, 2, 8, 3, 6, 4, 2, 0, 4, 2, 3, 1, 0), # 133 (8, 3, 6, 4, 0, 3, 3, 1, 3, 1, 0, 0, 0, 4, 6, 5, 4, 7, 1, 4, 3, 1, 2, 2, 0, 0), # 134 (6, 2, 8, 4, 2, 5, 0, 0, 3, 5, 0, 0, 0, 7, 6, 1, 3, 7, 3, 1, 3, 3, 1, 1, 0, 0), # 135 (3, 6, 6, 6, 5, 3, 2, 0, 3, 0, 1, 0, 0, 7, 5, 5, 2, 3, 0, 2, 2, 3, 1, 1, 0, 0), # 136 (5, 6, 3, 6, 0, 2, 2, 2, 3, 1, 3, 0, 0, 7, 6, 3, 0, 2, 2, 0, 2, 1, 4, 1, 0, 0), # 137 (4, 8, 5, 5, 4, 2, 3, 2, 4, 3, 0, 1, 0, 12, 7, 4, 3, 3, 1, 5, 2, 3, 0, 1, 0, 0), # 138 (5, 5, 10, 9, 6, 2, 1, 2, 0, 1, 0, 1, 0, 7, 5, 3, 2, 3, 1, 2, 2, 0, 2, 0, 0, 0), # 139 (5, 3, 2, 10, 1, 1, 3, 1, 4, 0, 0, 2, 0, 8, 8, 7, 5, 4, 0, 4, 1, 1, 0, 0, 0, 0), # 140 (6, 8, 9, 11, 4, 4, 3, 0, 1, 0, 1, 1, 0, 8, 5, 5, 3, 6, 3, 0, 1, 2, 3, 1, 0, 0), # 141 (8, 6, 7, 8, 6, 4, 1, 3, 3, 2, 2, 0, 0, 7, 10, 6, 7, 7, 0, 1, 0, 1, 4, 2, 1, 0), # 142 (5, 8, 7, 3, 4, 2, 1, 3, 1, 2, 0, 0, 0, 11, 9, 2, 1, 6, 1, 1, 1, 0, 3, 1, 0, 0), # 143 (9, 1, 5, 5, 5, 2, 1, 3, 3, 0, 0, 1, 0, 10, 4, 5, 5, 5, 2, 2, 1, 2, 6, 0, 1, 0), # 144 (10, 3, 12, 10, 4, 2, 0, 1, 2, 1, 0, 0, 0, 3, 4, 3, 4, 2, 2, 2, 1, 3, 2, 0, 1, 0), # 145 (6, 7, 5, 14, 4, 2, 2, 2, 5, 0, 0, 0, 0, 5, 6, 4, 1, 3, 5, 2, 1, 1, 3, 0, 0, 0), # 146 (3, 5, 4, 6, 5, 2, 3, 2, 3, 2, 2, 0, 0, 8, 3, 7, 0, 8, 2, 5, 0, 2, 3, 3, 1, 0), # 147 (6, 5, 9, 7, 4, 1, 5, 2, 5, 1, 1, 0, 0, 4, 4, 4, 5, 8, 1, 5, 1, 2, 3, 2, 0, 0), # 148 (8, 4, 8, 5, 4, 1, 2, 0, 4, 1, 1, 0, 0, 5, 7, 5, 0, 4, 5, 2, 3, 3, 1, 1, 0, 0), # 149 (4, 5, 5, 5, 3, 1, 0, 4, 4, 1, 0, 0, 0, 9, 4, 4, 2, 9, 3, 1, 1, 3, 3, 1, 0, 0), # 150 (7, 8, 5, 6, 2, 2, 3, 3, 2, 1, 1, 0, 0, 8, 8, 5, 8, 7, 4, 2, 0, 3, 4, 4, 0, 0), # 151 (11, 5, 5, 6, 5, 2, 0, 2, 5, 1, 2, 0, 0, 7, 1, 5, 4, 1, 2, 1, 2, 1, 2, 1, 0, 0), # 152 (4, 7, 5, 7, 6, 1, 0, 2, 1, 1, 0, 0, 0, 8, 4, 5, 5, 10, 5, 1, 2, 5, 1, 1, 0, 0), # 153 (7, 8, 5, 3, 4, 2, 1, 1, 3, 1, 0, 0, 0, 6, 7, 4, 2, 10, 4, 3, 0, 3, 3, 2, 0, 0), # 154 (6, 3, 3, 5, 3, 2, 0, 3, 4, 0, 0, 0, 0, 14, 5, 5, 1, 6, 5, 1, 1, 1, 4, 1, 0, 0), # 155 (9, 4, 4, 2, 4, 1, 2, 2, 3, 1, 0, 0, 0, 4, 5, 4, 1, 5, 4, 2, 2, 4, 5, 3, 1, 0), # 156 (2, 6, 7, 4, 7, 5, 3, 1, 0, 3, 1, 0, 0, 7, 8, 6, 2, 2, 2, 1, 2, 1, 3, 1, 0, 0), # 157 (3, 5, 3, 3, 5, 0, 2, 1, 5, 2, 0, 0, 0, 2, 6, 8, 6, 3, 1, 3, 2, 0, 1, 4, 0, 0), # 158 (4, 5, 11, 9, 5, 2, 1, 4, 4, 1, 1, 1, 0, 10, 6, 4, 1, 7, 4, 2, 4, 0, 2, 2, 1, 0), # 159 (3, 6, 5, 4, 3, 1, 1, 4, 0, 0, 1, 2, 0, 10, 7, 3, 1, 3, 2, 2, 2, 3, 2, 0, 1, 0), # 160 (4, 3, 5, 8, 6, 2, 3, 0, 1, 1, 0, 1, 0, 11, 3, 3, 4, 5, 4, 1, 2, 4, 1, 0, 0, 0), # 161 (2, 5, 3, 6, 3, 3, 0, 3, 1, 3, 1, 0, 0, 9, 6, 6, 3, 4, 5, 0, 1, 5, 2, 0, 0, 0), # 162 (6, 3, 9, 2, 5, 1, 1, 0, 3, 0, 0, 1, 0, 5, 4, 2, 1, 4, 3, 2, 1, 6, 0, 2, 0, 0), # 163 (3, 7, 5, 6, 7, 1, 1, 2, 4, 1, 2, 1, 0, 3, 3, 5, 0, 2, 2, 2, 0, 2, 2, 2, 1, 0), # 164 (8, 2, 3, 5, 3, 1, 1, 1, 2, 1, 0, 1, 0, 6, 6, 5, 2, 7, 5, 2, 2, 1, 1, 0, 0, 0), # 165 (1, 2, 7, 8, 7, 3, 1, 4, 0, 1, 0, 0, 0, 6, 5, 7, 3, 8, 1, 2, 4, 3, 0, 0, 0, 0), # 166 (7, 3, 5, 9, 6, 0, 2, 2, 2, 1, 0, 0, 0, 4, 8, 2, 2, 3, 1, 3, 1, 3, 1, 2, 0, 0), # 167 (5, 3, 4, 5, 3, 2, 1, 0, 0, 0, 0, 1, 0, 7, 2, 5, 3, 7, 4, 0, 3, 4, 1, 0, 0, 0), # 168 (4, 2, 5, 5, 2, 3, 2, 0, 4, 1, 2, 3, 0, 4, 5, 4, 1, 5, 1, 0, 3, 3, 0, 1, 0, 0), # 169 (2, 1, 3, 4, 6, 3, 1, 1, 2, 1, 0, 0, 0, 8, 0, 2, 2, 4, 3, 0, 0, 4, 2, 0, 0, 0), # 170 (5, 1, 3, 5, 2, 0, 3, 0, 0, 1, 1, 0, 0, 3, 7, 4, 2, 2, 1, 1, 2, 0, 3, 0, 0, 0), # 171 (3, 2, 5, 3, 2, 1, 1, 1, 2, 1, 0, 0, 0, 1, 5, 0, 2, 3, 1, 1, 0, 2, 0, 0, 0, 0), # 172 (2, 3, 4, 4, 2, 6, 2, 0, 1, 1, 0, 0, 0, 3, 5, 3, 1, 3, 0, 1, 1, 1, 1, 0, 0, 0), # 173 (2, 0, 2, 2, 3, 1, 2, 1, 2, 0, 2, 0, 0, 5, 2, 1, 1, 5, 2, 1, 0, 3, 0, 1, 0, 0), # 174 (2, 1, 2, 3, 4, 2, 2, 1, 2, 0, 0, 0, 0, 5, 2, 2, 0, 4, 2, 0, 1, 1, 0, 2, 0, 0), # 175 (2, 2, 4, 3, 1, 2, 1, 1, 1, 0, 0, 0, 0, 4, 3, 1, 1, 2, 2, 1, 2, 3, 2, 2, 0, 0), # 176 (1, 1, 1, 5, 2, 1, 0, 0, 4, 0, 0, 0, 0, 3, 5, 1, 0, 3, 1, 0, 0, 2, 2, 0, 0, 0), # 177 (1, 1, 4, 1, 2, 1, 1, 1, 1, 0, 1, 0, 0, 9, 2, 3, 1, 4, 0, 1, 2, 2, 1, 0, 0, 0), # 178 (0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0), # 179 ) station_arriving_intensity = ( (4.0166924626974145, 4.420230847754533, 4.169026583690005, 4.971734219090746, 4.4437484860876895, 2.5109239456298713, 3.3168284922991322, 3.7225409383835384, 4.872079249734406, 3.166412012417896, 3.3642121311084825, 3.918332062644939, 4.067104170062691), # 0 (4.283461721615979, 4.712048555315807, 4.444277273064122, 5.3001154026212935, 4.737992269979389, 2.6767868672340445, 3.535575153010955, 3.9676109783245668, 5.1937962610663275, 3.37518455382172, 3.5864769087649053, 4.176973328651484, 4.3358333179518835), # 1 (4.549378407183785, 5.0027081367127835, 4.718433828437931, 5.627190163731836, 5.0311703789997955, 2.841988091609956, 3.7534548063685635, 4.211700198323536, 5.514229445502039, 3.583131020016437, 3.8078585190210505, 4.434586121642444, 4.603491862567752), # 2 (4.81340623451725, 5.291056401549158, 4.9904086954558835, 5.951661126025659, 5.322129340801522, 3.0058724980680904, 3.9696029133183646, 4.453840925995606, 5.832108128736874, 3.7894261587409446, 4.027478729461906, 4.690148547944369, 4.869018245003381), # 3 (5.074508918732786, 5.57594015942862, 5.259114319762429, 6.272230913106056, 5.609715683037194, 3.1677849659189343, 4.183154934806767, 4.6930654889559325, 6.146161636466166, 3.993244717734143, 4.24445930767246, 4.942638713883811, 5.131350906351854), # 4 (5.331650174946809, 5.856206219954871, 5.523463147002015, 6.587602148576315, 5.892775933359424, 3.3270703744729717, 4.393246331780179, 4.928406214819674, 6.455119294385248, 4.193761444734931, 4.457922021237706, 5.191034725787318, 5.389428287706262), # 5 (5.583793718275733, 6.130701392731601, 5.782367622819093, 6.896477456039722, 6.170156619420835, 3.4830736030406912, 4.59901256518501, 5.158895431201991, 6.757710428189452, 4.390151087482207, 4.666988637742626, 5.434314689981447, 5.642188830159686), # 6 (5.829903263835975, 6.398272487362505, 6.034740192858108, 7.19755945909957, 6.440704268874043, 3.6351395309325767, 4.799589095967668, 5.383565465718042, 7.052664363574116, 4.58158839371487, 4.870780924772215, 5.671456712792743, 5.888570974805216), # 7 (6.068942526743948, 6.65776631345128, 6.279493302763517, 7.489550781359142, 6.703265409371669, 3.782613037459112, 4.994111385074558, 5.60144864598298, 7.338710426234565, 4.76724811117182, 5.068420649911457, 5.901438900547762, 6.127513162735934), # 8 (6.299875222116068, 6.908029680601619, 6.515539398179763, 7.771154046421735, 6.956686568566328, 3.924839001930787, 5.181714893452096, 5.811577299611971, 7.6145779418661395, 4.946304987591954, 5.259029580745342, 6.123239359573051, 6.35795383504493), # 9 (6.5216650650687455, 7.147909398417212, 6.7417909247512995, 8.04107187789063, 7.199814274110641, 4.061162303658086, 5.361535082046684, 6.012983754220169, 7.878996236164172, 5.117933770714171, 5.441729484858859, 6.335836196195162, 6.578831432825289), # 10 (6.7332757707184046, 7.3762522765017655, 6.957160328122573, 8.298006899369119, 7.431495053657227, 4.190927821951495, 5.532707411804733, 6.204700337422732, 8.130694634823994, 5.281309208277375, 5.615642129836999, 6.538207516740648, 6.78908439717009), # 11 (6.93367105418145, 7.591905124458958, 7.160560053938032, 8.54066173446049, 7.650575434858702, 4.313480436121496, 5.694367343672649, 6.385759376834817, 8.368402463540944, 5.435606048020458, 5.7798892832647475, 6.729331427536055, 6.987651169172428), # 12 (7.121814630574301, 7.793714751892496, 7.3509025478421295, 8.767739006768036, 7.855901945367681, 4.428165025478579, 5.845650338596845, 6.555193200071585, 8.590849048010346, 5.579999037682324, 5.933592712727095, 6.908186034907937, 7.173470189925388), # 13 (7.296670215013373, 7.980527968406071, 7.527100255479318, 8.977941339895034, 8.046321112836791, 4.5343264693332275, 5.9856918575237295, 6.7120341347481975, 8.796763713927538, 5.713662925001867, 6.0758741858090275, 7.073749445182848, 7.345479900522051), # 14 (7.457201522615084, 8.151191583603374, 7.688065622494034, 9.169971357444789, 8.220679464918646, 4.63130964699593, 6.1136273613997005, 6.855314508479805, 8.984875786987855, 5.835772457717993, 6.2058554700955355, 7.224999764687337, 7.502618742055505), # 15 (7.602372268495841, 8.304552407088106, 7.83271109453074, 9.342531683020573, 8.377823529265866, 4.718459437777168, 6.228592311171181, 6.984066648881569, 9.153914592886629, 5.945502383569597, 6.32265833317161, 7.360915099747952, 7.643825155618837), # 16 (7.73114616777206, 8.439457248463958, 7.959949117233882, 9.49432494022569, 8.516599833531071, 4.795120720987429, 6.329722167784569, 7.097322883568655, 9.302609457319187, 6.042027450295574, 6.425404542622239, 7.480473556691244, 7.768037582305133), # 17 (7.842486935560164, 8.55475291733462, 8.068692136247904, 9.624053752663423, 8.635854905366871, 4.860638375937203, 6.416152392186281, 7.194115540156209, 9.429689705980877, 6.1245224056348295, 6.513215866032407, 7.582653241843772, 7.874194463207477), # 18 (7.935358286976559, 8.649286223303795, 8.157852597217262, 9.730420743937053, 8.734435272425893, 4.914357281936967, 6.4870184453227155, 7.273476946259397, 9.533884664567024, 6.192161997326263, 6.585214070987103, 7.666432261532077, 7.961234239418957), # 19 (8.008723937137665, 8.72190397597517, 8.226342945786403, 9.812128537649883, 8.811187462360754, 4.955622318297215, 6.54145578814029, 7.334439429493374, 9.61392365877296, 6.2441209731087675, 6.64052092507132, 7.730788722082713, 8.02809535203266), # 20 (8.061547601159893, 8.771452984952447, 8.273075627599775, 9.86787975740519, 8.864958002824071, 4.983778364328429, 6.578599881585408, 7.376035317473299, 9.668536014294018, 6.279574080721244, 6.678258195870048, 7.774700729822235, 8.073716242141662), # 21 (8.092792994159664, 8.796780059839316, 8.296963088301828, 9.89637702680627, 8.89459342146846, 4.998170299341094, 6.59758618660448, 7.397296937814332, 9.696451056825532, 6.297696067902594, 6.697547650968272, 7.797146391077192, 8.097035350839063), # 22 (8.104314690674112, 8.799778875171468, 8.299938545953362, 9.899944650205763, 8.902185644826078, 5.0, 6.599843201807471, 7.399595061728395, 9.699940987654323, 6.299833818015546, 6.699966429729392, 7.799918061271147, 8.1), # 23 (8.112809930427323, 8.79802962962963, 8.299451851851853, 9.899505555555557, 8.906486090891882, 5.0, 6.598603050108934, 7.3964, 9.699473333333334, 6.29852049382716, 6.699699663299665, 7.799269135802469, 8.1), # 24 (8.121125784169264, 8.794581618655693, 8.29849108367627, 9.898636831275722, 8.910691956475603, 5.0, 6.596159122085048, 7.390123456790125, 9.69854938271605, 6.295935070873343, 6.69917071954109, 7.797988111568358, 8.1), # 25 (8.129261615238427, 8.789487517146778, 8.297069410150893, 9.897348353909464, 8.914803094736884, 5.0, 6.592549374646977, 7.380883950617285, 9.69718098765432, 6.29212056698674, 6.698384387080684, 7.7960925468678575, 8.1), # 26 (8.13721678697331, 8.7828, 8.2952, 9.89565, 8.918819358835371, 5.0, 6.587811764705883, 7.3688, 9.69538, 6.28712, 6.697345454545455, 7.793600000000001, 8.1), # 27 (8.1449906627124, 8.774571742112483, 8.292896021947874, 9.893551646090536, 8.922740601930721, 5.0, 6.581984249172921, 7.353990123456791, 9.693158271604938, 6.2809763877457705, 6.696058710562415, 7.790528029263832, 8.1), # 28 (8.1525826057942, 8.764855418381345, 8.290170644718794, 9.89106316872428, 8.926566677182576, 5.0, 6.575104784959253, 7.3365728395061724, 9.690527654320988, 6.273732748056699, 6.6945289437585735, 7.78689419295839, 8.1), # 29 (8.159991979557198, 8.753703703703705, 8.287037037037036, 9.888194444444444, 8.930297437750589, 5.0, 6.567211328976035, 7.316666666666666, 9.6875, 6.265432098765433, 6.692760942760943, 7.782716049382715, 8.1), # 30 (8.167218147339886, 8.741169272976682, 8.283508367626887, 9.88495534979424, 8.933932736794407, 5.0, 6.558341838134432, 7.2943901234567905, 9.684087160493828, 6.256117457704619, 6.6907594961965335, 7.778011156835849, 8.1), # 31 (8.174260472480764, 8.727304801097395, 8.27959780521262, 9.881355761316874, 8.937472427473677, 5.0, 6.548534269345599, 7.269861728395063, 9.680300987654322, 6.245831842706905, 6.688529392692356, 7.772797073616828, 8.1), # 32 (8.181118318318317, 8.712162962962962, 8.27531851851852, 9.877405555555555, 8.94091636294805, 5.0, 6.537826579520697, 7.243200000000001, 9.676153333333334, 6.234618271604939, 6.6860754208754205, 7.7670913580246905, 8.1), # 33 (8.187791048191048, 8.695796433470507, 8.270683676268861, 9.873114609053498, 8.944264396377173, 5.0, 6.526256725570888, 7.214523456790123, 9.671656049382719, 6.222519762231368, 6.68340236937274, 7.760911568358482, 8.1), # 34 (8.194278025437447, 8.678257887517146, 8.26570644718793, 9.868492798353909, 8.947516380920696, 5.0, 6.513862664407327, 7.183950617283951, 9.666820987654322, 6.209579332418839, 6.680515026811323, 7.754275262917239, 8.1), # 35 (8.200578613396004, 8.6596, 8.2604, 9.86355, 8.950672169738269, 5.0, 6.500682352941176, 7.151600000000001, 9.66166, 6.1958400000000005, 6.677418181818182, 7.747200000000001, 8.1), # 36 (8.20669217540522, 8.639875445816186, 8.254777503429356, 9.85829609053498, 8.953731615989538, 5.0, 6.486753748083595, 7.11759012345679, 9.656184938271606, 6.1813447828075, 6.674116623020328, 7.739703337905808, 8.1), # 37 (8.212618074803581, 8.619136899862827, 8.248852126200275, 9.85274094650206, 8.956694572834152, 5.0, 6.4721148067457435, 7.0820395061728405, 9.650407654320988, 6.166136698673983, 6.670615139044769, 7.7318028349337, 8.1), # 38 (8.218355674929589, 8.597437037037038, 8.242637037037039, 9.846894444444445, 8.959560893431762, 5.0, 6.456803485838781, 7.045066666666667, 9.644340000000001, 6.150258765432099, 6.666918518518519, 7.723516049382716, 8.1), # 39 (8.22390433912173, 8.574828532235939, 8.236145404663922, 9.84076646090535, 8.962330430942016, 5.0, 6.440857742273865, 7.006790123456792, 9.637993827160495, 6.133754000914496, 6.663031550068587, 7.714860539551899, 8.1), # 40 (8.229263430718502, 8.551364060356653, 8.229390397805213, 9.834366872427985, 8.965003038524562, 5.0, 6.424315532962156, 6.967328395061729, 9.631380987654321, 6.116665422953818, 6.658959022321986, 7.705853863740284, 8.1), # 41 (8.2344323130584, 8.527096296296298, 8.222385185185187, 9.827705555555557, 8.967578569339047, 5.0, 6.4072148148148145, 6.9268, 9.624513333333335, 6.0990360493827165, 6.654705723905725, 7.696513580246914, 8.1), # 42 (8.239410349479915, 8.50207791495199, 8.215142935528121, 9.820792386831277, 8.970056876545122, 5.0, 6.389593544743001, 6.8853234567901245, 9.617402716049384, 6.080908898033837, 6.650276443446813, 7.6868572473708285, 8.1), # 43 (8.244196903321543, 8.47636159122085, 8.2076768175583, 9.813637242798356, 8.972437813302436, 5.0, 6.371489679657872, 6.843017283950619, 9.610060987654322, 6.062326986739826, 6.645675969572266, 7.676902423411066, 8.1), # 44 (8.248791337921773, 8.450000000000001, 8.200000000000001, 9.80625, 8.974721232770637, 5.0, 6.352941176470589, 6.800000000000001, 9.6025, 6.043333333333334, 6.640909090909091, 7.666666666666666, 8.1), # 45 (8.253193016619106, 8.423045816186557, 8.192125651577504, 9.798640534979425, 8.976906988109373, 5.0, 6.333985992092311, 6.756390123456791, 9.594731604938271, 6.023970955647005, 6.635980596084299, 7.656167535436672, 8.1), # 46 (8.257401302752028, 8.39555171467764, 8.18406694101509, 9.790818724279836, 8.978994932478294, 5.0, 6.3146620834341975, 6.712306172839506, 9.586767654320989, 6.004282871513489, 6.630895273724903, 7.64542258802012, 8.1), # 47 (8.261415559659037, 8.367570370370371, 8.175837037037038, 9.782794444444447, 8.980984919037049, 5.0, 6.295007407407407, 6.667866666666668, 9.57862, 5.984312098765432, 6.625657912457912, 7.634449382716049, 8.1), # 48 (8.26523515067863, 8.339154458161865, 8.167449108367627, 9.774577572016462, 8.982876800945286, 5.0, 6.275059920923102, 6.623190123456791, 9.57030049382716, 5.964101655235483, 6.6202733009103385, 7.623265477823503, 8.1), # 49 (8.268859439149294, 8.310356652949247, 8.15891632373114, 9.766177983539094, 8.984670431362652, 5.0, 6.25485758089244, 6.578395061728395, 9.56182098765432, 5.943694558756287, 6.61474622770919, 7.611888431641519, 8.1), # 50 (8.272287788409528, 8.28122962962963, 8.150251851851852, 9.757605555555557, 8.9863656634488, 5.0, 6.23443834422658, 6.5336, 9.553193333333335, 5.923133827160494, 6.609081481481482, 7.600335802469137, 8.1), # 51 (8.275519561797823, 8.251826063100138, 8.141468861454047, 9.748870164609054, 8.987962350363372, 5.0, 6.213840167836683, 6.488923456790123, 9.54442938271605, 5.90246247828075, 6.603283850854222, 7.588625148605397, 8.1), # 52 (8.278554122652675, 8.222198628257889, 8.132580521262005, 9.739981687242798, 8.989460345266023, 5.0, 6.1931010086339064, 6.444483950617284, 9.535540987654322, 5.881723529949703, 6.597358124454421, 7.576774028349337, 8.1), # 53 (8.281390834312573, 8.192400000000001, 8.1236, 9.73095, 8.990859501316402, 5.0, 6.172258823529412, 6.400399999999999, 9.52654, 5.86096, 6.59130909090909, 7.5648, 8.1), # 54 (8.284029060116017, 8.162482853223594, 8.114540466392318, 9.721784979423868, 8.992159671674152, 5.0, 6.151351569434358, 6.35679012345679, 9.517438271604938, 5.84021490626429, 6.585141538845242, 7.552720621856425, 8.1), # 55 (8.286468163401498, 8.132499862825789, 8.105415089163237, 9.712496502057613, 8.993360709498928, 5.0, 6.130417203259905, 6.313772839506173, 9.508247654320988, 5.819531266575218, 6.578860256889887, 7.54055345221765, 8.1), # 56 (8.288707507507507, 8.102503703703704, 8.096237037037039, 9.703094444444446, 8.994462467950374, 5.0, 6.109493681917211, 6.271466666666668, 9.498980000000001, 5.798952098765433, 6.572470033670034, 7.528316049382716, 8.1), # 57 (8.290746455772544, 8.072547050754459, 8.087019478737998, 9.693588683127572, 8.99546480018814, 5.0, 6.088618962317438, 6.2299901234567905, 9.489647160493828, 5.778520420667582, 6.565975657812697, 7.516025971650663, 8.1), # 58 (8.292584371535098, 8.042682578875171, 8.077775582990398, 9.683989094650206, 8.996367559371876, 5.0, 6.067831001371743, 6.189461728395062, 9.480260987654322, 5.758279250114313, 6.55938191794488, 7.503700777320531, 8.1), # 59 (8.294220618133663, 8.012962962962964, 8.068518518518518, 9.674305555555556, 8.99717059866123, 5.0, 6.0471677559912855, 6.15, 9.470833333333335, 5.738271604938272, 6.552693602693603, 7.491358024691358, 8.1), # 60 (8.295654558906731, 7.983440877914953, 8.05926145404664, 9.664547942386832, 8.997873771215849, 5.0, 6.026667183087227, 6.1117234567901235, 9.461376049382716, 5.718540502972108, 6.545915500685871, 7.4790152720621865, 8.1), # 61 (8.296885557192804, 7.954168998628258, 8.050017558299041, 9.654726131687244, 8.998476930195388, 5.0, 6.006367239570725, 6.074750617283951, 9.451900987654321, 5.699128962048469, 6.539052400548697, 7.4666900777320535, 8.1), # 62 (8.297912976330368, 7.9252, 8.0408, 9.644850000000002, 8.998979928759486, 5.0, 5.986305882352941, 6.039200000000001, 9.44242, 5.68008, 6.532109090909092, 7.4544, 8.1), # 63 (8.298736179657919, 7.896586556927298, 8.0316219478738, 9.634929423868314, 8.999382620067799, 5.0, 5.966521068345034, 6.005190123456791, 9.432944938271605, 5.661436634659351, 6.5250903603940635, 7.442162597165067, 8.1), # 64 (8.29935453051395, 7.86838134430727, 8.02249657064472, 9.624974279835392, 8.999684857279973, 5.0, 5.947050754458163, 5.972839506172839, 9.423487654320988, 5.643241883859168, 6.518000997630629, 7.429995427526291, 8.1), # 65 (8.299767392236957, 7.840637037037038, 8.013437037037038, 9.614994444444445, 8.999886493555659, 5.0, 5.927932897603486, 5.942266666666668, 9.414060000000001, 5.625538765432099, 6.510845791245791, 7.417916049382717, 8.1), # 66 (8.299974128165434, 7.813406310013717, 8.004456515775034, 9.604999794238683, 8.999987382054504, 5.0, 5.909205454692165, 5.913590123456792, 9.404673827160494, 5.608370297210792, 6.5036295298665685, 7.405942021033379, 8.1), # 67 (8.29983329158466, 7.786598911456259, 7.9955247599451305, 9.594913392377887, 8.999902364237876, 4.99990720926688, 5.890812155863717, 5.88667508001829, 9.395270278920897, 5.591696353317733, 6.496228790832301, 7.394024017519794, 8.099900120027435), # 68 (8.298513365539453, 7.75939641577061, 7.98639074074074, 9.584226811594203, 8.99912854030501, 4.999173662551441, 5.872214545077291, 5.860079012345679, 9.385438271604938, 5.575045112563544, 6.487890271132376, 7.38177517868746, 8.099108796296298), # 69 (8.295908630047116, 7.731673967874684, 7.977014746227709, 9.572869699409555, 8.997599451303154, 4.9977290047248895, 5.853328107649096, 5.833561957018748, 9.375122313671698, 5.558335619570188, 6.478519109220864, 7.369138209034247, 8.097545867626888), # 70 (8.292055728514343, 7.703448134873224, 7.967400068587105, 9.560858803005905, 8.995334463003308, 4.995596646852614, 5.8341613276311906, 5.807132693187015, 9.364337768632831, 5.541568287474112, 6.468149896627089, 7.356122349770172, 8.095231910150892), # 71 (8.286991304347827, 7.674735483870967, 7.9575499999999995, 9.548210869565217, 8.99235294117647, 4.992800000000001, 5.81472268907563, 5.7808, 9.353100000000001, 5.524743529411765, 6.456817224880384, 7.342736842105264, 8.0921875), # 72 (8.280752000954257, 7.6455525819726535, 7.947467832647462, 9.534942646269458, 8.988674251593642, 4.989362475232434, 5.795020676034474, 5.754572656607225, 9.341424371284866, 5.507861758519595, 6.444555685510071, 7.328990927249535, 8.0884332133059), # 73 (8.273374461740323, 7.615915996283022, 7.937156858710562, 9.52107088030059, 8.98431776002582, 4.985307483615303, 5.775063772559778, 5.728459442158208, 9.329326245999086, 5.49092338793405, 6.431399870045485, 7.314893846413014, 8.083989626200276), # 74 (8.26489533011272, 7.5858422939068095, 7.92662037037037, 9.50661231884058, 8.97930283224401, 4.980658436213993, 5.754860462703601, 5.7024691358024695, 9.31682098765432, 5.473928830791576, 6.417384370015949, 7.300454840805718, 8.078877314814816), # 75 (8.255351249478142, 7.55534804194876, 7.915861659807956, 9.49158370907139, 8.973648834019205, 4.975438744093889, 5.734419230517997, 5.6766105166895295, 9.303923959762232, 5.4568785002286235, 6.402543776950793, 7.2856831516376666, 8.073116855281206), # 76 (8.244778863243274, 7.524449807513609, 7.904884019204388, 9.476001798174986, 8.967375131122408, 4.9696718183203785, 5.7137485600550235, 5.650892363968908, 9.290650525834478, 5.43977280938164, 6.38691268237935, 7.270588020118885, 8.06672882373114), # 77 (8.233214814814815, 7.493164157706095, 7.893690740740741, 9.459883333333334, 8.96050108932462, 4.963381069958848, 5.69285693536674, 5.625323456790124, 9.277016049382715, 5.422612171387073, 6.370525677830941, 7.255178687459391, 8.059733796296298), # 78 (8.220695747599452, 7.461507659630958, 7.88228511659808, 9.443245061728396, 8.953046074396838, 4.956589910074683, 5.671752840505201, 5.5999125743026985, 9.26303589391861, 5.405396999381371, 6.353417354834898, 7.239464394869204, 8.052152349108367), # 79 (8.207258305003878, 7.429496880392938, 7.870670438957475, 9.426103730542136, 8.945029452110063, 4.949321749733272, 5.650444759522465, 5.574668495656151, 9.248725422953818, 5.388127706500981, 6.335622304920551, 7.223454383558348, 8.04400505829904), # 80 (8.192939130434784, 7.397148387096775, 7.85885, 9.408476086956524, 8.936470588235293, 4.9416, 5.628941176470589, 5.549600000000001, 9.2341, 5.370804705882353, 6.317175119617225, 7.207157894736842, 8.0353125), # 81 (8.177774867298861, 7.364478746847206, 7.8468270919067225, 9.390378878153516, 8.927388848543533, 4.933448071940254, 5.607250575401629, 5.524715866483768, 9.219174988568815, 5.353428410661933, 6.298110390454251, 7.190584169614709, 8.026095250342937), # 82 (8.161802159002804, 7.331504526748971, 7.834605006858711, 9.371828851315083, 8.917803598805778, 4.924889376619419, 5.585381440367643, 5.500024874256973, 9.203965752171925, 5.335999233976169, 6.278462708960955, 7.17374244940197, 8.016373885459535), # 83 (8.145057648953301, 7.29824229390681, 7.822187037037037, 9.35284275362319, 8.907734204793028, 4.915947325102881, 5.563342255420687, 5.475535802469135, 9.188487654320987, 5.3185175889615115, 6.258266666666667, 7.156641975308642, 8.006168981481482), # 84 (8.127577980557048, 7.264708615425461, 7.80957647462277, 9.333437332259797, 8.897200032276286, 4.906645328456029, 5.54114150461282, 5.451257430269777, 9.172756058527662, 5.300983888754405, 6.237556855100715, 7.13929198854475, 7.995501114540467), # 85 (8.10939979722073, 7.230920058409665, 7.796776611796983, 9.313629334406873, 8.886220447026547, 4.897006797744247, 5.518787671996097, 5.4271985368084135, 9.156786328303614, 5.283398546491299, 6.216367865792428, 7.121701730320315, 7.984390860768176), # 86 (8.090559742351045, 7.1968931899641575, 7.7837907407407405, 9.293435507246377, 8.874814814814817, 4.887055144032922, 5.496289241622575, 5.403367901234568, 9.140593827160496, 5.265761975308642, 6.194734290271132, 7.103880441845354, 7.972858796296297), # 87 (8.071094459354686, 7.162644577193681, 7.7706221536351165, 9.27287259796028, 8.863002501412089, 4.876813778387441, 5.473654697544313, 5.37977430269776, 9.124193918609969, 5.248074588342881, 6.172690720066159, 7.085837364329892, 7.960925497256517), # 88 (8.051040591638339, 7.128190787202974, 7.75727414266118, 9.251957353730543, 8.850802872589366, 4.8663061118731905, 5.4508925238133665, 5.356426520347508, 9.107601966163696, 5.230336798730466, 6.150271746706835, 7.067581738983948, 7.948611539780521), # 89 (8.030434782608696, 7.093548387096774, 7.74375, 9.230706521739132, 8.838235294117649, 4.855555555555556, 5.428011204481793, 5.333333333333333, 9.090833333333334, 5.2125490196078434, 6.1275119617224885, 7.049122807017544, 7.9359375000000005), # 90 (8.00931367567245, 7.058733943979822, 7.730053017832647, 9.20913684916801, 8.825319131767932, 4.8445855204999235, 5.405019223601649, 5.3105035208047555, 9.073903383630546, 5.194711664111461, 6.104445956642448, 7.0304698096406995, 7.922923954046638), # 91 (7.9877139142362985, 7.023764024956858, 7.716186488340192, 9.187265083199142, 8.812073751311223, 4.833419417771681, 5.381925065224994, 5.287945861911295, 9.056827480566987, 5.176825145377768, 6.081108322996043, 7.011631988063439, 7.909591478052126), # 92 (7.965672141706924, 6.988655197132617, 7.702153703703704, 9.165107971014494, 8.798518518518518, 4.822080658436214, 5.358737213403881, 5.26566913580247, 9.039620987654322, 5.15888987654321, 6.0575336523126, 6.992618583495776, 7.895960648148147), # 93 (7.943225001491024, 6.953424027611842, 7.6879579561042535, 9.142682259796029, 8.784672799160816, 4.810592653558909, 5.335464152190369, 5.243682121627802, 9.022299268404208, 5.140906270744238, 6.033756536121448, 6.973438837147739, 7.882052040466393), # 94 (7.920409136995288, 6.9180870834992705, 7.673602537722909, 9.120004696725712, 8.770555959009119, 4.798978814205152, 5.312114365636515, 5.221993598536809, 9.004877686328305, 5.122874741117297, 6.009811565951917, 6.954101990229344, 7.867886231138546), # 95 (7.89726119162641, 6.882660931899643, 7.659090740740742, 9.097092028985507, 8.756187363834423, 4.787262551440329, 5.288696337794377, 5.200612345679013, 8.987371604938271, 5.104795700798839, 5.985733333333334, 6.934617283950619, 7.853483796296297), # 96 (7.873817808791078, 6.847162139917697, 7.64442585733882, 9.07396100375738, 8.741586379407732, 4.775467276329827, 5.265218552716011, 5.179547142203933, 8.969796387745772, 5.086669562925308, 5.961556429795026, 6.914993959521576, 7.838865312071332), # 97 (7.850115631895988, 6.811607274658171, 7.629611179698216, 9.050628368223297, 8.726772371500042, 4.763616399939035, 5.241689494453475, 5.158806767261089, 8.952167398262459, 5.068496740633154, 5.937315446866325, 6.895241258152239, 7.824051354595337), # 98 (7.826191304347827, 6.776012903225807, 7.614650000000001, 9.027110869565218, 8.711764705882354, 4.751733333333333, 5.218117647058825, 5.138400000000001, 8.9345, 5.050277647058824, 5.913044976076556, 6.875368421052632, 7.8090625000000005), # 99 (7.80208146955329, 6.740395592725341, 7.59954561042524, 9.00342525496511, 8.696582748325667, 4.739841487578113, 5.194511494584116, 5.118335619570188, 8.916809556470051, 5.032012695338767, 5.888779608955048, 6.855384689432774, 7.79391932441701), # 100 (7.777822770919068, 6.704771910261517, 7.584301303155008, 8.979588271604939, 8.681245864600985, 4.727964273738759, 5.17087952108141, 5.09862240512117, 8.899111431184272, 5.013702298609431, 5.86455393703113, 6.835299304502683, 7.7786424039780515), # 101 (7.753451851851853, 6.669158422939069, 7.56892037037037, 8.955616666666668, 8.665773420479303, 4.7161251028806594, 5.1472302106027605, 5.07926913580247, 8.881420987654321, 4.995346870007263, 5.840402551834131, 6.815121507472385, 7.763252314814816), # 102 (7.729005355758336, 6.633571697862738, 7.5534061042524, 8.93152718733226, 8.650184781731623, 4.704347386069197, 5.123572047200224, 5.060284590763604, 8.86375358939186, 4.976946822668712, 5.816360044893379, 6.794860539551898, 7.747769633058984), # 103 (7.704519926045208, 6.598028302137263, 7.537761796982167, 8.907336580783683, 8.634499314128943, 4.692654534369761, 5.099913514925861, 5.041677549154093, 8.846124599908551, 4.958502569730225, 5.792461007738201, 6.774525641951243, 7.732214934842251), # 104 (7.680032206119162, 6.562544802867383, 7.5219907407407405, 8.883061594202898, 8.618736383442267, 4.681069958847737, 5.076263097831727, 5.023456790123458, 8.82854938271605, 4.940014524328251, 5.768740031897927, 6.754126055880443, 7.716608796296296), # 105 (7.655578839386891, 6.527137767157839, 7.5060962277091905, 8.858718974771874, 8.602915355442589, 4.669617070568511, 5.052629279969876, 5.005631092821217, 8.811043301326016, 4.921483099599236, 5.745231708901884, 6.733671022549515, 7.700971793552812), # 106 (7.631196469255085, 6.491823762113369, 7.490081550068588, 8.83432546967257, 8.587055595900912, 4.65831928059747, 5.0290205453923695, 4.988209236396892, 8.793621719250115, 4.9029087086796315, 5.721970630279402, 6.713169783168484, 7.685324502743484), # 107 (7.606921739130435, 6.456619354838711, 7.473950000000001, 8.809897826086958, 8.571176470588235, 4.647200000000001, 5.0054453781512604, 4.9712000000000005, 8.7763, 4.884291764705883, 5.698991387559809, 6.69263157894737, 7.669687500000001), # 108 (7.582791292419635, 6.421541112438604, 7.4577048696845, 8.785452791196994, 8.55529734527556, 4.636282639841488, 4.98191226229861, 4.954612162780065, 8.759093507087334, 4.865632680814438, 5.676328572272432, 6.67206565109619, 7.654081361454047), # 109 (7.558841772529373, 6.38660560201779, 7.441349451303157, 8.761007112184648, 8.539437585733884, 4.625590611187319, 4.9584296818864715, 4.938454503886603, 8.742017604023777, 4.846931870141747, 5.654016775946601, 6.651481240824971, 7.638526663237312), # 110 (7.535109822866345, 6.351829390681004, 7.424887037037038, 8.736577536231884, 8.523616557734206, 4.615147325102881, 4.935006120966905, 4.922735802469136, 8.725087654320989, 4.828189745824256, 5.632090590111643, 6.630887589343731, 7.623043981481482), # 111 (7.51163208683724, 6.317229045532987, 7.408320919067217, 8.712180810520666, 8.507853627047528, 4.6049761926535595, 4.911650063591967, 4.907464837677184, 8.708319021490626, 4.809406720998413, 5.610584606296888, 6.6102939378624885, 7.607653892318244), # 112 (7.488403378962436, 6.282878895028762, 7.391694262601655, 8.687867105993632, 8.492140544138964, 4.595095815371611, 4.888420770925416, 4.892682055024485, 8.691770249006897, 4.790643789290184, 5.589539124922293, 6.589754349203543, 7.592355120674577), # 113 (7.465184718320052, 6.249117746820429, 7.375236540017295, 8.663831537021869, 8.476314683653062, 4.585483686823921, 4.865614566728464, 4.878569007604096, 8.675695228570449, 4.772252134330226, 5.568995469690558, 6.56952973769038, 7.577020331328028), # 114 (7.441907922403196, 6.215957758946438, 7.358957546165854, 8.640067604145424, 8.460326142310882, 4.576114809999011, 4.84324772015325, 4.865122123422967, 8.660099982935032, 4.754260262390462, 5.548923609141675, 6.549630066047081, 7.561605305328301), # 115 (7.418543898590108, 6.183350625033362, 7.342825751987099, 8.616532920213123, 8.444150821107023, 4.566967101829678, 4.821283854022315, 4.852304250319195, 8.644945071382265, 4.736634686759638, 5.529284745017185, 6.530018557989877, 7.546085807804713), # 116 (7.395063554259018, 6.151248038707777, 7.326809628420789, 8.593185098073794, 8.427764621036088, 4.558018479248712, 4.799686591158202, 4.840078236130868, 8.630191053193762, 4.719341920726503, 5.510040079058626, 6.5106584372350005, 7.53043760388658), # 117 (7.371437796788169, 6.119601693596259, 7.310877646406694, 8.569981750576266, 8.411143443092675, 4.549246859188911, 4.7784195543834524, 4.828406928696078, 8.615798487651148, 4.7023484775798075, 5.49115081300754, 6.49151292749868, 7.51463645870322), # 118 (7.347637533555794, 6.088363283325384, 7.294998276884579, 8.546880490569364, 8.394263188271378, 4.540630158583066, 4.757446366520605, 4.817253175852916, 8.601727934036035, 4.685620870608298, 5.4725781486054625, 6.472545252497148, 7.498658137383946), # 119 (7.323633671940129, 6.057484501521727, 7.27913999079421, 8.523838930901915, 8.377099757566798, 4.532146294363972, 4.736730650392203, 4.806579825439474, 8.587939951630046, 4.669125613100724, 5.454283287593933, 6.453718635946638, 7.482478405058078), # 120 (7.299397119319415, 6.026917041811863, 7.26327125907535, 8.500814684422748, 8.359629051973535, 4.523773183464424, 4.716236028820784, 4.796349725293846, 8.574395099714799, 4.652829218345837, 5.436227431714493, 6.434996301563378, 7.466073026854929), # 121 (7.274898783071883, 5.996612597822369, 7.247360552667769, 8.477765363980685, 8.341826972486187, 4.515488742817215, 4.695926124628894, 4.786525723254119, 8.561053937571911, 4.636698199632382, 5.4183717827086815, 6.416341473063601, 7.4494177679038165), # 122 (7.250109570575775, 5.9665228631798195, 7.231376342511229, 8.454648582424555, 8.323669420099353, 4.50727088935514, 4.675764560639071, 4.7770706671583865, 8.547877024483004, 4.62069907024911, 5.400677542318036, 6.397717374163538, 7.432488393334058), # 123 (7.225000389209324, 5.93659953151079, 7.215287099545496, 8.43142195260319, 8.30513229580763, 4.499097540010991, 4.655714959673856, 4.767947404844741, 8.534824919729692, 4.604798343484769, 5.383105912284096, 6.3790872285794205, 7.4152606682749695), # 124 (7.199542146350767, 5.9067942964418565, 7.199061294710339, 8.408043087365408, 8.286191500605618, 4.490946611717565, 4.635740944555791, 4.759118784151273, 8.521858182593595, 4.588962532628107, 5.3656180943484015, 6.360414260027479, 7.397710357855863), # 125 (7.1737057493783425, 5.877058851599596, 7.182667398945519, 8.384469599560044, 8.266822935487914, 4.482796021407654, 4.615806138107416, 4.750547652916074, 8.508937372356334, 4.573158150967874, 5.348175290252491, 6.341661692223948, 7.379813227206063), # 126 (7.147462105670289, 5.84734489061058, 7.166073883190804, 8.36065910203592, 8.247002501449119, 4.474623686014052, 4.595874163151275, 4.742196858977237, 8.496023048299525, 4.557351711792819, 5.3307387017379035, 6.322792748885053, 7.361545041454879), # 127 (7.120782122604837, 5.817604107101388, 7.14924921838596, 8.336569207641865, 8.226706099483833, 4.466407522469555, 4.575908642509906, 4.73402925017285, 8.483075769704788, 4.5415097283916905, 5.3132695305461795, 6.303770653727031, 7.34288156573163), # 128 (7.093636707560226, 5.787788194698593, 7.132161875470752, 8.312157529226706, 8.20590963058665, 4.458125447706956, 4.555873199005851, 4.726007674341008, 8.47005609585374, 4.5255987140532365, 5.2957289784188575, 6.284558630466109, 7.323798565165631), # 129 (7.065996767914694, 5.757848847028773, 7.1147803253849435, 8.28738167963927, 8.18458899575217, 4.449755378659047, 4.53573145546165, 4.7180949793198, 8.456924586028, 4.509585182066206, 5.278078247097476, 6.2651199028185225, 7.3042718048861985), # 130 (7.037833211046475, 5.727737757718502, 7.097073039068305, 8.262199271728381, 8.162720095974995, 4.441275232258625, 4.515447034699847, 4.71025401294732, 8.443641799509189, 4.493435645719348, 5.260278538323575, 6.2454176945004996, 7.2842770500226495), # 131 (7.009116944333808, 5.697406620394355, 7.079008487460597, 8.23656791834287, 8.140278832249724, 4.432662925438482, 4.49498355954298, 4.7024476230616585, 8.430168295578923, 4.4771166183014115, 5.2422910538386915, 6.225415229228274, 7.263790065704301), # 132 (6.979818875154931, 5.666807128682908, 7.060555141501587, 8.210445232331562, 8.11724110557095, 4.423896375131413, 4.474304652813592, 4.694638657500906, 8.416464633518821, 4.460594613101146, 5.224076995384369, 6.205075730718074, 7.242786617060469), # 133 (6.949909910888076, 5.635890976210739, 7.041681472131043, 8.183788826543283, 8.093582816933274, 4.414953498270212, 4.453373937334223, 4.686789964103155, 8.402491372610504, 4.443836143407299, 5.205597564702143, 6.184362422686133, 7.221242469220467), # 134 (6.919360958911483, 5.604609856604419, 7.022355950288727, 8.156556313826863, 8.069279867331296, 4.405812211787674, 4.432155035927415, 4.678864390706496, 8.388209072135584, 4.426807722508621, 5.186813963533554, 6.163238528848682, 7.199133387313616), # 135 (6.888142926603388, 5.572915463490528, 7.002547046914407, 8.128705307031124, 8.044308157759614, 4.396450432616592, 4.410611571415708, 4.670824785149022, 8.373578291375685, 4.409475863693858, 5.167687393620142, 6.1416672729219535, 7.176435136469229), # 136 (6.856226721342027, 5.540759490495638, 6.982223232947849, 8.100193419004901, 8.018643589212827, 4.386846077689759, 4.388707166621645, 4.662633995268823, 8.358559589612426, 4.391807080251762, 5.1481790567034444, 6.119611878622176, 7.153123481816621), # 137 (6.823583250505639, 5.508093631246327, 6.961352979328814, 8.070978262597011, 7.992262062685535, 4.376977063939971, 4.366405444367763, 4.654254868903992, 8.343113526127425, 4.373767885471078, 5.128250154525002, 6.097035569665582, 7.129174188485113), # 138 (6.790183421472455, 5.4748695793691695, 6.939904756997072, 8.041017450656287, 7.965139479172333, 4.366821308300021, 4.343670027476608, 4.64565025389262, 8.327200660202298, 4.355324792640558, 5.107861888826353, 6.073901569768405, 7.104563021604015), # 139 (6.755998141620719, 5.44103902849074, 6.91784703689239, 8.010268596031556, 7.937251739667824, 4.356356727702703, 4.320464538770717, 4.636782998072797, 8.310781551118666, 4.336444315048949, 5.086975461349035, 6.050173102646873, 7.079265746302652), # 140 (6.720998318328665, 5.406553672237617, 6.895148289954529, 7.978689311571642, 7.908574745166603, 4.345561239080812, 4.296752601072636, 4.6276159492826165, 8.293816758158144, 4.317092965985001, 5.065552073834591, 6.02581339201722, 7.053258127710331), # 141 (6.685154858974525, 5.371365204236373, 6.871776987123257, 7.946237210125377, 7.87908439666327, 4.334412759367142, 4.272497837204901, 4.6181119553601695, 8.276266840602354, 4.2972372587374625, 5.043552928024558, 6.000785661595676, 7.026515930956373), # 142 (6.64843867093654, 5.335425318113585, 6.8477015993383406, 7.91286990454158, 7.848756595152423, 4.322889205494485, 4.247663869990055, 4.608233864143545, 8.258092357732918, 4.276843706595082, 5.020939225660475, 5.975053135098472, 6.999014921170094), # 143 (6.610820661592948, 5.298685707495829, 6.822890597539542, 7.878545007669086, 7.817567241628663, 4.310968494395637, 4.222214322250639, 4.597944523470839, 8.239253868831447, 4.255878822846608, 4.997672168483881, 5.948579036241839, 6.970730863480812), # 144 (6.572271738321982, 5.26109806600968, 6.797312452666631, 7.843220132356716, 7.785492237086586, 4.298628543003392, 4.196112816809195, 4.587206781180141, 8.219711933179564, 4.23430912078079, 4.973712958236316, 5.921326588742011, 6.94163952301784), # 145 (6.5327628085018805, 5.2226140872817135, 6.770935635659374, 7.806852891453301, 7.7525074825207945, 4.285847268250545, 4.169322976488264, 4.575983485109542, 8.199427110058885, 4.212101113686376, 4.949022796659319, 5.893259016315216, 6.911716664910495), # 146 (6.49226477951088, 5.1831854649385045, 6.743728617457528, 7.769400897807664, 7.718588878925882, 4.272602587069886, 4.141808424110385, 4.564237483097132, 8.178359958751033, 4.189221314852117, 4.923562885494429, 5.864339542677689, 6.8809380542880945), # 147 (6.450748558727217, 5.142763892606631, 6.715659869000866, 7.730821764268637, 7.683712327296449, 4.258872416394214, 4.113532782498101, 4.551931622981006, 8.156471038537623, 4.1656362375667575, 4.897294426483186, 5.8345313915456565, 6.8492794562799535), # 148 (6.40818505352913, 5.101301063912665, 6.686697861229155, 7.691073103685042, 7.647853728627097, 4.24463467315632, 4.084459674473953, 4.539028752599253, 8.13372090870027, 4.1413123951190505, 4.870178621367128, 5.803797786635354, 6.81671663601539), # 149 (6.364545171294852, 5.058748672483183, 6.656811065082156, 7.65011252890571, 7.610988983912421, 4.229867274288999, 4.054552722860481, 4.525491719789965, 8.110070128520602, 4.116216300797741, 4.8421766718877945, 5.772101951663011, 6.783225358623717), # 150 (6.31979981940262, 5.015058411944763, 6.625967951499634, 7.607897652779464, 7.573093994147022, 4.214548136725044, 4.023775550480226, 4.511283372391235, 8.085479257280232, 4.090314467891583, 4.813249779786724, 5.739407110344858, 6.748781389234255), # 151 (6.273919905230675, 4.970181975923978, 6.594136991421362, 7.5643860881551355, 7.534144660325495, 4.198655177397251, 3.992091780155732, 4.496366558241153, 8.059908854260776, 4.06357340968932, 4.7833591468054575, 5.705676486397127, 6.713360492976318), # 152 (6.226876336157249, 4.924071058047406, 6.561286655787095, 7.519535447881546, 7.4941168834424445, 4.182166313238413, 3.9594650347095355, 4.48070412517781, 8.03331947874386, 4.035959639479703, 4.752465974685533, 5.670873303536052, 6.676938434979222), # 153 (6.178640019560583, 4.87667735194162, 6.527385415536607, 7.473303344807528, 7.452986564492464, 4.165059461181324, 3.9258589369641825, 4.464258921039298, 8.005671690011093, 4.0074396705514825, 4.72053146516849, 5.63496078547786, 6.639490980372286), # 154 (6.129181862818909, 4.827952551233196, 6.492401741609661, 7.425647391781903, 7.410729604470157, 4.147312538158777, 3.891237109742209, 4.446993793663709, 7.976926047344103, 3.9779800161934036, 4.687516819995866, 5.597902155938786, 6.600993894284821), # 155 (6.078472773310465, 4.7778483495487105, 6.456304104946021, 7.3765252016535, 7.367321904370119, 4.128903461103569, 3.85556317586616, 4.428871590889135, 7.947043110024501, 3.9475471896942183, 4.6533832409092035, 5.559660638635059, 6.561422941846148), # 156 (6.02648365841349, 4.726316440514739, 6.419060976485454, 7.32589438727115, 7.322739365186948, 4.109810146948491, 3.8188007581585754, 4.409855160553666, 7.915983437333911, 3.9161077043426733, 4.618091929650039, 5.52019945728291, 6.520753888185581), # 157 (5.971744757124192, 4.672362496617807, 6.378873563121885, 7.271815665320995, 7.274944884696798, 4.088819581053688, 3.780085376742286, 4.388637561879498, 7.881329673279279, 3.882692733032915, 4.580476602031154, 5.478079651355472, 6.477188687532276), # 158 (5.9058294135827225, 4.610452255679582, 6.32539025472239, 7.203181727030763, 7.212153047825303, 4.058951718405683, 3.734570210708573, 4.357770826211506, 7.829141808977716, 3.8418247952789963, 4.533933548495195, 5.425090018946487, 6.420342117536156), # 159 (5.827897675923448, 4.540077382832571, 6.257536766364711, 7.118862008327088, 7.133136105077437, 4.019473036838147, 3.6817949987070273, 4.316479351621878, 7.757940181782921, 3.792964521490315, 4.477807606887632, 5.360401559110278, 6.349136487114865), # 160 (5.738577643668768, 4.461696694464375, 6.1760375775282474, 7.019658003005382, 7.038714499425691, 3.970861793256251, 3.622145156805501, 4.265280426487824, 7.668663813599214, 3.7365265545367503, 4.412593323679766, 5.284613975126057, 6.264299235855278), # 161 (5.638497416341085, 4.375769006962591, 6.0816171676923965, 6.9063712048610615, 6.929708673842564, 3.9135962445651646, 3.5560061010718473, 4.204691339186562, 7.56225172633091, 3.6729255372881853, 4.338785245342897, 5.198326970273035, 6.166557803344267), # 162 (5.528285093462799, 4.2827531367148195, 5.975000016336562, 6.779803107689547, 6.806939071300551, 3.848154647670058, 3.4837632475739206, 4.1352293780953, 7.439642941882325, 3.6025761126145, 4.2568779183483265, 5.102140247830427, 6.0566396291687035), # 163 (5.408568774556308, 4.183107900108657, 5.856910602940141, 6.640755205286254, 6.6712261347721515, 3.7750152594761035, 3.405802012379573, 4.0574118315912555, 7.301776482157779, 3.525892923385575, 4.167365889167357, 4.996653511077443, 5.935272152915463), # 164 (5.279976559144014, 4.077292113531706, 5.728073406982535, 6.490028991446602, 6.523390307229859, 3.6946563368884693, 3.3225078115566578, 3.971755988051637, 7.149591369061584, 3.4432906124712908, 4.0707437042712895, 4.882466463293296, 5.803182814171416), # 165 (5.143136546748318, 3.9657645933715635, 5.589212907943143, 6.328425959966001, 6.3642520316461715, 3.607556136812327, 3.234266061173029, 3.878779135853662, 6.984026624498059, 3.35518382274153, 3.9675059101314236, 4.760178807757201, 5.661099052523436), # 166 (4.998676836891619, 3.8489841560158298, 5.441053585301364, 6.156747604639875, 6.194631750993584, 3.514192916152847, 3.14146217729654, 3.7789985633745413, 6.80602127037152, 3.2619871970661714, 3.858147053219062, 4.630390247748367, 5.509748307558397), # 167 (4.847225529096317, 3.727409617852103, 5.284319918536599, 5.975795419263637, 6.015349908244594, 3.415044931815199, 3.0444815759950434, 3.672931558991488, 6.616514328586284, 3.1641153783150977, 3.743161680005505, 4.493700486546009, 5.34985801886317), # 168 (4.689410722884812, 3.6014997952679835, 5.119736387128247, 5.786370897632707, 5.827226946371696, 3.310590440704556, 2.9437096733363934, 3.561095411081716, 6.416444821046671, 3.0619830093581895, 3.623044336962055, 4.350709227429338, 5.182155626024628), # 169 (4.525860517779507, 3.47171350465107, 4.948027470555708, 5.589275533542496, 5.631083308347387, 3.2013076997260854, 2.8395318853884426, 3.444007408022438, 6.206751769656991, 2.9560047330653263, 3.498289570560013, 4.202016173677567, 5.007368568629644), # 170 (4.3572030133028, 3.3385095623889605, 4.7699176482983825, 5.385310820788429, 5.427739437144165, 3.087674965784959, 2.7323336282190445, 3.3221848381908665, 5.9883741963215655, 2.846595192306391, 3.3693919272706787, 4.048221028569909, 4.826224286265092), # 171 (4.184066308977092, 3.2023467848692557, 4.586131399835669, 5.175278253165917, 5.218015775734523, 2.970170495786347, 2.6225003178960526, 3.1961449899642167, 5.762251122944709, 2.734169029951264, 3.2368459535653553, 3.889923495385577, 4.639450218517843), # 172 (4.007078504324784, 3.063683988479554, 4.39739320464697, 4.959979324470381, 5.002732767090961, 2.84927254663542, 2.51041737048732, 3.066405151719699, 5.529321571430739, 2.6191408888698255, 3.1011461959153426, 3.72772327740378, 4.44777380497477), # 173 (3.8268676988682753, 2.9229799896074544, 4.204427542211682, 4.740215528497233, 4.782710854185973, 2.725459375237348, 2.3964702020607005, 2.9334826118345285, 5.290524563683971, 2.5019254119319574, 2.9627872007919422, 3.5622200779037345, 4.251922485222747), # 174 (3.6440619921299646, 2.7806936046405557, 4.007958892009206, 4.516788359041894, 4.558770479992055, 2.599209238497303, 2.2810442286840464, 2.797894658685917, 5.046799121608725, 2.3829372420075394, 2.8222635146664556, 3.3940136001646515, 4.052623698848646), # 175 (3.459289483632255, 2.6372836499664585, 3.8087117335189427, 4.29049930989978, 4.331732087481704, 2.4710003933204536, 2.164524866425212, 2.6601585806510792, 4.799084267109314, 2.2625910219664536, 2.680069684010184, 3.2237035474657434, 3.8506048854393393), # 176 (3.273178272897546, 2.493208941972761, 3.607410546220291, 4.062149874866306, 4.102416119627419, 2.3413110966119706, 2.0472975313520503, 2.5207916661072263, 4.548319022090056, 2.1413013946785795, 2.536700255294429, 3.051889623086223, 3.6465934845817), # 177 (3.0863564594482376, 2.348928297047063, 3.404779809592651, 3.832541547736893, 3.871643019401691, 2.210619605277026, 1.929747639532414, 2.3803112034315723, 4.295442408455268, 2.0194830030138, 2.39264977499049, 2.879171530305302, 3.4413169358626017), # 178 (0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0), # 179 ) passenger_arriving_acc = ( (3, 5, 6, 5, 3, 2, 3, 1, 0, 0, 1, 0, 0, 5, 2, 0, 3, 1, 0, 2, 3, 2, 1, 1, 1, 0), # 0 (6, 11, 10, 6, 4, 6, 8, 3, 2, 2, 1, 0, 0, 7, 4, 1, 5, 4, 1, 3, 3, 2, 4, 1, 2, 0), # 1 (9, 14, 13, 12, 9, 6, 9, 5, 6, 3, 3, 0, 0, 16, 7, 6, 6, 5, 3, 7, 4, 3, 7, 1, 2, 0), # 2 (12, 20, 22, 17, 14, 9, 9, 8, 6, 5, 4, 0, 0, 19, 11, 12, 12, 6, 5, 7, 8, 5, 9, 2, 3, 0), # 3 (14, 23, 25, 19, 20, 13, 11, 11, 7, 7, 6, 1, 0, 27, 15, 14, 15, 16, 7, 8, 9, 7, 9, 3, 3, 0), # 4 (22, 30, 31, 25, 23, 14, 13, 11, 10, 7, 8, 1, 0, 34, 19, 18, 18, 20, 10, 11, 12, 9, 13, 5, 3, 0), # 5 (29, 37, 33, 33, 23, 15, 17, 13, 10, 8, 12, 1, 0, 39, 21, 21, 23, 25, 13, 12, 13, 11, 17, 6, 4, 0), # 6 (32, 45, 36, 37, 30, 16, 19, 16, 11, 10, 15, 1, 0, 41, 24, 23, 24, 29, 16, 13, 13, 12, 20, 8, 4, 0), # 7 (37, 51, 41, 41, 33, 19, 24, 19, 17, 11, 16, 1, 0, 48, 32, 24, 29, 30, 19, 18, 15, 14, 23, 11, 4, 0), # 8 (43, 59, 49, 50, 34, 22, 29, 21, 19, 11, 17, 3, 0, 59, 38, 29, 33, 33, 19, 23, 16, 15, 26, 12, 4, 0), # 9 (46, 64, 54, 55, 38, 22, 31, 23, 22, 11, 18, 3, 0, 66, 42, 33, 35, 38, 25, 25, 19, 18, 28, 16, 8, 0), # 10 (53, 69, 60, 60, 44, 28, 31, 24, 23, 12, 19, 3, 0, 74, 47, 38, 38, 46, 28, 25, 21, 19, 28, 16, 8, 0), # 11 (65, 75, 65, 64, 52, 29, 34, 26, 28, 13, 20, 4, 0, 81, 51, 46, 40, 52, 32, 28, 22, 20, 30, 18, 9, 0), # 12 (72, 85, 72, 67, 60, 33, 39, 27, 33, 15, 23, 4, 0, 92, 56, 52, 42, 59, 35, 28, 25, 22, 30, 19, 9, 0), # 13 (79, 92, 78, 72, 63, 36, 41, 28, 37, 19, 25, 4, 0, 101, 61, 56, 45, 68, 39, 30, 26, 25, 34, 22, 10, 0), # 14 (85, 102, 79, 82, 67, 39, 42, 30, 39, 23, 26, 4, 0, 107, 71, 58, 48, 73, 43, 34, 26, 28, 36, 24, 12, 0), # 15 (95, 113, 89, 88, 76, 44, 45, 31, 40, 24, 28, 5, 0, 118, 72, 62, 54, 82, 47, 38, 27, 28, 38, 26, 12, 0), # 16 (103, 121, 96, 98, 81, 45, 46, 37, 43, 25, 28, 6, 0, 125, 77, 65, 60, 88, 53, 40, 31, 30, 39, 28, 12, 0), # 17 (108, 131, 106, 104, 83, 49, 48, 38, 44, 29, 30, 7, 0, 137, 85, 70, 65, 94, 58, 44, 31, 35, 42, 29, 13, 0), # 18 (118, 142, 109, 111, 87, 50, 53, 43, 46, 34, 32, 7, 0, 144, 94, 78, 72, 98, 63, 46, 33, 40, 45, 30, 13, 0), # 19 (128, 152, 118, 117, 91, 53, 53, 45, 52, 35, 33, 7, 0, 151, 99, 83, 75, 102, 66, 49, 33, 44, 46, 33, 13, 0), # 20 (139, 163, 122, 125, 101, 55, 54, 50, 57, 36, 35, 8, 0, 155, 104, 85, 81, 108, 74, 52, 34, 48, 50, 34, 13, 0), # 21 (150, 175, 127, 135, 106, 59, 61, 54, 59, 38, 35, 9, 0, 161, 111, 93, 85, 116, 78, 57, 37, 50, 50, 35, 14, 0), # 22 (158, 181, 137, 140, 111, 63, 63, 55, 66, 43, 35, 9, 0, 176, 114, 98, 92, 117, 79, 62, 40, 54, 54, 35, 14, 0), # 23 (166, 187, 149, 149, 119, 63, 67, 56, 70, 46, 35, 10, 0, 183, 123, 102, 95, 122, 87, 69, 42, 56, 59, 35, 16, 0), # 24 (176, 195, 157, 156, 123, 67, 68, 59, 72, 47, 35, 10, 0, 191, 135, 105, 102, 128, 90, 71, 43, 59, 60, 36, 17, 0), # 25 (181, 202, 168, 165, 127, 70, 69, 61, 73, 49, 35, 12, 0, 200, 141, 109, 104, 133, 96, 75, 51, 64, 61, 38, 18, 0), # 26 (195, 213, 177, 169, 134, 72, 72, 64, 75, 51, 37, 13, 0, 205, 146, 112, 108, 137, 101, 79, 53, 67, 64, 39, 18, 0), # 27 (208, 222, 184, 177, 138, 74, 76, 66, 79, 55, 38, 13, 0, 216, 157, 118, 113, 142, 105, 87, 56, 70, 67, 39, 18, 0), # 28 (212, 230, 197, 186, 142, 79, 77, 68, 81, 56, 38, 14, 0, 222, 165, 124, 119, 146, 110, 93, 59, 74, 68, 41, 20, 0), # 29 (219, 236, 197, 191, 144, 83, 80, 69, 88, 59, 38, 14, 0, 233, 173, 134, 124, 155, 111, 96, 61, 79, 71, 43, 22, 0), # 30 (232, 248, 202, 195, 145, 86, 82, 72, 90, 64, 39, 16, 0, 241, 183, 142, 128, 163, 116, 101, 62, 80, 73, 45, 23, 0), # 31 (240, 255, 207, 206, 153, 87, 86, 76, 93, 65, 40, 19, 0, 249, 186, 146, 130, 170, 121, 102, 62, 82, 75, 47, 23, 0), # 32 (248, 264, 214, 211, 154, 89, 88, 78, 99, 68, 40, 20, 0, 253, 195, 155, 131, 176, 125, 105, 64, 84, 82, 49, 23, 0), # 33 (256, 279, 218, 219, 157, 91, 94, 82, 103, 70, 44, 20, 0, 265, 201, 163, 139, 183, 131, 107, 69, 85, 84, 50, 23, 0), # 34 (264, 287, 224, 226, 162, 95, 97, 84, 105, 71, 44, 21, 0, 273, 208, 167, 144, 189, 135, 113, 75, 87, 88, 51, 24, 0), # 35 (272, 293, 230, 235, 168, 99, 103, 91, 105, 72, 44, 23, 0, 278, 217, 172, 148, 197, 140, 116, 78, 91, 88, 52, 27, 0), # 36 (282, 302, 239, 241, 171, 100, 109, 91, 108, 75, 44, 26, 0, 286, 225, 176, 155, 202, 145, 121, 81, 95, 90, 54, 27, 0), # 37 (290, 309, 245, 247, 177, 102, 114, 93, 113, 77, 45, 26, 0, 294, 231, 181, 160, 208, 148, 125, 86, 97, 91, 57, 28, 0), # 38 (302, 319, 252, 254, 181, 104, 119, 99, 117, 77, 45, 27, 0, 299, 237, 186, 168, 212, 151, 128, 86, 99, 91, 59, 29, 0), # 39 (313, 327, 257, 262, 188, 110, 121, 100, 119, 79, 46, 28, 0, 307, 243, 188, 171, 221, 155, 129, 86, 101, 92, 63, 32, 0), # 40 (317, 334, 267, 269, 194, 115, 123, 107, 122, 82, 46, 28, 0, 313, 256, 190, 175, 223, 160, 138, 88, 102, 92, 64, 33, 0), # 41 (329, 345, 268, 275, 197, 117, 125, 111, 126, 82, 46, 29, 0, 324, 264, 192, 180, 229, 160, 140, 92, 105, 96, 65, 34, 0), # 42 (335, 353, 278, 281, 205, 121, 128, 113, 131, 86, 46, 29, 0, 339, 269, 198, 181, 233, 163, 141, 94, 110, 101, 68, 34, 0), # 43 (346, 359, 286, 289, 207, 122, 130, 117, 133, 86, 46, 30, 0, 345, 273, 203, 186, 242, 171, 143, 97, 111, 101, 68, 36, 0), # 44 (357, 367, 295, 297, 216, 124, 132, 121, 134, 86, 47, 30, 0, 351, 281, 213, 190, 252, 175, 147, 101, 112, 103, 69, 39, 0), # 45 (362, 372, 304, 307, 218, 126, 136, 125, 135, 88, 49, 30, 0, 363, 290, 218, 198, 257, 178, 150, 101, 115, 106, 73, 40, 0), # 46 (371, 380, 309, 316, 221, 128, 138, 127, 142, 92, 50, 31, 0, 374, 295, 222, 203, 262, 181, 156, 102, 121, 112, 75, 42, 0), # 47 (374, 388, 313, 320, 225, 130, 139, 129, 146, 94, 52, 32, 0, 381, 298, 225, 206, 267, 185, 160, 103, 122, 112, 75, 42, 0), # 48 (383, 398, 319, 327, 229, 130, 145, 131, 151, 96, 54, 33, 0, 392, 305, 230, 209, 277, 190, 164, 105, 124, 115, 76, 42, 0), # 49 (394, 401, 334, 332, 239, 134, 148, 135, 151, 96, 56, 33, 0, 400, 315, 233, 213, 281, 195, 164, 107, 127, 117, 77, 42, 0), # 50 (403, 407, 340, 340, 245, 140, 152, 138, 152, 97, 57, 33, 0, 405, 319, 244, 219, 287, 198, 165, 111, 128, 119, 78, 43, 0), # 51 (414, 413, 346, 350, 251, 146, 153, 138, 155, 98, 61, 34, 0, 415, 328, 249, 221, 298, 201, 168, 111, 132, 121, 80, 43, 0), # 52 (423, 422, 351, 357, 258, 150, 160, 139, 157, 100, 62, 36, 0, 428, 335, 254, 226, 301, 209, 170, 114, 137, 123, 80, 44, 0), # 53 (428, 429, 359, 360, 264, 153, 164, 143, 161, 101, 64, 36, 0, 435, 343, 264, 230, 312, 211, 176, 117, 140, 125, 83, 45, 0), # 54 (433, 439, 365, 368, 271, 156, 166, 145, 163, 102, 66, 36, 0, 448, 346, 271, 238, 320, 215, 177, 118, 142, 126, 84, 47, 0), # 55 (442, 449, 371, 377, 275, 160, 167, 145, 167, 105, 66, 36, 0, 454, 355, 279, 239, 329, 218, 178, 119, 144, 128, 85, 48, 0), # 56 (453, 460, 379, 386, 283, 165, 174, 150, 172, 106, 68, 36, 0, 462, 361, 281, 245, 336, 222, 180, 122, 146, 132, 87, 49, 0), # 57 (460, 464, 385, 394, 287, 166, 175, 152, 174, 107, 68, 38, 0, 468, 370, 288, 249, 338, 226, 183, 122, 151, 133, 89, 49, 0), # 58 (471, 471, 391, 398, 293, 167, 180, 154, 177, 108, 69, 38, 0, 473, 375, 295, 254, 344, 231, 185, 124, 154, 137, 90, 49, 0), # 59 (483, 477, 392, 403, 299, 169, 183, 158, 179, 109, 70, 39, 0, 479, 380, 298, 259, 353, 233, 192, 125, 155, 138, 90, 49, 0), # 60 (490, 484, 398, 414, 304, 169, 187, 163, 181, 112, 71, 39, 0, 486, 387, 306, 264, 364, 237, 195, 126, 158, 140, 96, 49, 0), # 61 (504, 495, 405, 424, 309, 169, 191, 166, 187, 115, 72, 40, 0, 493, 395, 311, 267, 375, 243, 199, 128, 159, 143, 98, 49, 0), # 62 (508, 504, 406, 429, 321, 173, 193, 169, 192, 115, 72, 40, 0, 506, 403, 322, 273, 385, 245, 202, 129, 164, 146, 99, 49, 0), # 63 (519, 507, 411, 435, 325, 177, 196, 172, 195, 117, 73, 40, 0, 514, 411, 323, 273, 393, 248, 205, 131, 166, 148, 100, 51, 0), # 64 (531, 517, 414, 442, 338, 180, 200, 172, 197, 118, 73, 40, 0, 519, 416, 332, 280, 397, 251, 207, 133, 170, 150, 100, 51, 0), # 65 (544, 525, 421, 449, 347, 185, 200, 173, 203, 119, 74, 40, 0, 527, 419, 335, 288, 401, 253, 209, 134, 173, 152, 103, 52, 0), # 66 (554, 533, 424, 454, 358, 186, 204, 176, 207, 119, 74, 40, 0, 532, 434, 342, 293, 412, 256, 211, 137, 177, 154, 104, 52, 0), # 67 (569, 543, 438, 468, 369, 188, 207, 182, 215, 121, 74, 40, 0, 540, 444, 348, 298, 416, 259, 214, 141, 177, 157, 108, 52, 0), # 68 (578, 550, 444, 475, 373, 188, 208, 185, 215, 123, 74, 40, 0, 549, 448, 350, 303, 422, 263, 218, 145, 181, 160, 110, 52, 0), # 69 (586, 559, 451, 479, 381, 189, 215, 189, 218, 124, 74, 40, 0, 560, 457, 356, 307, 429, 264, 220, 146, 182, 161, 112, 52, 0), # 70 (593, 567, 458, 483, 386, 191, 217, 190, 220, 127, 74, 41, 0, 568, 462, 357, 311, 436, 266, 220, 147, 184, 163, 113, 52, 0), # 71 (599, 573, 464, 487, 392, 197, 220, 192, 225, 127, 74, 41, 0, 576, 469, 365, 315, 441, 267, 225, 147, 188, 172, 114, 52, 0), # 72 (605, 577, 472, 497, 397, 201, 223, 195, 225, 128, 74, 42, 0, 582, 476, 370, 319, 447, 270, 228, 150, 193, 172, 114, 53, 0), # 73 (615, 588, 483, 501, 403, 204, 227, 199, 227, 129, 76, 42, 0, 587, 477, 372, 322, 456, 273, 233, 154, 194, 174, 116, 53, 0), # 74 (622, 591, 492, 511, 410, 208, 227, 199, 228, 130, 76, 42, 0, 595, 482, 377, 326, 463, 275, 235, 159, 194, 177, 117, 53, 0), # 75 (633, 601, 497, 525, 418, 212, 232, 201, 230, 130, 78, 43, 0, 603, 484, 385, 331, 473, 279, 235, 160, 196, 179, 120, 54, 0), # 76 (641, 605, 502, 534, 425, 218, 235, 201, 233, 133, 78, 43, 0, 610, 487, 394, 331, 477, 283, 238, 161, 198, 180, 124, 55, 0), # 77 (647, 606, 506, 541, 429, 223, 237, 207, 235, 133, 81, 43, 0, 619, 494, 400, 333, 485, 288, 240, 162, 202, 183, 126, 58, 0), # 78 (659, 611, 514, 553, 432, 226, 246, 211, 240, 134, 82, 44, 0, 624, 505, 404, 337, 491, 291, 243, 165, 208, 184, 128, 59, 0), # 79 (663, 615, 522, 564, 439, 231, 246, 213, 245, 136, 83, 45, 0, 627, 515, 406, 347, 500, 294, 243, 168, 210, 185, 130, 59, 0), # 80 (673, 619, 531, 574, 449, 231, 248, 216, 249, 137, 84, 45, 0, 633, 518, 412, 349, 504, 298, 244, 171, 215, 188, 131, 60, 0), # 81 (685, 630, 538, 580, 451, 232, 250, 219, 250, 140, 87, 46, 0, 641, 530, 414, 352, 506, 300, 246, 171, 216, 190, 132, 62, 0), # 82 (696, 638, 545, 586, 460, 237, 252, 219, 254, 141, 88, 48, 0, 648, 535, 421, 355, 512, 305, 250, 173, 218, 193, 135, 63, 0), # 83 (702, 648, 547, 593, 462, 239, 254, 222, 256, 144, 89, 49, 0, 661, 543, 429, 360, 519, 308, 254, 174, 224, 196, 135, 64, 0), # 84 (712, 654, 557, 599, 467, 241, 256, 228, 261, 146, 90, 50, 0, 673, 549, 433, 361, 525, 309, 255, 175, 227, 199, 137, 64, 0), # 85 (722, 660, 562, 604, 474, 244, 258, 233, 266, 147, 91, 50, 0, 677, 558, 437, 366, 528, 317, 258, 176, 232, 203, 138, 65, 0), # 86 (736, 663, 569, 612, 481, 246, 261, 235, 268, 148, 91, 51, 0, 684, 562, 445, 369, 539, 319, 260, 177, 234, 205, 141, 66, 0), # 87 (746, 670, 575, 621, 485, 251, 263, 239, 272, 149, 91, 52, 0, 692, 573, 453, 375, 544, 322, 264, 177, 235, 206, 142, 66, 0), # 88 (753, 678, 579, 624, 494, 252, 264, 242, 276, 149, 91, 52, 0, 703, 579, 463, 378, 546, 324, 265, 177, 237, 208, 144, 66, 0), # 89 (762, 684, 587, 630, 498, 254, 265, 249, 279, 149, 91, 53, 0, 714, 584, 468, 382, 553, 327, 268, 177, 237, 213, 145, 68, 0), # 90 (769, 687, 591, 635, 503, 258, 267, 250, 282, 150, 92, 53, 0, 722, 592, 474, 383, 562, 331, 270, 180, 241, 216, 146, 70, 0), # 91 (775, 692, 595, 639, 507, 260, 271, 253, 283, 150, 92, 54, 0, 734, 594, 478, 385, 568, 335, 271, 182, 245, 219, 146, 72, 0), # 92 (781, 694, 598, 647, 514, 262, 278, 256, 285, 150, 93, 55, 0, 741, 595, 487, 388, 573, 338, 271, 184, 247, 220, 148, 72, 0), # 93 (793, 702, 601, 650, 521, 264, 280, 256, 286, 150, 93, 55, 0, 750, 599, 490, 394, 578, 341, 271, 185, 250, 224, 149, 73, 0), # 94 (804, 707, 609, 656, 526, 265, 282, 258, 288, 152, 96, 56, 0, 759, 607, 496, 397, 583, 345, 275, 188, 253, 225, 152, 73, 0), # 95 (808, 714, 615, 665, 528, 272, 285, 264, 292, 157, 97, 56, 0, 767, 614, 501, 403, 588, 347, 278, 190, 256, 230, 152, 73, 0), # 96 (818, 718, 623, 672, 534, 275, 286, 268, 293, 157, 98, 56, 0, 778, 620, 504, 408, 594, 354, 281, 193, 262, 232, 152, 73, 0), # 97 (821, 725, 629, 678, 546, 277, 288, 270, 299, 160, 98, 56, 0, 789, 626, 510, 411, 599, 356, 285, 195, 263, 236, 153, 76, 0), # 98 (838, 731, 630, 691, 551, 282, 291, 270, 302, 161, 99, 56, 0, 799, 636, 516, 414, 602, 361, 289, 195, 265, 238, 153, 76, 0), # 99 (846, 737, 635, 700, 556, 287, 295, 272, 304, 164, 100, 56, 0, 805, 642, 523, 418, 608, 365, 290, 200, 267, 240, 157, 76, 0), # 100 (851, 743, 641, 705, 561, 287, 298, 272, 306, 166, 101, 58, 0, 822, 645, 528, 419, 613, 371, 296, 202, 270, 242, 158, 78, 0), # 101 (856, 748, 646, 709, 570, 288, 300, 276, 307, 167, 102, 59, 0, 830, 650, 534, 423, 620, 374, 300, 204, 273, 245, 159, 78, 0), # 102 (860, 754, 651, 716, 580, 291, 302, 279, 311, 167, 102, 59, 0, 834, 654, 541, 426, 623, 377, 302, 205, 274, 246, 159, 78, 0), # 103 (867, 762, 657, 723, 585, 291, 306, 280, 311, 167, 102, 59, 0, 839, 658, 547, 429, 631, 381, 305, 209, 277, 247, 161, 79, 0), # 104 (876, 769, 661, 728, 589, 295, 306, 285, 312, 170, 102, 59, 0, 846, 664, 552, 433, 638, 383, 306, 211, 279, 247, 161, 80, 0), # 105 (883, 771, 666, 733, 595, 297, 308, 286, 314, 171, 102, 60, 0, 856, 669, 555, 438, 647, 386, 308, 212, 282, 250, 163, 81, 0), # 106 (889, 781, 672, 741, 600, 299, 311, 288, 320, 172, 102, 60, 0, 865, 675, 563, 441, 656, 390, 311, 215, 284, 251, 166, 81, 0), # 107 (893, 787, 679, 748, 606, 303, 313, 290, 324, 173, 103, 60, 0, 875, 678, 565, 444, 661, 396, 312, 217, 286, 252, 168, 81, 0), # 108 (901, 793, 681, 757, 610, 307, 315, 295, 325, 174, 104, 60, 0, 884, 684, 571, 445, 664, 397, 316, 219, 289, 254, 169, 82, 0), # 109 (905, 801, 690, 761, 616, 307, 321, 296, 328, 175, 105, 62, 0, 894, 690, 578, 450, 670, 400, 320, 223, 292, 256, 170, 83, 0), # 110 (913, 804, 698, 768, 623, 310, 327, 299, 331, 176, 106, 62, 0, 905, 698, 581, 457, 679, 405, 325, 224, 297, 257, 173, 83, 0), # 111 (920, 807, 705, 775, 626, 313, 329, 301, 334, 176, 106, 62, 0, 914, 703, 585, 462, 690, 409, 328, 226, 301, 257, 174, 83, 0), # 112 (925, 811, 710, 779, 630, 317, 333, 302, 337, 178, 106, 63, 0, 919, 708, 588, 469, 693, 414, 332, 228, 306, 259, 175, 83, 0), # 113 (927, 815, 715, 784, 633, 318, 335, 303, 337, 179, 108, 63, 0, 930, 714, 597, 472, 703, 416, 336, 232, 310, 262, 177, 84, 0), # 114 (935, 826, 726, 792, 638, 322, 338, 303, 342, 181, 110, 65, 0, 938, 722, 600, 478, 708, 418, 342, 233, 311, 267, 177, 84, 0), # 115 (940, 831, 734, 796, 642, 323, 339, 309, 347, 184, 110, 66, 0, 943, 728, 606, 482, 714, 420, 344, 234, 315, 269, 178, 84, 0), # 116 (952, 836, 738, 801, 643, 331, 342, 309, 353, 186, 110, 66, 0, 951, 736, 608, 483, 720, 423, 346, 236, 319, 271, 179, 84, 0), # 117 (958, 844, 742, 811, 648, 332, 342, 310, 357, 188, 112, 66, 0, 958, 742, 614, 485, 730, 424, 349, 239, 321, 272, 181, 84, 0), # 118 (971, 852, 745, 816, 656, 334, 344, 312, 360, 188, 112, 66, 0, 970, 745, 615, 491, 742, 427, 350, 246, 324, 274, 181, 84, 0), # 119 (978, 857, 751, 827, 660, 336, 347, 316, 362, 191, 112, 66, 0, 978, 753, 620, 496, 745, 431, 353, 248, 326, 276, 181, 86, 0), # 120 (986, 859, 760, 835, 668, 339, 351, 318, 364, 192, 114, 66, 0, 985, 757, 623, 498, 752, 432, 356, 248, 327, 279, 181, 86, 0), # 121 (990, 863, 769, 837, 674, 342, 352, 320, 370, 192, 114, 66, 0, 991, 767, 629, 499, 758, 435, 357, 248, 330, 280, 181, 86, 0), # 122 (998, 868, 772, 843, 678, 346, 354, 321, 372, 195, 115, 66, 0, 996, 772, 633, 500, 764, 436, 360, 248, 332, 282, 182, 86, 0), # 123 (1007, 872, 774, 854, 686, 346, 355, 322, 373, 198, 115, 66, 0, 1003, 778, 636, 503, 771, 440, 361, 251, 335, 283, 184, 87, 0), # 124 (1010, 879, 777, 862, 692, 348, 355, 323, 377, 200, 117, 67, 0, 1012, 781, 639, 508, 775, 441, 363, 252, 341, 285, 186, 88, 0), # 125 (1018, 881, 782, 870, 697, 349, 357, 323, 382, 204, 117, 67, 0, 1018, 787, 643, 509, 780, 444, 366, 253, 343, 287, 187, 88, 0), # 126 (1023, 888, 786, 879, 704, 350, 358, 325, 384, 206, 121, 67, 0, 1025, 788, 646, 510, 788, 445, 368, 254, 351, 290, 187, 88, 0), # 127 (1029, 896, 795, 887, 709, 350, 360, 326, 386, 208, 122, 67, 0, 1032, 797, 648, 512, 795, 447, 368, 255, 354, 292, 189, 89, 0), # 128 (1036, 904, 800, 892, 713, 353, 365, 328, 389, 211, 123, 67, 0, 1042, 803, 650, 514, 798, 452, 369, 255, 357, 294, 189, 90, 0), # 129 (1041, 909, 805, 903, 717, 355, 367, 328, 391, 211, 124, 68, 0, 1053, 806, 653, 518, 802, 454, 370, 256, 360, 295, 191, 90, 0), # 130 (1050, 911, 810, 912, 724, 356, 367, 328, 391, 213, 124, 69, 0, 1058, 812, 657, 519, 809, 457, 372, 257, 363, 297, 192, 90, 0), # 131 (1053, 913, 820, 916, 736, 357, 368, 331, 394, 214, 125, 69, 0, 1061, 819, 663, 523, 813, 462, 372, 261, 366, 298, 194, 90, 0), # 132 (1062, 917, 825, 923, 741, 359, 371, 331, 399, 215, 126, 69, 0, 1073, 821, 671, 526, 819, 466, 374, 261, 370, 300, 197, 91, 0), # 133 (1070, 920, 831, 927, 741, 362, 374, 332, 402, 216, 126, 69, 0, 1077, 827, 676, 530, 826, 467, 378, 264, 371, 302, 199, 91, 0), # 134 (1076, 922, 839, 931, 743, 367, 374, 332, 405, 221, 126, 69, 0, 1084, 833, 677, 533, 833, 470, 379, 267, 374, 303, 200, 91, 0), # 135 (1079, 928, 845, 937, 748, 370, 376, 332, 408, 221, 127, 69, 0, 1091, 838, 682, 535, 836, 470, 381, 269, 377, 304, 201, 91, 0), # 136 (1084, 934, 848, 943, 748, 372, 378, 334, 411, 222, 130, 69, 0, 1098, 844, 685, 535, 838, 472, 381, 271, 378, 308, 202, 91, 0), # 137 (1088, 942, 853, 948, 752, 374, 381, 336, 415, 225, 130, 70, 0, 1110, 851, 689, 538, 841, 473, 386, 273, 381, 308, 203, 91, 0), # 138 (1093, 947, 863, 957, 758, 376, 382, 338, 415, 226, 130, 71, 0, 1117, 856, 692, 540, 844, 474, 388, 275, 381, 310, 203, 91, 0), # 139 (1098, 950, 865, 967, 759, 377, 385, 339, 419, 226, 130, 73, 0, 1125, 864, 699, 545, 848, 474, 392, 276, 382, 310, 203, 91, 0), # 140 (1104, 958, 874, 978, 763, 381, 388, 339, 420, 226, 131, 74, 0, 1133, 869, 704, 548, 854, 477, 392, 277, 384, 313, 204, 91, 0), # 141 (1112, 964, 881, 986, 769, 385, 389, 342, 423, 228, 133, 74, 0, 1140, 879, 710, 555, 861, 477, 393, 277, 385, 317, 206, 92, 0), # 142 (1117, 972, 888, 989, 773, 387, 390, 345, 424, 230, 133, 74, 0, 1151, 888, 712, 556, 867, 478, 394, 278, 385, 320, 207, 92, 0), # 143 (1126, 973, 893, 994, 778, 389, 391, 348, 427, 230, 133, 75, 0, 1161, 892, 717, 561, 872, 480, 396, 279, 387, 326, 207, 93, 0), # 144 (1136, 976, 905, 1004, 782, 391, 391, 349, 429, 231, 133, 75, 0, 1164, 896, 720, 565, 874, 482, 398, 280, 390, 328, 207, 94, 0), # 145 (1142, 983, 910, 1018, 786, 393, 393, 351, 434, 231, 133, 75, 0, 1169, 902, 724, 566, 877, 487, 400, 281, 391, 331, 207, 94, 0), # 146 (1145, 988, 914, 1024, 791, 395, 396, 353, 437, 233, 135, 75, 0, 1177, 905, 731, 566, 885, 489, 405, 281, 393, 334, 210, 95, 0), # 147 (1151, 993, 923, 1031, 795, 396, 401, 355, 442, 234, 136, 75, 0, 1181, 909, 735, 571, 893, 490, 410, 282, 395, 337, 212, 95, 0), # 148 (1159, 997, 931, 1036, 799, 397, 403, 355, 446, 235, 137, 75, 0, 1186, 916, 740, 571, 897, 495, 412, 285, 398, 338, 213, 95, 0), # 149 (1163, 1002, 936, 1041, 802, 398, 403, 359, 450, 236, 137, 75, 0, 1195, 920, 744, 573, 906, 498, 413, 286, 401, 341, 214, 95, 0), # 150 (1170, 1010, 941, 1047, 804, 400, 406, 362, 452, 237, 138, 75, 0, 1203, 928, 749, 581, 913, 502, 415, 286, 404, 345, 218, 95, 0), # 151 (1181, 1015, 946, 1053, 809, 402, 406, 364, 457, 238, 140, 75, 0, 1210, 929, 754, 585, 914, 504, 416, 288, 405, 347, 219, 95, 0), # 152 (1185, 1022, 951, 1060, 815, 403, 406, 366, 458, 239, 140, 75, 0, 1218, 933, 759, 590, 924, 509, 417, 290, 410, 348, 220, 95, 0), # 153 (1192, 1030, 956, 1063, 819, 405, 407, 367, 461, 240, 140, 75, 0, 1224, 940, 763, 592, 934, 513, 420, 290, 413, 351, 222, 95, 0), # 154 (1198, 1033, 959, 1068, 822, 407, 407, 370, 465, 240, 140, 75, 0, 1238, 945, 768, 593, 940, 518, 421, 291, 414, 355, 223, 95, 0), # 155 (1207, 1037, 963, 1070, 826, 408, 409, 372, 468, 241, 140, 75, 0, 1242, 950, 772, 594, 945, 522, 423, 293, 418, 360, 226, 96, 0), # 156 (1209, 1043, 970, 1074, 833, 413, 412, 373, 468, 244, 141, 75, 0, 1249, 958, 778, 596, 947, 524, 424, 295, 419, 363, 227, 96, 0), # 157 (1212, 1048, 973, 1077, 838, 413, 414, 374, 473, 246, 141, 75, 0, 1251, 964, 786, 602, 950, 525, 427, 297, 419, 364, 231, 96, 0), # 158 (1216, 1053, 984, 1086, 843, 415, 415, 378, 477, 247, 142, 76, 0, 1261, 970, 790, 603, 957, 529, 429, 301, 419, 366, 233, 97, 0), # 159 (1219, 1059, 989, 1090, 846, 416, 416, 382, 477, 247, 143, 78, 0, 1271, 977, 793, 604, 960, 531, 431, 303, 422, 368, 233, 98, 0), # 160 (1223, 1062, 994, 1098, 852, 418, 419, 382, 478, 248, 143, 79, 0, 1282, 980, 796, 608, 965, 535, 432, 305, 426, 369, 233, 98, 0), # 161 (1225, 1067, 997, 1104, 855, 421, 419, 385, 479, 251, 144, 79, 0, 1291, 986, 802, 611, 969, 540, 432, 306, 431, 371, 233, 98, 0), # 162 (1231, 1070, 1006, 1106, 860, 422, 420, 385, 482, 251, 144, 80, 0, 1296, 990, 804, 612, 973, 543, 434, 307, 437, 371, 235, 98, 0), # 163 (1234, 1077, 1011, 1112, 867, 423, 421, 387, 486, 252, 146, 81, 0, 1299, 993, 809, 612, 975, 545, 436, 307, 439, 373, 237, 99, 0), # 164 (1242, 1079, 1014, 1117, 870, 424, 422, 388, 488, 253, 146, 82, 0, 1305, 999, 814, 614, 982, 550, 438, 309, 440, 374, 237, 99, 0), # 165 (1243, 1081, 1021, 1125, 877, 427, 423, 392, 488, 254, 146, 82, 0, 1311, 1004, 821, 617, 990, 551, 440, 313, 443, 374, 237, 99, 0), # 166 (1250, 1084, 1026, 1134, 883, 427, 425, 394, 490, 255, 146, 82, 0, 1315, 1012, 823, 619, 993, 552, 443, 314, 446, 375, 239, 99, 0), # 167 (1255, 1087, 1030, 1139, 886, 429, 426, 394, 490, 255, 146, 83, 0, 1322, 1014, 828, 622, 1000, 556, 443, 317, 450, 376, 239, 99, 0), # 168 (1259, 1089, 1035, 1144, 888, 432, 428, 394, 494, 256, 148, 86, 0, 1326, 1019, 832, 623, 1005, 557, 443, 320, 453, 376, 240, 99, 0), # 169 (1261, 1090, 1038, 1148, 894, 435, 429, 395, 496, 257, 148, 86, 0, 1334, 1019, 834, 625, 1009, 560, 443, 320, 457, 378, 240, 99, 0), # 170 (1266, 1091, 1041, 1153, 896, 435, 432, 395, 496, 258, 149, 86, 0, 1337, 1026, 838, 627, 1011, 561, 444, 322, 457, 381, 240, 99, 0), # 171 (1269, 1093, 1046, 1156, 898, 436, 433, 396, 498, 259, 149, 86, 0, 1338, 1031, 838, 629, 1014, 562, 445, 322, 459, 381, 240, 99, 0), # 172 (1271, 1096, 1050, 1160, 900, 442, 435, 396, 499, 260, 149, 86, 0, 1341, 1036, 841, 630, 1017, 562, 446, 323, 460, 382, 240, 99, 0), # 173 (1273, 1096, 1052, 1162, 903, 443, 437, 397, 501, 260, 151, 86, 0, 1346, 1038, 842, 631, 1022, 564, 447, 323, 463, 382, 241, 99, 0), # 174 (1275, 1097, 1054, 1165, 907, 445, 439, 398, 503, 260, 151, 86, 0, 1351, 1040, 844, 631, 1026, 566, 447, 324, 464, 382, 243, 99, 0), # 175 (1277, 1099, 1058, 1168, 908, 447, 440, 399, 504, 260, 151, 86, 0, 1355, 1043, 845, 632, 1028, 568, 448, 326, 467, 384, 245, 99, 0), # 176 (1278, 1100, 1059, 1173, 910, 448, 440, 399, 508, 260, 151, 86, 0, 1358, 1048, 846, 632, 1031, 569, 448, 326, 469, 386, 245, 99, 0), # 177 (1279, 1101, 1063, 1174, 912, 449, 441, 400, 509, 260, 152, 86, 0, 1367, 1050, 849, 633, 1035, 569, 449, 328, 471, 387, 245, 99, 0), # 178 (1279, 1101, 1063, 1174, 912, 449, 441, 400, 509, 260, 152, 86, 0, 1367, 1050, 849, 633, 1035, 569, 449, 328, 471, 387, 245, 99, 0), # 179 ) passenger_arriving_rate = ( (4.0166924626974145, 4.051878277108322, 3.4741888197416713, 3.72880066431806, 2.962498990725126, 1.4647056349507583, 1.6584142461495661, 1.5510587243264744, 1.6240264165781353, 0.7916030031044742, 0.5607020218514138, 0.32652767188707826, 0.0, 4.067104170062691, 3.5918043907578605, 2.803510109257069, 2.374809009313422, 3.2480528331562706, 2.171482214057064, 1.6584142461495661, 1.0462183106791132, 1.481249495362563, 1.2429335547726867, 0.6948377639483343, 0.36835257064621113, 0.0), # 0 (4.283461721615979, 4.319377842372822, 3.703564394220102, 3.97508655196597, 3.1586615133195926, 1.561459005886526, 1.7677875765054776, 1.6531712409685695, 1.7312654203554425, 0.8437961384554302, 0.5977461514608177, 0.34808111072095704, 0.0, 4.3358333179518835, 3.8288922179305267, 2.9887307573040878, 2.53138841536629, 3.462530840710885, 2.3144397373559973, 1.7677875765054776, 1.1153278613475186, 1.5793307566597963, 1.3250288506553236, 0.7407128788440204, 0.39267071294298395, 0.0), # 1 (4.549378407183785, 4.585815791986718, 3.9320281903649423, 4.220392622798877, 3.3541135859998636, 1.6578263867724743, 1.8767274031842818, 1.7548750826348067, 1.838076481834013, 0.8957827550041094, 0.6346430865035085, 0.3695488434702037, 0.0, 4.603491862567752, 4.06503727817224, 3.173215432517542, 2.6873482650123277, 3.676152963668026, 2.4568251156887295, 1.8767274031842818, 1.1841617048374817, 1.6770567929999318, 1.4067975409329592, 0.7864056380729886, 0.41689234472606534, 0.0), # 2 (4.81340623451725, 4.850135034753395, 4.1586739128799035, 4.463745844519244, 3.548086227201014, 1.7534256238730528, 1.9848014566591823, 1.8557670524981693, 1.9440360429122914, 0.9473565396852364, 0.6712464549103178, 0.3908457123286974, 0.0, 4.869018245003381, 4.299302835615671, 3.356232274551589, 2.8420696190557084, 3.8880720858245827, 2.598073873497437, 1.9848014566591823, 1.2524468741950376, 1.774043113600507, 1.487915281506415, 0.8317347825759807, 0.4409213667957632, 0.0), # 3 (5.074508918732786, 5.111278479476234, 4.382595266468691, 4.704173184829542, 3.7398104553581293, 1.8478745634527118, 2.0915774674033836, 1.9554439537316386, 2.048720545488722, 0.998311179433536, 0.7074098846120768, 0.41188655949031766, 0.0, 5.131350906351854, 4.530752154393493, 3.5370494230603833, 2.9949335383006073, 4.097441090977444, 2.737621535224294, 2.0915774674033836, 1.3199104024662227, 1.8699052276790646, 1.5680577282765145, 0.8765190532937384, 0.46466167995238505, 0.0), # 4 (5.331650174946809, 5.368189034958631, 4.602885955835013, 4.940701611432236, 3.9285172889062823, 1.9407910517759004, 2.1966231658900894, 2.0535025895081978, 2.151706431461749, 1.048440361183733, 0.7429870035396177, 0.43258622714894324, 0.0, 5.389428287706262, 4.758448498638375, 3.7149350176980884, 3.145321083551198, 4.303412862923498, 2.8749036253114766, 2.1966231658900894, 1.3862793226970715, 1.9642586444531411, 1.6469005371440792, 0.9205771911670025, 0.48801718499623925, 0.0), # 5 (5.583793718275733, 5.619809610003967, 4.8186396856825775, 5.172358092029792, 4.113437746280557, 2.03179293510707, 2.299506282592505, 2.1495397630008295, 2.2525701427298173, 1.097537771870552, 0.777831439623771, 0.45285955749845397, 0.0, 5.642188830159686, 4.981455132482993, 3.889157198118855, 3.2926133156116553, 4.5051402854596345, 3.0093556682011613, 2.299506282592505, 1.4512806679336214, 2.0567188731402783, 1.724119364009931, 0.9637279371365156, 0.5108917827276335, 0.0), # 6 (5.829903263835975, 5.86508311341563, 5.02895016071509, 5.398169594324678, 4.293802845916028, 2.1204980597106697, 2.399794547983834, 2.2431522773825177, 2.350888121191372, 1.1453970984287176, 0.8117968207953693, 0.47262139273272863, 0.0, 5.888570974805216, 5.198835320060014, 4.058984103976846, 3.436191295286152, 4.701776242382744, 3.1404131883355246, 2.399794547983834, 1.514641471221907, 2.146901422958014, 1.799389864774893, 1.0057900321430182, 0.5331893739468755, 0.0), # 7 (6.068942526743948, 6.102952453997006, 5.232911085636264, 5.617163086019357, 4.468843606247779, 2.2065242718511486, 2.497055692537279, 2.333936935826242, 2.446236808744855, 1.1918120277929551, 0.8447367749852429, 0.49178657504564693, 0.0, 6.127513162735934, 5.409652325502115, 4.223683874926214, 3.5754360833788645, 4.89247361748971, 3.2675117101567386, 2.497055692537279, 1.5760887656079634, 2.2344218031238894, 1.872387695339786, 1.046582217127253, 0.5548138594542734, 0.0), # 8 (6.299875222116068, 6.332360540551483, 5.429616165149803, 5.828365534816301, 4.637791045710885, 2.2894894177929594, 2.590857446726048, 2.421490541504988, 2.538192647288713, 1.2365762468979886, 0.8765049301242238, 0.5102699466310877, 0.0, 6.35795383504493, 5.612969412941963, 4.382524650621119, 3.709728740693965, 5.076385294577426, 3.390086758106983, 2.590857446726048, 1.635349584137828, 2.3188955228554424, 1.9427885116054342, 1.0859232330299606, 0.5756691400501349, 0.0), # 9 (6.5216650650687455, 6.552250281882444, 5.6181591039594165, 6.0308039084179725, 4.799876182740427, 2.3690113438005502, 2.680767541023342, 2.505409897591737, 2.6263320787213904, 1.279483442678543, 0.9069549141431433, 0.5279863496829302, 0.0, 6.578831432825289, 5.807849846512232, 4.534774570715716, 3.838450328035629, 5.252664157442781, 3.5075738566284325, 2.680767541023342, 1.6921509598575357, 2.3999380913702133, 2.010267969472658, 1.1236318207918834, 0.5956591165347678, 0.0), # 10 (6.7332757707184046, 6.761564586793285, 5.797633606768811, 6.223505174526839, 4.954330035771484, 2.444707896138372, 2.7663537059023664, 2.585291807259472, 2.7102315449413314, 1.320327302069344, 0.9359403549728333, 0.5448506263950541, 0.0, 6.78908439717009, 5.993356890345594, 4.679701774864166, 3.9609819062080316, 5.420463089882663, 3.619408530163261, 2.7663537059023664, 1.7462199258131228, 2.477165017885742, 2.07450172484228, 1.1595267213537623, 0.6146876897084805, 0.0), # 11 (6.93367105418145, 6.959246364087378, 5.9671333782816935, 6.405496300845368, 5.100383623239134, 2.516196921070873, 2.8471836718363246, 2.6607330736811736, 2.789467487846981, 1.3589015120051147, 0.9633148805441247, 0.5607776189613379, 0.0, 6.987651169172428, 6.168553808574717, 4.816574402720623, 4.0767045360153435, 5.578934975693962, 3.7250263031536432, 2.8471836718363246, 1.7972835150506232, 2.550191811619567, 2.135165433615123, 1.1934266756563388, 0.63265876037158, 0.0), # 12 (7.121814630574301, 7.144238522568122, 6.125752123201774, 6.575804255076027, 5.237267963578454, 2.5830962648625047, 2.9228251692984224, 2.731330500029827, 2.863616349336782, 1.3949997594205812, 0.9889321187878493, 0.5756821695756614, 0.0, 7.173470189925388, 6.332503865332275, 4.944660593939246, 4.184999278261743, 5.727232698673564, 3.8238627000417584, 2.9228251692984224, 1.8450687606160747, 2.618633981789227, 2.1919347516920094, 1.225150424640355, 0.6494762293243748, 0.0), # 13 (7.296670215013373, 7.315483971038899, 6.272583546232765, 6.733456004921276, 5.3642140752245275, 2.6450237737777162, 2.9928459287618647, 2.7966808894784156, 2.932254571309179, 1.428415731250467, 1.0126456976348381, 0.5894791204319041, 0.0, 7.345479900522051, 6.484270324750944, 5.06322848817419, 4.285247193751401, 5.864509142618358, 3.9153532452697823, 2.9928459287618647, 1.8893026955555114, 2.6821070376122638, 2.244485334973759, 1.254516709246553, 0.6650439973671727, 0.0), # 14 (7.457201522615084, 7.471925618303093, 6.406721352078362, 6.877478518083592, 5.480452976612431, 2.701597294080959, 3.0568136806998503, 2.8563810451999188, 2.9949585956626184, 1.4589431144294984, 1.0343092450159228, 0.6020833137239449, 0.0, 7.502618742055505, 6.622916450963392, 5.171546225079613, 4.376829343288494, 5.989917191325237, 3.9989334632798865, 3.0568136806998503, 1.9297123529149707, 2.7402264883062153, 2.2924928393611976, 1.2813442704156726, 0.6792659653002813, 0.0), # 15 (7.602372268495841, 7.612506373164098, 6.527259245442284, 7.006898762265429, 5.585215686177244, 2.7524346720366815, 3.1142961555855906, 2.9100277703673205, 3.0513048642955427, 1.4863755958923994, 1.0537763888619351, 0.6134095916456628, 0.0, 7.643825155618837, 6.747505508102289, 5.268881944309675, 4.459126787677198, 6.102609728591085, 4.074038878514249, 3.1142961555855906, 1.9660247657404866, 2.792607843088622, 2.3356329207551436, 1.3054518490884568, 0.692046033924009, 0.0), # 16 (7.73114616777206, 7.736169144425294, 6.6332909310282355, 7.120743705169268, 5.677733222354047, 2.7971537539093334, 3.1648610838922844, 2.9572178681536063, 3.1008698191063955, 1.510506862573894, 1.0709007571037066, 0.6233727963909371, 0.0, 7.768037582305133, 6.857100760300307, 5.354503785518533, 4.531520587721681, 6.201739638212791, 4.140105015415049, 3.1648610838922844, 1.9979669670780953, 2.8388666111770235, 2.373581235056423, 1.3266581862056472, 0.7032881040386633, 0.0), # 17 (7.842486935560164, 7.841856840890068, 6.723910113539921, 7.218040314497568, 5.757236603577914, 2.8353723859633684, 3.2080761960931405, 2.9975481417317535, 3.1432299019936254, 1.5311306014087078, 1.085535977672068, 0.6318877701536477, 0.0, 7.874194463207477, 6.950765471690124, 5.427679888360339, 4.593391804226123, 6.286459803987251, 4.196567398424455, 3.2080761960931405, 2.0252659899738346, 2.878618301788957, 2.406013438165856, 1.344782022707984, 0.7128960764445517, 0.0), # 18 (7.935358286976559, 7.928512371361812, 6.798210497681052, 7.29781555795279, 5.822956848283928, 2.866708414463231, 3.2435092226613578, 3.030615394274749, 3.1779615548556746, 1.5480404993315662, 1.0975356784978507, 0.6388693551276732, 0.0, 7.961234239418957, 7.027562906404404, 5.4876783924892525, 4.644121497994697, 6.355923109711349, 4.242861551984649, 3.2435092226613578, 2.0476488674737365, 2.911478424141964, 2.4326051859842637, 1.3596420995362106, 0.720773851941983, 0.0), # 19 (8.008723937137665, 7.995078644643906, 6.855285788155336, 7.359096403237412, 5.874124974907169, 2.8907796856733756, 3.270727894070145, 3.0560164289555725, 3.2046412195909864, 1.5610302432771923, 1.106753487511887, 0.6442323935068929, 0.0, 8.02809535203266, 7.08655632857582, 5.533767437559434, 4.683090729831576, 6.409282439181973, 4.278423000537802, 3.270727894070145, 2.0648426326238396, 2.9370624874535847, 2.4530321344124713, 1.3710571576310673, 0.7268253313312643, 0.0), # 20 (8.061547601159893, 8.040498569539743, 6.89422968966648, 7.400909818053892, 5.909972001882714, 2.90720404585825, 3.289299940792704, 3.0733480489472083, 3.222845338098006, 1.5698935201803115, 1.113043032645008, 0.6478917274851863, 0.0, 8.073716242141662, 7.1268090023370485, 5.56521516322504, 4.709680560540933, 6.445690676196012, 4.302687268526092, 3.289299940792704, 2.0765743184701786, 2.954986000941357, 2.466969939351298, 1.378845937933296, 0.730954415412704, 0.0), # 21 (8.092792994159664, 8.063715054852706, 6.91413590691819, 7.422282770104703, 5.92972894764564, 2.915599341282305, 3.29879309330224, 3.0822070574226386, 3.2321503522751773, 1.574424016975649, 1.1162579418280456, 0.6497621992564327, 0.0, 8.097035350839063, 7.147384191820759, 5.581289709140227, 4.723272050926946, 6.464300704550355, 4.315089880391694, 3.29879309330224, 2.0825709580587892, 2.96486447382282, 2.474094256701568, 1.3828271813836381, 0.7330650049866098, 0.0), # 22 (8.104314690674112, 8.066463968907179, 6.916615454961135, 7.424958487654322, 5.9347904298840515, 2.916666666666667, 3.2999216009037355, 3.0831646090534983, 3.2333136625514407, 1.574958454503887, 1.1166610716215655, 0.6499931717725956, 0.0, 8.1, 7.149924889498552, 5.583305358107827, 4.72487536351166, 6.466627325102881, 4.316430452674898, 3.2999216009037355, 2.0833333333333335, 2.9673952149420257, 2.474986162551441, 1.3833230909922272, 0.7333149062642891, 0.0), # 23 (8.112809930427323, 8.06486049382716, 6.916209876543211, 7.4246291666666675, 5.937657393927921, 2.916666666666667, 3.299301525054467, 3.0818333333333334, 3.2331577777777776, 1.5746301234567905, 1.1166166105499442, 0.6499390946502058, 0.0, 8.1, 7.149330041152263, 5.583083052749721, 4.72389037037037, 6.466315555555555, 4.314566666666667, 3.299301525054467, 2.0833333333333335, 2.9688286969639606, 2.4748763888888896, 1.3832419753086422, 0.7331691358024692, 0.0), # 24 (8.121125784169264, 8.06169981710105, 6.915409236396892, 7.423977623456791, 5.940461304317068, 2.916666666666667, 3.298079561042524, 3.0792181069958855, 3.2328497942386836, 1.5739837677183361, 1.1165284532568485, 0.6498323426306966, 0.0, 8.1, 7.148155768937661, 5.5826422662842425, 4.7219513031550076, 6.465699588477367, 4.31090534979424, 3.298079561042524, 2.0833333333333335, 2.970230652158534, 2.474659207818931, 1.3830818472793784, 0.7328818015546411, 0.0), # 25 (8.129261615238427, 8.057030224051212, 6.914224508459078, 7.423011265432098, 5.943202063157923, 2.916666666666667, 3.2962746873234887, 3.0753683127572025, 3.23239366255144, 1.5730301417466854, 1.1163973978467807, 0.6496743789056548, 0.0, 8.1, 7.146418167962202, 5.581986989233903, 4.719090425240055, 6.46478732510288, 4.305515637860084, 3.2962746873234887, 2.0833333333333335, 2.9716010315789614, 2.4743370884773666, 1.3828449016918156, 0.732457293095565, 0.0), # 26 (8.13721678697331, 8.0509, 6.9126666666666665, 7.4217375, 5.945879572556914, 2.916666666666667, 3.2939058823529415, 3.0703333333333336, 3.231793333333333, 1.5717800000000004, 1.1162242424242426, 0.6494666666666669, 0.0, 8.1, 7.144133333333334, 5.581121212121213, 4.715339999999999, 6.463586666666666, 4.298466666666667, 3.2939058823529415, 2.0833333333333335, 2.972939786278457, 2.4739125000000004, 1.3825333333333334, 0.7319000000000001, 0.0), # 27 (8.1449906627124, 8.043357430269776, 6.910746684956561, 7.420163734567902, 5.948493734620481, 2.916666666666667, 3.2909921245864604, 3.06416255144033, 3.231052757201646, 1.570244096936443, 1.116009785093736, 0.6492106691053194, 0.0, 8.1, 7.141317360158513, 5.580048925468679, 4.710732290809328, 6.462105514403292, 4.289827572016462, 3.2909921245864604, 2.0833333333333335, 2.9742468673102405, 2.4733879115226345, 1.3821493369913125, 0.731214311842707, 0.0), # 28 (8.1525826057942, 8.0344508001829, 6.908475537265661, 7.41829737654321, 5.951044451455051, 2.916666666666667, 3.2875523924796264, 3.0569053497942384, 3.2301758847736624, 1.5684331870141752, 1.1157548239597623, 0.6489078494131992, 0.0, 8.1, 7.13798634354519, 5.578774119798812, 4.705299561042525, 6.460351769547325, 4.279667489711934, 3.2875523924796264, 2.0833333333333335, 2.9755222257275253, 2.4727657921810704, 1.3816951074531325, 0.7304046181984455, 0.0), # 29 (8.159991979557198, 8.02422839506173, 6.905864197530864, 7.416145833333333, 5.953531625167059, 2.916666666666667, 3.2836056644880176, 3.048611111111111, 3.2291666666666665, 1.5663580246913587, 1.115460157126824, 0.648559670781893, 0.0, 8.1, 7.134156378600823, 5.57730078563412, 4.699074074074074, 6.458333333333333, 4.268055555555556, 3.2836056644880176, 2.0833333333333335, 2.9767658125835297, 2.4720486111111115, 1.3811728395061729, 0.7294753086419755, 0.0), # 30 (8.167218147339886, 8.012738500228625, 6.902923639689073, 7.41371651234568, 5.955955157862938, 2.916666666666667, 3.279170919067216, 3.039329218106996, 3.2280290534979423, 1.5640293644261551, 1.1151265826994223, 0.6481675964029875, 0.0, 8.1, 7.129843560432862, 5.575632913497111, 4.692088093278464, 6.456058106995885, 4.2550609053497945, 3.279170919067216, 2.0833333333333335, 2.977977578931469, 2.4712388374485603, 1.3805847279378145, 0.7284307727480569, 0.0), # 31 (8.174260472480764, 8.000029401005945, 6.899664837677183, 7.411016820987655, 5.958314951649118, 2.916666666666667, 3.2742671346727996, 3.029109053497943, 3.226766995884774, 1.5614579606767267, 1.1147548987820595, 0.6477330894680691, 0.0, 8.1, 7.125063984148759, 5.573774493910297, 4.684373882030179, 6.453533991769548, 4.24075267489712, 3.2742671346727996, 2.0833333333333335, 2.979157475824559, 2.470338940329219, 1.3799329675354366, 0.7272754000914496, 0.0), # 32 (8.181118318318317, 7.986149382716048, 6.896098765432099, 7.408054166666666, 5.960610908632033, 2.916666666666667, 3.2689132897603486, 3.0180000000000002, 3.2253844444444444, 1.5586545679012351, 1.114345903479237, 0.6472576131687243, 0.0, 8.1, 7.119833744855966, 5.571729517396184, 4.6759637037037045, 6.450768888888889, 4.225200000000001, 3.2689132897603486, 2.0833333333333335, 2.9803054543160163, 2.469351388888889, 1.37921975308642, 0.7260135802469135, 0.0), # 33 (8.187791048191048, 7.971146730681298, 6.892236396890718, 7.404835956790124, 5.962842930918115, 2.916666666666667, 3.263128362785444, 3.006051440329218, 3.2238853497942395, 1.5556299405578424, 1.1139003948954567, 0.6467426306965403, 0.0, 8.1, 7.114168937661942, 5.569501974477284, 4.666889821673526, 6.447770699588479, 4.208472016460905, 3.263128362785444, 2.0833333333333335, 2.9814214654590576, 2.468278652263375, 1.3784472793781437, 0.724649702789209, 0.0), # 34 (8.194278025437447, 7.95506973022405, 6.888088705989941, 7.401369598765432, 5.965010920613797, 2.916666666666667, 3.2569313322036635, 2.9933127572016467, 3.2222736625514408, 1.5523948331047102, 1.1134191711352206, 0.6461896052431033, 0.0, 8.1, 7.108085657674136, 5.5670958556761025, 4.657184499314129, 6.4445473251028815, 4.1906378600823055, 3.2569313322036635, 2.0833333333333335, 2.9825054603068986, 2.4671231995884777, 1.3776177411979884, 0.7231881572930956, 0.0), # 35 (8.200578613396004, 7.937966666666665, 6.8836666666666675, 7.3976625, 5.967114779825512, 2.916666666666667, 3.250341176470588, 2.979833333333334, 3.220553333333333, 1.5489600000000006, 1.1129030303030305, 0.6456000000000002, 0.0, 8.1, 7.101600000000001, 5.564515151515152, 4.64688, 6.441106666666666, 4.1717666666666675, 3.250341176470588, 2.0833333333333335, 2.983557389912756, 2.4658875000000005, 1.3767333333333336, 0.7216333333333333, 0.0), # 36 (8.20669217540522, 7.919885825331503, 6.8789812528577965, 7.393722067901235, 5.969154410659692, 2.916666666666667, 3.2433768740417976, 2.9656625514403294, 3.218728312757202, 1.5453361957018754, 1.1123527705033882, 0.6449752781588174, 0.0, 8.1, 7.09472805974699, 5.561763852516941, 4.636008587105625, 6.437456625514404, 4.1519275720164615, 3.2433768740417976, 2.0833333333333335, 2.984577205329846, 2.4645740226337454, 1.3757962505715595, 0.7199896204846822, 0.0), # 37 (8.212618074803581, 7.9008754915409245, 6.874043438500229, 7.389555709876545, 5.971129715222768, 2.916666666666667, 3.2360574033728717, 2.9508497942386835, 3.2168025514403293, 1.5415341746684963, 1.111769189840795, 0.6443169029111417, 0.0, 8.1, 7.087485932022558, 5.558845949203975, 4.624602524005487, 6.433605102880659, 4.131189711934157, 3.2360574033728717, 2.0833333333333335, 2.985564857611384, 2.4631852366255154, 1.3748086877000458, 0.7182614083219023, 0.0), # 38 (8.218355674929589, 7.880983950617284, 6.868864197530866, 7.3851708333333335, 5.973040595621175, 2.916666666666667, 3.2284017429193903, 2.9354444444444447, 3.21478, 1.5375646913580252, 1.1111530864197532, 0.6436263374485597, 0.0, 8.1, 7.079889711934156, 5.555765432098766, 4.612694074074074, 6.42956, 4.109622222222223, 3.2284017429193903, 2.0833333333333335, 2.9865202978105874, 2.4617236111111116, 1.3737728395061732, 0.7164530864197532, 0.0), # 39 (8.22390433912173, 7.860259487882944, 6.863454503886603, 7.380574845679012, 5.974886953961343, 2.916666666666667, 3.2204288711369324, 2.9194958847736636, 3.212664609053498, 1.5334385002286244, 1.1105052583447648, 0.6429050449626583, 0.0, 8.1, 7.071955494589241, 5.552526291723823, 4.600315500685872, 6.425329218106996, 4.087294238683129, 3.2204288711369324, 2.0833333333333335, 2.9874434769806717, 2.460191615226338, 1.3726909007773205, 0.714569044352995, 0.0), # 40 (8.229263430718502, 7.838750388660264, 6.857825331504345, 7.375775154320989, 5.976668692349708, 2.916666666666667, 3.212157766481078, 2.903053497942387, 3.210460329218107, 1.529166355738455, 1.1098265037203312, 0.6421544886450238, 0.0, 8.1, 7.06369937509526, 5.549132518601655, 4.587499067215363, 6.420920658436214, 4.0642748971193425, 3.212157766481078, 2.0833333333333335, 2.988334346174854, 2.4585917181069967, 1.371565066300869, 0.7126136716963878, 0.0), # 41 (8.2344323130584, 7.816504938271606, 6.85198765432099, 7.370779166666668, 5.978385712892697, 2.916666666666667, 3.2036074074074072, 2.886166666666667, 3.2081711111111115, 1.5247590123456796, 1.1091176206509543, 0.641376131687243, 0.0, 8.1, 7.0551374485596705, 5.5455881032547705, 4.574277037037037, 6.416342222222223, 4.040633333333334, 3.2036074074074072, 2.0833333333333335, 2.9891928564463486, 2.4569263888888897, 1.370397530864198, 0.7105913580246915, 0.0), # 42 (8.239410349479915, 7.7935714220393235, 6.845952446273435, 7.3655942901234575, 5.980037917696748, 2.916666666666667, 3.1947967723715003, 2.868884773662552, 3.2058009053497942, 1.5202272245084596, 1.1083794072411357, 0.6405714372809025, 0.0, 8.1, 7.046285810089926, 5.541897036205678, 4.5606816735253775, 6.4116018106995885, 4.016438683127573, 3.1947967723715003, 2.0833333333333335, 2.990018958848374, 2.4551980967078197, 1.369190489254687, 0.7085064929126659, 0.0), # 43 (8.244196903321543, 7.769998125285779, 6.839730681298583, 7.360227932098766, 5.981625208868291, 2.916666666666667, 3.185744839828936, 2.8512572016460913, 3.2033536625514403, 1.515581746684957, 1.1076126615953779, 0.639741868617589, 0.0, 8.1, 7.037160554793477, 5.538063307976889, 4.54674524005487, 6.4067073251028805, 3.9917600823045283, 3.185744839828936, 2.0833333333333335, 2.9908126044341454, 2.4534093106995893, 1.3679461362597167, 0.7063634659350709, 0.0), # 44 (8.248791337921773, 7.745833333333334, 6.833333333333335, 7.354687500000001, 5.983147488513758, 2.916666666666667, 3.1764705882352944, 2.833333333333334, 3.2008333333333328, 1.510833333333334, 1.106818181818182, 0.638888888888889, 0.0, 8.1, 7.027777777777777, 5.534090909090909, 4.532500000000001, 6.4016666666666655, 3.9666666666666672, 3.1764705882352944, 2.0833333333333335, 2.991573744256879, 2.4515625000000005, 1.366666666666667, 0.7041666666666668, 0.0), # 45 (8.253193016619106, 7.721125331504343, 6.8267713763145865, 7.348980401234568, 5.984604658739582, 2.916666666666667, 3.1669929960461554, 2.81516255144033, 3.198243868312757, 1.5059927389117518, 1.10599676601405, 0.6380139612863894, 0.0, 8.1, 7.018153574150282, 5.5299838300702495, 4.517978216735254, 6.396487736625514, 3.941227572016462, 3.1669929960461554, 2.0833333333333335, 2.992302329369791, 2.4496601337448567, 1.3653542752629175, 0.7019204846822131, 0.0), # 46 (8.257401302752028, 7.695922405121171, 6.8200557841792415, 7.3431140432098765, 5.985996621652196, 2.916666666666667, 3.1573310417170988, 2.7967942386831277, 3.195589218106996, 1.5010707178783727, 1.105149212287484, 0.6371185490016767, 0.0, 8.1, 7.008304039018443, 5.525746061437419, 4.503212153635117, 6.391178436213992, 3.915511934156379, 3.1573310417170988, 2.0833333333333335, 2.992998310826098, 2.4477046810699594, 1.3640111568358484, 0.6996293095564702, 0.0), # 47 (8.261415559659037, 7.670272839506174, 6.8131975308641985, 7.3370958333333345, 5.987323279358032, 2.916666666666667, 3.1475037037037037, 2.7782777777777783, 3.1928733333333335, 1.4960780246913583, 1.1042763187429856, 0.6362041152263375, 0.0, 8.1, 6.998245267489711, 5.521381593714927, 4.488234074074074, 6.385746666666667, 3.88958888888889, 3.1475037037037037, 2.0833333333333335, 2.993661639679016, 2.445698611111112, 1.3626395061728398, 0.6972975308641977, 0.0), # 48 (8.26523515067863, 7.644224919981709, 6.806207590306356, 7.330933179012346, 5.9885845339635235, 2.916666666666667, 3.137529960461551, 2.7596625514403295, 3.190100164609053, 1.491025413808871, 1.1033788834850566, 0.6352721231519587, 0.0, 8.1, 6.987993354671545, 5.5168944174252825, 4.473076241426613, 6.380200329218106, 3.8635275720164617, 3.137529960461551, 2.0833333333333335, 2.9942922669817618, 2.443644393004116, 1.3612415180612714, 0.6949295381801555, 0.0), # 49 (8.268859439149294, 7.617826931870143, 6.799096936442616, 7.324633487654321, 5.989780287575101, 2.916666666666667, 3.12742879044622, 2.7409979423868314, 3.1872736625514397, 1.485923639689072, 1.1024577046181985, 0.6343240359701267, 0.0, 8.1, 6.977564395671393, 5.512288523090993, 4.457770919067215, 6.3745473251028795, 3.8373971193415644, 3.12742879044622, 2.0833333333333335, 2.9948901437875506, 2.441544495884774, 1.3598193872885234, 0.692529721079104, 0.0), # 50 (8.272287788409528, 7.591127160493827, 6.791876543209877, 7.318204166666668, 5.9909104422991994, 2.916666666666667, 3.11721917211329, 2.7223333333333333, 3.184397777777778, 1.4807834567901237, 1.1015135802469138, 0.6333613168724281, 0.0, 8.1, 6.966974485596708, 5.507567901234569, 4.44235037037037, 6.368795555555556, 3.811266666666667, 3.11721917211329, 2.0833333333333335, 2.9954552211495997, 2.4394013888888897, 1.3583753086419754, 0.6901024691358025, 0.0), # 51 (8.275519561797823, 7.564173891175126, 6.78455738454504, 7.311652623456791, 5.991974900242248, 2.916666666666667, 3.1069200839183413, 2.7037181069958844, 3.18147646090535, 1.4756156195701877, 1.1005473084757038, 0.6323854290504498, 0.0, 8.1, 6.956239719554947, 5.502736542378519, 4.4268468587105625, 6.3629529218107, 3.7852053497942384, 3.1069200839183413, 2.0833333333333335, 2.995987450121124, 2.437217541152264, 1.356911476909008, 0.6876521719250116, 0.0), # 52 (8.278554122652675, 7.537015409236398, 6.777150434385004, 7.304986265432099, 5.992973563510682, 2.916666666666667, 3.0965505043169532, 2.6852016460905355, 3.1785136625514405, 1.470430882487426, 1.0995596874090703, 0.6313978356957782, 0.0, 8.1, 6.945376192653559, 5.4977984370453505, 4.411292647462277, 6.357027325102881, 3.7592823045267494, 3.0965505043169532, 2.0833333333333335, 2.996486781755341, 2.4349954218107, 1.355430086877001, 0.6851832190214908, 0.0), # 53 (8.281390834312573, 7.5097000000000005, 6.769666666666667, 7.2982125, 5.993906334210934, 2.916666666666667, 3.086129411764706, 2.6668333333333334, 3.1755133333333334, 1.4652400000000003, 1.098551515151515, 0.6304000000000001, 0.0, 8.1, 6.9344, 5.492757575757575, 4.395720000000001, 6.351026666666667, 3.7335666666666665, 3.086129411764706, 2.0833333333333335, 2.996953167105467, 2.4327375000000004, 1.3539333333333334, 0.6827000000000002, 0.0), # 54 (8.284029060116017, 7.482275948788294, 6.762117055326932, 7.291338734567901, 5.994773114449434, 2.916666666666667, 3.075675784717179, 2.6486625514403292, 3.1724794238683125, 1.4600537265660727, 1.0975235898075406, 0.6293933851547021, 0.0, 8.1, 6.923327236701723, 5.487617949037702, 4.380161179698217, 6.344958847736625, 3.708127572016461, 3.075675784717179, 2.0833333333333335, 2.997386557224717, 2.4304462448559674, 1.3524234110653865, 0.6802069044352995, 0.0), # 55 (8.286468163401498, 7.454791540923639, 6.754512574302698, 7.28437237654321, 5.995573806332619, 2.916666666666667, 3.0652086016299527, 2.6307386831275723, 3.169415884773662, 1.4548828166438048, 1.0964767094816479, 0.6283794543514709, 0.0, 8.1, 6.912173997866179, 5.482383547408239, 4.364648449931414, 6.338831769547324, 3.6830341563786013, 3.0652086016299527, 2.0833333333333335, 2.9977869031663094, 2.4281241255144037, 1.3509025148605398, 0.6777083219021491, 0.0), # 56 (8.288707507507507, 7.427295061728395, 6.746864197530866, 7.277320833333334, 5.996308311966915, 2.916666666666667, 3.0547468409586056, 2.613111111111112, 3.166326666666667, 1.4497380246913585, 1.0954116722783391, 0.627359670781893, 0.0, 8.1, 6.900956378600823, 5.477058361391695, 4.349214074074075, 6.332653333333334, 3.6583555555555565, 3.0547468409586056, 2.0833333333333335, 2.9981541559834577, 2.425773611111112, 1.3493728395061733, 0.6752086419753087, 0.0), # 57 (8.290746455772544, 7.39983479652492, 6.739182898948332, 7.270191512345679, 5.99697653345876, 2.916666666666667, 3.044309481158719, 2.595829218106996, 3.163215720164609, 1.4446301051668957, 1.0943292763021162, 0.6263354976375554, 0.0, 8.1, 6.889690474013108, 5.471646381510581, 4.333890315500686, 6.326431440329218, 3.6341609053497947, 3.044309481158719, 2.0833333333333335, 2.99848826672938, 2.4233971707818935, 1.3478365797896665, 0.6727122542295383, 0.0), # 58 (8.292584371535098, 7.372459030635573, 6.731479652491998, 7.262991820987654, 5.9975783729145835, 2.916666666666667, 3.0339155006858713, 2.578942386831276, 3.160086995884774, 1.4395698125285785, 1.0932303196574802, 0.6253083981100444, 0.0, 8.1, 6.878392379210486, 5.4661515982874, 4.318709437585735, 6.320173991769548, 3.6105193415637866, 3.0339155006858713, 2.0833333333333335, 2.9987891864572918, 2.420997273662552, 1.3462959304984, 0.6702235482395976, 0.0), # 59 (8.294220618133663, 7.345216049382717, 6.723765432098765, 7.255729166666667, 5.998113732440819, 2.916666666666667, 3.0235838779956428, 2.5625000000000004, 3.156944444444445, 1.4345679012345682, 1.092115600448934, 0.6242798353909466, 0.0, 8.1, 6.867078189300411, 5.460578002244669, 4.303703703703704, 6.31388888888889, 3.5875000000000004, 3.0235838779956428, 2.0833333333333335, 2.9990568662204096, 2.4185763888888894, 1.3447530864197532, 0.6677469135802471, 0.0), # 60 (8.295654558906731, 7.3181541380887065, 6.716051211705533, 7.248410956790124, 5.998582514143899, 2.916666666666667, 3.0133335915436135, 2.5465514403292184, 3.1537920164609052, 1.4296351257430273, 1.0909859167809788, 0.623251272671849, 0.0, 8.1, 6.855763999390337, 5.454929583904893, 4.2889053772290815, 6.3075840329218105, 3.5651720164609055, 3.0133335915436135, 2.0833333333333335, 2.9992912570719494, 2.4161369855967085, 1.3432102423411068, 0.6652867398262462, 0.0), # 61 (8.296885557192804, 7.291321582075903, 6.708347965249201, 7.241044598765433, 5.998984620130258, 2.916666666666667, 3.0031836197853625, 2.5311460905349796, 3.1506336625514404, 1.4247822405121175, 1.0898420667581163, 0.6222241731443379, 0.0, 8.1, 6.844465904587715, 5.449210333790581, 4.274346721536352, 6.301267325102881, 3.5436045267489718, 3.0031836197853625, 2.0833333333333335, 2.999492310065129, 2.4136815329218115, 1.3416695930498403, 0.6628474165523549, 0.0), # 62 (8.297912976330368, 7.264766666666667, 6.700666666666668, 7.233637500000001, 5.999319952506323, 2.916666666666667, 2.9931529411764703, 2.5163333333333338, 3.147473333333333, 1.4200200000000003, 1.0886848484848488, 0.6212000000000001, 0.0, 8.1, 6.8332, 5.443424242424244, 4.26006, 6.294946666666666, 3.5228666666666677, 2.9931529411764703, 2.0833333333333335, 2.9996599762531617, 2.411212500000001, 1.3401333333333336, 0.6604333333333334, 0.0), # 63 (8.298736179657919, 7.2385376771833565, 6.693018289894834, 7.226197067901236, 5.999588413378532, 2.916666666666667, 2.983260534172517, 2.5021625514403296, 3.1443149794238683, 1.415359158664838, 1.0875150600656773, 0.6201802164304223, 0.0, 8.1, 6.821982380734645, 5.437575300328387, 4.246077475994513, 6.288629958847737, 3.5030275720164616, 2.983260534172517, 2.0833333333333335, 2.999794206689266, 2.408732355967079, 1.3386036579789669, 0.6580488797439416, 0.0), # 64 (8.29935453051395, 7.212682898948331, 6.685413808870599, 7.218730709876544, 5.999789904853316, 2.916666666666667, 2.9735253772290813, 2.4886831275720165, 3.1411625514403294, 1.4108104709647922, 1.0863334996051048, 0.619166285627191, 0.0, 8.1, 6.8108291418991, 5.431667498025524, 4.232431412894376, 6.282325102880659, 3.484156378600823, 2.9735253772290813, 2.0833333333333335, 2.999894952426658, 2.4062435699588485, 1.33708276177412, 0.6556984453589393, 0.0), # 65 (8.299767392236957, 7.187250617283952, 6.677864197530865, 7.211245833333334, 5.999924329037105, 2.916666666666667, 2.963966448801743, 2.475944444444445, 3.13802, 1.406384691358025, 1.085140965207632, 0.6181596707818932, 0.0, 8.1, 6.799756378600824, 5.425704826038159, 4.2191540740740745, 6.27604, 3.466322222222223, 2.963966448801743, 2.0833333333333335, 2.9999621645185526, 2.4037486111111117, 1.3355728395061732, 0.6533864197530866, 0.0), # 66 (8.299974128165434, 7.162289117512574, 6.670380429812529, 7.203749845679012, 5.999991588036336, 2.916666666666667, 2.9546027273460824, 2.4639958847736634, 3.1348912757201646, 1.4020925743026982, 1.0839382549777616, 0.617161835086115, 0.0, 8.1, 6.788780185947264, 5.419691274888807, 4.206277722908094, 6.269782551440329, 3.4495942386831286, 2.9546027273460824, 2.0833333333333335, 2.999995794018168, 2.401249948559671, 1.3340760859625058, 0.6511171925011432, 0.0), # 67 (8.29983329158466, 7.137715668834903, 6.662937299954276, 7.196185044283415, 5.999934909491917, 2.916612538739013, 2.9454060779318585, 2.452781283340954, 3.131756759640299, 1.3979240883294335, 1.0827047984720504, 0.6161686681266496, 0.0, 8.099900120027435, 6.777855349393144, 5.413523992360251, 4.1937722649883, 6.263513519280598, 3.433893796677336, 2.9454060779318585, 2.0832946705278665, 2.9999674547459585, 2.398728348094472, 1.3325874599908551, 0.648883242621355, 0.0), # 68 (8.298513365539453, 7.112780047789725, 6.655325617283951, 7.188170108695652, 5.999419026870006, 2.916184636488341, 2.9361072725386457, 2.4416995884773662, 3.1284794238683125, 1.3937612781408861, 1.0813150451887295, 0.6151479315572884, 0.0, 8.099108796296298, 6.766627247130171, 5.406575225943647, 4.181283834422658, 6.256958847736625, 3.4183794238683127, 2.9361072725386457, 2.0829890260631005, 2.999709513435003, 2.396056702898551, 1.33106512345679, 0.6466163679808842, 0.0), # 69 (8.295908630047116, 7.087367803885127, 6.647512288523091, 7.179652274557166, 5.998399634202102, 2.9153419194228523, 2.926664053824548, 2.4306508154244786, 3.1250407712238992, 1.3895839048925471, 1.079753184870144, 0.614094850752854, 0.0, 8.097545867626888, 6.755043358281393, 5.3987659243507204, 4.168751714677641, 6.2500815424477985, 3.40291114159427, 2.926664053824548, 2.082387085302037, 2.999199817101051, 2.393217424852389, 1.3295024577046182, 0.6443061639895571, 0.0), # 70 (8.292055728514343, 7.061494123633789, 6.639500057155922, 7.170644102254428, 5.9968896420022055, 2.9140980439973583, 2.9170806638155953, 2.4196386221612562, 3.1214459228776104, 1.3853920718685282, 1.0780249827711816, 0.613010195814181, 0.0, 8.095231910150892, 6.743112153955991, 5.390124913855908, 4.1561762156055835, 6.242891845755221, 3.387494071025759, 2.9170806638155953, 2.081498602855256, 2.9984448210011028, 2.3902147007514767, 1.3279000114311843, 0.6419540112394354, 0.0), # 71 (8.286991304347827, 7.035174193548387, 6.631291666666667, 7.161158152173913, 5.994901960784313, 2.9124666666666674, 2.907361344537815, 2.408666666666667, 3.1177, 1.3811858823529415, 1.0761362041467308, 0.6118947368421054, 0.0, 8.0921875, 6.730842105263158, 5.380681020733653, 4.143557647058824, 6.2354, 3.3721333333333336, 2.907361344537815, 2.080333333333334, 2.9974509803921565, 2.3870527173913048, 1.3262583333333333, 0.6395612903225807, 0.0), # 72 (8.280752000954257, 7.008423200141599, 6.622889860539551, 7.151206984702094, 5.992449501062428, 2.9104614438855867, 2.897510338017237, 2.397738606919677, 3.113808123761622, 1.376965439629899, 1.0740926142516787, 0.6107492439374613, 0.0, 8.0884332133059, 6.7182416833120735, 5.370463071258393, 4.130896318889696, 6.227616247523244, 3.356834049687548, 2.897510338017237, 2.0789010313468475, 2.996224750531214, 2.383735661567365, 1.3245779721079105, 0.6371293818310545, 0.0), # 73 (8.273374461740323, 6.981256329926103, 6.614297382258802, 7.140803160225442, 5.989545173350547, 2.908096032108927, 2.887531886279889, 2.3868581008992535, 3.1097754153330284, 1.3727308469835127, 1.0718999783409144, 0.6095744872010845, 0.0, 8.083989626200276, 6.705319359211929, 5.359499891704571, 4.118192540950537, 6.219550830666057, 3.3416013412589547, 2.887531886279889, 2.0772114515063764, 2.9947725866752735, 2.380267720075148, 1.3228594764517605, 0.6346596663569185, 0.0), # 74 (8.26489533011272, 6.953688769414575, 6.605516975308642, 7.129959239130434, 5.986201888162673, 2.905384087791496, 2.8774302313518003, 2.376028806584362, 3.1056069958847736, 1.3684822076978942, 1.069564061669325, 0.6083712367338099, 0.0, 8.078877314814816, 6.692083604071907, 5.347820308346624, 4.105446623093682, 6.211213991769547, 3.3264403292181073, 2.8774302313518003, 2.0752743484224974, 2.9931009440813363, 2.3766530797101453, 1.3211033950617284, 0.6321535244922342, 0.0), # 75 (8.255351249478142, 6.925735705119696, 6.596551383173297, 7.118687781803542, 5.982432556012803, 2.9023392673881023, 2.8672096152589983, 2.365254381953971, 3.1013079865874102, 1.364219625057156, 1.067090629491799, 0.6071402626364722, 0.0, 8.073116855281206, 6.678542889001194, 5.335453147458995, 4.092658875171468, 6.2026159731748205, 3.311356134735559, 2.8672096152589983, 2.0730994767057873, 2.9912162780064016, 2.372895927267848, 1.3193102766346596, 0.6296123368290635, 0.0), # 76 (8.244778863243274, 6.897412323554141, 6.587403349336991, 7.10700134863124, 5.9782500874149385, 2.8989752273535543, 2.8568742800275118, 2.354538484987045, 3.0968835086114925, 1.3599432023454103, 1.0644854470632252, 0.6058823350099072, 0.0, 8.06672882373114, 6.664705685108978, 5.322427235316125, 4.07982960703623, 6.193767017222985, 3.296353878981863, 2.8568742800275118, 2.0706965909668247, 2.9891250437074692, 2.369000449543747, 1.3174806698673982, 0.6270374839594675, 0.0), # 77 (8.233214814814815, 6.8687338112305865, 6.578075617283951, 7.0949125, 5.97366739288308, 2.895305624142661, 2.84642846768337, 2.343884773662552, 3.092338683127571, 1.3556530428467686, 1.0617542796384905, 0.6045982239549493, 0.0, 8.059733796296298, 6.650580463504441, 5.308771398192452, 4.066959128540305, 6.184677366255142, 3.2814386831275724, 2.84642846768337, 2.0680754458161865, 2.98683369644154, 2.364970833333334, 1.3156151234567903, 0.624430346475508, 0.0), # 78 (8.220695747599452, 6.8397153546617115, 6.5685709304984, 7.082433796296296, 5.968697382931225, 2.891344114210232, 2.8358764202526006, 2.333296905959458, 3.0876786313062032, 1.351349249845343, 1.058902892472483, 0.6032886995724337, 0.0, 8.052152349108367, 6.63617569529677, 5.294514462362415, 4.0540477495360285, 6.1753572626124065, 3.266615668343241, 2.8358764202526006, 2.0652457958644517, 2.9843486914656125, 2.3608112654320994, 1.3137141860996802, 0.6217923049692465, 0.0), # 79 (8.207258305003878, 6.810372140360193, 6.558892032464563, 7.069577797906602, 5.963352968073375, 2.8871043540110755, 2.8252223797612324, 2.3227785398567296, 3.0829084743179394, 1.3470319266252455, 1.055937050820092, 0.6019545319631957, 0.0, 8.04400505829904, 6.621499851595152, 5.2796852541004595, 4.041095779875736, 6.165816948635879, 3.2518899557994216, 2.8252223797612324, 2.0622173957221968, 2.9816764840366874, 2.3565259326355346, 1.3117784064929128, 0.619124740032745, 0.0), # 80 (8.192939130434784, 6.78071935483871, 6.5490416666666675, 7.056357065217393, 5.957647058823529, 2.8826000000000005, 2.8144705882352943, 2.3123333333333336, 3.078033333333333, 1.3427011764705885, 1.0528625199362043, 0.6005964912280702, 0.0, 8.0353125, 6.606561403508772, 5.264312599681022, 4.028103529411765, 6.156066666666666, 3.237266666666667, 2.8144705882352943, 2.059, 2.9788235294117644, 2.3521190217391315, 1.3098083333333335, 0.6164290322580647, 0.0), # 81 (8.177774867298861, 6.750772184609939, 6.539022576588936, 7.042784158615137, 5.951592565695688, 2.877844708631815, 2.8036252877008145, 2.301964944368237, 3.0730583295229383, 1.3383571026654835, 1.0496850650757086, 0.5992153474678925, 0.0, 8.026095250342937, 6.5913688221468165, 5.248425325378542, 4.0150713079964495, 6.146116659045877, 3.2227509221155315, 2.8036252877008145, 2.0556033633084394, 2.975796282847844, 2.3475947195383795, 1.3078045153177873, 0.6137065622372673, 0.0), # 82 (8.161802159002804, 6.720545816186557, 6.528837505715592, 7.028871638486312, 5.945202399203851, 2.8728521363613275, 2.7926907201838214, 2.2916770309404058, 3.067988584057308, 1.3339998084940425, 1.0464104514934927, 0.5978118707834975, 0.0, 8.016373885459535, 6.575930578618472, 5.232052257467463, 4.001999425482127, 6.135977168114616, 3.208347843316568, 2.7926907201838214, 2.052037240258091, 2.9726011996019257, 2.3429572128287712, 1.3057675011431187, 0.6109587105624144, 0.0), # 83 (8.145057648953301, 6.690055436081242, 6.518489197530864, 7.014632065217392, 5.938489469862018, 2.867635939643347, 2.7816711277103434, 2.2814732510288067, 3.0628292181069954, 1.329629397240378, 1.0430444444444447, 0.5963868312757202, 0.0, 8.006168981481482, 6.560255144032922, 5.215222222222223, 3.9888881917211334, 6.125658436213991, 3.194062551440329, 2.7816711277103434, 2.0483113854595336, 2.969244734931009, 2.338210688405798, 1.303697839506173, 0.6081868578255676, 0.0), # 84 (8.127577980557048, 6.659316230806673, 6.507980395518976, 7.000077999194847, 5.931466688184191, 2.862209774932684, 2.77057075230641, 2.2713572626124074, 3.057585352842554, 1.3252459721886014, 1.0395928091834528, 0.5949409990453959, 0.0, 7.995501114540467, 6.544350989499354, 5.197964045917263, 3.9757379165658033, 6.115170705685108, 3.17990016765737, 2.77057075230641, 2.0444355535233454, 2.9657333440920954, 2.3333593330649496, 1.3015960791037953, 0.6053923846187885, 0.0), # 85 (8.10939979722073, 6.6283433868755255, 6.497313843164153, 6.985222000805154, 5.924146964684365, 2.8565872986841443, 2.7593938359980483, 2.2613327236701726, 3.0522621094345377, 1.320849636622825, 1.0360613109654049, 0.5934751441933597, 0.0, 7.984390860768176, 6.528226586126955, 5.180306554827023, 3.9625489098684747, 6.104524218869075, 3.1658658131382413, 2.7593938359980483, 2.040419499060103, 2.9620734823421824, 2.3284073336017186, 1.2994627686328306, 0.6025766715341389, 0.0), # 86 (8.090559742351045, 6.597152090800478, 6.486492283950617, 6.970076630434782, 5.9165432098765445, 2.8507821673525378, 2.7481446208112876, 2.2514032921810703, 3.0468646090534985, 1.3164404938271608, 1.0324557150451887, 0.5919900368204463, 0.0, 7.972858796296297, 6.511890405024908, 5.162278575225944, 3.9493214814814817, 6.093729218106997, 3.1519646090534983, 2.7481446208112876, 2.036272976680384, 2.9582716049382722, 2.3233588768115947, 1.2972984567901236, 0.5997410991636799, 0.0), # 87 (8.071094459354686, 6.565757529094207, 6.475518461362597, 6.95465444847021, 5.908668334274726, 2.8448080373926743, 2.7368273487721564, 2.2415726261240665, 3.0413979728699894, 1.3120186470857205, 1.0287817866776934, 0.5904864470274911, 0.0, 7.960925497256517, 6.495350917302401, 5.143908933388466, 3.9360559412571607, 6.082795945739979, 3.138201676573693, 2.7368273487721564, 2.032005740994767, 2.954334167137363, 2.3182181494900704, 1.2951036922725196, 0.5968870480994735, 0.0), # 88 (8.051040591638339, 6.534174888269392, 6.464395118884317, 6.938968015297907, 5.90053524839291, 2.8386785652593614, 2.7254462619066833, 2.2318443834781285, 3.035867322054565, 1.3075841996826167, 1.025045291117806, 0.5889651449153291, 0.0, 7.948611539780521, 6.478616594068619, 5.125226455589029, 3.9227525990478496, 6.07173464410913, 3.12458213686938, 2.7254462619066833, 2.0276275466138296, 2.950267624196455, 2.312989338432636, 1.2928790237768635, 0.5940158989335812, 0.0), # 89 (8.030434782608696, 6.502419354838709, 6.453125000000001, 6.923029891304349, 5.892156862745098, 2.8324074074074077, 2.7140056022408965, 2.2222222222222223, 3.030277777777778, 1.303137254901961, 1.021251993620415, 0.5874269005847954, 0.0, 7.9359375000000005, 6.461695906432748, 5.106259968102074, 3.9094117647058826, 6.060555555555556, 3.111111111111111, 2.7140056022408965, 2.0231481481481484, 2.946078431372549, 2.3076766304347833, 1.2906250000000001, 0.5911290322580646, 0.0), # 90 (8.00931367567245, 6.470506115314836, 6.441710848193873, 6.906852636876007, 5.883546087845287, 2.826008220291622, 2.7025096118008247, 2.2127098003353147, 3.024634461210182, 1.2986779160278654, 1.0174076594404082, 0.585872484136725, 0.0, 7.922923954046638, 6.444597325503974, 5.0870382972020405, 3.8960337480835956, 6.049268922420364, 3.097793720469441, 2.7025096118008247, 2.0185773002083014, 2.9417730439226437, 2.302284212292003, 1.2883421696387747, 0.5882278286649852, 0.0), # 91 (7.9877139142362985, 6.438450356210453, 6.43015540695016, 6.890448812399356, 5.874715834207482, 2.8194946603668143, 2.690962532612497, 2.203310775796373, 3.018942493522329, 1.2942062863444421, 1.013518053832674, 0.5843026656719533, 0.0, 7.909591478052126, 6.427329322391485, 5.067590269163369, 3.8826188590333257, 6.037884987044658, 3.0846350861149223, 2.690962532612497, 2.0139247574048675, 2.937357917103741, 2.296816270799786, 1.2860310813900322, 0.5853136687464049, 0.0), # 92 (7.965672141706924, 6.406267264038233, 6.418461419753087, 6.873830978260871, 5.865679012345678, 2.8128803840877916, 2.6793686067019404, 2.1940288065843623, 3.013206995884774, 1.2897224691358027, 1.0095889420521, 0.5827182152913147, 0.0, 7.895960648148147, 6.409900368204461, 5.0479447102605, 3.8691674074074074, 6.026413991769548, 3.0716403292181074, 2.6793686067019404, 2.0092002743484225, 2.932839506172839, 2.291276992753624, 1.2836922839506175, 0.5823879330943849, 0.0), # 93 (7.943225001491024, 6.373972025310855, 6.406631630086878, 6.857011694847022, 5.856448532773877, 2.806179047909364, 2.6677320760951844, 2.1848675506782507, 3.007433089468069, 1.2852265676860597, 1.005626089353575, 0.581119903095645, 0.0, 7.882052040466393, 6.392318934052094, 5.028130446767873, 3.855679703058178, 6.014866178936138, 3.058814570949551, 2.6677320760951844, 2.0044136056495456, 2.9282242663869384, 2.2856705649490077, 1.2813263260173757, 0.5794520023009869, 0.0), # 94 (7.920409136995288, 6.341579826540998, 6.394668781435757, 6.840003522544284, 5.847037306006079, 2.799404308286339, 2.6560571828182575, 2.1758306660570037, 3.001625895442768, 1.2807186852793244, 1.0016352609919863, 0.5795084991857787, 0.0, 7.867886231138546, 6.374593491043566, 5.008176304959932, 3.8421560558379726, 6.003251790885536, 3.046162932479805, 2.6560571828182575, 1.9995745059188135, 2.9235186530030397, 2.2800011741814283, 1.2789337562871517, 0.5765072569582727, 0.0), # 95 (7.89726119162641, 6.30910585424134, 6.382575617283951, 6.8228190217391305, 5.8374582425562815, 2.7925698216735255, 2.6443481688971886, 2.1669218106995887, 2.995790534979424, 1.27619892519971, 0.9976222222222224, 0.5778847736625516, 0.0, 7.853483796296297, 6.356732510288067, 4.988111111111112, 3.828596775599129, 5.991581069958848, 3.0336905349794243, 2.6443481688971886, 1.9946927297668038, 2.9187291212781408, 2.2742730072463773, 1.2765151234567904, 0.5735550776583037, 0.0), # 96 (7.873817808791078, 6.276565294924556, 6.370354881115684, 6.805470752818035, 5.827724252938488, 2.7856892445257326, 2.6326092763580053, 2.1581446425849724, 2.9899321292485905, 1.2716673907313272, 0.9935927382991712, 0.576249496626798, 0.0, 7.838865312071332, 6.338744462894778, 4.967963691495855, 3.8150021721939806, 5.979864258497181, 3.0214024996189615, 2.6326092763580053, 1.9897780318040947, 2.913862126469244, 2.2684902509393456, 1.2740709762231368, 0.5705968449931414, 0.0), # 97 (7.850115631895988, 6.243973335103323, 6.35800931641518, 6.787971276167473, 5.817848247666694, 2.7787762332977706, 2.6208447472267373, 2.1495028196921204, 2.9840557994208194, 1.2671241851582886, 0.9895525744777209, 0.5746034381793533, 0.0, 7.824051354595337, 6.320637819972885, 4.947762872388605, 3.801372555474865, 5.968111598841639, 3.0093039475689687, 2.6208447472267373, 1.9848401666412645, 2.908924123833347, 2.2626570920558247, 1.2716018632830361, 0.5676339395548476, 0.0), # 98 (7.826191304347827, 6.211345161290323, 6.3455416666666675, 6.770333152173913, 5.807843137254903, 2.7718444444444446, 2.6090588235294123, 2.1410000000000005, 2.9781666666666666, 1.2625694117647062, 0.9855074960127594, 0.5729473684210528, 0.0, 7.8090625000000005, 6.302421052631579, 4.927537480063797, 3.787708235294118, 5.956333333333333, 2.9974000000000007, 2.6090588235294123, 1.9798888888888888, 2.9039215686274513, 2.256777717391305, 1.2691083333333337, 0.564667741935484, 0.0), # 99 (7.80208146955329, 6.178695959998229, 6.332954675354367, 6.752568941223833, 5.797721832217111, 2.764907534420566, 2.597255747292058, 2.1326398414875785, 2.9722698521566837, 1.258003173834692, 0.9814632681591747, 0.5712820574527312, 0.0, 7.79391932441701, 6.284102631980042, 4.907316340795873, 3.774009521504075, 5.944539704313367, 2.98569577808261, 2.597255747292058, 1.9749339531575472, 2.8988609161085557, 2.250856313741278, 1.2665909350708735, 0.5616996327271119, 0.0), # 100 (7.777822770919068, 6.1460409177397235, 6.320251085962506, 6.734691203703704, 5.787497243067323, 2.757979159680943, 2.585439760540705, 2.124426002133821, 2.9663704770614236, 1.253425574652358, 0.9774256561718551, 0.5696082753752236, 0.0, 7.7786424039780515, 6.265691029127459, 4.887128280859275, 3.760276723957073, 5.932740954122847, 2.9741964029873493, 2.585439760540705, 1.9699851140578162, 2.8937486215336614, 2.244897067901235, 1.2640502171925014, 0.5587309925217931, 0.0), # 101 (7.753451851851853, 6.11339522102748, 6.307433641975309, 6.716712500000001, 5.7771822803195345, 2.7510729766803848, 2.5736151053013803, 2.1163621399176957, 2.9604736625514403, 1.248836717501816, 0.9734004253056887, 0.5679267922893655, 0.0, 7.763252314814816, 6.24719471518302, 4.867002126528443, 3.746510152505447, 5.920947325102881, 2.962906995884774, 2.5736151053013803, 1.965052126200275, 2.8885911401597673, 2.2389041666666674, 1.261486728395062, 0.5557632019115891, 0.0), # 102 (7.729005355758336, 6.080774056374176, 6.294505086877001, 6.698645390499196, 5.766789854487748, 2.7442026418736987, 2.561786023600112, 2.1084519128181682, 2.9545845297972866, 1.2442367056671781, 0.9693933408155633, 0.5662383782959916, 0.0, 7.747769633058984, 6.228622161255906, 4.846966704077817, 3.7327101170015338, 5.909169059594573, 2.951832677945436, 2.561786023600112, 1.960144744195499, 2.883394927243874, 2.2328817968330656, 1.2589010173754003, 0.5527976414885616, 0.0), # 103 (7.704519926045208, 6.048192610292491, 6.281468164151806, 6.680502435587762, 5.756332876085962, 2.7373818117156943, 2.5499567574629305, 2.1006989788142056, 2.948708199969517, 1.2396256424325565, 0.9654101679563669, 0.564543803495937, 0.0, 7.732214934842251, 6.209981838455306, 4.827050839781834, 3.7188769272976687, 5.897416399939034, 2.9409785703398876, 2.5499567574629305, 1.9552727226540672, 2.878166438042981, 2.2268341451959213, 1.2562936328303613, 0.549835691844772, 0.0), # 104 (7.680032206119162, 6.015666069295101, 6.268325617283951, 6.662296195652173, 5.745824255628177, 2.7306241426611804, 2.5381315489158633, 2.0931069958847743, 2.942849794238683, 1.235003631082063, 0.961456671982988, 0.562843837990037, 0.0, 7.716608796296296, 6.1912822178904054, 4.80728335991494, 3.705010893246188, 5.885699588477366, 2.930349794238684, 2.5381315489158633, 1.9504458161865572, 2.8729121278140886, 2.220765398550725, 1.2536651234567902, 0.546878733572282, 0.0), # 105 (7.655578839386891, 5.983209619894685, 6.255080189757659, 6.644039231078905, 5.735276903628392, 2.723943291164965, 2.526314639984938, 2.0856796220088403, 2.9370144337753388, 1.2303707748998092, 0.9575386181503142, 0.5611392518791264, 0.0, 7.700971793552812, 6.172531770670389, 4.787693090751571, 3.691112324699427, 5.8740288675506775, 2.9199514708123764, 2.526314639984938, 1.9456737794035461, 2.867638451814196, 2.214679743692969, 1.2510160379515318, 0.5439281472631533, 0.0), # 106 (7.631196469255085, 5.950838448603921, 6.241734625057157, 6.625744102254428, 5.724703730600607, 2.7173529136818577, 2.5145102726961848, 2.0784205151653716, 2.931207239750038, 1.225727177169908, 0.9536617717132337, 0.5594308152640404, 0.0, 7.685324502743484, 6.153738967904443, 4.768308858566169, 3.6771815315097234, 5.862414479500076, 2.9097887212315205, 2.5145102726961848, 1.9409663669156128, 2.8623518653003037, 2.208581367418143, 1.2483469250114314, 0.5409853135094475, 0.0), # 107 (7.606921739130435, 5.918567741935485, 6.228291666666668, 6.607423369565218, 5.714117647058822, 2.7108666666666674, 2.5027226890756302, 2.0713333333333335, 2.9254333333333333, 1.221072941176471, 0.9498318979266349, 0.5577192982456142, 0.0, 7.669687500000001, 6.134912280701755, 4.749159489633174, 3.6632188235294123, 5.850866666666667, 2.899866666666667, 2.5027226890756302, 1.9363333333333337, 2.857058823529411, 2.20247445652174, 1.2456583333333338, 0.538051612903226, 0.0), # 108 (7.582791292419635, 5.886412686402053, 6.214754058070417, 6.589089593397745, 5.70353156351704, 2.7044982065742014, 2.490956131149305, 2.064421734491694, 2.9196978356957777, 1.2164081702036098, 0.9460547620454054, 0.5560054709246826, 0.0, 7.654081361454047, 6.116060180171507, 4.730273810227027, 3.6492245106108285, 5.839395671391555, 2.8901904282883715, 2.490956131149305, 1.9317844332672867, 2.85176578175852, 2.196363197799249, 1.2429508116140835, 0.5351284260365504, 0.0), # 109 (7.558841772529373, 5.854388468516307, 6.201124542752631, 6.570755334138486, 5.692958390489256, 2.6982611898592697, 2.4792148409432357, 2.0576893766194178, 2.9140058680079255, 1.211732967535437, 0.9423361293244336, 0.554290103402081, 0.0, 7.638526663237312, 6.0971911374228895, 4.711680646622168, 3.63519890260631, 5.828011736015851, 2.880765127267185, 2.4792148409432357, 1.9273294213280499, 2.846479195244628, 2.1902517780461626, 1.2402249085505264, 0.5322171335014826, 0.0), # 110 (7.535109822866345, 5.82251027479092, 6.187405864197532, 6.552433152173913, 5.68241103848947, 2.6921692729766806, 2.4675030604834527, 2.0511399176954734, 2.9083625514403293, 1.2070474364560642, 0.9386817650186072, 0.5525739657786443, 0.0, 7.623043981481482, 6.078313623565086, 4.693408825093036, 3.621142309368192, 5.816725102880659, 2.871595884773663, 2.4675030604834527, 1.9229780521262005, 2.841205519244735, 2.1841443840579715, 1.2374811728395065, 0.5293191158900837, 0.0), # 111 (7.51163208683724, 5.790793291738572, 6.173600765889348, 6.5341356078905, 5.671902418031685, 2.686236112381243, 2.4558250317959835, 2.0447770156988265, 2.9027730071635416, 1.2023516802496035, 0.9350974343828147, 0.5508578281552075, 0.0, 7.607653892318244, 6.059436109707281, 4.675487171914074, 3.6070550407488096, 5.805546014327083, 2.862687821978357, 2.4558250317959835, 1.9187400802723165, 2.8359512090158425, 2.178045202630167, 1.2347201531778695, 0.5264357537944157, 0.0), # 112 (7.488403378962436, 5.759305653776365, 6.159745218834713, 6.515900329495224, 5.661427029425976, 2.6804725589667733, 2.444210385462708, 2.038617522926869, 2.8972567496689656, 1.1976609473225461, 0.9315898541537156, 0.549146195766962, 0.0, 7.592355120674577, 6.0406081534365805, 4.657949270768578, 3.592982841967638, 5.794513499337931, 2.8540645320976163, 2.444210385462708, 1.914623256404838, 2.830713514712988, 2.1719667764984085, 1.2319490437669427, 0.5235732412523969, 0.0), # 113 (7.465184718320052, 5.728357934585393, 6.146030450014413, 6.497873652766401, 5.6508764557687075, 2.674865483980621, 2.432807283364232, 2.0327370865017067, 2.891898409523483, 1.1930630335825567, 0.9281659116150931, 0.5474608114741984, 0.0, 7.577020331328028, 6.022068926216181, 4.640829558075465, 3.5791891007476693, 5.783796819046966, 2.8458319211023895, 2.432807283364232, 1.9106182028433005, 2.8254382278843537, 2.1659578842554676, 1.2292060900028827, 0.5207598122350358, 0.0), # 114 (7.441907922403196, 5.697961279034234, 6.132464621804878, 6.480050703109068, 5.640217428207254, 2.669400305832757, 2.421623860076625, 2.027134218092903, 2.886699994311677, 1.1885650655976157, 0.9248206015236127, 0.5458025055039235, 0.0, 7.561605305328301, 6.003827560543158, 4.6241030076180625, 3.5656951967928463, 5.773399988623354, 2.8379879053300643, 2.421623860076625, 1.9067145041662548, 2.820108714103627, 2.1600169010363564, 1.226492924360976, 0.5179964799122032, 0.0), # 115 (7.418543898590108, 5.668071406280581, 6.119021459989249, 6.462399690159842, 5.629433880738015, 2.664064142733979, 2.4106419270111576, 2.021793437632998, 2.8816483571274216, 1.1841586716899097, 0.9215474575028644, 0.5441682131658231, 0.0, 7.546085807804713, 5.985850344824053, 4.607737287514321, 3.5524760150697285, 5.763296714254843, 2.8305108126861973, 2.4106419270111576, 1.9029029590956992, 2.8147169403690073, 2.154133230053281, 1.22380429199785, 0.5152792187527803, 0.0), # 116 (7.395063554259018, 5.638644035482129, 6.105674690350658, 6.444888823555345, 5.6185097473573915, 2.6588441128950824, 2.399843295579101, 2.0166992650545286, 2.8767303510645874, 1.179835480181626, 0.9183400131764379, 0.5425548697695834, 0.0, 7.53043760388658, 5.968103567465417, 4.591700065882189, 3.5395064405448773, 5.753460702129175, 2.8233789710763397, 2.399843295579101, 1.8991743663536302, 2.8092548736786958, 2.148296274518449, 1.2211349380701317, 0.5126040032256481, 0.0), # 117 (7.371437796788169, 5.60963488579657, 6.092398038672245, 6.427486312932199, 5.607428962061783, 2.6537273345268653, 2.3892097771917262, 2.0118362202900326, 2.871932829217049, 1.175587119394952, 0.9151918021679234, 0.5409594106248901, 0.0, 7.51463645870322, 5.950553516873789, 4.575959010839616, 3.5267613581848556, 5.743865658434098, 2.8165707084060454, 2.3892097771917262, 1.8955195246620464, 2.8037144810308914, 2.142495437644067, 1.218479607734449, 0.5099668077996883, 0.0), # 118 (7.347637533555794, 5.580999676381602, 6.079165230737149, 6.410160367927023, 5.5961754588475845, 2.648700925840122, 2.3787231832603024, 2.0071888232720485, 2.867242644678678, 1.1714052176520746, 0.9120963581009105, 0.5393787710414291, 0.0, 7.498658137383946, 5.933166481455719, 4.560481790504553, 3.5142156529562234, 5.734485289357356, 2.810064352580868, 2.3787231832603024, 1.8919292327429442, 2.7980877294237922, 2.1367201226423416, 1.21583304614743, 0.507363606943782, 0.0), # 119 (7.323633671940129, 5.552694126394916, 6.065949992328509, 6.392879198176436, 5.584733171711198, 2.6437520050456507, 2.3683653251961014, 2.0027415939331146, 2.8626466505433488, 1.1672814032751813, 0.909047214598989, 0.5378098863288866, 0.0, 7.482478405058078, 5.915908749617751, 4.545236072994944, 3.501844209825543, 5.7252933010866975, 2.80383823150636, 2.3683653251961014, 1.8883942893183219, 2.792366585855599, 2.1309597327254792, 1.2131899984657017, 0.5047903751268107, 0.0), # 120 (7.299397119319415, 5.524673954994208, 6.052726049229459, 6.3756110133170605, 5.573086034649023, 2.638867690354248, 2.358118014410392, 1.9984790522057692, 2.858131699904933, 1.1632073045864595, 0.906037905285749, 0.5362496917969483, 0.0, 7.466073026854929, 5.898746609766429, 4.530189526428744, 3.489621913759378, 5.716263399809866, 2.797870673088077, 2.358118014410392, 1.884905493110177, 2.7865430173245116, 2.1252036711056874, 1.2105452098458918, 0.5022430868176554, 0.0), # 121 (7.274898783071883, 5.496894881337171, 6.039467127223141, 6.358324022985514, 5.561217981657458, 2.634035099976709, 2.347963062314447, 1.9943857180225497, 2.8536846458573035, 1.1591745499080957, 0.9030619637847803, 0.5346951227553002, 0.0, 7.4494177679038165, 5.8816463503083005, 4.515309818923901, 3.4775236497242865, 5.707369291714607, 2.7921400052315697, 2.347963062314447, 1.8814536428405064, 2.780608990828729, 2.119441340995172, 1.2078934254446283, 0.49971771648519747, 0.0), # 122 (7.250109570575775, 5.469312624581501, 6.026146952092692, 6.340986436818417, 5.549112946732902, 2.629241352123832, 2.3378822803195356, 1.9904461113159944, 2.8492923414943343, 1.1551747675622777, 0.9001129237196728, 0.5331431145136282, 0.0, 7.432488393334058, 5.864574259649909, 4.500564618598363, 3.4655243026868323, 5.698584682988669, 2.7866245558423923, 2.3378822803195356, 1.8780295372313083, 2.774556473366451, 2.1136621456061393, 1.2052293904185383, 0.49721023859831837, 0.0), # 123 (7.225000389209324, 5.441882903884891, 6.012739249621247, 6.323566464452393, 5.536754863871753, 2.624473565006412, 2.327857479836928, 1.9866447520186423, 2.844941639909897, 1.1511995858711925, 0.897184318714016, 0.5315906023816185, 0.0, 7.4152606682749695, 5.847496626197802, 4.4859215935700805, 3.4535987576135767, 5.689883279819794, 2.781302652826099, 2.327857479836928, 1.87462397500458, 2.7683774319358765, 2.107855488150798, 1.2025478499242495, 0.49471662762589924, 0.0), # 124 (7.199542146350767, 5.414561438405035, 5.99921774559195, 6.306032315524057, 5.524127667070411, 2.619718856835246, 2.3178704722778956, 1.9829661600630304, 2.840619394197865, 1.147240633157027, 0.8942696823914004, 0.5300345216689567, 0.0, 7.397710357855863, 5.8303797383585225, 4.471348411957002, 3.4417218994710805, 5.68123878839573, 2.7761526240882426, 2.3178704722778956, 1.8712277548823186, 2.7620638335352057, 2.1020107718413525, 1.19984354911839, 0.49223285803682143, 0.0), # 125 (7.1737057493783425, 5.387303947299629, 5.985556165787933, 6.288352199670033, 5.511215290325276, 2.614964345821132, 2.307903069053708, 1.9793948553816976, 2.8363124574521112, 1.1432895377419687, 0.8913625483754153, 0.5284718076853291, 0.0, 7.379813227206063, 5.813189884538619, 4.4568127418770755, 3.4298686132259055, 5.6726249149042225, 2.7711527975343766, 2.307903069053708, 1.8678316755865225, 2.755607645162638, 2.0961173998900113, 1.1971112331575866, 0.4897549042999664, 0.0), # 126 (7.147462105670289, 5.360066149726364, 5.9717282359923365, 6.27049432652694, 5.498001667632746, 2.610197150174864, 2.2979370815756375, 1.975915357907182, 2.832007682766508, 1.139337927948205, 0.8884564502896507, 0.5268993957404212, 0.0, 7.361545041454879, 5.795893353144632, 4.442282251448253, 3.4180137838446143, 5.664015365533016, 2.766281501070055, 2.2979370815756375, 1.8644265358391885, 2.749000833816373, 2.0901647755089803, 1.1943456471984675, 0.487278740884215, 0.0), # 127 (7.120782122604837, 5.332803764842939, 5.957707681988301, 6.252426905731399, 5.484470732989221, 2.6054043881072406, 2.287954321254953, 1.9725121875720208, 2.827691923234929, 1.1353774320979229, 0.8855449217576967, 0.5253142211439193, 0.0, 7.34288156573163, 5.778456432583111, 4.427724608788483, 3.4061322962937677, 5.655383846469858, 2.7615170626008294, 2.287954321254953, 1.8610031343623146, 2.7422353664946106, 2.084142301910467, 1.1915415363976603, 0.4848003422584491, 0.0), # 128 (7.093636707560226, 5.305472511807044, 5.9434682295589605, 6.2341181469200295, 5.4706064203911, 2.600573177829058, 2.2779365995029255, 1.9691698643087534, 2.823352031951247, 1.1313996785133094, 0.882621496403143, 0.5237132192055092, 0.0, 7.323798565165631, 5.7608454112606, 4.413107482015715, 3.3941990355399274, 5.646704063902494, 2.756837810032255, 2.2779365995029255, 1.8575522698778983, 2.73530321019555, 2.078039382306677, 1.188693645911792, 0.48231568289154947, 0.0), # 129 (7.065996767914694, 5.2780281097763755, 5.9289836044874535, 6.215536259729452, 5.45639266383478, 2.595690637551111, 2.267865727730825, 1.9658729080499169, 2.818974862009333, 1.1273962955165517, 0.8796797078495794, 0.522093325234877, 0.0, 7.3042718048861985, 5.743026577583645, 4.398398539247896, 3.3821888865496543, 5.637949724018666, 2.7522220712698835, 2.267865727730825, 1.8540647411079363, 2.72819633191739, 2.0718454199098177, 1.1857967208974907, 0.4798207372523978, 0.0), # 130 (7.037833211046475, 5.250426277908626, 5.914227532556921, 6.196649453796286, 5.441813397316663, 2.590743885484198, 2.2577235173499237, 1.9626058387280498, 2.814547266503063, 1.1233589114298372, 0.8767130897205959, 0.5204514745417084, 0.0, 7.2842770500226495, 5.724966219958791, 4.383565448602979, 3.370076734289511, 5.629094533006126, 2.74764817421927, 2.2577235173499237, 1.850531346774427, 2.7209066986583315, 2.0655498179320957, 1.1828455065113843, 0.4773114798098752, 0.0), # 131 (7.009116944333808, 5.222622735361492, 5.8991737395504975, 6.1774259387571515, 5.4268525548331485, 2.5857200398391145, 2.24749177977149, 1.959353176275691, 2.8100560985263074, 1.119279154575353, 0.8737151756397821, 0.5187846024356896, 0.0, 7.263790065704301, 5.706630626792584, 4.36857587819891, 3.3578374637260584, 5.620112197052615, 2.7430944467859675, 2.24749177977149, 1.8469428855993675, 2.7134262774165743, 2.0591419795857178, 1.1798347479100997, 0.474783885032863, 0.0), # 132 (6.979818875154931, 5.194573201292665, 5.883795951251323, 6.1578339242486715, 5.411494070380632, 2.5806062188266576, 2.237152326406796, 1.9560994406253773, 2.80548821117294, 1.1151486532752868, 0.8706794992307283, 0.5170896442265063, 0.0, 7.242786617060469, 5.687986086491568, 4.353397496153641, 3.3454459598258595, 5.61097642234588, 2.7385392168755285, 2.237152326406796, 1.8432901563047555, 2.705747035190316, 2.052611308082891, 1.1767591902502648, 0.4722339273902424, 0.0), # 133 (6.949909910888076, 5.166233394859844, 5.868067893442536, 6.137841619907462, 5.395721877955516, 2.575389540657624, 2.2266869686671114, 1.9528291517096479, 2.8008304575368346, 1.1109590358518249, 0.8675995941170239, 0.5153635352238445, 0.0, 7.221242469220467, 5.668998887462289, 4.3379979705851195, 3.3328771075554737, 5.601660915073669, 2.7339608123935073, 2.2266869686671114, 1.8395639576125886, 2.697860938977758, 2.0459472066358213, 1.1736135786885074, 0.46965758135089497, 0.0), # 134 (6.919360958911483, 5.137559035220717, 5.851963291907273, 6.117417235370148, 5.379519911554198, 2.57005712354281, 2.2160775179637073, 1.9495268294610402, 2.796069690711861, 1.1067019306271555, 0.8644689939222592, 0.5136032107373902, 0.0, 7.199133387313616, 5.649635318111292, 4.322344969611295, 3.320105791881466, 5.592139381423722, 2.7293375612454565, 2.2160775179637073, 1.835755088244864, 2.689759955777099, 2.0391390784567163, 1.1703926583814546, 0.4670508213837017, 0.0), # 135 (6.888142926603388, 5.108505841532984, 5.835455872428673, 6.096528980273343, 5.362872105173076, 2.564596085693012, 2.205305785707854, 1.9461769938120925, 2.7911927637918947, 1.1023689659234648, 0.8612812322700237, 0.5118056060768296, 0.0, 7.176435136469229, 5.629861666845124, 4.306406161350118, 3.3071068977703937, 5.5823855275837895, 2.72464779133693, 2.205305785707854, 1.8318543469235802, 2.681436052586538, 2.0321763267577815, 1.1670911744857346, 0.46440962195754404, 0.0), # 136 (6.856226721342027, 5.079029532954335, 5.818519360789875, 6.075145064253675, 5.345762392808551, 2.558993545319026, 2.1943535833108223, 1.942764164695343, 2.7861865298708084, 1.0979517700629406, 0.8580298427839075, 0.5099676565518481, 0.0, 7.153123481816621, 5.609644222070328, 4.290149213919538, 3.293855310188821, 5.572373059741617, 2.7198698305734803, 2.1943535833108223, 1.8278525323707329, 2.6728811964042754, 2.0250483547512257, 1.1637038721579749, 0.46172995754130325, 0.0), # 137 (6.823583250505639, 5.0490858286424665, 5.801127482774012, 6.053233696947759, 5.3281747084570235, 2.5532366206316497, 2.1832027221838817, 1.9392728620433302, 2.781037842042475, 1.0934419713677697, 0.8547083590875004, 0.508086297472132, 0.0, 7.129174188485113, 5.58894927219345, 4.273541795437502, 3.280325914103308, 5.56207568408495, 2.7149820068606623, 2.1832027221838817, 1.8237404433083213, 2.6640873542285117, 2.017744565649253, 1.1602254965548024, 0.45900780260386065, 0.0), # 138 (6.790183421472455, 5.018630447755072, 5.783253964164227, 6.030763087992216, 5.3100929861148884, 2.547312429841679, 2.171835013738304, 1.9356876057885917, 2.775733553400766, 1.0888311981601397, 0.8513103148043922, 0.5061584641473672, 0.0, 7.104563021604015, 5.567743105621037, 4.256551574021961, 3.2664935944804183, 5.551467106801532, 2.709962648104028, 2.171835013738304, 1.8195088784583422, 2.6550464930574442, 2.0102543626640723, 1.1566507928328456, 0.4562391316140975, 0.0), # 139 (6.755998141620719, 4.987619109449845, 5.764872530743658, 6.007701447023667, 5.291501159778549, 2.5412080911599104, 2.1602322693853586, 1.9319929158636655, 2.770260517039555, 1.0841110787622374, 0.8478292435581727, 0.5041810918872395, 0.0, 7.079265746302652, 5.545992010759633, 4.2391462177908625, 3.2523332362867117, 5.54052103407911, 2.704790082209132, 2.1602322693853586, 1.8151486365427931, 2.6457505798892744, 2.0025671490078896, 1.1529745061487318, 0.45341991904089507, 0.0), # 140 (6.720998318328665, 4.956007532884482, 5.745956908295441, 5.984016983678732, 5.272383163444402, 2.5349107227971404, 2.148376300536318, 1.9281733122010902, 2.7646055860527143, 1.0792732414962505, 0.844258678972432, 0.502151116001435, 0.0, 7.053258127710331, 5.523662276015784, 4.221293394862159, 3.2378197244887508, 5.529211172105429, 2.6994426370815265, 2.148376300536318, 1.8106505162836717, 2.636191581722201, 1.994672327892911, 1.1491913816590882, 0.4505461393531348, 0.0), # 141 (6.685154858974525, 4.923751437216675, 5.726480822602714, 5.959677907594033, 5.252722931108846, 2.5284074429641663, 2.1362489186024507, 1.924213314733404, 2.7587556135341176, 1.0743093146843659, 0.8405921546707598, 0.5000654717996397, 0.0, 7.026515930956373, 5.500720189796036, 4.202960773353798, 3.222927944053097, 5.517511227068235, 2.6938986406267658, 2.1362489186024507, 1.806005316402976, 2.626361465554423, 1.9865593025313446, 1.1452961645205428, 0.4476137670196978, 0.0), # 142 (6.64843867093654, 4.890806541604119, 5.706417999448617, 5.934652428406185, 5.232504396768282, 2.521685369871783, 2.1238319349950276, 1.920097443393144, 2.7526974525776393, 1.0692109266487708, 0.8368232042767458, 0.4979210945915394, 0.0, 6.999014921170094, 5.477132040506932, 4.184116021383729, 3.207632779946312, 5.505394905155279, 2.6881364207504017, 2.1238319349950276, 1.8012038356227023, 2.616252198384141, 1.9782174761353954, 1.1412835998897235, 0.44461877650946546, 0.0), # 143 (6.610820661592948, 4.857128565204509, 5.685742164616285, 5.908908755751814, 5.2117114944191085, 2.5147316217307885, 2.1111071611253194, 1.9158102181128498, 2.746417956277149, 1.0639697057116522, 0.8329453614139802, 0.49571491968682, 0.0, 6.970730863480812, 5.452864116555019, 4.164726807069901, 3.191909117134956, 5.492835912554298, 2.6821343053579896, 2.1111071611253194, 1.796236872664849, 2.6058557472095543, 1.9696362519172719, 1.1371484329232573, 0.44155714229131915, 0.0), # 144 (6.572271738321982, 4.82267322717554, 5.6644270438888595, 5.882415099267537, 5.190328158057724, 2.507533316751979, 2.0980564084045974, 1.9113361588250588, 2.739903977726521, 1.0585772801951978, 0.8289521597060527, 0.4934438823951677, 0.0, 6.94163952301784, 5.4278827063468436, 4.144760798530264, 3.175731840585593, 5.479807955453042, 2.6758706223550823, 2.0980564084045974, 1.7910952262514135, 2.595164079028862, 1.9608050330891795, 1.132885408777772, 0.4384248388341401, 0.0), # 145 (6.5327628085018805, 4.787396246674904, 5.642446363049478, 5.855139668589976, 5.16833832168053, 2.5000775731461515, 2.084661488244132, 1.906659785462309, 2.7331423700196282, 1.0530252784215943, 0.8248371327765532, 0.4911049180262681, 0.0, 6.911716664910495, 5.402154098288948, 4.124185663882766, 3.1590758352647823, 5.4662847400392565, 2.669323699647233, 2.084661488244132, 1.7857696951043938, 2.584169160840265, 1.9517132228633256, 1.1284892726098958, 0.4352178406068095, 0.0), # 146 (6.49226477951088, 4.751253342860296, 5.619773847881273, 5.827050673355748, 5.145725919283921, 2.4923515091241004, 2.0709042120551926, 1.9017656179571385, 2.7261199862503442, 1.0473053287130294, 0.8205938142490716, 0.48869496188980743, 0.0, 6.8809380542880945, 5.375644580787881, 4.102969071245358, 3.1419159861390877, 5.4522399725006885, 2.662471865139994, 2.0709042120551926, 1.7802510779457859, 2.5728629596419603, 1.9423502244519164, 1.1239547695762548, 0.43193212207820875, 0.0), # 147 (6.450748558727217, 4.714200234889411, 5.596383224167389, 5.798116323201478, 5.1224748848643, 2.4843422428966253, 2.0567663912490506, 1.8966381762420859, 2.718823679512541, 1.0414090593916896, 0.8162157377471978, 0.48621094929547143, 0.0, 6.8492794562799535, 5.348320442250185, 4.081078688735989, 3.124227178175068, 5.437647359025082, 2.6552934467389204, 2.0567663912490506, 1.7745301734975893, 2.56123744243215, 1.9327054410671598, 1.1192766448334779, 0.42856365771721927, 0.0), # 148 (6.40818505352913, 4.676192641919942, 5.572248217690963, 5.768304827763782, 5.098569152418064, 2.4760368926745198, 2.0422298372369765, 1.8912619802496888, 2.71124030290009, 1.0353280987797628, 0.8116964368945213, 0.48364981555294617, 0.0, 6.81671663601539, 5.320147971082407, 4.058482184472607, 3.1059842963392876, 5.42248060580018, 2.6477667723495646, 2.0422298372369765, 1.7685977804817998, 2.549284576209032, 1.922768275921261, 1.1144496435381928, 0.42510842199272214, 0.0), # 149 (6.364545171294852, 4.6371862831095845, 5.54734255423513, 5.737584396679283, 5.0739926559416135, 2.467422576668583, 2.0272763614302405, 1.8856215499124855, 2.7033567095068674, 1.0290540751994355, 0.8070294453146325, 0.48100849597191764, 0.0, 6.783225358623717, 5.291093455691093, 4.035147226573162, 3.0871622255983056, 5.406713419013735, 2.63987016987748, 2.0272763614302405, 1.7624446976204164, 2.5369963279708068, 1.912528132226428, 1.1094685108470261, 0.4215623893735987, 0.0), # 150 (6.31979981940262, 4.597136877616033, 5.521639959583029, 5.705923239584598, 5.048729329431348, 2.4584864130896094, 2.011887775240113, 1.8797014051630145, 2.695159752426744, 1.0225786169728959, 0.8022082966311207, 0.4782839258620715, 0.0, 6.748781389234255, 5.261123184482786, 4.011041483155603, 3.067735850918687, 5.390319504853488, 2.6315819672282204, 2.011887775240113, 1.7560617236354352, 2.524364664715674, 1.9019744131948664, 1.1043279919166058, 0.41792153432873036, 0.0), # 151 (6.273919905230675, 4.55600014459698, 5.495114159517802, 5.673289566116352, 5.022763106883663, 2.4492155201483965, 1.996045890077866, 1.8734860659338137, 2.686636284753592, 1.0158933524223301, 0.7972265244675764, 0.475473040533094, 0.0, 6.713360492976318, 5.230203445864033, 3.9861326223378812, 3.04768005726699, 5.373272569507184, 2.622880492307339, 1.996045890077866, 1.7494396572488546, 2.5113815534418316, 1.8910965220387843, 1.0990228319035604, 0.4141818313269982, 0.0), # 152 (6.226876336157249, 4.5137318032101215, 5.467738879822579, 5.63965158591116, 4.996077922294963, 2.4395970160557408, 1.9797325173547677, 1.8669600521574208, 2.677773159581286, 1.008989909869926, 0.7920776624475889, 0.472572775294671, 0.0, 6.676938434979222, 5.19830052824138, 3.9603883122379444, 3.0269697296097773, 5.355546319162572, 2.6137440730203894, 1.9797325173547677, 1.742569297182672, 2.4980389611474814, 1.879883861970387, 1.093547775964516, 0.41033925483728384, 0.0), # 153 (6.178640019560583, 4.4702875726131515, 5.439487846280506, 5.604977508605646, 4.968657709661643, 2.429618019022439, 1.9629294684820913, 1.8601078837663743, 2.6685572300036977, 1.0018599176378709, 0.7867552441947484, 0.4695800654564884, 0.0, 6.639490980372286, 5.165380720021371, 3.9337762209737415, 3.005579752913612, 5.337114460007395, 2.604151037272924, 1.9629294684820913, 1.7354414421588849, 2.4843288548308213, 1.8683258362018824, 1.0878975692561013, 0.40638977932846837, 0.0), # 154 (6.129181862818909, 4.425623171963762, 5.410334784674718, 5.569235543836427, 4.940486402980104, 2.419265647259287, 1.9456185548711045, 1.852914080693212, 2.6589753491147006, 0.9944950040483511, 0.7812528033326445, 0.4664918463282322, 0.0, 6.600993894284821, 5.131410309610554, 3.906264016663222, 2.983485012145053, 5.317950698229401, 2.594079712970497, 1.9456185548711045, 1.7280468908994906, 2.470243201490052, 1.856411847945476, 1.0820669569349437, 0.402329379269433, 0.0), # 155 (6.078472773310465, 4.3796943204196515, 5.3802534207883514, 5.532393901240125, 4.911547936246746, 2.408527018977082, 1.92778158793308, 1.845363162870473, 2.649014370008167, 0.9868867974235548, 0.7755638734848673, 0.46330505321958826, 0.0, 6.561422941846148, 5.09635558541547, 3.8778193674243364, 2.960660392270664, 5.298028740016334, 2.5835084280186624, 1.92778158793308, 1.720376442126487, 2.455773968123373, 1.8441313004133755, 1.0760506841576702, 0.39815402912905923, 0.0), # 156 (6.02648365841349, 4.332456737138511, 5.349217480404546, 5.494420790453363, 4.881826243457965, 2.39738925238662, 1.9094003790792877, 1.8374396502306942, 2.63866114577797, 0.9790269260856685, 0.7696819882750067, 0.4600166214402426, 0.0, 6.520753888185581, 5.060182835842667, 3.848409941375033, 2.937080778257005, 5.27732229155594, 2.5724155103229718, 1.9094003790792877, 1.7124208945618713, 2.4409131217289826, 1.831473596817788, 1.0698434960809091, 0.3938597033762283, 0.0), # 157 (5.971744757124192, 4.28299895523299, 5.315727969268237, 5.453861748990747, 4.849963256464532, 2.3851447556146512, 1.890042688371143, 1.8285989841164574, 2.6271098910930926, 0.9706731832582289, 0.7634127670051923, 0.45650663761295607, 0.0, 6.477188687532276, 5.021573013742516, 3.817063835025962, 2.912019549774686, 5.254219782186185, 2.5600385777630406, 1.890042688371143, 1.7036748254390366, 2.424981628232266, 1.8179539163302492, 1.0631455938536476, 0.38936354138481727, 0.0), # 158 (5.9058294135827225, 4.226247901039617, 5.271158545601992, 5.402386295273073, 4.808102031883535, 2.3677218357366487, 1.8672851053542865, 1.8157378442547942, 2.609713936325905, 0.9604561988197493, 0.7556555914158659, 0.4520908349122073, 0.0, 6.420342117536156, 4.97299918403428, 3.7782779570793297, 2.8813685964592475, 5.21942787265181, 2.542032981956712, 1.8672851053542865, 1.6912298826690346, 2.4040510159417674, 1.8007954317576913, 1.0542317091203985, 0.3842043546399652, 0.0), # 159 (5.827897675923448, 4.161737600929857, 5.214613971970593, 5.339146506245316, 4.755424070051625, 2.344692604822253, 1.8408974993535137, 1.7985330631757823, 2.5859800605943066, 0.948241130372579, 0.7463012678146054, 0.4467001299258565, 0.0, 6.349136487114865, 4.913701429184421, 3.731506339073027, 2.844723391117736, 5.171960121188613, 2.5179462884460952, 1.8408974993535137, 1.6747804320158948, 2.3777120350258123, 1.7797155020817725, 1.0429227943941186, 0.3783397819027143, 0.0), # 160 (5.738577643668768, 4.0898886365923435, 5.146697981273539, 5.264743502254037, 4.69247633295046, 2.3163360460661466, 1.8110725784027506, 1.7772001777032602, 2.556221271199738, 0.9341316386341878, 0.7354322206132944, 0.44038449792717144, 0.0, 6.264299235855278, 4.844229477198885, 3.6771611030664717, 2.8023949159025627, 5.112442542399476, 2.4880802487845646, 1.8110725784027506, 1.6545257471901047, 2.34623816647523, 1.754914500751346, 1.029339596254708, 0.37180805787203125, 0.0), # 161 (5.638497416341085, 4.011121589715708, 5.068014306410331, 5.179778403645797, 4.619805782561709, 2.282931142663013, 1.7780030505359237, 1.7519547246610676, 2.5207505754436363, 0.9182313843220465, 0.7231308742238162, 0.43319391418941966, 0.0, 6.166557803344267, 4.765133056083616, 3.615654371119081, 2.754694152966139, 5.041501150887273, 2.4527366145254947, 1.7780030505359237, 1.630665101902152, 2.3099028912808546, 1.7265928012152658, 1.0136028612820662, 0.36464741724688265, 0.0), # 162 (5.528285093462799, 3.9258570419885843, 4.979166680280469, 5.084852330767161, 4.537959380867034, 2.244756877807534, 1.7418816237869603, 1.7230122408730417, 2.4798809806274416, 0.9006440281536252, 0.7094796530580545, 0.42517835398586895, 0.0, 6.0566396291687035, 4.676961893844558, 3.5473982652902722, 2.701932084460875, 4.959761961254883, 2.4122171372222585, 1.7418816237869603, 1.6033977698625244, 2.268979690433517, 1.6949507769223873, 0.9958333360560938, 0.356896094726235, 0.0), # 163 (5.408568774556308, 3.834515575099602, 4.8807588357834515, 4.980566403964691, 4.447484089848101, 2.2020922346943936, 1.7029010061897865, 1.6905882631630231, 2.433925494052593, 0.881473230846394, 0.6945609815278929, 0.4163877925897869, 0.0, 5.935272152915463, 4.580265718487656, 3.472804907639464, 2.644419692539181, 4.867850988105186, 2.3668235684282326, 1.7029010061897865, 1.5729230247817099, 2.2237420449240504, 1.660188801321564, 0.9761517671566904, 0.34859232500905474, 0.0), # 164 (5.279976559144014, 3.7375177707373965, 4.773394505818779, 4.867521743584952, 4.348926871486572, 2.155216196518274, 1.6612539057783289, 1.6548983283548488, 2.383197123020528, 0.8608226531178229, 0.678457284045215, 0.4068722052744414, 0.0, 5.803182814171416, 4.475594258018854, 3.3922864202260747, 2.582467959353468, 4.766394246041056, 2.3168576596967885, 1.6612539057783289, 1.5394401403701956, 2.174463435743286, 1.622507247861651, 0.954678901163756, 0.33977434279430885, 0.0), # 165 (5.143136546748318, 3.6352842105905996, 4.657677423285953, 4.746319469974501, 4.242834687764114, 2.1044077464738575, 1.6171330305865146, 1.6161579732723592, 2.328008874832686, 0.8387959556853827, 0.661250985021904, 0.39668156731310017, 0.0, 5.661099052523436, 4.363497240444101, 3.3062549251095197, 2.5163878670561473, 4.656017749665372, 2.262621162581303, 1.6171330305865146, 1.5031483903384697, 2.121417343882057, 1.5821064899915007, 0.9315354846571906, 0.33048038278096364, 0.0), # 166 (4.998676836891619, 3.528235476347844, 4.53421132108447, 4.617560703479906, 4.129754500662389, 2.0499458677558273, 1.57073108864827, 1.5745827347393924, 2.2686737567905064, 0.8154967992665431, 0.6430245088698437, 0.3858658539790306, 0.0, 5.509748307558397, 4.244524393769336, 3.215122544349218, 2.4464903977996286, 4.537347513581013, 2.2044158286351494, 1.57073108864827, 1.4642470483970196, 2.0648772503311945, 1.5391869011599693, 0.9068422642168941, 0.32074867966798587, 0.0), # 167 (4.847225529096317, 3.416792149697761, 4.403599932113832, 4.481846564447728, 4.010233272163062, 1.9921095435588663, 1.5222407879975217, 1.5303881495797866, 2.205504776195428, 0.7910288445787746, 0.6238602800009175, 0.3744750405455008, 0.0, 5.34985801886317, 4.119225446000509, 3.1193014000045878, 2.3730865337363234, 4.411009552390856, 2.1425434094117013, 1.5222407879975217, 1.4229353882563331, 2.005116636081531, 1.4939488548159094, 0.8807199864227666, 0.31061746815434194, 0.0), # 168 (4.689410722884812, 3.3013748123289846, 4.26644698927354, 4.33977817322453, 3.884817964247797, 1.9311777570776578, 1.4718548366681967, 1.4837897546173817, 2.1388149403488903, 0.7654957523395476, 0.6038407228270092, 0.3625591022857782, 0.0, 5.182155626024628, 3.9881501251435596, 3.019203614135046, 2.296487257018642, 4.277629880697781, 2.0773056564643344, 1.4718548366681967, 1.3794126836268983, 1.9424089821238986, 1.4465927244081769, 0.853289397854708, 0.30012498293899864, 0.0), # 169 (4.525860517779507, 3.1824040459301473, 4.12335622546309, 4.191956650156872, 3.7540555388982577, 1.8674294915068832, 1.4197659426942213, 1.435003086676016, 2.0689172565523304, 0.7390011832663317, 0.5830482617600022, 0.3501680144731306, 0.0, 5.007368568629644, 3.8518481592044362, 2.9152413088000113, 2.217003549798995, 4.137834513104661, 2.0090043213464224, 1.4197659426942213, 1.3338782082192022, 1.8770277694491289, 1.3973188833856243, 0.824671245092618, 0.28930945872092256, 0.0), # 170 (4.3572030133028, 3.06030043218988, 3.9749313735819856, 4.038983115591321, 3.61849295809611, 1.801143730041226, 1.3661668141095222, 1.3842436825795277, 1.9961247321071884, 0.7116487980765979, 0.5615653212117798, 0.33735175238082576, 0.0, 4.826224286265092, 3.710869276189083, 2.807826606058899, 2.134946394229793, 3.992249464214377, 1.9379411556113388, 1.3661668141095222, 1.2865312357437328, 1.809246479048055, 1.3463277051971074, 0.7949862747163972, 0.27820913019908006, 0.0), # 171 (4.184066308977092, 2.9354845527968174, 3.8217761665297245, 3.881458689874438, 3.4786771838230153, 1.7325994558753692, 1.3112501589480263, 1.331727079151757, 1.9207503743149028, 0.6835422574878162, 0.5394743255942259, 0.3241602912821315, 0.0, 4.639450218517843, 3.5657632041034453, 2.6973716279711297, 2.050626772463448, 3.8415007486298056, 1.8644179108124599, 1.3112501589480263, 1.237571039910978, 1.7393385919115076, 1.2938195632914795, 0.764355233305945, 0.26686223207243803, 0.0), # 172 (4.007078504324784, 2.808376989439591, 3.664494337205808, 3.7199844933527855, 3.3351551780606408, 1.6620756522039952, 1.25520868524366, 1.2776688132165412, 1.8431071904769127, 0.6547852222174565, 0.5168576993192239, 0.310643606450315, 0.0, 4.44777380497477, 3.417079670953465, 2.584288496596119, 1.9643556666523692, 3.6862143809538255, 1.7887363385031578, 1.25520868524366, 1.187196894431425, 1.6675775890303204, 1.2399948311175955, 0.7328988674411617, 0.25530699903996285, 0.0), # 173 (3.8268676988682753, 2.6793983238068333, 3.503689618509735, 3.5551616463729245, 3.1884739027906486, 1.5898513022217866, 1.1982351010303502, 1.2222844215977202, 1.763508187894657, 0.6254813529829895, 0.4937978667986571, 0.2968516731586446, 0.0, 4.251922485222747, 3.26536840474509, 2.468989333993285, 1.8764440589489682, 3.527016375789314, 1.7111981902368083, 1.1982351010303502, 1.1356080730155618, 1.5942369513953243, 1.1850538821243084, 0.700737923701947, 0.24358166580062124, 0.0), # 174 (3.6440619921299646, 2.548969137587176, 3.3399657433410055, 3.3875912692814207, 3.039180319994703, 1.5162053891234268, 1.1405221143420232, 1.165789441119132, 1.682266373869575, 0.595734310501885, 0.4703772524444093, 0.28283446668038764, 0.0, 4.052623698848646, 3.1111791334842636, 2.3518862622220467, 1.7872029315056546, 3.36453274773915, 1.632105217566785, 1.1405221143420232, 1.0830038493738763, 1.5195901599973516, 1.1291970897604737, 0.6679931486682011, 0.23172446705337968, 0.0), # 175 (3.459289483632255, 2.4175100124692537, 3.173926444599119, 3.2178744824248353, 2.8878213916544695, 1.441416896103598, 1.082262433212606, 1.1083994086046165, 1.5996947557031045, 0.5656477554916135, 0.44667828066836407, 0.268641962288812, 0.0, 3.8506048854393393, 2.9550615851769315, 2.23339140334182, 1.69694326647484, 3.199389511406209, 1.551759172046463, 1.082262433212606, 1.0295834972168558, 1.4439106958272347, 1.0726248274749453, 0.6347852889198239, 0.2197736374972049, 0.0), # 176 (3.273178272897546, 2.2854415301416977, 3.006175455183576, 3.0466124061497295, 2.7349440797516125, 1.365764806356983, 1.0236487656760251, 1.050329860878011, 1.5161063406966853, 0.535325348669645, 0.4227833758824049, 0.2543241352571853, 0.0, 3.6465934845817, 2.7975654878290377, 2.113916879412024, 1.6059760460089345, 3.0322126813933705, 1.4704618052292153, 1.0236487656760251, 0.9755462902549877, 1.3674720398758062, 1.0155374687165768, 0.6012350910367152, 0.20776741183106345, 0.0), # 177 (3.0863564594482376, 2.153184272293141, 2.8373165079938762, 2.87440616080267, 2.581095346267794, 1.2895281030782653, 0.964873819766207, 0.9917963347631552, 1.431814136151756, 0.5048707507534501, 0.39877496249841504, 0.2399309608587752, 0.0, 3.4413169358626017, 2.6392405694465264, 1.993874812492075, 1.51461225226035, 2.863628272303512, 1.3885148686684172, 0.964873819766207, 0.9210915021987609, 1.290547673133897, 0.9581353869342235, 0.5674633015987752, 0.1957440247539219, 0.0), # 178 (0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0), # 179 ) passenger_allighting_rate = ( (0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1, 0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1), # 0 (0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1, 0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1), # 1 (0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1, 0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1), # 2 (0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1, 0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1), # 3 (0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1, 0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1), # 4 (0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1, 0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1), # 5 (0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1, 0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1), # 6 (0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1, 0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1), # 7 (0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1, 0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1), # 8 (0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1, 0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1), # 9 (0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1, 0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1), # 10 (0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1, 0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1), # 11 (0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1, 0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1), # 12 (0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1, 0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1), # 13 (0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1, 0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1), # 14 (0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1, 0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1), # 15 (0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1, 0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1), # 16 (0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1, 0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1), # 17 (0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1, 0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1), # 18 (0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1, 0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1), # 19 (0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1, 0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1), # 20 (0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1, 0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1), # 21 (0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1, 0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1), # 22 (0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1, 0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1), # 23 (0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1, 0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1), # 24 (0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1, 0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1), # 25 (0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1, 0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1), # 26 (0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1, 0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1), # 27 (0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1, 0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1), # 28 (0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1, 0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1), # 29 (0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1, 0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1), # 30 (0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1, 0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1), # 31 (0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1, 0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1), # 32 (0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1, 0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1), # 33 (0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1, 0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1), # 34 (0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1, 0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1), # 35 (0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1, 0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1), # 36 (0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1, 0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1), # 37 (0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1, 0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1), # 38 (0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1, 0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1), # 39 (0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1, 0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1), # 40 (0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1, 0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1), # 41 (0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1, 0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1), # 42 (0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1, 0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1), # 43 (0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1, 0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1), # 44 (0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1, 0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1), # 45 (0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1, 0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1), # 46 (0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1, 0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1), # 47 (0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1, 0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1), # 48 (0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1, 0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1), # 49 (0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1, 0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1), # 50 (0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1, 0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1), # 51 (0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1, 0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1), # 52 (0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1, 0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1), # 53 (0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1, 0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1), # 54 (0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1, 0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1), # 55 (0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1, 0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1), # 56 (0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1, 0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1), # 57 (0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1, 0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1), # 58 (0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1, 0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1), # 59 (0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1, 0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1), # 60 (0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1, 0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1), # 61 (0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1, 0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1), # 62 (0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1, 0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1), # 63 (0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1, 0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1), # 64 (0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1, 0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1), # 65 (0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1, 0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1), # 66 (0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1, 0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1), # 67 (0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1, 0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1), # 68 (0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1, 0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1), # 69 (0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1, 0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1), # 70 (0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1, 0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1), # 71 (0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1, 0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1), # 72 (0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1, 0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1), # 73 (0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1, 0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1), # 74 (0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1, 0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1), # 75 (0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1, 0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1), # 76 (0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1, 0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1), # 77 (0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1, 0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1), # 78 (0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1, 0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1), # 79 (0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1, 0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1), # 80 (0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1, 0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1), # 81 (0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1, 0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1), # 82 (0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1, 0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1), # 83 (0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1, 0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1), # 84 (0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1, 0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1), # 85 (0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1, 0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1), # 86 (0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1, 0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1), # 87 (0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1, 0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1), # 88 (0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1, 0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1), # 89 (0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1, 0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1), # 90 (0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1, 0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1), # 91 (0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1, 0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1), # 92 (0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1, 0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1), # 93 (0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1, 0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1), # 94 (0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1, 0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1), # 95 (0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1, 0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1), # 96 (0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1, 0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1), # 97 (0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1, 0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1), # 98 (0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1, 0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1), # 99 (0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1, 0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1), # 100 (0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1, 0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1), # 101 (0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1, 0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1), # 102 (0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1, 0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1), # 103 (0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1, 0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1), # 104 (0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1, 0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1), # 105 (0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1, 0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1), # 106 (0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1, 0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1), # 107 (0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1, 0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1), # 108 (0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1, 0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1), # 109 (0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1, 0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1), # 110 (0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1, 0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1), # 111 (0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1, 0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1), # 112 (0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1, 0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1), # 113 (0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1, 0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1), # 114 (0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1, 0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1), # 115 (0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1, 0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1), # 116 (0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1, 0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1), # 117 (0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1, 0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1), # 118 (0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1, 0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1), # 119 (0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1, 0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1), # 120 (0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1, 0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1), # 121 (0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1, 0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1), # 122 (0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1, 0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1), # 123 (0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1, 0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1), # 124 (0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1, 0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1), # 125 (0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1, 0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1), # 126 (0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1, 0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1), # 127 (0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1, 0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1), # 128 (0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1, 0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1), # 129 (0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1, 0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1), # 130 (0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1, 0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1), # 131 (0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1, 0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1), # 132 (0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1, 0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1), # 133 (0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1, 0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1), # 134 (0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1, 0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1), # 135 (0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1, 0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1), # 136 (0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1, 0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1), # 137 (0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1, 0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1), # 138 (0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1, 0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1), # 139 (0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1, 0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1), # 140 (0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1, 0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1), # 141 (0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1, 0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1), # 142 (0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1, 0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1), # 143 (0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1, 0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1), # 144 (0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1, 0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1), # 145 (0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1, 0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1), # 146 (0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1, 0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1), # 147 (0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1, 0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1), # 148 (0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1, 0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1), # 149 (0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1, 0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1), # 150 (0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1, 0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1), # 151 (0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1, 0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1), # 152 (0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1, 0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1), # 153 (0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1, 0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1), # 154 (0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1, 0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1), # 155 (0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1, 0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1), # 156 (0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1, 0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1), # 157 (0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1, 0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1), # 158 (0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1, 0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1), # 159 (0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1, 0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1), # 160 (0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1, 0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1), # 161 (0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1, 0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1), # 162 (0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1, 0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1), # 163 (0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1, 0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1), # 164 (0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1, 0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1), # 165 (0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1, 0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1), # 166 (0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1, 0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1), # 167 (0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1, 0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1), # 168 (0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1, 0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1), # 169 (0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1, 0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1), # 170 (0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1, 0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1), # 171 (0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1, 0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1), # 172 (0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1, 0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1), # 173 (0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1, 0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1), # 174 (0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1, 0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1), # 175 (0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1, 0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1), # 176 (0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1, 0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1), # 177 (0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1, 0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1), # 178 (0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1, 0, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 0.07692307692307693, 1), # 179 ) """ parameters for reproducibiliy. More information: https://numpy.org/doc/stable/reference/random/parallel.html """ #initial entropy entropy = 8991598675325360468762009371570610170 #index for seed sequence child child_seed_index = ( 1, # 0 50, # 1 )
275.234225
493
0.768699
32,987
257,344
5.996574
0.21272
0.360348
0.345788
0.655177
0.380301
0.371181
0.367253
0.366121
0.365797
0.365797
0
0.84919
0.096113
257,344
934
494
275.528908
0.001199
0.015586
0
0.200873
0
0
0
0
0
0
0
0
0
1
0
false
0.005459
0
0
0
0
0
0
0
null
1
1
1
0
0
0
0
0
0
0
1
0
0
0
0
1
1
0
0
0
0
0
0
0
null
0
0
0
0
0
0
0
0
0
0
0
0
0
6
1eb95c11db6f813d4386b94dc770092d96a0a284
489
py
Python
util/__init__.py
sabbirahm3d/ds5k-capstone-dataset
d6d5ed5a1043de87b90e3e4b1737e6ffc563eeaf
[ "MIT" ]
null
null
null
util/__init__.py
sabbirahm3d/ds5k-capstone-dataset
d6d5ed5a1043de87b90e3e4b1737e6ffc563eeaf
[ "MIT" ]
1
2021-06-01T22:50:17.000Z
2021-06-01T22:50:17.000Z
util/__init__.py
ribbas/ds5k-capstone-dataset
d6d5ed5a1043de87b90e3e4b1737e6ffc563eeaf
[ "MIT" ]
null
null
null
#!/usr/bin/env python # -*- coding: utf-8 -*- from datetime import datetime from termcolor import cprint def __arg_fmt(*args): return datetime.now().strftime("%H:%M:%S | ") + \ ("{}" * len(args)).format(*args) def eprint(*ostream): cprint(__arg_fmt(*ostream), "red") def wprint(*ostream): cprint(__arg_fmt(*ostream), "yellow") def sprint(*ostream): cprint(__arg_fmt(*ostream), "green") def iprint(*ostream): cprint(__arg_fmt(*ostream), "blue")
14.818182
53
0.627812
62
489
4.709677
0.532258
0.10274
0.219178
0.260274
0.356164
0
0
0
0
0
0
0.002488
0.177914
489
32
54
15.28125
0.723881
0.08589
0
0
0
0
0.069663
0
0
0
0
0
0
1
0.384615
true
0
0.153846
0.076923
0.615385
0.692308
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
1
0
0
0
1
1
0
6
1edd74ade2f07c4eab8b5dc45039a0297e1f387a
96
py
Python
venv/lib/python3.8/site-packages/libfuturize/fixes/fix_basestring.py
Retraces/UkraineBot
3d5d7f8aaa58fa0cb8b98733b8808e5dfbdb8b71
[ "MIT" ]
2
2022-03-13T01:58:52.000Z
2022-03-31T06:07:54.000Z
venv/lib/python3.8/site-packages/libfuturize/fixes/fix_basestring.py
DesmoSearch/Desmobot
b70b45df3485351f471080deb5c785c4bc5c4beb
[ "MIT" ]
19
2021-11-20T04:09:18.000Z
2022-03-23T15:05:55.000Z
venv/lib/python3.8/site-packages/libfuturize/fixes/fix_basestring.py
DesmoSearch/Desmobot
b70b45df3485351f471080deb5c785c4bc5c4beb
[ "MIT" ]
null
null
null
/home/runner/.cache/pip/pool/6c/79/0a/b8cce1af914c5f08d794c3a3b287784b7ad091575bce1a16578fad9776
96
96
0.895833
9
96
9.555556
1
0
0
0
0
0
0
0
0
0
0
0.416667
0
96
1
96
96
0.479167
0
0
0
0
0
0
0
0
1
0
0
0
0
null
null
0
0
null
null
0
1
0
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
1
0
0
0
1
0
0
0
0
0
0
0
0
6
94c20b5ff60d57ac703d79b462aee0406e97f756
27,849
py
Python
baseline_modify/utils/model.py
lxchtan/DSTC9-Track1
26c3d36df1ab13a766767989434b79894b5317c5
[ "Apache-2.0" ]
7
2021-04-20T09:04:59.000Z
2022-03-07T03:42:09.000Z
baseline_modify/utils/model.py
lxchtan/DSTC9-Track1
26c3d36df1ab13a766767989434b79894b5317c5
[ "Apache-2.0" ]
null
null
null
baseline_modify/utils/model.py
lxchtan/DSTC9-Track1
26c3d36df1ab13a766767989434b79894b5317c5
[ "Apache-2.0" ]
null
null
null
import torch import torch.nn.functional as F import logging import math import numpy as np from torch.nn import KLDivLoss, MSELoss from .metrics import ROUGE_list from .auxiliary import top_filtering logger = logging.getLogger(__name__) def run_batch_generation_for_latentCopy(args, model, batch): batch = tuple(input_tensor.to(args.device) for input_tensor in batch) input_ids, token_type_ids, lm_labels, input_masks, input_masks_with_knowledge, knowledgeROIs = batch ori_model = model.module if hasattr(model, "module") else model ori_model.model_stage = 0 model_outputs = model(input_ids=input_ids, token_type_ids=None, labels=lm_labels, attention_mask=None) z, z_distribution = model_outputs[:2] ori_model.model_stage = 1 model_outputs = model(input_ids=input_ids, token_type_ids=None, labels=lm_labels, attention_mask=input_masks) z_prior, z_prior_distribution = model_outputs[:2] ori_model.model_stage = 2 model_outputs = model(input_ids=input_ids, token_type_ids=None, labels=lm_labels, attention_mask=input_masks_with_knowledge, z_hidden_embeds=z, knowledgeROIs=knowledgeROIs) KLDiv_Loss = KLDivLoss(reduction='batchmean') kld_loss = KLDiv_Loss(z_prior_distribution.log(), z_distribution) if getattr(args, "latent_modify", '') != 'real' \ else KLDiv_Loss(z_distribution.log(), z_prior_distribution) lm_loss, bow_loss, norm_loss, lm_logits = model_outputs[:4] return lm_loss, lm_logits, (bow_loss, norm_loss), kld_loss def run_batch_generation_eval_for_latentCopy(args, model, batch): batch = tuple(input_tensor.to(args.device) for input_tensor in batch) input_ids, token_type_ids, lm_labels, input_masks, input_masks_with_knowledge, knowledgeROIs = batch ori_model = model.module if hasattr(model, "module") else model ori_model.model_stage = 1 model_outputs = model(input_ids=input_ids, token_type_ids=None, labels=lm_labels, attention_mask=input_masks) z_prior, z_prior_distribution = model_outputs[:2] ori_model.model_stage = 2 model_outputs = model(input_ids=input_ids, token_type_ids=None, labels=lm_labels, attention_mask=input_masks_with_knowledge, z_hidden_embeds=z_prior, knowledgeROIs=knowledgeROIs) lm_loss, bow_loss, norm_loss, lm_logits = model_outputs[:4] return lm_loss, lm_logits, (bow_loss, norm_loss), torch.tensor([]) def run_batch_generation_greedy_sample_for_latentCopy(args, model, batch, dataset): special_tokens_ids = args.tokenizer.convert_tokens_to_ids(dataset.SPECIAL_TOKENS_VALUES) current_output = [] another_data = [] example = batch[0] knowledge, history = example["knowledge"], example["history"] response_text = example["response_text"] dialog_id = example["dialog_id"] instance, sequence = dataset.build_input_from_segments( knowledge, history, current_output, with_eos=False ) input_ids = torch.tensor(instance["input_ids"], device=args.device).unsqueeze(0) input_masks = torch.tensor(instance["input_masks"], device=args.device).unsqueeze(0) ori_model = model.module if hasattr(model, "module") else model ori_model.model_stage = 1 model_outputs = model(input_ids=input_ids, token_type_ids=None, attention_mask=input_masks) z_post, z_post_distribution = model_outputs[:2] ori_model.model_stage = 2 for i in range(args.max_length): instance, sequence = dataset.build_input_from_segments( knowledge, history, current_output, with_eos=False ) input_ids = torch.tensor(instance["input_ids"], device=args.device).unsqueeze(0) # input_masks = torch.tensor(instance["input_masks"], device=args.device).unsqueeze(0) input_masks_with_knowledge = torch.tensor(instance["input_masks_with_knowledge"], device=args.device).unsqueeze(0) knowledgeROIs = torch.tensor(instance["knowledgeROIs"], device=args.device).unsqueeze(0) model_outputs = model(input_ids=input_ids, token_type_ids=None, attention_mask=input_masks_with_knowledge, z_hidden_embeds=z_post, knowledgeROIs=knowledgeROIs) logits, attention_dist, p_gen = model_outputs[:3] logits = logits[0, -1, :] / args.temperature logits = top_filtering(logits, top_k=args.top_k, top_p=args.top_p) probs = F.softmax(logits, dim=-1) prev = torch.topk(probs, 1)[1] if args.no_sample else torch.multinomial(probs, 1) if i < args.min_length and prev.item() in special_tokens_ids: while prev.item() in special_tokens_ids: if probs.max().item() == 1: logger.warning("Warning: model generating special token with probability 1! Breaking...") break prev = torch.topk(probs, 1)[1] if args.no_sample else torch.multinomial(probs, 1) if prev.item() in special_tokens_ids: break if type(p_gen) != float: p_gen = p_gen[0, -1, 0] # logger.info(p_gen) attention_dist = attention_dist[0, -1, :] probs *= p_gen attention_dist *= (1 - p_gen) probs = probs.scatter_add(0, input_ids.squeeze(0), attention_dist) prev = torch.topk(probs, 1)[1] if args.no_sample else torch.multinomial(probs, 1) if i < args.min_length and prev.item() in special_tokens_ids: while prev.item() in special_tokens_ids: if probs.max().item() == 1: logger.warning("Warning: model generating special token with probability 1! Breaking...") break prev = torch.multinomial(probs, num_samples=1) if prev.item() in special_tokens_ids: break current_output.append(prev.item()) if type(p_gen) != float: another_data.append(format(p_gen.item(), ".4f")) return (current_output, another_data), response_text, dialog_id # Auxiliary for Beam Search def get_initial_values(args, model, dataset, history, knowledge, model_pre=lambda outputs, **kwargs: outputs, prob_postprocess=lambda outputs, probs, **kwargs: (outputs, probs)): outputs = () GFM = True # args.GFM current_output = [] sub_beam_size = args.sub_beam_size group_num = args.group_num whole_beam_size = sub_beam_size * group_num instance, sequence = dataset.build_input_from_segments( knowledge, history, current_output, with_eos=False ) input_ids = torch.tensor(instance["input_ids"], device=args.device).unsqueeze(0) input_masks = torch.tensor(instance["input_masks"], device=args.device).unsqueeze(0) model_args = { 'input_ids': input_ids, 'token_type_ids': None, 'attention_mask': input_masks } outputs = model_pre(outputs, args=args, model=model, model_args=model_args, instance=instance, whole_beam_size=whole_beam_size) model_outputs = model(**model_args) logits = model_outputs[0] logits = logits[0, -1, :] / args.temperature probs = F.softmax(logits, dim=-1) outputs, probs = prob_postprocess(outputs, probs, input_ids=input_ids, model_outputs=model_outputs, whole_beam_size=whole_beam_size) _indices = torch.topk(probs, whole_beam_size)[1] \ if args.no_sample else torch.multinomial(probs, whole_beam_size) # torch.multinomial(probs, whole_beam_size) _values = torch.index_select(torch.log(probs), 0, index=_indices) if GFM: _index = [] for i in range(group_num): _index.extend([i + group_num * j for j in range(sub_beam_size)]) _values = _values[_index] _indices = _indices[_index] score = _values.unsqueeze(-1) current_output = _indices.unsqueeze(-1) outputs = (current_output, score) + outputs return outputs # (current_output, score, z_post, p_gen_tensors) def build_inputs(args, current_output, dataset, history, knowledge, whole_beam_size): input_ids = [] input_masks = [] current_output_list = current_output.cpu().numpy().tolist() for j in range(whole_beam_size): instance, sequence = dataset.build_input_from_segments( knowledge, history, current_output_list[j], with_eos=False ) input_ids.append(torch.tensor(instance["input_ids"], device=args.device)) input_masks.append(torch.tensor(instance["input_masks"], device=args.device)) input_ids = torch.stack(input_ids, dim=0) input_masks = torch.stack(input_masks, dim=0) output = (input_ids, input_masks) return output def cal_next_word(args, score, probs, current_output, indices_shift, special_tokens_ids, place_hold_index, final_output, final_score, finish_index, finish_output_sign): sub_beam_size = args.sub_beam_size group_num = args.group_num tmp_new_scores = torch.log(probs) tmp_score = score.repeat((1, tmp_new_scores.size(-1))) + tmp_new_scores tmp_score = tmp_score.reshape((group_num, -1)) tmp_indices = torch.topk(tmp_score, sub_beam_size)[1] if args.no_sample \ else torch.multinomial(F.softmax(tmp_score, dim=-1), sub_beam_size) tmp_score = tmp_score.gather(dim=-1, index=tmp_indices).view(-1, 1) tmp_indices = tmp_indices.view(-1, 1) last_indices = tmp_indices // tmp_new_scores.size(-1) + indices_shift new_indices = tmp_indices % tmp_new_scores.size(-1) tmp_current_output = torch.cat([current_output[last_indices.view(-1)], new_indices], dim=-1) gain_finish_sentences(args, tmp_score, tmp_current_output, final_output, final_score, finish_index, finish_output_sign, place_hold_index, special_tokens_ids, new_indices, score, last_indices) return tmp_current_output, tmp_score def gain_finish_sentences(args, tmp_score, tmp_current_output, final_output, final_score, finish_index, finish_output_sign, place_hold_index, special_tokens_ids, new_indices=None, score=None, last_indices=None): sub_beam_size = args.sub_beam_size for j in finish_index.copy(): if new_indices is None or new_indices[j] in special_tokens_ids: group_id = j // sub_beam_size group_start = group_id * sub_beam_size finish_output_sign[group_id] -= 1 if finish_output_sign[group_id] == 0: for k in range(group_start, group_start + sub_beam_size): finish_index.remove(k) # Less than zero since finish_index.copy() will not be deleted at this time elif finish_output_sign[group_id] < 0: finish_output_sign[group_id] = 0 continue place_hold = group_start + sub_beam_size - 1 - finish_output_sign[group_id] place_hold_index.append(place_hold) final_score[place_hold] = tmp_score[j].item() final_output[place_hold] = tmp_current_output[j].cpu().numpy().tolist() if last_indices is not None: score[ last_indices.view(-1)[j]] = -10000 # The score wouldn't be reorder, so we need to used the last indices. def get_final_response(args, knowledge, final_score, final_output): select_method = getattr(args, "response_select_method", "final_score") output_index = int(np.argmax(final_score)) if select_method == "rouge_score": metric = ROUGE_list() rouge_score = [] for sentence in final_output: metric.update((sentence, knowledge)) rouge_score.append(metric.compute()) output_index = int(np.argmax(rouge_score)) real_output = final_output[output_index] return real_output def run_batch_generation_beam_sample_for_latentCopy(args, model, batch, dataset): def prob_postprocess_latentCopy(outputs, probs, **kwargs): input_ids = kwargs.get('input_ids') model_outputs = kwargs.get('model_outputs') whole_beam_size = kwargs.get('whole_beam_size') attention_dist, p_gen = model_outputs[1:3] if not isinstance(p_gen, float): p_gen = p_gen[0, -1, 0] attention_dist = attention_dist[0, -1, :] probs *= p_gen attention_dist *= (1 - p_gen) probs = probs.scatter_add(0, input_ids.squeeze(0), attention_dist) p_gen_tensors = p_gen.repeat((whole_beam_size, 1)) outputs += (p_gen_tensors,) return outputs, probs def model_pre_latentCopy(outputs, **kwargs): args = kwargs.get('args') model = kwargs.get('model') model_args = kwargs.get('model_args') instance = kwargs.get('instance') whole_beam_size = kwargs.get('whole_beam_size') model.model_stage = 1 model_outputs = model(**model_args) z_post, z_post_distribution = model_outputs[:2] model.model_stage = 2 input_masks_with_knowledge = torch.tensor(instance["input_masks_with_knowledge"], device=args.device).unsqueeze(0) knowledgeROIs = torch.tensor(instance["knowledgeROIs"], device=args.device).unsqueeze(0) model_args.update({ 'attention_mask': input_masks_with_knowledge, 'z_hidden_embeds': z_post, 'knowledgeROIs': knowledgeROIs }) z_post = z_post.expand((whole_beam_size,) + z_post.size()[1:]) return outputs + (z_post,) def build_inputs_knowledge(args, current_output, dataset, history, knowledge, whole_beam_size): input_ids = [] input_masks = [] knowledgeROIs = [] current_output_list = current_output.cpu().numpy().tolist() for j in range(whole_beam_size): instance, sequence = dataset.build_input_from_segments( knowledge, history, current_output_list[j], with_eos=False ) input_ids.append(torch.tensor(instance["input_ids"], device=args.device)) input_masks.append(torch.tensor(instance["input_masks_with_knowledge"], device=args.device)) knowledgeROIs.append(torch.tensor(instance["knowledgeROIs"], device=args.device)) input_ids = torch.stack(input_ids, dim=0) input_masks = torch.stack(input_masks, dim=0) knowledgeROIs = torch.stack(knowledgeROIs, dim=0) return input_ids, input_masks, knowledgeROIs build_inputs = build_inputs_knowledge # Initial sub_beam_size = args.sub_beam_size group_num = args.group_num whole_beam_size = sub_beam_size * group_num special_tokens_ids = args.tokenizer.convert_tokens_to_ids(dataset.SPECIAL_TOKENS_VALUES) finish_index = [i for i in range(whole_beam_size)] finish_output_sign = [sub_beam_size] * group_num final_score = [-1] * whole_beam_size final_output = [None] * whole_beam_size place_hold_index = [] indices_shift = torch.tensor(range(0, whole_beam_size, sub_beam_size), dtype=torch.int64, device=args.device) \ .unsqueeze(-1).repeat(1, sub_beam_size).view(-1).unsqueeze(-1) example = batch[0] knowledge, history = example["knowledge"], example["history"] response_text = example["response_text"] dialog_id = example["dialog_id"] current_output, score, z_post, p_gen_tensors = get_initial_values(args, model, dataset, history, knowledge, model_pre=model_pre_latentCopy, prob_postprocess=prob_postprocess_latentCopy) for i in range(1, args.max_length): input_ids, input_masks_with_knowledge, knowledgeROIs = build_inputs(args, current_output, dataset, history, knowledge, whole_beam_size) model_outputs = model(input_ids=input_ids, token_type_ids=None, attention_mask=input_masks_with_knowledge, z_hidden_embeds=z_post, knowledgeROIs=knowledgeROIs) logits, attention_dist, p_gen = model_outputs[:3] logits = logits[:, -1, :] / args.temperature probs = F.softmax(logits, dim=-1) # Jump out with lm score cal_next_word(args, score, probs, current_output, indices_shift, special_tokens_ids, place_hold_index, final_output, final_score, finish_index, finish_output_sign) if len(finish_index) == 0: break # Real calculation if type(p_gen) != float: p_gen = p_gen[:, -1, :] p_gen_tensors = torch.cat([p_gen_tensors, p_gen], dim=-1) attention_dist = attention_dist[:, -1, :] probs *= p_gen attention_dist *= (1 - p_gen) probs = probs.scatter_add(1, input_ids, attention_dist) current_output, score = cal_next_word(args, score, probs, current_output, indices_shift, special_tokens_ids, place_hold_index, final_output, final_score, finish_index, finish_output_sign) if len(finish_index) == 0: break # Remain gain_finish_sentences(args, score, current_output, final_output, final_score, finish_index, finish_output_sign, place_hold_index, special_tokens_ids) # End real_output = get_final_response(args, knowledge, final_score, final_output) return (real_output, ("Beam Result", final_output, final_score, p_gen_tensors.cpu().numpy().tolist())), response_text, dialog_id # TODO: reformat def run_batch_generation_diversity_beam_sample_for_latentCopy(args, model, batch, dataset): GFM = True # args.GFM sub_beam_size = args.sub_beam_size group_num = args.group_num whole_beam_size = sub_beam_size * group_num penalty_lambda = getattr(args, "penalty_lambda", 0.6) special_tokens_ids = args.tokenizer.convert_tokens_to_ids(dataset.SPECIAL_TOKENS_VALUES) current_output = [] example = batch[0] knowledge, history = example["knowledge"], example["history"] response_text = example["response_text"] dialog_id = example["dialog_id"] # Initial indices_shift = torch.tensor(range(0, whole_beam_size, sub_beam_size), dtype=torch.int64, device=args.device) \ .unsqueeze(-1).repeat(1, sub_beam_size).view(-1).unsqueeze(-1) finish_index = [i for i in range(whole_beam_size)] place_hold_index = [] finish_output_sign = [sub_beam_size] * group_num final_score = [-1] * whole_beam_size final_output = [None] * whole_beam_size instance, sequence = dataset.build_input_from_segments( knowledge, history, current_output, with_eos=False ) input_ids = torch.tensor(instance["input_ids"], device=args.device).unsqueeze(0) input_masks = torch.tensor(instance["input_masks"], device=args.device).unsqueeze(0) input_masks_with_knowledge = torch.tensor(instance["input_masks_with_knowledge"], device=args.device).unsqueeze(0) knowledgeROIs = torch.tensor(instance["knowledgeROIs"], device=args.device).unsqueeze(0) model.model_stage = 1 model_outputs = model(input_ids=input_ids, token_type_ids=None, attention_mask=input_masks) z_post, z_post_distribution = model_outputs[:2] model.model_stage = 2 model_outputs = model(input_ids=input_ids, token_type_ids=None, attention_mask=input_masks_with_knowledge, z_hidden_embeds=z_post, knowledgeROIs=knowledgeROIs) logits, attention_dist, p_gen = model_outputs[:3] logits = logits[0, -1, :] / args.temperature probs = F.softmax(logits, dim=-1) assert type(p_gen) != float p_gen = p_gen[0, -1, 0] attention_dist = attention_dist[0, -1, :] probs *= p_gen attention_dist *= (1 - p_gen) probs = probs.scatter_add(0, input_ids.squeeze(0), attention_dist) new_scores = torch.log(probs) new_indices_list = [] for _ in range(group_num): sub_new_indices = torch.topk(new_scores, sub_beam_size)[1] if args.no_sample \ else torch.multinomial(F.softmax(new_scores, dim=-1), sub_beam_size) new_indices_list.append(sub_new_indices) new_scores[sub_new_indices] -= penalty_lambda new_indices = torch.cat(new_indices_list, dim=0) scores = new_scores[new_indices].unsqueeze(1) current_output = new_indices.unsqueeze(1) p_gen_tensors = p_gen.repeat((whole_beam_size, 1)) z_post = z_post.expand((whole_beam_size,) + z_post.size()[1:]) for i in range(1, args.max_length): # Build input input_ids = [] input_masks_with_knowledge = [] knowledgeROIs = [] current_output_list = current_output.cpu().numpy().tolist() for j in range(whole_beam_size): instance, sequence = dataset.build_input_from_segments( knowledge, history, current_output_list[j], with_eos=False ) input_ids.append(torch.tensor(instance["input_ids"], device=args.device)) input_masks_with_knowledge.append(torch.tensor(instance["input_masks_with_knowledge"], device=args.device)) knowledgeROIs.append(torch.tensor(instance["knowledgeROIs"], device=args.device)) input_ids = torch.stack(input_ids, dim=0) input_masks_with_knowledge = torch.stack(input_masks_with_knowledge, dim=0) knowledgeROIs = torch.stack(knowledgeROIs, dim=0) model_outputs = model(input_ids=input_ids, token_type_ids=None, attention_mask=input_masks_with_knowledge, z_hidden_embeds=z_post, knowledgeROIs=knowledgeROIs) logits, attention_dist, p_gen = model_outputs[:3] logits = logits[:, -1, :] / args.temperature probs = F.softmax(logits, dim=-1) # Jump out with lm score tmp_new_scores = torch.log(probs) new_indices_list = [] last_indices_list = [] for i in range(1, group_num + 1): sub_new_scores = scores[(i - 1) * sub_beam_size: i * sub_beam_size, ...] \ + tmp_new_scores[(i - 1) * sub_beam_size: i * sub_beam_size, ...] sub_indices = torch.topk(sub_new_scores.view(-1), sub_beam_size)[1] if args.no_sample \ else torch.multinomial(F.softmax(sub_new_scores.view(-1), dim=-1), sub_beam_size) sub_last_indices = sub_indices // sub_new_scores.size(-1) + (i - 1) * sub_beam_size sub_new_indices = sub_indices % sub_new_scores.size(-1) new_indices_list.append(sub_new_indices) last_indices_list.append(sub_last_indices) tmp_new_scores[i * sub_beam_size:, sub_new_indices] -= penalty_lambda new_indices = torch.cat(new_indices_list, dim=0) last_indices = torch.cat(last_indices_list, dim=0) tmp_scores = scores[last_indices] + tmp_new_scores.gather(dim=1, index=new_indices.unsqueeze(1)) for j in finish_index.copy(): if new_indices[j] in special_tokens_ids: group_id = j // sub_beam_size group_start = group_id * sub_beam_size finish_output_sign[group_id] -= 1 if finish_output_sign[group_id] == 0: for k in range(group_start, group_start + sub_beam_size): finish_index.remove(k) elif finish_output_sign[group_id] < 0: continue place_hold = group_start + sub_beam_size - 1 - finish_output_sign[group_id] # place_hold_index.append(place_hold) final_score[place_hold] = tmp_scores[j].item() final_output[place_hold] = current_output[j].cpu().numpy().tolist() scores[j] = -10000 if len(finish_index) == 0: break # End with Jump out # Cal Real Score if type(p_gen) != float: p_gen = p_gen[:, -1, :] attention_dist = attention_dist[:, -1, :] probs *= p_gen attention_dist *= (1 - p_gen) probs = probs.scatter_add(1, input_ids, attention_dist) new_scores = torch.log(probs) new_indices_list = [] last_indices_list = [] for i in range(1, group_num + 1): sub_new_scores = scores[(i - 1) * sub_beam_size: i * sub_beam_size, ...] \ + new_scores[(i - 1) * sub_beam_size: i * sub_beam_size, ...] sub_indices = torch.topk(sub_new_scores.view(-1), sub_beam_size)[1] if args.no_sample \ else torch.multinomial(F.softmax(sub_new_scores.view(-1), dim=-1), sub_beam_size) sub_last_indices = sub_indices // sub_new_scores.size(-1) + (i - 1) * sub_beam_size sub_new_indices = sub_indices % sub_new_scores.size(-1) new_indices_list.append(sub_new_indices) last_indices_list.append(sub_last_indices) new_scores[i * sub_beam_size:, sub_new_indices] -= penalty_lambda new_indices = torch.cat(new_indices_list, dim=0) last_indices = torch.cat(last_indices_list, dim=0) scores = scores[last_indices] + new_scores.gather(dim=1, index=new_indices.unsqueeze(1)) # Break Out for j in finish_index.copy(): if new_indices[j] in special_tokens_ids: group_id = j // sub_beam_size group_start = group_id * sub_beam_size finish_output_sign[group_id] -= 1 if finish_output_sign[group_id] == 0: for k in range(group_start, group_start + sub_beam_size): finish_index.remove(k) elif finish_output_sign[group_id] < 0: continue place_hold = group_start + sub_beam_size - 1 - finish_output_sign[group_id] # place_hold_index.append(place_hold) final_score[place_hold] = scores[j].item() final_output[place_hold] = current_output[j].cpu().numpy().tolist() scores[j] = -10000 if len(finish_index) == 0: break # End Break Out current_output = torch.cat([current_output[last_indices], new_indices.unsqueeze(1)], dim=-1) p_gen_tensors = torch.cat([p_gen_tensors, p_gen], dim=-1) # Deal with residue for j in finish_index: group_id = j // sub_beam_size group_start = group_id * sub_beam_size finish_output_sign[group_id] -= 1 place_hold = group_start + sub_beam_size - 1 - finish_output_sign[group_id] final_score[place_hold] = scores[j].item() final_output[place_hold] = current_output[j].cpu().numpy().tolist() output_index = int(np.argmax(final_score)) select_method = getattr(args, "response_select_method", "final_score") if select_method == "rouge_score": metric = ROUGE_list() rouge_score = [] for sentence in final_output: metric.update((sentence, knowledge)) rouge_score.append(metric.compute()) output_index = int(np.argmax(rouge_score)) real_output = final_output[output_index] return (real_output, ("Beam Result", final_output, final_score, p_gen_tensors.cpu().numpy().tolist())), response_text, dialog_id def run_batch_selection_train(args, model, batch): batch = tuple(input_tensor.to(args.device) for input_tensor in batch if isinstance(input_tensor, torch.Tensor)) input_ids, token_type_ids, mc_token_ids, lm_labels, mc_labels = batch model_outputs = model( input_ids=input_ids, token_type_ids=token_type_ids, mc_token_ids=mc_token_ids, mc_labels=mc_labels ) mc_loss = model_outputs[0] lm_logits, mc_logits = model_outputs[1], model_outputs[2] return mc_loss, lm_logits, mc_logits, mc_labels def run_batch_selection_eval(args, model, batch): candidates_per_forward = args.max_candidates_per_forward_eval * ( args.n_gpu if isinstance(model, torch.nn.DataParallel) else 1) batch = tuple(input_tensor.to(args.device) for input_tensor in batch if isinstance(input_tensor, torch.Tensor)) input_ids, token_type_ids, mc_token_ids, _, mc_labels = batch all_mc_logits = [] for index in range(0, input_ids.size(1), candidates_per_forward): model_outputs = model( input_ids=input_ids[0, index:index + candidates_per_forward].unsqueeze(1), token_type_ids=token_type_ids[0, index:index + candidates_per_forward].unsqueeze(1), mc_token_ids=mc_token_ids[0, index:index + candidates_per_forward].unsqueeze(1) ) mc_logits = model_outputs[1] all_mc_logits.append(mc_logits.detach()) all_mc_logits = torch.cat(all_mc_logits, dim=0).unsqueeze(0) return torch.tensor(0.0), torch.tensor([]), all_mc_logits, mc_labels def run_batch_detection(args, model, batch): batch = tuple(input_tensor.to(args.device) for input_tensor in batch if isinstance(input_tensor, torch.Tensor)) input_ids, token_type_ids, mc_token_ids, lm_labels, labels = batch model_outputs = model( input_ids=input_ids, token_type_ids=token_type_ids, mc_token_ids=mc_token_ids, labels=labels ) cls_loss = model_outputs[0] lm_logits, cls_logits = model_outputs[1], model_outputs[2] return cls_loss, lm_logits, cls_logits, labels def run_batch_generation(args, model, batch): model_name = f"run_batch_generation_for_{args.model_type}" return eval(model_name)(args, model, batch) def run_batch_generation_sample(args, model, batch, dataset): middle_name = "beam" if args.beam_search else "greedy" diversity = getattr(args, "diversity_beam_search", False) return eval(f"run_batch_generation{'_diversity' if diversity else ''}_{middle_name}_sample_for_{args.model_type}")( args, model, batch, dataset)
45.504902
120
0.7192
4,014
27,849
4.64001
0.063279
0.037369
0.032483
0.017718
0.814443
0.802792
0.780617
0.759624
0.726336
0.706792
0
0.010717
0.172394
27,849
611
121
45.579378
0.797379
0.023053
0
0.636183
0
0
0.038924
0.011626
0
0
0
0.001637
0.001988
1
0.035785
false
0
0.015905
0
0.085487
0
0
0
0
null
0
0
0
1
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
6
a202acc8c5643962327b2e18e9f3ad2d9f380a4c
201
py
Python
003_LargestPrimeFactor.py
joetache4/ProjectEuler
f101e927d73dbafa11af1b208992bf0d830c88b1
[ "MIT" ]
null
null
null
003_LargestPrimeFactor.py
joetache4/ProjectEuler
f101e927d73dbafa11af1b208992bf0d830c88b1
[ "MIT" ]
null
null
null
003_LargestPrimeFactor.py
joetache4/ProjectEuler
f101e927d73dbafa11af1b208992bf0d830c88b1
[ "MIT" ]
null
null
null
''' Joe Walter difficulty: 5% run time: 0:00 answer: 6857 *** 003 Largest Prime Factor Largest prime factor of 600851475143 ''' from lib.num import factor print(max(factor(600851475143)))
11.166667
36
0.701493
28
201
5.035714
0.785714
0.170213
0.255319
0
0
0
0
0
0
0
0
0.216049
0.19403
201
17
37
11.823529
0.654321
0.681592
0
0
0
0
0
0
0
0
0
0
0
1
0
true
0
0.5
0
0.5
0.5
1
0
0
null
0
1
0
0
0
0
0
0
0
0
1
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
1
0
6
a204af6f655d1f7fbe2b1fd188ddc9fd3b880401
30
py
Python
VTree/__init__.py
MarcoMuellner/VTree
c4bd509daeb80652075df1937b5861fa3e281dff
[ "MIT" ]
null
null
null
VTree/__init__.py
MarcoMuellner/VTree
c4bd509daeb80652075df1937b5861fa3e281dff
[ "MIT" ]
null
null
null
VTree/__init__.py
MarcoMuellner/VTree
c4bd509daeb80652075df1937b5861fa3e281dff
[ "MIT" ]
null
null
null
from VTree.vtree import VTree
15
29
0.833333
5
30
5
0.6
0
0
0
0
0
0
0
0
0
0
0
0.133333
30
1
30
30
0.961538
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
1
0
0
6
bf5c7c9f63a96c942b79f08278c9d7d73453139a
1,420
py
Python
sudoku/question.py
eudika/puzzle
ede8c33c322f63b92736c2ec3135127322718733
[ "MIT" ]
null
null
null
sudoku/question.py
eudika/puzzle
ede8c33c322f63b92736c2ec3135127322718733
[ "MIT" ]
null
null
null
sudoku/question.py
eudika/puzzle
ede8c33c322f63b92736c2ec3135127322718733
[ "MIT" ]
1
2021-02-01T12:30:16.000Z
2021-02-01T12:30:16.000Z
# use 0 for blank cell questions = [ [ [5, 3, 0, 0, 7, 0, 0, 0, 0], [6, 0, 0, 1, 9, 5, 0, 0, 0], [0, 9, 8, 0, 0, 0, 0, 6, 0], [8, 0, 0, 0, 6, 0, 0, 0, 3], [4, 0, 0, 8, 0, 3, 0, 0, 1], [7, 0, 0, 0, 2, 0, 0, 0, 6], [0, 6, 0, 0, 0, 0, 2, 8, 0], [0, 0, 0, 4, 1, 9, 0, 0, 5], [0, 0, 0, 0, 8, 0, 0, 7, 9] ], [ [0, 0, 0, 0, 0, 0, 0, 0, 0], [0, 5, 8, 0, 0, 0, 3, 9, 0], [0, 1, 7, 6, 0, 3, 2, 4, 0], [0, 0, 2, 3, 0, 1, 6, 0, 0], [0, 0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 3, 5, 0, 4, 8, 0, 0], [0, 2, 4, 9, 0, 6, 7, 1, 0], [0, 7, 1, 0, 0, 0, 4, 3, 0], [0, 0, 0, 0, 0, 0, 0, 0, 0] ], [ [8, 0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 3, 6, 0, 0, 0, 0, 0], [0, 7, 0, 0, 9, 0, 2, 0, 0], [0, 5, 0, 0, 0, 7, 0, 0, 0], [0, 0, 0, 0, 4, 5, 7, 0, 0], [0, 0, 0, 1, 0, 0, 0, 3, 0], [0, 0, 1, 0, 0, 0, 0, 6, 8], [0, 0, 8, 5, 0, 0, 0, 1, 0], [0, 9, 0, 0, 0, 0, 4, 0, 0] ], [ [4, 9, 0, 0, 0, 0, 0, 6, 8], [8, 0, 0, 0, 4, 0, 0, 0, 3], [0, 0, 0, 6, 0, 1, 0, 0, 0], [0, 0, 5, 0, 6, 0, 4, 0, 0], [0, 4, 0, 5, 0, 3, 0, 1, 0], [0, 0, 1, 0, 2, 0, 3, 0, 0], [0, 0, 0, 4, 0, 2, 0, 0, 0], [5, 0, 0, 0, 1, 0, 0, 0, 9], [9, 2, 0, 0, 0, 0, 0, 8, 1] ], ]
28.979592
36
0.245775
330
1,420
1.057576
0.045455
0.848138
0.825215
0.641834
0.69341
0.567335
0.363897
0.180516
0.180516
0.12894
0
0.429326
0.466901
1,420
48
37
29.583333
0.031704
0.014085
0
0.130435
0
0
0
0
0
0
0
0
0
1
0
false
0
0
0
0
0
0
0
1
null
1
1
1
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
6
bfd027c4b523608bcae21d254032d38a95c54c3a
44,176
py
Python
code/transitemcee.py
mrtommyb/GP_model_Kepler_data
a51ba4b6ab325484b47b2e594539f537cacdbb62
[ "MIT" ]
null
null
null
code/transitemcee.py
mrtommyb/GP_model_Kepler_data
a51ba4b6ab325484b47b2e594539f537cacdbb62
[ "MIT" ]
1
2018-12-19T10:46:59.000Z
2018-12-20T14:36:03.000Z
code/transitemcee.py
mrtommyb/GP_model_Kepler_data
a51ba4b6ab325484b47b2e594539f537cacdbb62
[ "MIT" ]
1
2018-12-18T16:46:13.000Z
2018-12-18T16:46:13.000Z
import sys import numpy as np #import matplotlib.pyplot as plt import emcee import tmodtom as tmod import time as thetime from scipy.stats import truncnorm from claretquadpy import claretquad from claret4ppy import claretlimb4p from copy import deepcopy from numpy import random #from bilin_interp import ld_quad class transitemcee(object): def __init__(self,nplanets,cadence=1625.3, ldfileloc='/Users/tom/svn_code/tom_code/', codedir='/Users/tom/svn_code/tom_code/'): sys.path.append(codedir) self.nplanets = nplanets nmax = 1500000 #from the fortran self._ntt = np.zeros(nplanets) self._tobs = np.empty([self.nplanets,nmax]) self._omc = np.empty([self.nplanets,nmax]) self.cadence = cadence / 86400. self.allow_ecc_orbit = False self.ldfileloc = ldfileloc self.onlytransits = False self.tregion = 500 def get_stellar(self,teff,logg,FeH,n_ldparams=4): """ read in stellar parameters inputs teff : float The effective temperature of the star logg : float the surface gravity of the star in log cgs FeH : float the metalicity of the star in log solar optional n_ldparams : int """ self.Teff = teff self.logg = logg self.FeH = FeH if n_ldparams == 2: #if teff < 3500 and logg >= 3.5: if False: #this block should never run ldfile = self.ldfileloc + 'claret-quad-phoenix.txt' self.ld1,self.ld2 = ld_quad(ldfile, self.Teff,self.logg) self.ld3 = 0.0 self.ld4 = 0.0 #elif logg < 3.5 or teff >= 3500: if True: ldfile = self.ldfileloc + 'claret-limb-quad.txt' self.ld1,self.ld2 = claretquad(ldfile, self.Teff,self.logg,self.FeH) self.ld3 = 0.0 self.ld4 = 0.0 elif n_ldparams == 4: ldfile = self.ldfileloc + 'claret-limb.txt' self.ld1,self.ld2,self.ld3,self.ld4 = claretlimb4p(ldfile, self.Teff,self.logg,self.FeH) def open_lightcurve(self,filename,timeoffset=0.0, normalize=False): t = np.genfromtxt(filename).T time = t[0] - timeoffset if normalize: flux = t[1] / np.median(t[1]) err = t[2] / np.median(t[1]) else: flux = t[1] err = t[2] self.time = time self.flux = flux self.err = err self.npt = len(time) self._itime = np.zeros(self.npt) + self.cadence self._datatype = np.zeros(self.npt) def already_open(self,t1,f1,e1,timeoffset=0.0,normalize=False): time = t1 - timeoffset if normalize: flux = f1 / np.median(f1) err = e1 / np.median(f1) else: flux = f1 err = e1 self.time = time self.flux = flux self.err = err self.npt = len(time) self._itime = np.zeros(self.npt) + self.cadence self._datatype = np.zeros(self.npt) def get_rho(self,rho_vals,prior=False,rho_start=0.0, rho_stop = 30.): """ inputs rho_vals : array_like Two parameter array with value rho, rho_unc prior : bool, optional should this rho be used as a prior? """ self.rho_0 = rho_vals[0] self.rho_0_unc = rho_vals[1] self.rho_0_start = rho_start self.rho_0_stop = rho_stop if prior: self.rho_prior = True else: self.rho_prior = False def get_zpt(self,zpt_0): self.zpt_0 = zpt_0 if self.zpt_0 == 0.0: self.zpt_0 = 1.E-10 def get_sol(self,*args,**kwargs): """ reads the guess transit fit solution There are 6 args for every planet T0, period, impact paramter, rp/rs, ecosw and esinw optional keywords, these are kept fixed (for now) dil : float, optional dilution veloffset : float, optional velocity zeropoint rvamp : float, optional radial velocity amplitude from doppler beaming occ : float, optional occultation depth ell : float, optional amplitude of ellipsoidal variations alb : float, optional geometric albedo of the planet """ assert len(args) == self.nplanets * 6 if 'dil' in kwargs.keys(): dil = kwargs['dil'] print ' running with dil = %s' %(dil) else: dil = 0.0 if 'veloffset' in kwargs.keys(): veloffset = kwargs['veloffset'] else: veloffset = 0.0 if 'rvamp' in kwargs.keys(): rvamp = kwargs['rvamp'] else: rvamp = 0.0 if 'occ' in kwargs.keys(): occ = kwargs['occ'] else: occ = 0.0 if 'ell' in kwargs.keys(): ell = kwargs['ell'] else: ell = 0.0 if 'alb' in kwargs.keys(): alb = kwargs['alb'] else: alb = 0.0 try: if self.zpt_0 == 0.: self.zpt_0 = 1.E-10 except AttributeError: self.zpt_0 = 1.E-10 self.zpt_0_unc = 1.E-6 fit_sol = np.array([self.rho_0,self.zpt_0]) for i in xrange(self.nplanets): T0_0 = args[i*6] per_0 = args[i*6 +1] b_0 = args[i*6 +2] rprs_0 = args[i*6 +3] ecosw_0 = args[i*6 +4] esinw_0 = args[i*6 +5] new_params = np.array([T0_0,per_0, b_0,rprs_0,ecosw_0,esinw_0]) fit_sol = np.r_[fit_sol,new_params] self.fit_sol = fit_sol self.fit_sol_0 = deepcopy(self.fit_sol) self.fixed_sol = np.array([self.ld1,self.ld2, self.ld3,self.ld4, dil,veloffset,rvamp, occ,ell,alb]) def cut_non_transit(self,ntdur=10): #make a mask for each planet candidate self.onlytransits = True tregion = np.zeros(self.nplanets) maskdat = np.zeros([self.npt,self.nplanets],dtype=bool) for i in xrange(self.nplanets): T0 = self.fit_sol[i*6 + 2] per = self.fit_sol[i*6 + 3] rho = self.fit_sol[0] ars = self.get_ar(rho,per) tdur_dys = (1./ars) * per * (1./np.pi) #this is buggy because T0 is not nessessarily time of first transit #but time of a transit. So fudge. #subtract make T0 the first transit time0 = np.copy(T0) while True: if time0 - per < self.time[0]: break else: time0 = time0 - per ntransits = int((self.time[-1] - self.time[0]) / per) + 1 t_times = np.arange(ntransits)*per + T0 #make sure the first and last transit are not excluded even if #partially in the data t_times = np.r_[t_times,t_times[0] - per,t_times[-1] + per] for j in t_times: maskdat[:,i] = np.logical_or(maskdat[:,i], np.logical_and( self.time < j +tdur_dys*ntdur, self.time > j - tdur_dys*ntdur) ) tregion[i] = ntdur*tdur_dys #create a final mask that is the OR of the #individual masks finmask = np.zeros(self.npt) for i in xrange(self.nplanets): finmask = np.logical_or(finmask,maskdat[:,i]) self.time = self.time[finmask] self.flux = self.flux[finmask] self.err = self.err[finmask] self._itime = self._itime[finmask] self._datatype = self._datatype[finmask] self.tregion = tregion def get_ar(self,rho,period): """ gets a/R* from period and mean stellar density""" G = 6.67E-11 rho_SI = rho * 1000. tpi = 3. * np.pi period_s = period * 86400. part1 = period_s**2 * G * rho_SI ar = (part1 / tpi)**(1./3.) return ar # def calc_model(self,fitsol): # sol = np.zeros([8 + 10*self.nplanets]) # rho = fitsol[0] # zpt = fitsol[1] # ld1,ld2,ld3,ld4 = self.fixed_sol[0:4] # dil = self.fixed_sol[4] # veloffset = self.fixed_sol[5] # fixed_stuff = self.fixed_sol[6:10] # sol[0:8] = np.array([rho,ld1,ld2,ld3,ld4, # dil,veloffset,zpt]) # for i in xrange(self.nplanets): # sol[8+(i*10):8+(i*10)+10] = np.r_[fitsol[2+i*6:8+i*6],fixed_stuff] # tmodout = tmod.transitmodel(self.nplanets,sol,self.time,self._itime, # self._ntt,self._tobs,self._omc,self._datatype) # return tmodout - 1. # def logchi2(self,fitsol): # rho = fitsol[0] # if rho < 0.001 or rho > 30.: # return -np.inf # rprs = fitsol[np.arange(self.nplanets)*6 + 5] # if np.any(rprs < 0.) or np.any(rprs > 0.5): # return -np.inf # ecosw = fitsol[np.arange(self.nplanets)*6 + 6] # if np.any(ecosw < -1.0) or np.any(ecosw > 1.0): # return -np.inf # esinw = fitsol[np.arange(self.nplanets)*6 + 7] # if np.any(esinw < -1.0) or np.any(esinw > 1.0): # return -np.inf # b = fitsol[np.arange(self.nplanets)*6 + 4] # if np.any(b < 0.) or np.any(b > 1.0 + rprs): # return -np.inf # model_lc = self.calc_model(fitsol) # if self.rho_prior: # chi2prior = (self.rho_0 - rho)**2 / self.rho_0_unc**2 # else: # chi2prior = 0.0 # chi2val = np.sum((model_lc - self.flux)**2 / self.err**2) # chi2tot = chi2val + chi2prior # logp = -chi2tot / 2. # return logp # def do_emcee(self,nwalkers,threads=16,burnin=100,fullrun=1000): # l_var = 8 # p0 = self.get_guess(nwalkers) # sampler = emcee.EnsembleSampler(nwalkers, l_var, self.logchi2, # threads=threads) # time1 = thetime.time() # pos, prob, state = sampler.run_mcmc(p0, burnin) # sampler.reset() # time2 = thetime.time() # print 'burn-in took ' + str((time2 - time1)/60.) + ' min' # time1 = thetime.time() # sampler.run_mcmc(pos, fullrun) # time2 = thetime.time() # print 'MCMC run took ' + str((time2 - time1)/60.) + ' min' # print # print("Mean acceptance: " # + str(np.mean(sampler.acceptance_fraction))) # print # try: # print("Autocorrelation times sampled:", fullrun / sampler.acor) # except RuntimeError: # print("No Autocorrelation") # return sampler, (time2 - time1)/60. def get_guess(self,nwalkers): """ pick sensible starting ranges for the guess parameters T0, period, impact paramter, rp/rs, ecosw and esinw """ rho_unc = 0.001 zpt_unc = 1.E-8 T0_unc = 0.0002 per_unc = 0.00005 b_unc = 0.001 rprs_unc = 0.0001 ecosw_unc = 0.001 esinw_unc = 0.001 p0 = np.zeros([nwalkers,2+self.nplanets*6]) rho = self.fit_sol[0] zpt = self.fit_sol[1] start,stop = (0.0001 - rho) / rho_unc, (30.0 - rho) / rho_unc p0[...,0] = truncnorm.rvs(start,stop ,loc=rho,scale=rho_unc,size=nwalkers) p0[...,1] = np.random.normal(loc=zpt,scale=zpt,size=nwalkers) for i in xrange(self.nplanets): T0,per,b,rprs,ecosw,esinw = self.fit_sol[i*6+2:i*6 + 8] b = 0.0 ecosw = 0.0 esinw = 0.0 p0[...,i*6+2] = np.random.normal(T0,T0_unc,size=nwalkers) p0[...,i*6+3] = np.random.normal(per,per_unc,size=nwalkers) start,stop = (0.0 - b) / b_unc, (0.5 - b) / b_unc p0[...,i*6+4] = truncnorm.rvs(start,stop ,loc=b,scale=b_unc,size=nwalkers) start,stop = (0.0 - rprs) / rprs_unc, (0.5 - rprs) / rprs_unc p0[...,i*6+5] = truncnorm.rvs(start,stop ,loc=rprs,scale=rprs_unc,size=nwalkers) start,stop = (0.0 - ecosw) / ecosw_unc, (0.5 - ecosw) / ecosw_unc p0[...,i*6+6] = truncnorm.rvs(start,stop ,loc=ecosw,scale=ecosw_unc,size=nwalkers) start,stop = (0.0 - esinw) / esinw_unc, (0.5 - esinw) / esinw_unc p0[...,i*6+7] = truncnorm.rvs(start,stop ,loc=esinw,scale=esinw_unc,size=nwalkers) return p0 class transitemcee_paramprior(transitemcee): def __init__(self,nplanets,cadence=1626.3, ldfileloc='/Users/tom/svn_code/tom_code/'): transitemcee.__init__(self,nplanets,cadence,ldfileloc) def get_stellar(self,teff,teff_unc,logg,logg_unc,FeH,FeH_unc, n_ldparams=2): """ read in stellar parameters inputs teff : float The effective temperature of the star logg : float the surface gravity of the star in log cgs FeH : float the metalicity of the star in log solar optional n_ldparams : int """ self.Teff = teff self.Teff_unc = teff_unc self.logg = logg self.logg_unc = logg_unc self.FeH = FeH self.FeH_unc = FeH_unc self.n_ldparams = n_ldparams def get_sol(self,*args,**kwargs): """ reads the guess transit fit solution There are 6 args for every planet T0, period, impact paramter, rp/rs, ecosw and esinw optional keywords, these are kept fixed (for now) dil : float, optional dilution veloffset : float, optional velocity zeropoint rvamp : float, optional radial velocity amplitude from doppler beaming occ : float, optional occultation depth ell : float, optional amplitude of ellipsoidal variations alb : float, optional geometric albedo of the planet """ assert len(args) == self.nplanets * 6 if 'dil' in kwargs.keys(): dil = kwargs['dil'] print ' running with dil = %s' %(dil) else: dil = 0.0 if 'veloffset' in kwargs.keys(): veloffset = kwargs['veloffset'] else: veloffset = 0.0 if 'rvamp' in kwargs.keys(): rvamp = kwargs['rvamp'] else: rvamp = 0.0 if 'occ' in kwargs.keys(): occ = kwargs['occ'] else: occ = 0.0 if 'ell' in kwargs.keys(): ell = kwargs['ell'] else: ell = 0.0 if 'alb' in kwargs.keys(): alb = kwargs['alb'] else: alb = 0.0 try: if self.zpt_0 == 0.: self.zpt_0 = 1.E-10 except AttributeError: self.zpt_0 = 1.E-10 self.zpt_0_unc = 1.E-6 fit_sol = np.array([self.rho_0,self.zpt_0,self.Teff,self.logg,self.FeH]) for i in xrange(self.nplanets): T0_0 = args[i*6] per_0 = args[i*6 +1] b_0 = args[i*6 +2] rprs_0 = args[i*6 +3] ecosw_0 = args[i*6 +4] esinw_0 = args[i*6 +5] new_params = np.array([T0_0,per_0, b_0,rprs_0,ecosw_0,esinw_0]) fit_sol = np.r_[fit_sol,new_params] self.fit_sol = fit_sol self.fit_sol_0 = deepcopy(self.fit_sol) self.fixed_sol = np.array([ dil,veloffset,rvamp, occ,ell,alb]) def get_guess(self,nwalkers): """ pick sensible starting ranges for the guess parameters T0, period, impact paramter, rp/rs, ecosw and esinw """ rho_unc = 0.001 zpt_unc = 1.E-8 teff_unc = 10 logg_unc = 0.01 feh_unc = 0.01 T0_unc = 0.0002 per_unc = 0.00005 b_unc = 0.001 rprs_unc = 0.0001 ecosw_unc = 0.001 esinw_unc = 0.001 p0 = np.zeros([nwalkers,5+self.nplanets*6]) rho = self.fit_sol[0] zpt = self.fit_sol[1] teff = self.fit_sol[2] logg = self.fit_sol[3] feh = self.fit_sol[4] start,stop = (0.0001 - rho) / rho_unc, (30.0 - rho) / rho_unc p0[...,0] = truncnorm.rvs(start,stop ,loc=rho,scale=rho_unc,size=nwalkers) p0[...,1] = np.random.normal(loc=zpt,scale=zpt,size=nwalkers) start,stop = (3500. - teff) / teff_unc, (50000. - teff) / teff_unc p0[...,2] = truncnorm.rvs(start,stop ,loc=teff,scale=teff_unc,size=nwalkers) start,stop = (0.0 - logg) / logg_unc, (5. - logg) / logg_unc p0[...,3] = truncnorm.rvs(start,stop ,loc=logg,scale=logg_unc,size=nwalkers) start,stop = (-5.0 - feh) / feh_unc, (1.0 - feh) / feh_unc p0[...,4] = truncnorm.rvs(start,stop ,loc=feh,scale=feh_unc,size=nwalkers) for i in xrange(self.nplanets): T0,per,b,rprs,ecosw,esinw = self.fit_sol[i*6+5:i*6 + 11] b = 0.0 ecosw = 0.0 esinw = 0.0 p0[...,i*6+5] = np.random.normal(T0,T0_unc,size=nwalkers) p0[...,i*6+6] = np.random.normal(per,per_unc,size=nwalkers) start,stop = (0.0 - b) / b_unc, (0.5 - b) / b_unc p0[...,i*6+7] = truncnorm.rvs(start,stop ,loc=b,scale=b_unc,size=nwalkers) start,stop = (0.0 - rprs) / rprs_unc, (0.5 - rprs) / rprs_unc p0[...,i*6+8] = truncnorm.rvs(start,stop ,loc=rprs,scale=rprs_unc,size=nwalkers) start,stop = (0.0 - ecosw) / ecosw_unc, (0.5 - ecosw) / ecosw_unc p0[...,i*6+9] = truncnorm.rvs(start,stop ,loc=ecosw,scale=ecosw_unc,size=nwalkers) start,stop = (0.0 - esinw) / esinw_unc, (0.5 - esinw) / esinw_unc p0[...,i*6+10] = truncnorm.rvs(start,stop ,loc=esinw,scale=esinw_unc,size=nwalkers) return p0 def cut_non_transit(self,ntdur=10): #make a mask for each planet candidate self.onlytransits = True tregion = np.zeros(self.nplanets) maskdat = np.zeros([self.npt,self.nplanets],dtype=bool) for i in xrange(self.nplanets): T0 = self.fit_sol[i*6 + 5] per = self.fit_sol[i*6 + 6] rho = self.fit_sol[0] ars = self.get_ar(rho,per) tdur_dys = (1./ars) * per * (1./np.pi) #this is buggy because T0 is not nessessarily time of first transit #but time of a transit. So fudge. #subtract make T0 the first transit time0 = np.copy(T0) while True: if time0 - per < self.time[0]: break else: time0 = time0 - per ntransits = int((self.time[-1] - self.time[0]) / per) + 1 t_times = np.arange(ntransits)*per + T0 #make sure the first and last transit are not excluded even if #partially in the data t_times = np.r_[t_times,t_times[0] - per,t_times[-1] + per] for j in t_times: maskdat[:,i] = np.logical_or(maskdat[:,i], np.logical_and( self.time < j +tdur_dys*ntdur, self.time > j - tdur_dys*ntdur) ) tregion[i] = ntdur*tdur_dys #create a final mask that is the OR of the #individual masks finmask = np.zeros(self.npt) for i in xrange(self.nplanets): finmask = np.logical_or(finmask,maskdat[:,i]) self.time = self.time[finmask] self.flux = self.flux[finmask] self.err = self.err[finmask] self._itime = self._itime[finmask] self._datatype = self._datatype[finmask] self.tregion = tregion class transitemcee_paramprior_occ(transitemcee_paramprior): pass class transitemcee_fitldp(transitemcee): def __init__(self,nplanets,cadence=1626.3, ldfileloc='/Users/tom/svn_code/tom_code/', codedir='/Users/tom/svn_code/tom_code/'): transitemcee.__init__(self,nplanets,cadence,ldfileloc,codedir) def get_stellar(self,teff,logg,FeH, n_ldparams=2,ldp_prior=True): """ read in stellar parameters inputs teff : float The effective temperature of the star logg : float the surface gravity of the star in log cgs FeH : float the metalicity of the star in log solar optional n_ldparams : int """ self.Teff = teff self.logg = logg self.FeH = FeH self.ld1_unc = 0.1 self.ld2_unc = 0.1 self.ld3_unc = 0.1 self.ld4_unc = 0.1 if teff < 3500: teff = 3500 self.ld1_unc = 0.2 self.ld2_unc = 0.2 if logg < 0.0: logg = 0.0 self.ld1_unc = 0.05 self.ld2_unc = 0.05 if logg > 5.0: logg = 5.0 self.ld1_unc = 0.05 self.ld2_unc = 0.05 if FeH < -5.0: FeH = -5.0 self.ld1_unc = 0.05 self.ld2_unc = 0.05 if FeH > 1.0: FeH = 1.0 self.ld1_unc = 0.05 self.ld2_unc = 0.05 if n_ldparams == 2: ldfile = self.ldfileloc + 'claret-limb-quad.txt' self.ld1,self.ld2 = claretquad(ldfile, teff,logg,FeH) self.ld3 = 0.0 self.ld4 = 0.0 if teff < 3500: self.ld1,self.ld2 = claretquad(ldfile, 3500.,logg,FeH) elif n_ldparams == 4: ldfile = self.ldfileloc + 'claret-limb.txt' self.ld1,self.ld2,self.ld3,self.ld4 = claretlimb4p( ldfile, self.Teff,self.logg,self.FeH) self.ldp_prior = ldp_prior self.n_ldparams = n_ldparams def get_sol(self,*args,**kwargs): """ reads the guess transit fit solution There are 6 args for every planet T0, period, impact paramter, rp/rs, ecosw and esinw optional keywords, these are kept fixed (for now) dil : float, optional dilution veloffset : float, optional velocity zeropoint rvamp : float, optional radial velocity amplitude from doppler beaming occ : float, optional occultation depth ell : float, optional amplitude of ellipsoidal variations alb : float, optional geometric albedo of the planet """ assert len(args) == self.nplanets * 6 if 'dil' in kwargs.keys(): dil = kwargs['dil'] print ' running with dil = %s' %(dil) else: dil = 0.0 if 'veloffset' in kwargs.keys(): veloffset = kwargs['veloffset'] else: veloffset = 0.0 if 'rvamp' in kwargs.keys(): rvamp = kwargs['rvamp'] else: rvamp = 0.0 if 'occ' in kwargs.keys(): occ = kwargs['occ'] else: occ = 0.0 if 'ell' in kwargs.keys(): ell = kwargs['ell'] else: ell = 0.0 if 'alb' in kwargs.keys(): alb = kwargs['alb'] else: alb = 0.0 try: if self.zpt_0 == 0.: self.zpt_0 = 1.E-10 except AttributeError: self.zpt_0 = 1.E-10 self.zpt_0_unc = 1.E-6 if self.n_ldparams == 2: fit_sol = np.array([self.rho_0,self.zpt_0, self.ld1,self.ld2]) elif self.n_ldparams == 4: fit_sol = np.array([self.rho_0,self.zpt_0, self.ld1,self.ld2,self.ld3, self.ld4]) for i in xrange(self.nplanets): T0_0 = args[i*6] per_0 = args[i*6 +1] b_0 = args[i*6 +2] rprs_0 = args[i*6 +3] ecosw_0 = args[i*6 +4] esinw_0 = args[i*6 +5] new_params = np.array([T0_0,per_0, b_0,rprs_0,ecosw_0,esinw_0]) fit_sol = np.r_[fit_sol,new_params] self.fit_sol = fit_sol self.fit_sol_0 = deepcopy(self.fit_sol) self.fixed_sol = np.array([ dil,veloffset,rvamp, occ,ell,alb]) def get_guess(self,nwalkers): """ pick sensible starting ranges for the guess parameters T0, period, impact paramter, rp/rs, ecosw and esinw """ rho_unc = 0.1 zpt_unc = 1.E-8 ld1_unc = 0.05 ld2_unc = 0.05 ld3_unc = 0.05 ld4_unc = 0.05 T0_unc = 0.0002 per_unc = 0.00005 b_unc = 0.001 rprs_unc = 0.0001 ecosw_unc = 0.001 esinw_unc = 0.001 #p0 = np.zeros([nwalkers,4+self.nplanets*6]) if self.n_ldparams == 2: p0 = np.zeros([nwalkers,4+self.nplanets*6+1]) elif self.n_ldparams == 4: p0 = np.zeros([nwalkers,6+self.nplanets*6+1]) rho = self.fit_sol[0] zpt = self.fit_sol[1] ld1 = self.fit_sol[2] ld2 = self.fit_sol[3] if self.n_ldparams == 4: ld3 = self.fit_sol[4] ld4 = self.fit_sol[5] addval = 2 start,stop = (0.0 - ld3) / ld3_unc, (1.0 - ld3) / ld3_unc p0[...,4] = truncnorm.rvs(start,stop ,loc=ld3,scale=ld3_unc,size=nwalkers) start,stop = (0.0 - ld4) / ld4_unc, (1.0 - ld4) / ld4_unc p0[...,5] = truncnorm.rvs(start,stop ,loc=ld4,scale=ld4_unc,size=nwalkers) else: addval = 0 start,stop = (0.0001 - rho) / rho_unc, (30.0 - rho) / rho_unc p0[...,0] = truncnorm.rvs(start,stop ,loc=rho,scale=rho_unc,size=nwalkers) p0[...,1] = np.random.normal(loc=zpt,scale=zpt,size=nwalkers) start,stop = (0.0 - ld1) / ld1_unc, (1.0 - ld1) / ld1_unc p0[...,2] = truncnorm.rvs(start,stop ,loc=ld1,scale=ld1_unc,size=nwalkers) start,stop = (0.0 - ld2) / ld2_unc, (1.0 - ld2) / ld2_unc p0[...,3] = truncnorm.rvs(start,stop ,loc=ld2,scale=ld2_unc,size=nwalkers) for i in xrange(self.nplanets): (T0,per,b,rprs,ecosw, esinw) = self.fit_sol[i*6+4+addval:i*6 + 10+addval] b = 0.2 ecosw = 0.0 esinw = 0.0 p0[...,i*6+4+addval] = np.random.normal( T0,T0_unc,size=nwalkers) p0[...,i*6+5+addval] = np.random.normal( per,per_unc,size=nwalkers) start,stop = (0.0 - b) / b_unc, (0.5 - b) / b_unc p0[...,i*6+6+addval] = truncnorm.rvs( start,stop ,loc=b,scale=b_unc,size=nwalkers) start,stop = (0.0 - rprs) / rprs_unc, (0.5 - rprs) / rprs_unc p0[...,i*6+7+addval] = truncnorm.rvs( start,stop ,loc=rprs,scale=rprs_unc,size=nwalkers) start,stop = (0.0 - ecosw) / ecosw_unc, (0.5 - ecosw) / ecosw_unc p0[...,i*6+8+addval] = truncnorm.rvs( start,stop ,loc=ecosw,scale=ecosw_unc,size=nwalkers) start,stop = (0.0 - esinw) / esinw_unc, (0.5 - esinw) / esinw_unc p0[...,i*6+9+addval] = truncnorm.rvs( start,stop ,loc=esinw,scale=esinw_unc,size=nwalkers) #this is the jitter term #make it like self.err errterm = np.median(self.err) start,stop = 0.0,10. p0[...,-1] = truncnorm.rvs(start,stop, loc=0.0,scale=0.1*errterm,size=nwalkers) return p0 def cut_non_transit(self,ntdur=10): #make a mask for each planet candidate self.onlytransits = True tregion = np.zeros(self.nplanets) maskdat = np.zeros([self.npt,self.nplanets],dtype=bool) if self.n_ldparams == 2: addval = 0 elif self.n_ldparams == 4: addval = 2 for i in xrange(self.nplanets): T0 = self.fit_sol[i*6 + 4+addval] per = self.fit_sol[i*6 + 5+addval] rho = self.fit_sol[0] ars = self.get_ar(rho,per) tdur_dys = (1./ars) * per * (1./np.pi) #this is buggy because T0 is not nessessarily time of first transit #but time of a transit. So fudge. #subtract make T0 the first transit time0 = np.copy(T0) while True: if time0 - per < self.time[0]: break else: time0 = time0 - per ntransits = int((self.time[-1] - self.time[0]) / per) + 1 t_times = np.arange(ntransits)*per + T0 #make sure the first and last transit are not excluded even if #partially in the data t_times = np.r_[t_times,t_times[0] - per,t_times[-1] + per] for j in t_times: maskdat[:,i] = np.logical_or(maskdat[:,i], np.logical_and( self.time < j +tdur_dys*ntdur, self.time > j - tdur_dys*ntdur) ) tregion[i] = ntdur*tdur_dys #create a final mask that is the OR of the #individual masks finmask = np.zeros(self.npt) for i in xrange(self.nplanets): finmask = np.logical_or(finmask,maskdat[:,i]) self.time = self.time[finmask] self.flux = self.flux[finmask] self.err = self.err[finmask] self._itime = self._itime[finmask] self._datatype = self._datatype[finmask] self.tregion = tregion def get_ar(rho,period): """ gets a/R* from period and mean stellar density""" G = 6.67E-11 rho_SI = rho * 1000. tpi = 3. * np.pi period_s = period * 86400. part1 = period_s**2 * G * rho_SI ar = (part1 / tpi)**(1./3.) return ar def logchi2(fitsol,nplanets,rho_0,rho_0_unc,rho_prior, flux,err,fixed_sol,time,itime,ntt,tobs,omc,datatype, onlytransits=False,tregion=0.0): #here are some priors to keep values sensible rho = fitsol[0] if rho < 0.0001 or rho > 100.: return -np.inf rprs = fitsol[np.arange(nplanets)*6 + 5] if np.any(rprs < 0.) or np.any(rprs > 0.5): return -np.inf ecosw = fitsol[np.arange(nplanets)*6 + 6] if np.any(ecosw < -1.0) or np.any(ecosw > 1.0): return -np.inf esinw = fitsol[np.arange(nplanets)*6 + 7] if np.any(esinw < -1.0) or np.any(esinw > 1.0): return -np.inf #avoid parabolic orbits ecc = np.sqrt(esinw**2 + ecosw**2) if np.any(ecc > 1.0): return -np.inf #avoid orbits where the planet enters the star per = fitsol[np.arange(nplanets)*6 + 3] ar = get_ar(rho,per) if np.any(ecc > (1.-(1./ar))): return -np.inf b = fitsol[np.arange(nplanets)*6 + 4] if np.any(b < 0.) or np.any(b > 1.0 + rprs): return -np.inf if onlytransits: T0 = fitsol[np.arange(nplanets)*6 + 2] if np.any(T0 < T0 - tregion) or np.any(T0 > T0 + tregion): return -np.inf model_lc = calc_model(fitsol,nplanets,fixed_sol, time,itime,ntt,tobs,omc,datatype) if rho_prior: chi2prior = (rho_0 - rho)**2 / rho_0_unc**2 else: chi2prior = 0.0 ecc[ecc == 0.0] = 1.E-10 chi2ecc = np.log(1. / ecc) chi2val = np.sum((model_lc - flux)**2 / err**2) chi2const = np.log(1. / (np.sqrt(2.*np.pi) * np.mean(err))) chi2tot = (-chi2val/2.) + chi2prior #include eccentricity in the prior #having np.log(chi2ecc) -> e**(-chi2/2) / ecc logp = chi2tot + np.sum(chi2ecc) return logp def calc_model(fitsol,nplanets,fixed_sol,time,itime,ntt,tobs,omc,datatype): sol = np.zeros([8 + 10*nplanets]) rho = fitsol[0] zpt = fitsol[1] ld1,ld2,ld3,ld4 = fixed_sol[0:4] dil = fixed_sol[4] veloffset = fixed_sol[5] fixed_stuff = fixed_sol[6:10] sol[0:8] = np.array([rho,ld1,ld2,ld3,ld4, dil,veloffset,zpt]) for i in xrange(nplanets): sol[8+(i*10):8+(i*10)+10] = np.r_[fitsol[2+i*6:8+i*6],fixed_stuff] tmodout = tmod.transitmodel(nplanets,sol,time,itime, ntt,tobs,omc,datatype) return tmodout - 1. def logchi2_paramprior(fitsol,nplanets,rho_0,rho_0_unc,rho_prior, teff_0,teff_0_unc,logg_0,logg_0_unc,feh_0,feh_0_unc, flux,err,fixed_sol,time,itime,ntt,tobs,omc,datatype, n_ldparams=2,ldfileloc='/Users/tom/svn_code/tom_code/', onlytransits=False,tregion=0.0): minf = -np.inf #here are some priors to keep values sensible rho = fitsol[0] if rho < 1.E-6 or rho > 100.: return minf teff = fitsol[2] if teff < 3500 or teff > 50000.: return minf logg = fitsol[3] if logg < 0.0 or logg > 5.: return minf feh = fitsol[4] if feh < -5. or feh > 1.: return minf rprs = fitsol[np.arange(nplanets)*6 + 8] if np.any(rprs < 0.) or np.any(rprs > 0.5): return minf ecosw = fitsol[np.arange(nplanets)*6 + 9] if np.any(ecosw < -1.0) or np.any(ecosw > 1.0): return minf esinw = fitsol[np.arange(nplanets)*6 + 10] if np.any(esinw < -1.0) or np.any(esinw > 1.0): return minf #avoid parabolic orbits ecc = np.sqrt(esinw**2 + ecosw**2) if np.any(ecc > 1.0): return minf #avoid orbits where the planet enters the star per = fitsol[np.arange(nplanets)*6 + 6] ar = get_ar(rho,per) if np.any(ecc > (1.-(1./ar))): return minf b = fitsol[np.arange(nplanets)*6 + 7] if np.any(b < 0.) or np.any(b > 1.0 + rprs): return minf if onlytransits: T0 = fitsol[np.arange(nplanets)*6 + 5] if np.any(T0 < T0 - tregion) or np.any(T0 > T0 + tregion): return minf #calc thing limb darkening here if n_ldparams == 2: #if teff < 3500 and logg >= 3.5: if False: #this block should never run ldfile = ldfileloc + 'claret-quad-phoenix.txt' ld1,ld2 = ld_quad(ldfile, teff,logg) ld3 = 0.0 ld4 = 0.0 #elif logg < 3.5 or teff >= 3500: if True: ldfile = ldfileloc + 'claret-limb-quad.txt' ld1,ld2 = claretquad(ldfile, teff,logg,feh) ld3 = 0.0 ld4 = 0.0 elif n_ldparams == 4: ldfile = ldfileloc + 'claret-limb.txt' ld1,ld2,ld3,ld4 = claretlimb4p(ldfile, teff,logg,feh) lds = np.array([ld1,ld2,ld3,ld4]) fitsol_model_calc = np.r_[fitsol[0:2],fitsol[5:]] fixed_sol_model_calc = np.r_[lds,fixed_sol] model_lc = calc_model(fitsol_model_calc,nplanets,fixed_sol_model_calc, time,itime,ntt,tobs,omc,datatype) if rho_prior: rho_prior = (rho_0 - rho)**2 / rho_0_unc**2 #teff_prior = (teff_0 - teff)**2 / teff_0_unc**2 #logg_prior = (logg_0 - logg)**2 / logg_0_unc**2 #feh_prior = (feh_0 - feh)**2 / feh_0_unc**2 #chi2prior = rho_prior+teff_prior+logg_prior+feh_prior else: rho_prior = 0.0 teff_prior = (teff_0 - teff)**2 / teff_0_unc**2 logg_prior = (logg_0 - logg)**2 / logg_0_unc**2 feh_prior = (feh_0 - feh)**2 / feh_0_unc**2 chi2prior = -0.5*(rho_prior+teff_prior+logg_prior+feh_prior) ecc[ecc == 0.0] = 1.E-10 chi2ecc = np.log(1. / ecc) chi2val = -0.5*np.sum(((model_lc - flux)* (model_lc - flux)) / (err*err)) #chi2const = np.log(np.sum(1./(np.sqrt(2.*np.pi)*err))) chi2const = 0.0 chi2tot = chi2const + chi2val + chi2prior #include eccentricity in the prior #having np.log(chi2ecc) -> e**(-chi2/2) / ecc logp = chi2tot + np.sum(chi2ecc) return logp def logchi2_fitldp(fitsol,nplanets,rho_0,rho_0_unc,rho_prior, ld1_0,ld1_0_unc,ld2_0,ld2_0_unc,ldp_prior, flux,err,fixed_sol,time,itime,ntt,tobs,omc,datatype, n_ldparams=2,ldfileloc='/Users/tom/svn_code/tom_code/', onlytransits=False,tregion=0.0): minf = -np.inf #here are some priors to keep values sensible rho = fitsol[0] if rho < 1.E-6 or rho > 100.: return minf ld1 = fitsol[2] ld2 = fitsol[3] #some lind darkening constraints #from Burke et al. 2008 (XO-2b) if ld1 < 0.0: return minf if ld1 + ld2 > 1.0: return minf if ld1 + 2.*ld2 < 0.0: return minf if ld2 < -0.8: return minf if n_ldparams == 2: ld3, ld4 = 0.0,0.0 addval = 0 elif n_ldparams == 4: ld3 = fitsol[4] ld4 = fitsol[5] addval = 2 rprs = fitsol[np.arange(nplanets)*6 + 7 + addval] if np.any(rprs < 0.) or np.any(rprs > 0.5): return minf ecosw = fitsol[np.arange(nplanets)*6 + 8+addval] if np.any(ecosw < -1.0) or np.any(ecosw > 1.0): return minf esinw = fitsol[np.arange(nplanets)*6 + 9+addval] if np.any(esinw < -1.0) or np.any(esinw > 1.0): return minf #avoid parabolic orbits ecc = np.sqrt(esinw**2 + ecosw**2) if np.any(ecc > 1.0): return minf #avoid orbits where the planet enters the star per = fitsol[np.arange(nplanets)*6 + 5+addval] ar = get_ar(rho,per) if np.any(ecc > (1.-(1./ar))): return minf b = fitsol[np.arange(nplanets)*6 + 6+addval] if np.any(b < 0.) or np.any(b > 1.0 + rprs): return minf if onlytransits: T0 = fitsol[np.arange(nplanets)*6 + 4+addval] if np.any(T0 < T0 - tregion) or np.any(T0 > T0 + tregion): return minf jitter = fitsol[-1] if jitter < 0.0: return minf err_jit = np.sqrt(err**2 + jitter**2) err_jit2 = err**2 + jitter**2 lds = np.array([ld1,ld2,ld3,ld4]) fitsol_model_calc = np.r_[fitsol[0:2],fitsol[4:]] fixed_sol_model_calc = np.r_[lds,fixed_sol] model_lc = calc_model(fitsol_model_calc,nplanets,fixed_sol_model_calc, time,itime,ntt,tobs,omc,datatype) # if rho_prior: # rhoprior = (rho_0 - rho)**2 / rho_0_unc**2 # else: # rhoprior = 0.0 # if ldp_prior: # ldprior1 = (ld1_0 - ld1)*(ld1_0 - ld1) / ld1_0_unc**2 # ldprior2 = (ld2_0 - ld2)*(ld2_0 - ld2) / ld2_0_unc**2 # ldprior = ldprior1 + ldprior2 # else: # ldprior = 0.0 # chi2prior = -0.5*(rhoprior+ldprior) ecc[ecc == 0.0] = 1.E-10 #chi2ecc = np.log(1. / ecc) # chi2val = -0.5*np.sum(((model_lc - flux)* (model_lc - flux)) # / (err_jit*err_jit)) # chi2const = -1.0*np.sum(np.log(err_jit)) # #chi2const = 0.0 # chi2tot = chi2const + chi2val + chi2prior # #include eccentricity in the prior # #having np.log(chi2ecc) -> e**(-chi2/2) / ecc # logp = chi2tot + np.sum(chi2ecc) npt_lc = len(err_jit) loglc = ( - (npt_lc/2.)*np.log(2.*np.pi) - 0.5 * np.sum(np.log(err_jit2)) - 0.5 * np.sum((model_lc - flux)**2 / err_jit2) ) if rho_prior: logrho = ( - 0.5 * np.log(2.*np.pi) - 0.5 * np.log(rho_0_unc**2) - 0.5 * (rho_0 - rho)**2 / rho_0_unc**2 ) else: rho_prior = 0.0 if ldp_prior: logld1 = ( - 0.5 * np.log(2.*np.pi) - 0.5 * np.log(ld1_0_unc**2) - 0.5 * (ld1_0 - ld1)**2 / ld1_0_unc**2 ) logld2 = ( - 0.5 * np.log(2.*np.pi) - 0.5 * np.log(ld2_0_unc**2) - 0.5 * (ld2_0 - ld2)**2 / ld2_0_unc**2 ) logldp = logld1 + logld2 else: logldp = 0.0 logecc = - np.sum(np.log(ecc)) logLtot = loglc + logrho + logldp + logecc return logLtot # def calc_model_paramprior(fitsol,nplanets,fixed_sol,time,itime,ntt,tobs,omc,datatype): # sol = np.zeros([8 + 10*nplanets]) # rho = fitsol[0] # zpt = fitsol[1] # ld1,ld2,ld3,ld4 = fixed_sol[0:4] # dil = fixed_sol[4] # veloffset = fixed_sol[5] # fixed_stuff = fixed_sol[6:10] # sol[0:8] = np.array([rho,ld1,ld2,ld3,ld4, # dil,veloffset,zpt]) # for i in xrange(nplanets): # sol[8+(i*10):8+(i*10)+10] = np.r_[fitsol[2+i*6:8+i*6],fixed_stuff] # tmodout = tmod.transitmodel(nplanets,sol,time,itime, # ntt,tobs,omc,datatype) # return tmodout - 1. def get_stats(par_arr,noprint=False): par_arr onesig = (1. - 0.682689492) / 2. twosig = (1. - 0.954499736) / 2. threesig = (1. - 0.997300204) / 2. med = np.median(par_arr) stdev = np.std(par_arr) sort_arr = np.sort(par_arr) nval = len(par_arr) m1 = med - sort_arr[np.floor(onesig * nval)] p1 = sort_arr[np.floor(nval - (onesig * nval))] - med m2 = med - sort_arr[np.floor(twosig * nval)] p2 = sort_arr[np.floor(nval - (twosig * nval))] - med m3 = med - sort_arr[np.floor(threesig * nval)] p3 = sort_arr[np.floor(nval - (threesig * nval))] - med ninefivelow = sort_arr[np.floor(0.025*nval)] ninefivehigh = sort_arr[np.floor(0.975*nval)] if not noprint: print '95percent credible interval = %s - %s' %(ninefivelow,ninefivehigh) return np.array([med,stdev,p1,m1,p2,m2,p3,m3]) def model_real_paramprior(rho,zpt,teff,logg,feh,T0, per,b,rprs,ecosw,esinw, time,itime,ntt,tobs,omc,datatype, n_ldparams=2, ldfileloc='/Users/tom/svn_code/tom_code/'): ldfile = ldfileloc + 'claret-limb-quad.txt' ld1,ld2 = claretquad(ldfile,teff,logg,feh) ld3 = 0.0 ld4 = 0.0 dil=0.0 veloffset = 0.0 rvamp = 0.0 occ = 0.0 ell = 0.0 alb = 0.0 nplanets = 1 sol = np.array([rho,ld1,ld2,ld3,ld4, dil,veloffset,zpt,T0,per,b,rprs,ecosw,esinw, rvamp,occ,ell,alb]) tmodout = tmod.transitmodel(nplanets,sol,time,itime, ntt,tobs,omc,datatype) - 1.0 return tmodout def testtom(t,num): rho,zpt,teff,logg,feh,T0,per,b,rprs,ecosw,esinw = (t[...,num]) mod = model_real_paramprior(rho,zpt,teff,logg,feh,T0,per,b,rprs,ecosw, esinw,M.time,M._itime,M._ntt,M._tobs,M._omc,M._datatype, n_ldparams=2,ldfileloc='/Users/tom/svn_code/tom_code/') q,f = get_qf(M.time,a,per,T0) plt.plot(q,f,alpha=0.5) def run_crap(t): for num in random.choice(np.arange(len(t[1])),size=10): testtom(t,num) q,f = get_qf(M.time,M.flux,per,T0) plt.scatter(q,f,s=1,color='k',alpha=0.2) def get_qf(time,flux,period,epoch): date1 = (time - epoch) + 0.5*period phi1 = (((date1 / period) - np.floor(date1/period)) * 24. * period) - 12*period q1 = np.sort(phi1) f1 = (flux[np.argsort(phi1)]) * 1.E6 return q1, f1
31.919075
88
0.524267
6,194
44,176
3.629642
0.070552
0.008451
0.015123
0.021484
0.797305
0.763411
0.740059
0.729206
0.707143
0.692599
0
0.060029
0.349126
44,176
1,383
89
31.942155
0.721873
0.127015
0
0.64123
0
0
0.019903
0.00883
0
0
0
0
0.003417
0
null
null
0.001139
0.01139
null
null
0.006834
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
1
0
0
0
0
0
0
0
0
6
781ab1b68d7175d472282dd2c34637ddada37ab7
23,855
py
Python
tests/test_outputs_handler_matsim_xml_writer.py
arup-group/genet
24bfbee31da6d7951598adb29ddf17d3a08ed5e6
[ "MIT" ]
22
2020-12-22T11:11:44.000Z
2022-03-07T16:25:35.000Z
tests/test_outputs_handler_matsim_xml_writer.py
tkahng/genet
d5c29ed9e44408b60f55d8de889d7430debc9f04
[ "MIT" ]
27
2020-12-22T09:45:35.000Z
2022-03-03T14:52:24.000Z
tests/test_outputs_handler_matsim_xml_writer.py
tkahng/genet
d5c29ed9e44408b60f55d8de889d7430debc9f04
[ "MIT" ]
7
2021-01-02T10:00:05.000Z
2022-01-06T03:53:43.000Z
import os, sys import pytest import lxml from copy import deepcopy from shapely.geometry import LineString from tests.fixtures import network_object_from_test_data, full_fat_default_config_path, assert_semantically_equal from tests import xml_diff from genet.outputs_handler import matsim_xml_writer from genet.core import Network from genet.schedule_elements import read_vehicle_types from genet.inputs_handler import read import xml.etree.cElementTree as ET sys.path.insert(0, os.path.abspath(os.path.join(os.path.dirname(__file__), ".."))) pt2matsim_network_test_file = os.path.abspath( os.path.join(os.path.dirname(__file__), "test_data", "matsim", "network.xml")) pt2matsim_schedule_file = os.path.abspath( os.path.join(os.path.dirname(__file__), "test_data", "matsim", "schedule.xml")) pt2matsim_vehicles_file = os.path.abspath( os.path.join(os.path.dirname(__file__), "test_data", "matsim", "vehicles.xml")) @pytest.fixture def network_dtd(): dtd_path = os.path.abspath(os.path.join(os.path.dirname(__file__), "test_data", "dtd", "matsim", "network_v2.dtd")) yield lxml.etree.DTD(dtd_path) @pytest.fixture def schedule_dtd(): dtd_path = os.path.abspath(os.path.join(os.path.dirname(__file__), "test_data", "dtd", "matsim", "transitSchedule_v2.dtd")) yield lxml.etree.DTD(dtd_path) @pytest.fixture def vehicles_xsd(): xsd_path = os.path.abspath(os.path.join(os.path.dirname(__file__), "test_data", "dtd", "matsim", "vehicleDefinitions_v1.0.xsd")) xml_schema_doc = lxml.etree.parse(xsd_path) yield lxml.etree.XMLSchema(xml_schema_doc) @pytest.fixture def vehicle_types(): vehicle_types_config = os.path.abspath(os.path.join(os.path.dirname(__file__), '..', 'genet', "configs", "vehicles", "vehicle_definitions.yml")) return read_vehicle_types(vehicle_types_config) def test_generates_valid_matsim_network_xml_file(network_object_from_test_data, network_dtd, tmpdir): matsim_xml_writer.write_matsim_network(tmpdir, network_object_from_test_data) generated_network_file_path = os.path.join(tmpdir, 'network.xml') xml_obj = lxml.etree.parse(generated_network_file_path) assert network_dtd.validate(xml_obj), \ 'Doc generated at {} is not valid against DTD due to {}'.format(generated_network_file_path, network_dtd.error_log.filter_from_errors()) def test_network_from_test_osm_data_produces_valid_matsim_network_xml_file(full_fat_default_config_path, network_dtd, tmpdir): osm_test_file = os.path.abspath( os.path.join(os.path.dirname(__file__), "test_data", "osm", "osm.xml")) network = read.read_osm(osm_test_file, full_fat_default_config_path, 1, 'epsg:27700') network.write_to_matsim(tmpdir) generated_network_file_path = os.path.join(tmpdir, 'network.xml') xml_obj = lxml.etree.parse(generated_network_file_path) assert network_dtd.validate(xml_obj), \ 'Doc generated at {} is not valid against DTD due to {}'.format(generated_network_file_path, network_dtd.error_log.filter_from_errors()) def test_network_with_extra_attribs_produces_valid_matsim_network_xml_file(tmpdir, network_dtd): network = Network('epsg:27700') network.add_node('0', attribs={'id': '0', 'x': 1, 'y': 2, 'lat': 1, 'lon': 2}) network.add_node('1', attribs={'id': '1', 'x': 2, 'y': 2, 'lat': 2, 'lon': 2}) network.add_link('0', '0', '1', attribs={'id': '0', 'from': '0', 'to': '1', 'length': 1, 'freespeed': 1, 'capacity': 20, 'permlanes': 1, 'oneway': '1', 'modes': ['car'], 'extra_Special_attrib': 12}) network.write_to_matsim(tmpdir) generated_network_file_path = os.path.join(tmpdir, 'network.xml') xml_obj = lxml.etree.parse(generated_network_file_path) assert network_dtd.validate(xml_obj), \ 'Doc generated at {} is not valid against DTD due to {}'.format(generated_network_file_path, network_dtd.error_log.filter_from_errors()) _network_from_file = read.read_matsim(path_to_network=generated_network_file_path, epsg='epsg:27700') assert_semantically_equal(dict(_network_from_file.nodes()), { '0': {'id': '0', 'x': 1.0, 'y': 2.0, 'lon': -7.557148039524952, 'lat': 49.766825803756994, 's2_id': 5205973754090365183}, '1': {'id': '1', 'x': 2.0, 'y': 2.0, 'lon': -7.557134218911724, 'lat': 49.766826468710484, 's2_id': 5205973754090480551}}) assert_semantically_equal(dict(_network_from_file.links()), { '0': {'id': '0', 'from': '0', 'to': '1', 'freespeed': 1.0, 'capacity': 20.0, 'permlanes': 1.0, 'oneway': '1', 'modes': {'car'}, 's2_from': 5205973754090365183, 's2_to': 5205973754090480551, 'length': 1.0}}) def test_tolerates_networks_with_no_oneway_flag_on_links(tmpdir, network_dtd): network = Network('epsg:27700') network.add_node('0', attribs={'id': '0', 'x': 1, 'y': 2, 'lat': 1, 'lon': 2}) network.add_node('1', attribs={'id': '1', 'x': 2, 'y': 2, 'lat': 2, 'lon': 2}) network.add_link('0', '0', '1', attribs={ 'id': '0', 'from': '0', 'to': '1', 'length': 1, 'freespeed': 1, 'capacity': 20, 'permlanes': 1, 'modes': ['car'] }) network.write_to_matsim(tmpdir) generated_network_file_path = os.path.join(tmpdir, 'network.xml') xml_obj = lxml.etree.parse(generated_network_file_path) assert network_dtd.validate(xml_obj), \ 'Doc generated at {} is not valid against DTD due to {}'.format(generated_network_file_path, network_dtd.error_log.filter_from_errors()) _network_from_file = read.read_matsim(path_to_network=generated_network_file_path, epsg='epsg:27700') assert_semantically_equal(dict(_network_from_file.nodes()), { '0': {'id': '0', 'x': 1.0, 'y': 2.0, 'lon': -7.557148039524952, 'lat': 49.766825803756994, 's2_id': 5205973754090365183}, '1': {'id': '1', 'x': 2.0, 'y': 2.0, 'lon': -7.557134218911724, 'lat': 49.766826468710484, 's2_id': 5205973754090480551}}) assert_semantically_equal(dict(_network_from_file.links()), { '0': { 'id': '0', 'from': '0', 'to': '1', 'freespeed': 1.0, 'capacity': 20.0, 'permlanes': 1.0, 'modes': {'car'}, 's2_from': 5205973754090365183, 's2_to': 5205973754090480551, 'length': 1.0 } }) def test_network_with_attribs_doesnt_loose_any_attributes_after_saving(tmpdir): network = Network('epsg:27700') network.add_node('0', attribs={'id': '0', 'x': 1, 'y': 2, 'lat': 1, 'lon': 2}) network.add_node('1', attribs={'id': '1', 'x': 2, 'y': 2, 'lat': 2, 'lon': 2}) network.add_link('0', '0', '1', attribs={'id': '0', 'from': '0', 'to': '1', 'length': 1, 'freespeed': 1, 'capacity': 20, 'permlanes': 1, 'oneway': '1', 'modes': ['car'], 'extra_Special_attrib': 12}) network.add_link('0', '0', '1', attribs={'id': '0', 'from': '0', 'to': '1', 'length': 1, 'freespeed': 1, 'capacity': 20, 'permlanes': 1, 'oneway': '1', 'modes': ['car'], 'attributes': { 'osm:way:lanes': {'name': 'osm:way:lanes', 'class': 'java.lang.String', 'text': '3'}}}) link_attributes = deepcopy(dict(network.links())) node_attributes = deepcopy(dict(network.nodes())) network.write_to_matsim(tmpdir) link_attributes_post_save = dict(network.links()) node_attributes_post_save = dict(network.nodes()) assert_semantically_equal(link_attributes_post_save, link_attributes) assert_semantically_equal(node_attributes_post_save, node_attributes) def test_saving_network_with_geometry_doesnt_change_data_on_the_network(tmpdir): network = Network('epsg:27700') network.add_node('0', attribs={'id': '0', 'x': 1, 'y': 2, 'lat': 1, 'lon': 2}) network.add_node('1', attribs={'id': '1', 'x': 2, 'y': 2, 'lat': 2, 'lon': 2}) network.add_link('0', '0', '1', attribs={'id': '0', 'from': '0', 'to': '1', 'length': 1, 'freespeed': 1, 'capacity': 20, 'permlanes': 1, 'oneway': '1', 'modes': ['car'], 'geometry': LineString([(1,2), (2,3), (3,4)]), 'extra_Special_attrib': 12}) network.add_link('0', '0', '1', attribs={'id': '0', 'from': '0', 'to': '1', 'length': 1, 'freespeed': 1, 'capacity': 20, 'permlanes': 1, 'oneway': '1', 'modes': ['car'], 'geometry': LineString([(1,2), (2,3), (3,4)]), 'attributes': { 'osm:way:lanes': {'name': 'osm:way:lanes', 'class': 'java.lang.String', 'text': '3'}}}) link_attributes = deepcopy(dict(network.links())) node_attributes = deepcopy(dict(network.nodes())) network.write_to_matsim(tmpdir) link_attributes_post_save = dict(network.links()) node_attributes_post_save = dict(network.nodes()) assert_semantically_equal(link_attributes_post_save, link_attributes) assert_semantically_equal(node_attributes_post_save, node_attributes) def test_saving_network_with_geometry_produces_correct_polyline_in_link_attributes(tmpdir): network = Network('epsg:27700') network.add_node('0', attribs={'id': '0', 'x': 1, 'y': 2, 'lat': 1, 'lon': 2}) network.add_node('1', attribs={'id': '1', 'x': 2, 'y': 2, 'lat': 2, 'lon': 2}) network.add_link('0', '0', '1', attribs={'id': '0', 'from': '0', 'to': '1', 'length': 1, 'freespeed': 1, 'capacity': 20, 'permlanes': 1, 'oneway': '1', 'modes': ['car'], 'geometry': LineString([(1,2), (2,3), (3,4)]), 'extra_Special_attrib': 12}) network.write_to_matsim(tmpdir) found_geometry_attrib = False for event, elem in ET.iterparse(os.path.join(tmpdir, 'network.xml'), events=('start', 'end')): if event == 'start': if elem.tag == 'attribute': if elem.attrib['name'] == 'geometry': assert elem.text == '_ibE_seK_ibE_ibE_ibE_ibE' found_geometry_attrib = True assert found_geometry_attrib def test_saving_network_with_wrongly_formatted_attributes_with_geometry(tmpdir): # attributes are assumed to be a nested dictionary of very specific format. Due to the fact that user can # do virtually anything to edge attributes, or due to calculation error, this may not be the case. If it's not # of correct format, we don't expect it to get saved to the matsim network.xml network = Network('epsg:27700') network.add_node('0', attribs={'id': '0', 'x': 1, 'y': 2, 'lat': 1, 'lon': 2}) network.add_node('1', attribs={'id': '1', 'x': 2, 'y': 2, 'lat': 2, 'lon': 2}) link_attribs = {'id': '0', 'from': '0', 'to': '1', 'length': 1, 'freespeed': 1, 'capacity': 20, 'permlanes': 1, 'oneway': '1', 'modes': ['car'], 'geometry': LineString([(1,2), (2,3), (3,4)]), 'attributes': {'heyo': 'whoop'} } network.add_link('0', '0', '1', attribs=link_attribs) network.write_to_matsim(tmpdir) assert_semantically_equal(dict(network.links()), {'0': link_attribs}) assert_semantically_equal(matsim_xml_writer.check_link_attributes(link_attribs), {'id': '0', 'from': '0', 'to': '1', 'length': 1, 'freespeed': 1, 'capacity': 20, 'permlanes': 1, 'oneway': '1', 'modes': ['car'], 'geometry': LineString([(1, 2), (2, 3), (3, 4)]) } ) found_geometry_attrib = False for event, elem in ET.iterparse(os.path.join(tmpdir, 'network.xml'), events=('start', 'end')): if event == 'start': if elem.tag == 'attribute': if elem.attrib['name'] == 'geometry': assert elem.text == '_ibE_seK_ibE_ibE_ibE_ibE' found_geometry_attrib = True assert found_geometry_attrib def test_saving_network_with_bonkers_attributes_with_geometry(tmpdir): # attributes are assumed to be a nested dictionary of very specific format. Due to the fact that user can # do virtually anything to edge attributes, or due to calculation error, this may not be the case. If it's not # of correct format, we don't expect it to get saved to the matsim network.xml network = Network('epsg:27700') network.add_node('0', attribs={'id': '0', 'x': 1, 'y': 2, 'lat': 1, 'lon': 2}) network.add_node('1', attribs={'id': '1', 'x': 2, 'y': 2, 'lat': 2, 'lon': 2}) link_attribs = {'id': '0', 'from': '0', 'to': '1', 'length': 1, 'freespeed': 1, 'capacity': 20, 'permlanes': 1, 'oneway': '1', 'modes': ['car'], 'geometry': LineString([(1,2), (2,3), (3,4)]), 'attributes': float('nan') } network.add_link('0', '0', '1', attribs=link_attribs) network.write_to_matsim(tmpdir) assert_semantically_equal(dict(network.links()), {'0': link_attribs}) assert_semantically_equal(matsim_xml_writer.check_link_attributes(link_attribs), {'id': '0', 'from': '0', 'to': '1', 'length': 1, 'freespeed': 1, 'capacity': 20, 'permlanes': 1, 'oneway': '1', 'modes': ['car'], 'geometry': LineString([(1, 2), (2, 3), (3, 4)]) } ) found_geometry_attrib = False for event, elem in ET.iterparse(os.path.join(tmpdir, 'network.xml'), events=('start', 'end')): if event == 'start': if elem.tag == 'attribute': if elem.attrib['name'] == 'geometry': assert elem.text == '_ibE_seK_ibE_ibE_ibE_ibE' found_geometry_attrib = True assert found_geometry_attrib def test_saving_network_with_correct_attributes_and_geometry(tmpdir): # attributes are assumed to be a nested dictionary of very specific format. Due to the fact that user can # do virtually anything to edge attributes, or due to calculation error, this may not be the case. If it's not # of correct format, we don't expect it to get saved to the matsim network.xml network = Network('epsg:27700') network.add_node('0', attribs={'id': '0', 'x': 1, 'y': 2, 'lat': 1, 'lon': 2}) network.add_node('1', attribs={'id': '1', 'x': 2, 'y': 2, 'lat': 2, 'lon': 2}) link_attribs = {'id': '0', 'from': '0', 'to': '1', 'length': 1, 'freespeed': 1, 'capacity': 20, 'permlanes': 1, 'oneway': '1', 'modes': ['car'], 'geometry': LineString([(1,2), (2,3), (3,4)]), 'attributes': { 'osm:way:lanes': {'name': 'osm:way:lanes', 'class': 'java.lang.String', 'text': '3'} } } network.add_link('0', '0', '1', attribs=link_attribs) network.write_to_matsim(tmpdir) assert_semantically_equal(dict(network.links()), {'0': link_attribs}) assert_semantically_equal(matsim_xml_writer.check_link_attributes(link_attribs), link_attribs) found_geometry_attrib = False for event, elem in ET.iterparse(os.path.join(tmpdir, 'network.xml'), events=('start', 'end')): if event == 'start': if elem.tag == 'attribute': if elem.attrib['name'] == 'geometry': assert elem.text == '_ibE_seK_ibE_ibE_ibE_ibE' found_geometry_attrib = True assert found_geometry_attrib def test_saving_network_with_geometry_produces_polyline_if_link_already_has_other_attributes(tmpdir): network = Network('epsg:27700') network.add_node('0', attribs={'id': '0', 'x': 1, 'y': 2, 'lat': 1, 'lon': 2}) network.add_node('1', attribs={'id': '1', 'x': 2, 'y': 2, 'lat': 2, 'lon': 2}) network.add_link('0', '0', '1', attribs={'id': '0', 'from': '0', 'to': '1', 'length': 1, 'freespeed': 1, 'capacity': 20, 'permlanes': 1, 'oneway': '1', 'modes': ['car'], 'geometry': LineString([(1,2), (2,3), (3,4)]), 'attributes': { 'osm:way:lanes': {'name': 'osm:way:lanes', 'class': 'java.lang.String', 'text': '3'}}}) network.write_to_matsim(tmpdir) found_geometry_attrib = False for event, elem in ET.iterparse(os.path.join(tmpdir, 'network.xml'), events=('start', 'end')): if event == 'start': if elem.tag == 'attribute': if elem.attrib['name'] == 'geometry': assert elem.text == '_ibE_seK_ibE_ibE_ibE_ibE' found_geometry_attrib = True assert found_geometry_attrib def test_write_matsim_network_produces_semantically_equal_xml_to_input_matsim_xml(network_object_from_test_data, tmpdir): matsim_xml_writer.write_matsim_network(tmpdir, network_object_from_test_data) xml_diff.assert_semantically_equal(os.path.join(tmpdir, 'network.xml'), pt2matsim_network_test_file) def test_generates_valid_matsim_schedule_xml_file(network_object_from_test_data, schedule_dtd, tmpdir): matsim_xml_writer.write_matsim_schedule(tmpdir, network_object_from_test_data.schedule) generated_file_path = os.path.join(tmpdir, 'schedule.xml') xml_obj = lxml.etree.parse(generated_file_path) assert schedule_dtd.validate(xml_obj), \ 'Doc generated at {} is not valid against DTD due to {} errors - first error {}' \ .format(generated_file_path, len(schedule_dtd.error_log.filter_from_errors()), schedule_dtd.error_log.filter_from_errors()[0]) def test_write_matsim_schedule_produces_semantically_equal_xml_to_input_matsim_xml(network_object_from_test_data, tmpdir): matsim_xml_writer.write_matsim_schedule(tmpdir, network_object_from_test_data.schedule) xml_diff.assert_semantically_equal(os.path.join(tmpdir, 'schedule.xml'), pt2matsim_schedule_file) def test_write_matsim_schedule_produces_semantically_equal_xml_to_input_matsim_xml_if_stops_need_to_reprojected( network_object_from_test_data, tmpdir): # we change all the stops in the one service and one route that exists in the test data network_object_from_test_data.schedule.route('VJbd8660f05fe6f744e58a66ae12bd66acbca88b98').reproject('epsg:3035') matsim_xml_writer.write_matsim_schedule(tmpdir, network_object_from_test_data.schedule) xml_diff.assert_semantically_equal(os.path.join(tmpdir, 'schedule.xml'), pt2matsim_schedule_file) def test_generates_valid_matsim_vehicles_xml_file(tmpdir, vehicles_xsd, vehicle_types): vehicle_dict = { 'veh_1': {'type': 'bus'}, 'veh_2': {'type': 'bus'}, 'veh_3': {'type': 'bus'}, 'veh_4': {'type': 'tram'}, 'veh_5': {'type': 'rail'}, 'veh_6': {'type': 'subway'} } matsim_xml_writer.write_vehicles(tmpdir, vehicle_dict, vehicle_types) generated_file_path = os.path.join(tmpdir, 'vehicles.xml') xml_obj = lxml.etree.parse(generated_file_path) vehicles_xsd.assertValid(xml_obj) def test_generates_matsim_vehicles_xml_file_containing_expected_vehicle_types(tmpdir, vehicle_types): vehicle_dict = { 'veh_1': {'type': 'bus'}, 'veh_2': {'type': 'bus'}, 'veh_3': {'type': 'bus'}, 'veh_4': {'type': 'tram'}, 'veh_5': {'type': 'rail'}, 'veh_6': {'type': 'subway'} } matsim_xml_writer.write_vehicles(tmpdir, vehicle_dict, vehicle_types) generated_file_path = os.path.join(tmpdir, 'vehicles.xml') xml_obj = lxml.etree.parse(generated_file_path) vehicle_types = xml_obj.findall('{http://www.matsim.org/files/dtd}vehicleType') expected_vehicle_types = {v['type'] for k,v in vehicle_dict.items()} actual_vehicle_types = set() for vehicle_type in vehicle_types: actual_vehicle_types.add(vehicle_type.get('id')) assert expected_vehicle_types == actual_vehicle_types def test_generates_matsim_vehicles_xml_file_containing_expected_vehicles(tmpdir, vehicle_types): vehicle_dict = { 'veh_1': {'type': 'bus'}, 'veh_2': {'type': 'bus'}, 'veh_3': {'type': 'bus'}, 'veh_4': {'type': 'tram'}, 'veh_5': {'type': 'rail'}, 'veh_6': {'type': 'subway'} } matsim_xml_writer.write_vehicles(tmpdir, vehicle_dict, vehicle_types) generated_file_path = os.path.join(tmpdir, 'vehicles.xml') xml_obj = lxml.etree.parse(generated_file_path) vehicles = xml_obj.findall('{http://www.matsim.org/files/dtd}vehicle') assert len(vehicles) == len(vehicle_dict) for vehicle in vehicles: assert vehicle_dict[vehicle.get('id')]['type'] == vehicle.get('type') def test_throws_exception_when_generating_vehicles_xml_from_unrecognised_vehicle_types(tmpdir, vehicle_types): vehicle_dict = { 'veh_1': {'type': 'bus'}, 'veh_4': {'type': 'tram'}, 'veh_5': {'type': 'rocket ship'}, } with pytest.raises(NotImplementedError) as e: matsim_xml_writer.write_vehicles(tmpdir, vehicle_dict, vehicle_types) assert 'No Vehicle Type info available for mode rocket ship' in str(e.value) def test_write_matsim_vehicles_produces_semantically_equal_xml_to_input_matsim_xml(network_object_from_test_data, tmpdir): network = network_object_from_test_data matsim_xml_writer.write_matsim_schedule(tmpdir, network.schedule) matsim_xml_writer.write_vehicles(tmpdir, network.schedule.vehicles, network.schedule.vehicle_types) xml_diff.assert_semantically_equal(os.path.join(tmpdir, 'vehicles.xml'), pt2matsim_vehicles_file)
51.634199
117
0.57686
2,892
23,855
4.48029
0.090595
0.020375
0.020066
0.020993
0.856062
0.838466
0.815003
0.799799
0.796172
0.770472
0
0.045749
0.276127
23,855
461
118
51.746204
0.704598
0.040034
0
0.671309
0
0
0.143693
0.010223
0
0
0
0
0.108635
1
0.066852
false
0
0.033426
0
0.103064
0
0
0
0
null
0
0
0
1
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
6
7832eca570081a73826d0d22a031b56d9580e22d
96
py
Python
venv/lib/python3.8/site-packages/poetry/console/commands/command.py
Retraces/UkraineBot
3d5d7f8aaa58fa0cb8b98733b8808e5dfbdb8b71
[ "MIT" ]
2
2022-03-13T01:58:52.000Z
2022-03-31T06:07:54.000Z
venv/lib/python3.8/site-packages/poetry/console/commands/command.py
DesmoSearch/Desmobot
b70b45df3485351f471080deb5c785c4bc5c4beb
[ "MIT" ]
19
2021-11-20T04:09:18.000Z
2022-03-23T15:05:55.000Z
venv/lib/python3.8/site-packages/poetry/console/commands/command.py
DesmoSearch/Desmobot
b70b45df3485351f471080deb5c785c4bc5c4beb
[ "MIT" ]
null
null
null
/home/runner/.cache/pip/pool/56/84/72/17e2777b4dde572c90f35acc44886554c20a643ee1fa9fd8f6eed92f51
96
96
0.895833
9
96
9.555556
1
0
0
0
0
0
0
0
0
0
0
0.427083
0
96
1
96
96
0.46875
0
0
0
0
0
0
0
0
1
0
0
0
0
null
null
0
0
null
null
0
1
0
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
1
0
0
0
1
0
0
0
0
0
0
0
0
6
785960acbbf4bbe39ad3a68b7bb79d5725079424
33
py
Python
src/ltkit/panel/client/__init__.py
ptr-yudai/ltkit
a0f82712c7391a2ed2d06d2a80be982256cae5fa
[ "MIT" ]
1
2016-05-05T17:05:54.000Z
2016-05-05T17:05:54.000Z
src/ltkit/panel/server/__init__.py
ptr-yudai/ltkit
a0f82712c7391a2ed2d06d2a80be982256cae5fa
[ "MIT" ]
1
2016-05-05T17:31:35.000Z
2016-05-06T08:37:32.000Z
src/ltkit/panel/server/__init__.py
ptr-yudai/ltkit
a0f82712c7391a2ed2d06d2a80be982256cae5fa
[ "MIT" ]
null
null
null
import post import questionnaire
11
20
0.878788
4
33
7.25
0.75
0
0
0
0
0
0
0
0
0
0
0
0.121212
33
2
21
16.5
1
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
1
0
0
6
78afcbe24d632ccfd031ae7b5af3bf52effecd49
85,344
py
Python
peoples_advisor/api/oanda/oanda_api.py
Wumphlett/Peoples-Advisor
a965a7547a546a48656832975bbb45c0c6e44f78
[ "MIT" ]
null
null
null
peoples_advisor/api/oanda/oanda_api.py
Wumphlett/Peoples-Advisor
a965a7547a546a48656832975bbb45c0c6e44f78
[ "MIT" ]
null
null
null
peoples_advisor/api/oanda/oanda_api.py
Wumphlett/Peoples-Advisor
a965a7547a546a48656832975bbb45c0c6e44f78
[ "MIT" ]
null
null
null
import abc import json from datetime import datetime from typing import List, Optional, Union import requests api_version = "v3" practice_url = "https://api-fxpractice.oanda.com" live_url = "https://api-fxtrade.oanda.com" practice_stream_url = "https://stream-fxpractice.oanda.com" live_stream_url = "https://stream-fxtrade.oanda.com" def _conditional_update(store_dict, condition, key, value): if condition is not None and (condition is not bool or condition): store_dict.update({key: value}) class OandaError(Exception): def __init__(self, message="Null Message"): super().__init__(message) class ClientExtensions: """ Define client extensions for a given operation (DO NOT INTERACT WITH IF YOUR ACCOUNT IS ASSOCIATED WITH MT4) """ def __init__(self, client_id: str, client_tag: str, client_comment: str): """ Create client extensions Args: client_id (str): A client specified id string client_tag (str): A client specified tag string client_comment (str): A client specified comment """ self.id = client_id self.tag = client_tag self.comment = client_comment def as_dict(self): return {"id": self.id, "tag": self.tag, "comment": self.comment} class TakeProfitDetails: """ Define the details of a take profit order to be created """ def __init__( self, price: float, time_in_force: Optional[str] = "GTC", gtd_time: Optional[str] = None, client_extensions: Optional[ClientExtensions] = None, ): """ Create take profit details Args: price (float): The price that the take profit order will be triggered at see PriceValue in oanda_guide.txt time_in_force (str, optional): The time in force for the created take profit order NOTE: May only be 'GTC', 'GTD', or 'GFD' see TimeInForce in oanda_guide.txt gtd_time (str, optional): The date the take profit order will be canceled on if time_in_force is 'GTD' see DateTime in oanda_guide.txt client_extensions (ClientExtensions, optional): The client extensions to add to the take profit order """ self.price = price self.time_in_force = time_in_force self.gtd_time = gtd_time self.client_extensions = client_extensions.as_dict() if client_extensions is not None else None def as_dict(self): tpd_dict = {"price": str(self.price), "timeInForce": self.time_in_force} if self.time_in_force == "GTD" and self.gtd_time is None: raise OandaError("Invalid GTD time provided. If time_in_force is GTD, you must specify a proper GTD time") _conditional_update(tpd_dict, self.time_in_force == "GTD", "gtdTime", self.gtd_time) tpd_dict.update(self.client_extensions if self.client_extensions else {}) return tpd_dict class StopLossDetails: """ Define the details of a stop loss order to be created """ def __init__( self, price: float = None, distance: float = None, time_in_force: Optional[str] = "GTC", gtd_time: Optional[str] = None, client_extensions: Optional[ClientExtensions] = None, ): """ Create stop loss details Args: price (float): The price that the take profit order will be triggered at NOTE: Only price or distance may be specified see PriceValue in oanda_guide.txt distance (float): The distance (in price units) from the trade's open price to use as the stop loss order price NOTE: Only price or distance may be specified time_in_force (str, optional): The time in force for the created take profit order NOTE: May only be 'GTC', 'GTD', or 'GFD' see TimeInForce in oanda_guide.txt gtd_time (str, optional): The date the take profit order will be canceled on if time_in_force is 'GTD' see DateTime in oanda_guide.txt client_extensions (ClientExtensions, optional): The client extensions to add to the take profit order """ if (price is None and distance is None) or (price and distance): raise OandaError("Only price or distance may be specified") self.price = price self.distance = distance self.time_in_force = time_in_force self.gtd_time = gtd_time self.client_extensions = client_extensions.as_dict() if client_extensions is not None else None def as_dict(self): sl_dict = {"timeInForce": self.time_in_force} sl_dict.update({"price": str(self.price)} if self.price else {}) sl_dict.update({"distance": str(self.distance)} if self.distance else {}) if self.time_in_force == "GTD" and self.gtd_time is None: raise OandaError("Invalid GTD time provided. If time_in_force is GTD, you must specify a proper GTD time") _conditional_update(sl_dict, self.time_in_force == "GTD", "gtdTime", self.gtd_time) sl_dict.update(self.client_extensions if self.client_extensions else {}) return sl_dict class GuaranteedStopLossDetails: """ Define the details of a guaranteed stop loss order to be created """ def __init__( self, price: float = None, distance: float = None, time_in_force: Optional[str] = "GTC", gtd_time: Optional[str] = None, client_extensions: Optional[ClientExtensions] = None, ): """ Create stop loss details Args: price (float): The price that the take profit order will be triggered at NOTE: Only price or distance may be specified see PriceValue in oanda_guide.txt distance (float): The distance (in price units) from the trade's open price to use as the stop loss order price NOTE: Only price or distance may be specified time_in_force (str, optional): The time in force for the created take profit order NOTE: May only be 'GTC', 'GTD', or 'GFD' see TimeInForce in oanda_guide.txt gtd_time (str, optional): The date the take profit order will be canceled on if time_in_force is 'GTD' see DateTime in oanda_guide.txt client_extensions (ClientExtensions, optional): The client extensions to add to the take profit order """ if (price is None and distance is None) or (price and distance): raise OandaError("Only price or distance may be specified") self.price = price self.distance = distance self.time_in_force = time_in_force self.gtd_time = gtd_time self.client_extensions = client_extensions.as_dict() if client_extensions is not None else None def as_dict(self): gsl_dict = {"timeInForce": self.time_in_force} gsl_dict.update({"price": str(self.price)} if self.price else {}) gsl_dict.update({"distance": str(self.distance)} if self.distance else {}) if self.time_in_force == "GTD" and self.gtd_time is None: raise OandaError("Invalid GTD time provided. If time_in_force is GTD, you must specify a proper GTD time") _conditional_update(gsl_dict, self.time_in_force == "GTD", "gtdTime", self.gtd_time) gsl_dict.update(self.client_extensions if self.client_extensions else {}) return gsl_dict class TrailingStopLossDetails: """ Define the details of a stop loss order to be created """ def __init__( self, distance: float = None, time_in_force: Optional[str] = "GTC", gtd_time: Optional[str] = None, client_extensions: Optional[ClientExtensions] = None, ): """ Create stop loss details Args: distance (float): The distance (in price units) from the trade's open price to use as the stop loss order price time_in_force (str, optional): The time in force for the created take profit order NOTE: May only be 'GTC', 'GTD', or 'GFD' see TimeInForce in oanda_guide.txt gtd_time (str, optional): The date the take profit order will be canceled on if time_in_force is 'GTD' see DateTime in oanda_guide.txt client_extensions (ClientExtensions, optional): The client extensions to add to the take profit order """ self.distance = distance self.time_in_force = time_in_force self.gtd_time = gtd_time self.client_extensions = client_extensions.as_dict() if client_extensions is not None else None def as_dict(self): tsl_dict = {"timeInForce": self.time_in_force} tsl_dict.update({"distance": str(self.distance)} if self.distance else {}) if self.time_in_force == "GTD" and self.gtd_time is None: raise OandaError("Invalid GTD time provided. If time_in_force is GTD, you must specify a proper GTD time") _conditional_update(tsl_dict, self.time_in_force == "GTD", "gtdTime", self.gtd_time) tsl_dict.update(self.client_extensions if self.client_extensions else {}) return tsl_dict class OrderRequest: __metaclass__ = abc.ABCMeta def __init__(self, order_type: str): self.type = order_type @abc.abstractmethod def as_dict(self): return class MarketOrderRequest(OrderRequest): def __init__( self, instrument: str, units: float, time_in_force: Optional[str] = "FOK", position_fill: Optional[str] = "DEFAULT", price_floor: Optional[float] = None, take_profit_on_fill: Optional[TakeProfitDetails] = None, stop_loss_on_fill: Optional[StopLossDetails] = None, guaranteed_stop_loss_on_fill: Optional[GuaranteedStopLossDetails] = None, trailing_stop_loss_on_fill: Optional[TrailingStopLossDetails] = None, client_extensions: Optional[ClientExtensions] = None, trade_client_extensions: Optional[ClientExtensions] = None, ): """ Define a market order request Args: instrument (str): Name of the instrument see InstrumentName in oanda_guide.txt units (float): The quantity requested to be filled by the market order NOTE: A positive number creates a long order, negative number creates a short order time_in_force (str, optional): The time in force for the requested market order NOTE: May only be 'FOK', 'IOC' see TimeInForce in oanda_guide.txt position_fill (str, optional): Specify how positions in the account are modified when the order is filled see OrderPositionFill in oanda_guide.txt price_floor (float, optional): The worst price you're willing to have the market order filled at see PriceValue in oanda_guide.txt take_profit_on_fill (TakeProfitDetails, optional): Specify the details of a take profit order to be created This can happen when a filled order opens a trade requiring a take profit, or when a trade's dependent take profit order is modified directly through the trade stop_loss_on_fill (StopLossDetails, optional): Specify the details of a stop loss order to be created This can happen when a filled order opens a trade requiring a stop loss, or when a trade's dependent stop loss order is modified directly through the trade guaranteed_stop_loss_on_fill (GuaranteedStopLossDetails, optional): Specify the details of a guaranteed stop loss order to be created This can happen when a filled order opens a trade requiring a guaranteed stop loss, or when a trade's dependent guaranteed stop loss order is modified directly through the trade trailing_stop_loss_on_fill (TrailingStopLossDetails, optional): Specify the details of a trailing stop loss order to be created This can happen when a filled order opens a trade requiring a trailing stop loss, or when a trade's dependent trailing stop loss order is modified directly through the trade client_extensions (ClientExtensions, optional): The client extensions to add to the market order trade_client_extensions (ClientExtensions, optional): The client extensions to add to the trade created when the order is filled """ super().__init__("MARKET") self.instrument = instrument self.units = units self.time_in_force = time_in_force self.position_fill = position_fill self.price_floor = price_floor self.take_profit_on_fill = take_profit_on_fill self.stop_loss_on_fill = stop_loss_on_fill self.guaranteed_stop_loss_on_fill = guaranteed_stop_loss_on_fill self.trailing_stop_loss_on_fill = trailing_stop_loss_on_fill self.client_extensions = client_extensions self.trade_client_extensions = trade_client_extensions def as_dict(self): mor_dict = { "type": self.type, "instrument": self.instrument, "units": str(self.units), "timeInForce": self.time_in_force, "positionFill": self.position_fill, } _conditional_update(mor_dict, self.price_floor, "priceBound", str(self.price_floor)) _conditional_update( mor_dict, self.take_profit_on_fill, "takeProfitOnFill", self.take_profit_on_fill.as_dict(), ) _conditional_update( mor_dict, self.stop_loss_on_fill, "stopLossOnFill", self.stop_loss_on_fill.as_dict(), ) _conditional_update( mor_dict, self.guaranteed_stop_loss_on_fill, "guaranteedStopLossOnFill", self.guaranteed_stop_loss_on_fill.as_dict(), ) _conditional_update( mor_dict, self.trailing_stop_loss_on_fill, "trailingStopLossOnFill", self.trailing_stop_loss_on_fill.as_dict(), ) _conditional_update( mor_dict, self.client_extensions, "clientExtensions", self.client_extensions.as_dict(), ) _conditional_update( mor_dict, self.trade_client_extensions, "tradeClientExtensions", self.trade_client_extensions.as_dict(), ) return mor_dict class LimitOrderRequest(OrderRequest): def __init__( self, instrument: str, units: float, price: float, time_in_force: Optional[str] = "GTC", gtd_time: Optional[str] = None, position_fill: Optional[str] = "DEFAULT", trigger_condition: Optional[str] = "DEFAULT", take_profit_on_fill: Optional[TakeProfitDetails] = None, stop_loss_on_fill: Optional[StopLossDetails] = None, guaranteed_stop_loss_on_fill: Optional[GuaranteedStopLossDetails] = None, trailing_stop_loss_on_fill: Optional[TrailingStopLossDetails] = None, client_extensions: Optional[ClientExtensions] = None, trade_client_extensions: Optional[ClientExtensions] = None, ): """ Define a limit order request Args: instrument (str): Name of the instrument see InstrumentName in oanda_guide.txt units (float): The quantity requested to be filled by the limit order NOTE: A positive number creates a long order, negative number creates a short order price (float): The price threshold for the limit order (the order will only be filled by a market price equal to or greater than this price) time_in_force (str, optional): The time in force for the requested limit order see TimeInForce in oanda_guide.txt gtd_time (str, optional): The date the limit order will be canceled on if time_in_force is 'GTD' see DateTime in oanda_guide.txt position_fill (str, optional): Specify how positions in the account are modified when the order is filled see OrderPositionFill in oanda_guide.txt trigger_condition (str, optional): Specify which price component should be used when determining if an order should be triggered and filled see OrderTriggerCondition in oanda_guide.txt take_profit_on_fill (TakeProfitDetails, optional): Specify the details of a take profit order to be created This can happen when a filled order opens a trade requiring a take profit, or when a trade's dependent take profit order is modified directly through the trade stop_loss_on_fill (StopLossDetails, optional): Specify the details of a stop loss order to be created This can happen when a filled order opens a trade requiring a stop loss, or when a trade's dependent stop loss order is modified directly through the trade guaranteed_stop_loss_on_fill (GuaranteedStopLossDetails, optional): Specify the details of a guaranteed stop loss order to be created This can happen when a filled order opens a trade requiring a guaranteed stop loss, or when a trade's dependent guaranteed stop loss order is modified directly through the trade trailing_stop_loss_on_fill (TrailingStopLossDetails, optional): Specify the details of a trailing stop loss order to be created This can happen when a filled order opens a trade requiring a trailing stop loss, or when a trade's dependent trailing stop loss order is modified directly through the trade client_extensions (ClientExtensions, optional): The client extensions to add to the limit order trade_client_extensions (ClientExtensions, optional): The client extensions to add to the trade created when the order is filled """ super().__init__("LIMIT") self.instrument = instrument self.units = units self.price = price self.time_in_force = time_in_force self.gtd_time = gtd_time self.position_fill = position_fill self.trigger_condition = trigger_condition self.take_profit_on_fill = take_profit_on_fill self.stop_loss_on_fill = stop_loss_on_fill self.guaranteed_stop_loss_on_fill = guaranteed_stop_loss_on_fill self.trailing_stop_loss_on_fill = trailing_stop_loss_on_fill self.client_extensions = client_extensions self.trade_client_extensions = trade_client_extensions def as_dict(self): lor_dict = { "type": self.type, "instrument": self.instrument, "units": str(self.units), "price": str(self.price), "timeInForce": self.time_in_force, "positionFill": self.position_fill, "triggerCondition": self.trigger_condition, } if self.time_in_force == "GTD" and self.gtd_time is None: raise OandaError("Invalid GTD time provided. If time_in_force is GTD, you must specify a proper GTD time") _conditional_update(lor_dict, self.time_in_force == "GTD", "gtdTime", self.gtd_time) _conditional_update( lor_dict, self.take_profit_on_fill, "takeProfitOnFill", self.take_profit_on_fill.as_dict(), ) _conditional_update( lor_dict, self.stop_loss_on_fill, "stopLossOnFill", self.stop_loss_on_fill.as_dict(), ) _conditional_update( lor_dict, self.guaranteed_stop_loss_on_fill, "guaranteedStopLossOnFill", self.guaranteed_stop_loss_on_fill.as_dict(), ) _conditional_update( lor_dict, self.trailing_stop_loss_on_fill, "trailingStopLossOnFill", self.trailing_stop_loss_on_fill.as_dict(), ) _conditional_update( lor_dict, self.client_extensions, "clientExtensions", self.client_extensions.as_dict(), ) _conditional_update( lor_dict, self.trade_client_extensions, "tradeClientExtensions", self.trade_client_extensions.as_dict(), ) return lor_dict class StopOrderRequest(OrderRequest): def __init__( self, instrument: str, units: float, price: float, time_in_force: Optional[str] = "GTC", gtd_time: Optional[str] = None, position_fill: Optional[str] = "DEFAULT", trigger_condition: Optional[str] = "DEFAULT", price_floor: Optional[float] = None, take_profit_on_fill: Optional[TakeProfitDetails] = None, stop_loss_on_fill: Optional[StopLossDetails] = None, guaranteed_stop_loss_on_fill: Optional[GuaranteedStopLossDetails] = None, trailing_stop_loss_on_fill: Optional[TrailingStopLossDetails] = None, client_extensions: Optional[ClientExtensions] = None, trade_client_extensions: Optional[ClientExtensions] = None, ): """ Define a stop order request Args: instrument (str): Name of the instrument see InstrumentName in oanda_guide.txt units (float): The quantity requested to be filled by the stop order NOTE: A positive number creates a long order, negative number creates a short order price (float): The price threshold for the stop order (the order will only be filled by a market price equal to or greater than this price) time_in_force (str, optional): The time in force for the requested stop order see TimeInForce in oanda_guide.txt gtd_time (str, optional): The date the stop order will be canceled on if time_in_force is 'GTD' see DateTime in oanda_guide.txt position_fill (str, optional): Specify how positions in the account are modified when the order is filled see OrderPositionFill in oanda_guide.txt trigger_condition (str, optional): Specify which price component should be used when determining if an order should be triggered and filled see OrderTriggerCondition in oanda_guide.txt price_floor (float, optional): The worst price you're willing to have the stop order filled at see PriceValue in oanda_guide.txt take_profit_on_fill (TakeProfitDetails, optional): Specify the details of a take profit order to be created This can happen when a filled order opens a trade requiring a take profit, or when a trade's dependent take profit order is modified directly through the trade stop_loss_on_fill (StopLossDetails, optional): Specify the details of a stop loss order to be created This can happen when a filled order opens a trade requiring a stop loss, or when a trade's dependent stop loss order is modified directly through the trade guaranteed_stop_loss_on_fill (GuaranteedStopLossDetails, optional): Specify the details of a guaranteed stop loss order to be created This can happen when a filled order opens a trade requiring a guaranteed stop loss, or when a trade's dependent guaranteed stop loss order is modified directly through the trade trailing_stop_loss_on_fill (TrailingStopLossDetails, optional): Specify the details of a trailing stop loss order to be created This can happen when a filled order opens a trade requiring a trailing stop loss, or when a trade's dependent trailing stop loss order is modified directly through the trade client_extensions (ClientExtensions, optional): The client extensions to add to the stop order trade_client_extensions (ClientExtensions, optional): The client extensions to add to the trade created when the order is filled """ super().__init__("STOP") self.instrument = instrument self.units = units self.price = price self.time_in_force = time_in_force self.gtd_time = gtd_time self.position_fill = position_fill self.trigger_condition = trigger_condition self.price_floor = price_floor self.take_profit_on_fill = take_profit_on_fill self.stop_loss_on_fill = stop_loss_on_fill self.guaranteed_stop_loss_on_fill = guaranteed_stop_loss_on_fill self.trailing_stop_loss_on_fill = trailing_stop_loss_on_fill self.client_extensions = client_extensions self.trade_client_extensions = trade_client_extensions def as_dict(self): sor_dict = { "type": self.type, "instrument": self.instrument, "units": str(self.units), "price": str(self.price), "timeInForce": self.time_in_force, "positionFill": self.position_fill, "triggerCondition": self.trigger_condition, } if self.time_in_force == "GTD" and self.gtd_time is None: raise OandaError("Invalid GTD time provided. If time_in_force is GTD, you must specify a proper GTD time") _conditional_update(sor_dict, self.time_in_force == "GTD", "gtdTime", self.gtd_time) _conditional_update(sor_dict, self.price_floor, "priceBound", str(self.price_floor)) _conditional_update( sor_dict, self.take_profit_on_fill, "takeProfitOnFill", self.take_profit_on_fill.as_dict(), ) _conditional_update( sor_dict, self.stop_loss_on_fill, "stopLossOnFill", self.stop_loss_on_fill.as_dict(), ) _conditional_update( sor_dict, self.guaranteed_stop_loss_on_fill, "guaranteedStopLossOnFill", self.guaranteed_stop_loss_on_fill.as_dict(), ) _conditional_update( sor_dict, self.trailing_stop_loss_on_fill, "trailingStopLossOnFill", self.trailing_stop_loss_on_fill.as_dict(), ) _conditional_update( sor_dict, self.client_extensions, "clientExtensions", self.client_extensions.as_dict(), ) _conditional_update( sor_dict, self.trade_client_extensions, "tradeClientExtensions", self.trade_client_extensions.as_dict(), ) return sor_dict class MarketIfTouchedOrderRequest(OrderRequest): def __init__( self, instrument: str, units: float, price: float, time_in_force: Optional[str] = "GTC", gtd_time: Optional[str] = None, position_fill: Optional[str] = "DEFAULT", trigger_condition: Optional[str] = "DEFAULT", price_floor: Optional[float] = None, take_profit_on_fill: Optional[TakeProfitDetails] = None, stop_loss_on_fill: Optional[StopLossDetails] = None, guaranteed_stop_loss_on_fill: Optional[GuaranteedStopLossDetails] = None, trailing_stop_loss_on_fill: Optional[TrailingStopLossDetails] = None, client_extensions: Optional[ClientExtensions] = None, trade_client_extensions: Optional[ClientExtensions] = None, ): """ Define a market if touched order request Args: instrument (str): Name of the instrument see InstrumentName in oanda_guide.txt units (float): The quantity requested to be filled by the market if touched order NOTE: A positive number creates a long order, negative number creates a short order price (float): The price threshold for the market if touched order (the order will only be filled by a market price equal to or greater than this price) time_in_force (str, optional): The time in force for the requested market if touched order NOTE: May only be 'GTC', 'GFD', 'GTD' see TimeInForce in oanda_guide.txt gtd_time (str, optional): The date the market if touched order will be canceled on if time_in_force is 'GTD' see DateTime in oanda_guide.txt position_fill (str, optional): Specify how positions in the account are modified when the order is filled see OrderPositionFill in oanda_guide.txt trigger_condition (str, optional): Specify which price component should be used when determining if an order should be triggered and filled see OrderTriggerCondition in oanda_guide.txt price_floor (float, optional): The worst price you're willing to have the market if touched order filled at see PriceValue in oanda_guide.txt take_profit_on_fill (TakeProfitDetails, optional): Specify the details of a take profit order to be created This can happen when a filled order opens a trade requiring a take profit, or when a trade's dependent take profit order is modified directly through the trade stop_loss_on_fill (StopLossDetails, optional): Specify the details of a stop loss order to be created This can happen when a filled order opens a trade requiring a stop loss, or when a trade's dependent stop loss order is modified directly through the trade guaranteed_stop_loss_on_fill (GuaranteedStopLossDetails, optional): Specify the details of a guaranteed stop loss order to be created This can happen when a filled order opens a trade requiring a guaranteed stop loss, or when a trade's dependent guaranteed stop loss order is modified directly through the trade trailing_stop_loss_on_fill (TrailingStopLossDetails, optional): Specify the details of a trailing stop loss order to be created This can happen when a filled order opens a trade requiring a trailing stop loss, or when a trade's dependent trailing stop loss order is modified directly through the trade client_extensions (ClientExtensions, optional): The client extensions to add to the market if touched order trade_client_extensions (ClientExtensions, optional): The client extensions to add to the trade created when the order is filled """ super().__init__("MARKET_IF_TOUCHED") self.instrument = instrument self.units = units self.price = price self.time_in_force = time_in_force self.gtd_time = gtd_time self.position_fill = position_fill self.trigger_condition = trigger_condition self.price_floor = price_floor self.take_profit_on_fill = take_profit_on_fill self.stop_loss_on_fill = stop_loss_on_fill self.guaranteed_stop_loss_on_fill = guaranteed_stop_loss_on_fill self.trailing_stop_loss_on_fill = trailing_stop_loss_on_fill self.client_extensions = client_extensions self.trade_client_extensions = trade_client_extensions def as_dict(self): motor_dict = { "type": self.type, "instrument": self.instrument, "units": str(self.units), "price": str(self.price), "timeInForce": self.time_in_force, "positionFill": self.position_fill, "triggerCondition": self.trigger_condition, } if self.time_in_force == "GTD" and self.gtd_time is None: raise OandaError("Invalid GTD time provided. If time_in_force is GTD, you must specify a proper GTD time") _conditional_update(motor_dict, self.time_in_force == "GTD", "gtdTime", self.gtd_time) _conditional_update(motor_dict, self.price_floor, "priceBound", str(self.price_floor)) _conditional_update( motor_dict, self.take_profit_on_fill, "takeProfitOnFill", self.take_profit_on_fill.as_dict(), ) _conditional_update( motor_dict, self.stop_loss_on_fill, "stopLossOnFill", self.stop_loss_on_fill.as_dict(), ) _conditional_update( motor_dict, self.guaranteed_stop_loss_on_fill, "guaranteedStopLossOnFill", self.guaranteed_stop_loss_on_fill.as_dict(), ) _conditional_update( motor_dict, self.trailing_stop_loss_on_fill, "trailingStopLossOnFill", self.trailing_stop_loss_on_fill.as_dict(), ) _conditional_update( motor_dict, self.client_extensions, "clientExtensions", self.client_extensions.as_dict(), ) _conditional_update( motor_dict, self.trade_client_extensions, "tradeClientExtensions", self.trade_client_extensions.as_dict(), ) return motor_dict class TakeProfitOrderRequest(OrderRequest): def __init__( self, trade_id: int, price: float, time_in_force: Optional[str] = "GTC", gtd_time: Optional[str] = None, trigger_condition: Optional[str] = "DEFAULT", client_trade_id: Optional[str] = None, client_extensions: Optional[ClientExtensions] = None, ): """ Define a take profit order request Args: trade_id (int): The id of the trade to close when the price threshold is breached price (float): The price threshold for the take profit order (the order will only be filled by a market price equal to or greater than this price) time_in_force (str, optional): The time in force for the requested take profit order NOTE: May only be 'GTC', 'GFD', 'GTD' see TimeInForce in oanda_guide.txt gtd_time (str, optional): The date the take profit order will be canceled on if time_in_force is 'GTD' see DateTime in oanda_guide.txt trigger_condition (str, optional): Specify which price component should be used when determining if an order should be triggered and filled This can happen when a filled order opens a trade requiring a trailing stop loss, or when a trade's dependent trailing stop loss order is modified directly through the trade see OrderTriggerCondition in oanda_guide.txt client_trade_id (str, optional): The client trade id of the order to close when the price threshold is reached client_extensions (ClientExtensions, optional): The client extensions to add to the take profit order """ super().__init__("TAKE_PROFIT") self.trade_id = trade_id self.price = price self.time_in_force = time_in_force self.gtd_time = gtd_time self.trigger_condition = trigger_condition self.client_trade_id = client_trade_id self.client_extensions = client_extensions def as_dict(self): tpor_dict = { "type": self.type, "tradeID": self.trade_id, "price": str(self.price), "timeInForce": self.time_in_force, "triggerCondition": self.trigger_condition, } if self.time_in_force == "GTD" and self.gtd_time is None: raise OandaError("Invalid GTD time provided. If time_in_force is GTD, you must specify a proper GTD time") _conditional_update(tpor_dict, self.time_in_force == "GTD", "gtdTime", self.gtd_time) _conditional_update(tpor_dict, self.client_trade_id, "clientTradeID", self.client_trade_id) _conditional_update( tpor_dict, self.client_extensions, "clientExtensions", self.client_extensions.as_dict(), ) return tpor_dict class StopLossOrderRequest(OrderRequest): def __init__( self, trade_id: int, price: float, distance: float, time_in_force: Optional[str] = "GTC", gtd_time: Optional[str] = None, trigger_condition: Optional[str] = "DEFAULT", client_trade_id: Optional[str] = None, client_extensions: Optional[ClientExtensions] = None, ): """ Define a stop loss order request Args: trade_id (int): The id of the trade to close when the price threshold is breached price (float): The price threshold for the stop loss order (the order will only be filled by a market price equal to or greater than this price) NOTE: Only price or distance may be specified distance (float): The distance (in price units) from the trade's open price to use as the stop loss order price NOTE: Only price or distance may be specified NOTE: If the trade is short, the instrument's bid price is used, if long, the ask is used time_in_force (str, optional): The time in force for the requested stop loss order NOTE: May only be 'GTC', 'GFD', 'GTD' see TimeInForce in oanda_guide.txt gtd_time (str, optional): The date the stop loss order will be canceled on if time_in_force is 'GTD' see DateTime in oanda_guide.txt trigger_condition (str, optional): Specify which price component should be used when determining if an order should be triggered and filled This can happen when a filled order opens a trade requiring a trailing stop loss, or when a trade's dependent trailing stop loss order is modified directly through the trade see OrderTriggerCondition in oanda_guide.txt client_trade_id (str, optional): The client trade id of the order to close when the price threshold is reached client_extensions (ClientExtensions, optional): The client extensions to add to the stop loss order """ super().__init__("STOP_LOSS") if (price is None and distance is None) or (price and distance): raise OandaError("Only price or distance may be specified") self.trade_id = trade_id self.price = price self.distance = distance self.time_in_force = time_in_force self.gtd_time = gtd_time self.trigger_condition = trigger_condition self.client_trade_id = client_trade_id self.client_extensions = client_extensions def as_dict(self): slor_dict = { "type": self.type, "tradeID": self.trade_id, "timeInForce": self.time_in_force, "triggerCondition": self.trigger_condition, } if self.time_in_force == "GTD" and self.gtd_time is None: raise OandaError("Invalid GTD time provided. If time_in_force is GTD, you must specify a proper GTD time") slor_dict.update({"price": str(self.price)} if self.price else {}) slor_dict.update({"distance": str(self.distance)} if self.distance else {}) _conditional_update(slor_dict, self.time_in_force == "GTD", "gtdTime", self.gtd_time) _conditional_update(slor_dict, self.client_trade_id, "clientTradeID", self.client_trade_id) _conditional_update( slor_dict, self.client_extensions, "clientExtensions", self.client_extensions.as_dict(), ) return slor_dict class GuaranteedStopLossOrderRequest(OrderRequest): def __init__( self, trade_id: int, price: float, distance: float, time_in_force: Optional[str] = "GTC", gtd_time: Optional[str] = None, trigger_condition: Optional[str] = "DEFAULT", client_trade_id: Optional[str] = None, client_extensions: Optional[ClientExtensions] = None, ): """ Define a guaranteed stop loss order request Args: trade_id (int): The id of the trade to close when the price threshold is breached price (float): The price threshold for the guaranteed stop loss order (the order will only be filled by a market price equal to or greater than this price) NOTE: Only price or distance may be specified distance (float): The distance (in price units) from the trade's open price to use as the stop loss order price NOTE: Only price or distance may be specified NOTE: If the trade is short, the instrument's bid price is used, if long, the ask is used time_in_force (str, optional): The time in force for the requested guaranteed stop loss order NOTE: May only be 'GTC', 'GFD', 'GTD' see TimeInForce in oanda_guide.txt gtd_time (str, optional): The date the guaranteed stop loss order will be canceled on if time_in_force is 'GTD' see DateTime in oanda_guide.txt trigger_condition (str, optional): Specify which price component should be used when determining if an order should be triggered and filled This can happen when a filled order opens a trade requiring a trailing stop loss, or when a trade's dependent trailing stop loss order is modified directly through the trade see OrderTriggerCondition in oanda_guide.txt client_trade_id (str, optional): The client trade id of the order to close when the price threshold is reached client_extensions (ClientExtensions, optional): The client extensions to add to the guaranteed stop loss order """ super().__init__("GUARANTEED_STOP_LOSS") if (price is None and distance is None) or (price and distance): raise OandaError("Only price or distance may be specified") self.trade_id = trade_id self.price = price self.distance = distance self.time_in_force = time_in_force self.gtd_time = gtd_time self.trigger_condition = trigger_condition self.client_trade_id = client_trade_id self.client_extensions = client_extensions def as_dict(self): gslor_dict = { "type": self.type, "tradeID": self.trade_id, "timeInForce": self.time_in_force, "triggerCondition": self.trigger_condition, } if self.time_in_force == "GTD" and self.gtd_time is None: raise OandaError("Invalid GTD time provided. If time_in_force is GTD, you must specify a proper GTD time") gslor_dict.update({"price": str(self.price)} if self.price else {}) gslor_dict.update({"distance": str(self.distance)} if self.distance else {}) _conditional_update(gslor_dict, self.time_in_force == "GTD", "gtdTime", self.gtd_time) _conditional_update(gslor_dict, self.client_trade_id, "clientTradeID", self.client_trade_id) _conditional_update( gslor_dict, self.client_extensions, "clientExtensions", self.client_extensions.as_dict(), ) return gslor_dict class TrailingStopLossOrderRequest(OrderRequest): def __init__( self, trade_id: int, distance: float, time_in_force: Optional[str] = "GTC", gtd_time: Optional[str] = None, trigger_condition: Optional[str] = "DEFAULT", client_trade_id: Optional[str] = None, client_extensions: Optional[ClientExtensions] = None, ): """ Define a trailing stop loss order request Args: trade_id (int): The id of the trade to close when the price threshold is breached distance (float): The distance (in price units) from the trade's open price to use as the stop loss order price time_in_force (str, optional): The time in force for the requested trailing stop loss order NOTE: May only be 'GTC', 'GFD', 'GTD' see TimeInForce in oanda_guide.txt gtd_time (str, optional): The date the trailing stop loss order will be canceled on if time_in_force is 'GTD' see DateTime in oanda_guide.txt trigger_condition (str, optional): Specify which price component should be used when determining if an order should be triggered and filled This can happen when a filled order opens a trade requiring a trailing stop loss, or when a trade's dependent trailing stop loss order is modified directly through the trade see OrderTriggerCondition in oanda_guide.txt client_trade_id (str, optional): The client trade id of the order to close when the price threshold is reached client_extensions (ClientExtensions, optional): The client extensions to add to the trailing stop loss order """ super().__init__("TRAILING_STOP_LOSS") self.trade_id = trade_id self.distance = distance self.time_in_force = time_in_force self.gtd_time = gtd_time self.trigger_condition = trigger_condition self.client_trade_id = client_trade_id self.client_extensions = client_extensions def as_dict(self): tslor_dict = { "type": self.type, "tradeID": self.trade_id, "timeInForce": self.time_in_force, "triggerCondition": self.trigger_condition, } if self.time_in_force == "GTD" and self.gtd_time is None: raise OandaError("Invalid GTD time provided. If time_in_force is GTD, you must specify a proper GTD time") tslor_dict.update({"distance": str(self.distance)} if self.distance else {}) _conditional_update(tslor_dict, self.time_in_force == "GTD", "gtdTime", self.gtd_time) _conditional_update(tslor_dict, self.client_trade_id, "clientTradeID", self.client_trade_id) _conditional_update( tslor_dict, self.client_extensions, "clientExtensions", self.client_extensions.as_dict(), ) return tslor_dict class OandaApi: def __init__( self, auth: str, live: bool = False, account_index: Optional[int] = 0, datetime_format: Optional[str] = "RFC3339", ): """ Initialize the API for a specific account under the given api token. Args: auth (str): The api authorization token live (bool, optional): Whether the api should make calls on the live account or not account_index (int, optional): The account index to use, should the api token govern multiple accounts datetime_format (str, optional): The datetime format to use see AcceptDatetimeFormat in oanda_guide.txt """ self.auth = auth self.live = live self.datetime_format = datetime_format self.account_id = self.get_accounts()["accounts"][account_index]["id"] def get_accounts(self) -> dict: """ Get a list of accounts for a given api token """ return self._oanda_api_call("get", "accounts") def get_account_details(self) -> dict: """ Get account details for the account specified at API initialization """ return self._oanda_api_call("get", f"accounts/{self.account_id}") def get_account_summary(self) -> dict: """ Get a summary for the account associated with the API """ return self._oanda_api_call("get", f"accounts/{self.account_id}/summary") def get_account_instruments(self, instruments: Optional[List[str]] = None) -> dict: """ Get a list of tradable instruments available for a given account Args: instruments (List[str], optional): A list of instruments see InstrumentName in oanda_guide.txt """ params = {"instruments": ",".join(instruments)} if instruments else None return self._oanda_api_call("get", f"accounts/{self.account_id}/instruments", params=params) def get_account_changes(self, since_transaction: int) -> dict: """ Poll an account for its current state and changes since a given transaction id Args: since_transaction (int): ID of the transaction to get account changes since see TransactionID in oanda_guide.txt """ params = {"sinceTransactionID": str(since_transaction)} return self._oanda_api_call("get", f"accounts/{self.account_id}/changes", params=params) def configure_account(self, alias: Optional[str] = None, margin_rate: Optional[float] = None) -> dict: """ Configure the alias and/or the margin rate for the account Args: alias (str, optional): Custom name to associate with the account margin_rate (float, optional): Margin rate to change the account to ex. A 50:1 margin rate would be represented as 0.02 """ data = {} data.update({"alias": alias} if alias else {}) data.update({"marginRate": str(margin_rate)} if margin_rate else {}) return self._oanda_api_call("patch", f"accounts/{self.account_id}/configuration", data=data) def get_instrument_candles( self, instrument: str, price: Optional[str] = None, granularity: Optional[str] = None, count: Optional[int] = None, from_time: Optional[str] = None, to_time: Optional[str] = None, smooth: Optional[bool] = None, include_first: Optional[bool] = None, daily_align: Optional[int] = None, timezone_align: Optional[str] = None, weekly_align: Optional[str] = None, units: Optional[float] = None, ) -> dict: """ Get candlestick data for an instrument Args: instrument (str): Name of the instrument see InstrumentName in oanda_guide.txt price (str, optional): The price component(s) ot get candlestick data for default: 'M' see PricingComponent in oanda_guide.txt granularity (str, optional): The granularity of the candlesticks to fetch default: 'S5' see CandlestickGranularity in oanda_guide.txt count (int, optional): The number of candlesticks to return NOTE: count should not be specified if both the from and to time are specified default: 500, max: 5000 from_time (str, optional): The start of the time range to fetch candlesticks for see DateTime in oanda_guide.txt to_time (str, optional): The end of the time range to fetch candlesticks for see DateTime in oanda_guide.txt smooth (bool, optional): A flag that controls whether the candlesticks are smoothed default: False include_first (bool, optional): A flag that controls whether the candlestick that is covered by the from time is included in the results default: True daily_align (int, optional): The hour of the day (in the specified timezone) to use for granularities that have daily alignments min: 0, default: 17, max: 23 timezone_align (str, optional): The timezone to use for the daily_align parameter timezones are specified in the form America/New_York default: 'America/New_York' weekly_align (str, optional): The day of the week used for granularities that have weekly alignment default: 'Friday' see WeeklyAlignment in oanda_guide.txt units (float, optional): Number of units used to calculate the volume-weighted average bid and ask prices """ params = {} params.update({"price": price} if price else {}) params.update({"granularity": granularity} if granularity else {}) params.update({"count": str(count)} if count else {}) params.update({"from": from_time} if from_time else {}) params.update({"to": to_time} if to_time else {}) params.update({"smooth": str(smooth)} if smooth else {}) params.update({"includeFirst": str(include_first)} if include_first else {}) params.update({"dailyAlignment": str(daily_align)} if daily_align else {}) params.update({"alignmentTimezone": timezone_align} if timezone_align else {}) params.update({"weeklyAlignment": weekly_align} if weekly_align else {}) params.update({"units": str(units)} if units else {}) return self._oanda_api_call( "get", f"accounts/{self.account_id}/instruments/{instrument}/candles", params=params, ) def get_instrument_candles_in_range( self, instrument: str, from_time: str, to_time: str, price: Optional[str] = None, granularity: Optional[str] = None, smooth: Optional[bool] = None, include_first: Optional[bool] = None, daily_align: Optional[int] = None, timezone_align: Optional[str] = None, weekly_align: Optional[str] = None, units: Optional[float] = None, ): """ Get candlestick data for an instrument within a given time range NOTE: This is intended to be used when you need more than 5000 candlesticks for a given time range Args: instrument (str): Name of the instrument see InstrumentName in oanda_guide.txt from_time (str): The start of the time range to fetch candlesticks for see DateTime in oanda_guide.txt to_time (str): The end of the time range to fetch candlesticks for see DateTime in oanda_guide.txt price (str, optional): The price component(s) ot get candlestick data for default: 'M' see PricingComponent in oanda_guide.txt granularity (str, optional): The granularity of the candlesticks to fetch default: 'S5' see CandlestickGranularity in oanda_guide.txt smooth (bool, optional): A flag that controls whether the candlesticks are smoothed default: False include_first (bool, optional): A flag that controls whether the candlestick that is covered by the from time is included in the results default: True daily_align (int, optional): The hour of the day (in the specified timezone) to use for granularities that have daily alignments min: 0, default: 17, max: 23 timezone_align (str, optional): The timezone to use for the daily_align parameter timezones are specified in the form America/New_York default: 'America/New_York' weekly_align (str, optional): The day of the week used for granularities that have weekly alignment default: 'Friday' see WeeklyAlignment in oanda_guide.txt units (float, optional): Number of units used to calculate the volume-weighted average bid and ask prices """ params = {"count": 5000} params.update({"price": price} if price else {}) params.update({"granularity": granularity} if granularity else {}) params.update({"from": from_time} if from_time else {}) params.update({"smooth": str(smooth)} if smooth else {}) params.update({"includeFirst": str(include_first)} if include_first else {}) params.update({"dailyAlignment": str(daily_align)} if daily_align else {}) params.update({"alignmentTimezone": timezone_align} if timezone_align else {}) params.update({"weeklyAlignment": weekly_align} if weekly_align else {}) params.update({"units": str(units)} if units else {}) start = self.oanda_time_to_datetime(from_time) end = self.oanda_time_to_datetime(to_time) count = 5000 while start < end and count == 5000: candles = self._oanda_api_call( "get", f"accounts/{self.account_id}/instruments/{instrument}/candles", params=params, )["candles"] count = len(candles) params.update({"from": candles[-1]["time"]}) start = self.oanda_time_to_datetime(candles[-1]["time"]) for candle in candles: if self.oanda_time_to_datetime(candle["time"]) < end: # Strip Z and last 3 nanosecond digits yield candle else: break def get_instrument_order_book(self, instrument: str, time: Optional[str] = None) -> dict: """ Get an order book for an instrument Args: instrument (str): Name of the instrument see InstrumentName in oanda_guide.txt time (str, optional) The time of the snapshot to fetch see DateTime in oanda_guide.txt """ params = {} params.update({"time": time} if time else {}) return self._oanda_api_call("get", f"instruments/{instrument}/orderBook", params=params) def get_instrument_position_book(self, instrument: str, time: Optional[str] = None) -> dict: """ Get a position book for an instrument Args: instrument (str): Name of the instrument see InstrumentName in oanda_guide.txt time (str, optional) The time of the snapshot to fetch see DateTime in oanda_guide.txt """ params = {} params.update({"time": time} if time else {}) return self._oanda_api_call("get", f"instruments/{instrument}/positionBook", params=params) def get_orders( self, ids: Optional[List[int]] = None, state: Optional[str] = None, instrument: Optional[str] = None, count: Optional[int] = None, before_id: Optional[int] = None, ) -> dict: """ Get a list of orders for the account Args: ids (list, optional): List of order ids to retrieve see OrderID in oanda_guide.txt state (str, optional): The state to filter the requested orders by see OrderStateFilter in oanda_guide.txt instrument (str, optional): The instrument to filter the requested orders by see InstrumentName in oanda_guide.txt count (int, optional): The maximum number of orders to return max: 500 before_id (int, optional): The maximum order id to return (if not provided, return the most recent orders) see OrderId in oanda_guide.txt """ params = {} params.update({"ids": ",".join([str(order_id) for order_id in ids])} if ids else {}) params.update({"state": state} if state else {}) params.update({"instrument": instrument} if instrument else {}) params.update({"count": str(count)} if count else {}) params.update({"beforeID": str(before_id)} if before_id else {}) return self._oanda_api_call("get", f"accounts/{self.account_id}/orders", params=params) def get_pending_orders(self) -> dict: """ Get all pending orders in the account """ return self._oanda_api_call("get", f"accounts/{self.account_id}/pendingOrders") def get_order_details(self, order_id: int) -> dict: """ Get details for a single order in the account Args: order_id (int): The id of the order to retrieve details for see OrderID in oanda_guide.txt """ return self._oanda_api_call("get", f"accounts/{self.account_id}/orders/{str(order_id)}") def create_order(self, order: OrderRequest) -> dict: """ Create an order for the account Args: order (OrderRequest): An OrderRequest representing the order you wish to create NOTE: You may use any of the 8 available sub-classes of OrderRequest, but not OrderRequest itself see OrderRequest in oanda_guide.txt """ return self._oanda_api_call("post", f"accounts/{self.account_id}/orders", data=order.as_dict()) def replace_order(self, order_id: int, order: OrderRequest) -> dict: """ Replace an order in the account by simultaneously cancelling it and creating a replacement order Args: order_id (int): The id of the order to cancel see OrderID in oanda_guide.txt order (OrderRequest): An OrderRequest representing the order you wish to create NOTE: You may use any of the 8 available sub-classes of OrderRequest, but not OrderRequest itself see OrderRequest in oanda_guide.txt """ return self._oanda_api_call( "put", f"accounts/{self.account_id}/orders/{str(order_id)}", data=order.as_dict(), ) def cancel_order(self, order_id: int) -> dict: """ Cancel an order for the account Args: order_id (int): The id of the order to cancel see OrderID in oanda_guide.txt """ return self._oanda_api_call("put", f"accounts/{self.account_id}/orders/{str(order_id)}/cancel") def update_order_client_extensions( self, order_id: int, client_extensions: Optional[ClientExtensions] = None, trade_client_extensions: Optional[ClientExtensions] = None, ) -> dict: """ Update client extensions for an order Args: order_id (int): The id of the order to update client extensions for see OrderID in oanda_guide.txt client_extensions (ClientExtensions, optional): The client extensions to update the order to see ClientExtensions in oanda_guide.txt trade_client_extensions (ClientExtensions, optional): The client extensions to update the trade to see ClientExtensions in oanda_guide.txt """ data = {} data.update({"clientExtensions": client_extensions.as_dict()} if client_extensions else {}) data.update({"tradeClientExtensions": trade_client_extensions.as_dict()} if trade_client_extensions else {}) return self._oanda_api_call( "put", f"accounts/{self.account_id}/orders/{str(order_id)}/clientExtensions", data=data, ) def get_trades( self, ids: Optional[List[int]] = None, state: Optional[str] = None, instrument: Optional[str] = None, count: Optional[int] = None, before_id: Optional[int] = None, ) -> dict: """ Get a list of trades for the account Args: ids (list, optional): List of trade ids to retrieve see OrderID in oanda_guide.txt state (str, optional): The state to filter the requested trades by see OrderStateFilter in oanda_guide.txt instrument (str, optional): The instrument to filter the requested orders by see InstrumentName in oanda_guide.txt count (int, optional): The maximum number of trades to return max: 500 before_id (int, optional): The maximum trade id to return (if not provided, return the most recent trades) see TradeId in oanda_guide.txt """ params = {} params.update({"ids": ",".join([str(trade_id) for trade_id in ids])} if ids else {}) params.update({"state": state} if state else {}) params.update({"instrument": instrument} if instrument else {}) params.update({"count": str(count)} if count else {}) params.update({"beforeID": str(before_id)} if before_id else {}) return self._oanda_api_call("get", f"accounts/{self.account_id}/trades", params=params) def get_open_trades(self) -> dict: """ Get a list of open trades for the account """ return self._oanda_api_call("get", f"accounts/{self.account_id}/openTrades") def get_trade_details(self, trade_id: int) -> dict: """ Get details for a single trade in the account Args: trade_id (int): The id of the trade to retrieve details for see TradeId in oanda_guide.txt """ return self._oanda_api_call("get", f"accounts/{self.account_id}/trades/{str(trade_id)}") def close_trade(self, trade_id: int, units: Optional[float] = None) -> dict: """ Close (partially or fully) a specific open trade in the account Args: trade_id (int): The id of the trade to close see TradeId in oanda_guide.txt units (float, optional): The default behavior is to close the trade fully If units are specified, then the trade will be closed the provided number of units By default, this will close the trade fully if a number of units is not specified NOTE: This number must be positive """ data = {"units": "ALL"} if units is None else {"units": str(units)} return self._oanda_api_call("put", f"accounts/{self.account_id}/trades/{str(trade_id)}/close", data=data) def modify_trade_dependent_orders( self, trade_id: int, take_profit: Optional[Union[str, TakeProfitDetails]] = "NO_CHANGE", stop_loss: Optional[Union[str, StopLossDetails]] = "NO_CHANGE", trailing_stop_loss: Optional[Union[str, TrailingStopLossDetails]] = "NO_CHANGE", guaranteed_stop_loss: Optional[Union[str, GuaranteedStopLossDetails]] = "NO_CHANGE", ) -> dict: """ Create, replace, and cancel a trade's dependent orders (take profit, stop loss, and trailing stop loss) through the trade itself Args: trade_id (int): The id of the trade to modify the orders of see TradeId in oanda_guide.txt take_profit (str ['NO_CHANGE', 'CANCEL'], TakeProfitDetails, optional): If take_profit is set to 'NO_CHANGE' the take profit, if it exists, will not be modified. If set to 'CANCEL', the take profit, if it exists, will be canceled. If take_profit is supplied with TakeProfitDetails, then the take profit will update. see TakeProfitDetails in oanda_guide.txt stop_loss (str ['NO_CHANGE', 'CANCEL'], StopLossDetails, optional): If stop_loss is set to 'NO_CHANGE' the stop loss, if it exists, will not be modified. If set to 'CANCEL', the stop loss, if it exists, will be canceled. If stop_loss is supplied with StopLossDetails, then the stop loss will update. see StopLossDetails in oanda_guide.txt trailing_stop_loss (str ['NO_CHANGE', 'CANCEL'], TrailingStopLossDetails, optional): If trailing_stop_loss is set to 'NO_CHANGE' the trailing stop loss, if it exists, will not be modified. If set to 'CANCEL', the trailing stop loss, if it exists, will be canceled. If trailing_stop_loss is supplied with TrailingStopLossDetails, then the trailing stop loss will update. see TrailingStopLossDetails in oanda_guide.txt guaranteed_stop_loss (str ['NO_CHANGE', 'CANCEL'], GuaranteedStopLossDetails, optional): If guaranteed_stop_loss is set to 'NO_CHANGE' the guaranteed stop loss, if it exists, will not be modified. If set to 'CANCEL', the guaranteed stop loss, if it exists, will be canceled. If guaranteed_stop_loss is supplied with GuaranteedStopLossDetails, then the guaranteed stop loss will update. see GuaranteedStopLossDetails in oanda_guide.txt """ data = {} if type(take_profit) == str and take_profit != "NO_CHANGE": data.update( {"takeProfit": None} if type(take_profit) == str and take_profit == "CANCEL" else {"takeProfit": take_profit.as_dict()} ) if type(stop_loss) == str and stop_loss != "NO_CHANGE": data.update( {"stopLoss": None} if type(stop_loss) == str and stop_loss == "CANCEL" else {"stopLoss": stop_loss.as_dict()} ) if type(trailing_stop_loss) == str and trailing_stop_loss != "NO_CHANGE": data.update( {"trailingStopLoss": None} if type(trailing_stop_loss) == str and trailing_stop_loss == "CANCEL" else {"trailingStopLoss": trailing_stop_loss.as_dict()} ) if type(guaranteed_stop_loss) == str and guaranteed_stop_loss != "NO_CHANGE": data.update( {"guaranteedStopLoss": None} if type(guaranteed_stop_loss) == str and guaranteed_stop_loss == "CANCEL" else {"guaranteedStopLoss": guaranteed_stop_loss.as_dict()} ) return self._oanda_api_call( "put", f"accounts/{self.account_id}/trades/{str(trade_id)}/orders", data=data, ) def update_trade_client_extensions( self, trade_id: int, client_extensions: Optional[ClientExtensions] = None ) -> dict: """ Update client extensions for a trade Args: trade_id (int): The id of the order to update client extensions for see TradeId in oanda_guide.txt client_extensions (ClientExtensions, optional): The client extensions to update the order to see ClientExtensions in oanda_guide.txt """ data = {} data.update({"clientExtensions": client_extensions.as_dict()} if client_extensions else {}) return self._oanda_api_call( "put", f"accounts/{self.account_id}/orders/{str(trade_id)}/clientExtensions", data=data, ) def get_positions(self) -> dict: """ Get a list of positions for the account """ return self._oanda_api_call("get", f"accounts/{self.account_id}/positions") def get_open_positions(self) -> dict: """ Get a list of open positions for the account """ return self._oanda_api_call("get", f"accounts/{self.account_id}/openPositions") def get_instrument_position(self, instrument: str) -> dict: """ Get the position of a given instrument for the account (Position may be open or closed) Args: instrument (str): Name of the instrument see InstrumentName in oanda_guide.txt """ return self._oanda_api_call("get", f"accounts/{self.account_id}/positions/{instrument}") def close_instrument_position( self, instrument: str, long_units: Optional[Union[str, float]] = "ALL", short_units: Optional[Union[str, float]] = "ALL", long_client_extensions: Optional[ClientExtensions] = None, short_client_extensions: Optional[ClientExtensions] = None, ) -> dict: """ Close a position for specific instrument, in whole or in part Args: instrument (str): Name of the instrument see InstrumentName in oanda_guide.txt long_units (str ['ALL', 'NONE'], float, optional): The amount of units of the long position to close from 'NONE' to 'ALL' or some float value in-between short_units (str ['ALL', 'NONE'], float, optional): The amount of units of the short position to close from 'NONE' to 'ALL' or some float value in-between long_client_extensions (ClientExtensions, optional): the client extensions to add to the market order created to close the long position short_client_extensions (ClientExtensions, optional): the client extensions to add to the market order created to close the short position """ data = {} if type(long_units) == str and long_units != "ALL": data.update( {"longUnits": "NONE"} if type(long_units) == str and long_units == "NONE" else {"longUnits": str(long_units)} ) if type(short_units) == str and short_units != "ALL": data.update( {"shortUnits": "NONE"} if type(short_units) == str and short_units == "NONE" else {"shortUnits": str(short_units)} ) data.update({"longClientExtensions": long_client_extensions.as_dict()} if long_client_extensions else {}) data.update({"shortClientExtensions": short_client_extensions.as_dict()} if short_client_extensions else {}) return self._oanda_api_call("put", f"accounts/{self.account_id}/positions/{instrument}/close", data=data) def get_transactions( self, from_time: Optional[str] = None, to_time: Optional[str] = None, page_size: Optional[int] = None, transaction_type: Optional[List[str]] = None, ) -> dict: """ Get a list of transactions given a set of time based parameters Args: from_time (str, optional): The start of the time range to fetch transaction history for default: account creation see DateTime in oanda_guide.txt to_time (str, optional): The end of the time range to fetch transaction history for default: current time see DateTime in oanda_guide.txt page_size (int, optional): The number of transactions to include in each page of the results max: 1000 transaction_type (List[str], optional): Filters to apply to the transactions returned see TransactionFilter in oanda_guide.txt """ params = {} params.update({"from": from_time} if from_time else {}) params.update({"to": to_time} if to_time else {}) params.update({"pageSize": str(page_size)} if page_size else {}) params.update({"type": ",".join(transaction_type)} if transaction_type else {}) return self._oanda_api_call("get", f"accounts/{self.account_id}/transactions", params=params) def get_transaction_details(self, transaction_id: id) -> dict: """ Get details for a single transaction in the account Args: transaction_id (int): The id of the transaction to retrieve details for see TransactionID in oanda_guide.txt """ return self._oanda_api_call("get", f"accounts/{self.account_id}/transactions/{str(transaction_id)}") def get_transactions_in_range(self, from_id: int, to_id: int, transaction_type: Optional[List[str]] = None) -> dict: """ Get a list of transactions given a range of transaction ids Args: from_id (int): The starting transaction id of the range see TransactionID in oanda_guide.txt to_id (int): The ending transaction id of the rage see TransactionID in oanda_guide.txt transaction_type (List[str], optional): Filters to apply to the transactions returned see TransactionFilter in oanda_guide.txt """ params = {"from": str(from_id), "to": str(to_id)} params.update({"type": ",".join(transaction_type)} if transaction_type else {}) return self._oanda_api_call("get", f"accounts/{self.account_id}/transactions/idrange", params=params) def get_transactions_since_id(self, from_id: int, transaction_type: Optional[List[str]] = None) -> dict: """ Get a list of transactions since a given transaction id Args: from_id (int): The starting transaction id see TransactionID in oanda_guide.txt transaction_type (List[str], optional): Filters to apply to the transactions returned see TransactionFilter in oanda_guide.txt """ params = {"id": str(from_id)} params.update({"type": ",".join(transaction_type)} if transaction_type else {}) return self._oanda_api_call("get", f"accounts/{self.account_id}/transactions/sinceid", params=params) def transaction_stream(self): """ Connect to the transaction stream NOTE: This returns a generator --- Usage --- transaction_stream = API.transaction_stream() for transaction in transaction_stream: # Do something with transaction print(transaction) # Keep everything within the for loop # It will produce new transactions as transactions are made ------------- """ stream = self._oanda_api_stream_call("get", f"accounts/{self.account_id}/transactions/stream") with stream as stream: for transaction in stream.iter_lines(): transaction = json.loads(transaction.decode("utf-8")) yield transaction def get_candles( self, candle_specs: List[str], units: Optional[float] = None, smooth: Optional[bool] = None, daily_align: Optional[int] = None, timezone_align: Optional[str] = None, weekly_align: Optional[str] = None, ) -> dict: """ Get recently completed candles for a given combination of instruments/specs Args: candle_specs (List[str]): List of candle specifications to get pricing for see CandleSpecification in oanda_guide.txt units (float, optional): Number of units used to calculate the volume-weighted average bid and ask prices smooth (bool, optional): A flag that controls whether the candlesticks are smoothed default: False daily_align (int, optional): The hour of the day (in the specified timezone) to use for granularities that have daily alignments min: 0, default: 17, max: 23 timezone_align (str, optional): The timezone to use for the daily_align parameter timezones are specified in the form America/New_York default: 'America/New_York' weekly_align (str, optional): The day of the week used for granularities that have weekly alignment default: 'Friday' see WeeklyAlignment in oanda_guide.txt """ params = {"candleSpecifications": ",".join(candle_specs)} params.update({"units": str(units)} if units else {}) params.update({"smooth": str(smooth)} if smooth else {}) params.update({"dailyAlignment": str(daily_align)} if daily_align else {}) params.update({"alignmentTimezone": timezone_align} if timezone_align else {}) params.update({"weeklyAlignment": weekly_align} if weekly_align else {}) return self._oanda_api_call("get", f"accounts/{self.account_id}/candles/latest", params=params) def get_instrument_pricing( self, instruments: List[str], since: Optional[str] = None, convert: Optional[bool] = None, ) -> dict: """ Get pricing for a given list of instruments Args: instruments (List[str]): A list of instruments see InstrumentName in oanda_guide.txt since (str, optional): Only provide pricing info since the given datetime see DateTime in oanda_guide.txt convert (bool, optional): Include home conversions in the returned response default: True """ params = {"instruments": ",".join(instruments)} params.update({"since": since} if since else {}) params.update({"includeHomeConversion": str(convert)} if convert else {}) return self._oanda_api_call("get", f"accounts/{self.account_id}/pricing", params=params) def pricing_stream( self, instruments: List[str], snapshot: Optional[bool] = None, convert: Optional[bool] = None, ): """ Connect to the pricing stream NOTE: This returns a generator Args: instruments (List[str]): A list of instruments see InstrumentName in oanda_guide.txt snapshot (bool, optional): Flag that enables/disables the sending of a pricing snapshot on connection default: True convert (bool, optional): Include home conversions in the returned response default: True --- Usage --- pricing_stream = API.pricing_stream(['EUR_USD', 'GBP_USD']) for pricing in pricing_stream: # Do something with transaction print(pricing) # Keep everything within the for loop # It will produce new prices live ------------- """ params = {"instruments": ",".join(instruments)} params.update({"snapshot": str(snapshot)} if snapshot else {}) params.update({"includeHomeConversion": str(convert)} if convert else {}) stream = self._oanda_api_stream_call("get", f"accounts/{self.account_id}/pricing/stream", params=params) with stream as stream: for price in stream.iter_lines(): price = json.loads(price.decode("utf-8")) if price.get("type") and price.get("type") == "PRICE" and price.get("tradeable"): price.pop("status") yield price def oanda_time_to_datetime(self, time_str: str): if self.datetime_format == "RFC3339": if time_str[-1] == "Z": return datetime.fromisoformat(time_str[0:-4]) else: return datetime.fromisoformat(time_str) elif self.datetime_format == "UNIX": return datetime.fromtimestamp(int(float(time_str))) else: raise OandaError("Improper datetime format. Must be 'RFC3339' or 'UNIX'") def datetime_to_oanda_time(self, date: datetime): if self.datetime_format == "RFC3339": return date.isoformat("T") + "000Z" elif self.datetime_format == "UNIX": # TODO TEST return date.timestamp() else: raise OandaError("Improper datetime format. Must be 'RFC3339' or 'UNIX'") def _oanda_api_call(self, method, endpoint, params=None, data=None): params = params if params != {} else None data = data if data != {} else None base_url = live_url if self.live else practice_url full_url = f"{base_url}/{api_version}/{endpoint}" headers = { "Authorization": f"Bearer {self.auth}", "Content-Type": "application/json", "Accept-Datetime-Format": self.datetime_format, } response = getattr(requests, method)(full_url, headers=headers, params=params, json=data) if response.status_code >= 300: raise OandaError("HTTP Error {}: {}".format(response.status_code, response.json()["errorMessage"])) return response.json() def _oanda_api_stream_call(self, method, endpoint, params=None, data=None): params = params if params != {} else None data = data if data != {} else None base_url = live_stream_url if self.live else practice_stream_url full_url = f"{base_url}/{api_version}/{endpoint}" headers = { "Authorization": f"Bearer {self.auth}", "Content-Type": "application/json", "Accept-Datetime-Format": self.datetime_format, } response = getattr(requests, method)(full_url, headers=headers, params=params, json=data, stream=True) if response.status_code >= 300: raise OandaError("HTTP Error {}: {}".format(response.status_code, response.json()["errorMessage"])) return response
47.651591
120
0.632546
10,526
85,344
4.948793
0.047216
0.028105
0.024496
0.029948
0.850185
0.820929
0.795896
0.787564
0.774049
0.762051
0
0.001621
0.291749
85,344
1,790
121
47.678212
0.86017
0.411218
0
0.659465
0
0
0.12728
0.0442
0
0
0
0.000559
0
1
0.072016
false
0
0.005144
0.002058
0.149177
0
0
0
0
null
0
0
0
1
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
6
78cb1942d2bcd385d4fd1f157de0fb5937388fd4
35
py
Python
tests/import.py
MarcoQin/python-lua
0a93d3841860547a101068d4895bfa743f45c67d
[ "Apache-2.0" ]
69
2020-02-23T11:20:18.000Z
2022-03-14T06:10:40.000Z
tests/import.py
lumimyrsky/python-lua
80b41381057a5c01793c1bc5beed0d6a1678349a
[ "Apache-2.0" ]
5
2020-05-27T13:32:18.000Z
2022-03-19T01:52:28.000Z
tests/import.py
lumimyrsky/python-lua
80b41381057a5c01793c1bc5beed0d6a1678349a
[ "Apache-2.0" ]
15
2020-03-29T17:54:41.000Z
2022-03-15T06:22:01.000Z
import foo.bar import bar as bar_ex
17.5
20
0.828571
8
35
3.5
0.625
0
0
0
0
0
0
0
0
0
0
0
0.142857
35
2
20
17.5
0.933333
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
1
0
0
6
156af6400e11dd64ed6bee827b241623e6d1388d
30,844
py
Python
interfaces/rail/convertDESCcat.py
ixkael/PhotoZviaGP
32967d597a6d8c799235d4f9ea75e7328ce0c7af
[ "MIT" ]
null
null
null
interfaces/rail/convertDESCcat.py
ixkael/PhotoZviaGP
32967d597a6d8c799235d4f9ea75e7328ce0c7af
[ "MIT" ]
null
null
null
interfaces/rail/convertDESCcat.py
ixkael/PhotoZviaGP
32967d597a6d8c799235d4f9ea75e7328ce0c7af
[ "MIT" ]
null
null
null
####################################################################################################### # # script : convertDESCcat.py # # convert DESC catalog to be injected in Delight # produce files `galaxies-redshiftpdfs.txt` and `galaxies-redshiftpdfs2.txt` for training and target # ######################################################################################################### import sys import os import numpy as np from functools import reduce from delight.io import * from delight.utils import * from tables_io import io import coloredlogs import logging logger = logging.getLogger(__name__) coloredlogs.install(level='DEBUG', logger=logger,fmt='%(asctime)s,%(msecs)03d %(programname)s, %(name)s[%(process)d] %(levelname)s %(message)s') # option to convert DC2 flux level (in AB units) into internal Delight units # this option will be removed when optimisation of parameters will be implemented FLAG_CONVERTFLUX_TODELIGHTUNIT=True def group_entries(f): """ group entries in single numpy array """ galid = f['id'][()][:, np.newaxis] redshift = f['redshift'][()][:, np.newaxis] mag_err_g_lsst = f['mag_err_g_lsst'][()][:, np.newaxis] mag_err_i_lsst = f['mag_err_i_lsst'][()][:, np.newaxis] mag_err_r_lsst = f['mag_err_r_lsst'][()][:, np.newaxis] mag_err_u_lsst = f['mag_err_u_lsst'][()][:, np.newaxis] mag_err_y_lsst = f['mag_err_y_lsst'][()][:, np.newaxis] mag_err_z_lsst = f['mag_err_z_lsst'][()][:, np.newaxis] mag_g_lsst = f['mag_g_lsst'][()][:, np.newaxis] mag_i_lsst = f['mag_i_lsst'][()][:, np.newaxis] mag_r_lsst = f['mag_r_lsst'][()][:, np.newaxis] mag_u_lsst = f['mag_u_lsst'][()][:, np.newaxis] mag_y_lsst = f['mag_y_lsst'][()][:, np.newaxis] mag_z_lsst = f['mag_z_lsst'][()][:, np.newaxis] full_arr = np.hstack((galid, redshift, mag_u_lsst, mag_g_lsst, mag_r_lsst, mag_i_lsst, mag_z_lsst, mag_y_lsst, \ mag_err_u_lsst, mag_err_g_lsst, mag_err_r_lsst, mag_err_i_lsst, mag_err_z_lsst, mag_err_y_lsst)) return full_arr def filter_mag_entries(d,nb=6): """ Filter bad data with bad magnitudes input - d: array of magnitudes and errors - nb : number of bands output : - indexes of row to be filtered """ u = d[:, 2] idx_u = np.where(u > 31.8)[0] return idx_u def mag_to_flux(d,nb=6): """ Convert magnitudes to fluxes input: -d : array of magnitudes with errors :return: array of fluxes with error """ fluxes = np.zeros_like(d) fluxes[:, 0] = d[:, 0] # object index fluxes[:, 1] = d[:, 1] # redshift for idx in np.arange(nb): fluxes[:, 2 + idx] = np.power(10, -0.4 * d[:, 2 + idx]) # fluxes fluxes[:, 8 + idx] = fluxes[:, 2 + idx] * d[:, 8 + idx] # errors on fluxes return fluxes def filter_flux_entries(d,nb=6,nsig=5): """ Filter noisy data on the the number SNR input : - d: flux and errors array - nb : number of bands - nsig : number of sigma output: indexes of row to suppress """ # collection of indexes indexes = [] #indexes = np.array(indexes, dtype=np.int) indexes = np.array(indexes, dtype=int) for idx in np.arange(nb): ratio = d[:, 2 + idx] / d[:, 8 + idx] # flux divided by sigma-flux bad_indexes = np.where(ratio < nsig)[0] indexes = np.concatenate((indexes, bad_indexes)) indexes = np.unique(indexes) return np.sort(indexes) def convertDESCcatChunk(configfilename,data,chunknum,flag_filter_validation = True, snr_cut_validation = 5): """ convertDESCcatChunk(configfilename,data,chunknum,flag_filter_validation = True, snr_cut_validation = 5) Convert files in ascii format to be used by Delight Input data can be filtered by series of filters. But it is necessary to remember which entries are kept, which are eliminated input args: - configfilename : Delight configuration file containing path for output files (flux variances and redshifts) - data : the DC2 data - chunknum : number of the chunk - filter_validation : Flag to activate quality filter data - snr_cut_validation : cut on flux SNR output : - the target file of the chunk which path is in configuration file :return: - the list of selected (unfiltered DC2 data) """ msg="--- Convert DESC catalogs chunk {}---".format(chunknum) logger.info(msg) if FLAG_CONVERTFLUX_TODELIGHTUNIT: flux_multiplicative_factor = 2.22e10 else: flux_multiplicative_factor = 1 # produce a numpy array magdata = group_entries(data) # remember the number of entries Nin = magdata.shape[0] msg = "Number of objects = {} , in chunk : {}".format(Nin,chunknum) logger.debug(msg) # keep indexes to filter data with bad magnitudes if flag_filter_validation: indexes_bad_mag = filter_mag_entries(magdata) #magdata_f = np.delete(magdata, indexes_bad_mag, axis=0) magdata_f = magdata # filtering will be done later else: indexes_bad_mag=np.array([]) magdata_f = magdata Nbadmag = len(indexes_bad_mag) msg = "Number of objects with bad magnitudes = {} , in chunk : {}".format(Nbadmag, chunknum) logger.debug(msg) #print("indexes_bad_mag = ",indexes_bad_mag) # convert mag to fluxes fdata = mag_to_flux(magdata_f) # keep indexes to filter data with bad SNR if flag_filter_validation: indexes_bad_snr = filter_flux_entries(fdata, nsig = snr_cut_validation) fdata_f = fdata #fdata_f = np.delete(fdata, indexes_bad, axis=0) #magdata_f = np.delete(magdata_f, indexes_bad, axis=0) else: fdata_f=fdata indexes_bad_snr = np.array([]) Nbadsnr = len(indexes_bad_snr) msg = "Number of objects with bad SNR = {} , in chunk : {}".format(Nbadsnr, chunknum) logger.debug(msg) #print("indexes_bad_snr = ", indexes_bad_snr) # make union of indexes (unique id) before removing them for Delight idxToRemove = reduce(np.union1d,(indexes_bad_mag,indexes_bad_snr)) NtoRemove=len(idxToRemove) msg = "Number of objects filtered out = {} , in chunk : {}".format(NtoRemove, chunknum) logger.debug(msg) #print("indexes_to_remove = ", idxToRemove) #pprint(idxToRemove) # fdata_f contains the fluxes and errors to be send to Delight # indexes of full input dataset idxInitial = np.arange(Nin) if NtoRemove>0: fdata_f = np.delete(fdata_f,idxToRemove, axis=0) idxFinal=np.delete(idxInitial,idxToRemove, axis=0) else: idxFinal = idxInitial Nkept = len(idxFinal) msg = "Number of objects kept = {} , in chunk : {}".format(Nkept, chunknum) logger.debug(msg) #print("indexes_kept = ", idxFinal) gid = fdata_f[:, 0] rs = fdata_f[:, 1] # 2) parameter file params = parseParamFile(configfilename, verbose=False, catFilesNeeded=False) numB = len(params['bandNames']) numObjects = len(gid) msg = "get {} objects ".format(numObjects) logger.debug(msg) logger.debug(params['bandNames']) # Generate target data # ------------------------- # what is fluxes and fluxes variance fluxes, fluxesVar = np.zeros((numObjects, numB)), np.zeros((numObjects, numB)) # loop on objects to simulate for the target and save in output trarget file for k in range(numObjects): # loop on number of bands for i in range(numB): trueFlux = fdata_f[k, 2 + i] noise = fdata_f[k, 8 + i] # put the DC2 data to the internal units of Delight trueFlux *= flux_multiplicative_factor noise *= flux_multiplicative_factor # fluxes[k, i] = trueFlux + noise * np.random.randn() # noisy flux fluxes[k, i] = trueFlux if fluxes[k, i] < 0: # fluxes[k, i]=np.abs(noise)/10. fluxes[k, i] = trueFlux fluxesVar[k, i] = noise ** 2. # container for target galaxies output # at some redshift, provides the flux and its variance inside each band data = np.zeros((numObjects, 1 + len(params['target_bandOrder']))) bandIndices, bandNames, bandColumns, bandVarColumns, redshiftColumn, refBandColumn = readColumnPositions(params, prefix="target_") for ib, pf, pfv in zip(bandIndices, bandColumns, bandVarColumns): data[:, pf] = fluxes[:, ib] data[:, pfv] = fluxesVar[:, ib] data[:, redshiftColumn] = rs data[:, -1] = 0 # NO TYPE msg = "write file {}".format(os.path.basename(params['targetFile'])) logger.debug(msg) msg = "write target file {}".format(params['targetFile']) logger.debug(msg) outputdir = os.path.dirname(params['targetFile']) if not os.path.exists(outputdir): # pragma: no cover msg = " outputdir not existing {} then create it ".format(outputdir) logger.info(msg) os.makedirs(outputdir) np.savetxt(params['targetFile'], data) # return the index of selected data return idxFinal #def convertDESCcat(configfilename,desctraincatalogfile,desctargetcatalogfile,\ #flag_filter_training=True,flag_filter_validation=True,snr_cut_training=5,snr_cut_validation=5): # """ # convertDESCcat(configfilename,desctraincatalogfile,desctargetcatalogfile,\ # flag_filter_training=True,flag_filter_validation=True,snr_cut_training=5,snr_cut_validation=5): # Convert files in ascii format to be used by Delight # input args: # - configfilename : Delight configuration file containingg path for output files (flux variances and redshifts) # - desctraincatalogfile : training file provided by RAIL (hdf5 format) # - desctargetcatalogfile : target file provided by RAIL (hdf5 format) # - flag_filter_training : Activate filtering on training data # - flag_filter_validation : Activate filtering on validation data # - snr_cut_training : Cut on flux SNR in training data # - snr_cut_validation : Cut on flux SNR in validation data # output : # - the Delight training and target file which path is in configuration file # :return: nothing # """ # logger.info("--- Convert DESC training and target catalogs ---") # if FLAG_CONVERTFLUX_TODELIGHTUNIT: # flux_multiplicative_factor = 2.22e10 # else: # flux_multiplicative_factor = 1 # 1) DESC catalog file # msg="read DESC hdf5 training file {} ".format(desctraincatalogfile) # logger.debug(msg) # f = io.readHdf5ToDict(desctraincatalogfile, groupname='photometry') # produce a numpy array # magdata = group_entries(f) # remember the number of entries # Nin = magdata.shape[0] # msg = "Number of objects = {} , in training dataset".format(Nin) # logger.debug(msg) # keep indexes to filter data with bad magnitudes # if flag_filter_training: # indexes_bad_mag = filter_mag_entries(magdata) # magdata_f = np.delete(magdata, indexes_bad_mag, axis=0) # magdata_f = magdata # filtering will be done later # else: # indexes_bad_mag = np.array([]) # magdata_f = magdata # Nbadmag = len(indexes_bad_mag) # msg = "Number of objects with bad magnitudes {} in training dataset".format(Nbadmag) # logger.debug(msg) # convert mag to fluxes # fdata = mag_to_flux(magdata_f) # keep indexes to filter data with bad SNR # if flag_filter_training: # indexes_bad_snr = filter_flux_entries(fdata, nsig=snr_cut_training) # fdata_f = fdata # else: # fdata_f = fdata # indexes_bad_snr = np.array([]) # Nbadsnr = len(indexes_bad_snr) # msg = "Number of objects with bad SNR = {} , in training dataset".format(Nbadsnr) # logger.debug(msg) # make union of indexes (unique id) before removing them for Delight # idxToRemove = reduce(np.union1d, (indexes_bad_mag, indexes_bad_snr)) # NtoRemove = len(idxToRemove) # msg = "Number of objects filtered out = {} , in training dataset".format(NtoRemove) # logger.debug(msg) # fdata_f contains the fluxes and errors to be send to Delight # indexes of full input dataset # idxInitial = np.arange(Nin) # if NtoRemove > 0: # fdata_f = np.delete(fdata_f, idxToRemove, axis=0) # idxFinal = np.delete(idxInitial, idxToRemove, axis=0) # else: # idxFinal = idxInitial # Nkept = len(idxFinal) # msg = "Number of objects kept = {} , in training dataset".format(Nkept) # logger.debug(msg) # gid = fdata_f[:, 0] # rs = fdata_f[:, 1] # 2) parameter file # params = parseParamFile(configfilename, verbose=False, catFilesNeeded=False) # numB = len(params['bandNames']) # numObjects = len(gid) # msg = "get {} objects ".format(numObjects) # logger.debug(msg) # logger.debug(params['bandNames']) # Generate training data #------------------------- # what is fluxes and fluxes variance # fluxes, fluxesVar = np.zeros((numObjects, numB)), np.zeros((numObjects, numB)) # loop on objects to simulate for the training and save in output training file # for k in range(numObjects): #loop on number of bands # for i in range(numB): # trueFlux = fdata_f[k,2+i] # noise = fdata_f[k,8+i] # put the DC2 data to the internal units of Delight # trueFlux *= flux_multiplicative_factor # noise *= flux_multiplicative_factor #fluxes[k, i] = trueFlux + noise * np.random.randn() # noisy flux # fluxes[k, i] = trueFlux # if fluxes[k, i]<0: #fluxes[k, i]=np.abs(noise)/10. # fluxes[k, i] = trueFlux # fluxesVar[k, i] = noise**2. # container for training galaxies output # at some redshift, provides the flux and its variance inside each band # data = np.zeros((numObjects, 1 + len(params['training_bandOrder']))) # bandIndices, bandNames, bandColumns, bandVarColumns, redshiftColumn,refBandColumn = readColumnPositions(params, prefix="training_") # for ib, pf, pfv in zip(bandIndices, bandColumns, bandVarColumns): # data[:, pf] = fluxes[:, ib] # data[:, pfv] = fluxesVar[:, ib] # data[:, redshiftColumn] = rs # data[:, -1] = 0 # NO type # msg="write training file {}".format(params['trainingFile']) # logger.debug(msg) # outputdir=os.path.dirname(params['trainingFile']) # if not os.path.exists(outputdir): # msg = " outputdir not existing {} then create it ".format(outputdir) # logger.info(msg) # os.makedirs(outputdir) # np.savetxt(params['trainingFile'], data) # Generate Target data : procedure similar to the training #----------------------------------------------------------- # 1) DESC catalog file # msg = "read DESC hdf5 validation file {} ".format(desctargetcatalogfile) # logger.debug(msg) # f = io.readHdf5ToDict(desctargetcatalogfile, groupname='photometry') # produce a numpy array # magdata = group_entries(f) # remember the number of entries # Nin = magdata.shape[0] # msg = "Number of objects = {} , in validation dataset".format(Nin) # logger.debug(msg) # filter bad data # keep indexes to filter data with bad magnitudes # if flag_filter_validation: # indexes_bad_mag = filter_mag_entries(magdata) # magdata_f = np.delete(magdata, indexes_bad_mag, axis=0) # magdata_f = magdata # filtering will be done later # else: # indexes_bad_mag = np.array([]) # magdata_f = magdata # Nbadmag = len(indexes_bad_mag) # msg = "Number of objects with bad magnitudes = {} , in validation dataset".format(Nbadmag) # logger.debug(msg) # convert mag to fluxes # fdata = mag_to_flux(magdata_f) # keep indexes to filter data with bad SNR # if flag_filter_validation: # indexes_bad_snr = filter_flux_entries(fdata, nsig=snr_cut_validation) # fdata_f = fdata # fdata_f = np.delete(fdata, indexes_bad, axis=0) # magdata_f = np.delete(magdata_f, indexes_bad, axis=0) # else: # fdata_f = fdata # indexes_bad_snr = np.array([]) # Nbadsnr = len(indexes_bad_snr) # msg = "Number of objects with bad SNR = {} , in validation dataset".format(Nbadsnr) # logger.debug(msg) # make union of indexes (unique id) before removing them for Delight # idxToRemove = reduce(np.union1d, (indexes_bad_mag, indexes_bad_snr)) # NtoRemove = len(idxToRemove) # msg = "Number of objects filtered out = {} , in validation dataset".format(NtoRemove) # logger.debug(msg) # fdata_f contains the fluxes and errors to be send to Delight # indexes of full input dataset # idxInitial = np.arange(Nin) # if NtoRemove > 0: # fdata_f = np.delete(fdata_f, idxToRemove, axis=0) # idxFinal = np.delete(idxInitial, idxToRemove, axis=0) # else: # idxFinal = idxInitial # Nkept = len(idxFinal) # msg = "Number of objects kept = {} , in validation dataset".format(Nkept) # logger.debug(msg) # gid = fdata_f[:, 0] # rs = fdata_f[:, 1] # numObjects = len(gid) # msg = "get {} objects ".format(numObjects) # logger.debug(msg) # fluxes, fluxesVar = np.zeros((numObjects, numB)), np.zeros((numObjects, numB)) # loop on objects in target files # for k in range(numObjects): # loop on bands # for i in range(numB): # compute the flux in that band at the redshift # trueFlux = fdata_f[k, 2 + i] # noise = fdata_f[k, 8 + i] # put the DC2 data to the internal units of Delight # trueFlux *= flux_multiplicative_factor # noise *= flux_multiplicative_factor #fluxes[k, i] = trueFlux + noise * np.random.randn() # fluxes[k, i] = trueFlux # if fluxes[k, i]<0: #fluxes[k, i]=np.abs(noise)/10. # fluxes[k, i] = trueFlux # fluxesVar[k, i] = noise**2 # data = np.zeros((numObjects, 1 + len(params['target_bandOrder']))) # bandIndices, bandNames, bandColumns, bandVarColumns, redshiftColumn,refBandColumn = readColumnPositions(params, prefix="target_") # for ib, pf, pfv in zip(bandIndices, bandColumns, bandVarColumns): # data[:, pf] = fluxes[:, ib] # data[:, pfv] = fluxesVar[:, ib] # data[:, redshiftColumn] = rs # data[:, -1] = 0 # NO TYPE # msg = "write file {}".format(os.path.basename(params['targetFile'])) # logger.debug(msg) # msg = "write target file {}".format(params['targetFile']) # logger.debug(msg) # outputdir = os.path.dirname(params['targetFile']) # if not os.path.exists(outputdir): # msg = " outputdir not existing {} then create it ".format(outputdir) # logger.info(msg) # os.makedirs(outputdir) # np.savetxt(params['targetFile'], data) ################################################################################ # New version of RAIL with data structure directly provided: (SDC 2021/10/23) # ################################################################################ def convertDESCcatTrainData(configfilename,descatalogdata,flag_filter=True,snr_cut=5): """ convertDESCcatData(configfilename,desccatalogdata, flag_filter=True,snr_cut=5,s): Convert files in ascii format to be used by Delight input args: - configfilename : Delight configuration file containingg path for output files (flux variances and redshifts) - desccatalogdata : data provided by RAIL (dictionary format) - flag_filter : Activate filtering on training data - snr_cut: Cut on flux SNR in training data output : - the Delight training which path is in configuration file :return: nothing """ logger.info("--- Convert DESC training catalogs data ---") if FLAG_CONVERTFLUX_TODELIGHTUNIT: flux_multiplicative_factor = 2.22e10 else: flux_multiplicative_factor = 1 magdata = group_entries(descatalogdata) # remember the number of entries Nin = magdata.shape[0] msg = "Number of objects = {} , in training dataset".format(Nin) logger.debug(msg) # keep indexes to filter data with bad magnitudes if flag_filter: indexes_bad_mag = filter_mag_entries(magdata) # magdata_f = np.delete(magdata, indexes_bad_mag, axis=0) magdata_f = magdata # filtering will be done later else: indexes_bad_mag = np.array([]) magdata_f = magdata Nbadmag = len(indexes_bad_mag) msg = "Number of objects with bad magnitudes {} in training dataset".format(Nbadmag) logger.debug(msg) # convert mag to fluxes fdata = mag_to_flux(magdata_f) # keep indexes to filter data with bad SNR if flag_filter: indexes_bad_snr = filter_flux_entries(fdata, nsig=snr_cut) fdata_f = fdata # fdata_f = np.delete(fdata, indexes_bad, axis=0) # magdata_f = np.delete(magdata_f, indexes_bad, axis=0) else: fdata_f = fdata indexes_bad_snr = np.array([]) Nbadsnr = len(indexes_bad_snr) msg = "Number of objects with bad SNR = {} , in training dataset".format(Nbadsnr) logger.debug(msg) # make union of indexes (unique id) before removing them for Delight idxToRemove = reduce(np.union1d, (indexes_bad_mag, indexes_bad_snr)) NtoRemove = len(idxToRemove) msg = "Number of objects filtered out = {} , in training dataset".format(NtoRemove) logger.debug(msg) # fdata_f contains the fluxes and errors to be send to Delight # indexes of full input dataset idxInitial = np.arange(Nin) if NtoRemove > 0: fdata_f = np.delete(fdata_f, idxToRemove, axis=0) idxFinal = np.delete(idxInitial, idxToRemove, axis=0) else: idxFinal = idxInitial Nkept = len(idxFinal) msg = "Number of objects kept = {} , in training dataset".format(Nkept) logger.debug(msg) gid = fdata_f[:, 0] rs = fdata_f[:, 1] # 2) parameter file #------------------- params = parseParamFile(configfilename, verbose=False, catFilesNeeded=False) numB = len(params['bandNames']) numObjects = len(gid) msg = "get {} objects ".format(numObjects) logger.debug(msg) logger.debug(params['bandNames']) # Generate training data #------------------------- # what is fluxes and fluxes variance fluxes, fluxesVar = np.zeros((numObjects, numB)), np.zeros((numObjects, numB)) # loop on objects to simulate for the training and save in output training file for k in range(numObjects): #loop on number of bands for i in range(numB): trueFlux = fdata_f[k,2+i] noise = fdata_f[k,8+i] # put the DC2 data to the internal units of Delight trueFlux *= flux_multiplicative_factor noise *= flux_multiplicative_factor #fluxes[k, i] = trueFlux + noise * np.random.randn() # noisy flux fluxes[k, i] = trueFlux if fluxes[k, i]<0: #fluxes[k, i]=np.abs(noise)/10. fluxes[k, i] = trueFlux fluxesVar[k, i] = noise**2. # container for training galaxies output # at some redshift, provides the flux and its variance inside each band data = np.zeros((numObjects, 1 + len(params['training_bandOrder']))) bandIndices, bandNames, bandColumns, bandVarColumns, redshiftColumn,refBandColumn = readColumnPositions(params, prefix="training_") for ib, pf, pfv in zip(bandIndices, bandColumns, bandVarColumns): data[:, pf] = fluxes[:, ib] data[:, pfv] = fluxesVar[:, ib] data[:, redshiftColumn] = rs data[:, -1] = 0 # NO type msg="write training file {}".format(params['trainingFile']) logger.debug(msg) outputdir=os.path.dirname(params['trainingFile']) if not os.path.exists(outputdir): msg = " outputdir not existing {} then create it ".format(outputdir) logger.info(msg) os.makedirs(outputdir) np.savetxt(params['trainingFile'], data) #--- def convertDESCcatTargetFile(configfilename,desctargetcatalogfile,flag_filter=True,snr_cut=5): """ convertDESCcatTargetFile(configfilename,desctargetcatalogfile,flag_filter=True,snr_cut) Convert files in ascii format to be used by Delight input args: - configfilename : Delight configuration file containingg path for output files (flux variances and redshifts) - desctargetcatalogfile : target file provided by RAIL (hdf5 format) - flag_filter_ : Activate filtering on validation data - snr_cut: Cut on flux SNR in validation data output : - the Delight target file which path is in configuration file :return: nothing """ logger.info("--- Convert DESC target catalogs ---") if FLAG_CONVERTFLUX_TODELIGHTUNIT: flux_multiplicative_factor = 2.22e10 else: flux_multiplicative_factor = 1 # Generate Target data : procedure similar to the training #----------------------------------------------------------- # 1) DESC catalog file #--------------------- msg = "read DESC hdf5 validation file {} ".format(desctargetcatalogfile) logger.debug(msg) f = io.readHdf5ToDict(desctargetcatalogfile, groupname='photometry') # produce a numpy array magdata = group_entries(f) # remember the number of entries Nin = magdata.shape[0] msg = "Number of objects = {} , in validation dataset".format(Nin) logger.debug(msg) # filter bad data # keep indexes to filter data with bad magnitudes if flag_filter: indexes_bad_mag = filter_mag_entries(magdata) # magdata_f = np.delete(magdata, indexes_bad_mag, axis=0) magdata_f = magdata # filtering will be done later else: indexes_bad_mag = np.array([]) magdata_f = magdata Nbadmag = len(indexes_bad_mag) msg = "Number of objects with bad magnitudes = {} , in validation dataset".format(Nbadmag) logger.debug(msg) # convert mag to fluxes fdata = mag_to_flux(magdata_f) # keep indexes to filter data with bad SNR if flag_filter: indexes_bad_snr = filter_flux_entries(fdata, nsig=snr_cut) fdata_f = fdata # fdata_f = np.delete(fdata, indexes_bad, axis=0) # magdata_f = np.delete(magdata_f, indexes_bad, axis=0) else: fdata_f = fdata indexes_bad_snr = np.array([]) Nbadsnr = len(indexes_bad_snr) msg = "Number of objects with bad SNR = {} , in validation dataset".format(Nbadsnr) logger.debug(msg) # make union of indexes (unique id) before removing them for Delight idxToRemove = reduce(np.union1d, (indexes_bad_mag, indexes_bad_snr)) NtoRemove = len(idxToRemove) msg = "Number of objects filtered out = {} , in validation dataset".format(NtoRemove) logger.debug(msg) # fdata_f contains the fluxes and errors to be send to Delight # indexes of full input dataset idxInitial = np.arange(Nin) if NtoRemove > 0: fdata_f = np.delete(fdata_f, idxToRemove, axis=0) idxFinal = np.delete(idxInitial, idxToRemove, axis=0) else: idxFinal = idxInitial Nkept = len(idxFinal) msg = "Number of objects kept = {} , in validation dataset".format(Nkept) logger.debug(msg) gid = fdata_f[:, 0] rs = fdata_f[:, 1] # 2) parameter file #------------------- params = parseParamFile(configfilename, verbose=False, catFilesNeeded=False) numB = len(params['bandNames']) numObjects = len(gid) msg = "get {} objects ".format(numObjects) logger.debug(msg) logger.debug(params['bandNames']) # 3) Generate target data #------------------------ numObjects = len(gid) msg = "get {} objects ".format(numObjects) logger.debug(msg) fluxes, fluxesVar = np.zeros((numObjects, numB)), np.zeros((numObjects, numB)) # loop on objects in target files for k in range(numObjects): # loop on bands for i in range(numB): # compute the flux in that band at the redshift trueFlux = fdata_f[k, 2 + i] noise = fdata_f[k, 8 + i] # put the DC2 data to the internal units of Delight trueFlux *= flux_multiplicative_factor noise *= flux_multiplicative_factor #fluxes[k, i] = trueFlux + noise * np.random.randn() fluxes[k, i] = trueFlux if fluxes[k, i]<0: #fluxes[k, i]=np.abs(noise)/10. fluxes[k, i] = trueFlux fluxesVar[k, i] = noise**2 data = np.zeros((numObjects, 1 + len(params['target_bandOrder']))) bandIndices, bandNames, bandColumns, bandVarColumns, redshiftColumn,refBandColumn = readColumnPositions(params, prefix="target_") for ib, pf, pfv in zip(bandIndices, bandColumns, bandVarColumns): data[:, pf] = fluxes[:, ib] data[:, pfv] = fluxesVar[:, ib] data[:, redshiftColumn] = rs data[:, -1] = 0 # NO TYPE msg = "write file {}".format(os.path.basename(params['targetFile'])) logger.debug(msg) msg = "write target file {}".format(params['targetFile']) logger.debug(msg) outputdir = os.path.dirname(params['targetFile']) if not os.path.exists(outputdir): msg = " outputdir not existing {} then create it ".format(outputdir) logger.info(msg) os.makedirs(outputdir) np.savetxt(params['targetFile'], data) if __name__ == "__main__": # pragma: no cover # execute only if run as a script msg="Start convertDESCcat.py" logger.info(msg) logger.info("--- convert DESC catalogs ---") if len(sys.argv) < 4: raise Exception('Please provide a parameter file and the training and validation and catalog files') convertDESCcat(sys.argv[1],sys.argv[2],sys.argv[3])
30.998995
193
0.618953
3,785
30,844
4.92074
0.084544
0.031141
0.03157
0.024161
0.847517
0.824698
0.808376
0.795007
0.777933
0.777933
0
0.008314
0.25522
30,844
994
194
31.030181
0.802455
0.489171
0
0.69
0
0.003333
0.126513
0.002993
0
0
0
0
0
1
0.023333
false
0
0.03
0
0.07
0
0
0
0
null
0
0
0
1
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
6
15ab521643177805667c3b28ddd62d5b0fd9c70f
31
py
Python
mygtestabcde/__init__.py
Adriengith/mygtestabcde
10a4939290758dbfff923ed4c8705e6729492313
[ "MIT" ]
null
null
null
mygtestabcde/__init__.py
Adriengith/mygtestabcde
10a4939290758dbfff923ed4c8705e6729492313
[ "MIT" ]
null
null
null
mygtestabcde/__init__.py
Adriengith/mygtestabcde
10a4939290758dbfff923ed4c8705e6729492313
[ "MIT" ]
null
null
null
from mygtestabcde.Ml import Ml
15.5
30
0.83871
5
31
5.2
0.8
0
0
0
0
0
0
0
0
0
0
0
0.129032
31
1
31
31
0.962963
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
1
0
0
6
eceb0bfce03b700e6aa0ed99eb55a90a822590dc
30
py
Python
src/test/__init__.py
caveman1234/tpython-kinter
159879c7c2dcb7f1af1876fe3b76a3466e3ac7b3
[ "MIT" ]
null
null
null
src/test/__init__.py
caveman1234/tpython-kinter
159879c7c2dcb7f1af1876fe3b76a3466e3ac7b3
[ "MIT" ]
null
null
null
src/test/__init__.py
caveman1234/tpython-kinter
159879c7c2dcb7f1af1876fe3b76a3466e3ac7b3
[ "MIT" ]
null
null
null
from src.test.test import func
30
30
0.833333
6
30
4.166667
0.833333
0
0
0
0
0
0
0
0
0
0
0
0.1
30
1
30
30
0.925926
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
1
0
0
6
bf17db4529599b0629e22acadb01d724fb0441ac
504
py
Python
vulture-whitelist.py
lschmelzeisen/wikidata-history-analyzer
8673639b61839d2dca271fbbaf2feb8563b75f2d
[ "ECL-2.0", "Apache-2.0" ]
6
2021-06-10T09:26:44.000Z
2021-07-07T13:49:00.000Z
vulture-whitelist.py
lschmelzeisen/wikidated
299c65b99008a7131a580b21067fab66ac0d8fc0
[ "ECL-2.0", "Apache-2.0" ]
null
null
null
vulture-whitelist.py
lschmelzeisen/wikidated
299c65b99008a7131a580b21067fab66ac0d8fc0
[ "ECL-2.0", "Apache-2.0" ]
null
null
null
_.error_on_external_run # unused attribute (/home/lschmelzeisen/Repositories/wikidated/noxfile.py:22) _.reuse_existing_virtualenvs # unused attribute (/home/lschmelzeisen/Repositories/wikidated/noxfile.py:23) _.stop_on_first_error # unused attribute (/home/lschmelzeisen/Repositories/wikidated/noxfile.py:24) test # unused function (/home/lschmelzeisen/Repositories/wikidated/noxfile.py:44) _.isLoggable # unused method (/home/lschmelzeisen/Repositories/wikidated/src/wikidated/_jvm_manager.py:100)
84
108
0.829365
61
504
6.622951
0.47541
0.210396
0.358911
0.470297
0.576733
0.576733
0.460396
0.460396
0
0
0
0.023207
0.059524
504
5
109
100.8
0.829114
0.78373
0
0
0
0
0
0
0
0
0
0
0
1
0
true
0
0
0
0
0
0
0
0
null
1
1
1
0
0
0
0
0
0
0
0
0
0
1
0
1
0
0
0
0
0
0
0
0
null
0
0
0
0
0
0
1
0
0
0
0
0
0
6
bf321f31198cefe44778b98181074b618e168ba2
44
py
Python
tlxzoo/module/bert/__init__.py
tensorlayer/TLXZoo
8747c090825a6c0f6cd9239b281bfe56852fe2fb
[ "Apache-2.0" ]
11
2022-01-14T07:31:10.000Z
2022-01-26T08:36:51.000Z
tlxzoo/module/bert/__init__.py
tensorlayer/TLXZoo
8747c090825a6c0f6cd9239b281bfe56852fe2fb
[ "Apache-2.0" ]
null
null
null
tlxzoo/module/bert/__init__.py
tensorlayer/TLXZoo
8747c090825a6c0f6cd9239b281bfe56852fe2fb
[ "Apache-2.0" ]
6
2022-01-20T10:15:51.000Z
2022-01-25T04:58:41.000Z
from .bert import * from .transform import *
22
24
0.75
6
44
5.5
0.666667
0
0
0
0
0
0
0
0
0
0
0
0.159091
44
2
24
22
0.891892
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
1
0
0
6
bd61433695a8b48c3fc94618ec7d4b7023150061
366
py
Python
jivago/wsgi/request/streaming_request_body.py
keotl/jivago
892dfb0cae773e36245083c3e56f0f8523145523
[ "MIT" ]
12
2018-03-19T20:57:44.000Z
2020-01-27T14:11:24.000Z
jivago/wsgi/request/streaming_request_body.py
keotl/jivago
892dfb0cae773e36245083c3e56f0f8523145523
[ "MIT" ]
73
2018-04-20T22:26:00.000Z
2021-12-01T14:17:37.000Z
jivago/wsgi/request/streaming_request_body.py
keotl/jivago
892dfb0cae773e36245083c3e56f0f8523145523
[ "MIT" ]
1
2019-02-28T13:33:45.000Z
2019-02-28T13:33:45.000Z
import io class StreamingRequestBody(object): def __init__(self, content: io.RawIOBase): self.content = content def read(self, n: int = 1) -> bytes: return self.content.read(n) def readall(self) -> bytes: return self.content.readall() def readinto(self, out: bytearray) -> int: return self.content.readinto(out)
21.529412
46
0.639344
45
366
5.111111
0.444444
0.23913
0.221739
0.191304
0
0
0
0
0
0
0
0.00361
0.243169
366
16
47
22.875
0.826715
0
0
0
0
0
0
0
0
0
0
0
0
1
0.4
false
0
0.1
0.3
0.9
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
1
0
0
0
1
1
0
0
6
bd8ddd013f4601ae6fab0ec607f64af5cfc5b0c1
156
py
Python
backend/python_service/service.py
tuilagio/amos2021ws07-nft-development
10e52a1186401e2b27a3d7e4c12667f8e39d654d
[ "MIT" ]
null
null
null
backend/python_service/service.py
tuilagio/amos2021ws07-nft-development
10e52a1186401e2b27a3d7e4c12667f8e39d654d
[ "MIT" ]
null
null
null
backend/python_service/service.py
tuilagio/amos2021ws07-nft-development
10e52a1186401e2b27a3d7e4c12667f8e39d654d
[ "MIT" ]
null
null
null
# SPDX-License-Identifier: MIT # SPDX-FileCopyrightText: 2021 Felix Steinkohl <steinkohl@campus.tu-berlin.de> def hello_world(): return "hello world"
22.285714
78
0.75641
20
156
5.85
0.8
0.17094
0
0
0
0
0
0
0
0
0
0.029412
0.128205
156
6
79
26
0.830882
0.673077
0
0
0
0
0.229167
0
0
0
0
0
0
1
0.5
true
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
1
0
0
1
1
0
0
6