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 |
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
72762023f4b83c0c94c27310981c37e838797c57
| 156
|
py
|
Python
|
tests/book/ch07/__init__.py
|
xchaoinfo/pyhanlp
|
d61829a7aa35965e34ca0e220ee7f83bd3e8c5ed
|
[
"Apache-2.0"
] | 2,792
|
2018-03-19T10:24:23.000Z
|
2022-03-29T07:46:53.000Z
|
pyhanlp-master/tests/book/ch07/__init__.py
|
tianmingl/maincode
|
724c60d5281ba3911ca065d9e144bb1b09e8257f
|
[
"MIT"
] | 50
|
2018-03-19T11:08:37.000Z
|
2022-01-11T16:34:00.000Z
|
pyhanlp-master/tests/book/ch07/__init__.py
|
tianmingl/maincode
|
724c60d5281ba3911ca065d9e144bb1b09e8257f
|
[
"MIT"
] | 802
|
2018-03-19T11:08:49.000Z
|
2022-03-22T07:20:26.000Z
|
# -*- coding:utf-8 -*-
# Author:hankcs
# Date: 2018-07-04 17:26
# 《自然语言处理入门》第 7 章 词性标注
# 配套书籍:http://nlp.hankcs.com/book.php
# 讨论答疑:https://bbs.hankcs.com/
| 22.285714
| 37
| 0.647436
| 28
| 156
| 3.607143
| 0.892857
| 0.178218
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0.10219
| 0.121795
| 156
| 6
| 38
| 26
| 0.635037
| 0.916667
| 0
| null | 0
| null | 0
| 0
| null | 0
| 0
| 0
| null | 1
| null | true
| 0
| 0
| null | null | null | 1
| 0
| 0
| null | 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| 0
| 0
| 1
| 0
| 0
| 0
| 0
| 0
| 0
| null | 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| 0
| 0
| 0
| 0
|
0
| 4
|
728543b4b45d729ce806d1524c285959b76acd5a
| 267
|
py
|
Python
|
censys/search/v1/__init__.py
|
snowgears/censys-python
|
9ee3e090ef3e47c6c6a768d7fe4412509b3d274f
|
[
"Apache-2.0"
] | 230
|
2017-09-15T22:18:52.000Z
|
2022-03-31T23:50:27.000Z
|
censys/search/v1/__init__.py
|
snowgears/censys-python
|
9ee3e090ef3e47c6c6a768d7fe4412509b3d274f
|
[
"Apache-2.0"
] | 83
|
2017-10-02T04:51:53.000Z
|
2022-03-29T12:08:41.000Z
|
censys/search/v1/__init__.py
|
snowgears/censys-python
|
9ee3e090ef3e47c6c6a768d7fe4412509b3d274f
|
[
"Apache-2.0"
] | 60
|
2017-11-19T17:25:58.000Z
|
2022-03-25T06:21:51.000Z
|
"""Interact with the Censys Search v1 APIs."""
from .certificates import CensysCertificates
from .data import CensysData
from .ipv4 import CensysIPv4
from .websites import CensysWebsites
__all__ = ["CensysCertificates", "CensysData", "CensysIPv4", "CensysWebsites"]
| 33.375
| 78
| 0.794007
| 28
| 267
| 7.428571
| 0.642857
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0.016878
| 0.11236
| 267
| 7
| 79
| 38.142857
| 0.860759
| 0.149813
| 0
| 0
| 0
| 0
| 0.235294
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| false
| 0
| 0.8
| 0
| 0.8
| 0
| 1
| 0
| 0
| null | 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| null | 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| 1
| 0
|
0
| 4
|
72a1c88470f7d6e163b55ce9004d445a3eb9b60c
| 137
|
py
|
Python
|
annotator/tests/__init__.py
|
nickstenning/annotator-store-py
|
f7851efcda3f4451deb4b741fcc40796cbb46f74
|
[
"MIT"
] | 6
|
2015-01-21T19:55:37.000Z
|
2021-07-07T10:23:16.000Z
|
annotator/tests/__init__.py
|
nickstenning/annotator-store-py
|
f7851efcda3f4451deb4b741fcc40796cbb46f74
|
[
"MIT"
] | null | null | null |
annotator/tests/__init__.py
|
nickstenning/annotator-store-py
|
f7851efcda3f4451deb4b741fcc40796cbb46f74
|
[
"MIT"
] | 1
|
2019-02-25T01:15:14.000Z
|
2019-02-25T01:15:14.000Z
|
import os
import annotator.model as model
# Use in-memory database for testing
model.configure('sqlite:///:memory:')
model.rebuilddb()
| 17.125
| 37
| 0.759124
| 19
| 137
| 5.473684
| 0.736842
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0.116788
| 137
| 7
| 38
| 19.571429
| 0.859504
| 0.248175
| 0
| 0
| 0
| 0
| 0.18
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| true
| 0
| 0.5
| 0
| 0.5
| 0
| 1
| 0
| 0
| null | 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| null | 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| 1
| 0
| 0
| 0
|
0
| 4
|
72b14094f931c3dda1080aae55a2ea02a8e1a940
| 200
|
py
|
Python
|
extra-hooks/hook-soundfile.py
|
FilthyFrankTheGoanimator/Voice
|
0bf3570bd6b376c936ea9f04fc15f129e738b168
|
[
"BSD-3-Clause"
] | 556
|
2021-03-10T19:09:47.000Z
|
2022-03-30T13:45:13.000Z
|
extra-hooks/hook-soundfile.py
|
FilthyFrankTheGoanimator/Voice
|
0bf3570bd6b376c936ea9f04fc15f129e738b168
|
[
"BSD-3-Clause"
] | 100
|
2021-03-14T12:35:46.000Z
|
2022-03-26T07:57:42.000Z
|
extra-hooks/hook-soundfile.py
|
FilthyFrankTheGoanimator/Voice
|
0bf3570bd6b376c936ea9f04fc15f129e738b168
|
[
"BSD-3-Clause"
] | 84
|
2021-03-16T21:44:06.000Z
|
2022-03-30T21:58:28.000Z
|
import os
from PyInstaller.utils.hooks import get_package_paths
sfp = get_package_paths("soundfile")
bins = os.path.join(sfp[0], "_soundfile_data")
datas = [(bins, "_soundfile_data")]
binaries = []
| 22.222222
| 53
| 0.75
| 28
| 200
| 5.071429
| 0.642857
| 0.140845
| 0.211268
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0.005618
| 0.11
| 200
| 8
| 54
| 25
| 0.792135
| 0
| 0
| 0
| 0
| 0
| 0.195
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| false
| 0
| 0.333333
| 0
| 0.333333
| 0
| 1
| 0
| 0
| null | 0
| 1
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| null | 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| 0
| 0
|
0
| 4
|
72dca0b50016ce604f2019128489cc7d9fc50492
| 49
|
py
|
Python
|
PYTHON-CURSO EM VIDEO/Exercicio-Modulo.py
|
JaumVitor/HOMEWORK-PYTHON
|
aff564ac61802c7417d7280a73c1ed4a98978ed3
|
[
"Apache-2.0"
] | null | null | null |
PYTHON-CURSO EM VIDEO/Exercicio-Modulo.py
|
JaumVitor/HOMEWORK-PYTHON
|
aff564ac61802c7417d7280a73c1ed4a98978ed3
|
[
"Apache-2.0"
] | null | null | null |
PYTHON-CURSO EM VIDEO/Exercicio-Modulo.py
|
JaumVitor/HOMEWORK-PYTHON
|
aff564ac61802c7417d7280a73c1ed4a98978ed3
|
[
"Apache-2.0"
] | null | null | null |
import random
n = random.randint(0,5)
print (n)
| 9.8
| 23
| 0.693878
| 9
| 49
| 3.777778
| 0.777778
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0.04878
| 0.163265
| 49
| 4
| 24
| 12.25
| 0.780488
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| false
| 0
| 0.333333
| 0
| 0.333333
| 0.333333
| 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
| 0
| 0
| 1
| 0
| 0
| 0
|
0
| 4
|
f41409bb7474281eb2878840ff1c10c2609435cd
| 1,778
|
py
|
Python
|
karp5/tests/unit_tests/server/translator/test_validatejson.py
|
spraakbanken/karp-backend-v5
|
bfca9d0f29a1243ee8d817c6a7db8b30a7da1097
|
[
"MIT"
] | 4
|
2018-01-09T10:20:22.000Z
|
2019-11-21T12:26:56.000Z
|
karp5/tests/unit_tests/server/translator/test_validatejson.py
|
spraakbanken/karp-backend-v5
|
bfca9d0f29a1243ee8d817c6a7db8b30a7da1097
|
[
"MIT"
] | 44
|
2018-03-23T13:59:13.000Z
|
2022-03-29T06:03:17.000Z
|
karp5/tests/unit_tests/server/translator/test_validatejson.py
|
spraakbanken/karp-backend-v5
|
bfca9d0f29a1243ee8d817c6a7db8b30a7da1097
|
[
"MIT"
] | 2
|
2018-01-07T12:08:32.000Z
|
2019-08-21T08:05:17.000Z
|
from unittest import mock
import pytest
from karp5.server.translator.validatejson import validate_json
def test_validate_json_escapes_correct():
lexicon_id = "Test"
doc = {"field": "&", "string": "o\u0308"}
expected = {"field": "&", "string": "ö"}
validate_json(doc, lexicon_id)
assert doc == expected
def test_validate_json_respect_no_escape_but_normalizes_string():
lexicon_id = "test"
doc = {"field": "&", "string": "o\u0308"}
expected = {"field": "&", "string": "ö"}
with mock.patch(
"karp5.server.translator.validatejson.conf_mgr", lexicons={"test": {"no_escape": True}}
):
validate_json(doc, lexicon_id)
assert doc == expected
@pytest.mark.parametrize(
"doc, expected",
[
({"xml": "<tag>"}, {"xml": "<tag>"}),
({"xml": "[<tag>]"}, {"xml": "[<tag>]"}),
({"xml": {"text": "<tag>"}}, {"xml": {"text": "<tag>"}}),
],
)
def test_validate_json_handles_xml_correct_with_escaping(doc, expected):
lexicon_id = "test"
with mock.patch(
"karp5.server.translator.validatejson.conf_mgr", lexicons={"test": {"usedtags": ["tag"]}}
):
validate_json(doc, lexicon_id)
assert doc == expected
@pytest.mark.parametrize(
"doc, expected",
[
({"xml": "<tag>"}, {"xml": "<tag>"}),
({"xml": "[<tag>]"}, {"xml": "[<tag>]"}),
({"xml": {"text": "<tag>"}}, {"xml": {"text": "<tag>"}}),
],
)
def test_validate_json_handles_xml_correct_without_escaping(doc, expected):
lexicon_id = "test"
with mock.patch(
"karp5.server.translator.validatejson.conf_mgr",
lexicons={"test": {"no_escape": True, "usedtags": ["tag"]}},
):
validate_json(doc, lexicon_id)
assert doc == expected
| 26.147059
| 97
| 0.582677
| 198
| 1,778
| 5.010101
| 0.242424
| 0.060484
| 0.072581
| 0.072581
| 0.785282
| 0.785282
| 0.785282
| 0.712702
| 0.671371
| 0.671371
| 0
| 0.008493
| 0.205287
| 1,778
| 67
| 98
| 26.537313
| 0.69356
| 0
| 0
| 0.591837
| 0
| 0
| 0.237908
| 0.075928
| 0
| 0
| 0
| 0
| 0.081633
| 1
| 0.081633
| false
| 0
| 0.061224
| 0
| 0.142857
| 0
| 0
| 0
| 0
| null | 0
| 0
| 0
| 0
| 1
| 1
| 1
| 0
| 1
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| null | 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
|
0
| 4
|
f41a7fc579508437aab43fd7e058c8d07272f3e0
| 151
|
py
|
Python
|
tableaurest/__main__.py
|
levikanwischer/tableaurest
|
089f077521c27461850eb74661a58b4657748320
|
[
"MIT"
] | null | null | null |
tableaurest/__main__.py
|
levikanwischer/tableaurest
|
089f077521c27461850eb74661a58b4657748320
|
[
"MIT"
] | null | null | null |
tableaurest/__main__.py
|
levikanwischer/tableaurest
|
089f077521c27461850eb74661a58b4657748320
|
[
"MIT"
] | null | null | null |
# -*- coding: utf-8 -*-
"""Tableau REST API interface with misc utilities."""
from tableaurest import cli
if __name__ == '__main__':
cli.main()
| 16.777778
| 53
| 0.655629
| 19
| 151
| 4.789474
| 0.894737
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0.00813
| 0.18543
| 151
| 8
| 54
| 18.875
| 0.731707
| 0.463576
| 0
| 0
| 0
| 0
| 0.106667
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| true
| 0
| 0.333333
| 0
| 0.333333
| 0
| 1
| 0
| 0
| null | 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| null | 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| 1
| 0
| 0
| 0
|
0
| 4
|
f445687c6394f6c1172723b5a889ae2af01f540a
| 332
|
py
|
Python
|
string/test2.py
|
Vayne-Lover/Python
|
79cfe3d6971a7901d420ba5a7f52bf4c68f6a1c1
|
[
"Apache-2.0"
] | 1
|
2016-07-14T06:16:58.000Z
|
2016-07-14T06:16:58.000Z
|
string/test2.py
|
Vayne-Lover/Python
|
79cfe3d6971a7901d420ba5a7f52bf4c68f6a1c1
|
[
"Apache-2.0"
] | null | null | null |
string/test2.py
|
Vayne-Lover/Python
|
79cfe3d6971a7901d420ba5a7f52bf4c68f6a1c1
|
[
"Apache-2.0"
] | null | null | null |
#!/usr/local/bin/python
width=input('Please input width: ')
price_width=10
item_width=width-price_width
header='%-*s%*s'
format='%-*s%*.2f'
print width*'='
print header %(item_width,'Item',price_width,'Price')
print width*'-'
print format%(item_width,'Apple',price_width,0.442)
print format%(item_width,'Pears',price_width,0.367)
| 23.714286
| 53
| 0.728916
| 53
| 332
| 4.396226
| 0.377358
| 0.214592
| 0.128755
| 0.171674
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0.035484
| 0.066265
| 332
| 13
| 54
| 25.538462
| 0.716129
| 0.066265
| 0
| 0
| 0
| 0
| 0.184466
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| null | null | 0
| 0
| null | null | 0.5
| 0
| 0
| 0
| null | 1
| 0
| 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
| 1
| 0
| 0
| 0
| 0
| 0
| 0
| 1
|
0
| 4
|
f4590263896550efdd8153b59d7d0b9f66fad57a
| 2,512
|
py
|
Python
|
venv/Lib/site-packages/pyqt6_plugins/tests/testbuttonplugin.py
|
Armageddon-15/pixivpy
|
2a4d8c9ebdb28efeceabe87e6f9950cb20a83aed
|
[
"Unlicense"
] | null | null | null |
venv/Lib/site-packages/pyqt6_plugins/tests/testbuttonplugin.py
|
Armageddon-15/pixivpy
|
2a4d8c9ebdb28efeceabe87e6f9950cb20a83aed
|
[
"Unlicense"
] | 20
|
2021-05-03T18:02:23.000Z
|
2022-03-12T12:01:04.000Z
|
Lib/site-packages/pyqt5_plugins/tests/testbuttonplugin.py
|
fochoao/cpython
|
3dc84b260e5bced65ebc2c45c40c8fa65f9b5aa9
|
[
"bzip2-1.0.6",
"0BSD"
] | 1
|
2022-02-21T03:09:29.000Z
|
2022-02-21T03:09:29.000Z
|
# TODO: CAMPid 0970432108721340872130742130870874321
import importlib
import pkg_resources
major = None
def import_it(*segments):
global major
if major is None:
options = [5, 6]
else:
options = [major]
error = None
for major in options:
# TODO: this is not great but the plugin gets imported directly rather
# than as part of the module so... could add some code here on
# build or something. but yeah, all kind of a mess. require an
# env var be set, etc.
try:
m = {
"pyqt_tools": "pyqt{major}_tools".format(major=major),
"pyqt_plugins": "pyqt{major}_plugins".format(major=major),
"qt_tools": "qt{major}_tools".format(major=major),
"qt_applications": "qt{major}_applications".format(major=major),
"PyQt": "PyQt{major}".format(major=major),
}
majored = [m[segments[0]], *segments[1:]]
return importlib.import_module(".".join(majored))
except ModuleNotFoundError as e:
if error is None:
error = e
continue
else:
raise e from error
qt_tools = import_it("qt_tools")
QtGui = import_it("PyQt", "QtGui")
QtDesigner = import_it("PyQt", "QtDesigner")
pyqt_plugins = import_it("pyqt_plugins")
import_it("pyqt_plugins", "tests", "testbutton")
class TestButtonPlugin(QtDesigner.QPyDesignerCustomWidgetPlugin):
# https://wiki.python.org/moin/PyQt/Using_Python_Custom_Widgets_in_Qt_Designer
def __init__(self, parent=None):
super().__init__(parent=parent)
self.initialized = False
def initialize(self, core):
if self.initialized:
return
self.initialized = True
def isInitialized(self):
return self.initialized
def createWidget(self, parent):
return pyqt_plugins.tests.testbutton.TestButton(parent)
def name(self):
return pyqt_plugins.tests.testbutton.TestButton.__name__
def group(self):
return 'pyqt{}-tools'.format(major)
def icon(self):
return QtGui.QIcon()
def toolTip(self):
return 'pyqt{}-tools Test Button Tool Tip'.format(major)
def whatsThis(self):
return 'pyqt{}-tools Test Button What\'s this'.format(major)
def isContainer(self):
return False
def includeFile(self):
return 'pyqt{}_plugins.tests.testbutton'.format(major)
| 28.545455
| 82
| 0.618631
| 291
| 2,512
| 5.195876
| 0.408935
| 0.065476
| 0.05291
| 0.068783
| 0.187169
| 0.152778
| 0
| 0
| 0
| 0
| 0
| 0.022527
| 0.275478
| 2,512
| 87
| 83
| 28.873563
| 0.808242
| 0.143312
| 0
| 0.034483
| 0
| 0
| 0.144522
| 0.024709
| 0
| 0
| 0
| 0.011494
| 0
| 1
| 0.206897
| false
| 0
| 0.155172
| 0.155172
| 0.568966
| 0
| 0
| 0
| 0
| null | 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| null | 0
| 0
| 1
| 0
| 0
| 1
| 0
| 0
| 0
| 1
| 1
| 0
|
0
| 4
|
be49488283466d31bdbc4f8c659f53df0745308c
| 935
|
py
|
Python
|
lgp/factory/alfred_factory.py
|
dingmyu/hlsm
|
628702789d910f745c74e738efbdd65f0fdb654b
|
[
"BSD-3-Clause"
] | null | null | null |
lgp/factory/alfred_factory.py
|
dingmyu/hlsm
|
628702789d910f745c74e738efbdd65f0fdb654b
|
[
"BSD-3-Clause"
] | null | null | null |
lgp/factory/alfred_factory.py
|
dingmyu/hlsm
|
628702789d910f745c74e738efbdd65f0fdb654b
|
[
"BSD-3-Clause"
] | null | null | null |
from typing import Dict
from lgp.abcd.factory import Factory
from lgp.env.alfred.alfred_env import AlfredEnv
from lgp.agents.agents import get_agent
from lgp.models.alfred.hlsm.hlsm_model_factory import HlsmModelFactory
from lgp.parameters import Hyperparams
class AlfredFactory(Factory):
def __init__(self):
super().__init__()
def get_model_factory(self, setup: Dict, hparams : Hyperparams):
# TODO support picking between multiple models if needed
return HlsmModelFactory(hparams)
def get_environment(self, setup : Dict, task_num_range=None):
# TODO: Retrieve train/dev/test split based on setup
device = setup.get("device", "cpu")
env = AlfredEnv(device=device, setup=setup["env_setup"])
env.set_task_num_range(task_num_range)
return env
def get_agent(self, setup : Hyperparams, hparams : Hyperparams):
return get_agent(setup, hparams)
| 32.241379
| 70
| 0.727273
| 123
| 935
| 5.325203
| 0.406504
| 0.053435
| 0.054962
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0.191444
| 935
| 28
| 71
| 33.392857
| 0.866402
| 0.112299
| 0
| 0
| 0
| 0
| 0.021792
| 0
| 0
| 0
| 0
| 0.035714
| 0
| 1
| 0.222222
| false
| 0
| 0.333333
| 0.111111
| 0.777778
| 0
| 0
| 0
| 0
| null | 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| null | 0
| 0
| 1
| 0
| 0
| 1
| 0
| 0
| 1
| 1
| 0
| 0
|
0
| 4
|
be57ba2ab2d1edd6f6138462da1ac9bdd580b0cf
| 208
|
py
|
Python
|
websauna/system/devop/scripts/tweens.py
|
maikroeder/websauna
|
fd266cf5e4761cd4c1f3e33be47ad8358b4c6afa
|
[
"CNRI-Python"
] | null | null | null |
websauna/system/devop/scripts/tweens.py
|
maikroeder/websauna
|
fd266cf5e4761cd4c1f3e33be47ad8358b4c6afa
|
[
"CNRI-Python"
] | null | null | null |
websauna/system/devop/scripts/tweens.py
|
maikroeder/websauna
|
fd266cf5e4761cd4c1f3e33be47ad8358b4c6afa
|
[
"CNRI-Python"
] | 1
|
2021-04-15T17:35:57.000Z
|
2021-04-15T17:35:57.000Z
|
import sys
from websauna.utils.configincluder import monkey_patch_paster_config_parser
from pyramid.scripts import ptweens
monkey_patch_paster_config_parser()
def main():
sys.exit(ptweens.main() or 0)
| 20.8
| 75
| 0.822115
| 30
| 208
| 5.433333
| 0.633333
| 0.134969
| 0.208589
| 0.282209
| 0.355828
| 0
| 0
| 0
| 0
| 0
| 0
| 0.005405
| 0.110577
| 208
| 10
| 76
| 20.8
| 0.875676
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0.166667
| true
| 0
| 0.5
| 0
| 0.666667
| 0
| 0
| 0
| 0
| null | 0
| 1
| 1
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| null | 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| 1
| 0
| 0
| 0
|
0
| 4
|
be5cf4f8ce415b2068d36c701d68bc53433f7653
| 66
|
py
|
Python
|
3rdparty/python/pylint/main.py
|
NunoEdgarGFlowHub/heron
|
53380553d79a9473184821e5864aedfe9f45f290
|
[
"Apache-2.0"
] | 2
|
2016-07-04T07:10:31.000Z
|
2018-03-28T16:59:02.000Z
|
3rdparty/python/pylint/main.py
|
NunoEdgarGFlowHub/heron
|
53380553d79a9473184821e5864aedfe9f45f290
|
[
"Apache-2.0"
] | null | null | null |
3rdparty/python/pylint/main.py
|
NunoEdgarGFlowHub/heron
|
53380553d79a9473184821e5864aedfe9f45f290
|
[
"Apache-2.0"
] | 1
|
2019-10-02T15:23:46.000Z
|
2019-10-02T15:23:46.000Z
|
import pylint
if __name__ == '__main__':
pylint.run_pylint()
| 13.2
| 26
| 0.69697
| 8
| 66
| 4.625
| 0.75
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0.181818
| 66
| 4
| 27
| 16.5
| 0.685185
| 0
| 0
| 0
| 0
| 0
| 0.121212
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| true
| 0
| 0.333333
| 0
| 0.333333
| 0
| 1
| 0
| 0
| null | 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| null | 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| 1
| 0
| 0
| 0
|
0
| 4
|
be79b140a8e08b918cadd6887d9447eb1e80f251
| 211
|
py
|
Python
|
catkin_ws/src/spring2016/agirard/camera_stuff_agirard/include/camera_stuff_agirard/util.py
|
DiegoOrtegoP/Software
|
4a07dd2dab29db910ca2e26848fa6b53b7ab00cd
|
[
"CC-BY-2.0"
] | 12
|
2016-04-14T12:21:46.000Z
|
2021-06-18T07:51:40.000Z
|
catkin_ws/src/spring2016/agirard/camera_stuff_agirard/include/camera_stuff_agirard/util.py
|
DiegoOrtegoP/Software
|
4a07dd2dab29db910ca2e26848fa6b53b7ab00cd
|
[
"CC-BY-2.0"
] | 14
|
2017-03-03T23:33:05.000Z
|
2018-04-03T18:07:53.000Z
|
catkin_ws/src/spring2016/agirard/camera_stuff_agirard/include/camera_stuff_agirard/util.py
|
DiegoOrtegoP/Software
|
4a07dd2dab29db910ca2e26848fa6b53b7ab00cd
|
[
"CC-BY-2.0"
] | 113
|
2016-05-03T06:11:42.000Z
|
2019-06-01T14:37:38.000Z
|
# -*- coding: utf-8 -*-
"""
Created on Fri Feb 26 11:00:57 2016
@author: alex
"""
import random
def getName():
return "I'm the tools module!!"
def getStatus():
return random.choice(["happy","awesome"])
| 17.583333
| 45
| 0.630332
| 31
| 211
| 4.290323
| 0.903226
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0.075145
| 0.180095
| 211
| 12
| 45
| 17.583333
| 0.693642
| 0.345972
| 0
| 0
| 0
| 0
| 0.259542
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0.4
| true
| 0
| 0.2
| 0.4
| 1
| 0
| 0
| 0
| 0
| null | 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| null | 0
| 0
| 0
| 0
| 0
| 1
| 1
| 0
| 0
| 1
| 1
| 0
|
0
| 4
|
be937f610176c6fbf6c095361f0601136b3b6cd9
| 26,493
|
py
|
Python
|
api/v1/routers/proxmox.py
|
UCCNetsoc/cloud
|
d3f87c7868ef7615a5836a2a3ba09bfd1dffed1d
|
[
"BSD-3-Clause"
] | 9
|
2021-02-07T19:49:49.000Z
|
2021-12-05T20:52:25.000Z
|
api/v1/routers/proxmox.py
|
UCCNetsoc/admin
|
d3f87c7868ef7615a5836a2a3ba09bfd1dffed1d
|
[
"BSD-3-Clause"
] | 18
|
2020-09-07T16:04:40.000Z
|
2020-11-05T01:50:14.000Z
|
api/v1/routers/proxmox.py
|
UCCNetsoc/admin
|
d3f87c7868ef7615a5836a2a3ba09bfd1dffed1d
|
[
"BSD-3-Clause"
] | 4
|
2020-09-29T12:03:22.000Z
|
2020-10-17T21:33:16.000Z
|
import os
import time
import structlog as logging
from fastapi import APIRouter, HTTPException, BackgroundTasks, Depends, Path, Query, Response, UploadFile, File
from fastapi.responses import StreamingResponse
from pydantic import BaseModel, Field
from typing import List, Dict, Optional
from v1 import providers, templates, models, exceptions, utilities, templates
from v1.config import config
logger = logging.getLogger(__name__)
router = APIRouter()
def fancy_name(instance_type: models.proxmox.Type) -> str:
if instance_type == models.proxmox.Type.LXC:
return "Container"
elif instance_type == models.proxmox.Type.VPS:
return "VPS"
def fancy_specs(specs: models.proxmox.Specs) -> str:
return f"{specs.cores} CPU, {specs.memory}MB RAM, {specs.disk_space}GB disk space, {specs.swap}MB swap"
def ensure_active(instance: models.proxmox.Instance):
"""Throws exception saying instance must be active to perform action if instance is not active"""
if instance.active == False:
raise exceptions.rest.Error(status_code=403, detail=models.rest.Detail(
msg="Instance must be activated to perform this action"
))
def ensure_not_tos_suspended(instance: models.proxmox.Instance):
"""Throws exception saying instance must be not suspended"""
if instance.metadata.tos.suspended == True:
raise exceptions.rest.Error(status_code=403, detail=models.rest.Detail(
msg=f"Instance is suspended for Terms of Service violations ({metadata.tos.reason})"
))
@router.get(
'/traefik-config',
status_code=200,
response_model=dict,
responses={400: {"model": models.rest.Error}}
)
def get_traefik_config(
key: str = ""
):
if key != config.proxmox.network.traefik.config_key:
raise exceptions.rest.Error(status_code=403, detail=models.rest.Detail(
msg=f"invalid config key"
))
return providers.proxmox.build_traefik_config("web-secure")
@router.get(
'/{email_or_username}/{instance_type}-templates',
status_code=200,
response_model=Dict[str,models.proxmox.Template],
responses={400: {"model": models.rest.Error}}
)
def get_templates(
instance_type: models.proxmox.Type
):
return providers.proxmox.read_templates(instance_type)
@router.get(
'/{email_or_username}/{instance_type}-template/{template_id}',
status_code=200,
response_model=models.proxmox.Template,
responses={400: {"model": models.rest.Error}}
)
def get_template(
instance_type: models.proxmox.Type,
template_id: str = Path(**models.proxmox.TemplateID)
):
return providers.proxmox.read_template(instance_type, template_id)
@router.post(
'/{email_or_username}/{instance_type}-request/{hostname}',
status_code=201,
responses={400: {"model": models.rest.Error}}
)
def create_instance_request(
email_or_username: str,
instance_type: models.proxmox.Type,
detail: models.proxmox.InstanceRequestDetail,
hostname: str = Path(**models.proxmox.Hostname),
bearer_account: models.account.Account = Depends(utilities.auth.get_bearer_account)
):
resource_account = providers.accounts.find_verified_account(email_or_username)
utilities.auth.ensure_sysadmin_or_acting_on_self(bearer_account, resource_account)
# will raise exception if template doesnt exist
template = providers.proxmox.read_template(instance_type, detail.template_id)
try:
instance = providers.proxmox.read_instance_by_account(instance_type, resource_account, hostname)
raise exceptions.resource.AlreadyExists(f"Instance {hostname} already exists!")
except exceptions.resource.NotFound:
pass
serialized = models.proxmox.InstanceRequest(
exp=time.time() + 172800, # 2 days
iat=time.time(),
username=resource_account.username,
hostname=hostname,
type=instance_type,
detail=detail
).sign_serialize(config.links.jwt.private_key)
utilities.webhook.info(
f"""**{resource_account.username} ({resource_account.email}) requested an instance named `{hostname}`!**
They want **{template.metadata.title} {fancy_name(instance_type)} ({fancy_specs(template.specs)})** for the following reason: ```{detail.reason}```
To approve this request, sign in as a SysAdmin and click the following link:
{config.links.base_url}/instance-request/{resource_account.username}/{instance_type}-request/{hostname}/{serialized.token}
"""
)
# providers.email.send(
# [resource_account.email],
# f"{fancy_name(instance_type)} request '{hostname}' received",
# templates.email.netsoc.render(
# heading=f"{fancy_name(instance_type)} request '{hostname}' received",
# paragraph=
# f"""Hi {resource_account.username}!<br/><br/>
# We've received your request for a {fancy_name(instance_type)} named '{hostname}'<br/>
# We will notify you by email as soon as we have approved/denied your request<br/><br/>
# If you do not receive a response within 2-3 days, contact the SysAdmins on the UCC Netsoc Discord<br/>
# Once you make contact, they might request the information below:<br/>
# """,
# embeds=[
# { "text": serialized.token }
# ],
# ),
# "text/html"
# )
return models.rest.Info(
detail=models.rest.Detail(
msg="Instance request received, the email associated with this account will be notified as soon as the request has been approved/denied"
)
)
@router.get(
'/{email_or_username}/{instance_type}-request/{hostname}',
status_code=200,
response_model=models.proxmox.InstanceRequest
)
def get_instance_request(
email_or_username: str,
instance_type: models.proxmox.Type,
token: str,
hostname: str = Path(**models.proxmox.Hostname),
bearer_account: models.account.Account = Depends(utilities.auth.get_bearer_account)
):
resource_account = providers.accounts.find_verified_account(email_or_username)
utilities.auth.ensure_sysadmin(bearer_account)
serialized = models.jwt.Serialized(token=token)
try:
request = serialized.deserialize_verify(models.proxmox.InstanceRequest, config.links.jwt.public_key)
except Exception as e:
logger.error(f"Invalid JWT", serialized=serialized, e=e, exc_info=True)
raise exceptions.rest.Error(status_code=400, detail=models.rest.Detail(
msg="Invalid or expired request, please ask user to re-request"
))
if request.username != resource_account.username:
raise exceptions.rest.Error(status_code=400, detail=models.rest.Detail(
msg=f"Token is for a user other than {email_or_username}"
))
if request.hostname != hostname:
raise exceptions.rest.Error(status_code=400, detail=models.rest.Detail(
msg=f"Token is for a hostname other than {hostname}"
))
return request
@router.post(
'/{email_or_username}/{instance_type}-request/{hostname}/approval',
status_code=201,
responses={400: {"model": models.rest.Error}}
)
def approve_instance_request(
email_or_username: str,
instance_type: models.proxmox.Type,
token: str,
background_tasks: BackgroundTasks,
hostname: str = Path(**models.proxmox.Hostname),
bearer_account: models.account.Account = Depends(utilities.auth.get_bearer_account),
):
resource_account = providers.accounts.find_verified_account(email_or_username)
utilities.auth.ensure_sysadmin(bearer_account)
try:
providers.proxmox.read_instance_by_account(instance_type, resource_account, hostname)
raise exceptions.resource.AlreadyExists(f"Instance {hostname} already exists!")
except exceptions.resource.NotFound:
pass
serialized = models.jwt.Serialized(token=token)
try:
request = serialized.deserialize_verify(models.proxmox.InstanceRequest, config.links.jwt.public_key)
except Exception as e:
logger.error(f"Invalid JWT", serialized=serialized, e=e, exc_info=True)
raise exceptions.rest.Error(status_code=400, detail=models.rest.Detail(
msg="Invalid or expired request, please ask user to re-request"
))
if request.username != resource_account.username:
raise exceptions.rest.Error(status_code=400, detail=models.rest.Detail(
msg=f"Token is for a user other than {email_or_username}"
))
if request.hostname != hostname:
raise exceptions.rest.Error(status_code=400, detail=models.rest.Detail(
msg=f"Token is for a hostname other than {hostname}"
))
def creation_task():
try:
providers.proxmox.create_instance(
instance_type,
resource_account,
hostname,
request.detail
)
providers.email.send(
[resource_account.email],
f"{fancy_name(instance_type)} request '{hostname}' accepted!",
templates.email.netsoc.render(
heading=f"{fancy_name(instance_type)} request '{hostname}' accepted",
paragraph=
f"""Hi {resource_account.username}!<br/><br/>
We received your request for a {fancy_name(instance_type)} named '{hostname}'<br/>
We're delighted to inform you that your instance request has been granted!<br/>
For guides on how to SSH into your instance, please consult the <a style="color: white" href='https://tutorial.netsoc.co'>tutorial</a>
<br/>
"""
),
"text/html"
)
utilities.webhook.info(
f"""**{resource_account.username} ({resource_account.email})'s instance `{hostname}` was emailed about installation!**"""
)
except Exception as e:
utilities.webhook.info(
f"""**{resource_account.username} ({resource_account.email})'s instance `{hostname}` install task failed: ```{e}```!**"""
)
raise e
utilities.webhook.info(
f"""**{resource_account.username} ({resource_account.email})'s instance `{hostname}` was installed!**"""
)
utilities.webhook.info(
f"""**{resource_account.username} ({resource_account.email}) request for an instance named `{hostname}` was granted! Install job started...**"""
)
background_tasks.add_task(creation_task)
@router.post(
'/{email_or_username}/{instance_type}-request/{hostname}/denial',
status_code=201,
responses={400: {"model": models.rest.Error}}
)
def deny_instance_request(
email_or_username: str,
instance_type: models.proxmox.Type,
token: str,
request_denial: models.proxmox.InstanceRequestDenial,
hostname: str = Path(**models.proxmox.Hostname),
bearer_account: models.account.Account = Depends(utilities.auth.get_bearer_account)
):
resource_account = providers.accounts.find_verified_account(email_or_username)
utilities.auth.ensure_sysadmin(bearer_account)
serialized = models.jwt.Serialized(token=token)
try:
request = serialized.deserialize_verify(models.proxmox.InstanceRequest, config.links.jwt.public_key)
except Exception as e:
logger.error(f"Invalid JWT", serialized=serialized, e=e, exc_info=True)
raise exceptions.rest.Error(status_code=400, detail=models.rest.Detail(
msg="Invalid or expired request, please ask user to re-request"
))
if request.username != resource_account.username:
raise exceptions.rest.Error(status_code=400, detail=models.rest.Detail(
msg=f"Token is for a user other than {email_or_username}"
))
if request.hostname != hostname:
raise exceptions.rest.Error(status_code=400, detail=models.rest.Detail(
msg=f"Token is for a hostname other than {hostname}"
))
utilities.webhook.info(
f"""**{resource_account.username} ({resource_account.email}) request for a instance named `{hostname}` was denied!**
The reason given was: ```{request_denial.reason}```
"""
)
providers.email.send(
[resource_account.email],
f"{fancy_name(instance_type)} request '{hostname}' denied",
templates.email.netsoc.render(
heading=f"{fancy_name(instance_type)} request '{hostname}' denied",
paragraph=
f"""Hi {resource_account.username}!<br/><br/>
We received your request for a {fancy_name(instance_type)} named '{hostname}'<br/>
Unfortunately we've had to deny the request for now.<br/><br/>
Requests for {fancy_name(instance_type)}s are typically denied where we believe a ToS violation may occur, or that a {fancy_name(instance_type)} may not be suitable for the reason you specified<br/><br/>
The reason your request was denied is available below<br/><br/>
If you have any questions, contact the SysAdmins on the UCC Netsoc Discord<br/>
""",
embeds=[
{ "text": request_denial.reason }
]
),
"text/html"
)
utilities.webhook.info(
f"""**{resource_account.username} ({resource_account.email}) was emailed about denial!**"""
)
@router.get(
'/{email_or_username}/{instance_type}',
status_code=200,
)
def get_instances(
email_or_username: str,
instance_type: models.proxmox.Type,
bearer_account: models.account.Account = Depends(utilities.auth.get_bearer_account)
):
resource_account = providers.accounts.find_verified_account(email_or_username)
utilities.auth.ensure_sysadmin_or_acting_on_self(bearer_account, resource_account)
return providers.proxmox.read_instances_by_account(instance_type, resource_account)
@router.post(
'/{email_or_username}/{instance_type}/{hostname}/start',
status_code=201,
)
def start_instance(
email_or_username: str,
instance_type: models.proxmox.Type,
hostname: str = Path(**models.proxmox.Hostname),
bearer_account: models.account.Account = Depends(utilities.auth.get_bearer_account)
):
resource_account = providers.accounts.find_verified_account(email_or_username)
utilities.auth.ensure_sysadmin_or_acting_on_self(bearer_account, resource_account)
instance = providers.proxmox.read_instance_by_account(instance_type, resource_account, hostname)
ensure_active(instance)
providers.proxmox.start_instance(instance)
utilities.webhook.info(
f"""**{resource_account.username} ({resource_account.email}) started instance `{instance.hostname}`!**"""
)
@router.post(
'/{email_or_username}/{instance_type}/{hostname}/stop',
status_code=200,
)
def stop_instance(
email_or_username: str,
instance_type: models.proxmox.Type,
hostname: str = Path(**models.proxmox.Hostname),
bearer_account: models.account.Account = Depends(utilities.auth.get_bearer_account)
):
resource_account = providers.accounts.find_verified_account(email_or_username)
utilities.auth.ensure_sysadmin_or_acting_on_self(bearer_account, resource_account)
instance = providers.proxmox.read_instance_by_account(instance_type, resource_account, hostname)
ensure_active(instance)
providers.proxmox.stop_instance(instance)
utilities.webhook.info(
f"""**{resource_account.username} ({resource_account.email}) stopped instance `{instance.hostname}`!**"""
)
@router.post(
'/{email_or_username}/{instance_type}/{hostname}/shutdown',
status_code=200,
)
def shutdown_instance(
email_or_username: str,
instance_type: models.proxmox.Type,
hostname: str = Path(**models.proxmox.Hostname),
bearer_account: models.account.Account = Depends(utilities.auth.get_bearer_account)
):
resource_account = providers.accounts.find_verified_account(email_or_username)
utilities.auth.ensure_sysadmin_or_acting_on_self(bearer_account, resource_account)
instance = providers.proxmox.read_instance_by_account(instance_type, resource_account, hostname)
ensure_active(instance)
providers.proxmox.shutdown_instance(instance)
utilities.webhook.info(
f"""**{resource_account.username} ({resource_account.email}) shutdown instance `{instance.hostname}`!**"""
)
@router.post(
'/{email_or_username}/{instance_type}/{hostname}/respec-request',
status_code=201,
)
def request_instance_respec(
email_or_username: str,
instance_type: models.proxmox.Type,
respec: models.proxmox.RespecRequest,
hostname: str = Path(**models.proxmox.Hostname),
bearer_account: models.account.Account = Depends(utilities.auth.get_bearer_account)
):
resource_account = providers.accounts.find_verified_account(email_or_username)
utilities.auth.ensure_sysadmin_or_acting_on_self(bearer_account, resource_account)
instance = providers.proxmox.read_instance_by_account(instance_type, resource_account, hostname)
ensure_active(instance)
utilities.webhook.info(
f"""**{resource_account.username} ({resource_account.email}) requested new specifications for `{instance.hostname}`!**```{respec.details}```"""
)
@router.post(
'/{email_or_username}/{instance_type}/{hostname}/active',
status_code=201,
)
def mark_instance_active(
email_or_username: str,
instance_type: models.proxmox.Type,
hostname: str = Path(**models.proxmox.Hostname),
bearer_account: models.account.Account = Depends(utilities.auth.get_bearer_account)
):
resource_account = providers.accounts.find_verified_account(email_or_username)
utilities.auth.ensure_sysadmin_or_acting_on_self(bearer_account, resource_account)
instance = providers.proxmox.read_instance_by_account(instance_type, resource_account, hostname)
ensure_not_tos_suspended(instance)
providers.proxmox.mark_instance_active(instance)
utilities.webhook.info(
f"""**{resource_account.username} ({resource_account.email}) marked instance `{instance.hostname}` active!**"""
)
@router.delete(
'/{email_or_username}/{instance_type}/{hostname}',
status_code=200,
)
def delete_instance(
email_or_username: str,
instance_type: models.proxmox.Type,
hostname: str = Path(**models.proxmox.Hostname),
bearer_account: models.account.Account = Depends(utilities.auth.get_bearer_account)
):
resource_account = providers.accounts.find_verified_account(email_or_username)
utilities.auth.ensure_sysadmin_or_acting_on_self(bearer_account, resource_account)
instance = providers.proxmox.read_instance_by_account(instance_type, resource_account, hostname)
ensure_active(instance)
providers.proxmox.delete_instance(instance)
utilities.webhook.info(
f"""**{resource_account.username} ({resource_account.email}) deleted instance `{instance.hostname}`**"""
)
ranged_port = models.proxmox.generate_ranged_port_field_args(config.proxmox.network.port_forward.range[0], config.proxmox.network.port_forward.range[1])
@router.post(
'/{email_or_username}/{instance_type}/{hostname}/port/{external_port}/{internal_port}',
status_code=200,
)
def add_instance_port(
email_or_username: str,
instance_type: models.proxmox.Type,
hostname: str = Path(**models.proxmox.Hostname),
external_port: int = Path(**ranged_port),
internal_port: int = Path(**models.proxmox.Port),
bearer_account: models.account.Account = Depends(utilities.auth.get_bearer_account)
):
resource_account = providers.accounts.find_verified_account(email_or_username)
utilities.auth.ensure_sysadmin_or_acting_on_self(bearer_account, resource_account)
instance = providers.proxmox.read_instance_by_account(instance_type, resource_account, hostname)
ensure_active(instance)
providers.proxmox.add_instance_port(instance, external_port, internal_port)
utilities.webhook.info(
f"""**{resource_account.username} ({resource_account.email}) added instance `{instance.hostname}` portmap {external_port}->{internal_port}**"""
)
@router.get(
'/{email_or_username}/{instance_type}/{hostname}/free-external-port',
status_code=200,
response_model=int
)
def get_random_available_external_port(
email_or_username: str,
instance_type: models.proxmox.Type,
hostname: str = Path(**models.proxmox.Hostname)
):
return providers.proxmox.get_random_available_external_port()
@router.delete(
'/{email_or_username}/{instance_type}/{hostname}/port/{external_port}',
status_code=200,
)
def remove_instance_port(
email_or_username: str,
instance_type: models.proxmox.Type,
hostname: str = Path(**models.proxmox.Hostname),
external_port: int = Path(**models.proxmox.Port), # don't need to worry about them deleting non-ranged ports
bearer_account: models.account.Account = Depends(utilities.auth.get_bearer_account)
):
resource_account = providers.accounts.find_verified_account(email_or_username)
utilities.auth.ensure_sysadmin_or_acting_on_self(bearer_account, resource_account)
instance = providers.proxmox.read_instance_by_account(instance_type, resource_account, hostname)
ensure_active(instance)
providers.proxmox.remove_instance_port(instance, external_port)
utilities.webhook.info(
f"""**{resource_account.username} ({resource_account.email}) removed instance `{instance.hostname}` portmap for external port {external_port}**"""
)
@router.get(
'/vhost-requirements',
status_code=200,
response_model=models.config.Proxmox.Network.VHostRequirements
)
def get_allowed_a_aaaa() -> str:
return config.proxmox.network.vhosts
@router.post(
'/{email_or_username}/{instance_type}/{hostname}/vhost/{vhost}',
status_code=200,
)
def add_instance_vhost(
email_or_username: str,
instance_type: models.proxmox.Type,
options: models.proxmox.VHostOptions,
hostname: str = Path(**models.proxmox.Hostname),
vhost: str = Path(**models.proxmox.VHost),
bearer_account: models.account.Account = Depends(utilities.auth.get_bearer_account)
):
resource_account = providers.accounts.find_verified_account(email_or_username)
utilities.auth.ensure_sysadmin_or_acting_on_self(bearer_account, resource_account)
instance = providers.proxmox.read_instance_by_account(instance_type, resource_account, hostname)
ensure_active(instance)
providers.proxmox.add_instance_vhost(instance, vhost, options)
utilities.webhook.info(
f"""**{resource_account.username} ({resource_account.email}) added instance `{instance.hostname}` vhost {vhost}**"""
)
@router.delete(
'/{email_or_username}/{instance_type}/{hostname}/vhost/{vhost}',
status_code=200,
)
def remove_instance_vhost(
email_or_username: str,
instance_type: models.proxmox.Type,
hostname: str = Path(**models.proxmox.Hostname),
vhost: str = Path(**models.proxmox.VHost),
bearer_account: models.account.Account = Depends(utilities.auth.get_bearer_account)
):
resource_account = providers.accounts.find_verified_account(email_or_username)
utilities.auth.ensure_sysadmin_or_acting_on_self(bearer_account, resource_account)
instance = providers.proxmox.read_instance_by_account(instance_type, resource_account, hostname)
ensure_active(instance)
providers.proxmox.remove_instance_vhost(instance, vhost)
utilities.webhook.info(
f"""**{resource_account.username} ({resource_account.email}) deleted instance `{instance.hostname}` vhost {vhost}**"""
)
@router.post(
'/{email_or_username}/{instance_type}/{hostname}/reset-root-user',
status_code=200,
response_model=models.rest.Info
)
def reset_instance_root_user(
email_or_username: str,
instance_type: models.proxmox.Type,
background_tasks: BackgroundTasks,
hostname: str = Path(**models.proxmox.Hostname),
bearer_account: models.account.Account = Depends(utilities.auth.get_bearer_account)
) -> models.rest.Info:
resource_account = providers.accounts.find_verified_account(email_or_username)
utilities.auth.ensure_sysadmin_or_acting_on_self(bearer_account, resource_account)
instance = providers.proxmox.read_instance_by_account(instance_type, resource_account, hostname)
ensure_active(instance)
def reset_password_task():
try:
password, private_key, root_user = providers.proxmox.reset_instance_root_user(instance)
providers.email.send(
[resource_account.email],
f"{fancy_name(instance_type)} '{hostname}' root user information",
templates.email.netsoc.render(
heading=f"{fancy_name(instance_type)} '{hostname}' root user information",
paragraph=f"""Hi {resource_account.username}!<br/><br/>
We successfully set the password and SSH identity for the root user on your {fancy_name(instance_type)} named '{hostname}'<br/><br/>
You will find the password followed by the SSH private key for the user <code>root</code> below:<br/>
""",
embeds=[
{ "text": f"<code>{password}</code>" },
{ "text": f"<pre>{private_key}</pre>" }
]
),
"text/html"
)
except Exception as e:
utilities.webhook.info(
f"""**{resource_account.username} ({resource_account.email})'s instance `{hostname}` reset password task failed: ```{e}```!**"""
)
raise e
utilities.webhook.info(
f"""**{resource_account.username} ({resource_account.email}) reset instance `{instance.hostname}` root user**"""
)
utilities.webhook.info(
f"""**{resource_account.username} ({resource_account.email}) reset instance `{instance.hostname}` root user task started...**"""
)
background_tasks.add_task(reset_password_task)
return models.rest.Info(
detail=models.rest.Detail(
msg="A new root password and private key will be sent to the email associated with this account. If you do not receive it, contact the SysAdmins"
)
)
| 39.307122
| 219
| 0.701468
| 3,137
| 26,493
| 5.704176
| 0.105196
| 0.081312
| 0.046105
| 0.043814
| 0.778306
| 0.749525
| 0.720633
| 0.706773
| 0.689561
| 0.647033
| 0
| 0.00602
| 0.184917
| 26,493
| 674
| 220
| 39.307122
| 0.822636
| 0.040048
| 0
| 0.592523
| 0
| 0.035514
| 0.266908
| 0.129793
| 0
| 0
| 0
| 0
| 0
| 1
| 0.050467
| false
| 0.018692
| 0.016822
| 0.009346
| 0.08972
| 0
| 0
| 0
| 0
| null | 0
| 0
| 0
| 0
| 1
| 1
| 1
| 0
| 1
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| null | 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
|
0
| 4
|
fe2689e309f9e3e14c86f7d7f1053f9d91a3e800
| 257
|
py
|
Python
|
kabzimal/rest/serializers/category_type.py
|
arasumran/kabzimal
|
dbae35fdb940bdf0338bd43983b1894c87a35961
|
[
"MIT"
] | null | null | null |
kabzimal/rest/serializers/category_type.py
|
arasumran/kabzimal
|
dbae35fdb940bdf0338bd43983b1894c87a35961
|
[
"MIT"
] | 12
|
2020-06-05T23:02:28.000Z
|
2022-03-11T23:59:56.000Z
|
kabzimal/rest/serializers/category_type.py
|
arasumran/kabzimal
|
dbae35fdb940bdf0338bd43983b1894c87a35961
|
[
"MIT"
] | null | null | null |
from rest_framework import serializers
from kabzimal.models import CategoryTypeModel
class CategoryTypeSerializers(serializers.ModelSerializer):
class Meta:
model = CategoryTypeModel
fields = ('category_type_name','category_type_desc',)
| 28.555556
| 60
| 0.789883
| 25
| 257
| 7.92
| 0.72
| 0.121212
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0.14786
| 257
| 9
| 60
| 28.555556
| 0.90411
| 0
| 0
| 0
| 0
| 0
| 0.139535
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| false
| 0
| 0.333333
| 0
| 0.666667
| 0
| 1
| 0
| 0
| null | 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| null | 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| 1
| 0
|
0
| 4
|
fe322c862c4034dd066b3deccad6b440c7969053
| 175
|
py
|
Python
|
evennia_extensions/character_extensions/apps.py
|
dvoraen/arxcode
|
a89f2004fca10e0b1f1995c2420dd3ffbf08774b
|
[
"MIT"
] | 42
|
2018-08-12T00:55:24.000Z
|
2021-12-24T15:16:08.000Z
|
evennia_extensions/character_extensions/apps.py
|
dvoraen/arxcode
|
a89f2004fca10e0b1f1995c2420dd3ffbf08774b
|
[
"MIT"
] | 312
|
2018-10-22T23:03:27.000Z
|
2022-02-06T13:02:58.000Z
|
evennia_extensions/character_extensions/apps.py
|
dvoraen/arxcode
|
a89f2004fca10e0b1f1995c2420dd3ffbf08774b
|
[
"MIT"
] | 42
|
2018-08-12T00:41:48.000Z
|
2022-01-27T14:03:16.000Z
|
from django.apps import AppConfig
class CharacterExtensionsConfig(AppConfig):
name = "evennia_extensions.character_extensions"
verbose_name = "Character Extensions"
| 25
| 52
| 0.805714
| 17
| 175
| 8.117647
| 0.705882
| 0.275362
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0.131429
| 175
| 6
| 53
| 29.166667
| 0.907895
| 0
| 0
| 0
| 0
| 0
| 0.337143
| 0.222857
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| false
| 0
| 0.25
| 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
| 0
| 0
| 0
| 0
| 1
| 0
|
0
| 4
|
fe356dbbe79178ea35bd659e01fce672a693db29
| 386
|
py
|
Python
|
spyder/plugins/breakpoints/api.py
|
Earthman100/spyder
|
949ce0f9100a69504c70a5678e8589a05aee7d38
|
[
"MIT"
] | 7,956
|
2015-02-17T01:19:09.000Z
|
2022-03-31T21:52:15.000Z
|
spyder/plugins/breakpoints/api.py
|
Earthman100/spyder
|
949ce0f9100a69504c70a5678e8589a05aee7d38
|
[
"MIT"
] | 16,326
|
2015-02-16T23:15:21.000Z
|
2022-03-31T23:34:34.000Z
|
spyder/plugins/breakpoints/api.py
|
Earthman100/spyder
|
949ce0f9100a69504c70a5678e8589a05aee7d38
|
[
"MIT"
] | 1,918
|
2015-02-20T19:26:26.000Z
|
2022-03-31T19:03:25.000Z
|
# -*- coding: utf-8 -*-
# Copyright (c) 2009- Spyder Project Contributors
#
# Distributed under the terms of the MIT License
# (see spyder/__init__.py for details)
"""
Breakpoints Plugin API.
"""
# Local imports
from spyder.plugins.breakpoints.plugin import BreakpointsActions
from spyder.plugins.breakpoints.widgets.main_widget import (
BreakpointTableViewActions)
| 25.733333
| 65
| 0.738342
| 44
| 386
| 6.363636
| 0.772727
| 0.121429
| 0.121429
| 0.2
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0.015528
| 0.165803
| 386
| 14
| 66
| 27.571429
| 0.854037
| 0.497409
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| true
| 0
| 0.666667
| 0
| 0.666667
| 0
| 0
| 0
| 0
| null | 0
| 0
| 1
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| null | 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| 1
| 0
| 1
| 0
|
0
| 4
|
fe4487ae4692eb0b3690eef04b23e8280b9200b2
| 67
|
py
|
Python
|
src/model/__init__.py
|
Lukeeeeee/FISDNN
|
49361770fe987337b16a296c00cfd6562a7e95ed
|
[
"MIT"
] | null | null | null |
src/model/__init__.py
|
Lukeeeeee/FISDNN
|
49361770fe987337b16a296c00cfd6562a7e95ed
|
[
"MIT"
] | null | null | null |
src/model/__init__.py
|
Lukeeeeee/FISDNN
|
49361770fe987337b16a296c00cfd6562a7e95ed
|
[
"MIT"
] | null | null | null |
import os
MODEL_PATH = os.path.dirname(os.path.realpath(__file__))
| 22.333333
| 56
| 0.791045
| 11
| 67
| 4.363636
| 0.636364
| 0.25
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0.074627
| 67
| 2
| 57
| 33.5
| 0.774194
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| false
| 0
| 0.5
| 0
| 0.5
| 0
| 1
| 0
| 0
| null | 1
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| null | 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| 0
| 0
|
0
| 4
|
fe5787c1a5d93d1d2caedddad50b0c8a30f20cfe
| 46,717
|
py
|
Python
|
Lib/site-packages/PySide/examples/opengl/textures/textures_rc.py
|
heylenz/python27
|
bee49fa9d65b8ab7d591146a5b6cd47aeb41d940
|
[
"bzip2-1.0.6",
"MIT"
] | null | null | null |
Lib/site-packages/PySide/examples/opengl/textures/textures_rc.py
|
heylenz/python27
|
bee49fa9d65b8ab7d591146a5b6cd47aeb41d940
|
[
"bzip2-1.0.6",
"MIT"
] | null | null | null |
Lib/site-packages/PySide/examples/opengl/textures/textures_rc.py
|
heylenz/python27
|
bee49fa9d65b8ab7d591146a5b6cd47aeb41d940
|
[
"bzip2-1.0.6",
"MIT"
] | null | null | null |
# Resource object code
#
# Created: Wed Dec 28 19:57:29 2005
# by: The Resource Compiler for PyQt (Qt v4.1.0)
#
# WARNING! All changes made in this file will be lost!
from PySide import QtCore
qt_resource_data = "\
\x00\x00\x05\x3e\
\x89\
\x50\x4e\x47\x0d\x0a\x1a\x0a\x00\x00\x00\x0d\x49\x48\x44\x52\x00\
\x00\x01\x00\x00\x00\x01\x00\x08\x03\x00\x00\x00\x6b\xac\x58\x54\
\x00\x00\x00\xa5\x50\x4c\x54\x45\x00\x7c\xf8\x00\x80\xf8\x08\x80\
\xf8\x08\x84\xf8\x10\x84\xf8\x10\x88\xf8\x18\x88\xf8\x18\x8c\xf8\
\x20\x90\xf8\x28\x90\xf8\x28\x94\xf8\x30\x94\xf8\x30\x98\xf8\x38\
\x98\xf8\x38\x9c\xf8\x40\x9c\xf8\x40\xa0\xf8\x48\xa4\xf8\x50\xa4\
\xf8\x50\xa8\xf8\x58\xa8\xf8\x58\xac\xf8\x60\xb0\xf8\x68\xb0\xf8\
\x68\xb4\xf8\x70\xb4\xf8\x70\xb8\xf8\x78\xbc\xf8\x80\xbc\xf8\x80\
\xc0\xf8\x88\xc4\xf8\x90\xc4\xf8\x90\xc8\xf8\x98\xcc\xf8\xa0\xcc\
\xf8\xa0\xd0\xf8\xa8\xd4\xf8\xb0\xd8\xf8\xb8\xd8\xf8\xb8\xdc\xf8\
\xc0\xdc\xf8\xc0\xe0\xf8\xc8\xe0\xf8\xc8\xe4\xf8\xd0\xe4\xf8\xd0\
\xe8\xf8\xd8\xe8\xf8\xd8\xec\xf8\xe0\xec\xf8\xe0\xf0\xf8\xe8\xf4\
\xf8\xf0\xf4\xf8\xf0\xf8\xf8\xf8\xf8\xf8\xf8\xfc\xf8\xce\x99\xaa\
\x77\x00\x00\x00\x09\x70\x48\x59\x73\x00\x00\x00\x48\x00\x00\x00\
\x48\x00\x46\xc9\x6b\x3e\x00\x00\x04\x3f\x49\x44\x41\x54\x78\xda\
\xed\xdd\xe1\x76\xd2\x40\x10\x05\xe0\x0d\x34\x05\x91\x62\x28\x82\
\x14\x24\x16\x53\xc4\x88\x18\x13\xd3\x79\xff\x47\xf3\x8f\x9e\xee\
\x20\x25\x9b\x9e\xb6\xb6\x73\xef\x3e\x40\x0f\xfb\x41\x93\xbd\x33\
\x13\x70\x02\xbe\x1c\x01\x08\x40\x00\x02\x10\x40\x1c\xe0\x22\x00\
\x01\x08\xa0\x01\xa0\x2e\x7d\x04\x20\x00\x01\x08\x40\x00\x02\x10\
\x80\x00\x04\x20\x00\x01\x08\x40\x00\x02\x10\x80\x00\x04\x20\x00\
\x01\x08\x40\x00\x02\x10\x80\x00\x04\x20\x00\x01\x08\x40\x00\x02\
\x10\xe0\x05\xac\x9f\xd9\x7c\x38\x02\x05\xa8\xf3\x74\xd2\x73\xce\
\xb9\x1e\x20\x40\x91\xcd\x87\xd1\xdf\x21\x96\x2e\x16\x40\x9d\xa7\
\x93\xf3\x63\x63\x3c\x08\x00\xea\x8d\x07\x03\xa8\xf3\xf4\x32\x3e\
\x39\xc8\x65\x18\xa0\x3c\xfe\xc6\xc3\x00\x54\xbd\xa0\x51\x3e\xbb\
\x00\x53\x87\x0d\x70\xe3\xb0\x01\xaa\x18\x1c\x60\xe2\xb0\x01\x32\
\x87\x0d\x50\xc6\xe0\x00\x63\x87\x0d\x90\x39\x6c\x80\xf2\x0c\x1c\
\x60\xec\xb0\x01\x32\x87\x0d\x10\x74\x07\xb0\x0c\x70\xe9\xb0\x01\
\x32\x87\x0d\x50\xc5\xe0\x00\x7e\x06\x88\x00\x01\x54\x08\x5e\xe0\
\x01\xa8\x2a\x50\xbf\xc6\x03\x98\xf9\x1b\xdc\x0a\x1c\xc0\xd6\xdf\
\xdf\x4c\xe0\x00\xea\xbe\xb7\xbd\xb8\xc2\x03\xb8\xf2\xb7\x97\x09\
\x1c\xc0\x37\xff\xb6\x97\x08\x1e\xc0\xc0\x3f\x02\x14\x78\x00\x2b\
\x7f\x73\x4b\x81\x03\x28\x3a\xea\x08\x80\x07\x90\xf8\x7b\xdb\x08\
\x1c\xc0\xda\xdf\xda\x58\xe0\x00\x54\x08\xec\x14\x78\x00\xaa\x13\
\xba\x12\x38\x00\x75\x06\xfe\x73\x05\x44\x02\x50\x67\x60\xf7\x45\
\xe0\x00\x96\xfe\xbe\x26\x02\x07\xf0\xc3\x3f\x03\x77\x4b\x3c\x00\
\x75\x04\x48\x05\x0e\x40\xd5\x81\x07\x02\x07\xa0\xeb\xc0\x39\x1e\
\xc0\xfc\xa0\x0c\x84\x06\xb0\x8b\x0e\xca\x40\x68\x00\x43\x7f\x4f\
\x6b\x81\x03\x50\x21\x68\x28\x70\x00\xea\x0a\x18\xed\xf0\x00\x3e\
\xf8\x3b\x9a\x0b\x1c\xc0\xa9\x2b\x20\x04\xc0\xf0\xb0\x10\x0e\x06\
\xf0\xd9\xdf\xcf\x85\xc0\x01\xd4\xe7\xf7\x9e\x01\x31\x00\x54\xfb\
\x3b\x11\x38\x80\x42\x0d\x40\xec\xf0\x00\xc6\xf7\x94\x41\x50\x00\
\x36\xee\x9f\x56\x18\x16\xc0\x9b\xfb\x53\x20\x04\xc0\xb5\xbf\x97\
\x4e\x09\x07\xa0\xcb\x20\x0b\x81\x03\x50\xb7\xc0\xb3\x0a\x0e\x40\
\xdf\x02\x53\x81\x03\x50\xcf\x44\xf5\x6a\x38\x80\xdc\x9d\xa8\x03\
\x21\x00\xa8\x14\xd8\x17\x38\x00\x3d\x11\x7e\x03\x07\x70\xdb\x3f\
\x55\x08\x04\x00\xf8\xe4\xf4\x44\x2c\x1a\xc0\xaf\xb8\x29\x06\x1b\
\x07\x50\xcd\xf0\xa3\x31\xd8\x36\x40\xd9\x69\x8c\xc1\xb6\x01\x66\
\xcd\x31\xd8\x34\x80\x3e\x04\xcf\x04\x0e\xe0\x7d\x40\x0c\xb6\x0c\
\xf0\xdd\x05\xc4\x60\xcb\x00\xe3\x90\x18\x6c\x18\x40\xa7\xa0\x54\
\xe0\x00\x46\x41\x31\xd8\x2e\xc0\x36\x2c\x06\xdb\x05\x18\x85\xc5\
\x60\xb3\x00\xdb\xc0\x18\x6c\x16\x60\x18\x18\x83\xad\x02\x6c\x42\
\x63\xb0\x55\x80\x61\x68\x0c\x36\x0a\xb0\x09\x8e\xc1\x46\x01\x2e\
\x82\x63\xb0\x4d\x00\x7d\x0b\xd8\xe3\x01\xbc\xf3\x5f\xfc\xa5\xc0\
\x01\xe4\xad\xaf\x00\xc6\x00\x92\xb6\xb7\x00\x63\x00\x3b\xf5\xda\
\xbf\xe2\x01\x4c\x5a\x1e\x02\xad\x01\xec\xa3\x76\x29\xc0\x1c\xc0\
\xac\x5d\x0c\x34\x07\x50\xaa\x0f\xc0\x35\x1e\x80\x1a\x88\xe9\xd6\
\x70\x00\x55\xb7\x45\x29\xd8\x22\xc0\x2a\xbc\x19\x64\x12\xe0\xf6\
\xbc\x75\x0c\xb2\x05\xa0\x1e\x0b\x38\x36\x16\x6f\x1d\xc0\xff\x7e\
\x1c\x37\x12\x38\x80\xb6\xa5\x50\x73\x00\xe3\x07\x1d\x82\xec\x00\
\xec\xdb\x35\x43\xec\x01\xa8\x53\x70\x4f\xe0\x00\xf4\x21\x68\x8d\
\x07\x90\x3e\xfc\x03\x60\x03\xa0\xe9\xb7\x62\x1e\x79\x15\x2f\x0d\
\xe0\xe6\x79\xf7\x1f\xd2\x6f\x7a\x5e\x80\x04\x1c\x60\xef\xc0\x01\
\xe6\xe0\x00\x75\x17\x1c\xe0\xda\x81\x03\x0c\xc0\x01\x72\x07\x0e\
\x30\x05\x07\xa8\x22\x70\x80\xbd\x43\xff\x17\x40\xff\x04\xc8\x5b\
\x5e\x04\xc1\x01\x52\x74\x80\x2d\x3a\x40\x89\x0e\x20\x31\x3a\x40\
\x82\x0e\x70\x85\x0e\xf0\x08\xaf\xc4\xe0\xb3\xc3\x04\x20\x00\x01\
\x08\x40\x00\x02\x10\x80\x00\x04\x20\x00\x01\x08\x40\x00\x02\x9c\
\x58\x0d\xbf\x3b\x5c\x9b\x07\x68\x28\x29\x56\xe6\x01\x76\x4f\x3f\
\x10\xf6\xb2\x01\x36\xa7\x01\x72\xf3\x00\x0d\x7d\x95\xcc\x3c\x40\
\x43\x67\x6d\x69\x1e\xa0\x61\xc8\x34\xb1\x0e\xd0\x34\x5e\xd0\xb5\
\x0e\xf0\xb1\xa9\x07\x90\x1b\x07\x68\x1c\xb3\x9e\xd9\x06\x58\x37\
\x76\x81\xba\x95\x65\x80\x2a\x60\xce\x7e\x69\x19\x20\x64\xba\x24\
\x2a\xec\x02\xac\x82\x5a\xa1\x83\xda\x2a\xc0\x22\xb0\x19\x9c\xd4\
\x26\x01\xf6\xa3\xe0\x76\xf8\x60\x67\x0e\xa0\xde\x4c\xda\xcc\x17\
\x46\xd3\xfc\x15\x03\xac\x96\x07\x6b\x31\xbd\x68\x3f\x5d\x19\x27\
\xf3\xbb\xbf\x50\xbc\x2a\x80\x27\x18\x25\xdd\x12\x80\x00\x04\x20\
\x00\x01\x08\x40\x00\x02\x18\x28\x8a\xfe\xaf\x45\x00\x02\x10\x80\
\x00\x04\x20\x00\x01\x08\x40\x00\x02\x10\x80\x00\x04\x20\x00\x01\
\x08\x40\x00\x02\x10\x80\x00\x04\x20\x00\x01\x08\x40\x00\x02\x10\
\x80\x00\x04\x20\x00\x2a\x00\xda\x22\x00\x01\x08\x70\x07\x80\xbb\
\x08\x40\x00\x02\x10\x00\x7a\xfd\x06\x0e\x4c\xb1\x67\x70\xf4\x76\
\x0b\x00\x00\x00\x00\x49\x45\x4e\x44\xae\x42\x60\x82\
\x00\x00\x07\xa7\
\x89\
\x50\x4e\x47\x0d\x0a\x1a\x0a\x00\x00\x00\x0d\x49\x48\x44\x52\x00\
\x00\x01\x00\x00\x00\x01\x00\x08\x03\x00\x00\x00\x6b\xac\x58\x54\
\x00\x00\x00\x8d\x50\x4c\x54\x45\x78\xfc\x00\x80\xfc\x00\x80\xfc\
\x08\x80\xfc\x10\x88\xfc\x10\x88\xfc\x18\x88\xfc\x20\x90\xfc\x20\
\x90\xfc\x28\x90\xfc\x30\x98\xfc\x30\x98\xfc\x38\x98\xfc\x40\xa0\
\xfc\x40\xa0\xfc\x48\xa0\xfc\x50\xa8\xfc\x50\xa8\xfc\x58\xa8\xfc\
\x60\xb0\xfc\x60\xb0\xfc\x68\xb0\xfc\x70\xb8\xfc\x70\xb8\xfc\x78\
\xc0\xfc\x80\xc0\xfc\x88\xc0\xfc\x90\xc8\xfc\x90\xc8\xfc\x98\xc8\
\xfc\xa0\xd0\xfc\xa0\xd0\xfc\xa8\xd0\xfc\xb0\xd8\xfc\xb0\xd8\xfc\
\xb8\xd8\xfc\xc0\xe0\xfc\xc0\xe0\xfc\xc8\xe0\xfc\xd0\xe8\xfc\xd0\
\xe8\xfc\xd8\xe8\xfc\xe0\xf0\xfc\xe0\xf0\xfc\xe8\xf0\xfc\xf0\xf8\
\xfc\xf0\xf8\xfc\xf8\xa0\x01\x02\x2a\x00\x00\x00\x09\x70\x48\x59\
\x73\x00\x00\x00\x48\x00\x00\x00\x48\x00\x46\xc9\x6b\x3e\x00\x00\
\x06\xc0\x49\x44\x41\x54\x78\xda\xed\xdd\xdb\x62\x9b\x38\x10\x06\
\x60\x4b\x85\x42\x21\x66\xa1\x26\x1c\x8a\x03\x81\x9a\x40\x21\xf0\
\xfe\x8f\xb7\x17\xbb\x6d\xe2\xc6\x18\x8c\xf5\x13\x81\x86\xcb\x36\
\x17\xf8\x33\x16\xd2\x68\x66\xb4\xeb\x15\xbf\x76\x04\x40\x00\x04\
\x40\x00\x04\xd0\xef\x14\xbc\x08\x80\x00\x08\xe0\x1c\x40\xa9\xa1\
\x8f\x00\x08\x80\x00\x08\x80\x00\x08\x80\x00\x08\x80\x00\x08\x80\
\x00\x08\x80\x00\x08\x80\x00\x08\x80\x00\x08\x80\x00\x08\x80\x00\
\x08\x80\x00\x08\x80\x00\x08\x80\x00\x08\x80\x00\x08\x80\x00\x08\
\x80\x00\x08\xe0\xae\xab\x43\xde\x7c\xd7\x49\x0f\xf0\xcc\x76\x5c\
\x37\xac\x07\xc7\x3b\x04\x61\x9c\x3c\x65\x79\x51\x56\x75\xd3\x4e\
\xba\xf3\xae\x6d\xea\xaa\x3c\x15\x79\x96\x3e\x1d\x7f\xc4\x51\x18\
\xf8\x07\xcf\x75\xf6\xb6\x65\x1a\xba\xc6\xd9\x6e\xc7\x7f\x49\x0e\
\x50\xf2\xc1\xcc\x2c\xc6\x35\xdd\x30\x4d\xcb\xde\x3b\x8e\xeb\x79\
\x07\xff\x31\xf8\xf0\xf9\xc6\x2f\x47\x72\x80\x00\x9d\xe0\x66\x48\
\x0e\x10\xa1\x01\x7c\xc9\x01\x12\x34\x40\x26\x39\x40\x8a\x06\x68\
\x25\x07\x28\xc0\x9f\xdf\x94\xfd\x35\x58\x82\x01\x3c\xd9\x01\x6a\
\x30\xc0\x0f\xd9\x01\x5a\x30\x40\x21\xfd\x4c\x10\x0c\xf0\x4b\x7a\
\x00\x0e\xfd\xfc\x4c\xfe\xc5\x90\x0e\x05\xd0\xe4\x07\x30\x65\x7f\
\x0b\xa2\x01\x6c\x28\x80\x25\x3f\xc0\x1e\x0a\x60\xcb\x0f\xe0\xaa\
\x0e\x70\x50\x1d\xe0\x51\x75\x80\x50\x75\x80\x58\xf5\xb7\x00\x36\
\x22\xf2\x4d\x7e\x80\x54\xf5\x89\x50\x26\x79\x48\x14\x0e\x90\xab\
\xbe\x16\xc0\xc6\xc4\x56\xb0\x1a\x04\xc7\xc4\xe4\xdf\x1a\x7b\x51\
\xfd\x2d\x50\x41\x7f\x01\x95\xfc\x00\xf5\x87\xfd\xc0\xff\x36\x04\
\xff\xec\x08\xfa\x41\x18\x46\x71\x9c\x1c\x8f\x69\x96\xe5\x45\x71\
\x2a\xcb\xb2\x3c\xfd\x2c\xf2\x3c\xcb\xd2\xa7\x63\x92\xc4\x51\x14\
\x86\x81\xef\x1f\xbe\x7b\xae\xeb\xec\xf7\xb6\x6d\x99\xa6\xf1\x55\
\xd7\x34\x1e\xf5\xf2\x03\x34\x67\x00\x61\x2f\xdf\xb5\x28\x40\xa4\
\x1e\xc0\x79\x5c\x3c\x56\x1d\x20\x51\x0f\xe0\xf5\x0c\xe0\xa8\x1e\
\x40\x77\x06\xf0\xa4\x3a\x40\xaa\x3a\x40\xa6\x3a\x40\xae\x3a\x40\
\xa1\x3a\xc0\x4f\xd5\x01\x4e\xaa\x03\x94\xaa\x03\x54\xaa\x03\xd4\
\xaa\x03\x34\xaa\x03\xb4\x04\xa0\x38\x40\xa7\x3a\x40\xaf\x38\x00\
\x53\x1d\x80\x13\x80\xe2\x00\x9a\xea\x00\xba\xea\x00\x86\xea\x00\
\xa6\xea\x00\xdf\x54\x07\xb0\x54\x07\xb0\x55\x07\xd8\xab\x0e\xe0\
\x5c\xfc\x93\xf6\x74\x0c\xbd\xbd\xa9\x6b\x9c\xed\xd8\x17\xdd\x30\
\x6d\xf7\x31\xce\x4e\xaf\x1b\x04\x70\x3f\xfc\xf7\x4b\xe2\x1a\x83\
\x39\x70\x6e\x94\x77\x5b\x06\xe8\x32\x4f\x1b\x4d\x82\x79\x88\x5f\
\xd6\x0d\xf0\x3a\x50\xe6\xd8\x65\xee\xd4\x7a\x2a\x3d\xac\x57\x0c\
\x70\x96\x1f\x70\xf8\xfd\xaf\xa7\xc3\x6d\xd5\x64\xf6\xb1\x5b\x2b\
\x40\xf3\xb1\xd6\xbd\x4d\x66\x54\x52\x69\x71\xb7\x01\x80\xa0\xef\
\xfb\xea\x30\xb3\x94\x10\x45\xb0\x64\x9a\x5c\xd8\x3f\xdf\x53\x45\
\xf6\x35\x5f\x21\xc0\x59\xa6\xa8\x6d\xdc\x5b\x2c\xde\xae\x0e\xe0\
\x24\x38\x3d\x3c\x5f\x1b\x80\xf0\x6c\xf1\x70\x65\x00\xcf\xc2\x13\
\x84\x9d\x76\x55\x00\x80\x92\x19\xb3\x5d\x13\x00\xa2\x68\x4a\xac\
\xc0\x1a\xcb\xe6\xcc\x66\x3d\x00\x98\xc2\x49\xb3\x5b\x0d\x80\x8f\
\x29\x95\x70\x57\x03\xe0\x81\x8a\x45\xe2\xb5\x00\xa0\xca\xe7\x59\
\xb1\x12\x00\x58\x03\x05\xa3\x5b\x07\x80\x05\xab\x98\x0a\xd6\x01\
\x60\xc0\x00\xd8\xcb\x2a\x00\x34\x18\xc0\xee\x61\x15\x00\x0c\x07\
\x20\x28\xf1\x16\x0b\xd0\x21\xeb\x26\xf7\x2b\x00\x68\xa0\x95\xb3\
\xa5\xfc\x00\x03\x95\xb3\xcc\xf2\xa2\xb4\xa8\x9a\xd7\xbe\xef\xdb\
\xa6\x2e\x8e\xa1\x37\x67\xb4\xf4\xe4\x07\xb8\x10\x10\xe2\x4e\x7c\
\xf1\x9b\x6b\x73\xff\xd6\xc6\x63\xbc\x93\x1e\xe0\xef\xfe\x09\xcc\
\xcd\xae\xdd\x74\xe9\xdf\x16\x32\x4e\xa5\x07\x38\x8f\x87\xe8\xd1\
\xe8\x4a\xbe\x4b\xf4\x85\x87\x41\x2c\xc0\xfb\x78\x88\x3e\xad\x6c\
\xb2\x8b\xa7\x3f\x05\xac\x95\x1d\xe0\xad\xb1\x32\x9f\xbe\x7e\x6b\
\xa7\xaf\xa0\x72\xd9\x01\x82\x79\x11\xfd\x27\xbe\xdc\x82\x00\x3c\
\x0f\xf0\xd9\xac\x70\x7e\x35\x71\x24\xb0\x64\x07\xe8\xfb\xca\x99\
\x15\xc9\x6e\xa6\x2d\x23\x59\x27\x3d\x40\xdf\x9f\x66\x45\x6f\x3a\
\x6b\xa1\xc9\x20\x1e\x60\xe6\xd5\x1a\xcb\xcc\x04\xa4\x05\xe8\xeb\
\x29\x4b\xe9\x68\xc3\x00\x93\xfa\x90\x79\x5b\x06\x98\x12\x53\xb7\
\x37\x0d\xd0\x8d\xbf\x0c\xcd\x4d\x03\x4c\xd8\x5a\x35\xb6\x0d\x30\
\x1e\x54\xd6\x36\x0e\x30\x3a\x0e\xf2\x8d\x03\x8c\x86\xd5\xd9\xd6\
\x01\x62\xd5\x9f\x80\xb1\xa8\xaa\xbe\x75\x80\xb1\xf6\xf4\xe6\xe6\
\x01\x62\x95\x27\x42\x7d\x3f\xda\x94\xd4\xd9\x3c\xc0\xc8\x29\x25\
\xde\xf6\x01\xf6\xe0\xbc\x49\xe9\x01\x7c\x65\xe3\x01\xff\x5f\xd7\
\x33\x0d\xab\xed\x03\xe4\xe0\xd6\xd2\xd2\x03\x54\xd8\x69\x80\xfc\
\x00\xbf\xc0\xfb\xc3\xd2\x03\x5c\x3d\xaf\x2d\x51\x00\xe0\x6a\x92\
\x49\xad\x00\x40\x8f\x1d\x02\xd6\xfd\x04\x84\x2a\x00\x34\xe0\x3c\
\x31\xe9\x01\x6a\x64\x40\x70\x0d\x00\x57\xea\xce\x7c\x99\x01\x2a\
\x57\x50\x61\x4b\x8a\x9c\x07\xc3\x00\x5a\x9f\x89\x2a\x70\x8b\xd6\
\x98\x28\x19\x7f\xd9\xed\x76\x5c\xcc\x23\x30\x7c\x5e\x5d\x26\x2b\
\xc0\xb3\x21\x32\xa1\xdd\xc4\xc5\x43\x41\x00\x7f\xaa\x64\x98\x88\
\xc6\x07\x1d\x03\x57\xcd\x88\x07\x78\x7b\x66\xff\x11\x70\x7f\x83\
\xb5\xb7\x5a\x27\x2b\x40\x2a\xb4\x97\x78\x30\x04\x20\xea\xb0\x06\
\xf1\x00\x8d\xd0\xc2\x9e\xaf\xc0\x65\x00\x6a\x10\x34\x04\xe6\xf1\
\x95\xc0\x14\x49\x18\xc0\xbb\x30\x26\xbb\x77\xb6\xee\x43\xe7\x00\
\x20\x80\xf7\x7b\xda\xfa\x7d\x93\x81\x76\x60\x57\x80\x55\x32\x03\
\xb4\xe2\x8a\x5c\x63\x78\xe1\x28\x64\x26\x68\x8a\xba\xd7\x56\x43\
\xff\x00\x30\x00\x67\x3f\x5c\x76\xc7\x70\x35\xf0\x0e\xd4\x64\x2f\
\x9f\x3f\xef\x9b\xc1\x67\xff\x5e\x6b\x86\x5c\x04\x00\x01\xda\xf3\
\x1b\xd7\xe7\x4e\x89\x2d\x60\x18\x00\xbb\x1a\xfc\xeb\xce\x67\x0a\
\x04\xf8\x01\x00\x05\xf0\xf7\xad\xeb\x73\x7e\x05\x29\xbe\x7b\x04\
\x0c\xe0\xc3\x7e\x9e\x76\xfb\x84\xa8\xb8\x3c\x00\xe8\xa2\x4f\xa9\
\x80\x00\xbc\x7e\xb8\x79\x7e\xeb\x3e\xf6\xcf\xcb\x53\x20\x2e\xbc\
\xbf\x22\x26\x24\x76\x61\xf8\xf2\x6f\x7a\x74\xb3\xcb\xdf\x3f\x17\
\x7f\x56\x15\x06\xe0\xd2\xf8\x65\xde\x50\xdd\x11\x0d\x7c\x7e\xc0\
\x49\x4d\x18\x80\x8b\x9b\xfa\x2c\x98\xf8\x10\x34\x03\xb9\x71\x1a\
\xe2\xa0\x26\x50\x54\x78\x60\x04\x9b\x14\xc5\x18\xaa\x9c\xd4\x21\
\xbd\x45\x41\xfb\x02\x43\x69\xde\x46\x32\xf6\x14\xa4\x43\xe9\xc1\
\x06\xa6\xb7\x2a\x08\xe0\x71\x78\x3f\x2b\xb8\xf2\x20\xb7\x91\xbe\
\x54\x17\x39\x30\xc0\xd5\x3c\x77\x23\x28\x2e\x3d\x07\x75\xf2\x30\
\x18\x02\x66\xb0\x23\x8b\x41\x00\xed\x58\x9a\xbb\x75\x48\xf2\xea\
\xf7\x97\xda\x96\x69\xe4\x5c\x2b\x12\xd3\x70\x47\x35\xa2\xf6\x06\
\xa7\x75\x84\x60\x5c\xd3\xb5\xf1\x46\x2b\x36\xf0\x90\x32\x14\xc0\
\x41\x5c\xab\x10\x0e\x3d\xb0\x1a\x05\x70\x14\xd7\x2c\x06\x7b\x48\
\x1f\x6c\x7b\x5c\xd0\xc7\xd7\xd0\x67\x15\xc3\x12\x24\xb8\x88\x8f\
\xcf\x7c\xf8\x01\x75\x30\x00\x01\x7d\xe4\xd8\xf7\x05\x8e\xa8\x84\
\x01\xdc\xdf\x4c\xd3\x5d\xe4\x88\x52\x18\x40\x76\xe7\xb7\xef\xbd\
\xf4\xfd\xaa\x01\xee\xea\xa2\x35\xa1\xe1\x8e\xf4\x00\x7d\x30\xb7\
\x95\x1e\x73\x96\x3c\xa3\x1c\x98\x26\xd7\xa5\x33\x9a\xe9\xb3\x7d\
\xb2\xec\xd9\xb4\xd8\x3c\xc1\x3a\xba\xe9\x34\x09\xee\xa6\x8b\x9f\
\xcb\x0a\x4f\x94\xac\x93\xfd\xa4\xae\x8a\x9a\x13\x15\x9f\x71\x28\
\xeb\x22\x99\xa2\xa7\xd8\x35\xae\x28\x68\xb6\x9f\x7e\xda\xa1\xd4\
\x8b\xa5\xca\x76\x2f\x59\x1c\xb8\x7b\xcb\xd0\x38\x67\x3b\xc6\x75\
\xc3\xb4\xf7\x6e\x90\xe4\xd5\xe7\x1e\xc6\x2b\x7f\xbd\x00\x01\x10\
\x00\x01\x10\x00\x01\x10\x00\x01\x10\x00\x01\x10\x00\x01\x10\x00\
\x01\x10\x00\x01\x10\x00\x01\x10\x00\x01\x10\x00\x01\x10\x00\x01\
\x10\x00\x01\x10\x00\x01\x10\x00\x01\x10\x00\x01\x40\x00\x54\xbb\
\x08\x80\x00\x08\xe0\x0d\x40\xdd\x8b\x00\x08\x80\x00\x08\x40\xe9\
\xeb\x5f\x29\x7e\x47\x9c\x8c\x3f\x1d\xdc\x00\x00\x00\x00\x49\x45\
\x4e\x44\xae\x42\x60\x82\
\x00\x00\x09\x8e\
\x89\
\x50\x4e\x47\x0d\x0a\x1a\x0a\x00\x00\x00\x0d\x49\x48\x44\x52\x00\
\x00\x01\x00\x00\x00\x01\x00\x08\x03\x00\x00\x00\x6b\xac\x58\x54\
\x00\x00\x00\xf0\x50\x4c\x54\x45\xf8\x00\x78\xf8\x00\x80\xf8\x04\
\x80\xf8\x08\x80\xf8\x0c\x80\xf8\x10\x80\xf8\x10\x88\xf8\x14\x88\
\xf8\x18\x88\xf8\x1c\x88\xf8\x20\x88\xf8\x20\x90\xf8\x24\x90\xf8\
\x28\x90\xf8\x2c\x90\xf8\x30\x90\xf8\x30\x98\xf8\x34\x98\xf8\x38\
\x98\xf8\x3c\x98\xf8\x40\x98\xf8\x40\xa0\xf8\x44\xa0\xf8\x48\xa0\
\xf8\x4c\xa0\xf8\x50\xa0\xf8\x50\xa8\xf8\x54\xa8\xf8\x58\xa8\xf8\
\x5c\xa8\xf8\x60\xa8\xf8\x60\xb0\xf8\x64\xb0\xf8\x68\xb0\xf8\x6c\
\xb0\xf8\x70\xb0\xf8\x70\xb8\xf8\x74\xb8\xf8\x78\xb8\xf8\x7c\xb8\
\xf8\x80\xb8\xf8\x80\xc0\xf8\x84\xc0\xf8\x88\xc0\xf8\x8c\xc0\xf8\
\x90\xc0\xf8\x90\xc8\xf8\x94\xc8\xf8\x98\xc8\xf8\x9c\xc8\xf8\xa0\
\xc8\xf8\xa0\xd0\xf8\xa4\xd0\xf8\xa8\xd0\xf8\xac\xd0\xf8\xb0\xd0\
\xf8\xb0\xd8\xf8\xb4\xd8\xf8\xb8\xd8\xf8\xbc\xd8\xf8\xc0\xd8\xf8\
\xc0\xe0\xf8\xc4\xe0\xf8\xc8\xe0\xf8\xcc\xe0\xf8\xd0\xe0\xf8\xd0\
\xe8\xf8\xd4\xe8\xf8\xd8\xe8\xf8\xdc\xe8\xf8\xe0\xe8\xf8\xe0\xf0\
\xf8\xe4\xf0\xf8\xe8\xf0\xf8\xec\xf0\xf8\xf0\xf0\xf8\xf0\xf8\xf8\
\xf4\xf8\xf8\xf8\xf8\xf8\xfc\xf8\xd6\xac\x3e\xe0\x00\x00\x00\x09\
\x70\x48\x59\x73\x00\x00\x00\x48\x00\x00\x00\x48\x00\x46\xc9\x6b\
\x3e\x00\x00\x08\x44\x49\x44\x41\x54\x78\xda\xed\xdd\x6b\x5b\xda\
\x48\x14\x00\xe0\x40\x52\x01\x05\x54\xac\xc8\x4a\x11\x61\x2d\x56\
\xa4\x5c\xaa\x60\x15\xb9\x88\x60\x00\x49\xce\xff\xff\x37\xfb\xa1\
\xbb\xed\xb6\x0f\x73\x83\x99\x30\xc9\x9c\xf9\xac\x79\x98\x37\x99\
\xfb\x99\x19\x0b\x0c\x4f\x16\x02\x20\x00\x02\x20\x00\x02\x80\x65\
\x60\x42\x00\x04\x40\x80\xdf\x01\x8c\xaa\xfa\x10\x00\x01\x10\x00\
\x01\x10\x00\x01\x10\x00\x01\x10\x00\x01\x10\x00\x01\x10\x00\x01\
\x10\x00\x01\x10\x00\x01\x10\x00\x01\x10\x00\x01\x10\x00\x01\x10\
\x00\x01\x10\x00\x01\x10\x00\x01\x10\x00\x01\x10\x60\xf7\x69\xe5\
\x4e\x86\x4f\x0f\xdd\xce\xa3\x61\x00\xf3\xe7\xbb\x9b\xf2\xd9\x51\
\x32\xfe\x33\x96\xa7\xb8\x34\x04\xc0\x1f\xb7\x2f\x73\x1f\xd6\x44\
\x33\x25\x9f\xa2\x0f\xe0\xf5\xaf\x4f\xe2\xe4\x80\xae\xaa\x17\x69\
\x80\x79\xbb\x60\x33\x42\xda\x32\xe3\xc8\x02\xbc\x77\xf2\x31\x8e\
\xa0\xbe\x78\x3d\x9a\x00\xe3\xb2\xcd\x1b\xd7\x98\x9b\x45\x0f\xa0\
\x77\x2c\x12\xd9\xe9\xb8\xd1\x02\xf0\x3b\x69\xb1\xd0\xd6\x46\xb4\
\xbe\x80\x7b\xc1\xec\x5b\xb5\x48\xd5\x01\xfd\xac\x68\x68\x73\x25\
\x4a\x95\xe0\xec\x9c\x23\xc7\x76\x36\x5f\xba\xaa\x37\x5a\xed\x4e\
\xbb\x59\xff\x7c\x1d\xa1\x66\xd0\xaf\x33\x6a\xfe\x58\xa6\xf4\xb5\
\x3f\x8f\xec\x60\x68\x44\xff\xfa\xd3\x95\xde\x52\xfd\x8f\xd8\x1d\
\x80\x5f\xa3\x75\x7b\xb2\x37\xaf\x11\x1f\x0e\x8f\x29\xaf\xdf\xa9\
\xbc\x44\x7e\x3e\xa0\x41\x1e\xf0\xa4\xdb\x1e\x40\xc4\x01\x16\x67\
\xc4\xec\x1f\xf5\x0c\x98\x11\x1a\x24\x49\xd9\x3f\xe8\x9a\x30\x25\
\xd6\x22\x7d\xfe\x4e\xc3\x37\x60\x4e\xd0\xbb\x20\xbd\xfe\x73\x17\
\x20\xfa\x00\xee\x11\x21\xfb\x7b\x5d\x00\x03\x00\x5e\x48\xc5\xff\
\x74\x0e\x26\x00\xf4\x1d\x42\xfe\xaf\x01\x4c\x00\xb8\x27\x54\x7f\
\x4e\x0f\x8c\x00\x68\x10\x5e\x7f\x72\x02\x46\x00\xd4\x49\x5d\xbf\
\x19\x18\x01\x70\x4b\xc8\xff\xe1\x02\x8c\x00\x20\xe5\x3f\xb3\xd3\
\xfc\x07\x07\x40\x2a\xff\xe9\x39\x18\x01\xf0\x8d\x90\xff\xc4\x0c\
\x8c\x00\x78\x22\xb4\x7f\xf6\x08\x8c\x00\x78\x21\xf5\x7f\xba\x60\
\x04\x80\x4b\xea\xff\x56\xc1\x08\x00\xef\x90\x90\xff\x63\xdf\x0c\
\x80\x32\x69\xf8\x3f\x03\x23\x00\xda\xa4\xf1\x7f\x1b\x8c\x00\x18\
\x93\xe6\x7f\xf2\x60\x04\xc0\x32\x45\x5a\xf0\x9a\x99\x01\x50\x22\
\x15\x80\x3a\x18\x01\xf0\x9d\x94\xff\x7d\xdf\x08\x80\x65\x82\x04\
\x70\x0f\x46\x00\x14\x89\xeb\x1f\x60\x04\x00\xb1\x00\x58\x0f\x46\
\x00\x78\x07\xc4\xc5\x5f\x30\x02\xe0\x86\xf8\x01\x74\x8c\x00\x70\
\x89\xf1\x1f\x09\xcf\x08\x80\x62\x30\x71\x5e\xda\x02\x8c\xc8\x11\
\x10\x53\x23\x00\xc8\x31\x00\x39\x30\x01\x60\x48\xfe\x00\x9a\x46\
\x00\xe4\xc9\x00\xae\x09\x00\x94\x0f\xe0\x18\x4c\x00\x28\x90\x01\
\xae\x4d\x00\x98\x52\x82\x00\x07\x26\x00\x54\x29\x51\x80\xbe\x01\
\x00\x2b\x87\x0c\x90\x07\x03\x00\x9a\x56\x48\xaa\x00\x55\x00\x19\
\x0a\xc0\xa3\x01\x00\x63\x5a\x14\xf8\xc2\x00\x80\x2b\x4a\xfe\x93\
\x10\x7d\x00\x3f\x69\x85\xa5\x0e\x54\x03\xf0\x44\x2b\x01\x57\x06\
\x00\x94\x68\x00\x2d\x03\x00\xf6\x68\x00\xfd\xe8\x03\x0c\xa9\x5b\
\x81\x28\x2b\x62\xb3\x6e\xbd\x7c\x9a\x4d\x3a\x76\xcc\x4e\xa4\x32\
\x27\x17\xf5\xee\x24\x94\x00\x35\xea\x46\x30\x42\x47\xf8\xad\x75\
\xbe\xee\xc3\x71\x0a\x8d\x71\xe8\x00\xa8\x9b\xc1\xd6\xb6\x82\xab\
\x56\x8e\xb6\x7d\xac\xee\x86\x0a\xc0\xa5\x96\x80\x35\x93\x01\x6e\
\xd5\x61\x6c\x9d\x8c\xe5\x07\x21\x02\xe8\x50\xf3\x52\xf8\xf3\xcf\
\x17\xd5\x38\xcf\x86\xd9\xfc\x30\x34\x00\x65\x6a\x46\x2e\xff\xf8\
\xeb\x96\x63\x71\xa6\xe2\x22\x24\x00\x69\x81\xad\xdf\x53\x91\x73\
\x03\xf6\xee\x42\x01\xb0\x10\xd8\xfb\xdf\xb6\x2d\xa1\x74\xbe\x0a\
\x01\x40\x8f\x9e\x87\xff\xad\x0a\x7a\x25\xe1\x5b\xc1\xb2\x6f\xfa\
\x03\x5c\xd1\xb3\xf0\x6b\x6f\xc8\xfc\x68\x83\x7b\xd1\x12\x43\xed\
\x01\x3e\xd2\x73\xf0\xf3\x28\xa4\xd7\xd4\x46\x37\xc3\x39\x43\xdd\
\x01\xf6\xe8\x19\x18\xfd\xd7\x5f\x76\xac\xcd\x92\x33\xd6\x1b\x60\
\xce\xf8\xfd\xff\xee\x8a\x7f\xb6\xad\x4d\xd3\xde\xab\xd6\x00\x4f\
\x8c\x9f\xff\x63\x2c\xd4\xdf\x3c\xff\x96\x95\x59\xe9\x0c\xd0\x60\
\xfc\xfa\x39\x00\xc0\x70\x9b\xfc\x5b\x56\x51\x67\x00\x56\xd3\xb6\
\x04\x80\xc9\x87\x2d\xef\xc8\x6c\x6a\x0c\x70\xc2\xf8\xed\x2b\xca\
\xf6\x01\xee\x24\x31\xcc\x56\x3a\x00\xab\x71\xf3\xe0\x3d\x6b\x6d\
\x9d\xce\xb4\x05\xf0\x59\x07\xc2\xf9\xfe\xa9\x8c\x8b\x62\x7b\xba\
\x02\xcc\x58\xbf\xdc\xaf\x48\xb9\x29\x37\xe5\x6b\x0a\xf0\xcc\xfa\
\xe5\x6d\x49\x77\x05\xb7\x35\x05\xb8\x63\x9e\x87\x28\x09\xe0\xc0\
\xd7\x13\xe0\x56\xb4\x3e\x3f\xbd\xbe\x1f\xb9\x4b\xdf\x9b\x4f\xba\
\xb5\x93\x98\xc0\x7f\x7e\xd3\x13\xa0\x26\x92\xfb\xf8\xf9\xc3\xef\
\xef\x71\xd1\xca\x70\xff\xf3\xa1\x9e\x00\x97\xfc\xd9\x8f\x95\xd7\
\xb5\xe6\x3d\x6e\x82\x17\x2d\x01\x8a\xfc\x3d\xfa\x11\xa1\x21\xad\
\x71\x56\x13\x55\x2d\x01\xb8\x1b\xf9\x22\x39\x5e\x7a\x98\xe0\x9b\
\x1b\xf1\x75\x04\x38\xb4\x24\xbc\xbe\x19\x5f\x31\x78\xd4\x11\xe0\
\x80\x2f\xff\x25\xc6\xc4\x2a\x97\xc0\x95\x8e\x00\x7c\xf3\x5c\x39\
\xd6\xd7\x3b\xdf\xe7\xa9\x45\x74\x04\xe0\x2a\xbe\x36\x3b\x5c\x7e\
\xcc\x53\x13\xba\x1a\x02\xec\xc9\x3a\x17\x98\xa7\xcb\xdc\xd1\x10\
\xc0\x96\x36\x90\x29\x04\x73\xc0\xae\x6c\x80\xb8\xb4\x17\xf7\xc6\
\xb6\xcc\x69\x08\x20\xb1\xfd\xae\xb3\x67\xc8\xc3\xf9\x05\x7c\xe6\
\x7c\x94\xc7\xae\x50\xa7\xfa\x01\x70\x2c\x77\x70\xc7\xfd\xb0\x47\
\x96\x0f\xfa\x01\xb0\xdf\xda\x3e\xf7\xb3\x56\x4c\xcd\x56\x18\x3b\
\x42\x02\x55\x37\x73\xf6\xac\xa6\x1f\x00\xfb\xa8\x7c\x81\xe9\xcc\
\xf1\x96\x3d\xea\x5d\x00\x64\xa5\x76\xdf\x58\x4f\x3b\xd5\x0f\x80\
\x19\xf2\x22\x14\x2c\xfe\x45\xfd\x68\x40\x36\xc0\x47\x66\xb4\x97\
\xc8\xd3\x58\x65\xe0\x20\x84\x33\x42\x15\x99\x75\x6a\x52\x3f\x80\
\xaa\x8c\x81\xd0\xaf\xf4\x89\xfe\xb0\x0f\xfa\x01\x30\xfb\xaf\x62\
\xe7\xc7\xb5\x18\xd3\xca\xfa\x01\x7c\x63\x01\x3c\x83\xc4\x4a\x20\
\xa6\x1f\x00\x2b\x40\xc4\x12\x8b\x6f\xf1\xe9\x63\x0b\x5b\x3f\x80\
\x17\x16\x80\xe0\x11\xa2\xf4\xc9\xc1\x84\x7e\x00\x0b\x16\x80\xe0\
\xbd\x29\xe7\x61\x6b\x06\x99\xc3\x41\xc1\xe3\x53\x6a\x61\xeb\x08\
\x31\xbb\x82\x82\xab\x19\x2d\xd1\xcd\x07\x3b\x07\x60\x05\x49\x09\
\x3e\x8e\x1e\x79\xfc\x51\x43\x80\xba\xdc\x22\x30\xa0\x3e\xec\x93\
\x86\x00\x3d\x76\x94\x98\x48\x9a\x86\x6d\x3e\x80\xf1\x8b\x85\xb7\
\x4e\xcf\x55\xc7\xc9\x48\x07\x60\x74\x5d\x44\x57\x73\x96\x7c\xa1\
\xe7\x1a\x01\xb0\x9a\x01\xc1\xad\x90\x1e\x47\xe0\xb1\x66\x00\x8c\
\xf1\x60\x7f\x83\x1f\x48\x1c\x0a\xf8\x3a\x02\x74\x65\x8e\x06\xc1\
\x57\xbd\x3c\x2c\x1f\xc0\x95\x3a\x93\xbd\xa2\x3d\xab\xac\x25\x00\
\x63\x16\xa7\x26\xb1\x12\x6c\xeb\x09\xf0\x49\x66\xac\xff\x5c\x62\
\x85\x1a\x14\x00\xbd\xfb\x2e\x78\x9c\xec\x44\xed\x6c\x80\x12\x80\
\x99\xcc\x69\xbc\xbe\xda\x91\x80\x9a\xed\xf3\x19\x89\x33\x22\xb4\
\x36\xe5\x56\x57\x00\xfa\x18\xfe\xbb\xd0\xb3\x9a\x6a\x17\xc7\x77\
\x71\x84\x86\xd8\x49\x5a\x94\x6e\x95\x9c\xb3\x89\x55\x00\xd0\xd7\
\xc8\xc5\x76\xbb\x28\x3f\x96\x50\x09\x00\xf5\x04\x01\xb1\xd3\xf4\
\x28\xab\xcd\x63\x7d\x01\xe8\x73\xe3\x22\xa7\x61\xac\xc8\x3b\x08\
\xd2\xa0\x2f\x00\xec\xcb\xaa\x04\x06\xca\xf7\x0e\xaa\x01\xb8\x91\
\xd5\x15\x22\xef\x43\x75\x56\x3a\x03\xb8\x31\x49\x8b\x43\x05\xc5\
\xbb\x05\x94\x1d\xa8\x78\x26\xa7\x0c\xf8\xb6\xda\x4e\x80\x3a\x80\
\x9e\x9c\x38\xb1\x27\xf5\x5b\x47\x15\x01\xd0\xbb\xc3\xdc\x71\x52\
\xc4\x1d\x48\xb1\x89\xee\x00\xf7\x32\x62\x7c\x3d\xe2\x3a\xdb\x05\
\xe8\x0e\x40\x8f\x97\x1b\x6e\xa9\x68\xbb\xfa\x03\xdc\x49\xf8\x04\
\xb2\x0a\x17\x44\x94\x03\xf8\xe9\xad\xa7\x46\x1f\x89\x1b\x0e\xde\
\x43\x00\x40\x6f\x08\xb8\xb2\x70\xa4\x70\x3d\x24\x00\x00\xf8\x6b\
\xcb\x20\xd7\x96\xea\x3e\x90\x6a\x00\xd7\xd9\xaa\x10\xb8\xa4\x83\
\x46\xd2\x5e\x48\x00\xa8\xb3\x39\xcc\xfb\x66\x7d\xd2\x19\x93\xf1\
\x11\x84\x05\x00\x72\xd4\x00\xa7\xd9\x66\x7d\x20\xc9\x77\x34\x29\
\x05\x98\x51\x37\xd1\xa5\x68\xbd\xb9\xab\x00\x5a\x40\xf5\x00\xe4\
\x86\xec\xc7\x88\x96\xb8\x50\x4a\x3e\x68\xa4\x08\xa1\x02\x60\x6c\
\xfb\x89\xd5\xd6\x4f\x8f\xcd\x89\x87\x11\xe5\xbc\x90\x01\xb0\x76\
\xbd\x64\xd7\x34\xe9\x7e\x93\xd8\x7c\x9c\x84\xe1\x44\xc9\x3f\x12\
\x2b\x7e\x3e\xd7\xfb\xfd\xa5\xbe\x37\xc8\x8b\xab\x67\x0a\xee\x68\
\x53\x0e\xe0\x33\x77\x10\x38\xa5\xce\xf8\x47\x51\x58\x0e\xbe\xe6\
\x29\x11\x36\x45\x15\xb7\xb3\x28\x07\x00\xbf\xcc\xb3\x9f\xda\x49\
\xa5\x93\x8c\x20\xd3\x8a\x92\xdb\x69\xd4\x03\x30\xa6\x48\x79\x93\
\xad\xe8\x96\xd6\x20\x00\xa0\x6b\x6f\x9d\xff\xcc\x2b\x84\x18\x00\
\x5e\x33\x5b\xe6\xbf\xac\xec\x8a\xca\x60\x00\xc0\xfb\x1c\xdb\xe6\
\xf5\x2b\xbc\x94\x21\x20\x00\x80\xe1\xe1\xc6\xa5\xff\x56\xe5\xdd\
\x5c\x81\x01\x00\xb4\x13\x9b\x64\x3f\x7e\xa1\xf6\x76\xc2\x00\x01\
\x60\x75\x2b\x4c\x60\xff\xad\xfa\x72\xc6\x20\x01\x00\xbc\xb6\xd0\
\x71\x9a\xc9\x2f\x4b\x80\x48\x01\x00\xc0\xe0\x92\xf3\x48\x59\xa7\
\x1c\xc8\x7d\x34\x81\x03\x00\xf8\xdf\x2b\xcc\x53\x06\x52\xa5\x5e\
\x40\xb7\x12\xee\x00\x00\x00\x60\xda\xb9\xcc\x12\x7a\xfd\xb1\xcc\
\xe5\xdd\x1b\x04\x96\x76\x04\x00\x00\xe0\xbf\x76\x6f\xab\x85\x5c\
\x26\xe9\xd8\xb1\x98\x93\x3c\xc8\xe6\xce\xaa\xcd\xc7\x69\xc0\xf7\
\x51\xee\x10\x40\x8f\x84\x00\x08\x80\x00\x08\x80\x00\x08\x80\x00\
\x08\x80\x00\x08\x80\x00\x08\x80\x00\x08\x80\x00\x08\x80\x00\x08\
\x80\x00\x08\x80\x00\x08\x80\x00\x08\x80\x00\x08\x80\x00\x08\x80\
\x00\x08\x60\x2a\x80\x69\x09\x01\x10\x00\x01\x7e\x01\x98\x9b\x10\
\x00\x01\x10\x00\x01\x8c\x4e\xff\x00\xf3\x6b\xd4\xa5\x75\x51\x85\
\x33\x00\x00\x00\x00\x49\x45\x4e\x44\xae\x42\x60\x82\
\x00\x00\x04\x14\
\x89\
\x50\x4e\x47\x0d\x0a\x1a\x0a\x00\x00\x00\x0d\x49\x48\x44\x52\x00\
\x00\x01\x00\x00\x00\x01\x00\x08\x03\x00\x00\x00\x6b\xac\x58\x54\
\x00\x00\x00\x9f\x50\x4c\x54\x45\xf8\x7c\x00\xf8\x80\x00\xf8\x80\
\x08\xf8\x84\x08\xf8\x84\x10\xf8\x88\x10\xf8\x88\x18\xf8\x8c\x18\
\xf8\x8c\x20\xf8\x90\x20\xf8\x94\x28\xf8\x94\x30\xf8\x98\x30\xf8\
\x98\x38\xf8\x9c\x38\xf8\xa0\x40\xf8\xa4\x48\xf8\xa4\x50\xf8\xa8\
\x50\xf8\xa8\x58\xf8\xac\x58\xf8\xb0\x60\xf8\xb0\x68\xf8\xb4\x68\
\xf8\xb4\x70\xf8\xb8\x70\xf8\xb8\x78\xf8\xbc\x78\xf8\xc0\x80\xf8\
\xc4\x88\xf8\xc8\x90\xf8\xc8\x98\xf8\xcc\x98\xf8\xd0\xa0\xf8\xd4\
\xa8\xf8\xd4\xb0\xf8\xd8\xb0\xf8\xd8\xb8\xf8\xdc\xb8\xf8\xe0\xc0\
\xf8\xe0\xc8\xf8\xe4\xc8\xf8\xe4\xd0\xf8\xe8\xd0\xf8\xec\xd8\xf8\
\xec\xe0\xf8\xf0\xe0\xf8\xf0\xe8\xf8\xf4\xe8\xf8\xf4\xf0\xf8\xf8\
\xf0\xf8\xf8\xf8\xf8\xfc\xf8\x35\x75\xa4\x70\x00\x00\x00\x09\x70\
\x48\x59\x73\x00\x00\x00\x48\x00\x00\x00\x48\x00\x46\xc9\x6b\x3e\
\x00\x00\x03\x1b\x49\x44\x41\x54\x78\xda\xed\xdd\x61\x73\xd2\x40\
\x10\x80\xe1\x8b\x10\x23\x1a\x01\x23\x69\x6c\x0b\xb1\x80\x0d\x62\
\x10\x62\xe8\xff\xff\x6d\xb6\xd5\xd1\x92\x12\x72\x29\x38\x72\xbb\
\xef\x7e\xce\xb0\xec\x33\xc9\x5d\xb8\xd9\x1d\xcc\x9d\xf2\x30\x00\
\x00\x00\x00\x00\x00\xdc\x19\x85\x01\x00\x00\x00\xec\x02\xa8\x5a\
\xfa\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\
\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\
\x00\x00\x00\x00\x00\x00\x00\x80\xff\x18\x45\xae\x1a\x20\x1b\x79\
\x91\x5e\x80\xf5\xb8\x77\xff\x35\xde\x68\x05\x98\x0d\xbd\xa7\xbd\
\x3b\xca\x00\xf2\x4b\xbf\xd2\xbc\xa4\x09\xa0\x48\xc3\xe7\xdd\x5b\
\x7a\x00\x6e\x23\x6f\x5f\xfb\x9a\x12\x80\xfc\x2a\xa8\xe9\xdf\xd3\
\x00\x50\xb9\xf5\xb5\x01\xcc\xab\xb7\xbe\x2a\x80\xaf\x89\xdf\xd0\
\xc2\x2a\x19\x60\xf5\xf8\xc2\xa3\x15\xa0\x48\xdf\x5b\x35\x31\xcb\
\x04\x28\xa7\x43\xcf\xb2\x8b\x5b\x20\xc0\x76\x1e\x75\xec\xdb\xd8\
\xc5\x01\x64\x71\xb7\x55\x1f\xbf\x2c\x80\xec\xc2\x6f\x3b\xc8\x20\
\x08\x60\x91\xbc\x7e\xc1\x24\x87\x14\x80\xac\x65\xf5\xb2\x00\xb2\
\xd8\x7f\xf1\x2c\x8f\xf3\x00\xe5\x6c\xd4\x3d\x66\x98\xc9\x6d\x80\
\xcd\xcd\xf0\xd5\x91\xd3\x5c\x0e\x03\xe4\xe3\xbe\x77\xfc\x38\x9b\
\xa3\x00\xe5\x97\x8b\xe0\x34\xf3\x7c\x2e\x02\x2c\x27\x03\xef\x64\
\x03\x8d\xae\x01\xe4\x69\xe4\x9b\xd3\x84\x83\x00\xab\x0f\xa7\x2a\
\xde\x51\x80\xcc\xae\x32\x2f\x4a\x02\x99\x00\x0b\x9b\xf2\x3b\x97\
\xeb\xfb\xd3\x00\x5f\x24\xc0\xb2\xb9\x2a\x7f\x5c\x3c\x5e\x9a\x88\
\x04\xf8\xde\x54\x53\x2f\x2d\x7f\x5f\x3a\x15\x09\x50\x1e\xae\xe8\
\xdd\xb4\xd5\xcd\xe2\xe2\x36\x78\xe8\xc9\x1e\xdc\xee\x6c\x18\x32\
\x01\xfa\xf5\x0b\xff\xb2\x72\x26\x2a\x13\x20\xae\x29\x3f\x5e\xb5\
\x7c\x5a\x5c\x05\x48\x6b\xf7\xbd\xbd\xa9\xe5\x01\xec\x59\xda\x82\
\xc9\x8f\xda\xd4\x02\x7f\x0b\x54\xcf\xbb\x7b\x37\xdb\x03\xa9\x05\
\x02\x0c\x77\x4a\x08\x67\x87\x53\x0b\x04\xf8\xfc\x74\xdf\xcb\x9a\
\x52\x0b\x04\x58\xff\x59\xf8\x47\xdf\x9a\x53\x4b\x3c\x0f\xf8\xf5\
\x26\xd0\x49\x56\x36\xa9\x25\x02\x3c\x6c\x84\xfe\x75\x61\x97\x5a\
\x22\x40\xe1\x05\x93\xd2\x36\xb5\xc8\x33\xc1\x45\x8b\xd4\x7a\xfb\
\x03\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\
\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\
\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\
\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\
\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\
\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\
\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\
\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\
\x00\x00\x00\x00\x38\x5f\x80\xad\x76\x80\x4d\x33\x40\x21\x1a\xc0\
\xe2\x7f\xda\x73\xd1\x00\x93\x66\x80\xa9\x68\x80\x7e\x33\x40\x2c\
\x19\xc0\xe2\x09\x30\xfe\x56\x30\x40\x68\x01\x60\x52\xb9\x00\xb1\
\x4d\xfd\xa6\xbb\x16\x0a\x50\x8e\x8c\x5d\xbc\xdd\x88\x04\x98\xf7\
\x8c\x6d\x04\x99\x38\x80\xe5\xd8\xbe\xfc\x87\x18\xcc\x4a\x37\x01\
\xae\x9f\xc7\x55\x12\x85\x1d\xd3\x3a\xbc\xf0\xe3\xa7\xea\x47\x4d\
\xce\x1e\xa0\x34\xff\x34\x7c\x00\x00\x00\x00\x00\x00\x00\x00\x00\
\x00\x87\x4f\x85\xcf\x23\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\
\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\
\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x40\x2b\x80\xb6\x00\
\x00\x00\x00\xfe\x02\xe8\x0d\x00\x00\x00\x00\x00\xd5\xf1\x13\x3b\
\x45\x7a\xc4\xe1\x22\xe3\x41\x00\x00\x00\x00\x49\x45\x4e\x44\xae\
\x42\x60\x82\
\x00\x00\x06\xe8\
\x89\
\x50\x4e\x47\x0d\x0a\x1a\x0a\x00\x00\x00\x0d\x49\x48\x44\x52\x00\
\x00\x01\x00\x00\x00\x01\x00\x08\x03\x00\x00\x00\x6b\xac\x58\x54\
\x00\x00\x00\x8a\x50\x4c\x54\x45\x00\xfc\x78\x00\xfc\x80\x08\xfc\
\x80\x10\xfc\x80\x10\xfc\x88\x18\xfc\x88\x20\xfc\x88\x20\xfc\x90\
\x28\xfc\x90\x30\xfc\x90\x30\xfc\x98\x38\xfc\x98\x40\xfc\x98\x40\
\xfc\xa0\x48\xfc\xa0\x50\xfc\xa0\x50\xfc\xa8\x58\xfc\xa8\x60\xfc\
\xa8\x60\xfc\xb0\x68\xfc\xb0\x70\xfc\xb0\x70\xfc\xb8\x78\xfc\xb8\
\x80\xfc\xb8\x80\xfc\xc0\x88\xfc\xc0\x90\xfc\xc0\x90\xfc\xc8\x98\
\xfc\xc8\xa0\xfc\xd0\xa8\xfc\xd0\xb0\xfc\xd0\xb0\xfc\xd8\xb8\xfc\
\xd8\xc0\xfc\xe0\xc8\xfc\xe0\xd0\xfc\xe0\xd0\xfc\xe8\xd8\xfc\xe8\
\xe0\xfc\xe8\xe0\xfc\xf0\xe8\xfc\xf0\xf0\xfc\xf0\xf0\xfc\xf8\xf8\
\xfc\xf8\x60\x3b\x5e\x10\x00\x00\x00\x09\x70\x48\x59\x73\x00\x00\
\x00\x48\x00\x00\x00\x48\x00\x46\xc9\x6b\x3e\x00\x00\x06\x04\x49\
\x44\x41\x54\x78\xda\xed\xdd\x61\x77\xa2\x38\x14\x06\x60\x42\x61\
\x60\xa4\xba\xd0\x76\x74\x75\x51\x2a\x32\x50\x62\xf8\xff\x7f\x6f\
\x3b\x9d\x3d\x67\xdb\x01\x14\x85\x24\x37\xe4\xcd\x77\xcf\xe9\x7d\
\x2a\xe1\xe6\xe6\x26\x3a\x8d\xe5\xc3\x01\x00\x00\x00\x00\x00\x00\
\x34\x8e\x85\x03\x00\x00\x00\xc0\x57\x00\xab\xa6\x3e\x00\x00\x00\
\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\
\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\
\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\
\x00\x26\x1e\x55\x9e\xae\x93\x28\xf4\x5d\x97\x31\xd7\xf3\x83\x30\
\x4a\xd6\x69\x56\x08\x1b\x00\xc4\x71\xf3\xe8\xf6\x75\x2c\x06\xf1\
\xf6\xc8\xe7\x0c\x50\xed\x1e\xd9\xd5\xbe\xcd\x70\x9d\x8b\x59\x02\
\xf0\x7f\x16\x43\x7b\x57\xd9\xea\x20\xe6\x06\x50\x24\xec\xa6\xfe\
\x5d\x37\xc9\xe7\x04\x70\x8c\xee\xe8\x61\x0e\x52\x31\x13\x80\xe3\
\xe2\xce\x36\x6e\x6f\xcb\x67\x00\x50\x44\x23\x3a\xd9\xdd\x9d\xe9\
\x00\x75\x32\xb2\x99\x3f\x38\x1a\x0d\x90\xba\xe3\xcf\x33\x2c\x6b\
\x63\x01\xca\xc5\x24\x27\x3a\x1e\x32\x43\x01\x36\x6c\xaa\x43\x2d\
\x4f\xc2\x40\x80\x89\xfe\xfd\xff\xcd\x04\x95\x71\x00\x53\x3c\xfd\
\x9f\xdf\x88\x85\x59\x00\x3c\x9e\xfa\x68\x97\x7b\x34\x0a\xe0\xdb\
\xf4\x87\xdb\xd8\xc1\x20\x00\x2e\xe3\x78\x1f\xcb\xcd\x01\x28\xa4\
\x1c\x70\x74\x4f\xc6\x00\x1c\xe5\x1c\xf1\xf4\x2a\x53\x00\x52\x49\
\x87\x5c\xbf\x0b\x43\x00\x36\xb2\x8e\xf9\xbe\x18\x02\x90\xc8\x02\
\x70\x32\x33\x00\x1e\xa5\x01\x78\xdc\x08\x80\x40\xde\x59\xf7\x17\
\x23\x00\x98\x3c\x00\x56\x1a\x00\xc0\x1d\x89\x63\x69\x00\xc0\x80\
\x3c\x88\xb9\x77\x7f\x4b\x0a\xfa\x00\x97\xf2\x20\x6f\xb5\xcd\x8a\
\x8f\x99\x4c\xf0\x22\xdb\xae\xbc\x9b\x01\x12\xfa\x00\xbd\x79\xd0\
\x62\xdb\x7e\x82\xcb\x4d\x78\xe3\x2c\xc0\xc9\x03\x74\xe7\x41\xee\
\xba\x2f\x93\x3d\xc5\x37\x3d\x0f\x7f\x93\x07\xe8\xca\x83\xbc\xdd\
\xa5\x34\xb6\x5c\xde\x52\x1e\x22\x0f\xd0\xde\x09\x60\x3f\xce\x57\
\x3e\x93\xdd\x30\x19\x54\xd4\x01\x5a\x79\x50\x38\x60\xe6\xae\x87\
\x7f\x09\x76\xd4\x01\xfe\x7c\xa2\xe3\x61\x8b\xb8\xe7\xa1\x00\x8f\
\xc4\x01\xfe\xcc\x83\xd6\x43\x3f\xb8\x1e\xfa\x1e\x20\x0e\x50\xdc\
\x19\xff\xf0\x55\xe4\x4f\xda\x00\xaf\x5f\xfe\xd8\xbf\xc6\x4d\x9f\
\x9d\xe3\x40\x1b\xe0\x4b\x1e\xe4\xdf\x94\xb6\xd4\xc3\x76\x13\xd6\
\xb4\x01\xbe\x3c\xca\xfb\xdb\x3e\x7b\x18\x04\xb0\xa2\x0d\xf0\xf9\
\x49\xf6\xc7\xe7\x10\x5d\x29\x35\x6d\x80\x68\x4c\xfd\xe2\x34\x04\
\x20\xa4\x0d\xf0\x39\x0f\xba\x7d\x33\x63\x48\x3e\xe4\xd3\x06\xf8\
\x94\x07\xb1\xdb\xeb\xd8\x43\xf6\x14\x5c\xd2\x00\x7c\x64\xf9\xc6\
\x57\x99\x09\xc9\x00\x28\x46\x66\xed\x2f\xa6\x7f\x03\x5e\x47\xa6\
\x6c\xf9\x80\xe2\x38\x69\x80\x74\xec\x1f\xca\x14\x56\x04\x64\x00\
\xac\xc7\x96\xef\xae\xa7\x02\x11\x69\x80\x64\x6c\xce\x7e\x7d\x51\
\x98\x90\x06\xf8\xf4\x0f\xbc\xaf\xc3\x6f\x6f\xf8\x5a\x20\x18\x9b\
\xb0\xe5\x86\xaf\x06\xd9\xd8\x7f\x54\xa9\x70\x6f\x44\x02\x00\x1f\
\x93\x07\xff\x5e\x13\x9b\x5d\x11\x2a\xc6\xe4\xc1\x1f\x43\xa8\x7b\
\x09\xc8\x00\xc8\xc6\x6f\x63\x5e\x03\xd8\x90\x06\x48\xc7\x57\xaf\
\xaf\x01\x1c\x69\x03\x04\xee\xc8\xa9\xea\x7c\x6d\x25\x20\x48\x03\
\x7c\x4c\x63\x3f\xf3\x43\xba\xbd\xfb\xd3\xca\x0a\x62\x44\x8f\xce\
\x56\x57\x00\xf6\x73\x07\x38\x19\xbf\x3d\x3e\x72\x64\x97\x01\xe2\
\x66\xee\x00\x3b\x65\xef\x00\xa2\x00\x2f\x8a\x0a\xa2\x64\x01\x2e\
\xd7\x03\xb6\xf3\x07\xb8\xd8\x2a\xe1\xf2\xd9\x03\xd4\x33\xe8\x14\
\x95\xf7\x12\x60\x6f\xf3\x07\xb8\x38\x07\x3e\x37\xf3\x07\xb8\x74\
\xde\x90\x55\xf3\x07\xe0\x6c\x06\x07\x26\xc6\x8c\xbd\xba\x57\x00\
\x4d\x80\x58\x4d\x7f\x1c\x59\x00\xe1\xaa\x68\x0b\x20\x0c\x70\xa9\
\x47\xe6\x64\x03\xc0\x4a\x51\x9f\x3c\x55\x80\x0b\xef\x00\x9f\xdb\
\x00\xb0\x55\xb4\x0c\x26\x0b\xd0\xdf\x1e\xf2\xd4\xd8\x00\xd0\xbf\
\x0e\x08\xce\x56\x00\xf4\x96\x02\x98\x61\x37\x48\xdc\x39\x72\x85\
\x29\x10\x49\x80\x48\xc5\x56\x00\x61\x80\xde\x7a\x78\x28\xec\x00\
\xe8\xfb\x02\xb8\x55\x63\x05\x40\xdf\x2b\x80\x49\xbc\x4e\x8c\x14\
\x40\xdf\x99\xf3\xb4\xb1\x03\x60\x27\xbd\x23\x8a\x36\x40\xdf\x61\
\x91\xb8\xb1\x04\xa0\x67\x19\xb8\x14\x96\x00\xf4\xcc\x80\x0b\xc9\
\xf7\x8a\x92\x01\xe0\xdd\xab\xa0\x50\xf6\xa5\xa2\x64\x00\x12\x3d\
\xf1\x93\x01\xc8\x34\xc5\x4f\x05\xa0\xf6\x34\xc5\x4f\x05\xa0\xf3\
\xde\xa1\x85\x8a\x7b\xd6\x69\x00\x74\xde\x38\x11\x9d\x1b\x5b\x00\
\x72\xa6\xfe\xfd\x4f\x09\xa0\x73\x02\x58\x29\xba\x5e\x9e\x00\x80\
\x58\x28\xcf\x7f\x69\x01\x24\x8a\xb6\x40\xa8\x02\xec\x54\x6c\x82\
\x13\x06\xc8\x98\xe2\xf5\x2f\x31\x80\xc2\x95\x7a\x1a\x80\x3c\x40\
\xe5\xc9\xee\x03\xa4\x0d\xc0\x03\xb5\xf5\x2f\x6a\x00\xe7\xf6\x0b\
\x90\xed\x1b\x7b\x00\x44\xa4\xe8\xfa\x6c\xaa\x00\xed\x1a\x18\xcb\
\x1a\x8b\x00\x62\x55\x17\xc8\x13\x05\xe8\x88\x3f\x6f\x2c\x02\x88\
\x95\x5c\x9d\x4e\x17\x20\x56\xf6\x13\x12\x34\x01\xda\xf3\x9f\x57\
\x36\xf6\x00\x88\xf6\x55\x41\x7e\xd5\xd8\x03\xd0\x11\x7f\xa0\x2b\
\x7e\x1d\x00\xe7\x76\xfe\x13\xd6\x8d\x3d\x00\x7c\xa1\xa5\xfc\x4d\
\x06\x80\x87\x7a\xca\xdf\x54\x00\xea\x76\xfc\x91\x68\xec\x01\xa8\
\x03\x5d\xe5\x6f\x1a\x00\xd5\x37\x6d\xe5\x6f\x12\x00\x95\xaf\xaf\
\xfc\x4d\x01\xa0\xf4\x35\x96\xbf\x09\x00\x14\x9e\xce\xf2\xb7\x7e\
\x80\xe2\x41\x6b\xf9\x5b\x3b\xc0\xc9\xd5\x5b\xfe\xd6\x0d\x90\xbb\
\xca\xfa\xbf\x49\x02\x1c\x5d\xdd\xe5\x6f\xbd\x00\xaf\x4c\x7b\xf9\
\x5b\x2b\x40\x7b\xff\x4f\x7d\xf9\x5b\x27\xc0\x81\x11\x28\x7f\x6b\
\x04\xd8\x33\x0a\xe5\x6f\x7d\x00\x29\x8d\xf2\xb7\x36\x80\x1d\x91\
\xf2\xb7\x2e\x80\x2d\x95\xf2\xb7\x26\x80\x76\x03\xa0\x3f\x45\xf9\
\x5b\x70\x43\x00\x7e\x8c\x3a\xfe\x24\xf8\x5b\x59\x9c\xf2\xec\xb0\
\x4f\xb7\x9b\xf5\x4b\x12\xaf\x96\x51\x18\xf8\x0f\xec\xfe\xdb\x4a\
\x15\x03\x74\x5d\x07\x53\xb7\xc3\xac\xab\xf7\x30\x5f\xdf\xc3\xdc\
\xbd\x87\xf9\xfc\x2b\xcc\xef\x81\xef\xb9\x6a\xae\x93\x92\x09\xf0\
\xd4\x79\x0b\x4a\xba\xdb\xbe\x87\x99\xbc\x87\xb9\xb8\x1a\x66\xff\
\x48\x0d\x00\x90\xf7\xcb\xb3\x53\xde\xac\x2c\x0f\x20\x96\x19\x3f\
\xfd\x39\x40\xac\xa4\xc6\x3f\xdd\x6d\x22\x92\x00\xc4\x52\x6e\xfc\
\x4e\x49\x1b\x40\x44\x92\xe3\x9f\xee\x17\x07\xe5\xfc\xda\xdc\x42\
\x76\xfc\x0e\xa7\x0c\xa0\x20\x7e\xe7\x4c\x18\x80\x87\xf2\xe3\x77\
\x04\x5d\x80\x3a\x50\x10\xff\x74\xd9\xfa\xe4\x00\x6f\x4a\xe2\xa7\
\x0b\x50\xf9\x8e\xd5\x00\xa5\xa2\xf8\xa9\x02\x94\x9e\x63\x35\x40\
\xa1\x2c\x7e\xa2\x00\x2b\x07\x00\x00\x00\x00\x00\x00\xa0\x62\x08\
\xdb\x01\x38\x00\x2c\x07\xa8\x6d\x07\xa8\x6c\x07\x28\x6c\x07\xa0\
\x5e\x16\x37\x67\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\
\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\
\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x60\x2b\x80\
\x6d\x03\x00\x00\x00\xc0\xff\x00\xf6\x0e\x00\x00\x00\x00\x00\xb0\
\x7a\xfc\x0b\x43\xd4\xc6\xc6\x44\x07\xe4\xaa\x00\x00\x00\x00\x49\
\x45\x4e\x44\xae\x42\x60\x82\
\x00\x00\x09\x13\
\x89\
\x50\x4e\x47\x0d\x0a\x1a\x0a\x00\x00\x00\x0d\x49\x48\x44\x52\x00\
\x00\x01\x00\x00\x00\x01\x00\x08\x03\x00\x00\x00\x6b\xac\x58\x54\
\x00\x00\x00\xed\x50\x4c\x54\x45\x78\x00\xf8\x80\x00\xf8\x80\x04\
\xf8\x80\x08\xf8\x80\x0c\xf8\x88\x10\xf8\x88\x14\xf8\x88\x18\xf8\
\x88\x1c\xf8\x88\x20\xf8\x90\x20\xf8\x90\x24\xf8\x90\x28\xf8\x90\
\x2c\xf8\x90\x30\xf8\x98\x30\xf8\x98\x34\xf8\x98\x38\xf8\x98\x3c\
\xf8\x98\x40\xf8\xa0\x40\xf8\xa0\x44\xf8\xa0\x48\xf8\xa0\x4c\xf8\
\xa0\x50\xf8\xa8\x50\xf8\xa8\x54\xf8\xa8\x58\xf8\xa8\x5c\xf8\xa8\
\x60\xf8\xb0\x60\xf8\xb0\x64\xf8\xb0\x68\xf8\xb0\x6c\xf8\xb0\x70\
\xf8\xb8\x70\xf8\xb8\x74\xf8\xb8\x78\xf8\xb8\x7c\xf8\xb8\x80\xf8\
\xc0\x80\xf8\xc0\x84\xf8\xc0\x88\xf8\xc0\x8c\xf8\xc0\x90\xf8\xc8\
\x90\xf8\xc8\x94\xf8\xc8\x98\xf8\xc8\x9c\xf8\xc8\xa0\xf8\xd0\xa0\
\xf8\xd0\xa4\xf8\xd0\xa8\xf8\xd0\xac\xf8\xd0\xb0\xf8\xd8\xb0\xf8\
\xd8\xb4\xf8\xd8\xb8\xf8\xd8\xbc\xf8\xd8\xc0\xf8\xe0\xc0\xf8\xe0\
\xc4\xf8\xe0\xc8\xf8\xe0\xcc\xf8\xe0\xd0\xf8\xe8\xd0\xf8\xe8\xd4\
\xf8\xe8\xd8\xf8\xe8\xdc\xf8\xe8\xe0\xf8\xf0\xe0\xf8\xf0\xe4\xf8\
\xf0\xe8\xf8\xf0\xec\xf8\xf0\xf0\xf8\xf8\xf0\xf8\xf8\xf4\xf8\xf8\
\xf8\xf8\xf8\xfc\xf8\x09\xd1\x39\xc7\x00\x00\x00\x09\x70\x48\x59\
\x73\x00\x00\x00\x48\x00\x00\x00\x48\x00\x46\xc9\x6b\x3e\x00\x00\
\x07\xcc\x49\x44\x41\x54\x78\xda\xed\xdd\x69\x43\xda\x4c\x10\x00\
\xe0\x1c\x50\x90\xa3\x28\x2d\x52\x81\xaa\x78\x03\xe5\xa8\x82\x22\
\x45\xa8\x81\x0a\x91\x64\xfe\xff\xcf\xe9\x87\xbe\xaf\x72\xe4\xce\
\x26\x66\x36\xb3\xdf\x23\xd9\x47\xc8\x31\x3b\x33\x2b\x40\xcc\x87\
\x40\x00\x04\x40\x00\x04\x40\x00\x20\xc4\x70\x10\x00\x01\x10\xc0\
\x26\x40\xac\x2e\x7d\x04\x40\x00\x04\x40\x00\x04\x40\x00\x04\x40\
\x00\x04\x40\x00\x04\x40\x00\x04\x40\x00\x04\x40\x00\x04\x40\x00\
\x04\x40\x00\x04\x40\x00\x04\x40\x00\x04\x40\x00\x04\x40\x00\x04\
\x40\x00\x04\x40\x00\x04\x40\x00\x04\x40\x00\x04\x40\x00\xac\x87\
\xae\x0c\x5a\x67\x95\x2f\xf9\x74\x52\x96\x04\x29\xf1\x29\x9d\x2d\
\x56\xce\x5b\x7d\x45\x8f\x03\x80\xd2\x3d\xfe\x2c\x99\xa4\x2c\x4a\
\x85\x5a\x67\xc6\x33\xc0\xea\xae\x96\xb2\x4d\xdc\x4c\x55\x6f\x5f\
\xb9\x04\xd0\xee\x0e\x25\x87\xc9\xab\xd2\xb7\xbe\xc6\x1b\xc0\xe4\
\x58\x76\x95\xc0\x9b\x38\x9f\x73\x04\xa0\xff\x2c\xb8\xcf\x61\x16\
\x2b\x13\x4e\x00\x5e\x1b\x9f\x3c\xe6\x71\x57\xe7\x1c\x00\xa8\x57\
\x09\xef\x99\xec\xd2\xf9\x0a\x39\xc0\xab\x9f\xe9\x0b\x82\x20\x64\
\xc6\x98\x01\xb4\x56\xd2\x77\x39\x83\x78\xa6\xa1\x05\xb8\x4b\x33\
\xa9\xe8\x38\x58\xe2\x04\x50\xf7\x59\xd5\xb4\xa4\x9f\x51\x02\x3c\
\xb0\xab\xea\x91\xc7\x18\x01\xae\x18\xd6\x35\x25\x9e\x10\x02\x1c\
\xb2\xac\xec\x4a\x4c\xf1\x01\x24\x59\x02\x08\xa9\x25\x36\x80\x39\
\xe3\xea\xbe\xa2\x8e\x0c\xe0\x8e\x75\x7d\xe3\x05\x32\x80\x73\xd6\
\x00\xe2\x04\x17\xc0\x01\xf3\x12\xd7\x7d\x54\x00\xba\xcc\x1c\x40\
\xe8\x60\x02\xf8\x1d\x40\x95\x73\x4a\x47\x04\xd0\x0d\xa2\xce\xfb\
\x16\x11\xc0\x49\x10\x00\x79\x44\x00\xf9\x40\x4a\xfd\x27\x68\x00\
\x34\xd1\xf4\x6e\x96\xab\x5c\x77\x87\x4f\x53\x45\x99\x8e\x07\x9d\
\xcb\xf2\x9e\x1b\x80\x4b\x34\x00\x63\x93\x17\xdb\xb3\xe1\x4e\x8c\
\x6b\xd9\x3f\x71\x1c\x33\xcc\xa1\x01\x68\x19\x86\x79\x47\x66\xf7\
\xcc\x61\xd9\xa1\xc0\x1c\x0b\x40\xd5\x20\xc4\x6b\xb9\xe8\xa5\x54\
\x1c\x01\x0c\xb0\x00\x64\x76\xbe\xbc\xb6\x31\x8d\x51\xd6\x01\xc0\
\x15\x12\x80\xe5\xf6\x89\x9f\x38\x88\x6c\xae\x6a\xf6\x00\x65\x24\
\x00\xc3\xad\x5f\x7f\xcf\xd9\x61\x0d\x5b\x80\xcf\x48\x00\x6e\x36\
\x97\x37\x86\x4e\x8f\x6b\xdb\x2e\x13\x20\x01\xd8\x08\x87\x89\xf7\
\xce\x0f\xbc\xb0\x01\x48\x22\x01\xd8\xb8\xb1\xf7\xdc\x1c\xf9\xc5\
\x26\x28\x80\x03\xe0\xcf\xc6\xf5\xcf\x5d\x24\xcd\x7a\x29\x4d\xc6\
\x01\xd0\x5f\x7f\x81\xd1\xfc\x5c\x3e\x90\xfe\x04\xd6\x7e\xc9\xa2\
\xdb\x78\xf6\xca\x32\x9a\x9c\xc6\x01\x50\xf4\x13\xca\xb4\x0c\x26\
\x16\x71\x00\xbc\x87\xc3\x92\xee\xf3\x9d\x9e\x2d\x53\x26\x50\x00\
\xac\x4d\xe1\x07\x8b\xc7\xe8\xb5\x71\x83\x02\xa0\xe7\x2f\x8a\x67\
\x15\x4c\x1a\xa2\x00\x38\x7d\x3b\xdf\x06\xeb\x70\xe2\x12\x05\xc0\
\x5b\x4a\x98\xac\x7a\x39\xfc\x97\xf9\xfc\x0b\x28\x02\x22\xda\x5b\
\x3e\xe4\x77\x4f\xc7\xbf\x84\xf7\x36\x1c\x0c\xc0\xd3\xdb\xf9\x7a\
\xcb\x6b\x50\xcd\x01\x7e\xa3\x00\x68\xfb\x7c\x75\xd3\x43\x5c\x1c\
\x0b\x04\xa0\xea\x73\x3d\x57\x33\x05\xe8\xe1\x00\xc8\xfa\x8c\xe2\
\x2f\x4d\x9f\x83\x91\x2c\x8d\xfd\xec\xfd\x1b\x3f\x3d\x1e\x3f\xe3\
\x62\x71\x94\x5d\x3c\xed\x3d\xae\xaa\xc7\x04\xc0\x2c\x2e\xf6\x0b\
\x62\x02\x70\x6c\x3c\xff\x13\x88\x0b\x80\xf1\xcb\x50\x4e\x8b\x0b\
\x80\x71\x7a\x99\x1c\x4c\xba\x6c\x14\x01\x9a\x86\xc1\xd0\x07\x88\
\x0d\x40\xce\x08\xe0\x07\xc4\x06\x60\x64\x34\xff\x06\xc4\x07\xa0\
\x18\x42\x1c\x28\xca\x00\x06\x49\xf6\x62\x07\xe2\x03\xf0\xba\x5b\
\x64\x22\x0f\x20\x46\x00\xbb\x2b\xe4\x7b\x53\x88\x11\xc0\x6e\x66\
\x4d\x49\x85\x18\x01\x0c\xb6\x73\xcb\xa4\x56\xc0\x9f\x18\x2d\x80\
\xbb\xed\xf9\xe7\x7e\x43\x9c\x00\x1a\x5b\xf3\x97\xae\x83\x6f\xa8\
\x10\x21\x80\xe5\x76\xa6\x5c\x51\x09\xe1\x53\xa3\x03\xd0\xdb\x5a\
\x14\x4e\xdf\x85\xf2\xb1\x51\x01\x18\x6c\xa5\x16\xcb\x57\xdc\x35\
\x50\xb0\xfa\xf2\xb7\xb6\xde\x7f\xa4\xfa\x32\xac\xcf\xfe\x78\x00\
\xa5\x55\x92\x76\x6a\xe6\x07\x53\x95\x53\x00\x75\xf9\xdf\x58\xcc\
\x95\xa7\x41\xab\x5e\x34\xcd\x08\x4a\xee\xd7\x1a\xc3\x05\x6f\x00\
\xaa\xe8\xb6\x6c\xba\xda\x7d\xe1\x09\x60\xe0\xa5\x48\xa2\xd0\x5c\
\x70\x03\xe0\xb1\x8e\x46\xac\x3c\x71\x02\xb0\x27\x78\x1d\xa5\x09\
\x0f\x00\x33\x3f\xe5\x42\xd5\x17\xfc\x00\x1d\x7f\x15\xf4\x3d\xf4\
\x00\x65\xc1\xdf\x38\x5a\xe1\x06\xd0\x7d\x76\xd4\x11\x84\xac\x82\
\x1a\x60\xec\xbf\x6e\x30\xf9\x84\x19\x80\x45\x53\x11\xf9\x11\x31\
\x00\x93\xb6\x3a\xf2\x08\x2d\x80\xeb\xe7\x60\x93\x9b\x81\x82\x15\
\xa0\xcf\xa8\x7e\x38\xa3\x22\x05\x60\x56\x4f\x5e\x46\x0a\x90\x66\
\x05\x20\x74\x51\x02\xcc\x98\xcd\x5f\x48\x2c\x30\x02\x6c\xa7\x3e\
\x89\x92\x77\x81\x1a\x46\x80\x7f\xa9\x4f\x99\xf2\x45\xe7\x61\x32\
\x57\x35\x00\x00\x6d\x39\x1b\xf5\xae\xca\x29\xf7\x02\x53\x84\x00\
\xfa\x65\xf1\xfa\xd1\xb8\x80\x66\x71\x5b\x71\xf9\x94\x5c\xe1\x2a\
\x2a\x0c\x00\xa0\xdf\x1f\xba\x79\x4c\x10\xe7\xbc\x01\x00\xc0\xfc\
\xd8\x05\xc1\x25\x87\x00\x00\xb3\x23\xe7\x2d\x85\xb8\x04\x00\x18\
\x38\xee\x26\x32\xe6\x13\x00\x96\xa5\x70\x7b\xcb\x45\x2f\x49\x4a\
\xaf\x3b\x03\xf8\xcc\x2b\x80\x49\xa6\xe8\xee\x50\xb9\x05\xb0\xa9\
\x1f\xff\x7f\x8c\xf8\x05\x58\x2b\xbc\xb4\x18\x2d\x8e\x01\x74\x27\
\xcd\x18\x4f\x39\x06\x80\x85\x83\x27\xe3\x12\xcf\x00\x4e\x96\x50\
\xf2\x5c\x03\x38\x08\xa0\xa6\xf8\x06\x18\xd9\x47\x45\xf8\x06\xb0\
\xff\x0a\x48\x9c\x03\xd8\xe6\x52\x88\x9c\x03\xe8\x76\xad\xc9\x93\
\x9c\x03\xd8\x46\xd1\x33\xbc\x03\x3c\xda\xa5\x0e\xf1\x0e\xb0\xb2\
\x89\x0f\x7d\xe5\x1d\xc0\xee\x3e\x70\xc4\x3d\x40\x3d\xc6\xef\x02\
\x00\x60\xdb\x5c\xb1\xc3\x3d\xc0\xd0\x1a\xe0\x89\x7b\x00\xc5\xfa\
\x39\x48\xe3\x1e\x60\x11\x46\x8f\xe9\x28\x03\xbc\x0a\x21\xb4\x95\
\x8b\x32\x80\x6e\x09\xd0\xe6\x1f\x40\xb3\x04\x78\x89\x2c\x80\xfa\
\xc0\xa8\xd6\x7d\x69\x35\x7f\x56\x3d\xa5\x18\x03\xa8\xf7\xe7\x05\
\x91\x55\xd3\x3f\xcb\x9d\x9a\x1a\x51\x04\xb8\xcc\x8b\x2c\xff\x3d\
\x13\x2b\x80\x59\x14\x01\xde\x5b\x1f\x30\x49\xe7\xec\x87\xb1\xd1\
\x02\x53\x80\xb3\xb7\xf3\x3b\x60\x71\x6e\x8d\xe0\xef\x01\x8c\x01\
\xd6\x76\x17\x63\xd1\xf3\xe5\xbb\x45\x34\x48\x8b\x24\x80\xc2\x36\
\x68\x9f\x0d\xa3\xb1\x24\xdb\xbb\xc0\xda\xee\x5a\xfe\xb7\x44\xb2\
\xb8\x0b\x4a\x51\xcd\x13\x5c\x5b\xd2\x4b\xfb\xfe\x92\x5a\x84\x85\
\x19\x76\x15\x63\x0b\x70\xca\xf2\x5b\x6a\xbe\xdf\x86\x34\x8f\x2a\
\xc0\x7a\x43\x60\xf9\x8f\xcf\x07\xe1\x44\x28\xad\x65\xd9\x02\x4c\
\x18\xe6\x74\x9b\xff\x02\xd2\x5a\x64\x01\x36\xf7\xd7\xf2\xd7\x01\
\xe1\x4b\x38\x5b\x0d\x31\x7e\x17\xd8\xb8\x73\x25\xfd\x34\x01\x98\
\x06\x9c\x17\x10\x10\xc0\xe6\x6e\x51\x87\xc0\xea\x2f\xad\x2f\x0a\
\xcf\xa2\x0c\x70\xbd\x79\xb2\x4d\xcf\x7f\xc8\xbc\xc2\xae\x0f\x51\
\x06\xd8\xba\x72\x89\x9e\x33\xb9\x0a\xc1\xae\x06\x04\x06\x30\x63\
\x54\xe1\x65\x9a\x2a\x58\xd0\xa2\x0d\xa0\x6f\x57\x81\xec\x79\x8a\
\x5c\x4d\xcc\x8a\x49\x12\xac\x77\xdb\x63\x1e\x12\xdb\xd9\x68\x33\
\xeb\xe1\xb1\x5d\x35\xdb\x63\x43\x62\xbd\xbf\x04\x7b\x80\xdd\x6d\
\x06\xb3\xae\x9f\x08\x35\xb3\x2c\x41\x31\x80\xde\x4a\xac\x01\x0c\
\x82\x18\x29\x97\xfd\x70\xf5\x72\x88\xad\xc5\x99\x03\x18\x3d\xc0\
\x26\xee\xdd\xfc\x85\x55\x29\xe8\x38\x68\xa0\x00\xc6\xc5\x81\x75\
\xe7\xd7\xee\xc5\x7e\xc0\x05\x02\x01\x03\x80\xf1\xf5\x3b\xeb\xb4\
\x2f\xfa\xd0\xb4\x62\xa4\x09\x38\x00\xcc\xf6\x5b\xae\x3a\xb9\x16\
\xae\xce\x4c\x43\x00\x41\xf5\x96\x63\x0e\x50\x35\x9d\x42\xdd\xf6\
\x91\xe0\xd6\xb4\x82\x32\x31\x02\x2c\x00\x16\xb1\x6c\xa9\x6a\x95\
\xd3\xa0\xf7\x72\xe6\x11\x80\x67\x40\x03\x60\x9d\xe0\x99\xbd\x31\
\x79\x36\x9e\x5e\x58\xd4\xcf\x1e\x06\xd8\x5c\x8f\x39\x80\x6d\x8d\
\x78\xe6\xe4\x76\xeb\x85\x76\xd1\xaf\x5b\xed\x38\x2c\xfd\x00\x40\
\x04\x00\x4e\x6a\xc2\xe5\x42\xe5\xac\xd1\xe9\x76\xdb\x8d\xcb\xea\
\x81\x4d\xa5\x60\x36\xd0\xbe\xca\x01\x00\xe4\x05\xa6\xe3\x78\x05\
\xc8\x00\xaa\x2c\xa7\x9f\x1f\x03\x60\x03\x68\xb0\x9b\x7e\xa2\x8d\
\xb1\xaf\xf0\x03\xb3\xf9\xd7\xc2\xe8\xac\xca\x1e\x60\xce\x68\xfa\
\x47\x53\x00\x94\x00\xeb\x2b\xa4\x9e\x87\x58\x7d\x06\xc0\x0a\xe0\
\xbf\x61\x96\x58\x9b\x01\xe0\x05\xf0\xdb\x2f\x29\xdb\x5c\x00\x60\
\x06\x80\xc7\x6f\xde\x9b\x86\xc9\xdf\xc7\x10\xea\x08\x26\x51\x72\
\x71\x93\xf3\x34\xfb\x72\x6f\x05\xc0\x03\x00\x00\x4c\x2f\x32\x2e\
\x5b\xa4\xd5\x1f\x35\x08\x7f\x04\x99\x2a\xab\xb4\x4a\xce\xee\x08\
\x62\xae\xd6\x56\xe0\x63\x46\xc0\xb9\xc2\xfa\xb4\x5d\xcd\x5b\x29\
\xc8\xd9\x4a\x73\xb4\x82\x8f\x1b\xa1\x24\x4b\xcf\x87\xdd\xab\xe3\
\xc3\x62\x3e\x9d\x4c\xc8\x92\x20\x25\x52\x99\xfc\xfe\xd7\xf2\x69\
\xb3\x3f\x59\xc0\x47\x8f\x28\x67\x8b\x13\x00\x01\x10\x00\x01\x10\
\x00\x01\x10\x00\x01\x10\x00\x01\x10\x00\x01\x10\x00\x01\x10\x00\
\x01\x10\x00\x01\x10\x00\x01\x10\x00\x01\x10\x00\x01\x10\x00\x01\
\x10\x00\x01\x10\x00\x01\x10\x40\x80\x00\x71\x1b\x04\x40\x00\x04\
\xf0\x0e\x10\xdf\x41\x00\x04\x40\x00\x04\x10\xeb\xf1\x17\xe9\x89\
\x47\x68\xda\x1b\x7c\x00\x00\x00\x00\x00\x49\x45\x4e\x44\xae\x42\
\x60\x82\
"
qt_resource_name = "\
\x00\x06\
\x07\x03\x7d\xc3\
\x00\x69\
\x00\x6d\x00\x61\x00\x67\x00\x65\x00\x73\
\x00\x09\
\x0a\x87\xa4\xa7\
\x00\x73\
\x00\x69\x00\x64\x00\x65\x00\x34\x00\x2e\x00\x70\x00\x6e\x00\x67\
\x00\x09\
\x0a\x88\xa4\xa7\
\x00\x73\
\x00\x69\x00\x64\x00\x65\x00\x35\x00\x2e\x00\x70\x00\x6e\x00\x67\
\x00\x09\
\x0a\x89\xa4\xa7\
\x00\x73\
\x00\x69\x00\x64\x00\x65\x00\x36\x00\x2e\x00\x70\x00\x6e\x00\x67\
\x00\x09\
\x0a\x84\xa4\xa7\
\x00\x73\
\x00\x69\x00\x64\x00\x65\x00\x31\x00\x2e\x00\x70\x00\x6e\x00\x67\
\x00\x09\
\x0a\x85\xa4\xa7\
\x00\x73\
\x00\x69\x00\x64\x00\x65\x00\x32\x00\x2e\x00\x70\x00\x6e\x00\x67\
\x00\x09\
\x0a\x86\xa4\xa7\
\x00\x73\
\x00\x69\x00\x64\x00\x65\x00\x33\x00\x2e\x00\x70\x00\x6e\x00\x67\
"
qt_resource_struct = "\
\x00\x00\x00\x00\x00\x02\x00\x00\x00\x01\x00\x00\x00\x01\
\x00\x00\x00\x00\x00\x02\x00\x00\x00\x06\x00\x00\x00\x02\
\x00\x00\x00\x5a\x00\x00\x00\x00\x00\x01\x00\x00\x16\x7f\
\x00\x00\x00\x72\x00\x00\x00\x00\x00\x01\x00\x00\x1a\x97\
\x00\x00\x00\x8a\x00\x00\x00\x00\x00\x01\x00\x00\x21\x83\
\x00\x00\x00\x12\x00\x00\x00\x00\x00\x01\x00\x00\x00\x00\
\x00\x00\x00\x2a\x00\x00\x00\x00\x00\x01\x00\x00\x05\x42\
\x00\x00\x00\x42\x00\x00\x00\x00\x00\x01\x00\x00\x0c\xed\
"
def qInitResources():
QtCore.qRegisterResourceData(0x01, qt_resource_struct, qt_resource_name, qt_resource_data)
def qCleanupResources():
QtCore.qUnregisterResourceData(0x01, qt_resource_struct, qt_resource_name, qt_resource_data)
qInitResources()
| 61.713342
| 96
| 0.726609
| 11,253
| 46,717
| 3.014929
| 0.026571
| 0.09267
| 0.109824
| 0.117429
| 0.16509
| 0.143779
| 0.132638
| 0.129985
| 0.121938
| 0.117605
| 0
| 0.334067
| 0.017403
| 46,717
| 756
| 97
| 61.794974
| 0.405019
| 0.003403
| 0
| 0.069987
| 0
| 0.934051
| 0
| 0
| 0
| 1
| 0.000172
| 0
| 0
| 1
| 0.002692
| false
| 0
| 0.001346
| 0
| 0.004038
| 0
| 0
| 0
| 0
| null | 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| 0
| 0
| 0
| 1
| 0
| 0
| null | 1
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
|
0
| 4
|
fe9a8448b4435f761166925585d16b98f977c2d1
| 9,708
|
py
|
Python
|
lasaft/source_separation/sub_modules/building_blocks.py
|
roger-tseng/Conditioned-Source-Separation-LaSAFT
|
47cf2b7d11ac442f58127afb4ed5a8af360b20d9
|
[
"MIT"
] | 78
|
2020-10-23T20:32:37.000Z
|
2021-11-25T20:00:22.000Z
|
lasaft/source_separation/sub_modules/building_blocks.py
|
ws-choi/LightSAFT-Net-for-MDX-Challenge
|
bd38f44cad681deb7f1cf296b2efdd4c018c8212
|
[
"MIT"
] | 24
|
2020-11-03T02:28:15.000Z
|
2021-08-13T07:38:31.000Z
|
lasaft/source_separation/sub_modules/building_blocks.py
|
ws-choi/LightSAFT-Net-for-MDX-Challenge
|
bd38f44cad681deb7f1cf296b2efdd4c018c8212
|
[
"MIT"
] | 20
|
2020-11-03T01:39:52.000Z
|
2021-11-18T03:42:04.000Z
|
import torch
import torch.nn as nn
class TFC(nn.Module):
""" [B, in_channels, T, F] => [B, gr, T, F] """
def __init__(self, in_channels, num_layers, gr, kt, kf, activation):
"""
in_channels: number of input channels
num_layers: number of densely connected conv layers
gr: growth rate
kt: kernel size of the temporal axis.
kf: kernel size of the freq. axis
activation: activation function
"""
super(TFC, self).__init__()
c = in_channels
self.H = nn.ModuleList()
for i in range(num_layers):
self.H.append(
nn.Sequential(
nn.Conv2d(in_channels=c, out_channels=gr, kernel_size=(kf, kt), stride=1,
padding=(kt // 2, kf // 2)),
nn.BatchNorm2d(gr),
activation(),
)
)
c += gr
self.activation = self.H[-1][-1]
def forward(self, x):
""" [B, in_channels, T, F] => [B, gr, T, F] """
x_ = self.H[0](x)
for h in self.H[1:]:
x = torch.cat((x_, x), 1)
x_ = h(x)
return x_
class DTFC(nn.Module):
""" [B, in_channels, T, F] => [B, gr, T, F] """
def __init__(self, in_channels, out_channels, num_layers, gr, kt, kf, activation):
"""
in_channels: number of input channels
num_layers: number of densely connected conv layers
gr: growth rate
kt: kernel size of the temporal axis.
kf: kernel size of the freq. axis
activation: activation function
"""
super(DTFC, self).__init__()
assert num_layers > 2
self.first_conv = nn.Sequential(
nn.Conv2d(in_channels=in_channels, out_channels=gr, kernel_size=(kf, kt), stride=1,
padding=(kt // 2, kf // 2)),
nn.BatchNorm2d(gr),
activation(),
)
c = gr
d = 1
self.H = nn.ModuleList()
for i in range(num_layers - 2):
self.H.append(
nn.Sequential(
nn.Conv2d(in_channels=c, out_channels=gr, kernel_size=(kf, kt), stride=1,
padding=((kt // 2) * d, (kf // 2) * d), dilation=d),
nn.BatchNorm2d(gr),
activation(),
)
)
c += gr
d += 2
self.last_conv = nn.Sequential(
nn.Conv2d(in_channels=c, out_channels=out_channels, kernel_size=(kf, kt), stride=1,
padding=(kt // 2, kf // 2)),
nn.BatchNorm2d(out_channels),
activation(),
)
self.activation = self.H[-1][-1]
def forward(self, x):
""" [B, in_channels, T, F] => [B, gr, T, F] """
x = self.first_conv(x)
for h in self.H:
x_ = h(x)
x = torch.cat((x_, x), 1)
return self.last_conv(x)
class TDF(nn.Module):
""" [B, in_channels, T, F] => [B, gr, T, F] """
def __init__(self, channels, f, bn_factor=16, bias=False, min_bn_units=16, activation=nn.ReLU):
"""
channels: # channels
f: num of frequency bins
bn_factor: bottleneck factor. if None: single layer. else: MLP that maps f => f//bn_factor => f
bias: bias setting of linear layers
activation: activation function
"""
super(TDF, self).__init__()
if bn_factor is None:
self.tdf = nn.Sequential(
nn.Linear(f, f, bias),
nn.BatchNorm2d(channels),
activation()
)
else:
bn_units = max(f // bn_factor, min_bn_units)
self.bn_units = bn_units
self.tdf = nn.Sequential(
nn.Linear(f, bn_units, bias),
nn.BatchNorm2d(channels),
activation(),
nn.Linear(bn_units, f, bias),
nn.BatchNorm2d(channels),
activation()
)
def forward(self, x):
return self.tdf(x)
class TFC_TDF(nn.Module):
def __init__(self, in_channels, num_layers, gr, kt, kf, f, bn_factor=16, min_bn_units=16, bias=False,
activation=nn.ReLU):
"""
in_channels: number of input channels
num_layers: number of densely connected conv layers
gr: growth rate
kt: kernel size of the temporal axis.
kf: kernel size of the freq. axis
f: num of frequency bins
below are params for TDF
bn_factor: bottleneck factor. if None: single layer. else: MLP that maps f => f//bn_factor => f
bias: bias setting of linear layers
activation: activation function
"""
super(TFC_TDF, self).__init__()
self.tfc = TFC(in_channels, num_layers, gr, kt, kf, activation)
self.tdf = TDF(gr, f, bn_factor, bias, min_bn_units, activation)
self.activation = self.tdf.tdf[-1]
def forward(self, x):
x = self.tfc(x)
return x + self.tdf(x)
class DTFC_TDF(nn.Module):
""" [B, in_channels, T, F] => [B, gr, T, F] """
def __init__(self, in_channels, out_channels, num_layers, gr, kt, kf,
f, bn_factor=16, min_bn_units=16, bias=False, activation=nn.ReLU):
"""
in_channels: number of input channels
num_layers: number of densely connected conv layers
gr: growth rate
kt: kernel size of the temporal axis.
kf: kernel size of the freq. axis
f: num of frequency bins
below are params for TDF
bn_factor: bottleneck factor. if None: single layer. else: MLP that maps f => f//bn_factor => f
bias: bias setting of linear layers
activation: activation function
"""
super(DTFC_TDF, self).__init__()
self.tfc = DTFC(in_channels, out_channels, num_layers, gr, kt, kf, activation)
self.tdf = TDF(out_channels, f, bn_factor, bias, min_bn_units, activation)
self.activation = self.tdf.tdf[-1]
def forward(self, x):
x = self.tfc(x)
return x + self.tdf(x)
class TDF_f1_to_f2(nn.Module):
""" [B, in_channels, T, F] => [B, gr, T, F] """
def __init__(self, channels, f1, f2, bn_factor=16, bias=False, min_bn_units=16, activation=nn.ReLU):
"""
channels: # channels
f1: num of frequency bins (input)
f2: num of frequency bins (output)
bn_factor: bottleneck factor. if None: single layer. else: MLP that maps f => f//bn_factor => f
bias: bias setting of linear layers
activation: activation function
"""
super(TDF_f1_to_f2, self).__init__()
self.num_target_f = f2
if bn_factor is None:
self.tdf = nn.Sequential(
nn.Linear(f1, f2, bias),
nn.BatchNorm2d(channels),
activation()
)
else:
bn_units = max(f2 // bn_factor, min_bn_units)
self.tdf = nn.Sequential(
nn.Linear(f1, bn_units, bias),
nn.BatchNorm2d(channels),
activation(),
nn.Linear(bn_units, f2, bias),
nn.BatchNorm2d(channels),
activation()
)
def forward(self, x):
return self.tdf(x)
class TFC_RNN(nn.Module):
""" [B, in_channels, T, F] => [B, gr, T, F] """
def __init__(self, in_channels, num_layers_tfc, gr, kt, kf,
f, bn_factor_rnn, num_layers_rnn, bidirectional=True, min_bn_units_rnn=16, bias_rnn=True,
bn_factor_tdf=16, bias_tdf=True,
skip_connection=True,
activation=nn.ReLU):
"""
in_channels: number of input channels
num_layers_tfc: number of densely connected conv layers
gr: growth rate
kt: kernel size of the temporal axis.
kf: kernel size of the freq. axis
f: num of frequency bins
bn_factor_rnn: bottleneck factor of rnn
num_layers_rnn: number of layers of rnn
bidirectional: if true then bidirectional version rnn
bn_factor_tdf: bottleneck factor of tdf
bias: bias
skip_connection: if true then tic+rnn else rnn
activation: activation function
"""
super(TFC_RNN, self).__init__()
self.skip_connection = skip_connection
self.tfc = TFC(in_channels, num_layers_tfc, gr, kt, kf, activation)
self.bn = nn.BatchNorm2d(gr)
hidden_units_rnn = max(f // bn_factor_rnn, min_bn_units_rnn)
self.rnn = nn.GRU(f, hidden_units_rnn, num_layers_rnn, bias=bias_rnn, batch_first=True,
bidirectional=bidirectional)
f_from = hidden_units_rnn * 2 if bidirectional else hidden_units_rnn
f_to = f
self.tdf_f1_to_f2 = TDF_f1_to_f2(gr, f_from, f_to, bn_factor=bn_factor_tdf, bias=bias_tdf,
activation=activation)
def forward(self, x):
""" [B, in_channels, T, F] => [B, gr, T, F] """
x = self.tfc(x) # [B, in_channels, T, F] => [B, gr, T, F]
x = self.bn(x) # [B, gr, T, F] => [B, gr, T, F]
tfc_output = x
B, C, T, F = x.shape
x = x.view(-1, T, F)
self.rnn.flatten_parameters()
x, _ = self.rnn(x) # [B * gr, T, F] => [B * gr, T, 2*hidden_size]
x = x.view(B, C, T, -1) # [B * gr, T, 2*hidden_size] => [B, gr, T, 2*hidden_size]
rnn_output = self.tdf_f1_to_f2(x) # [B, gr, T, 2*hidden_size] => [B, gr, T, F]
return tfc_output + rnn_output if self.skip_connection else rnn_output
| 33.133106
| 106
| 0.544293
| 1,302
| 9,708
| 3.865591
| 0.085253
| 0.05762
| 0.014306
| 0.013908
| 0.782635
| 0.757004
| 0.73336
| 0.709319
| 0.684085
| 0.648718
| 0
| 0.013754
| 0.340956
| 9,708
| 292
| 107
| 33.246575
| 0.772898
| 0.281211
| 0
| 0.418301
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0.006536
| 1
| 0.091503
| false
| 0
| 0.013072
| 0.013072
| 0.196078
| 0
| 0
| 0
| 0
| null | 0
| 0
| 0
| 0
| 1
| 1
| 1
| 0
| 1
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| null | 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
|
0
| 4
|
228c77df7dcc541294fe6003162dbf0c5ef8b281
| 346
|
py
|
Python
|
api/tests/python/end_points/test_first_vowels.py
|
sumesh-aot/namex
|
53e11aed5ea550b71b7b983f1b57b65db5a06766
|
[
"Apache-2.0"
] | 4
|
2018-10-05T23:41:05.000Z
|
2019-06-19T16:17:50.000Z
|
api/tests/python/end_points/test_first_vowels.py
|
sumesh-aot/namex
|
53e11aed5ea550b71b7b983f1b57b65db5a06766
|
[
"Apache-2.0"
] | 635
|
2018-05-31T04:12:46.000Z
|
2022-03-31T18:45:42.000Z
|
api/tests/python/end_points/test_first_vowels.py
|
rarmitag/namex
|
1b308bf96130619d4a61d44e075cc7ab177dc6cd
|
[
"Apache-2.0"
] | 71
|
2018-05-14T20:47:55.000Z
|
2022-03-31T23:08:30.000Z
|
from hamcrest import *
from namex.analytics.phonetic import first_vowels
def test_can_extract_o():
assert_that(first_vowels('GOLDSTREAM'), equal_to('O'))
def test_can_extract_ou():
assert_that(first_vowels('CLOUDSIDE'), equal_to('OU'))
def test_resists_no_vowel():
assert_that(first_vowels('KCH'), equal_to(''))
| 21.625
| 59
| 0.713873
| 48
| 346
| 4.75
| 0.5
| 0.192982
| 0.197368
| 0.276316
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0.156069
| 346
| 15
| 60
| 23.066667
| 0.780822
| 0
| 0
| 0
| 0
| 0
| 0.075758
| 0
| 0
| 0
| 0
| 0
| 0.375
| 1
| 0.375
| true
| 0
| 0.25
| 0
| 0.625
| 0
| 0
| 0
| 0
| null | 0
| 1
| 1
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| null | 0
| 0
| 0
| 0
| 0
| 1
| 1
| 0
| 0
| 0
| 0
| 0
|
0
| 4
|
22b615b8b1e2132d9be635a373db9e9561d23095
| 100
|
py
|
Python
|
robots/robot2/config.py
|
memristor/mep2
|
bc5cddacba3d740f791f3454b8cb51bda83ce202
|
[
"MIT"
] | 5
|
2018-11-27T15:15:00.000Z
|
2022-02-10T21:44:13.000Z
|
robots/robot2/config.py
|
memristor/mep2
|
bc5cddacba3d740f791f3454b8cb51bda83ce202
|
[
"MIT"
] | 2
|
2018-10-20T15:48:40.000Z
|
2018-11-20T05:11:33.000Z
|
robots/robot2/config.py
|
memristor/mep2
|
bc5cddacba3d740f791f3454b8cb51bda83ce202
|
[
"MIT"
] | 1
|
2020-02-07T12:44:47.000Z
|
2020-02-07T12:44:47.000Z
|
from modules.default_config import motion, collision_wait_suspend, pathfind
motion.can.iface='can1'
| 33.333333
| 75
| 0.85
| 14
| 100
| 5.857143
| 0.928571
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0.010753
| 0.07
| 100
| 2
| 76
| 50
| 0.870968
| 0
| 0
| 0
| 0
| 0
| 0.04
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| true
| 0
| 0.5
| 0
| 0.5
| 0
| 1
| 0
| 0
| null | 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| null | 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| 1
| 0
| 0
| 0
|
0
| 4
|
22bdb1881643032b6fd02b088b3eaea91461ea33
| 654
|
py
|
Python
|
tests/easy/query/test_util.py
|
lifeomic/phc-sdk-py
|
51709c1c2f129a3fbe336a44e4d501ae0249859e
|
[
"MIT"
] | 1
|
2020-07-22T12:46:58.000Z
|
2020-07-22T12:46:58.000Z
|
tests/easy/query/test_util.py
|
lifeomic/phc-sdk-py
|
51709c1c2f129a3fbe336a44e4d501ae0249859e
|
[
"MIT"
] | 54
|
2019-10-09T16:19:04.000Z
|
2022-01-19T20:28:59.000Z
|
tests/easy/query/test_util.py
|
lifeomic/phc-sdk-py
|
51709c1c2f129a3fbe336a44e4d501ae0249859e
|
[
"MIT"
] | 2
|
2019-10-30T19:54:43.000Z
|
2020-12-03T18:57:15.000Z
|
from phc.easy.query.util import flat_map_pipe
def test_flat_map_pipe_with_list():
def plus_one(x):
return x + 1
def duplicate_and_plus_one(x):
return [x + 1, x + 1]
def duplicate_and_plus_two(x):
return [x + 2, x + 2]
value = flat_map_pipe(
[1, 2, 3], plus_one, duplicate_and_plus_one, duplicate_and_plus_two
)
assert value == [5, 5, 5, 5, 6, 6, 6, 6, 7, 7, 7, 7]
def test_flat_map_pipe():
def plus_one(x):
return x + 1
def duplicate_and_plus_one(x):
return [x + 1, x + 1]
value = flat_map_pipe(1, plus_one, duplicate_and_plus_one)
assert value == [3, 3]
| 21.096774
| 75
| 0.607034
| 114
| 654
| 3.166667
| 0.245614
| 0.155125
| 0.265928
| 0.155125
| 0.722992
| 0.484765
| 0.288089
| 0.288089
| 0.288089
| 0.288089
| 0
| 0.054968
| 0.276758
| 654
| 30
| 76
| 21.8
| 0.708245
| 0
| 0
| 0.421053
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0.105263
| 1
| 0.368421
| false
| 0
| 0.052632
| 0.263158
| 0.684211
| 0
| 0
| 0
| 0
| null | 0
| 1
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| null | 0
| 0
| 0
| 0
| 0
| 1
| 0
| 0
| 0
| 1
| 1
| 0
|
0
| 4
|
22d254097039b048101792f94bc244b9773ccdd5
| 85
|
py
|
Python
|
my_test.py
|
santhosh7403/test-proj
|
81e790e2623ce80a395b7bf3759bfb16cad5a445
|
[
"MIT"
] | null | null | null |
my_test.py
|
santhosh7403/test-proj
|
81e790e2623ce80a395b7bf3759bfb16cad5a445
|
[
"MIT"
] | null | null | null |
my_test.py
|
santhosh7403/test-proj
|
81e790e2623ce80a395b7bf3759bfb16cad5a445
|
[
"MIT"
] | null | null | null |
"""
module docstring for pylint
"""
print("Hello")
print("new line to test")
| 9.444444
| 32
| 0.611765
| 11
| 85
| 4.727273
| 0.909091
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0.223529
| 85
| 8
| 33
| 10.625
| 0.787879
| 0.329412
| 0
| 0
| 0
| 0
| 0.477273
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| true
| 0
| 0
| 0
| 0
| 1
| 1
| 0
| 0
| null | 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| null | 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| 0
| 0
| 0
| 1
|
0
| 4
|
22e6ddd8a4427ef84379ae7d03d41c0b3fcaf8e8
| 113
|
py
|
Python
|
src/west/__init__.py
|
nashif/west
|
2673e8ca87bbacf7b8111f683916bb1f4cc48ffa
|
[
"Apache-2.0"
] | 16
|
2019-10-26T17:09:18.000Z
|
2022-02-21T12:15:32.000Z
|
src/west/__init__.py
|
nashif/west
|
2673e8ca87bbacf7b8111f683916bb1f4cc48ffa
|
[
"Apache-2.0"
] | 44
|
2016-12-08T21:36:34.000Z
|
2017-10-08T23:29:39.000Z
|
src/west/__init__.py
|
nashif/west
|
2673e8ca87bbacf7b8111f683916bb1f4cc48ffa
|
[
"Apache-2.0"
] | 8
|
2016-12-08T21:27:13.000Z
|
2017-04-13T21:26:04.000Z
|
# Copyright 2018 Open Source Foundries Limited.
#
# SPDX-License-Identifier: Apache-2.0
# Nothing here for now.
| 18.833333
| 47
| 0.752212
| 16
| 113
| 5.3125
| 1
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0.0625
| 0.150442
| 113
| 5
| 48
| 22.6
| 0.822917
| 0.911504
| 0
| null | 0
| null | 0
| 0
| null | 0
| 0
| 0
| null | 1
| null | true
| 0
| 0
| null | null | null | 1
| 0
| 0
| null | 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| 0
| 0
| 1
| 0
| 0
| 0
| 0
| 0
| 0
| null | 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| 0
| 0
| 0
| 0
|
0
| 4
|
a3c34a92364776755de95cfa87d5ed08887aa342
| 215
|
py
|
Python
|
opendatatools/fund/__init__.py
|
solider245/OpenData
|
031aa29b7b6b26a903f378e3da10520fd3a1b7ab
|
[
"Apache-2.0"
] | 1,179
|
2018-05-28T07:14:41.000Z
|
2022-03-27T16:03:51.000Z
|
opendatatools/fund/__init__.py
|
taoyeah/OpenData
|
031aa29b7b6b26a903f378e3da10520fd3a1b7ab
|
[
"Apache-2.0"
] | 42
|
2018-07-05T02:44:56.000Z
|
2022-03-29T12:12:30.000Z
|
opendatatools/fund/__init__.py
|
taoyeah/OpenData
|
031aa29b7b6b26a903f378e3da10520fd3a1b7ab
|
[
"Apache-2.0"
] | 297
|
2018-05-28T07:39:38.000Z
|
2022-03-28T02:35:59.000Z
|
# encoding: utf-8
from .fund_interface import *
__all__ = ['get_fund_list',
'get_fund_company', 'get_fundlist_by_company',
'get_fund_type', 'get_fundlist_by_type',
'get_fund_nav']
| 23.888889
| 57
| 0.651163
| 28
| 215
| 4.321429
| 0.535714
| 0.231405
| 0.214876
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0.006061
| 0.232558
| 215
| 8
| 58
| 26.875
| 0.727273
| 0.069767
| 0
| 0
| 0
| 0
| 0.489899
| 0.116162
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| false
| 0
| 0.2
| 0
| 0.2
| 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
| 0
| 0
| 0
| 0
|
0
| 4
|
a3e846ccb424bdc1e7198e9923b14a3d9faf8f7b
| 3,373
|
py
|
Python
|
lpqtree/lpqpydist.py
|
skoudoro/lpqtree
|
8a7ecc9f4c661261249160bdaa6e61e46b3e7ba9
|
[
"BSD-2-Clause"
] | null | null | null |
lpqtree/lpqpydist.py
|
skoudoro/lpqtree
|
8a7ecc9f4c661261249160bdaa6e61e46b3e7ba9
|
[
"BSD-2-Clause"
] | null | null | null |
lpqtree/lpqpydist.py
|
skoudoro/lpqtree
|
8a7ecc9f4c661261249160bdaa6e61e46b3e7ba9
|
[
"BSD-2-Clause"
] | null | null | null |
# Etienne St-Onge
import numpy as np
# Vector norm operator
def l1(vts, axis=-1, keepdims=False):
return np.sum(np.abs(vts), axis=axis, keepdims=keepdims)
def l2(vts, axis=-1, keepdims=False):
return np.sqrt(np.sum(np.square(vts), axis=axis, keepdims=keepdims))
def lp(vts, p, axis=-1, keepdims=False):
inv_p = 1.0/p
return np.sum(np.abs(vts**p), axis=axis, keepdims=keepdims)**inv_p
# Matrix norm operator, along the two last axis
def l11(mts):
# Equivalent to L1 matrix norm
return np.sum(l1(mts, axis=-1, keepdims=False), axis=-1, keepdims=False)
def l12(mts):
return l2(l1(mts, axis=-1, keepdims=False), axis=-1, keepdims=False)
def l21(mts):
return np.sum(l2(mts, axis=-1, keepdims=False), axis=-1, keepdims=False)
def l22(mts):
# Equivalent to L2 matrix norm
return np.sqrt(np.sum(np.sum(np.square(mts), axis=-1, keepdims=False), axis=-1, keepdims=False))
def lp1(mts, p):
return np.sum(lp(mts, p=p, axis=-1, keepdims=False), axis=-1, keepdims=False)
def lp2(mts, p):
return l2(lp(mts, p=p, axis=-1, keepdims=False), axis=-1, keepdims=False)
def l1q(mts, q):
inv_q = 1.0/q
return np.sum(l1(mts, axis=-1, keepdims=False)**q, axis=-1, keepdims=False)**inv_q
def l2q(mts, q):
inv_q = 1.0/q
return np.sum(l2(mts, axis=-1, keepdims=False)**q, axis=-1, keepdims=False)**inv_q
def lpq(mts, p, q):
inv_q = 1.0/q
return np.sum(lp(mts, p=p, axis=-1, keepdims=False)**q, axis=-1, keepdims=False)**inv_q
# Matrix norm operator with mean instead of sum
def l1m(mts):
return np.mean(l1(mts, axis=-1, keepdims=False), axis=-1, keepdims=False)
def l2m(mts):
return np.mean(l2(mts, axis=-1, keepdims=False), axis=-1, keepdims=False)
def lpm(mts, p):
return np.mean(lp(mts, p=p, axis=-1, keepdims=False), axis=-1, keepdims=False)
# Matrix norm switch
def lpq_switch(mts, p, q):
assert (p >= 1)
if q == "m":
if p == 1:
return l1m(mts)
elif p == 2:
return l2m(mts)
else:
return lpm(mts, p=p)
# else:
assert (q >= 1)
if q == 1:
if p == 1:
return l11(mts)
elif p == 2:
return l21(mts)
else:
return lp1(mts, p=p)
if q == 2:
if p == 1:
return l12(mts)
elif p == 2:
return l22(mts)
else:
return lp2(mts, p=p)
# else: # q > 2
if p == 1:
return l1q(mts, q=q)
elif p == 2:
return l2q(mts, q=q)
# else: # p > 2 and q > 2
return lpq(mts, p=p, q=q)
def lpq_str_switch(mts, norm="l22"):
assert len(norm) == 3
assert norm[0].lower() == "l"
p = int(norm[1])
if norm[2] == "m":
q = "m"
else:
q = int(norm[2])
return lpq_switch(mts, p=p, q=q)
# Compute the distance between each pair
def lpq_pairwise(mts1, mts2, p, q):
assert mts1.ndim == 3
assert mts2.ndim == 3
assert np.alltrue(mts1.shape[1:] == mts2.shape[1:])
return lpq_switch(mts1 - mts2, p=p, q=q)
# Compute the distance between all pairs (Warning about memory)
def lpq_allpairs(mts1, mts2, p, q):
assert mts1.ndim == 3
assert mts2.ndim == 3
assert np.alltrue(mts1.shape == mts2.shape)
idx_i, idx_j = np.mgrid[0:mts1.shape[0], 0:mts2.shape[0]]
return lpq_switch(mts1[idx_i] - mts2[idx_j], p=p, q=q)
| 23.753521
| 100
| 0.585829
| 579
| 3,373
| 3.378238
| 0.150259
| 0.069018
| 0.179448
| 0.248466
| 0.562883
| 0.523517
| 0.451431
| 0.421779
| 0.392127
| 0.374744
| 0
| 0.049724
| 0.24874
| 3,373
| 141
| 101
| 23.921986
| 0.722178
| 0.103172
| 0
| 0.22619
| 0
| 0
| 0.002326
| 0
| 0
| 0
| 0
| 0
| 0.119048
| 1
| 0.22619
| false
| 0
| 0.011905
| 0.130952
| 0.595238
| 0
| 0
| 0
| 0
| null | 0
| 0
| 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
| 4
|
430085da8d84ae2711239abf143bcc5f58f1fb46
| 86
|
py
|
Python
|
Python/3dprinter/3dprinter.py
|
rvrheenen/OpenKattis
|
7fd59fcb54e86cdf10f56c580c218c62e584f391
|
[
"MIT"
] | 12
|
2016-10-03T20:43:43.000Z
|
2021-06-12T17:18:42.000Z
|
Python/3dprinter/3dprinter.py
|
rvrheenen/OpenKattis
|
7fd59fcb54e86cdf10f56c580c218c62e584f391
|
[
"MIT"
] | null | null | null |
Python/3dprinter/3dprinter.py
|
rvrheenen/OpenKattis
|
7fd59fcb54e86cdf10f56c580c218c62e584f391
|
[
"MIT"
] | 10
|
2017-11-14T19:56:37.000Z
|
2021-02-02T07:39:57.000Z
|
print((lambda x: (1<<(x-1).bit_length()).bit_length() if x > 2 else x)(int(input())))
| 43
| 85
| 0.604651
| 17
| 86
| 2.941176
| 0.647059
| 0.08
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0.038961
| 0.104651
| 86
| 1
| 86
| 86
| 0.61039
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| true
| 0
| 0
| 0
| 0
| 1
| 1
| 0
| 0
| null | 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| null | 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| 0
| 0
| 0
| 1
|
0
| 4
|
430b5e4f82043d8c9eeffedd399e61242daf7144
| 112
|
py
|
Python
|
run.py
|
KhomenkoAnna/attr_lingvo
|
c1eafb8ae6214acc9b3d662117f2a25106a99fef
|
[
"MIT"
] | null | null | null |
run.py
|
KhomenkoAnna/attr_lingvo
|
c1eafb8ae6214acc9b3d662117f2a25106a99fef
|
[
"MIT"
] | 7
|
2020-07-21T01:39:18.000Z
|
2022-02-19T03:25:01.000Z
|
run.py
|
KhomenkoAnna/attr_lingvo
|
c1eafb8ae6214acc9b3d662117f2a25106a99fef
|
[
"MIT"
] | 1
|
2020-10-27T10:11:25.000Z
|
2020-10-27T10:11:25.000Z
|
from app import app
app.run(host="127.0.0.1", port=5000)
# To Run:
# python run.py
# or
# python -m flask run
| 12.444444
| 36
| 0.651786
| 23
| 112
| 3.173913
| 0.695652
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0.10989
| 0.1875
| 112
| 8
| 37
| 14
| 0.692308
| 0.392857
| 0
| 0
| 0
| 0
| 0.142857
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| true
| 0
| 0.5
| 0
| 0.5
| 0
| 1
| 0
| 0
| null | 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| null | 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| 1
| 0
| 0
| 0
|
0
| 4
|
43147cb9c05fa8b0325ba3b14369527cb89e20fa
| 195
|
py
|
Python
|
src/enums/__init__.py
|
BoaVaga/boavaga_server
|
7d25a68832d3b9f4f5666d0a3d55c99025498511
|
[
"MIT"
] | null | null | null |
src/enums/__init__.py
|
BoaVaga/boavaga_server
|
7d25a68832d3b9f4f5666d0a3d55c99025498511
|
[
"MIT"
] | null | null | null |
src/enums/__init__.py
|
BoaVaga/boavaga_server
|
7d25a68832d3b9f4f5666d0a3d55c99025498511
|
[
"MIT"
] | null | null | null |
from src.enums.upload_status import UploadStatus
from src.enums.estados_enum import EstadosEnum
from src.enums.user_type import UserType
GRAPHQL_SCHEMA_ENUMS = (
EstadosEnum,
UserType
)
| 21.666667
| 48
| 0.810256
| 26
| 195
| 5.884615
| 0.576923
| 0.137255
| 0.235294
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0.138462
| 195
| 8
| 49
| 24.375
| 0.910714
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| false
| 0
| 0.428571
| 0
| 0.428571
| 0
| 1
| 0
| 0
| null | 0
| 1
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| null | 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| 0
| 0
|
0
| 4
|
43478f8b97937ff86fb978a11ddb7db2a20a9e1c
| 215
|
py
|
Python
|
Problems/Palindromic String/palstr.py
|
jamtot/HackerEarth
|
71b919920dbc5b3af3fc49920939bab418455fb6
|
[
"MIT"
] | 3
|
2018-07-17T09:03:02.000Z
|
2020-05-11T18:03:25.000Z
|
Problems/Palindromic String/palstr.py
|
jamtot/HackerEarth
|
71b919920dbc5b3af3fc49920939bab418455fb6
|
[
"MIT"
] | null | null | null |
Problems/Palindromic String/palstr.py
|
jamtot/HackerEarth
|
71b919920dbc5b3af3fc49920939bab418455fb6
|
[
"MIT"
] | 2
|
2016-06-01T13:16:27.000Z
|
2018-09-25T08:32:24.000Z
|
def palindromic(string):
halflen=len(string)/2
if string[:halflen]==string[-halflen:][::-1]:
return "YES"
else:
return "NO"
if __name__ == "__main__":
print palindromic(raw_input())
| 21.5
| 49
| 0.604651
| 25
| 215
| 4.84
| 0.68
| 0.322314
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0.012048
| 0.227907
| 215
| 9
| 50
| 23.888889
| 0.716867
| 0
| 0
| 0
| 0
| 0
| 0.060465
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| null | null | 0
| 0
| null | null | 0.125
| 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
| 1
| 0
| 0
| 0
| 0
| 0
| 0
| 0
|
0
| 4
|
4a34148f947225561be1c4b2338fd483aaefcb50
| 795
|
py
|
Python
|
scrapinsta/domain/providers/IWebdriver.py
|
matheuskolln/scrapinsta
|
47ec816f33a36e8570d4c56f921ba18a2d12a306
|
[
"MIT"
] | 1
|
2021-09-05T05:37:22.000Z
|
2021-09-05T05:37:22.000Z
|
scrapinsta/domain/providers/IWebdriver.py
|
matheuskolln/scrapinsta
|
47ec816f33a36e8570d4c56f921ba18a2d12a306
|
[
"MIT"
] | 13
|
2020-11-06T17:43:46.000Z
|
2021-09-05T00:13:02.000Z
|
scrapinsta/domain/providers/IWebdriver.py
|
matheuskolln/scrapinsta
|
47ec816f33a36e8570d4c56f921ba18a2d12a306
|
[
"MIT"
] | 2
|
2020-11-09T20:39:57.000Z
|
2021-09-05T01:37:29.000Z
|
from abc import ABC, abstractmethod
from typing import Optional
from selenium.webdriver.remote.webelement import WebElement
class IWebdriver(ABC):
"""Abstract class for webdriver."""
@property
@abstractmethod
def client(self) -> Optional[object]:
pass
@abstractmethod
def __init__(self, config) -> None:
pass
@abstractmethod
def quit_driver(self) -> Optional[bool]:
pass
@abstractmethod
def open_url(self, url: str) -> None:
pass
@abstractmethod
def find_element(self, selector: str, type: str) -> WebElement:
pass
@abstractmethod
def send_keys(self, element: WebElement, value: str) -> None:
pass
@abstractmethod
def click(self, element: WebElement) -> None:
pass
| 20.921053
| 67
| 0.649057
| 85
| 795
| 5.976471
| 0.435294
| 0.234252
| 0.248032
| 0.147638
| 0.110236
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0.257862
| 795
| 37
| 68
| 21.486486
| 0.861017
| 0.036478
| 0
| 0.538462
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0.269231
| false
| 0.269231
| 0.115385
| 0
| 0.423077
| 0
| 0
| 0
| 0
| null | 1
| 1
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| null | 0
| 0
| 0
| 0
| 0
| 1
| 0
| 1
| 0
| 0
| 0
| 0
|
0
| 4
|
4a4143edcef7c1eab365fff8a958c5f59a102291
| 3,262
|
py
|
Python
|
tests/test_fuse.py
|
mlzxy/qsparse
|
d236bed4afe68c6dec959d38826e8b3b3b8774b4
|
[
"MIT"
] | 25
|
2021-11-01T14:13:27.000Z
|
2022-03-08T11:41:50.000Z
|
tests/test_fuse.py
|
mlzxy/qsparse
|
d236bed4afe68c6dec959d38826e8b3b3b8774b4
|
[
"MIT"
] | null | null | null |
tests/test_fuse.py
|
mlzxy/qsparse
|
d236bed4afe68c6dec959d38826e8b3b3b8774b4
|
[
"MIT"
] | 2
|
2021-12-16T20:58:16.000Z
|
2021-12-19T03:31:48.000Z
|
import torch
import torch.nn as nn
from qsparse import fuse_bn
def test_conv2d():
net = nn.Sequential(nn.Conv2d(3, 10, 3), nn.BatchNorm2d(10))
net.train()
inputs = torch.randn(10, 3, 32, 32)
nn.init.uniform_(list(net.children())[1].weight)
nn.init.uniform_(list(net.children())[1].bias)
net(inputs)
net.eval()
gt = net(inputs)
net_fused = fuse_bn(net)
pred = net_fused(inputs)
assert "batchnorm" not in str(net_fused).lower()
assert torch.allclose(gt, pred, atol=1e-5)
def test_linear():
net = nn.Sequential(nn.Linear(20, 10), nn.BatchNorm1d(10))
net.train()
inputs = torch.randn(10, 20)
nn.init.uniform_(list(net.children())[1].weight)
nn.init.uniform_(list(net.children())[1].bias)
net(inputs)
net.eval()
gt = net(inputs)
net_fused = fuse_bn(net)
pred = net_fused(inputs)
assert "batchnorm" not in str(net_fused).lower()
assert torch.allclose(gt, pred, atol=1e-5)
def test_deconv2d():
net = nn.Sequential(nn.ConvTranspose2d(3, 10, 3), nn.BatchNorm2d(10))
net.train()
inputs = torch.randn(10, 3, 32, 32)
nn.init.uniform_(list(net.children())[1].weight)
nn.init.uniform_(list(net.children())[1].bias)
net(inputs)
net.eval()
gt = net(inputs)
net_fused = fuse_bn(net)
pred = net_fused(inputs)
assert "batchnorm" not in str(net_fused).lower()
assert torch.allclose(gt, pred, atol=1e-5)
def test_complex_sequential():
inputs = torch.randn(10, 10, 32, 32)
net1 = nn.Sequential(nn.Conv2d(10, 10, 3), nn.BatchNorm2d(10))
net1.train()
nn.init.uniform_(list(net1.children())[1].weight)
nn.init.uniform_(list(net1.children())[1].bias)
net1(inputs)
net2 = nn.Sequential(nn.ConvTranspose2d(10, 10, 3), nn.BatchNorm2d(10))
net2.train()
nn.init.uniform_(list(net2.children())[1].weight)
nn.init.uniform_(list(net2.children())[1].bias)
net2(inputs)
net3 = nn.Sequential(nn.Conv2d(10, 10, 3), nn.BatchNorm2d(10))
net3.train()
nn.init.uniform_(list(net3.children())[1].weight)
nn.init.uniform_(list(net3.children())[1].bias)
net3(inputs)
net4 = nn.Sequential(nn.ConvTranspose2d(10, 10, 3), nn.BatchNorm2d(10))
net4.train()
nn.init.uniform_(list(net4.children())[1].weight)
nn.init.uniform_(list(net4.children())[1].bias)
net4(inputs)
bn = nn.BatchNorm2d(10)
nn.init.uniform_(bn.weight)
nn.init.uniform_(bn.bias)
bn(inputs)
net = nn.Sequential(
net1, nn.Sequential(net3, net4), net2, nn.Conv2d(10, 10, 3), nn.Sequential(bn)
)
net.eval()
gt = net(inputs)
net_fused = fuse_bn(net)
assert "batchnorm" not in str(net_fused).lower()
pred = net_fused(inputs)
assert torch.allclose(gt, pred, atol=1e-5)
def test_data_parallel():
net = nn.Sequential(nn.Linear(20, 10), nn.BatchNorm1d(10))
net.train()
inputs = torch.randn(10, 20)
nn.init.uniform_(list(net.children())[1].weight)
nn.init.uniform_(list(net.children())[1].bias)
net = nn.DataParallel(net)
net(inputs)
net.eval()
gt = net(inputs)
net_fused = fuse_bn(net)
pred = net_fused(inputs)
assert "batchnorm" not in str(net_fused).lower()
assert torch.allclose(gt, pred, atol=1e-5)
| 29.926606
| 86
| 0.649295
| 493
| 3,262
| 4.20284
| 0.109533
| 0.052124
| 0.112934
| 0.131274
| 0.801641
| 0.783301
| 0.776062
| 0.648649
| 0.631274
| 0.631274
| 0
| 0.058824
| 0.18179
| 3,262
| 108
| 87
| 30.203704
| 0.717497
| 0
| 0
| 0.571429
| 0
| 0
| 0.013795
| 0
| 0
| 0
| 0
| 0
| 0.10989
| 1
| 0.054945
| false
| 0
| 0.032967
| 0
| 0.087912
| 0
| 0
| 0
| 0
| null | 0
| 0
| 0
| 1
| 1
| 1
| 0
| 0
| 1
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| null | 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
|
0
| 4
|
4a540ba05da1ca53683ac95f226be539a556efb1
| 254
|
py
|
Python
|
tests/unittests/http_functions/async_return_str/main.py
|
gohar94/azure-functions-python-worker
|
4322e53ddbcc1eea40c1b061b42653336d9003f6
|
[
"MIT"
] | 277
|
2018-01-25T23:13:03.000Z
|
2022-02-22T06:12:04.000Z
|
tests/unittests/http_functions/async_return_str/main.py
|
gohar94/azure-functions-python-worker
|
4322e53ddbcc1eea40c1b061b42653336d9003f6
|
[
"MIT"
] | 731
|
2018-01-18T18:54:38.000Z
|
2022-03-29T00:01:46.000Z
|
tests/unittests/http_functions/async_return_str/main.py
|
YunchuWang/azure-functions-python-worker
|
1f23e038a506c6412e4efbf07eb471a6afab0c2a
|
[
"MIT"
] | 109
|
2018-01-18T02:22:57.000Z
|
2022-02-15T18:59:54.000Z
|
# Copyright (c) Microsoft Corporation. All rights reserved.
# Licensed under the MIT License.
import asyncio
import azure.functions
async def main(req: azure.functions.HttpRequest, context):
await asyncio.sleep(0.1)
return 'Hello Async World!'
| 25.4
| 59
| 0.759843
| 34
| 254
| 5.676471
| 0.852941
| 0.145078
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0.009302
| 0.153543
| 254
| 9
| 60
| 28.222222
| 0.888372
| 0.350394
| 0
| 0
| 0
| 0
| 0.111111
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| true
| 0
| 0.4
| 0
| 0.6
| 0
| 0
| 0
| 0
| null | 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| null | 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| 1
| 0
| 1
| 0
|
0
| 4
|
4a570793d2cc81269969ad28d19ef77d5fb0f627
| 85
|
py
|
Python
|
race/admin.py
|
scottBowles/dnd
|
a1ef333f1a865d51b5426dc4b3493e8437584565
|
[
"MIT"
] | null | null | null |
race/admin.py
|
scottBowles/dnd
|
a1ef333f1a865d51b5426dc4b3493e8437584565
|
[
"MIT"
] | null | null | null |
race/admin.py
|
scottBowles/dnd
|
a1ef333f1a865d51b5426dc4b3493e8437584565
|
[
"MIT"
] | null | null | null |
from django.contrib import admin
from .models import Race
admin.site.register(Race)
| 17
| 32
| 0.811765
| 13
| 85
| 5.307692
| 0.692308
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0.117647
| 85
| 4
| 33
| 21.25
| 0.92
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| true
| 0
| 0.666667
| 0
| 0.666667
| 0
| 1
| 0
| 0
| null | 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| null | 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| 1
| 0
| 0
| 0
|
0
| 4
|
434bf057f7f7dbdabae462cb478f6bf782e98886
| 409
|
py
|
Python
|
games/stumped/__init__.py
|
Ragnyll/mmai-19
|
a78ce9380cf1555d1b1e53c60ea7469939523019
|
[
"MIT"
] | 1
|
2017-04-12T22:02:14.000Z
|
2017-04-12T22:02:14.000Z
|
games/stumped/__init__.py
|
Ragnyll/mmai-19
|
a78ce9380cf1555d1b1e53c60ea7469939523019
|
[
"MIT"
] | null | null | null |
games/stumped/__init__.py
|
Ragnyll/mmai-19
|
a78ce9380cf1555d1b1e53c60ea7469939523019
|
[
"MIT"
] | null | null | null |
# DO NOT MODIFY THESE IMPORTS
from games.stumped.ai import AI
from games.stumped.game import Game
from games.stumped.beaver import Beaver
from games.stumped.game_object import GameObject
from games.stumped.job import Job
from games.stumped.player import Player
from games.stumped.spawner import Spawner
from games.stumped.tile import Tile
# if you need to initialize this module with custom logic do so here
| 34.083333
| 68
| 0.826406
| 67
| 409
| 5.029851
| 0.447761
| 0.21365
| 0.379822
| 0.118694
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0.129584
| 409
| 11
| 69
| 37.181818
| 0.946629
| 0.229829
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| true
| 0
| 1
| 0
| 1
| 0
| 0
| 0
| 0
| null | 1
| 1
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| null | 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| 1
| 0
| 0
| 0
|
0
| 4
|
43565057eed0b13344924898c8c1102ed07f4146
| 162
|
py
|
Python
|
zipline/pipeline/loaders/__init__.py
|
leonarduschen/zipline
|
5e6c9fce7e0f812bd181024ad192ca2976d49667
|
[
"Apache-2.0"
] | 14,525
|
2015-01-01T02:57:52.000Z
|
2022-03-31T18:16:35.000Z
|
zipline/pipeline/loaders/__init__.py
|
leonarduschen/zipline
|
5e6c9fce7e0f812bd181024ad192ca2976d49667
|
[
"Apache-2.0"
] | 2,146
|
2015-01-01T13:03:44.000Z
|
2022-02-22T03:25:28.000Z
|
zipline/pipeline/loaders/__init__.py
|
leonarduschen/zipline
|
5e6c9fce7e0f812bd181024ad192ca2976d49667
|
[
"Apache-2.0"
] | 4,517
|
2015-01-01T14:26:47.000Z
|
2022-03-31T14:38:05.000Z
|
from .equity_pricing_loader import (
EquityPricingLoader,
USEquityPricingLoader,
)
__all__ = [
'EquityPricingLoader',
'USEquityPricingLoader',
]
| 16.2
| 36
| 0.728395
| 10
| 162
| 11.2
| 0.8
| 0.714286
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0.185185
| 162
| 9
| 37
| 18
| 0.848485
| 0
| 0
| 0
| 0
| 0
| 0.246914
| 0.12963
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| false
| 0
| 0.125
| 0
| 0.125
| 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
| 0
| 0
| 0
| 0
|
0
| 4
|
436cecff5aac09206eee1fa9a0c74ea3a5ba0392
| 122
|
py
|
Python
|
math2/physics/consts.py
|
AussieSeaweed/math2
|
9e83fa8a5a5d227d72fec1b08f6759f0f0f41fca
|
[
"MIT"
] | 2
|
2021-03-29T03:15:57.000Z
|
2021-03-29T03:23:21.000Z
|
math2/physics/consts.py
|
AussieSeaweed/math2
|
9e83fa8a5a5d227d72fec1b08f6759f0f0f41fca
|
[
"MIT"
] | 1
|
2021-04-07T11:07:17.000Z
|
2021-04-07T11:07:17.000Z
|
math2/physics/consts.py
|
AussieSeaweed/math2
|
9e83fa8a5a5d227d72fec1b08f6759f0f0f41fca
|
[
"MIT"
] | null | null | null |
boltzmann = 1.380649e-23
ideal_gas = 8.31446261815324
mole = 6.02214076e23
coulomb = 8.9875517923e9
e0 = 8.8541878128e-12
| 20.333333
| 28
| 0.778689
| 18
| 122
| 5.222222
| 0.888889
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0.570093
| 0.122951
| 122
| 5
| 29
| 24.4
| 0.308411
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| false
| 0
| 0
| 0
| 0
| 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 | 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
|
0
| 4
|
4384378ab8a4c0d87213d3db007a7a876b2bc471
| 112
|
py
|
Python
|
docker-images/rasa2/snips_services/__init__.py
|
sanyaade-machine-learning/opensnips_original
|
3c7d4aa2ef7dec7b0b8c532a537b79c3ef9df7cc
|
[
"MIT"
] | 57
|
2017-12-28T22:50:20.000Z
|
2022-01-25T16:05:36.000Z
|
docker-images/rasa2/snips_services/__init__.py
|
sanyaade-machine-learning/opensnips_original
|
3c7d4aa2ef7dec7b0b8c532a537b79c3ef9df7cc
|
[
"MIT"
] | 28
|
2018-04-18T06:45:20.000Z
|
2022-03-08T22:50:50.000Z
|
docker-images/rasa2/snips_services/__init__.py
|
sanyaade-machine-learning/opensnips_original
|
3c7d4aa2ef7dec7b0b8c532a537b79c3ef9df7cc
|
[
"MIT"
] | 18
|
2017-12-27T01:57:14.000Z
|
2021-03-02T14:13:06.000Z
|
# -*-: coding utf-8 -*-
""" snipsskillscore module """
import sys
reload(sys)
sys.setdefaultencoding('utf-8')
| 14
| 31
| 0.660714
| 13
| 112
| 5.692308
| 0.692308
| 0.108108
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0.020619
| 0.133929
| 112
| 7
| 32
| 16
| 0.742268
| 0.410714
| 0
| 0
| 0
| 0
| 0.084746
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| true
| 0
| 0.333333
| 0
| 0.333333
| 0
| 1
| 0
| 0
| null | 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| null | 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| 1
| 0
| 0
| 0
|
0
| 4
|
43a295778e113cf0180b15a930d44a5e37996100
| 5,607
|
py
|
Python
|
src/tests/orga/views/test_orga_views_dashboard.py
|
chriswolfdesign/pretalx
|
fb6bcf090a5c92e55a79851d60dfc716309da557
|
[
"Apache-2.0"
] | null | null | null |
src/tests/orga/views/test_orga_views_dashboard.py
|
chriswolfdesign/pretalx
|
fb6bcf090a5c92e55a79851d60dfc716309da557
|
[
"Apache-2.0"
] | null | null | null |
src/tests/orga/views/test_orga_views_dashboard.py
|
chriswolfdesign/pretalx
|
fb6bcf090a5c92e55a79851d60dfc716309da557
|
[
"Apache-2.0"
] | null | null | null |
import datetime as dt
import pytest
from django.urls import reverse
from django.utils.timezone import now
from django_scopes import scope
@pytest.mark.parametrize("test_user", ("orga", "speaker", "superuser", "None"))
@pytest.mark.parametrize("query", ("", "?q=e"))
@pytest.mark.django_db
def test_dashboard_event_list(
orga_user, orga_client, speaker, event, other_event, test_user, slot, query
):
if test_user == "speaker":
orga_client.force_login(speaker)
elif test_user == "None":
orga_client.logout()
elif test_user == "superuser":
orga_user.is_administrator = True
orga_user.save()
response = orga_client.get(reverse("orga:event.list") + query, follow=True)
if test_user == "speaker":
assert response.status_code == 200
assert event.slug not in response.content.decode()
elif test_user == "orga":
assert response.status_code == 200
assert event.slug in response.content.decode()
assert other_event.slug not in response.content.decode()
elif test_user == "superuser":
assert response.status_code == 200
assert event.slug in response.content.decode(), response.content.decode()
assert other_event.slug in response.content.decode(), response.content.decode()
else:
current_url = response.redirect_chain[-1][0]
assert "login" in current_url
@pytest.mark.parametrize(
"test_user", ("orga", "speaker", "superuser", "reviewer", "None")
)
@pytest.mark.parametrize("query", ("", "?q=e"))
@pytest.mark.django_db
def test_event_dashboard(
orga_user, orga_client, review_user, speaker, event, test_user, slot, query
):
from pretalx.common.models.log import ActivityLog
ActivityLog.objects.create(
event=event,
person=speaker,
content_object=slot.submission,
action_type="pretalx.submission.create",
)
if test_user == "speaker":
orga_client.force_login(speaker)
elif test_user == "None":
orga_client.logout()
elif test_user == "superuser":
orga_user.is_administrator = True
orga_user.save()
elif test_user == "reviewer":
with scope(event=event):
event.active_review_phase.can_see_speaker_names = False
event.active_review_phase.save()
orga_client.force_login(review_user)
response = orga_client.get(event.orga_urls.base + query, follow=True)
if test_user == "speaker":
assert response.status_code == 404
assert event.slug not in response.content.decode()
elif test_user == "orga":
assert response.status_code == 200
assert event.slug in response.content.decode()
assert speaker.name in response.content.decode()
elif test_user == "superuser":
assert response.status_code == 200
assert event.slug in response.content.decode(), response.content.decode()
assert speaker.name in response.content.decode()
elif test_user == "reviewer":
assert not review_user.has_perm("orga.view_speakers", event)
assert response.status_code == 200
assert event.slug in response.content.decode(), response.content.decode()
assert speaker.name not in response.content.decode()
else:
current_url = response.redirect_chain[-1][0]
assert "login" in current_url
@pytest.mark.parametrize("test_user", ("orga", "speaker", "superuser", "None"))
@pytest.mark.django_db
def test_dashboard_organiser_list(
orga_user, orga_client, speaker, event, other_event, test_user
):
if test_user == "speaker":
orga_client.force_login(speaker)
elif test_user == "None":
orga_client.logout()
elif test_user == "superuser":
orga_user.is_administrator = True
orga_user.save()
response = orga_client.get(reverse("orga:organiser.list"), follow=True)
if test_user == "speaker":
assert response.status_code == 404, response.status_code
elif test_user == "orga":
assert event.organiser.name in response.content.decode()
assert other_event.organiser.name not in response.content.decode()
elif test_user == "superuser":
assert (
event.organiser.name in response.content.decode()
), response.content.decode()
assert (
other_event.organiser.name in response.content.decode()
), response.content.decode()
else:
current_url = response.redirect_chain[-1][0]
assert "login" in current_url
@pytest.mark.django_db
def test_event_dashboard_with_talks(event, orga_client, review_user, review, slot):
with scope(event=event):
event.cfp.deadline = now()
event.save()
response = orga_client.get(event.orga_urls.base)
assert response.status_code == 200
@pytest.mark.django_db
def test_event_dashboard_with_accepted(
event, orga_client, review_user, review, slot, accepted_submission
):
with scope(event=event):
event.cfp.deadline = now()
event.save()
response = orga_client.get(event.orga_urls.base)
assert response.status_code == 200
@pytest.mark.django_db
@pytest.mark.parametrize("start_diff,end_diff", ((0, 0), (-3, -3), (3, 3),))
def test_event_dashboard_different_times(event, orga_client, start_diff, end_diff):
with scope(event=event):
today = now().date()
event.date_from = today + dt.timedelta(days=start_diff)
event.date_end = today + dt.timedelta(days=end_diff)
event.save()
response = orga_client.get(event.orga_urls.base)
assert response.status_code == 200
| 36.174194
| 87
| 0.680221
| 716
| 5,607
| 5.125698
| 0.145251
| 0.056676
| 0.125886
| 0.100272
| 0.785831
| 0.766485
| 0.765123
| 0.735695
| 0.7
| 0.683106
| 0
| 0.010069
| 0.202961
| 5,607
| 154
| 88
| 36.409091
| 0.811143
| 0
| 0
| 0.664179
| 0
| 0
| 0.066346
| 0.004459
| 0
| 0
| 0
| 0
| 0.231343
| 1
| 0.044776
| false
| 0
| 0.044776
| 0
| 0.089552
| 0
| 0
| 0
| 0
| null | 0
| 0
| 0
| 0
| 1
| 1
| 1
| 0
| 1
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| null | 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
|
0
| 4
|
43bf85f1f0c740fc91aae0582f625931da112c29
| 6,731
|
py
|
Python
|
apps/api/openapi_server/test/integration/_test_organization_controller.py
|
rrchai/challenge-registry
|
6dcba8f10575820776300a1bcdcfbe924d0cf78a
|
[
"Apache-2.0"
] | 1
|
2022-03-07T13:26:07.000Z
|
2022-03-07T13:26:07.000Z
|
apps/api/openapi_server/test/integration/_test_organization_controller.py
|
rrchai/challenge-registry
|
6dcba8f10575820776300a1bcdcfbe924d0cf78a
|
[
"Apache-2.0"
] | 157
|
2021-06-16T20:45:10.000Z
|
2022-03-05T00:16:06.000Z
|
apps/api/openapi_server/test/integration/_test_organization_controller.py
|
rrchai/challenge-registry
|
6dcba8f10575820776300a1bcdcfbe924d0cf78a
|
[
"Apache-2.0"
] | 6
|
2022-02-13T04:26:07.000Z
|
2022-03-16T14:46:26.000Z
|
# coding: utf-8
from __future__ import absolute_import
import unittest
from flask import json
from openapi_server.dbmodels.organization import Organization as DbOrganization # noqa: E501
from openapi_server.test.integration import BaseTestCase
from openapi_server.test.integration import util
ID_QUERY = [("organizationId", "awesome-organization")]
REQUEST_HEADERS = {
'Accept': "application/json",
'Content-Type': "application/json",
}
RESPONSE_HEADERS = {
'Accept': "application/json",
}
# TODO: mock 500 responses
class TestOrganizationController(BaseTestCase):
"""OrganizationController integration test stubs"""
def setUp(self):
util.connect_db()
DbOrganization.objects.delete()
def tearDown(self):
util.disconnect_db()
def test_create_organization_with_status201(self):
"""Test case for create_organization
Create an organization (201)
"""
organization = {
'name': "name",
'shortName': "shortName",
'url': "https://openapi-generator.tech"
}
response = self.client.open(
"/api/v1/organizations",
method="POST",
headers=REQUEST_HEADERS,
data=json.dumps(organization),
query_string=ID_QUERY
)
self.assertStatus(
response, 201,
f"Response body is: {response.data.decode('utf-8')}"
)
# TODO: update to test for non-JSON connexion request
def test_create_organization_with_status400(self):
"""Test case for create_organization
Create a (non-JSON) organization (400)
"""
organization = {
'name': "name",
'shortName': "shortName",
'url': "https://openapi-generator.tech"
}
response = self.client.open(
"/api/v1/organizations",
method="POST",
headers=REQUEST_HEADERS,
data=organization,
query_string=ID_QUERY
)
self.assert400(
response,
f"Response body is: {response.data.decode('utf-8')}"
)
def test_create_empty_organization_with_status400(self):
"""Test case for create_organization
Create an empty organization with missing required properties (400)
"""
organization = {}
response = self.client.open(
"/api/v1/organizations",
method="POST",
headers=REQUEST_HEADERS,
data=json.dumps(organization),
query_string=ID_QUERY
)
self.assert400(
response,
f"Response body is: {response.data.decode('utf-8')}"
)
def test_create_organization_with_status409(self):
"""Test case for create_organization
Create a duplicate organization (409)
"""
util.create_test_organization("awesome-organization") # duplicated org
organization = {
'name': "name",
'shortName': "shortName",
'url': "https://openapi-generator.tech"
}
response = self.client.open(
"/api/v1/organizations",
method="POST",
headers=REQUEST_HEADERS,
data=json.dumps(organization),
query_string=ID_QUERY
)
self.assertStatus(
response, 409,
f"Response body is: {response.data.decode('utf-8')}"
)
def test_delete_organization_with_status200(self):
"""Test case for delete_organization
Delete an existing organization (200)
"""
organization = util.create_test_organization("awesome-organization")
response = self.client.open(
f"/api/v1/organizations/{organization.id}",
method="DELETE",
headers=RESPONSE_HEADERS
)
self.assert200(
response,
f"Response body is: {response.data.decode('utf-8')}"
)
def test_delete_organization_with_status404(self):
"""Test case for delete_organization
Delete an unknown organization (404)
"""
organization_id = "foo"
response = self.client.open(
f"/api/v1/organizations/{organization_id}",
method="DELETE",
headers=RESPONSE_HEADERS
)
self.assert404(
response,
f"Response body is: {response.data.decode('utf-8')}"
)
def test_get_organization_with_status200(self):
"""Test case for get_organization
Get an existing organization (200)
"""
organization = util.create_test_organization("awesome-organization")
response = self.client.open(
f"/api/v1/organizations/{organization.id}",
method="GET",
headers=RESPONSE_HEADERS
)
self.assert200(
response,
f"Response body is: {response.data.decode('utf-8')}"
)
def test_get_organization_with_status404(self):
"""Test case for get_organization
Get an existing organization (200)
"""
organization_id = "foo"
response = self.client.open(
f"/api/v1/organizations/{organization_id}",
method="GET",
headers=RESPONSE_HEADERS
)
self.assert404(
response,
f"Response body is: {response.data.decode('utf-8')}"
)
def test_list_organizations_with_status200(self):
"""Test case for list_organizations
Get all organizations (200)
"""
util.create_test_organization("awesome-organization")
query_string = [("limit", 10),
("offset", 0)]
response = self.client.open(
"/api/v1/organizations",
method="GET",
headers=RESPONSE_HEADERS,
query_string=query_string
)
self.assert200(
response,
f"Response body is: {response.data.decode('utf-8')}"
)
def test_list_organizations_with_status400(self):
"""Test case for list_organizations
Get all organizations using an invalid query (400)
"""
util.create_test_organization("awesome-organization")
query_string = [("limit", "no-limit"),
("offset", "none")]
response = self.client.open(
"/api/v1/organizations",
method="GET",
headers=RESPONSE_HEADERS,
query_string=query_string
)
self.assert400(
response,
f"Response body is: {response.data.decode('utf-8')}"
)
if __name__ == "__main__":
unittest.main()
| 29.783186
| 93
| 0.579557
| 651
| 6,731
| 5.823349
| 0.179724
| 0.011606
| 0.031654
| 0.039567
| 0.793722
| 0.775257
| 0.738591
| 0.729095
| 0.685835
| 0.616988
| 0
| 0.025991
| 0.314069
| 6,731
| 225
| 94
| 29.915556
| 0.795105
| 0.134155
| 0
| 0.616352
| 0
| 0
| 0.222044
| 0.105752
| 0
| 0
| 0
| 0.008889
| 0.062893
| 1
| 0.075472
| false
| 0
| 0.037736
| 0
| 0.119497
| 0
| 0
| 0
| 0
| null | 0
| 0
| 0
| 0
| 1
| 1
| 1
| 0
| 1
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| null | 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
|
0
| 4
|
43cb0de8975ecc5b9798976e6270975a96e19941
| 286
|
py
|
Python
|
transactions.py
|
diop/Toshitext
|
5c2b36d12c6313c836230bf339c07bc7d9c19c59
|
[
"MIT"
] | 1
|
2019-03-19T21:43:00.000Z
|
2019-03-19T21:43:00.000Z
|
transactions.py
|
diop/Toshitext
|
5c2b36d12c6313c836230bf339c07bc7d9c19c59
|
[
"MIT"
] | null | null | null |
transactions.py
|
diop/Toshitext
|
5c2b36d12c6313c836230bf339c07bc7d9c19c59
|
[
"MIT"
] | null | null | null |
from blockcypher import simple_spend
import requests, json
from_privkey =
to_address =
to_satoshis =
simple_spend(from_privkey='97838249d77bfa65f97be02b63fd1b7bb6a58474c7c22784a0da63993d1c2f90', to_address='C1rGdt7QEPGiwPMFhNKNhHmyoWpa5X92pn', to_satoshis=10000, coin_symbol='bcy')
| 35.75
| 180
| 0.86014
| 28
| 286
| 8.464286
| 0.607143
| 0.092827
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0.196226
| 0.073427
| 286
| 8
| 180
| 35.75
| 0.698113
| 0
| 0
| 0
| 0
| 0
| 0.351916
| 0.341463
| 0
| 0
| 0
| 0
| 0
| 0
| null | null | 0
| 0.333333
| null | null | 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
| 1
| 0
| 0
| 0
| 1
| 0
| 0
| 0
|
0
| 4
|
43d6a782f87e84f89d96bba094e2db1f5558711f
| 160
|
py
|
Python
|
src/amq/random_helper.py
|
aquadrop/memory
|
0f96720abc5cfaddc47c7b461cfd12b2e6cbd9c2
|
[
"MIT"
] | 2
|
2017-10-25T15:17:15.000Z
|
2017-12-05T01:31:51.000Z
|
src/amq/random_helper.py
|
aquadrop/memory
|
0f96720abc5cfaddc47c7b461cfd12b2e6cbd9c2
|
[
"MIT"
] | null | null | null |
src/amq/random_helper.py
|
aquadrop/memory
|
0f96720abc5cfaddc47c7b461cfd12b2e6cbd9c2
|
[
"MIT"
] | 2
|
2017-10-30T07:29:06.000Z
|
2017-12-05T05:50:53.000Z
|
import random
seed = "1234567890abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ"
def random_string(num=16):
return ''.join(random.sample(seed, num))
| 22.857143
| 71
| 0.8
| 15
| 160
| 8.466667
| 0.733333
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0.083333
| 0.1
| 160
| 6
| 72
| 26.666667
| 0.798611
| 0
| 0
| 0
| 0
| 0
| 0.3875
| 0.3875
| 0
| 0
| 0
| 0
| 0
| 1
| 0.25
| false
| 0
| 0.25
| 0.25
| 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
| 0
| 0
| 0
| 1
| 0
| 0
|
0
| 4
|
78e9c516321d0891efee98ac017e0f08444d6464
| 97
|
py
|
Python
|
yawlib/yawol/django/apps.py
|
letuananh/yawlib
|
01cac5ec1eda82d131f00431391594dd52ba1a98
|
[
"MIT"
] | 1
|
2018-10-18T15:42:02.000Z
|
2018-10-18T15:42:02.000Z
|
yawlib/yawol/django/apps.py
|
letuananh/yawlib
|
01cac5ec1eda82d131f00431391594dd52ba1a98
|
[
"MIT"
] | 3
|
2017-01-10T03:39:14.000Z
|
2021-07-05T07:41:40.000Z
|
yawlib/yawol/django/apps.py
|
letuananh/yawlib
|
01cac5ec1eda82d131f00431391594dd52ba1a98
|
[
"MIT"
] | 1
|
2017-07-16T08:30:45.000Z
|
2017-07-16T08:30:45.000Z
|
from django.apps import AppConfig
class YawoldjangoConfig(AppConfig):
name = 'yawoldjango'
| 16.166667
| 35
| 0.773196
| 10
| 97
| 7.5
| 0.9
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0.154639
| 97
| 5
| 36
| 19.4
| 0.914634
| 0
| 0
| 0
| 0
| 0
| 0.113402
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| false
| 0
| 0.333333
| 0
| 1
| 0
| 1
| 0
| 0
| null | 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| null | 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| 1
| 0
|
0
| 4
|
603b6bd7993a1cdcc836d48b5038d5edc1f6ca53
| 237
|
py
|
Python
|
tools/reports/__init__.py
|
limazix/cps863-machine-learning
|
1c53d07e7f9f5e4a48e90c7c4c9006e4f2a8c6b7
|
[
"Apache-2.0"
] | null | null | null |
tools/reports/__init__.py
|
limazix/cps863-machine-learning
|
1c53d07e7f9f5e4a48e90c7c4c9006e4f2a8c6b7
|
[
"Apache-2.0"
] | null | null | null |
tools/reports/__init__.py
|
limazix/cps863-machine-learning
|
1c53d07e7f9f5e4a48e90c7c4c9006e4f2a8c6b7
|
[
"Apache-2.0"
] | 1
|
2021-04-09T14:58:52.000Z
|
2021-04-09T14:58:52.000Z
|
"""
:mod: `reports` -- Report Wrapper
=================================
.. module:: reports
:synopsis: Report building tools
:platform: OpenSuse 15.2 on WSL2 (Windows 10)
.. moduleauthor:: Bruno Lima <blcardoso@cos.ufrj.br>
"""
| 23.7
| 52
| 0.57384
| 25
| 237
| 5.44
| 0.92
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0.029851
| 0.151899
| 237
| 9
| 53
| 26.333333
| 0.646766
| 0.962025
| 0
| null | 0
| null | 0
| 0
| null | 0
| 0
| 0
| null | 1
| null | true
| 0
| 0
| null | null | null | 1
| 0
| 0
| null | 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| 0
| 0
| 1
| 0
| 0
| 0
| 0
| 0
| 0
| null | 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| 0
| 0
| 0
| 0
|
0
| 4
|
606154a71ddc4cb0e8be3d054be80265667d122b
| 75
|
py
|
Python
|
audiomate/formats/__init__.py
|
CostanzoPablo/audiomate
|
080402eadaa81f77f64c8680510a2de64bc18e74
|
[
"MIT"
] | 133
|
2018-05-18T13:54:10.000Z
|
2022-02-15T02:14:20.000Z
|
audiomate/formats/__init__.py
|
CostanzoPablo/audiomate
|
080402eadaa81f77f64c8680510a2de64bc18e74
|
[
"MIT"
] | 68
|
2018-06-03T16:42:09.000Z
|
2021-01-29T10:58:30.000Z
|
audiomate/formats/__init__.py
|
CostanzoPablo/audiomate
|
080402eadaa81f77f64c8680510a2de64bc18e74
|
[
"MIT"
] | 37
|
2018-11-02T02:40:29.000Z
|
2021-11-30T07:44:50.000Z
|
""" This module contains code for working with different file formats. """
| 37.5
| 74
| 0.746667
| 10
| 75
| 5.6
| 1
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0.16
| 75
| 1
| 75
| 75
| 0.888889
| 0.88
| 0
| null | 0
| null | 0
| 0
| null | 0
| 0
| 0
| null | 1
| null | true
| 0
| 0
| null | null | null | 1
| 0
| 0
| null | 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| 0
| 0
| 1
| 0
| 0
| 0
| 0
| 0
| 0
| null | 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| 0
| 0
| 0
| 0
|
0
| 4
|
60621675f3c37375b8388a5c29b106ab0a56e08c
| 111
|
py
|
Python
|
vendor/HoeffdingTree/ht/weightmass.py
|
writ3it/HD_Netezza_in-database_prediction
|
9a89d4618e93ff2cf3b1c16660522c56aae27373
|
[
"MIT"
] | null | null | null |
vendor/HoeffdingTree/ht/weightmass.py
|
writ3it/HD_Netezza_in-database_prediction
|
9a89d4618e93ff2cf3b1c16660522c56aae27373
|
[
"MIT"
] | null | null | null |
vendor/HoeffdingTree/ht/weightmass.py
|
writ3it/HD_Netezza_in-database_prediction
|
9a89d4618e93ff2cf3b1c16660522c56aae27373
|
[
"MIT"
] | 1
|
2019-09-03T03:11:09.000Z
|
2019-09-03T03:11:09.000Z
|
class WeightMass(object):
"""Wrapper for a weight value."""
def __init__(self):
self.weight = 0
| 27.75
| 37
| 0.621622
| 14
| 111
| 4.642857
| 0.857143
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0.011905
| 0.243243
| 111
| 4
| 38
| 27.75
| 0.761905
| 0.243243
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0.333333
| false
| 0
| 0
| 0
| 0.666667
| 0
| 1
| 0
| 0
| null | 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| null | 0
| 0
| 0
| 0
| 0
| 1
| 0
| 0
| 0
| 0
| 1
| 0
|
0
| 4
|
60d01ff47ef5a6ac0578c1944e00df951e9e7901
| 107
|
py
|
Python
|
rockwell/HackathonProject/apps.py
|
Xiangyongluo/Hackathon-Project
|
815eb9b4e1ea9d41d4ddc90e204bbe919b8bc2ba
|
[
"Apache-2.0"
] | null | null | null |
rockwell/HackathonProject/apps.py
|
Xiangyongluo/Hackathon-Project
|
815eb9b4e1ea9d41d4ddc90e204bbe919b8bc2ba
|
[
"Apache-2.0"
] | 1
|
2021-12-04T04:35:52.000Z
|
2021-12-04T04:35:52.000Z
|
rockwell/HackathonProject/apps.py
|
Xiangyongluo/Hackathon-Project
|
815eb9b4e1ea9d41d4ddc90e204bbe919b8bc2ba
|
[
"Apache-2.0"
] | null | null | null |
from django.apps import AppConfig
class HackathonprojectConfig(AppConfig):
name = 'HackathonProject'
| 17.833333
| 40
| 0.794393
| 10
| 107
| 8.5
| 0.9
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0.140187
| 107
| 5
| 41
| 21.4
| 0.923913
| 0
| 0
| 0
| 0
| 0
| 0.149533
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| false
| 0
| 0.333333
| 0
| 1
| 0
| 1
| 0
| 0
| null | 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| null | 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| 1
| 0
|
0
| 4
|
60ebfd39cd9d015849942034592604a20b89a3c8
| 35
|
py
|
Python
|
PCTC/Sample R1/Q3.py
|
object-oriented-human/competitive
|
9e761020e887d8980a39a64eeaeaa39af0ecd777
|
[
"MIT"
] | 1
|
2022-02-21T15:43:01.000Z
|
2022-02-21T15:43:01.000Z
|
PCTC/Sample R1/Q3.py
|
foooop/competitive
|
9e761020e887d8980a39a64eeaeaa39af0ecd777
|
[
"MIT"
] | null | null | null |
PCTC/Sample R1/Q3.py
|
foooop/competitive
|
9e761020e887d8980a39a64eeaeaa39af0ecd777
|
[
"MIT"
] | null | null | null |
s = input()
print((30//len(s)+1)*s)
| 17.5
| 23
| 0.542857
| 8
| 35
| 2.375
| 0.75
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0.09375
| 0.085714
| 35
| 2
| 23
| 17.5
| 0.5
| 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 | 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| null | 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 1
|
0
| 4
|
881432207f8f83a5e747a6429232537134d3cb42
| 2,420
|
py
|
Python
|
examples/simultaneous_translation/eval/agents/word_splitter.py
|
tmtmaj/Exploiting-PrLM-for-NLG-tasks
|
e8752593d3ee881cf9c0fb5ed26d26fcb02e6dd5
|
[
"MIT"
] | null | null | null |
examples/simultaneous_translation/eval/agents/word_splitter.py
|
tmtmaj/Exploiting-PrLM-for-NLG-tasks
|
e8752593d3ee881cf9c0fb5ed26d26fcb02e6dd5
|
[
"MIT"
] | null | null | null |
examples/simultaneous_translation/eval/agents/word_splitter.py
|
tmtmaj/Exploiting-PrLM-for-NLG-tasks
|
e8752593d3ee881cf9c0fb5ed26d26fcb02e6dd5
|
[
"MIT"
] | null | null | null |
# Copyright (c) Facebook, Inc. and its affiliates.
#
# This source code is licensed under the MIT license found in the
# LICENSE file in the root directory of this source tree.
class SubwordSplitter(object):
def process_line(self, string):
raise NotImplementedError
def split(self, string):
raise NotImplementedError
class NoneWordSplitter(object):
def __init__(self, model):
pass
def split(self, string):
return [string]
def process_line(self, string):
return [string]
def finished_word(self, string):
return True
def merge(self, list_of_string):
return "".join(list_of_string)
def last_full_word_step(self, tokens, step):
return len(tokens)
def end_idx_last_full_word(self, tokens):
return len(tokens)
class BPEWordSplitter(object):
# TODO: lock back here
def __init__(self, model_path):
super().__init__()
from subword_nmt.apply_bpe import BPE
with open(model_path) as f:
self.model = BPE(f)
def split(self, string):
return self.model.process_line(string).split()
def end_idx_last_full_word(self, tokens):
# Begin of word indices
bow_indices = [0] + [i + 1 for i, t in enumerate(tokens[1:]) if t[-2:] != '@@']
if len(bow_indices) < 2:
return 0
else:
return bow_indices[-1]
def merge(self, list_of_string):
return " ".join([item.replace("@@", "") for item in list_of_string])
class SentencePieceModelWordSplitter(object):
def __init__(self, model_path):
super().__init__()
import sentencepiece as spm
self.model = spm.SentencePieceProcessor()
self.model.Load(model_path)
def split(self, string):
return self.model.EncodeAsPieces(string)
def end_idx_last_full_word(self, tokens):
# Begin of word indices
bow_indices = [i for i, t in enumerate(tokens) if t[0] == '\u2581']
if len(bow_indices) < 2:
return 0
else:
return bow_indices[-1]
def merge(self, list_of_string):
return self.model.DecodePieces(list_of_string)
SPLITTER_DICT = {
None: NoneWordSplitter,
"BPE": BPEWordSplitter,
"SentencePieceModel": SentencePieceModelWordSplitter,
}
| 26.888889
| 88
| 0.615702
| 293
| 2,420
| 4.866894
| 0.324232
| 0.056802
| 0.050491
| 0.050491
| 0.437588
| 0.352735
| 0.321879
| 0.234923
| 0.186536
| 0.186536
| 0
| 0.008711
| 0.28843
| 2,420
| 89
| 89
| 27.191011
| 0.819396
| 0.096281
| 0
| 0.526316
| 0
| 0
| 0.015311
| 0
| 0
| 0
| 0
| 0.011236
| 0
| 1
| 0.298246
| false
| 0.017544
| 0.035088
| 0.175439
| 0.649123
| 0
| 0
| 0
| 0
| null | 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| null | 0
| 0
| 1
| 0
| 0
| 1
| 0
| 0
| 0
| 1
| 1
| 0
|
0
| 4
|
7163584bf87eb06a15bad68beab4a31d0e55173f
| 118
|
py
|
Python
|
TCC/addon-move.py
|
andredalton/bcc
|
188190e436615e2344d87b722856fa02e6eec9cc
|
[
"Apache-2.0"
] | 1
|
2018-08-02T14:09:26.000Z
|
2018-08-02T14:09:26.000Z
|
TCC/addon-move.py
|
andredalton/bcc
|
188190e436615e2344d87b722856fa02e6eec9cc
|
[
"Apache-2.0"
] | null | null | null |
TCC/addon-move.py
|
andredalton/bcc
|
188190e436615e2344d87b722856fa02e6eec9cc
|
[
"Apache-2.0"
] | 1
|
2020-07-13T04:27:02.000Z
|
2020-07-13T04:27:02.000Z
|
import bby
class MoveOperator(bby.types.Operator):
bl_idname = "object.move_operator"
bl_label = "Move Operator"
| 19.666667
| 39
| 0.762712
| 16
| 118
| 5.4375
| 0.6875
| 0.229885
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0.135593
| 118
| 5
| 40
| 23.6
| 0.852941
| 0
| 0
| 0
| 0
| 0
| 0.279661
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| false
| 0
| 0.25
| 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
| 0
| 0
| 0
| 0
| 1
| 0
|
0
| 4
|
7187eec468b4b2ec00f9ad59ef1a541bf05208b1
| 13
|
py
|
Python
|
data/studio21_generated/introductory/4247/starter_code.py
|
vijaykumawat256/Prompt-Summarization
|
614f5911e2acd2933440d909de2b4f86653dc214
|
[
"Apache-2.0"
] | null | null | null |
data/studio21_generated/introductory/4247/starter_code.py
|
vijaykumawat256/Prompt-Summarization
|
614f5911e2acd2933440d909de2b4f86653dc214
|
[
"Apache-2.0"
] | null | null | null |
data/studio21_generated/introductory/4247/starter_code.py
|
vijaykumawat256/Prompt-Summarization
|
614f5911e2acd2933440d909de2b4f86653dc214
|
[
"Apache-2.0"
] | null | null | null |
def odd(s):
| 6.5
| 11
| 0.538462
| 3
| 13
| 2.333333
| 1
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0.230769
| 13
| 2
| 12
| 6.5
| 0.7
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| null | null | 0
| 0
| null | null | 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
| 1
| 0
| 0
| 0
| 0
| 0
| 0
| 0
|
0
| 4
|
718843813d9621ba1794353fb2f580498f365845
| 179
|
py
|
Python
|
setup.py
|
dyf/dlist
|
bcc944b7b18f194f543e4c16c6b33a8688a98937
|
[
"MIT"
] | null | null | null |
setup.py
|
dyf/dlist
|
bcc944b7b18f194f543e4c16c6b33a8688a98937
|
[
"MIT"
] | null | null | null |
setup.py
|
dyf/dlist
|
bcc944b7b18f194f543e4c16c6b33a8688a98937
|
[
"MIT"
] | null | null | null |
from setuptools import setup, find_packages
setup(
name='dlist',
version='0.1.0',
packages=find_packages('src'),
package_dir={'': 'src'},
license='MIT'
)
| 17.9
| 43
| 0.614525
| 22
| 179
| 4.863636
| 0.727273
| 0.224299
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0.021277
| 0.212291
| 179
| 9
| 44
| 19.888889
| 0.737589
| 0
| 0
| 0
| 0
| 0
| 0.106145
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| true
| 0
| 0.125
| 0
| 0.125
| 0
| 1
| 0
| 0
| null | 1
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| null | 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| 0
| 0
| 0
| 0
|
0
| 4
|
718efc2d15a6bd7ad29e424236f3ad3057586016
| 106
|
py
|
Python
|
restaurant/apps/system/blog/apps.py
|
Frank1963-mpoyi/RUTH-RESTAURANT-BACK-END
|
b2c657b822295b717e699797a12c3db48f8d3b70
|
[
"MIT"
] | null | null | null |
restaurant/apps/system/blog/apps.py
|
Frank1963-mpoyi/RUTH-RESTAURANT-BACK-END
|
b2c657b822295b717e699797a12c3db48f8d3b70
|
[
"MIT"
] | null | null | null |
restaurant/apps/system/blog/apps.py
|
Frank1963-mpoyi/RUTH-RESTAURANT-BACK-END
|
b2c657b822295b717e699797a12c3db48f8d3b70
|
[
"MIT"
] | null | null | null |
from django.apps import AppConfig
class BlogConfig(AppConfig):
name = 'restaurant.apps.system.blog'
| 17.666667
| 40
| 0.764151
| 13
| 106
| 6.230769
| 0.846154
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0.141509
| 106
| 5
| 41
| 21.2
| 0.89011
| 0
| 0
| 0
| 0
| 0
| 0.254717
| 0.254717
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| false
| 0
| 0.333333
| 0
| 1
| 0
| 1
| 0
| 0
| null | 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| null | 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| 1
| 0
|
0
| 4
|
719bffa135a95e199072fe10b49394178d72d276
| 500
|
py
|
Python
|
Program.py
|
SwagataChaudhuri/Mouse-Shaker
|
a424ecc1ffa65ce0b8a1a5e7ad6dfea17ed1b2aa
|
[
"Apache-2.0"
] | null | null | null |
Program.py
|
SwagataChaudhuri/Mouse-Shaker
|
a424ecc1ffa65ce0b8a1a5e7ad6dfea17ed1b2aa
|
[
"Apache-2.0"
] | null | null | null |
Program.py
|
SwagataChaudhuri/Mouse-Shaker
|
a424ecc1ffa65ce0b8a1a5e7ad6dfea17ed1b2aa
|
[
"Apache-2.0"
] | null | null | null |
import ctypes
import time
mouse_event = ctypes.windll.user32.mouse_event
MOUSE_EVENT_MOVE = 0x0001
print("Press Ctrl-C to end Mouse Shaker")
try:
while True:
mouse_event(MOUSE_EVENT_MOVE, 25, 0, 0, 0)
time.sleep(240)
mouse_event(MOUSE_EVENT_MOVE, 0, 25, 0, 0)
time.sleep(240)
mouse_event(MOUSE_EVENT_MOVE, -25, 0, 0, 0)
time.sleep(240)
mouse_event(MOUSE_EVENT_MOVE, 0, -25, 0, 0)
time.sleep(240)
except KeyboardInterrupt:
pass
| 26.315789
| 51
| 0.66
| 77
| 500
| 4.077922
| 0.337662
| 0.350318
| 0.238854
| 0.318471
| 0.598726
| 0.522293
| 0.522293
| 0.522293
| 0.522293
| 0.522293
| 0
| 0.102362
| 0.238
| 500
| 18
| 52
| 27.777778
| 0.721785
| 0
| 0
| 0.235294
| 0
| 0
| 0.064
| 0
| 0
| 0
| 0.012
| 0
| 0
| 1
| 0
| false
| 0.058824
| 0.117647
| 0
| 0.117647
| 0.058824
| 0
| 0
| 0
| null | 1
| 1
| 1
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| null | 0
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| 0
| 0
| 0
|
0
| 4
|
71b761a31eeb871d25432eff783e01a30defbd06
| 2,185
|
py
|
Python
|
fake_entries.py
|
bacarpenter/voice-diary
|
2b76416e0ee029b39b6b65b645dfae2581fb7ed3
|
[
"MIT"
] | null | null | null |
fake_entries.py
|
bacarpenter/voice-diary
|
2b76416e0ee029b39b6b65b645dfae2581fb7ed3
|
[
"MIT"
] | null | null | null |
fake_entries.py
|
bacarpenter/voice-diary
|
2b76416e0ee029b39b6b65b645dfae2581fb7ed3
|
[
"MIT"
] | null | null | null |
import crypto
import database
database.initialize_connection()
key = crypto.convert_passphrase_to_key("1")
i = int(input("# "))
j = 0
while j < i:
title = crypto.encrypt(f"Title #{j}", key)
text = crypto.encrypt(f"Lorem ipsum dolor sit amet, consectetur adipiscing elit. Phasellus id cursus felis. Nunc dolor libero, ultricies ut tellus non, vulputate vestibulum libero. Aenean mattis urna id nibh imperdiet rutrum. Duis a vestibulum eros. Vestibulum sed commodo est, non porta nisi. Fusce congue diam sed tellus vestibulum, et consectetur arcu molestie. Nam eu dolor quis ipsum malesuada gravida eget ac risus. Curabitur fermentum risus vel lectus imperdiet, eu auctor urna eleifend. Etiam odio quam, tincidunt sed consectetur a, finibus sodales justo. Maecenas non metus sed tellus porttitor commodo. Proin pretium arcu quis feugiat finibus. Donec efficitur ligula sit amet nisl suscipit cursus. Morbi nec ante et lorem feugiat tempor. Mauris faucibus maximus velit. Cras at est sapien. Interdum et malesuada fames ac ante ipsum primis in faucibus. Pellentesque nec sem eu enim tristique porttitor sit amet sit amet arcu. Sed in egestas tellus, nec molestie sapien. Cras venenatis eleifend leo, lobortis laoreet tellus vestibulum quis. Nam ut lorem orci. Vestibulum dui arcu, molestie at venenatis at, scelerisque nec libero. Donec eu sodales lorem. Aenean ac eros justo. Fusce id justo libero. Cras posuere nisl a sem lobortis malesuada. Duis vel eleifend quam. Etiam et libero lorem. Nullam sollicitudin massa eu libero semper, vitae tempor mauris tincidunt. Duis sodales eros purus. Donec eu bibendum massa. Curabitur feugiat et tellus vitae ullamcorper. Nullam eget pharetra velit. In malesuada ultricies sagittis. Cras tincidunt erat vitae accumsan scelerisque. Vivamus tempor feugiat nisl. Morbi cursus posuere semper. Donec blandit elementum justo, at eleifend quam molestie eget. Duis eget sem ligula. Cras enim nisi, hendrerit ut posuere ac, volutpat imperdiet risus. Donec vitae sapien nisl. Donec mattis augue id enim pellentesque euismod. Suspendisse aliquet tempus pretium.", key)
database.create_entry(title, text)
j += 1
database.close_connection()
| 136.5625
| 1,909
| 0.800458
| 323
| 2,185
| 5.396285
| 0.448916
| 0.016064
| 0.016064
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0.001618
| 0.151487
| 2,185
| 16
| 1,910
| 136.5625
| 0.938511
| 0
| 0
| 0
| 0
| 0.083333
| 0.86322
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| false
| 0.083333
| 0.166667
| 0
| 0.166667
| 0
| 0
| 0
| 0
| null | 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 1
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| null | 0
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| 0
| 0
| 0
|
0
| 4
|
71c852b6ca15a398c64ff8e6b2ac3d2cf1bdeb76
| 22
|
py
|
Python
|
rrparser/_version.py
|
brsynth/RRParser
|
330604e4a4fa0e4fffb2303d9aa7a48fc149d326
|
[
"MIT"
] | 1
|
2022-01-21T15:21:19.000Z
|
2022-01-21T15:21:19.000Z
|
rrparser/_version.py
|
brsynth/RRParser
|
330604e4a4fa0e4fffb2303d9aa7a48fc149d326
|
[
"MIT"
] | null | null | null |
rrparser/_version.py
|
brsynth/RRParser
|
330604e4a4fa0e4fffb2303d9aa7a48fc149d326
|
[
"MIT"
] | null | null | null |
__version__ = "2.4.5"
| 11
| 21
| 0.636364
| 4
| 22
| 2.5
| 1
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0.157895
| 0.136364
| 22
| 1
| 22
| 22
| 0.368421
| 0
| 0
| 0
| 0
| 0
| 0.227273
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| false
| 0
| 0
| 0
| 0
| 0
| 1
| 1
| 0
| null | 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| 0
| 1
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| null | 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
|
0
| 4
|
e093df3a2e3ab5288e9e03a1bf0e986e1fa833ae
| 3,497
|
py
|
Python
|
excursion/testcases/madgraph5atlasval/share/MadGraph_param_card_SingleVectorLQ_U1_DrellYan.py
|
irinaespejo/excursion
|
c5a5c6d882b8dd1008fbabf1a3b81eaba382bef6
|
[
"Apache-2.0"
] | 2
|
2021-07-09T13:19:06.000Z
|
2021-08-20T14:30:20.000Z
|
excursion/testcases/madgraph5atlasval/share/MadGraph_param_card_SingleVectorLQ_U1_DrellYan.py
|
irinaespejo/excursion
|
c5a5c6d882b8dd1008fbabf1a3b81eaba382bef6
|
[
"Apache-2.0"
] | null | null | null |
excursion/testcases/madgraph5atlasval/share/MadGraph_param_card_SingleVectorLQ_U1_DrellYan.py
|
irinaespejo/excursion
|
c5a5c6d882b8dd1008fbabf1a3b81eaba382bef6
|
[
"Apache-2.0"
] | 4
|
2020-11-02T10:35:02.000Z
|
2022-01-14T18:35:05.000Z
|
######################################################################
## PARAM_CARD AUTOMATICALY GENERATED BY MG5 FOLLOWING UFO MODEL ####
######################################################################
## ##
## Width set on Auto will be computed following the information ##
## present in the decay.py files of the model. ##
## See arXiv:1402.1178 for more details. ##
## ##
######################################################################
###################################
## INFORMATION FOR MASS
###################################
Block mass
5 4.700000e+00 # MB
6 1.720000e+02 # MT
15 1.777000e+00 # MTA
23 9.118760e+01 # MZ
25 1.250000e+02 # MH
9000002 1.000000e+03 # mLQ
## Dependent parameters, given by model restrictions.
## Those values should be edited following the
## analytical expression. MG5 ignores those values
## but they are important for interfacing the output of MG5
## to external program such as Pythia.
1 0.000000 # d : 0.0
2 0.000000 # u : 0.0
3 0.000000 # s : 0.0
4 0.000000 # c : 0.0
11 0.000000 # e- : 0.0
12 0.000000 # ve : 0.0
13 0.000000 # mu- : 0.0
14 0.000000 # vm : 0.0
16 0.000000 # vt : 0.0
21 0.000000 # g : 0.0
22 0.000000 # a : 0.0
24 79.824360 # w+ : cmath.sqrt(MZ__exp__2/2. + cmath.sqrt(MZ__exp__4/4. - (aEW*cmath.pi*MZ__exp__2)/(Gf*sqrt__2)))
###################################
## INFORMATION FOR NPCOUP
###################################
Block npcoup
1 1.000000e+00 # kappa
2 1.000000e+00 # gbmuL
3 0.000000e+00 # gbeL
4 1.000000e+00 # gsmuL
5 0.000000e+00 # gseL
###################################
## INFORMATION FOR SMINPUTS
###################################
Block sminputs
1 1.279000e+02 # aEWM1
2 1.166370e-05 # Gf
3 1.184000e-01 # aS
###################################
## INFORMATION FOR YUKAWA
###################################
Block yukawa
5 4.700000e+00 # ymb
6 1.720000e+02 # ymt
15 1.777000e+00 # ymtau
###################################
## INFORMATION FOR DECAY
###################################
DECAY 6 1.508336e+00 # WT
DECAY 23 2.495200e+00 # WZ
DECAY 24 2.085000e+00 # WW
DECAY 25 4.070000e-03 # WH
DECAY 9000002 1.000000e+01 # wLQ
## Dependent parameters, given by model restrictions.
## Those values should be edited following the
## analytical expression. MG5 ignores those values
## but they are important for interfacing the output of MG5
## to external program such as Pythia.
DECAY 1 0.000000 # d : 0.0
DECAY 2 0.000000 # u : 0.0
DECAY 3 0.000000 # s : 0.0
DECAY 4 0.000000 # c : 0.0
DECAY 5 0.000000 # b : 0.0
DECAY 11 0.000000 # e- : 0.0
DECAY 12 0.000000 # ve : 0.0
DECAY 13 0.000000 # mu- : 0.0
DECAY 14 0.000000 # vm : 0.0
DECAY 15 0.000000 # ta- : 0.0
DECAY 16 0.000000 # vt : 0.0
DECAY 21 0.000000 # g : 0.0
DECAY 22 0.000000 # a : 0.0
#===========================================================
# QUANTUM NUMBERS OF NEW STATE(S) (NON SM PDG CODE)
#===========================================================
Block QNUMBERS 9000002 # vlq
1 2 # 3 times electric charge
2 3 # number of spin states (2S+1)
3 3 # colour rep (1: singlet, 3: triplet, 8: octet)
4 1 # Particle/Antiparticle distinction (0=own anti)
| 34.97
| 117
| 0.477838
| 471
| 3,497
| 3.515924
| 0.356688
| 0.101449
| 0.050725
| 0.013285
| 0.397343
| 0.397343
| 0.237923
| 0.237923
| 0.237923
| 0.237923
| 0
| 0.207132
| 0.246211
| 3,497
| 99
| 118
| 35.323232
| 0.421093
| 0
| 0
| 0.107143
| 1
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| null | null | 0
| 0
| null | null | 0
| 0
| 0
| 0
| null | 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| 0
| 0
| 1
| 0
| 0
| 0
| null | 0
| 0
| 0
| 0
| 1
| 0
| 0
| 0
| 0
| 0
| 0
| 0
|
0
| 4
|
e094e3306d8f87d9423e34ad7d9ae58f09fd3994
| 268
|
py
|
Python
|
club/context_processors.py
|
ujlbu4/vas3k.club
|
1ec907cf7e5ae3a74059cde8729ca0b3e2d55a3e
|
[
"MIT"
] | 2
|
2020-12-31T06:21:54.000Z
|
2021-11-15T15:35:45.000Z
|
club/context_processors.py
|
ujlbu4/vas3k.club
|
1ec907cf7e5ae3a74059cde8729ca0b3e2d55a3e
|
[
"MIT"
] | null | null | null |
club/context_processors.py
|
ujlbu4/vas3k.club
|
1ec907cf7e5ae3a74059cde8729ca0b3e2d55a3e
|
[
"MIT"
] | null | null | null |
from django.conf import settings
from common.data.expertise import EXPERTISE
def settings_processor(request):
return {"settings": settings}
def data_processor(request):
return {
"global_data": {
"expertise": EXPERTISE,
}
}
| 16.75
| 43
| 0.652985
| 27
| 268
| 6.37037
| 0.481481
| 0.151163
| 0.255814
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0.253731
| 268
| 15
| 44
| 17.866667
| 0.86
| 0
| 0
| 0
| 0
| 0
| 0.104478
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0.2
| false
| 0
| 0.2
| 0.2
| 0.6
| 0
| 1
| 0
| 0
| null | 0
| 1
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| null | 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 1
| 0
|
0
| 4
|
e0a5b0bde44a8262513a8a341012154b9f7b3570
| 88
|
py
|
Python
|
__init__.py
|
simran212530/Probability_Gauss_Module
|
26525ca72d7d39e9ff3e3f1e7cd62b3760c7d26a
|
[
"MIT"
] | null | null | null |
__init__.py
|
simran212530/Probability_Gauss_Module
|
26525ca72d7d39e9ff3e3f1e7cd62b3760c7d26a
|
[
"MIT"
] | null | null | null |
__init__.py
|
simran212530/Probability_Gauss_Module
|
26525ca72d7d39e9ff3e3f1e7cd62b3760c7d26a
|
[
"MIT"
] | null | null | null |
from .Gaussiandistribution import Gaussian
from .Binomialdistribution import Binomial
| 29.333333
| 43
| 0.863636
| 8
| 88
| 9.5
| 0.75
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0.113636
| 88
| 2
| 44
| 44
| 0.974359
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| true
| 0
| 1
| 0
| 1
| 0
| 1
| 0
| 0
| null | 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| null | 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| 1
| 0
| 0
| 0
|
0
| 4
|
e0ea9fa2beebcf8b1f9a57118be612fbcaa9dbab
| 22,037
|
py
|
Python
|
near_finder/coordinate_routines.py
|
dbstein/near_finder
|
af5adf47c328e618c5555f9082752049f27492bd
|
[
"Apache-2.0"
] | null | null | null |
near_finder/coordinate_routines.py
|
dbstein/near_finder
|
af5adf47c328e618c5555f9082752049f27492bd
|
[
"Apache-2.0"
] | null | null | null |
near_finder/coordinate_routines.py
|
dbstein/near_finder
|
af5adf47c328e618c5555f9082752049f27492bd
|
[
"Apache-2.0"
] | null | null | null |
import numpy as np
import numba
import scipy
import scipy.interpolate
from near_finder.utilities import fourier_derivative_1d
from near_finder.utilities import interp_fourier as _interp
from near_finder.utilities import have_better_fourier
if have_better_fourier:
from near_finder.utilities import interp_fourier2 as _interp2
def compute_local_coordinates(cx, cy, x, y, newton_tol=1e-12,
interpolation_scheme='nufft', guess_ind=None, verbose=False, max_iterations=30):
"""
Find (s, r) given (x, y) using the coordinates:
x = X(s) + r n_x(s)
y = Y(s) + r n_y(s)
Where X, Y is given by cx, cy
Uses a NUFFT based scheme if interpolation_scheme = 'nufft'
And a polynomail based scheme if interpolation_scheme = 'polyi'
The NUFFT scheme is more accurate and robust;
The polynomial based scheme is more accurate
"""
if interpolation_scheme == 'nufft':
return compute_local_coordinates_nufft(cx, cy, x, y, newton_tol, guess_ind, verbose, max_iterations)
elif interpolation_scheme == 'polyi':
return compute_local_coordinates_polyi(cx, cy, x, y, newton_tol, guess_ind, verbose, max_iterations)
else:
raise Exception('interpolation_scheme not recognized')
def compute_local_coordinates_nufft(cx, cy, x, y, newton_tol=1e-12,
guess_ind=None, verbose=False, max_iterations=30):
"""
Find using the coordinates:
x = X + r n_x
y = Y + r n_y
"""
xshape = x.shape
yshape = y.shape
x = x.flatten()
y = y.flatten()
n = cx.shape[0]
dt = 2*np.pi/n
ts = np.arange(n)*dt
ik = 1j*np.fft.fftfreq(n, dt/(2*np.pi))
# tangent vectors
xp = fourier_derivative_1d(f=cx, d=1, ik=ik, out='f')
yp = fourier_derivative_1d(f=cy, d=1, ik=ik, out='f')
xpp = fourier_derivative_1d(f=cx, d=2, ik=ik, out='f')
ypp = fourier_derivative_1d(f=cy, d=2, ik=ik, out='f')
# speed
sp = np.sqrt(xp*xp + yp*yp)
isp = 1.0/sp
# unit tangent vectors
tx = xp*isp
ty = yp*isp
# unit normal vectors
nx = ty
ny = -tx
# interpolation routines for the necessary objects
if have_better_fourier:
def interp(f):
return _interp2(f)
else:
def interp(f):
return _interp(f, x.size)
nc_i = interp(nx + 1j*ny)
c_i = interp(cx + 1j*cy)
cp_i = interp(xp + 1j*yp)
cpp_i = interp(xpp + 1j*ypp)
# function for computing (d^2)_s and its derivative
def f(t, x, y):
C = c_i(t)
X = C.real
Y = C.imag
Cp = cp_i(t)
Xp = Cp.real
Yp = Cp.imag
return Xp*(X-x) + Yp*(Y-y), X, Y, Xp, Yp
def fp(t, x, y, X, Y, Xp, Yp):
Cpp = cpp_i(t)
Xpp = Cpp.real
Ypp = Cpp.imag
return Xpp*(X-x) + Ypp*(Y-y) + Xp*Xp + Yp*Yp
# brute force find of guess_inds if not provided (slow!)
if guess_ind is None:
guess_ind = np.empty(x.size, dtype=int)
multi_guess_ind_finder(cx, cy, x, y, guess_ind)
# get starting guess
t = ts[guess_ind]
# begin Newton iteration
rem, X, Y, Xp, Yp = f(t, x, y)
mrem = np.abs(rem).max()
if verbose:
print('Newton tol: {:0.2e}'.format(mrem))
iteration = 0
while mrem > newton_tol:
J = fp(t, x, y, X, Y, Xp, Yp)
delt = -rem/J
line_factor = 1.0
while True:
t_new = t + line_factor*delt
rem_new, X, Y, Xp, Yp = f(t_new, x, y)
mrem_new = np.abs(rem_new).max()
try:
rem_new, X, Y, Xp, Yp = f(t_new, x, y)
mrem_new = np.abs(rem_new).max()
testit = True
except:
testit = False
if testit and ((mrem_new < (1-0.5*line_factor)*mrem) or line_factor < 1e-4):
t = t_new
# put theta back in [0, 2 pi]
t[t < 0] += 2*np.pi
t[t > 2*np.pi] -= 2*np.pi
rem = rem_new
mrem = mrem_new
break
line_factor *= 0.5
if verbose:
print('Newton tol: {:0.2e}'.format(mrem))
iteration += 1
if iteration > max_iterations:
raise Exception('Exceeded maximum number of iterations solving for coordinates .')
# need to determine the sign now
C = c_i(t)
X = C.real
Y = C.imag
if True: # use nx, ny from guess_inds to determine sign
NX = nx[guess_ind]
NY = ny[guess_ind]
else: # interpolate to get these
NC = nc_i(t)
NX = NC.real
NY = NC.imag
r = np.hypot(X-x, Y-y)
xe1 = X + r*NX
ye1 = Y + r*NY
err1 = np.hypot(xe1-x, ye1-y)
xe2 = X - r*NX
ye2 = Y - r*NY
err2 = np.hypot(xe2-x, ye2-y)
sign = (err1 < err2).astype(int)*2 - 1
return t, r*sign
snodes = np.linspace(-1, 1, 6)
MAT = np.empty([6,6], dtype=float)
for i in range(6):
MAT[:,i] = np.power(snodes,i)
IMAT = np.linalg.inv(MAT)
@numba.njit(fastmath=True)
def _polyi(f, xx):
n = f.size
h = 2*np.pi/n
ix = int(xx//h)
lb = (ix-2)*h
ub = (ix+3)*h
scalex = 2*((xx-lb)/(ub-lb) - 0.5)
p2 = scalex*scalex
p3 = p2*scalex
p4 = p3*scalex
p5 = p4*scalex
fout = 0.0
for j in range(6):
fout += IMAT[0, j]*f[(ix+j-2) % n]
coef = 0.0
for j in range(6):
coef += IMAT[1, j]*f[(ix+j-2) % n]
fout += coef*scalex
coef = 0.0
for j in range(6):
coef += IMAT[2, j]*f[(ix+j-2) % n]
fout += coef*p2
coef = 0.0
for j in range(6):
coef += IMAT[3, j]*f[(ix+j-2) % n]
fout += coef*p3
coef = 0.0
for j in range(6):
coef += IMAT[4, j]*f[(ix+j-2) % n]
fout += coef*p4
coef = 0.0
for j in range(6):
coef += IMAT[5, j]*f[(ix+j-2) % n]
fout += coef*p5
return fout
@numba.njit(fastmath=True)
def _polyi(f, xx):
n = f.size
h = 2*np.pi/n
ix = int(xx//h)
lb = (ix-2)*h
ub = (ix+3)*h
scalex = 2*((xx-lb)/(ub-lb) - 0.5)
F = np.empty(6, np.float64)
for j in range(6):
F[j] = f[(ix+j-2) % n]
A = IMAT.dot(F)
return A[0] + A[1]*scalex + A[2]*scalex**2 + A[3]*scalex**3 + A[4]*scalex**4 + A[5]*scalex**5
@numba.njit(fastmath=True)
def _polyi_p(f, xx):
n = f.size
h = 2*np.pi/n
ix = int(xx//h)
lb = (ix-2)*h
ub = (ix+3)*h
scalex = 2*((xx-lb)/(ub-lb) - 0.5)
dscale = 2.0/(ub-lb)
F = np.empty(6, np.float64)
for j in range(6):
F[j] = f[(ix+j-2) % n]
A = IMAT.dot(F)
# calculate value
O0 = A[0] + A[1]*scalex + A[2]*scalex**2 + A[3]*scalex**3 + A[4]*scalex**4 + A[5]*scalex**5
# calculate derivative
O1 = A[1] + 2*A[2]*scalex + 3*A[3]*scalex**2 + 4*A[4]*scalex**3 + 5*A[5]*scalex**4
return O0, O1*dscale
@numba.njit(fastmath=True)
def _polyi_pp(f, xx):
n = f.size
h = 2*np.pi/n
ix = int(xx//h)
lb = (ix-2)*h
ub = (ix+3)*h
scalex = 2*((xx-lb)/(ub-lb) - 0.5)
dscale = 2.0/(ub-lb)
F = np.empty(6, np.float64)
for j in range(6):
F[j] = f[(ix+j-2) % n]
A = IMAT.dot(F)
# calculate value
O0 = A[0] + A[1]*scalex + A[2]*scalex**2 + A[3]*scalex**3 + A[4]*scalex**4 + A[5]*scalex**5
# calculate derivative
O1 = A[1] + 2*A[2]*scalex + 3*A[3]*scalex**2 + 4*A[4]*scalex**3 + 5*A[5]*scalex**4
# calculate second derivative
O2 = 2*A[2] + 6*A[3]*scalex + 12*A[4]*scalex**2 + 20*A[5]*scalex**3
return O0, O1*dscale, O2*dscale*dscale
# @numba.njit(fastmath=True)
# def _polyi_(f, xx):
# n = f.size
# h = 2*np.pi/n
# ix = int(xx//h)
# ratx = xx/h - (ix+0.5)
# fout = f[(ix - 2) % n] * (3/256 + ratx*( -9/1920 + ratx*( -5/48/2 + ratx*( 1/8/6 + ratx*( 1/2/24 - 1/8/120*ratx)))))
# fout += f[(ix - 1) % n] * (-25/256 + ratx*( 125/1920 + ratx*( 39/48/2 + ratx*(-13/8/6 + ratx*(-3/2/24 + 5/8/120*ratx)))))
# fout += f[(ix ) % n] * (150/256 + ratx*(-2250/1920 + ratx*(-34/48/2 + ratx*( 34/8/6 + ratx*( 2/2/24 - 10/8/120*ratx)))))
# fout += f[(ix + 1) % n] * (150/256 + ratx*( 2250/1920 + ratx*(-34/48/2 + ratx*(-34/8/6 + ratx*( 2/2/24 + 10/8/120*ratx)))))
# fout += f[(ix + 2) % n] * (-25/256 + ratx*( -125/1920 + ratx*( 39/48/2 + ratx*( 13/8/6 + ratx*(-3/2/24 - 5/8/120*ratx)))))
# fout += f[(ix + 3) % n] * (3/256 + ratx*( 9/1920 + ratx*( -5/48/2 + ratx*( -1/8/6 + ratx*( 1/2/24 + 1/8/120*ratx)))))
# return fout
@numba.njit(parallel=True, fastmath=True)
def multi_polyi(f, xx, out):
for i in numba.prange(xx.size):
out[i] = _polyi(f, xx[i])
@numba.njit(parallel=True, fastmath=True)
def multi_polyi_p(f, xx, out, outp):
for i in numba.prange(xx.size):
out[i], outp[i] = _polyi_p(f, xx[i])
@numba.njit(fastmath=True)
def _f(t, _cx, _cy, x, y):
cx, cxp = _polyi_p(_cx, t)
cy, cyp = _polyi_p(_cy, t)
return cxp*(cx-x) + cyp*(cy-y)
@numba.njit(fastmath=True)
def _f_fp(t, _cx, _cy, x, y):
cx, cxp, cxpp = _polyi_pp(_cx, t)
cy, cyp, cypp = _polyi_pp(_cy, t)
f = cxp*(cx-x) + cyp*(cy-y)
fp = cxpp*(cx-x) + cypp*(cy-y) + cxp*cxp + cyp*cyp
return f, fp
@numba.njit(fastmath=True)
def _newton(t, xi, yi, newton_tol, _cx, _cy, verbose, maxi):
# get initial residual
rem, fp = _f_fp(t, _cx, _cy, xi, yi)
# Newton iteration
iteration = 0
while np.abs(rem) > newton_tol:
# compute step
t = t -rem/fp
rem, fp = _f_fp(t, _cx, _cy, xi, yi)
iteration += 1
if iteration > maxi:
raise Exception('Exceeded maximum number of iterations solving for coordinates.')
if t < 0: t += 2*np.pi
if t >= 2*np.pi: t -= 2*np.pi
return t
@numba.njit(parallel=False, fastmath=True)
def _multi_newton(its, x, y, newton_tol, _cx, _cy, verbose, maxi):
N = x.size
all_t = np.empty(N)
for i in numba.prange(N):
all_t[i] = _newton(its[i], x[i], y[i], newton_tol, _cx, _cy, verbose, maxi)
return all_t
@numba.njit(fastmath=True)
def _guess_ind_finder(cx, cy, x, y):
_min = 1e300
argmin = -1
for i in range(cx.size):
dx = cx[i] - x
dy = cy[i] - y
d = np.sqrt(dx*dx + dy*dy)
if d < _min:
_min = d
argmin = i
return argmin
@numba.njit(fastmath=True, parallel=True)
def multi_guess_ind_finder(cx, cy, x, y, inds):
for j in numba.prange(x.size):
inds[j] = _guess_ind_finder(cx, cy, x[j], y[j])
def compute_local_coordinates_polyi(cx, cy, x, y, newton_tol=1e-12,
guess_ind=None, verbose=False, max_iterations=30):
"""
Find using the coordinates:
x = X + r n_x
y = Y + r n_y
"""
xshape = x.shape
x = x.flatten()
y = y.flatten()
xsize = x.size
n = cx.shape[0]
dt = 2*np.pi/n
ts = np.arange(n)*dt
ik = 1j*np.fft.fftfreq(n, dt/(2*np.pi))
# tangent vectors
xp = fourier_derivative_1d(f=cx, d=1, ik=ik, out='f')
yp = fourier_derivative_1d(f=cy, d=1, ik=ik, out='f')
# speed
sp = np.sqrt(xp*xp + yp*yp)
isp = 1.0/sp
# unit tangent vectors
tx = xp*isp
ty = yp*isp
# unit normal vectors
nx = ty
ny = -tx
# brute force find of guess_inds if not provided (slow!)
if guess_ind is None:
guess_ind = np.empty(x.size, dtype=int)
multi_guess_ind_finder(cx, cy, x, y, guess_ind)
# get starting points (initial guess for t and r)
initial_ts = ts[guess_ind]
# run the multi-newton solver
t = _multi_newton(initial_ts, x, y, newton_tol, cx, cy, verbose, max_iterations)
# need to determine the sign now
X, Y = np.zeros_like(x), np.zeros_like(x)
XP, YP = np.zeros_like(x), np.zeros_like(x)
multi_polyi_p(cx, t, X, XP)
multi_polyi_p(cy, t, Y, YP)
ISP = 1.0/np.sqrt(XP*XP + YP*YP)
NX = YP/ISP
NY = -XP/ISP
r = np.hypot(X-x, Y-y)
xe1 = X + r*NX
ye1 = Y + r*NY
err1 = np.hypot(xe1-x, ye1-y)
xe2 = X - r*NX
ye2 = Y - r*NY
err2 = np.hypot(xe2-x, ye2-y)
sign = (err1 < err2).astype(int)*2 - 1
return t, r*sign
def compute_local_coordinates_old(cx, cy, x, y, newton_tol=1e-12,
interpolation_scheme='nufft', guess_ind=None, verbose=False, max_iterations=30):
"""
Find (s, r) given (x, y) using the coordinates:
x = X(s) + r n_x(s)
y = Y(s) + r n_y(s)
Where X, Y is given by cx, cy
Uses a NUFFT based scheme if interpolation_scheme = 'nufft'
And a polynomail based scheme if interpolation_scheme = 'polyi'
The NUFFT scheme is more accurate and robust;
The polynomial based scheme is more accurate
"""
if interpolation_scheme == 'nufft':
return compute_local_coordinates_nufft_old(cx, cy, x, y, newton_tol, guess_ind, verbose, max_iterations)
elif interpolation_scheme == 'polyi':
return compute_local_coordinates_polyi_old(cx, cy, x, y, newton_tol, guess_ind, verbose, max_iterations)
else:
raise Exception('interpolation_scheme not recognized')
def compute_local_coordinates_nufft_old(cx, cy, x, y, newton_tol=1e-12,
guess_ind=None, verbose=False, max_iterations=30):
"""
Find using the coordinates:
x = X + r n_x
y = Y + r n_y
"""
xshape = x.shape
yshape = y.shape
x = x.flatten()
y = y.flatten()
n = cx.shape[0]
dt = 2*np.pi/n
ts = np.arange(n)*dt
ik = 1j*np.fft.fftfreq(n, dt/(2*np.pi))
# tangent vectors
xp = fourier_derivative_1d(f=cx, d=1, ik=ik, out='f')
yp = fourier_derivative_1d(f=cy, d=1, ik=ik, out='f')
# speed
sp = np.sqrt(xp*xp + yp*yp)
isp = 1.0/sp
# unit tangent vectors
tx = xp*isp
ty = yp*isp
# unit normal vectors
nx = ty
ny = -tx
# derivatives of the normal vector
nxp = fourier_derivative_1d(f=nx, d=1, ik=ik, out='f')
nyp = fourier_derivative_1d(f=ny, d=1, ik=ik, out='f')
# interpolation routines for the necessary objects
if have_better_fourier:
def interp(f):
return _interp2(f)
else:
def interp(f):
return _interp(np.fft.fft(f), x.size)
nx_i = interp(nx)
ny_i = interp(ny)
nxp_i = interp(nxp)
nyp_i = interp(nyp)
x_i = interp(cx)
y_i = interp(cy)
xp_i = interp(xp)
yp_i = interp(yp)
# functions for coordinate transform and its jacobian
def f(t, r):
x = x_i(t) + r*nx_i(t)
y = y_i(t) + r*ny_i(t)
return x, y
def Jac(t, r):
dxdt = xp_i(t) + r*nxp_i(t)
dydt = yp_i(t) + r*nyp_i(t)
dxdr = nx_i(t)
dydr = ny_i(t)
J = np.zeros((t.shape[0],2,2),dtype=float)
J[:,0,0] = dxdt
J[:,0,1] = dydt
J[:,1,0] = dxdr
J[:,1,1] = dydr
return J.transpose((0,2,1))
# brute force find of guess_inds if not provided (slow!)
if guess_ind is None:
xd = x - cx[:,None]
yd = y - cy[:,None]
dd = xd**2 + yd**2
guess_ind = dd.argmin(axis=0)
# get starting points (initial guess for t and r)
t = ts[guess_ind]
cxg = cx[guess_ind]
cyg = cy[guess_ind]
xdg = x - cxg
ydg = y - cyg
r = np.sqrt(xdg**2 + ydg**2)
# how about we re-sign r?
nxg = nx[guess_ind]
nyg = ny[guess_ind]
xcr1 = cxg + r*nxg
ycr1 = cyg + r*nyg
d1 = np.hypot(xcr1-x, ycr1-y)
xcr2 = cxg - r*nxg
ycr2 = cyg - r*nyg
d2 = np.hypot(xcr2-x, ycr2-y)
better2 = d1 > d2
r[better2] *= -1
# begin Newton iteration
xo, yo = f(t, r)
remx = xo - x
remy = yo - y
rem = np.abs(np.sqrt(remx**2 + remy**2)).max()
if verbose:
print('Newton tol: {:0.2e}'.format(rem))
iteration = 0
while rem > newton_tol:
J = Jac(t, r)
delt = -np.linalg.solve(J, np.column_stack([remx, remy]))
line_factor = 1.0
while True:
t_new, r_new = t + line_factor*delt[:,0], r + line_factor*delt[:,1]
try:
xo, yo = f(t_new, r_new)
remx = xo - x
remy = yo - y
rem_new = np.sqrt(remx**2 + remy**2).max()
testit = True
except:
testit = False
if testit and ((rem_new < (1-0.5*line_factor)*rem) or line_factor < 1e-4):
t = t_new
# put theta back in [0, 2 pi]
t[t < 0] += 2*np.pi
t[t > 2*np.pi] -= 2*np.pi
r = r_new
rem = rem_new
break
line_factor *= 0.5
if verbose:
print('Newton tol: {:0.2e}'.format(rem))
iteration += 1
if iteration > max_iterations:
raise Exception('Exceeded maximum number of iterations solving for coordinates .')
return t, r
#### Faster version based on poly interpolation + numba
# LAGRANGE VERSION IS SLOW RIGHT NOW
# Lagrange interpolation matrix
"""
snodes = np.linspace(-1, 1, 6)
MAT = np.empty([6,6], dtype=float)
for i in range(6):
MAT[:,i] = np.power(snodes,i)
IMAT = np.linalg.inv(MAT)
@numba.njit
def _polyi(f, xx):
n = f.size
h = 2*np.pi/n
ix = int(xx//h)
lb = (ix-2)*h
ub = (ix+3)*h
scalex = 2*((xx-lb)/(ub-lb) - 0.5)
p2 = scalex*scalex
p3 = p2*scalex
p4 = p3*scalex
p5 = p4*scalex
ix0 = (ix-2)%n
ix1 = (ix-1)%n
ix2 = (ix )%n
ix3 = (ix+1)%n
ix4 = (ix+2)%n
ix5 = (ix+3)%n
fout = 0.0
for j in range(6):
fout += IMAT[0, j]*f[(ix+j-2) % n]
coef = 0.0
for j in range(6):
coef += IMAT[1, j]*f[(ix+j-2) % n]
fout += coef*scalex
coef = 0.0
for j in range(6):
coef += IMAT[2, j]*f[(ix+j-2) % n]
fout += coef*p2
coef = 0.0
for j in range(6):
coef += IMAT[3, j]*f[(ix+j-2) % n]
fout += coef*p3
coef = 0.0
for j in range(6):
coef += IMAT[4, j]*f[(ix+j-2) % n]
fout += coef*p4
coef = 0.0
for j in range(6):
coef += IMAT[5, j]*f[(ix+j-2) % n]
fout += coef*p5
return fout
#"""
# using this for now, much faster, not as stable...
@numba.njit
def _f_old(t, r, cx, cy, nx, ny):
x = _polyi(cx, t) + r*_polyi(nx, t)
y = _polyi(cy, t) + r*_polyi(ny, t)
return x, y
@numba.njit
def _Jac_old(t, r, xp, yp, nx, ny, nxp, nyp):
J00 = _polyi(xp, t) + r*_polyi(nxp, t)
J01 = _polyi(nx, t)
J10 = _polyi(yp, t) + r*_polyi(nyp, t)
J11 = _polyi(ny, t)
return J00, J01, J10, J11
@numba.njit
def _newton_old(t, r, xi, yi, newton_tol, cx, cy, nx, ny, xp, yp, nxp, nyp, verbose, maxi):
# get initial residual
xo, yo = _f_old(t, r, cx, cy, nx, ny)
remx = xo - xi
remy = yo - yi
rem = np.sqrt(remx**2 + remy**2)
# Newton iteration
iteration = 0
while rem > newton_tol:
# get Jacobian
J00, J01, J10, J11 = _Jac_old(t, r, xp, yp, nx, ny, nxp, nyp)
idetJ = 1.0/(J00*J11-J01*J10)
# compute step
delt = (J01*remy-J11*remx)*idetJ
delr = (J10*remx-J00*remy)*idetJ
# take step with simple line search
line_factor = 1.0
while True:
t_new, r_new = t + line_factor*delt, r + line_factor*delr
xo, yo = _f_old(t_new, r_new, cx, cy, nx, ny)
remx = xo - xi
remy = yo - yi
rem_new = np.sqrt(remx**2 + remy**2)
if (rem_new < (1-0.25*line_factor)*rem) or line_factor < 1e-4:
t = t_new
r = r_new
rem = rem_new
break
line_factor *= 0.5
iteration += 1
if iteration > maxi:
raise Exception('Exceeded maximum number of iterations solving for coordinates.')
if t < 0: t += 2*np.pi
if t >= 2*np.pi: t -= 2*np.pi
return t, r
@numba.njit(parallel=True)
def _multi_newton_old(its, irs, x, y, newton_tol, cx, cy, nx, ny, xp, yp, nxp, nyp, verbose, maxi):
N = x.size
all_r = np.empty(N)
all_t = np.empty(N)
for i in numba.prange(N):
all_t[i], all_r[i] = _newton_old(its[i], irs[i], x[i], y[i], newton_tol, cx, cy, nx, ny, xp, yp, nxp, nyp, verbose, maxi)
return all_t, all_r
def compute_local_coordinates_polyi_old(cx, cy, x, y, newton_tol=1e-12,
guess_ind=None, verbose=False, max_iterations=30):
"""
Find using the coordinates:
x = X + r n_x
y = Y + r n_y
"""
xshape = x.shape
x = x.flatten()
y = y.flatten()
xsize = x.size
n = cx.shape[0]
dt = 2*np.pi/n
ts = np.arange(n)*dt
ik = 1j*np.fft.fftfreq(n, dt/(2*np.pi))
# tangent vectors
xp = fourier_derivative_1d(f=cx, d=1, ik=ik, out='f')
yp = fourier_derivative_1d(f=cy, d=1, ik=ik, out='f')
# speed
sp = np.sqrt(xp*xp + yp*yp)
isp = 1.0/sp
# unit tangent vectors
tx = xp*isp
ty = yp*isp
# unit normal vectors
nx = ty
ny = -tx
# derivatives of the normal vector
nxp = fourier_derivative_1d(f=nx, d=1, ik=ik, out='f')
nyp = fourier_derivative_1d(f=ny, d=1, ik=ik, out='f')
# brute force find of guess_inds if not provided (slow!)
if guess_ind is None:
xd = x - cx[:,None]
yd = y - cy[:,None]
dd = xd**2 + yd**2
guess_ind = dd.argmin(axis=0)
# get starting points (initial guess for t and r)
initial_ts = ts[guess_ind]
cxg = cx[guess_ind]
cyg = cy[guess_ind]
xdg = x - cxg
ydg = y - cyg
initial_rs = np.sqrt(xdg**2 + ydg**2)
# how about we re-sign r?
nxg = nx[guess_ind]
nyg = ny[guess_ind]
xcr1 = cxg + initial_rs*nxg
ycr1 = cyg + initial_rs*nyg
d1 = np.hypot(xcr1-x, ycr1-y)
xcr2 = cxg - initial_rs*nxg
ycr2 = cyg - initial_rs*nyg
d2 = np.hypot(xcr2-x, ycr2-y)
better2 = d1 > d2
initial_rs[better2] *= -1
# run the multi-newton solver
all_t, all_r = _multi_newton_old(initial_ts, initial_rs, x, y, newton_tol, cx, cy, nx, ny, xp, yp, nxp, nyp, verbose, max_iterations)
return all_t, all_r
| 28.996053
| 137
| 0.541498
| 3,775
| 22,037
| 3.056954
| 0.086623
| 0.007799
| 0.011265
| 0.008319
| 0.790035
| 0.761352
| 0.721057
| 0.705806
| 0.689341
| 0.664125
| 0
| 0.046355
| 0.303989
| 22,037
| 759
| 138
| 29.034256
| 0.706024
| 0.156873
| 0
| 0.623016
| 0
| 0
| 0.025564
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0.059524
| false
| 0
| 0.015873
| 0.007937
| 0.132937
| 0.007937
| 0
| 0
| 0
| null | 0
| 0
| 0
| 0
| 1
| 1
| 1
| 0
| 1
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| null | 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
|
0
| 4
|
e0fcc9e2813b2f179ad23da7b97ede10bd2e217d
| 215
|
py
|
Python
|
playground/module_all_calls.py
|
pwwang/python-varname
|
d5eade2698284cf27ae0659b0bab1fcdee833b78
|
[
"MIT"
] | 167
|
2020-01-15T17:15:32.000Z
|
2022-03-29T18:23:05.000Z
|
playground/module_all_calls.py
|
un1tz3r0/python-varname
|
d5eade2698284cf27ae0659b0bab1fcdee833b78
|
[
"MIT"
] | 45
|
2020-02-19T22:55:28.000Z
|
2022-03-28T11:43:40.000Z
|
playground/module_all_calls.py
|
un1tz3r0/python-varname
|
d5eade2698284cf27ae0659b0bab1fcdee833b78
|
[
"MIT"
] | 16
|
2020-07-26T18:49:46.000Z
|
2022-02-23T16:54:39.000Z
|
import sys
from varname import varname
def func():
# all calls from this module will be ignored
return varname(ignore=sys.modules[__name__])
def func2():
return func()
def func3():
return func2()
| 16.538462
| 48
| 0.693023
| 30
| 215
| 4.833333
| 0.633333
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0.017751
| 0.213953
| 215
| 12
| 49
| 17.916667
| 0.840237
| 0.195349
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0.375
| true
| 0
| 0.25
| 0.375
| 1
| 0
| 0
| 0
| 0
| null | 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| null | 0
| 0
| 0
| 0
| 0
| 1
| 1
| 0
| 0
| 1
| 1
| 0
|
0
| 4
|
46053e959de95fb7456de6ee50259ada107f8d3a
| 157
|
py
|
Python
|
FusionIIIT/applications/establishment/urls.py
|
ajwad-shaikh/Fusion
|
0274387f5fc6e53cde85267924df8c65d666ea68
|
[
"bzip2-1.0.6"
] | 2
|
2020-06-17T11:59:08.000Z
|
2020-07-10T12:17:35.000Z
|
FusionIIIT/applications/establishment/urls.py
|
ajwad-shaikh/Fusion
|
0274387f5fc6e53cde85267924df8c65d666ea68
|
[
"bzip2-1.0.6"
] | 19
|
2019-09-08T06:01:14.000Z
|
2020-05-21T09:08:20.000Z
|
FusionIIIT/applications/establishment/urls.py
|
ajwad-shaikh/Fusion
|
0274387f5fc6e53cde85267924df8c65d666ea68
|
[
"bzip2-1.0.6"
] | 14
|
2019-08-31T12:25:42.000Z
|
2022-01-12T08:05:33.000Z
|
from django.conf.urls import url
from . import views
app_name = 'establishment'
urlpatterns = [
url(r'^$', views.establishment, name='establishment')
]
| 19.625
| 57
| 0.719745
| 19
| 157
| 5.894737
| 0.631579
| 0.303571
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0.146497
| 157
| 8
| 58
| 19.625
| 0.835821
| 0
| 0
| 0
| 0
| 0
| 0.177215
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| false
| 0
| 0.333333
| 0
| 0.333333
| 0
| 1
| 0
| 0
| null | 1
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| null | 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| 0
| 0
|
0
| 4
|
4612dd2b521a4f4ab732729569a2104e8878bd68
| 231
|
py
|
Python
|
sims/s228/mkmovie.py
|
ammarhakim/ammar-simjournal
|
85b64ddc9556f01a4fab37977864a7d878eac637
|
[
"MIT",
"Unlicense"
] | 1
|
2019-12-19T16:21:13.000Z
|
2019-12-19T16:21:13.000Z
|
sims/s228/mkmovie.py
|
ammarhakim/ammar-simjournal
|
85b64ddc9556f01a4fab37977864a7d878eac637
|
[
"MIT",
"Unlicense"
] | null | null | null |
sims/s228/mkmovie.py
|
ammarhakim/ammar-simjournal
|
85b64ddc9556f01a4fab37977864a7d878eac637
|
[
"MIT",
"Unlicense"
] | 2
|
2020-01-08T06:23:33.000Z
|
2020-01-08T07:06:50.000Z
|
import os
for i in range(21):
cmd = "/Users/ahakim/research/gkeyll-project/gkeyllall/gkeyll/scripts/gkeplot.py -p s228-gemguide-5m_q_%d.h5 -c 3 --dont-show --save -o gemguide-5m_%05d" % (i, i)
print cmd
os.system(cmd)
| 33
| 166
| 0.683983
| 41
| 231
| 3.780488
| 0.804878
| 0.129032
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0.05641
| 0.155844
| 231
| 6
| 167
| 38.5
| 0.738462
| 0
| 0
| 0
| 0
| 0.2
| 0.627706
| 0.419913
| 0
| 0
| 0
| 0
| 0
| 0
| null | null | 0
| 0.2
| null | null | 0.2
| 0
| 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
| 1
| 1
| null | 0
| 0
| 0
| 0
| 1
| 0
| 0
| 0
| 0
| 0
| 0
| 0
|
0
| 4
|
1cc680528377937e7bd5440d0a704c60acc04b2d
| 475
|
py
|
Python
|
stories/admin.py
|
City-of-Helsinki/aggregaattori
|
be38b167220ab371975b705dd7f3bbe494afc9e9
|
[
"MIT"
] | 1
|
2017-08-11T06:50:20.000Z
|
2017-08-11T06:50:20.000Z
|
stories/admin.py
|
City-of-Helsinki/aggregaattori
|
be38b167220ab371975b705dd7f3bbe494afc9e9
|
[
"MIT"
] | 37
|
2017-08-11T06:38:06.000Z
|
2020-06-05T17:07:47.000Z
|
stories/admin.py
|
City-of-Helsinki/aggregaattori
|
be38b167220ab371975b705dd7f3bbe494afc9e9
|
[
"MIT"
] | null | null | null |
from django.contrib import admin
from django.contrib.gis.admin import OSMGeoAdmin
from munigeo.models import AdministrativeDivisionGeometry
from parler.admin import TranslatableAdmin
from stories.models import Story
class StoryAdmin(OSMGeoAdmin, TranslatableAdmin):
pass
class AdministrativeDivisionGeometryAdmin(OSMGeoAdmin):
pass
admin.site.register(Story, StoryAdmin)
admin.site.register(AdministrativeDivisionGeometry, AdministrativeDivisionGeometryAdmin)
| 25
| 88
| 0.852632
| 46
| 475
| 8.804348
| 0.434783
| 0.049383
| 0.083951
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0.096842
| 475
| 18
| 89
| 26.388889
| 0.944056
| 0
| 0
| 0.181818
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| true
| 0.181818
| 0.454545
| 0
| 0.636364
| 0
| 0
| 0
| 0
| null | 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| null | 0
| 0
| 0
| 0
| 0
| 0
| 1
| 1
| 1
| 0
| 1
| 0
|
0
| 4
|
1cd53467dc8e7a54dc683fcc9cac466ab242ed50
| 125
|
py
|
Python
|
modules/logging_config.py
|
Remillardj/databasePT
|
7e63a405b85f3598ff12ccc25b0622b7ee065879
|
[
"Apache-2.0"
] | null | null | null |
modules/logging_config.py
|
Remillardj/databasePT
|
7e63a405b85f3598ff12ccc25b0622b7ee065879
|
[
"Apache-2.0"
] | null | null | null |
modules/logging_config.py
|
Remillardj/databasePT
|
7e63a405b85f3598ff12ccc25b0622b7ee065879
|
[
"Apache-2.0"
] | null | null | null |
import logging
from logging.config import fileConfig
fileConfig('../config/logging_config.ini')
logger = logging.getLogger()
| 25
| 42
| 0.808
| 15
| 125
| 6.666667
| 0.533333
| 0.26
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0.08
| 125
| 5
| 43
| 25
| 0.869565
| 0
| 0
| 0
| 0
| 0
| 0.222222
| 0.222222
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| false
| 0
| 0.5
| 0
| 0.5
| 0
| 1
| 0
| 0
| null | 1
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| null | 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| 0
| 0
|
0
| 4
|
1ce591b8c17600bd3f84b9a2987d423d6879708b
| 61
|
py
|
Python
|
src/slotscheck/__main__.py
|
q0w/slotscheck
|
ec4e8d9925d2c01cbf36aa618b665de0e919672b
|
[
"MIT"
] | 48
|
2022-01-03T11:31:02.000Z
|
2022-03-23T14:16:03.000Z
|
src/slotscheck/__main__.py
|
q0w/slotscheck
|
ec4e8d9925d2c01cbf36aa618b665de0e919672b
|
[
"MIT"
] | 64
|
2022-01-03T13:07:36.000Z
|
2022-03-29T04:35:27.000Z
|
src/slotscheck/__main__.py
|
q0w/slotscheck
|
ec4e8d9925d2c01cbf36aa618b665de0e919672b
|
[
"MIT"
] | 3
|
2022-01-04T18:37:43.000Z
|
2022-02-02T13:46:19.000Z
|
from .cli import root
if __name__ == "__main__":
root()
| 12.2
| 26
| 0.639344
| 8
| 61
| 3.875
| 0.875
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0.229508
| 61
| 4
| 27
| 15.25
| 0.659574
| 0
| 0
| 0
| 0
| 0
| 0.131148
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| true
| 0
| 0.333333
| 0
| 0.333333
| 0
| 1
| 0
| 0
| null | 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| null | 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| 1
| 0
| 0
| 0
|
0
| 4
|
1ced01d443da3da475f6fa685a2902a3a716adaf
| 157
|
py
|
Python
|
pyres/exceptions.py
|
timgates42/pyres
|
4f4b28257afe5b7a08fd38a063fad7ce62c03ae2
|
[
"MIT"
] | 351
|
2015-01-07T03:49:17.000Z
|
2020-05-16T10:26:59.000Z
|
pyres/exceptions.py
|
timgates42/pyres
|
4f4b28257afe5b7a08fd38a063fad7ce62c03ae2
|
[
"MIT"
] | 10
|
2015-01-13T17:02:18.000Z
|
2019-04-01T16:34:02.000Z
|
pyres/exceptions.py
|
timgates42/pyres
|
4f4b28257afe5b7a08fd38a063fad7ce62c03ae2
|
[
"MIT"
] | 56
|
2015-01-14T14:41:17.000Z
|
2020-06-24T14:55:41.000Z
|
class NoQueueError(Exception):
pass
class JobError(RuntimeError):
pass
class TimeoutError(JobError):
pass
class CrashError(JobError):
pass
| 14.272727
| 30
| 0.732484
| 16
| 157
| 7.1875
| 0.5
| 0.234783
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0.191083
| 157
| 11
| 31
| 14.272727
| 0.905512
| 0
| 0
| 0.5
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| true
| 0.5
| 0
| 0
| 0.5
| 0
| 1
| 0
| 0
| null | 1
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| null | 0
| 0
| 0
| 0
| 0
| 0
| 1
| 1
| 0
| 0
| 0
| 0
|
0
| 4
|
1cf218f53ceeadb8cd5482d66bc15aa9241c412b
| 891
|
py
|
Python
|
fdk_client/platform/models/LogInfo.py
|
kavish-d/fdk-client-python
|
a1023eb530473322cb52e095fc4ceb226c1e6037
|
[
"MIT"
] | null | null | null |
fdk_client/platform/models/LogInfo.py
|
kavish-d/fdk-client-python
|
a1023eb530473322cb52e095fc4ceb226c1e6037
|
[
"MIT"
] | null | null | null |
fdk_client/platform/models/LogInfo.py
|
kavish-d/fdk-client-python
|
a1023eb530473322cb52e095fc4ceb226c1e6037
|
[
"MIT"
] | null | null | null |
"""Platform Models."""
from marshmallow import fields, Schema
from marshmallow.validate import OneOf
from ..enums import *
from ..models.BaseSchema import BaseSchema
class LogInfo(BaseSchema):
# Analytics swagger.json
_id = fields.Str(required=False)
status = fields.Str(required=False)
event_type = fields.Str(required=False)
marketplace_name = fields.Str(required=False)
event = fields.Str(required=False)
trace_id = fields.Str(required=False)
company_id = fields.Float(required=False)
brand_id = fields.Float(required=False)
store_code = fields.Str(required=False)
store_id = fields.Float(required=False)
item_id = fields.Float(required=False)
article_id = fields.Str(required=False)
seller_identifier = fields.Str(required=False)
| 13.5
| 50
| 0.657688
| 101
| 891
| 5.693069
| 0.346535
| 0.293913
| 0.266087
| 0.344348
| 0.4
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0.246914
| 891
| 65
| 51
| 13.707692
| 0.85693
| 0.044893
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| false
| 0
| 0.222222
| 0
| 1
| 0
| 0
| 0
| 0
| null | 1
| 1
| 1
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| null | 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
|
0
| 4
|
1cf4e52877ac1e11e48d331ede13238aad662355
| 87
|
py
|
Python
|
src/applications/player/apps.py
|
luisito666/M2-API-REST
|
238837c2cbd0e9aadcce29def0dd9935b888047b
|
[
"MIT"
] | 10
|
2018-02-12T10:30:22.000Z
|
2020-06-29T21:06:15.000Z
|
src/applications/player/apps.py
|
luisito666/M2-API-REST
|
238837c2cbd0e9aadcce29def0dd9935b888047b
|
[
"MIT"
] | 62
|
2018-01-05T04:52:38.000Z
|
2021-04-10T07:14:45.000Z
|
server/player/apps.py
|
MahjongRepository/mahjong-leaderboard
|
77dfd26cb812c12fa7c2b11e862bb80a9135ccb0
|
[
"MIT"
] | 8
|
2018-05-11T11:05:41.000Z
|
2021-03-10T08:10:50.000Z
|
from django.apps import AppConfig
class PlayerConfig(AppConfig):
name = "player"
| 14.5
| 33
| 0.747126
| 10
| 87
| 6.5
| 0.9
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0.172414
| 87
| 5
| 34
| 17.4
| 0.902778
| 0
| 0
| 0
| 0
| 0
| 0.068966
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| false
| 0
| 0.333333
| 0
| 1
| 0
| 1
| 0
| 0
| null | 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| null | 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| 1
| 0
|
0
| 4
|
e817a92b265bc2cfead396544980e6a8e126d9d3
| 91
|
py
|
Python
|
resident/apps.py
|
vitorh45/residential
|
d36b29a72b9d1d79efab7e8549aec39eacce10d7
|
[
"MIT"
] | null | null | null |
resident/apps.py
|
vitorh45/residential
|
d36b29a72b9d1d79efab7e8549aec39eacce10d7
|
[
"MIT"
] | 12
|
2020-02-12T00:03:32.000Z
|
2022-03-11T23:49:10.000Z
|
resident/apps.py
|
vitorh45/residential
|
d36b29a72b9d1d79efab7e8549aec39eacce10d7
|
[
"MIT"
] | null | null | null |
from django.apps import AppConfig
class ResidentConfig(AppConfig):
name = 'resident'
| 15.166667
| 33
| 0.758242
| 10
| 91
| 6.9
| 0.9
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0.164835
| 91
| 5
| 34
| 18.2
| 0.907895
| 0
| 0
| 0
| 0
| 0
| 0.087912
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| false
| 0
| 0.333333
| 0
| 1
| 0
| 1
| 0
| 0
| null | 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| null | 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| 1
| 0
|
0
| 4
|
e8213f8b5ba75cdca1476d851ab24ede42be4c2b
| 204
|
py
|
Python
|
cls2det/detection/utils/__init__.py
|
Media-Smart/cls2det
|
2e0eaeec0a74edfe6946ebb6bc1df8a17a8e478a
|
[
"Apache-2.0"
] | 22
|
2020-06-11T07:00:02.000Z
|
2020-12-14T15:20:59.000Z
|
cls2det/detection/utils/__init__.py
|
Media-Smart/cls2det
|
2e0eaeec0a74edfe6946ebb6bc1df8a17a8e478a
|
[
"Apache-2.0"
] | null | null | null |
cls2det/detection/utils/__init__.py
|
Media-Smart/cls2det
|
2e0eaeec0a74edfe6946ebb6bc1df8a17a8e478a
|
[
"Apache-2.0"
] | 4
|
2020-10-22T05:49:01.000Z
|
2021-12-18T22:57:54.000Z
|
from .common import (data2coco, draw, get_img_annotations,
get_label, get_scale)
from .operations import (box_rescale, cell2box, nms,
remove_outlier, resize)
| 40.8
| 58
| 0.627451
| 22
| 204
| 5.545455
| 0.818182
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0.014085
| 0.303922
| 204
| 4
| 59
| 51
| 0.84507
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| true
| 0
| 0.5
| 0
| 0.5
| 0
| 1
| 0
| 0
| null | 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| null | 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| 1
| 0
| 0
| 0
|
0
| 4
|
08feb6f90eced6bcc66e4b8ec2cab34baed46a7e
| 4,522
|
py
|
Python
|
tests/dicts/io/test_io_dict_toml.py
|
next-franciscoalgaba/python-benedict
|
81ff459304868327238c322a0a8a203d9d5d4314
|
[
"MIT"
] | 365
|
2019-05-21T05:50:30.000Z
|
2022-03-29T11:35:35.000Z
|
tests/dicts/io/test_io_dict_toml.py
|
next-franciscoalgaba/python-benedict
|
81ff459304868327238c322a0a8a203d9d5d4314
|
[
"MIT"
] | 78
|
2019-11-16T12:22:54.000Z
|
2022-03-14T12:21:30.000Z
|
tests/dicts/io/test_io_dict_toml.py
|
next-franciscoalgaba/python-benedict
|
81ff459304868327238c322a0a8a203d9d5d4314
|
[
"MIT"
] | 26
|
2019-12-16T06:34:12.000Z
|
2022-02-28T07:16:41.000Z
|
# -*- coding: utf-8 -*-
from benedict.dicts.io import IODict
from .test_io_dict import io_dict_test_case
class io_dict_toml_test_case(io_dict_test_case):
def test_from_toml_with_valid_data(self):
j = """
a = 1
[b]
c = 3
d = 4
"""
# static method
d = IODict.from_toml(j)
self.assertTrue(isinstance(d, dict))
self.assertEqual(d, { 'a':1, 'b':{ 'c':3, 'd':4 },})
# constructor
d = IODict(j, format='toml')
self.assertTrue(isinstance(d, dict))
self.assertEqual(d, { 'a':1, 'b':{ 'c':3, 'd':4 },})
def test_from_toml_with_invalid_data(self):
j = 'Lorem ipsum est in ea occaecat nisi officia.'
# static method
with self.assertRaises(ValueError):
IODict.from_toml(j)
# constructor
with self.assertRaises(ValueError):
IODict(j, format='toml')
def test_from_toml_with_valid_file_valid_content(self):
filepath = self.input_path('valid-content.toml')
# static method
d = IODict.from_toml(filepath)
self.assertTrue(isinstance(d, dict))
# constructor
d = IODict(filepath, format='toml')
self.assertTrue(isinstance(d, dict))
# constructor with format autodetection
d = IODict(filepath)
self.assertTrue(isinstance(d, dict))
def test_from_toml_with_valid_file_valid_content_invalid_format(self):
# filepath = self.input_path('valid-content.base64')
# with self.assertRaises(ValueError):
# d = IODict.from_toml(filepath)
filepath = self.input_path('valid-content.json')
with self.assertRaises(ValueError):
IODict.from_toml(filepath)
filepath = self.input_path('valid-content.qs')
with self.assertRaises(ValueError):
IODict.from_toml(filepath)
filepath = self.input_path('valid-content.xml')
with self.assertRaises(ValueError):
IODict.from_toml(filepath)
filepath = self.input_path('valid-content.yml')
with self.assertRaises(ValueError):
IODict.from_toml(filepath)
def test_from_toml_with_valid_file_invalid_content(self):
filepath = self.input_path('invalid-content.toml')
# static method
with self.assertRaises(ValueError):
IODict.from_toml(filepath)
# constructor
with self.assertRaises(ValueError):
IODict(filepath, format='toml')
def test_from_toml_with_invalid_file(self):
filepath = self.input_path('invalid-file.toml')
# static method
with self.assertRaises(ValueError):
IODict.from_toml(filepath)
# constructor
with self.assertRaises(ValueError):
IODict(filepath, format='toml')
def test_from_toml_with_valid_url_valid_content(self):
url = self.input_url('valid-content.toml')
# static method
d = IODict.from_toml(url)
self.assertTrue(isinstance(d, dict))
# constructor
d = IODict(url, format='toml')
self.assertTrue(isinstance(d, dict))
# constructor with format autodetection
d = IODict(url)
self.assertTrue(isinstance(d, dict))
def test_from_toml_with_valid_url_invalid_content(self):
url = 'https://github.com/fabiocaccamo/python-benedict'
# static method
with self.assertRaises(ValueError):
IODict.from_toml(url)
# constructor
with self.assertRaises(ValueError):
IODict(url, format='toml')
def test_from_toml_with_invalid_url(self):
url = 'https://github.com/fabiocaccamo/python-benedict-invalid'
# static method
with self.assertRaises(ValueError):
IODict.from_toml(url)
# constructor
with self.assertRaises(ValueError):
IODict(url, format='toml')
def test_to_toml(self):
d = IODict({
'x': 7,
'y': 8,
'z': 9,
'a': 1,
'b': 2,
'c': 3,
})
s = d.to_toml()
self.assertEqual(d, IODict.from_toml(s))
def test_to_toml_file(self):
d = IODict({
'x': 7,
'y': 8,
'z': 9,
'a': 1,
'b': 2,
'c': 3,
})
filepath = self.output_path('test_to_toml_file.toml')
d.to_toml(filepath=filepath)
self.assertFileExists(filepath)
self.assertEqual(d, IODict.from_toml(filepath))
| 32.768116
| 74
| 0.602388
| 530
| 4,522
| 4.943396
| 0.135849
| 0.073282
| 0.080153
| 0.171756
| 0.824427
| 0.820992
| 0.715267
| 0.672137
| 0.564886
| 0.489313
| 0
| 0.007394
| 0.282176
| 4,522
| 137
| 75
| 33.007299
| 0.799754
| 0.094427
| 0
| 0.525253
| 0
| 0
| 0.094548
| 0.005403
| 0
| 0
| 0
| 0
| 0.272727
| 1
| 0.111111
| false
| 0
| 0.020202
| 0
| 0.141414
| 0
| 0
| 0
| 0
| null | 0
| 0
| 1
| 1
| 1
| 1
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| null | 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
|
0
| 4
|
1c0a0003c44de72cbd1ff3024f096574280f0d72
| 80
|
py
|
Python
|
server/flask/app/__init__.py
|
JeanExtreme002/Keylogger
|
bcb568818ca2c71f9cc1663d3858906ac660e778
|
[
"BSD-3-Clause"
] | 4
|
2020-02-09T20:29:43.000Z
|
2021-11-08T08:48:05.000Z
|
server/flask/app/__init__.py
|
JeanExtreme002/Keylogger
|
bcb568818ca2c71f9cc1663d3858906ac660e778
|
[
"BSD-3-Clause"
] | null | null | null |
server/flask/app/__init__.py
|
JeanExtreme002/Keylogger
|
bcb568818ca2c71f9cc1663d3858906ac660e778
|
[
"BSD-3-Clause"
] | null | null | null |
from flask import Flask
server = Flask(__name__)
from app.controller import *
| 13.333333
| 28
| 0.775
| 11
| 80
| 5.272727
| 0.636364
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0.1625
| 80
| 5
| 29
| 16
| 0.865672
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| false
| 0
| 0.666667
| 0
| 0.666667
| 0
| 1
| 0
| 0
| null | 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| null | 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| 1
| 0
|
0
| 4
|
1c100580c9230b7b37b663cc1f2263a3b573bde1
| 94
|
py
|
Python
|
iframeplaylistgenerator/__init__.py
|
nweber/iframe-playlist-generator
|
ba6d89473d39604806a53a1a07b8f21ae4814c23
|
[
"Apache-2.0"
] | 61
|
2015-01-15T17:14:46.000Z
|
2021-10-30T01:49:06.000Z
|
iframeplaylistgenerator/__init__.py
|
nweber/iframe-playlist-generator
|
ba6d89473d39604806a53a1a07b8f21ae4814c23
|
[
"Apache-2.0"
] | 2
|
2015-10-31T08:27:48.000Z
|
2017-04-13T22:33:50.000Z
|
iframeplaylistgenerator/__init__.py
|
nweber/iframe-playlist-generator
|
ba6d89473d39604806a53a1a07b8f21ae4814c23
|
[
"Apache-2.0"
] | 16
|
2015-01-29T05:43:58.000Z
|
2020-10-29T18:34:34.000Z
|
from iframeplaylistgenerator.generator import (
update_for_iframes, create_iframe_playlist
)
| 23.5
| 47
| 0.87234
| 10
| 94
| 7.8
| 1
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0.085106
| 94
| 3
| 48
| 31.333333
| 0.906977
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| true
| 0
| 0.333333
| 0
| 0.333333
| 0
| 1
| 0
| 0
| null | 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| null | 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| 1
| 0
| 0
| 0
|
0
| 4
|
1c4e0aa42b76eb9a4136a0ace34182588b23f6bd
| 311
|
py
|
Python
|
NuIMDB/src/model/Model.py
|
shriyanshagnihotri/NuAssignment
|
324a7242d16b453a02efdfcae2e8ed195f2d4ae8
|
[
"MIT"
] | null | null | null |
NuIMDB/src/model/Model.py
|
shriyanshagnihotri/NuAssignment
|
324a7242d16b453a02efdfcae2e8ed195f2d4ae8
|
[
"MIT"
] | null | null | null |
NuIMDB/src/model/Model.py
|
shriyanshagnihotri/NuAssignment
|
324a7242d16b453a02efdfcae2e8ed195f2d4ae8
|
[
"MIT"
] | null | null | null |
import bsddb as dbDriver
class Model:
dbDriverObj = None
def __init__(self):
self.dbDriverObj = dbDriver.hashopen('MovieDB.db')
def read_app(self, appname):
return self.dbDriverObj.get(appname, None)
def write_app(self, appname, data):
self.dbDriverObj[appname] = data
self.dbDriverObj.sync()
| 18.294118
| 52
| 0.73955
| 41
| 311
| 5.463415
| 0.536585
| 0.267857
| 0.125
| 0.232143
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0.14791
| 311
| 16
| 53
| 19.4375
| 0.845283
| 0
| 0
| 0
| 0
| 0
| 0.032154
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0.3
| false
| 0
| 0.1
| 0.1
| 0.7
| 0
| 0
| 0
| 0
| null | 1
| 0
| 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
| 0
| 1
| 0
|
0
| 4
|
1c54496e77b20ced1f2cb45bca6297391ffa1e7e
| 24,266
|
py
|
Python
|
tests/test_publish_draft_services.py
|
alphagov-mirror/digitalmarketplace-scripts
|
8a7ef9b2b5f5fffea6e012bd676b095a27d35101
|
[
"MIT"
] | 1
|
2020-06-23T01:55:31.000Z
|
2020-06-23T01:55:31.000Z
|
tests/test_publish_draft_services.py
|
alphagov-mirror/digitalmarketplace-scripts
|
8a7ef9b2b5f5fffea6e012bd676b095a27d35101
|
[
"MIT"
] | 267
|
2015-10-12T12:43:52.000Z
|
2021-08-19T10:38:55.000Z
|
tests/test_publish_draft_services.py
|
alphagov-mirror/digitalmarketplace-scripts
|
8a7ef9b2b5f5fffea6e012bd676b095a27d35101
|
[
"MIT"
] | 7
|
2015-11-11T16:47:41.000Z
|
2021-04-10T18:03:04.000Z
|
import mock
import pytest
from dmapiclient import DataAPIClient, HTTPError
from dmtestutils.api_model_stubs import DraftServiceStub, SupplierFrameworkStub
from dmtestutils.comparisons import ExactIdentity
from dmtestutils.mocking import assert_args_and_return_iter_over
from dmutils.s3 import S3
from dmscripts.publish_draft_services import (
publish_draft_services, copy_draft_documents, publish_draft_service, get_draft_services_iter
)
@mock.patch('dmscripts.publish_draft_services.get_draft_services_iter')
@mock.patch('dmscripts.publish_draft_services.publish_draft_service')
@mock.patch('dmscripts.publish_draft_services.copy_draft_documents')
class TestPublishAndCopyDraftServices:
def setup(self):
self.mock_data_api_client = mock.create_autospec(DataAPIClient)
self.draft_services_iter = []
self.live_assets_endpoint = "https://boyish.gam/bols/"
self.document_keys = ('123', '456')
self.draft_service1 = DraftServiceStub(framework_slug="g-cloud-123", id=123).response()
self.draft_service2 = DraftServiceStub(framework_slug="g-cloud-123", id=456).response()
def find_draft_services_iter_side_effect(self, *args, **kwargs):
return self.draft_service1, self.draft_service2
@pytest.mark.parametrize("draft_ids_file", ("1, 2, 3", None))
@pytest.mark.parametrize("dry_run", (False, True,))
def test_publish_draft_services_happy_path(
self, copy_draft_documents, publish_draft_service, get_draft_services_iter, dry_run, draft_ids_file
):
get_draft_services_iter.side_effect = self.find_draft_services_iter_side_effect
# Assume the drafts have not been previously published
publish_draft_service.return_value = ("serviceID", False)
publish_draft_services(
self.mock_data_api_client,
"g-cloud-123",
'draft-bucket',
'documents-bucket',
self.document_keys,
self.live_assets_endpoint,
draft_ids_file=draft_ids_file,
dry_run=dry_run,
)
assert publish_draft_service.mock_calls == [
mock.call(
self.mock_data_api_client,
self.draft_service1,
dry_run=dry_run,
),
mock.call(
self.mock_data_api_client,
self.draft_service2,
dry_run=dry_run,
)
]
assert copy_draft_documents.mock_calls == [
mock.call(
'draft-bucket',
'documents-bucket',
self.document_keys,
self.live_assets_endpoint,
ExactIdentity(self.mock_data_api_client),
"g-cloud-123",
self.draft_service1,
"serviceID",
dry_run
),
mock.call(
'draft-bucket',
'documents-bucket',
self.document_keys,
self.live_assets_endpoint,
ExactIdentity(self.mock_data_api_client),
"g-cloud-123",
self.draft_service2,
"serviceID",
dry_run
),
]
assert get_draft_services_iter.mock_calls == [
mock.call(
ExactIdentity(self.mock_data_api_client),
'g-cloud-123',
draft_ids_file=draft_ids_file
)
]
@pytest.mark.parametrize("skip_docs_flag", (False, True,))
@pytest.mark.parametrize("dry_run", (False, True,))
def test_publish_draft_services_does_not_copy_if_copy_flag_false(
self, copy_draft_documents, publish_draft_service, get_draft_services_iter, dry_run, skip_docs_flag
):
get_draft_services_iter.side_effect = self.find_draft_services_iter_side_effect
# Not yet published
publish_draft_service.return_value = ("serviceID", False)
publish_draft_services(
self.mock_data_api_client,
"g-cloud-123",
'draft-bucket',
'documents-bucket',
self.document_keys,
self.live_assets_endpoint,
dry_run=dry_run,
skip_docs_if_published=skip_docs_flag,
copy_documents=False
)
assert len(copy_draft_documents.mock_calls) == 0
@pytest.mark.parametrize("draft_ids_file", ("1, 2, 3", None))
@pytest.mark.parametrize("dry_run", (False, True,))
def test_publish_draft_services_skips_copying_if_draft_already_published(
self, copy_draft_documents, publish_draft_service, get_draft_services_iter, dry_run, draft_ids_file
):
get_draft_services_iter.side_effect = self.find_draft_services_iter_side_effect
# Already published
publish_draft_service.return_value = ("serviceID", True)
publish_draft_services(
self.mock_data_api_client,
"g-cloud-123",
'draft-bucket',
'documents-bucket',
self.document_keys,
self.live_assets_endpoint,
draft_ids_file=draft_ids_file,
dry_run=dry_run,
)
assert len(copy_draft_documents.mock_calls) == 0
@pytest.mark.parametrize("draft_ids_file", ("1, 2, 3", None))
@pytest.mark.parametrize("dry_run", (False, True,))
def test_publish_draft_services_does_not_skip_copying_published_docs_if_skip_flag_false(
self, copy_draft_documents, publish_draft_service, get_draft_services_iter, dry_run, draft_ids_file
):
get_draft_services_iter.side_effect = self.find_draft_services_iter_side_effect
# Already published
publish_draft_service.return_value = ("serviceID", True)
publish_draft_services(
self.mock_data_api_client,
"g-cloud-123",
'draft-bucket',
'documents-bucket',
self.document_keys,
self.live_assets_endpoint,
draft_ids_file=draft_ids_file,
dry_run=dry_run,
skip_docs_if_published=False,
)
assert len(copy_draft_documents.mock_calls) == 2
class TestGetDraftServicesIter:
def setup(self):
self.supplier1 = SupplierFrameworkStub(
supplier_id=878004, framework_slug="g-cloud-123", on_framework=False).response()
self.supplier2 = SupplierFrameworkStub(
supplier_id=878040, framework_slug="g-cloud-123", on_framework=True).response()
self.supplier3 = SupplierFrameworkStub(
supplier_id=878400, framework_slug="g-cloud-123", on_framework=True).response()
self.supplier4 = SupplierFrameworkStub(
supplier_id=878401, framework_slug="g-cloud-123", on_framework=True).response()
self.mock_data_api_client = mock.create_autospec(DataAPIClient)
self.mock_data_api_client.find_framework_suppliers_iter.side_effect = assert_args_and_return_iter_over(
(
self.supplier1,
self.supplier2,
self.supplier3,
self.supplier4
),
"g-cloud-123",
with_declarations=None
)
# 1: submitted, supplier not on framework
# 2: not submitted, supplier on framework
# 3 & 4: submitted, supplier on framework
# 5: submitted, supplier on framework
self.draft_service1 = DraftServiceStub(
framework_slug="g-cloud-123",
id=123,
supplierId=self.supplier1['supplierId'],
status='submitted'
).response()
self.draft_service2 = DraftServiceStub(
framework_slug="g-cloud-123",
id=456,
supplierId=self.supplier2['supplierId'],
status='not-submitted'
).response()
self.draft_service3 = DraftServiceStub(
framework_slug="g-cloud-123",
id=789,
supplierId=self.supplier3['supplierId'],
status='submitted'
).response()
self.draft_service4 = DraftServiceStub(
framework_slug="g-cloud-123",
id=101,
supplierId=self.supplier4['supplierId'], status='submitted'
).response()
self.draft_service5 = DraftServiceStub(
framework_slug="g-cloud-123",
id=202,
supplierId=self.supplier4['supplierId'],
status='submitted'
).response()
self.mock_data_api_client.find_draft_services_by_framework_iter.side_effect = [
[], # Supplier 2 has no submitted services
[self.draft_service3, self.draft_service4], # Supplier 3
[self.draft_service5] # Supplier 4
]
def test_get_draft_services_fetches_drafts_for_framework_suppliers_only(self):
drafts = get_draft_services_iter(self.mock_data_api_client, 'g-cloud-123')
assert list(drafts) == [
self.draft_service3,
self.draft_service4,
self.draft_service5,
]
assert self.mock_data_api_client.find_draft_services_by_framework_iter.call_args_list == [
mock.call('g-cloud-123', status='submitted', supplier_id=878040),
mock.call('g-cloud-123', status='submitted', supplier_id=878400),
mock.call('g-cloud-123', status='submitted', supplier_id=878401),
]
def test_get_draft_services_for_draft_ids_file_includes_not_submitted_services(self):
self.mock_data_api_client.get_draft_service.side_effect = [
{"services": self.draft_service2},
{"services": self.draft_service3}
]
draft_ids_file = [str(self.draft_service2['id']), str(self.draft_service3['id'])]
drafts = get_draft_services_iter(self.mock_data_api_client, 'g-cloud-123', draft_ids_file=draft_ids_file)
assert list(drafts) == [
self.draft_service2,
self.draft_service3
]
def test_get_draft_services_for_draft_ids_file_raises_on_supplier_id_mismatch(self):
self.mock_data_api_client.get_draft_service.side_effect = [
{"services": self.draft_service1}
]
with pytest.raises(ValueError) as excinfo:
list(get_draft_services_iter(self.mock_data_api_client, 'g-cloud-123', draft_ids_file="1"))
assert str(excinfo.value) == "Draft service 1's supplier (878004) not on framework 'g-cloud-123'"
class TestPublishDraftService:
def setup(self):
self.mock_data_api_client = mock.create_autospec(DataAPIClient)
self.mock_data_api_client.publish_draft_service.return_value = {
"services": {
"id": "500400300"
}
}
self.mock_data_api_client.get_draft_service.return_value = {
"serviceId": "500400200",
"supplierId": 999,
"id": 987654
}
self.draft_service = {
"supplierId": 999,
"id": 987654
}
@pytest.mark.parametrize("dry_run", (False, True,))
@mock.patch('dmscripts.publish_draft_services.get_logger')
def test_publish_draft_service_with_service_id_logs_warning(self, logger_mock, dry_run):
draft_service_with_existing_id = {
"serviceId": "12345678",
"supplierId": 999,
"id": 987654
}
assert publish_draft_service(
self.mock_data_api_client,
draft_service_with_existing_id
) == ("12345678", True)
assert logger_mock.return_value.info.call_args_list == [
mock.call("supplier %s: draft %s: publishing", 999, 987654)
]
assert logger_mock.return_value.warning.call_args_list == [
mock.call(
"supplier %s: draft %s: skipped publishing - already has service id: %s",
999,
987654,
"12345678"
)
]
@mock.patch('dmscripts.publish_draft_services.random')
@mock.patch('dmscripts.publish_draft_services.get_logger')
def test_publish_draft_service_with_dry_run_only_logs(self, logger_mock, random):
random.randint.return_value = "55500001"
assert publish_draft_service(
self.mock_data_api_client,
self.draft_service,
dry_run=True,
) == ("55500001", False)
assert logger_mock.return_value.info.call_args_list == [
mock.call("supplier %s: draft %s: publishing", 999, 987654),
mock.call(
"supplier %s: draft %s: dry run: generating random test service id: %s",
999,
987654,
"55500001"
)
]
@mock.patch('dmscripts.publish_draft_services.get_logger')
def test_publish_draft_service_happy_path(self, logger_mock):
assert publish_draft_service(
self.mock_data_api_client,
self.draft_service,
dry_run=False,
) == ("500400300", False)
assert self.mock_data_api_client.publish_draft_service.call_args_list == [
mock.call(987654, user='publish_draft_services.py')
]
assert self.mock_data_api_client.get_draft_service.call_args_list == []
assert logger_mock.return_value.info.call_args_list == [
mock.call("supplier %s: draft %s: publishing", 999, 987654),
mock.call(
"supplier %s: draft %s: published - new service id: %s",
999,
987654,
"500400300"
)
]
@mock.patch('dmscripts.publish_draft_services.get_logger')
def test_publish_draft_service_retries_republish_api_error(self, logger_mock):
mock_response = mock.Mock(status_code=400)
mock_response.json.return_value = {"error": "Cannot re-publish a submitted service"}
self.mock_data_api_client.publish_draft_service.side_effect = HTTPError(
response=mock_response
)
assert publish_draft_service(
self.mock_data_api_client,
self.draft_service,
dry_run=False,
) == ("500400200", True)
assert self.mock_data_api_client.publish_draft_service.call_args_list == [
mock.call(987654, user='publish_draft_services.py')
]
assert self.mock_data_api_client.get_draft_service.call_args_list == [
mock.call(987654)
]
assert logger_mock.return_value.info.call_args_list == [
mock.call("supplier %s: draft %s: publishing", 999, 987654)
]
assert logger_mock.return_value.warning.call_args_list == [
mock.call(
"supplier %s: draft %s: failed publishing - has service id: %s",
999,
987654,
"500400200",
)
]
class TestCopyDraftDocuments:
def setup(self):
self.mock_draft_bucket = mock.create_autospec(S3, bucket_name="ducky")
self.mock_draft_bucket.path_exists.return_value = True
self.mock_documents_bucket = mock.create_autospec(S3, bucket_name="puddeny-pie")
self.mock_data_api_client = mock.create_autospec(DataAPIClient)
self.draft_service = DraftServiceStub(
id=379001,
framework_slug="g-cloud-123",
supplier_id="171400",
service_id="2229090909",
**{
"chinChopperURL": "https://gin.ger.br/ead/g-cloud-123/submissions/171400/379001-steak.pdf",
"beeoTeeTomURL": "https://gin.ger.br/ead/g-cloud-123/submissions/171400/379001-kidney.pdf",
"madcapURL": "https://gin.ger.br/ead/g-cloud-123/submissions/171400/379001-liver.odt",
"boldAsBrassURL": "https://gin.ger.br/ead/g-cloud-123/submissions/171400/379001-mashed.pdf",
}
).response()
self.document_keys = (
"chinChopperURL",
"beeoTeeTomURL",
"madcapURL",
"boldAsBrassURL",
)
self.live_assets_endpoint = "https://boyish.gam/bols/"
def mock_documents_bucket_copy_side_effect(self, src_bucket, src_key, target_key, **kwargs):
# Raise an error if this document already exists in the target bucket
if target_key == "g-cloud-123/documents/171400/2229090909-kidney.pdf":
raise ValueError("Target key already exists in S3.")
return mock.Mock()
def test_copy_draft_documents_only_logs_on_dry_run(self):
copy_draft_documents(
self.mock_draft_bucket,
self.mock_documents_bucket,
self.document_keys,
self.live_assets_endpoint,
self.mock_data_api_client,
"g-cloud-123",
self.draft_service,
"2229090909",
)
assert self.mock_draft_bucket.mock_calls == [
mock.call.path_exists("g-cloud-123/submissions/171400/379001-steak.pdf"),
mock.call.path_exists("g-cloud-123/submissions/171400/379001-kidney.pdf"),
mock.call.path_exists("g-cloud-123/submissions/171400/379001-liver.odt"),
mock.call.path_exists("g-cloud-123/submissions/171400/379001-mashed.pdf"),
]
assert self.mock_documents_bucket.mock_calls == []
assert self.mock_data_api_client.mock_calls == []
def test_copy_draft_documents_happy_path(self):
copy_draft_documents(
self.mock_draft_bucket,
self.mock_documents_bucket,
self.document_keys,
self.live_assets_endpoint,
self.mock_data_api_client,
"g-cloud-123",
self.draft_service,
"2229090909",
dry_run=False,
)
assert self.mock_draft_bucket.mock_calls == [
mock.call.path_exists("g-cloud-123/submissions/171400/379001-steak.pdf"),
mock.call.path_exists("g-cloud-123/submissions/171400/379001-kidney.pdf"),
mock.call.path_exists("g-cloud-123/submissions/171400/379001-liver.odt"),
mock.call.path_exists("g-cloud-123/submissions/171400/379001-mashed.pdf"),
]
assert self.mock_documents_bucket.mock_calls == [
mock.call.copy(
acl="public-read",
src_bucket="ducky",
src_key="g-cloud-123/submissions/171400/379001-steak.pdf",
target_key="g-cloud-123/documents/171400/2229090909-steak.pdf",
),
mock.call.copy(
acl="public-read",
src_bucket="ducky",
src_key="g-cloud-123/submissions/171400/379001-kidney.pdf",
target_key="g-cloud-123/documents/171400/2229090909-kidney.pdf",
),
mock.call.copy(
acl="public-read",
src_bucket="ducky",
src_key="g-cloud-123/submissions/171400/379001-liver.odt",
target_key="g-cloud-123/documents/171400/2229090909-liver.odt",
),
mock.call.copy(
acl="public-read",
src_bucket="ducky",
src_key="g-cloud-123/submissions/171400/379001-mashed.pdf",
target_key="g-cloud-123/documents/171400/2229090909-mashed.pdf",
),
]
assert self.mock_data_api_client.mock_calls == [
mock.call.update_service(
"2229090909",
{
"chinChopperURL": "https://boyish.gam/bols/g-cloud-123/documents/171400/2229090909-steak.pdf",
"beeoTeeTomURL": "https://boyish.gam/bols/g-cloud-123/documents/171400/2229090909-kidney.pdf",
"madcapURL": "https://boyish.gam/bols/g-cloud-123/documents/171400/2229090909-liver.odt",
"boldAsBrassURL": "https://boyish.gam/bols/g-cloud-123/documents/171400/2229090909-mashed.pdf",
},
user="publish_draft_services.py",
),
]
def test_copy_draft_documents_raises_on_supplier_id_mismatch(self):
draft_service_with_bad_document_path = DraftServiceStub(
id=379001,
framework_slug="g-cloud-123",
supplier_id="171400",
service_id="2229090909",
**{
"chinChopperURL": "https://gin.ger.br/ead/g-cloud-123/submissions/999999/379001-steak.pdf",
"beeoTeeTomURL": "https://gin.ger.br/ead/g-cloud-123/submissions/171400/379001-kidney.pdf",
}
).response()
with pytest.raises(ValueError) as excinfo:
copy_draft_documents(
self.mock_draft_bucket,
self.mock_documents_bucket,
self.document_keys,
self.live_assets_endpoint,
self.mock_data_api_client,
"g-cloud-123",
draft_service_with_bad_document_path,
"2229090909",
dry_run=False,
)
assert str(excinfo.value) == "supplier id mismatch: '999999' != '171400'"
assert self.mock_documents_bucket.mock_calls == []
assert self.mock_data_api_client.mock_calls == []
def test_copy_draft_documents_raises_on_draft_service_id_mismatch(self):
draft_service_with_bad_document_path = DraftServiceStub(
id=379001,
framework_slug="g-cloud-123",
supplier_id="171400",
service_id="2229090909",
**{
"chinChopperURL": "https://gin.ger.br/ead/g-cloud-123/submissions/171400/999999-steak.pdf",
"beeoTeeTomURL": "https://gin.ger.br/ead/g-cloud-123/submissions/171400/379001-kidney.pdf",
}
).response()
with pytest.raises(ValueError) as excinfo:
copy_draft_documents(
self.mock_draft_bucket,
self.mock_documents_bucket,
self.document_keys,
self.live_assets_endpoint,
self.mock_data_api_client,
"g-cloud-123",
draft_service_with_bad_document_path,
"2229090909",
dry_run=False,
)
assert str(excinfo.value) == "draft id mismatch: '999999' != '379001'"
assert self.mock_documents_bucket.mock_calls == []
assert self.mock_data_api_client.mock_calls == []
def test_copy_draft_documents_ignores_error_if_document_exists_in_target_bucket(self):
self.mock_documents_bucket.copy.side_effect = self.mock_documents_bucket_copy_side_effect
copy_draft_documents(
self.mock_draft_bucket,
self.mock_documents_bucket,
self.document_keys,
self.live_assets_endpoint,
self.mock_data_api_client,
"g-cloud-123",
self.draft_service,
"2229090909",
dry_run=False,
)
# Service is updated as normal
assert self.mock_data_api_client.mock_calls == [
mock.call.update_service(
"2229090909",
{
"chinChopperURL": "https://boyish.gam/bols/g-cloud-123/documents/171400/2229090909-steak.pdf",
"beeoTeeTomURL": "https://boyish.gam/bols/g-cloud-123/documents/171400/2229090909-kidney.pdf",
"madcapURL": "https://boyish.gam/bols/g-cloud-123/documents/171400/2229090909-liver.odt",
"boldAsBrassURL": "https://boyish.gam/bols/g-cloud-123/documents/171400/2229090909-mashed.pdf",
},
user="publish_draft_services.py",
),
]
def test_copy_draft_documents_raises_on_other_copy_error(self):
self.mock_documents_bucket.copy.side_effect = ValueError("Unexpected S3 error.")
with pytest.raises(ValueError) as excinfo:
copy_draft_documents(
self.mock_draft_bucket,
self.mock_documents_bucket,
self.document_keys,
self.live_assets_endpoint,
self.mock_data_api_client,
"g-cloud-123",
self.draft_service,
"2229090909",
dry_run=False,
)
assert str(excinfo.value) == "Unexpected S3 error."
| 40.37604
| 115
| 0.614564
| 2,704
| 24,266
| 5.190828
| 0.080251
| 0.029068
| 0.043602
| 0.045953
| 0.793816
| 0.767883
| 0.732901
| 0.708464
| 0.665361
| 0.634583
| 0
| 0.068439
| 0.285255
| 24,266
| 600
| 116
| 40.443333
| 0.740833
| 0.017226
| 0
| 0.58444
| 0
| 0.030361
| 0.19447
| 0.054208
| 0
| 0
| 0
| 0
| 0.075901
| 1
| 0.043643
| false
| 0
| 0.01518
| 0.001898
| 0.070209
| 0
| 0
| 0
| 0
| null | 0
| 0
| 0
| 0
| 1
| 1
| 1
| 0
| 1
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| null | 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
|
0
| 4
|
1c5e0bb2812c71eb52fdd180195e0cfb11bce337
| 900
|
py
|
Python
|
cart_venv/Lib/site-packages/tensorflow_core/_api/v1/compat/v2/random/experimental/__init__.py
|
juice1000/Synchronous-vs-Asynchronous-Learning-Tensorflow-
|
654be60f7986ac9bb7ce1d080ddee377c3389f93
|
[
"MIT"
] | 2
|
2019-08-04T20:28:14.000Z
|
2019-10-27T23:26:42.000Z
|
cart_venv/Lib/site-packages/tensorflow_core/_api/v1/compat/v2/random/experimental/__init__.py
|
juice1000/Synchronous-vs-Asynchronous-Learning-Tensorflow-
|
654be60f7986ac9bb7ce1d080ddee377c3389f93
|
[
"MIT"
] | null | null | null |
cart_venv/Lib/site-packages/tensorflow_core/_api/v1/compat/v2/random/experimental/__init__.py
|
juice1000/Synchronous-vs-Asynchronous-Learning-Tensorflow-
|
654be60f7986ac9bb7ce1d080ddee377c3389f93
|
[
"MIT"
] | 1
|
2020-11-04T03:16:29.000Z
|
2020-11-04T03:16:29.000Z
|
# This file is MACHINE GENERATED! Do not edit.
# Generated by: tensorflow/python/tools/api/generator/create_python_api.py script.
"""Public API for tf.random.experimental namespace.
"""
from __future__ import print_function as _print_function
import sys as _sys
from tensorflow.python.ops.stateful_random_ops import Generator
from tensorflow.python.ops.stateful_random_ops import create_rng_state
from tensorflow.python.ops.stateful_random_ops import get_global_generator
from tensorflow.python.ops.stateful_random_ops import set_global_generator
del _print_function
from tensorflow.python.util import module_wrapper as _module_wrapper
if not isinstance(_sys.modules[__name__], _module_wrapper.TFModuleWrapper):
_sys.modules[__name__] = _module_wrapper.TFModuleWrapper(
_sys.modules[__name__], "compat.v2.random.experimental", public_apis=None, deprecation=False,
has_lite=False)
| 39.130435
| 99
| 0.832222
| 124
| 900
| 5.637097
| 0.435484
| 0.137339
| 0.143062
| 0.131617
| 0.429185
| 0.429185
| 0.429185
| 0.429185
| 0.297568
| 0
| 0
| 0.001229
| 0.095556
| 900
| 22
| 100
| 40.909091
| 0.857494
| 0.194444
| 0
| 0
| 1
| 0
| 0.040446
| 0.040446
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| true
| 0
| 0.583333
| 0
| 0.583333
| 0.166667
| 0
| 0
| 0
| null | 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| 0
| 0
| null | 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| 1
| 0
| 1
| 0
|
0
| 4
|
1c705dbfdb782e7a54ff9fa992d0fcee6321b6f8
| 96
|
py
|
Python
|
Aug21/EffectivePython/ObjectOrientedProgramming/exploringclass.py
|
pythonbykhaja/intesivepython
|
d3074f35bf36a04d4d1d9b4ff4631733d40b5817
|
[
"Apache-2.0"
] | 2
|
2021-05-29T18:21:50.000Z
|
2021-07-24T13:03:30.000Z
|
Aug21/EffectivePython/ObjectOrientedProgramming/exploringclass.py
|
pythonbykhaja/intesivepython
|
d3074f35bf36a04d4d1d9b4ff4631733d40b5817
|
[
"Apache-2.0"
] | null | null | null |
Aug21/EffectivePython/ObjectOrientedProgramming/exploringclass.py
|
pythonbykhaja/intesivepython
|
d3074f35bf36a04d4d1d9b4ff4631733d40b5817
|
[
"Apache-2.0"
] | 2
|
2021-05-25T10:19:54.000Z
|
2021-09-21T12:20:48.000Z
|
class Dummy:
def __str__(self) -> str:
return "dummy"
d1 = Dummy()
print(d1)
| 10.666667
| 29
| 0.541667
| 12
| 96
| 4
| 0.666667
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0.030769
| 0.322917
| 96
| 8
| 30
| 12
| 0.707692
| 0
| 0
| 0
| 0
| 0
| 0.052083
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0.2
| false
| 0
| 0
| 0.2
| 0.6
| 0.2
| 1
| 0
| 0
| null | 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| null | 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 1
| 0
|
0
| 4
|
1c71355885c5ae9012ce9beb5fdc9ffe57d226af
| 57
|
py
|
Python
|
lang/Python/file-input-output-1.py
|
ethansaxenian/RosettaDecode
|
8ea1a42a5f792280b50193ad47545d14ee371fb7
|
[
"MIT"
] | 5
|
2021-01-29T20:08:05.000Z
|
2022-03-22T06:16:05.000Z
|
lang/Python/file-input-output-1.py
|
ethansaxenian/RosettaDecode
|
8ea1a42a5f792280b50193ad47545d14ee371fb7
|
[
"MIT"
] | null | null | null |
lang/Python/file-input-output-1.py
|
ethansaxenian/RosettaDecode
|
8ea1a42a5f792280b50193ad47545d14ee371fb7
|
[
"MIT"
] | 1
|
2021-04-13T04:19:31.000Z
|
2021-04-13T04:19:31.000Z
|
import shutil
shutil.copyfile('input.txt', 'output.txt')
| 19
| 42
| 0.754386
| 8
| 57
| 5.375
| 0.75
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0.070175
| 57
| 2
| 43
| 28.5
| 0.811321
| 0
| 0
| 0
| 0
| 0
| 0.333333
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| true
| 0
| 0.5
| 0
| 0.5
| 0
| 1
| 0
| 0
| null | 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| null | 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| 1
| 0
| 0
| 0
|
0
| 4
|
1c7d1cead25a2490606975f6d4a016cc690910db
| 136
|
py
|
Python
|
__init__.py
|
kehr/mi
|
85abe3a9558ce66d4a7f2d0260d6138c4f8ad417
|
[
"MIT"
] | null | null | null |
__init__.py
|
kehr/mi
|
85abe3a9558ce66d4a7f2d0260d6138c4f8ad417
|
[
"MIT"
] | null | null | null |
__init__.py
|
kehr/mi
|
85abe3a9558ce66d4a7f2d0260d6138c4f8ad417
|
[
"MIT"
] | null | null | null |
# -*- coding: utf-8 -*-
# @Project: mi
# @File: __init__.py
# @Author: kehr
# @Date: 2016-10-18 18:56:16
# @Email: kehr.china@gmail.com
| 19.428571
| 30
| 0.610294
| 22
| 136
| 3.590909
| 0.909091
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0.130435
| 0.154412
| 136
| 6
| 31
| 22.666667
| 0.556522
| 0.904412
| 0
| null | 0
| null | 0
| 0
| null | 0
| 0
| 0
| null | 1
| null | true
| 0
| 0
| null | null | null | 1
| 0
| 0
| null | 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| 0
| 0
| 1
| 0
| 0
| 0
| 0
| 0
| 0
| null | 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| 0
| 0
| 0
| 0
|
0
| 4
|
1c9c35a84f69b569bed382a208022626260639fa
| 67
|
py
|
Python
|
src/appliance-onboarding-script/appliance_setup/avs/avsarconboarder/orchestrator/_orchestrator.py
|
Azure/ArcOnAVS
|
9ecd26ceb2f49953db1beda07beba55c15e773ce
|
[
"MIT"
] | null | null | null |
src/appliance-onboarding-script/appliance_setup/avs/avsarconboarder/orchestrator/_orchestrator.py
|
Azure/ArcOnAVS
|
9ecd26ceb2f49953db1beda07beba55c15e773ce
|
[
"MIT"
] | null | null | null |
src/appliance-onboarding-script/appliance_setup/avs/avsarconboarder/orchestrator/_orchestrator.py
|
Azure/ArcOnAVS
|
9ecd26ceb2f49953db1beda07beba55c15e773ce
|
[
"MIT"
] | null | null | null |
class Orchestrator:
def orchestrate(self, *args):
pass
| 16.75
| 33
| 0.641791
| 7
| 67
| 6.142857
| 1
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0.268657
| 67
| 4
| 34
| 16.75
| 0.877551
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0.333333
| false
| 0.333333
| 0
| 0
| 0.666667
| 0
| 1
| 0
| 0
| null | 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| null | 0
| 0
| 0
| 0
| 0
| 1
| 0
| 1
| 0
| 0
| 0
| 0
|
0
| 4
|
98bbd49acfb5b7b0721c5a987756a21266ad84e0
| 569
|
py
|
Python
|
django_outbox_middleware/views.py
|
ArtProcessors/django-outbox-middleware
|
25aad0cea4fc284a6b800abcbb7f3037bcaf6621
|
[
"MIT"
] | null | null | null |
django_outbox_middleware/views.py
|
ArtProcessors/django-outbox-middleware
|
25aad0cea4fc284a6b800abcbb7f3037bcaf6621
|
[
"MIT"
] | null | null | null |
django_outbox_middleware/views.py
|
ArtProcessors/django-outbox-middleware
|
25aad0cea4fc284a6b800abcbb7f3037bcaf6621
|
[
"MIT"
] | null | null | null |
# -*- coding: utf-8 -*-
from django.views.generic import (
CreateView,
DeleteView,
DetailView,
UpdateView,
ListView
)
from .models import (
OutboxRequestLog,
)
class OutboxRequestLogCreateView(CreateView):
model = OutboxRequestLog
class OutboxRequestLogDeleteView(DeleteView):
model = OutboxRequestLog
class OutboxRequestLogDetailView(DetailView):
model = OutboxRequestLog
class OutboxRequestLogUpdateView(UpdateView):
model = OutboxRequestLog
class OutboxRequestLogListView(ListView):
model = OutboxRequestLog
| 14.589744
| 45
| 0.745167
| 42
| 569
| 10.095238
| 0.52381
| 0.247642
| 0.245283
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0.002151
| 0.182777
| 569
| 38
| 46
| 14.973684
| 0.909677
| 0.036907
| 0
| 0.25
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| false
| 0
| 0.1
| 0
| 0.6
| 0
| 0
| 0
| 1
| null | 1
| 1
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| null | 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
|
0
| 4
|
98d4d85bcbec05ab4881900d4fe12940c7f048c5
| 201
|
py
|
Python
|
src/pages/__init__.py
|
kryvokhyzha/bert-for-ukranian-ner
|
48da40f09cb216ad51a97c303998157858fbe8bc
|
[
"MIT"
] | null | null | null |
src/pages/__init__.py
|
kryvokhyzha/bert-for-ukranian-ner
|
48da40f09cb216ad51a97c303998157858fbe8bc
|
[
"MIT"
] | null | null | null |
src/pages/__init__.py
|
kryvokhyzha/bert-for-ukranian-ner
|
48da40f09cb216ad51a97c303998157858fbe8bc
|
[
"MIT"
] | null | null | null |
from pages.about_page import get_about_page as about_page
from pages.general_page import get_general_page as general_page
from pages.user_history_page import get_user_history_page as user_history_page
| 50.25
| 78
| 0.895522
| 36
| 201
| 4.583333
| 0.277778
| 0.163636
| 0.236364
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0.089552
| 201
| 3
| 79
| 67
| 0.901639
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| true
| 0
| 1
| 0
| 1
| 0
| 0
| 0
| 0
| null | 0
| 1
| 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
| 4
|
c7027fc4b72cd6dcaa85948c9b004dab91920470
| 95
|
py
|
Python
|
mypro/webtestapp/apps.py
|
yubboyu/django
|
cc261f658a6a0310e44b089959113cf5d88ce112
|
[
"MIT"
] | null | null | null |
mypro/webtestapp/apps.py
|
yubboyu/django
|
cc261f658a6a0310e44b089959113cf5d88ce112
|
[
"MIT"
] | null | null | null |
mypro/webtestapp/apps.py
|
yubboyu/django
|
cc261f658a6a0310e44b089959113cf5d88ce112
|
[
"MIT"
] | null | null | null |
from django.apps import AppConfig
class WebtestappConfig(AppConfig):
name = 'webtestapp'
| 15.833333
| 34
| 0.768421
| 10
| 95
| 7.3
| 0.9
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0.157895
| 95
| 5
| 35
| 19
| 0.9125
| 0
| 0
| 0
| 0
| 0
| 0.105263
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| false
| 0
| 0.333333
| 0
| 1
| 0
| 1
| 0
| 0
| null | 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| null | 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| 1
| 0
|
0
| 4
|
c71848f38fdc08f6b042d9ace261a1ea01381ccd
| 5,603
|
py
|
Python
|
twilio_management/models.py
|
icardenas/mirror-a2p-twilio
|
af6fe6099680491130a4bb5767bdde448f97feae
|
[
"Apache-2.0"
] | 3
|
2021-10-31T00:21:13.000Z
|
2022-03-07T21:11:14.000Z
|
twilio_management/models.py
|
icardenas/mirror-a2p-twilio
|
af6fe6099680491130a4bb5767bdde448f97feae
|
[
"Apache-2.0"
] | null | null | null |
twilio_management/models.py
|
icardenas/mirror-a2p-twilio
|
af6fe6099680491130a4bb5767bdde448f97feae
|
[
"Apache-2.0"
] | null | null | null |
import abc
import logging
from django.db import connection, models
logger = logging.getLogger(__name__)
class AbstractModel(models.Model):
class Meta:
abstract = True
@classmethod
def truncate(cls):
with connection.cursor() as cursor:
logger.info(f"truncate table {cls._meta.db_table}")
cursor.execute("TRUNCATE TABLE {} CASCADE".format(cls._meta.db_table))
class CustomerProfile(AbstractModel):
empty = models.BooleanField(default=False)
# valid_until = models.CharField(max_length=100, null=True)
date_updated = models.DateTimeField(auto_now=True)
friendly_name = models.CharField(max_length=255, null=True)
url = models.CharField(max_length=255, null=True)
date_created = models.DateTimeField(auto_now_add=False)
sid = models.CharField(max_length=255, null=True)
policy_sid = models.CharField(max_length=255, null=True)
email = models.CharField(max_length=255, null=True)
status_callback = models.CharField(max_length=255, null=True)
status = models.CharField(max_length=16, null=True)
class A2PBrand(AbstractModel):
date_created = models.DateTimeField(auto_now_add=False)
date_updated = models.DateTimeField(auto_now=True)
email = models.CharField(max_length=255, null=True)
friendly_name = models.CharField(max_length=255, null=True)
# links: Links
policy_sid = models.CharField(max_length=255, null=True)
sid = models.CharField(max_length=255, null=True)
status = models.CharField(max_length=255, null=True)
status_callback = models.CharField(max_length=255, null=True)
url = models.CharField(max_length=255, null=True)
valid_until = models.CharField(max_length=255, null=True)
class BrandRegistration(AbstractModel):
a2p_brand = models.ForeignKey(
A2PBrand, on_delete=models.CASCADE, null=True
)
a2p_profile_bundle_sid = models.CharField(max_length=64)
brand_score: models.IntegerField(default=0)
brand_type: models.CharField(max_length=64)
customer_profile_bundle_sid = models.CharField(max_length=64)
date_created = models.DateTimeField(auto_now_add=False)
date_updated = models.DateTimeField(auto_now=True)
failure_reason = models.CharField(max_length=255, null=True)
identity_status = models.CharField(max_length=64, null=True)
mock = models.BooleanField(default=False)
russell_3000 = models.CharField(max_length=64, null=True)
sid = models.CharField(max_length=64)
skip_automatic_sec_vet = models.BooleanField(default=False)
status = models.CharField(max_length=64)
tax_exempt_status = models.CharField(max_length=64, null=True)
tcr_id = models.CharField(max_length=64, null=True)
url = models.CharField(max_length=255, null=True)
class MessagingService(AbstractModel):
sid = models.CharField(max_length=34)
friendly_name = models.CharField(max_length=255)
date_created = models.DateTimeField(auto_now_add=False)
date_updated = models.DateTimeField(auto_now=False)
status = models.CharField(max_length=16)
inbound_request_url = models.CharField(max_length=255, null=True)
inbound_method = models.CharField(max_length=4)
fallback_url = models.CharField(max_length=255, null=True)
fallback_method = models.CharField(max_length=4)
status_callback = models.CharField(max_length=255, null=True)
smart_encoding = models.BooleanField(default=False)
fallback_to_long_code = models.BooleanField(default=False)
scan_message_content = models.CharField(max_length=255, null=True)
usecase = models.CharField(max_length=255)
us_app_to_person_registered = models.BooleanField(default=False)
use_inbound_webhook_on_number = models.BooleanField(default=False)
def __str__(self):
return self.friendly_name
class Compliance(AbstractModel):
sid = models.CharField(max_length=34)
friendly_name = models.CharField(max_length=255)
has_embedded_phone= models.BooleanField(default=False)
brand_registration_sid= models.CharField(max_length=34)
description= models.CharField(max_length=255)
date_updated= models.DateTimeField(auto_now=True)
campaign_status= models.CharField(max_length=16)
campaign_id= models.CharField(max_length=34, null=True)
is_externally_registered= models.BooleanField(default=False)
has_embedded_links= models.BooleanField(default=False)
url= models.CharField(max_length=255)
sid= models.CharField(max_length=34)
date_created = models.DateTimeField(auto_now_add=False)
us_app_to_person_usecase = models.CharField(max_length=255)
mock = models.BooleanField(default=False)
messaging_service = models.ForeignKey(
MessagingService, on_delete=models.CASCADE, null=True
)
class PhoneNumber(AbstractModel):
phone_number = models.CharField(max_length=20)
friendly_name = models.CharField(max_length=255)
date_created = models.DateTimeField(auto_now_add=False)
date_updated = models.DateTimeField(auto_now=False)
sid = models.CharField(max_length=34)
sms_fallback_method = models.CharField(max_length=4)
sms_fallback_url = models.CharField(max_length=255)
sms_method = models.CharField(max_length=4)
sms_url = models.CharField(max_length=255)
status_callback = models.CharField(max_length=255)
status_callback_method = models.CharField(max_length=4)
status = models.CharField(max_length=16)
messaging_service = models.ForeignKey(
MessagingService, on_delete=models.CASCADE, null=True
)
def __str__(self):
return self.friendly_name
| 43.434109
| 82
| 0.758165
| 729
| 5,603
| 5.577503
| 0.175583
| 0.206591
| 0.247909
| 0.330546
| 0.735612
| 0.68544
| 0.574766
| 0.432366
| 0.330054
| 0.286276
| 0
| 0.030631
| 0.143495
| 5,603
| 128
| 83
| 43.773438
| 0.816628
| 0.012493
| 0
| 0.409091
| 0
| 0
| 0.01085
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0.027273
| false
| 0
| 0.027273
| 0.018182
| 0.890909
| 0
| 0
| 0
| 0
| null | 1
| 1
| 1
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| null | 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
|
0
| 4
|
c7452593d2f552d5204a88816a6e9169903bc261
| 213
|
py
|
Python
|
splitiorequests/models/splits/splits.py
|
mikoblog/splitio-requests
|
c09b069e49f5224cbe3f892a5731c62885fd6151
|
[
"MIT"
] | null | null | null |
splitiorequests/models/splits/splits.py
|
mikoblog/splitio-requests
|
c09b069e49f5224cbe3f892a5731c62885fd6151
|
[
"MIT"
] | 4
|
2020-11-22T12:07:45.000Z
|
2021-03-26T23:44:12.000Z
|
splitiorequests/models/splits/splits.py
|
mikoblog/splitio-requests
|
c09b069e49f5224cbe3f892a5731c62885fd6151
|
[
"MIT"
] | null | null | null |
# -*- coding: utf-8 -*-
from dataclasses import dataclass
from typing import List
from .split import Split
@dataclass
class Splits:
objects: List[Split]
offset: int
limit: int
totalCount: int
| 13.3125
| 33
| 0.685446
| 27
| 213
| 5.407407
| 0.62963
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0.006098
| 0.230047
| 213
| 15
| 34
| 14.2
| 0.884146
| 0.098592
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| true
| 0
| 0.333333
| 0
| 0.888889
| 0
| 1
| 0
| 0
| null | 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| null | 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| 1
| 0
| 1
| 0
|
0
| 4
|
c75949df35529283e9ea57bce58ef0ef9e3877b4
| 9,343
|
py
|
Python
|
tests/test_planning_exploring_starts_policy.py
|
pudumagico/RLASP
|
bce5b87404fdca60e983e4a187e734c49ac923fa
|
[
"MIT"
] | null | null | null |
tests/test_planning_exploring_starts_policy.py
|
pudumagico/RLASP
|
bce5b87404fdca60e983e4a187e734c49ac923fa
|
[
"MIT"
] | 1
|
2021-06-02T16:55:33.000Z
|
2021-06-04T14:30:54.000Z
|
tests/test_planning_exploring_starts_policy.py
|
pudumagico/RLASP
|
bce5b87404fdca60e983e4a187e734c49ac923fa
|
[
"MIT"
] | 2
|
2021-03-22T14:46:49.000Z
|
2021-03-31T16:12:12.000Z
|
import os
import sys
import unittest
from unittest.mock import MagicMock, patch
# Make sure the path of the framework is included in the import path
sys.path.insert(0, os.path.abspath(os.path.join(os.path.dirname(__file__), '../src')))
# Framework imports
from mdp import VacuumCleanerWorldBuilder
from policy import PlanningExploringStartsPolicy, PlannerPolicy, RandomPolicy, RandomPolicy, QTablePolicy
import random
class TestPlanningExploringStartsPolicy(unittest.TestCase):
def test_is_new_state(self):
qtable_policy = QTablePolicy()
random_policy = RandomPolicy()
mdp_builder = VacuumCleanerWorldBuilder()
mdp = mdp_builder.build_mdp()
planner_policy = PlannerPolicy(planning_horizon=1, mdp_builder=mdp_builder)
policy = PlanningExploringStartsPolicy(planner_policy, random_policy, qtable_policy)
self.assertTrue(policy.is_new_state(state='s1'))
policy.initialize_state(state='s1', available_actions={'a(1)', 'a(2)'})
self.assertFalse(policy.is_new_state('s1'))
def test_exploring_starts(self):
planner_policy = MagicMock(spec=PlannerPolicy)
qtable_policy = MagicMock(spec=QTablePolicy)
random_policy = MagicMock(spec=RandomPolicy)
random_policy.suggest_action_for_state = MagicMock(return_value='a3')
policy = PlanningExploringStartsPolicy(planner_policy, random_policy, qtable_policy)
policy.initialize_state('s1', {'a1', 'a2', 'a3'})
suggested_action = policy.suggest_action_for_state('s1')
# The first action in a new episode should be random (exploring start)
random_policy.suggest_action_for_state.assert_called_with('s1')
self.assertEqual('a3', suggested_action)
# Any following action should either be planned or greedy, but not random.
random_policy.reset_mock()
policy.initialize_state('s2', {'a3', 'a4', 'a5'})
_ = policy.suggest_action_for_state('s2')
self.assertTrue(planner_policy.suggest_action_for_state.called \
or qtable_policy.suggest_action_for_state.called)
random_policy.suggest_action_for_state.assert_not_called()
# If we start a new episode, the first action should be random again.
policy.initialize_new_episode()
suggested_action = policy.suggest_action_for_state('s1')
random_policy.suggest_action_for_state.assert_called_with('s1')
self.assertEqual('a3', suggested_action)
def test_plan_for_new_states(self):
planner_policy = MagicMock(spec=PlannerPolicy)
planner_policy.suggest_action_for_state = MagicMock(return_value='a2')
qtable_policy = MagicMock(spec=QTablePolicy)
qtable_policy.suggest_action_for_state = MagicMock(return_value='a3')
random_policy = MagicMock(spec=RandomPolicy)
policy = PlanningExploringStartsPolicy(planner_policy, random_policy, qtable_policy,
plan_for_new_states = True)
# First action is an exploring start
policy.initialize_state('s1', {'a1'})
policy.suggest_action_for_state('s1')
random_policy.reset_mock()
# Second action is in an unknown state. The planner should be used.
policy.initialize_state('s2', {'a2', 'a3'})
suggested_action = policy.suggest_action_for_state('s2')
self.assertEqual('a2', suggested_action)
planner_policy.suggest_action_for_state.assert_called_with('s2')
random_policy.suggest_action_for_state.assert_not_called()
qtable_policy.suggest_action_for_state.assert_not_called()
planner_policy.reset_mock()
# The next time we encounter s2, no planning should happen.
suggested_action = policy.suggest_action_for_state('s2')
self.assertEqual('a3', suggested_action)
qtable_policy.suggest_action_for_state.assert_called_with('s2')
random_policy.suggest_action_for_state.assert_not_called()
planner_policy.suggest_action_for_state.assert_not_called()
def test_dont_plan_for_new_states(self):
planner_policy = MagicMock(spec=PlannerPolicy)
planner_policy.suggest_action_for_state = MagicMock(return_value='a2')
qtable_policy = MagicMock(spec=QTablePolicy)
qtable_policy.suggest_action_for_state = MagicMock(return_value='a3')
random_policy = MagicMock(spec=RandomPolicy)
policy = PlanningExploringStartsPolicy(planner_policy, random_policy, qtable_policy,
plan_for_new_states = False)
# First action is an exploring start
policy.initialize_state('s1', {'a1'})
policy.suggest_action_for_state('s1')
random_policy.reset_mock()
# Second action is in an unknown state. The planner should be used.
policy.initialize_state('s2', {'a2', 'a3'})
suggested_action = policy.suggest_action_for_state('s2')
self.assertEqual('a3', suggested_action)
planner_policy.suggest_action_for_state.assert_not_called()
random_policy.suggest_action_for_state.assert_not_called()
qtable_policy.suggest_action_for_state.assert_called_with('s2')
planner_policy.reset_mock()
# The next time we encounter s2, no planning should happen.
suggested_action = policy.suggest_action_for_state('s2')
self.assertEqual('a3', suggested_action)
qtable_policy.suggest_action_for_state.assert_called_with('s2')
random_policy.suggest_action_for_state.assert_not_called()
planner_policy.suggest_action_for_state.assert_not_called()
def test_planning_factor(self):
planner_policy = MagicMock(spec=PlannerPolicy)
planner_policy.suggest_action_for_state = MagicMock(return_value='plan')
qtable_policy = MagicMock(spec=QTablePolicy)
qtable_policy.suggest_action_for_state = MagicMock(return_value='greedy')
random_policy = MagicMock(spec=RandomPolicy)
policy = PlanningExploringStartsPolicy(planner_policy, random_policy, qtable_policy,
planning_factor = 0.2)
# First action is an exploring start
policy.initialize_state('s1', {'plan', 'greedy'})
policy.suggest_action_for_state('s1')
random_policy.reset_mock()
# The second suggestion is randomly chosen between the qtable policy and
# the planning policy. Let's mock up the random number generator to only
# get suggestions from the qtable policy.
with patch('random.random', MagicMock(return_value=0.21)): # 0.21 > 0.2 -> follow greedy policy
suggested_action = policy.suggest_action_for_state('s1')
self.assertEqual('greedy', suggested_action)
qtable_policy.suggest_action_for_state.assert_called_with('s1')
planner_policy.suggest_action_for_state.assert_not_called()
random_policy.suggest_action_for_state.assert_not_called()
qtable_policy.reset_mock()
# On the other hand, when we mock up the random number generator such
# that we only get suggestions from the planner policy, things should
# go accordingly.
with patch('random.random', MagicMock(return_value=0.19)): # 0.19 < 0.2 -> follow planner policy
suggested_action = policy.suggest_action_for_state('s1')
self.assertEqual('plan', suggested_action)
planner_policy.suggest_action_for_state.assert_called_with('s1')
qtable_policy.suggest_action_for_state.assert_not_called()
random_policy.suggest_action_for_state.assert_not_called()
planner_policy.reset_mock()
def test_update(self):
planner_policy = MagicMock()
qtable_policy = MagicMock(spec=QTablePolicy())
random_policy = MagicMock(spec=RandomPolicy())
policy = PlanningExploringStartsPolicy(planner_policy, random_policy, qtable_policy)
# Updating the policy should update the qtable policy as well.
policy.initialize_state('s1', {'a1', 'a2'})
policy.update('s1', 'a2', -1.23)
qtable_policy.update.assert_called_with('s1', 'a2', -1.23)
def test_value_for(self):
planner_policy = MagicMock()
qtable_policy = QTablePolicy()
random_policy = RandomPolicy()
policy = PlanningExploringStartsPolicy(planner_policy, random_policy, qtable_policy)
# Evaluation of a state-action pair should be the same as for the qtable policy.
policy.initialize_state('s1', {'a1', 'a2'})
policy.update('s1', 'a2', -1.23)
self.assertEqual(-1.23, policy.value_for('s1', 'a2'))
def test_optimal_value_for(self):
planner_policy = MagicMock()
qtable_policy = QTablePolicy()
random_policy = RandomPolicy()
policy = PlanningExploringStartsPolicy(planner_policy, random_policy, qtable_policy)
# Evaluation of a state-action pair should be the same as for the qtable policy.
policy.initialize_state('s', {'a', 'b', 'c'})
policy.update('s', 'a', 1.23)
policy.update('s', 'b', -5.43)
policy.update('s', 'c', 0.03)
self.assertEqual(1.23, policy.optimal_value_for('s'))
| 45.354369
| 105
| 0.696564
| 1,119
| 9,343
| 5.502234
| 0.131367
| 0.08868
| 0.129609
| 0.150073
| 0.768231
| 0.752314
| 0.710736
| 0.705376
| 0.656813
| 0.63976
| 0
| 0.015644
| 0.213208
| 9,343
| 205
| 106
| 45.57561
| 0.821929
| 0.136359
| 0
| 0.602941
| 0
| 0
| 0.026725
| 0
| 0
| 0
| 0
| 0
| 0.257353
| 1
| 0.058824
| false
| 0
| 0.051471
| 0
| 0.117647
| 0
| 0
| 0
| 0
| null | 0
| 0
| 0
| 0
| 1
| 1
| 1
| 0
| 1
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| null | 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
|
0
| 4
|
c77692b0ecb2549fd064e002e2ed7f6755d50bef
| 237
|
py
|
Python
|
tests/stile/test_stile_builder.py
|
mccormickmichael/laurel
|
6222d8d2dea6fa18cfe3b031434154003e8a125b
|
[
"Unlicense"
] | 1
|
2018-08-20T13:49:46.000Z
|
2018-08-20T13:49:46.000Z
|
tests/stile/test_stile_builder.py
|
mccormickmichael/laurel
|
6222d8d2dea6fa18cfe3b031434154003e8a125b
|
[
"Unlicense"
] | null | null | null |
tests/stile/test_stile_builder.py
|
mccormickmichael/laurel
|
6222d8d2dea6fa18cfe3b031434154003e8a125b
|
[
"Unlicense"
] | null | null | null |
import unittest
from scaffold.stile.stile_builder import StileBuilder
class TestServicesBuilder(unittest.TestCase):
def test_import(self):
# this placeholder test enforces that VpcBuilder's imports are valid
pass
| 21.545455
| 76
| 0.763713
| 28
| 237
| 6.392857
| 0.821429
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0.189873
| 237
| 10
| 77
| 23.7
| 0.932292
| 0.278481
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0.2
| false
| 0.2
| 0.6
| 0
| 1
| 0
| 1
| 0
| 0
| null | 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| null | 0
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 1
| 0
| 1
| 0
|
0
| 4
|
c7882034a3e30bd849525bd5d10f95e6a090212f
| 118
|
py
|
Python
|
Gathered CTF writeups/ptr-yudai-writeups/2019/Sunshine_CTF_2019/middle_ocean/solve.py
|
mihaid-b/CyberSakura
|
f60e6b6bfd6898c69b84424b080090ae98f8076c
|
[
"MIT"
] | 1
|
2022-03-27T06:00:41.000Z
|
2022-03-27T06:00:41.000Z
|
Gathered CTF writeups/ptr-yudai-writeups/2019/Sunshine_CTF_2019/middle_ocean/solve.py
|
mihaid-b/CyberSakura
|
f60e6b6bfd6898c69b84424b080090ae98f8076c
|
[
"MIT"
] | null | null | null |
Gathered CTF writeups/ptr-yudai-writeups/2019/Sunshine_CTF_2019/middle_ocean/solve.py
|
mihaid-b/CyberSakura
|
f60e6b6bfd6898c69b84424b080090ae98f8076c
|
[
"MIT"
] | 1
|
2022-03-27T06:01:42.000Z
|
2022-03-27T06:01:42.000Z
|
l = [83, 85, 78, 123, 77, 52, 57, 53, 45, 102, 52, 110, 33, 125]
flag = ""
for c in l:
flag += chr(c)
print(flag)
| 19.666667
| 64
| 0.516949
| 25
| 118
| 2.44
| 0.8
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0.367816
| 0.262712
| 118
| 5
| 65
| 23.6
| 0.333333
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| false
| 0
| 0
| 0
| 0
| 0.2
| 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 | 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
|
0
| 4
|
c7b7504b98e295f424ed8a06a19a618d573ecece
| 296
|
py
|
Python
|
lib/python3.9/site-packages/tests/test_youtube.py
|
gitloon/sopel
|
8cf460fc9ee5c53c36cdfffcf019e6df4801515e
|
[
"EFL-2.0"
] | 5
|
2016-02-20T02:45:59.000Z
|
2022-01-10T18:20:43.000Z
|
lib/python3.9/site-packages/tests/test_youtube.py
|
gitloon/sopel
|
8cf460fc9ee5c53c36cdfffcf019e6df4801515e
|
[
"EFL-2.0"
] | 32
|
2015-10-09T00:58:00.000Z
|
2022-03-05T21:02:05.000Z
|
lib/python3.9/site-packages/tests/test_youtube.py
|
gitloon/sopel
|
8cf460fc9ee5c53c36cdfffcf019e6df4801515e
|
[
"EFL-2.0"
] | 22
|
2015-10-01T13:04:19.000Z
|
2021-06-28T09:46:39.000Z
|
#!/usr/bin/env python
# coding=utf-8
from __future__ import unicode_literals, absolute_import, division, print_function
import unittest
from sopel_modules.youtube import youtube
class TestYoutube(unittest.TestCase):
def setUp(self):
pass
def testSomething(self):
pass
| 19.733333
| 82
| 0.746622
| 37
| 296
| 5.756757
| 0.756757
| 0.075117
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0.004115
| 0.179054
| 296
| 14
| 83
| 21.142857
| 0.872428
| 0.111486
| 0
| 0.25
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0.25
| false
| 0.25
| 0.375
| 0
| 0.75
| 0.125
| 0
| 0
| 0
| null | 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| null | 0
| 0
| 0
| 0
| 0
| 1
| 0
| 1
| 1
| 0
| 1
| 0
|
0
| 4
|
c7ccc63e485408d3a3683026b69ce3813f8b4d44
| 356
|
py
|
Python
|
bob/learn/tensorflow/scripts/tf.py
|
bioidiap/bob.learn.tensorflow
|
7813e4ce3eecd77987a7046679f0d9ff52d06005
|
[
"BSD-3-Clause"
] | 2
|
2020-08-03T17:07:18.000Z
|
2021-11-21T22:03:17.000Z
|
bob/learn/tensorflow/scripts/tf.py
|
bioidiap/bob.learn.tensorflow
|
7813e4ce3eecd77987a7046679f0d9ff52d06005
|
[
"BSD-3-Clause"
] | null | null | null |
bob/learn/tensorflow/scripts/tf.py
|
bioidiap/bob.learn.tensorflow
|
7813e4ce3eecd77987a7046679f0d9ff52d06005
|
[
"BSD-3-Clause"
] | null | null | null |
"""The main entry for bob tf (click-based) scripts.
"""
import click
import pkg_resources
from click_plugins import with_plugins
from bob.extension.scripts.click_helper import AliasedGroup
@with_plugins(pkg_resources.iter_entry_points("bob.learn.tensorflow.cli"))
@click.group(cls=AliasedGroup)
def tf():
"""Tensorflow-related commands."""
pass
| 23.733333
| 74
| 0.77809
| 49
| 356
| 5.489796
| 0.591837
| 0.089219
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0.109551
| 356
| 14
| 75
| 25.428571
| 0.84858
| 0.216292
| 0
| 0
| 0
| 0
| 0.089888
| 0.089888
| 0
| 0
| 0
| 0
| 0
| 1
| 0.125
| true
| 0.125
| 0.5
| 0
| 0.625
| 0
| 0
| 0
| 0
| null | 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| null | 0
| 0
| 0
| 0
| 0
| 0
| 1
| 1
| 1
| 0
| 1
| 0
|
0
| 4
|
c7d83d61b0df5cda4214e23d39dd00cef93e1896
| 225
|
py
|
Python
|
exceldriver/__init__.py
|
whoopnip/py-excel-driver
|
6910ba3487ffd4aec4ceba7c57f14c1ae0c12fff
|
[
"MIT"
] | 1
|
2021-11-10T03:29:32.000Z
|
2021-11-10T03:29:32.000Z
|
exceldriver/__init__.py
|
whoopnip/py-excel-driver
|
6910ba3487ffd4aec4ceba7c57f14c1ae0c12fff
|
[
"MIT"
] | 4
|
2020-03-24T17:43:57.000Z
|
2021-06-02T00:26:44.000Z
|
exceldriver/__init__.py
|
whoopnip/py-excel-driver
|
6910ba3487ffd4aec4ceba7c57f14c1ae0c12fff
|
[
"MIT"
] | 1
|
2021-08-09T11:09:07.000Z
|
2021-08-09T11:09:07.000Z
|
"""
A tool used to work with Excel from Python. It currently mainly handles starting and stopping
Excel, and getting the active Excel instance and workbook so that COM commands can be run on them.
"""
from .excel import Excel
| 45
| 98
| 0.782222
| 38
| 225
| 4.631579
| 0.815789
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0.173333
| 225
| 5
| 99
| 45
| 0.946237
| 0.853333
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| true
| 0
| 1
| 0
| 1
| 0
| 0
| 0
| 0
| null | 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| 0
| 0
| 1
| 0
| 0
| 0
| 0
| 0
| 0
| null | 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| 1
| 0
| 0
| 0
|
0
| 4
|
c7f59a1fb3ccd8b667ce30846486f35e7bc2c28d
| 321
|
py
|
Python
|
py/jupyterlab-sqlite3/src/jupyterlab_sqlite3/tests/test_meta.py
|
gt-coar/janki
|
69141d66415757c373300e0404b0d49d1c3456bb
|
[
"BSD-3-Clause"
] | 1
|
2021-05-25T15:59:25.000Z
|
2021-05-25T15:59:25.000Z
|
py/jupyterlab-sqlite3/src/jupyterlab_sqlite3/tests/test_meta.py
|
gt-coar/janki
|
69141d66415757c373300e0404b0d49d1c3456bb
|
[
"BSD-3-Clause"
] | 7
|
2021-05-11T19:37:23.000Z
|
2021-06-16T15:12:12.000Z
|
py/jupyterlab-sqlite3/src/jupyterlab_sqlite3/tests/test_meta.py
|
gt-coar/janki
|
69141d66415757c373300e0404b0d49d1c3456bb
|
[
"BSD-3-Clause"
] | 1
|
2021-05-11T19:34:46.000Z
|
2021-05-11T19:34:46.000Z
|
# Copyright (c) 2021 University System of Georgia and janki contributors
# Distributed under the terms of the BSD-3-Clause License.
import jupyterlab_sqlite3
def test_version():
assert jupyterlab_sqlite3.__version__
def test_labextensions():
assert len(jupyterlab_sqlite3._jupyter_labextension_paths()) == 1
| 24.692308
| 72
| 0.794393
| 41
| 321
| 5.926829
| 0.756098
| 0.209877
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0.032609
| 0.140187
| 321
| 12
| 73
| 26.75
| 0.847826
| 0.395639
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0.4
| 1
| 0.4
| true
| 0
| 0.2
| 0
| 0.6
| 0
| 0
| 0
| 0
| null | 1
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| null | 0
| 0
| 0
| 0
| 0
| 1
| 1
| 0
| 0
| 0
| 1
| 0
|
0
| 4
|
1be7f86042e471561d66170cab2e2a8a197d32ff
| 2,555
|
py
|
Python
|
MainSite/migrations/0001_initial.py
|
mellora/EliteConsortiumWebSite
|
02fbcd3aed5e3794b50445f1881e03945ee73f20
|
[
"MIT"
] | null | null | null |
MainSite/migrations/0001_initial.py
|
mellora/EliteConsortiumWebSite
|
02fbcd3aed5e3794b50445f1881e03945ee73f20
|
[
"MIT"
] | null | null | null |
MainSite/migrations/0001_initial.py
|
mellora/EliteConsortiumWebSite
|
02fbcd3aed5e3794b50445f1881e03945ee73f20
|
[
"MIT"
] | null | null | null |
# Generated by Django 3.1.3 on 2020-11-30 17:22
from django.db import migrations, models
class Migration(migrations.Migration):
initial = True
dependencies = [
]
operations = [
migrations.CreateModel(
name='MemberConsortiumPricing',
fields=[
('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
('service_name', models.CharField(max_length=200)),
('min_price', models.DecimalField(decimal_places=2, default=0, max_digits=5)),
('max_price', models.DecimalField(decimal_places=2, default=0, max_digits=5)),
('extra_cost_text', models.CharField(blank=True, default='', max_length=200, null=True)),
('extra_cost', models.DecimalField(decimal_places=2, default=0, max_digits=5)),
],
options={
'verbose_name': 'Member Consortium Pricing',
'verbose_name_plural': 'Member Consortium Pricing',
},
),
migrations.CreateModel(
name='NonMemberConsortiumPricing',
fields=[
('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
('service_name', models.CharField(max_length=200)),
('price', models.DecimalField(decimal_places=2, default=0, max_digits=5)),
('extra_cost_text', models.CharField(blank=True, default='', max_length=200, null=True)),
('extra_cost', models.DecimalField(decimal_places=2, default=0, max_digits=5)),
],
options={
'verbose_name': 'Non Member Consortium Pricing',
'verbose_name_plural': 'Non Member Consortium Pricing',
},
),
migrations.CreateModel(
name='ThirdPartyProgramSupportFees',
fields=[
('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
('service', models.CharField(max_length=200)),
('charge_rate', models.CharField(max_length=200)),
('driver_num', models.CharField(max_length=200)),
('price', models.DecimalField(decimal_places=2, default=0, max_digits=5)),
],
options={
'verbose_name': 'Third Party Program Support Fees',
'verbose_name_plural': 'Third Party Program Support Fees',
},
),
]
| 44.051724
| 114
| 0.581605
| 255
| 2,555
| 5.635294
| 0.282353
| 0.068894
| 0.058455
| 0.129436
| 0.802366
| 0.725818
| 0.60334
| 0.60334
| 0.60334
| 0.60334
| 0
| 0.029785
| 0.290411
| 2,555
| 57
| 115
| 44.824561
| 0.762824
| 0.017613
| 0
| 0.52
| 1
| 0
| 0.192982
| 0.030702
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| false
| 0
| 0.02
| 0
| 0.1
| 0
| 0
| 0
| 0
| null | 0
| 0
| 0
| 1
| 1
| 0
| 0
| 0
| 1
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| 0
| 0
| null | 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
|
0
| 4
|
1beae98e55ef740b718861cabcd8be22ec93822a
| 829
|
py
|
Python
|
dvadmin-backend/apps/vadmin/stock/models/index_history.py
|
zzjo/dvadmin-backend
|
b114af920c101becd94b2ed28d04bd084d25d342
|
[
"MIT"
] | 1
|
2021-12-20T10:10:34.000Z
|
2021-12-20T10:10:34.000Z
|
dvadmin-backend/apps/vadmin/stock/models/index_history.py
|
zzjo/dvadmin-backend
|
b114af920c101becd94b2ed28d04bd084d25d342
|
[
"MIT"
] | null | null | null |
dvadmin-backend/apps/vadmin/stock/models/index_history.py
|
zzjo/dvadmin-backend
|
b114af920c101becd94b2ed28d04bd084d25d342
|
[
"MIT"
] | null | null | null |
from django.db.models import CharField, DecimalField, DateField
from apps.vadmin.op_drf.models import CoreModel
class IndexHistory(CoreModel):
name = CharField(max_length=64, verbose_name="名称")
code = CharField(max_length=64, verbose_name="代码")
date = DateField(verbose_name="时间")
open = DecimalField(max_digits=19, decimal_places=3, verbose_name="开盘价")
high = DecimalField(max_digits=19, decimal_places=3, verbose_name="最高价")
low = DecimalField(max_digits=19, decimal_places=3, verbose_name="最低价")
close = DecimalField(max_digits=19, decimal_places=3, verbose_name="收盘价")
volume = DecimalField(max_digits=19, decimal_places=0, verbose_name="成交量")
class Meta:
verbose_name = "指数历史数据"
verbose_name_plural = verbose_name
def __str__(self):
return f"{self.name}"
| 37.681818
| 78
| 0.729795
| 112
| 829
| 5.142857
| 0.4375
| 0.210069
| 0.182292
| 0.199653
| 0.503472
| 0.503472
| 0.333333
| 0.333333
| 0.333333
| 0
| 0
| 0.027143
| 0.155609
| 829
| 21
| 79
| 39.47619
| 0.795714
| 0
| 0
| 0
| 0
| 0
| 0.045838
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0.0625
| false
| 0
| 0.125
| 0.0625
| 0.875
| 0
| 0
| 0
| 0
| null | 1
| 1
| 1
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| null | 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
|
0
| 4
|
1bff0c27b95eb50252a3d37bacf1dc50484fe209
| 138
|
py
|
Python
|
apps/operation/__init__.py
|
ZREDU-007/mooc
|
1a1f4f92e029da68e032db0005ac955fc1ca3e8c
|
[
"Apache-2.0"
] | 5
|
2020-01-04T01:21:22.000Z
|
2020-11-19T09:10:50.000Z
|
apps/operation/__init__.py
|
ZREDU-007/mooc
|
1a1f4f92e029da68e032db0005ac955fc1ca3e8c
|
[
"Apache-2.0"
] | 6
|
2020-02-12T03:25:29.000Z
|
2021-09-08T01:33:43.000Z
|
apps/operation/__init__.py
|
ZREDU-007/mooc
|
1a1f4f92e029da68e032db0005ac955fc1ca3e8c
|
[
"Apache-2.0"
] | null | null | null |
# -*- coding: utf-8 -*-
__author__ = 'Kris,QQ:1209304692。QQ群:知尔MOOC,760196377'
default_app_config = "operation.apps.OperationConfig"
| 27.6
| 55
| 0.724638
| 16
| 138
| 5.875
| 1
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0.163934
| 0.115942
| 138
| 4
| 56
| 34.5
| 0.606557
| 0.152174
| 0
| 0
| 0
| 0
| 0.621622
| 0.621622
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| false
| 0
| 0
| 0
| 0
| 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
| 1
| 1
| null | 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
|
0
| 4
|
400f18d3de97ac4eed25040e49caa00d4dc12abe
| 80
|
py
|
Python
|
scripts/hdftools/hdfmultiple.py
|
jason-neal/Starfish
|
4ffa45e0190fb6f3262511d57d1a563e5ee711de
|
[
"BSD-3-Clause"
] | 1
|
2017-07-10T00:06:36.000Z
|
2017-07-10T00:06:36.000Z
|
scripts/hdftools/hdfmultiple.py
|
jason-neal/Starfish
|
4ffa45e0190fb6f3262511d57d1a563e5ee711de
|
[
"BSD-3-Clause"
] | null | null | null |
scripts/hdftools/hdfmultiple.py
|
jason-neal/Starfish
|
4ffa45e0190fb6f3262511d57d1a563e5ee711de
|
[
"BSD-3-Clause"
] | 5
|
2016-06-11T09:48:16.000Z
|
2019-08-07T19:52:41.000Z
|
#!/usr/bin/env python
import hdfutils
hdfutils.GR_list(hdfutils.flatchainList)
| 16
| 40
| 0.8125
| 11
| 80
| 5.818182
| 0.818182
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0.075
| 80
| 5
| 40
| 16
| 0.864865
| 0.25
| 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
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| null | 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| 1
| 0
| 0
| 0
|
0
| 4
|
4022048beaf9e62006b590c7f562be2560bb6504
| 96
|
py
|
Python
|
__main__.py
|
justJDev/Crosswords
|
8cbc8b2e4dc12b523d5a43baeeec832267101c52
|
[
"MIT"
] | null | null | null |
__main__.py
|
justJDev/Crosswords
|
8cbc8b2e4dc12b523d5a43baeeec832267101c52
|
[
"MIT"
] | null | null | null |
__main__.py
|
justJDev/Crosswords
|
8cbc8b2e4dc12b523d5a43baeeec832267101c52
|
[
"MIT"
] | null | null | null |
import tkinter
from game import CrosswordsGame
CrosswordsGame().new_game()
tkinter.mainloop()
| 13.714286
| 31
| 0.8125
| 11
| 96
| 7
| 0.636364
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0.104167
| 96
| 6
| 32
| 16
| 0.895349
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| true
| 0
| 0.5
| 0
| 0.5
| 0
| 1
| 0
| 0
| null | 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| null | 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| 1
| 0
| 0
| 0
|
0
| 4
|
40292e606bac6356035c19823b121a70f86632aa
| 96
|
py
|
Python
|
Echo.py
|
shaharh21-meet/meet2019y1lab3
|
e6ec01576be32bed1ed0f7b405f1f03752fe6bc4
|
[
"MIT"
] | null | null | null |
Echo.py
|
shaharh21-meet/meet2019y1lab3
|
e6ec01576be32bed1ed0f7b405f1f03752fe6bc4
|
[
"MIT"
] | null | null | null |
Echo.py
|
shaharh21-meet/meet2019y1lab3
|
e6ec01576be32bed1ed0f7b405f1f03752fe6bc4
|
[
"MIT"
] | null | null | null |
user = input("Say something! ")
print(user.upper())
print(user.lower())
print(user.swapcase())
| 16
| 31
| 0.6875
| 13
| 96
| 5.076923
| 0.615385
| 0.409091
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0.09375
| 96
| 5
| 32
| 19.2
| 0.758621
| 0
| 0
| 0
| 0
| 0
| 0.157895
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| false
| 0
| 0
| 0
| 0
| 0.75
| 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
| 0
| 0
| 0
| 0
| 0
| 1
|
0
| 4
|
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.