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 |
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
9dd9dad394c32abe6360e1672d122d0e523f340a | 120 | py | Python | tests/test_pypkgs_pg.py | pgysbers/pypkgs_pg | 1e4a727e1ef6a41be98f2273fdcb68945de7c3fb | [
"MIT"
] | null | null | null | tests/test_pypkgs_pg.py | pgysbers/pypkgs_pg | 1e4a727e1ef6a41be98f2273fdcb68945de7c3fb | [
"MIT"
] | null | null | null | tests/test_pypkgs_pg.py | pgysbers/pypkgs_pg | 1e4a727e1ef6a41be98f2273fdcb68945de7c3fb | [
"MIT"
] | null | null | null | from pypkgs_pg import __version__
from pypkgs_pg import pypkgs_pg
def test_version():
assert __version__ == '0.1.0' | 24 | 33 | 0.775 | 19 | 120 | 4.263158 | 0.526316 | 0.296296 | 0.296296 | 0.444444 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0.029412 | 0.15 | 120 | 5 | 34 | 24 | 0.764706 | 0 | 0 | 0 | 0 | 0 | 0.041322 | 0 | 0 | 0 | 0 | 0 | 0.25 | 1 | 0.25 | true | 0 | 0.5 | 0 | 0.75 | 0 | 1 | 0 | 0 | null | 1 | 1 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 1 | 1 | 0 | 1 | 0 | 1 | 0 | 0 | 9 |
9ded117b54cfdd2170abcac9d6d621eb7539bf31 | 10,454 | py | Python | test/test_htmlmode.py | atsuoishimoto/kaaedit | 5233fdb70a04783c6513a5ec339452450e62e995 | [
"Unlicense"
] | 1 | 2015-11-04T13:37:08.000Z | 2015-11-04T13:37:08.000Z | test/test_htmlmode.py | atsuoishimoto/kaaedit | 5233fdb70a04783c6513a5ec339452450e62e995 | [
"Unlicense"
] | null | null | null | test/test_htmlmode.py | atsuoishimoto/kaaedit | 5233fdb70a04783c6513a5ec339452450e62e995 | [
"Unlicense"
] | null | null | null | import kaa_testutils
from kaa import highlight
from kaa.filetype.html import htmlmode
class TestHTMLHighlight(kaa_testutils._TestDocBase):
tokenizers = htmlmode.build_tokenizers()
def test_entity(self):
hl = highlight.Highlighter(tokenizers=self.tokenizers)
doc = self._getdoc('< ї ∢')
assert [
(0, 4, self.tokenizers[0].tokens.keywords.tokenid),
(4, 5, hl.tokenizers[0].nulltoken),
(5, 12, self.tokenizers[0].tokens.keywords.tokenid),
(12, 13, hl.tokenizers[0].nulltoken),
(13, 21, self.tokenizers[0].tokens.keywords.tokenid)
] == list((f, t, style) for f, t, style in hl.highlight(doc, 0))
def test_comment(self):
hl = highlight.Highlighter(tokenizers=self.tokenizers)
doc = self._getdoc('<!--abc-->')
assert [
(0, 4, self.tokenizers[0].tokens.comment.span_start),
(4, 7, self.tokenizers[0].tokens.comment.span_mid),
(7, 10, self.tokenizers[0].tokens.comment.span_end),
] == list((f, t, style) for f, t, style in hl.highlight(doc, 0))
doc = self._getdoc('<!--abc-x->')
assert [
(0, 4, self.tokenizers[0].tokens.comment.span_start),
(4, 11, self.tokenizers[0].tokens.comment.span_mid),
] == list((f, t, style) for f, t, style in hl.highlight(doc, 0))
def test_endtag(self):
hl = highlight.Highlighter(tokenizers=self.tokenizers)
doc = self._getdoc('</abc>')
assert [
(0, 2, self.tokenizers[0].tokens.endtag.span_start),
(2, 5, self.tokenizers[0].tokens.endtag.span_mid),
(5, 6, self.tokenizers[0].tokens.endtag.span_end),
] == list((f, t, style) for f, t, style in hl.highlight(doc, 0))
def test_elem(self):
hl = highlight.Highlighter(tokenizers=self.tokenizers)
doc = self._getdoc('<a> ')
assert [
(0, 1, hl.tokenizers[0].tokens.htmltag.span_lt),
(1, 2, hl.tokenizers[0].tokens.htmltag.span_elemname),
(2, 3, hl.tokenizers[0].tokens.htmltag.span_gt),
(3, 4, hl.tokenizers[0].nulltoken),
] == list((f, t, style) for f, t, style in hl.highlight(doc, 0))
doc = self._getdoc('< abc > ')
assert [
(0, 1, hl.tokenizers[0].tokens.htmltag.span_lt),
(1, 5, hl.tokenizers[0].tokens.htmltag.span_elemname),
(5, 7, hl.tokenizers[0].tokens.htmltag.span_gt),
(7, 8, hl.tokenizers[0].nulltoken),
] == list((f, t, style) for f, t, style in hl.highlight(doc, 0))
doc = self._getdoc('<abc xyz>')
assert [
(0, 1, hl.tokenizers[0].tokens.htmltag.span_lt),
(1, 4, hl.tokenizers[0].tokens.htmltag.span_elemname),
(4, 5, hl.tokenizers[0].tokens.htmltag.span_elemws),
(5, 8, hl.tokenizers[0].tokens.htmltag.span_attrname),
(8, 9, hl.tokenizers[0].tokens.htmltag.span_gt),
] == list((f, t, style) for f, t, style in hl.highlight(doc, 0))
doc = self._getdoc('<abc xyz = opq>')
assert [
(0, 1, hl.tokenizers[0].tokens.htmltag.span_lt),
(1, 4, hl.tokenizers[0].tokens.htmltag.span_elemname),
(4, 5, hl.tokenizers[0].tokens.htmltag.span_elemws),
(5, 8, hl.tokenizers[0].tokens.htmltag.span_attrname),
(8, 11, hl.tokenizers[0].tokens.htmltag.span_elemws),
(11, 14, hl.tokenizers[0].tokens.htmltag.span_attrvalue),
(14, 15, hl.tokenizers[0].tokens.htmltag.span_gt),
] == list((f, t, style) for f, t, style in hl.highlight(doc, 0))
doc = self._getdoc('<abc xyz = "opq">')
assert [
(0, 1, hl.tokenizers[0].tokens.htmltag.span_lt),
(1, 4, hl.tokenizers[0].tokens.htmltag.span_elemname),
(4, 5, hl.tokenizers[0].tokens.htmltag.span_elemws),
(5, 8, hl.tokenizers[0].tokens.htmltag.span_attrname),
(8, 11, hl.tokenizers[0].tokens.htmltag.span_elemws),
(11, 16, hl.tokenizers[0].tokens.htmltag.span_attrvalue),
(16, 17, hl.tokenizers[0].tokens.htmltag.span_gt),
] == list((f, t, style) for f, t, style in hl.highlight(doc, 0))
doc = self._getdoc("<abc xyz = 'opq' abc=123>")
assert [
(0, 1, hl.tokenizers[0].tokens.htmltag.span_lt),
(1, 4, hl.tokenizers[0].tokens.htmltag.span_elemname),
(4, 5, hl.tokenizers[0].tokens.htmltag.span_elemws),
(5, 8, hl.tokenizers[0].tokens.htmltag.span_attrname),
(8, 11, hl.tokenizers[0].tokens.htmltag.span_elemws),
(11, 16, hl.tokenizers[0].tokens.htmltag.span_attrvalue),
(16, 17, hl.tokenizers[0].tokens.htmltag.span_elemws),
(17, 20, hl.tokenizers[0].tokens.htmltag.span_attrname),
(20, 21, hl.tokenizers[0].tokens.htmltag.span_elemws),
(21, 24, hl.tokenizers[0].tokens.htmltag.span_attrvalue),
(24, 25, hl.tokenizers[0].tokens.htmltag.span_gt),
] == list((f, t, style) for f, t, style in hl.highlight(doc, 0))
doc = self._getdoc("<abc xyz= ")
assert [
(0, 1, hl.tokenizers[0].tokens.htmltag.span_lt),
(1, 4, hl.tokenizers[0].tokens.htmltag.span_elemname),
(4, 5, hl.tokenizers[0].tokens.htmltag.span_elemws),
(5, 8, hl.tokenizers[0].tokens.htmltag.span_attrname),
(8, 10, hl.tokenizers[0].tokens.htmltag.span_elemws),
] == list((f, t, style) for f, t, style in hl.highlight(doc, 0))
doc = self._getdoc("<abc xyz=>")
assert [
(0, 1, hl.tokenizers[0].tokens.htmltag.span_lt),
(1, 4, hl.tokenizers[0].tokens.htmltag.span_elemname),
(4, 5, hl.tokenizers[0].tokens.htmltag.span_elemws),
(5, 8, hl.tokenizers[0].tokens.htmltag.span_attrname),
(8, 9, hl.tokenizers[0].tokens.htmltag.span_elemws),
(9, 10, hl.tokenizers[0].tokens.htmltag.span_gt),
] == list((f, t, style) for f, t, style in hl.highlight(doc, 0))
def test_javascript(self):
hl = highlight.Highlighter(tokenizers=self.tokenizers)
doc = self._getdoc(" <script>if</script>if ")
assert [
(0, 6, hl.tokenizers[0].tokens.keywords.tokenid),
(6, 14, hl.tokenizers[0].tokens.jsstart.section_start),
(14, 16, hl.tokenizers[1].tokens[0].tokenid),
(16, 25, hl.tokenizers[1].tokens[-1].section_end),
(25, 27, hl.tokenizers[0].nulltoken),
(27, 33, hl.tokenizers[0].tokens.keywords.tokenid),
] == list((f, t, style) for f, t, style in hl.highlight(doc, 0))
def test_style(self):
hl = highlight.Highlighter(tokenizers=self.tokenizers)
doc = self._getdoc("<style>a</style> ")
assert [
(0, 7, hl.tokenizers[0].tokens.cssstart.section_start),
(7, 8, hl.tokenizers[2].tokens[0].span_selector),
(8, 16, hl.tokenizers[2].tokens[-1].span_close),
(16, 22, hl.tokenizers[0].tokens.keywords.tokenid),
] == list((f, t, style) for f, t, style in hl.highlight(doc, 0))
def test_javascriptattr1(self):
hl = highlight.Highlighter(tokenizers=self.tokenizers)
doc = self._getdoc("<a ona='if'>")
assert [
(0, 1, hl.tokenizers[0].tokens.htmltag.span_lt),
(1, 2, hl.tokenizers[0].tokens.htmltag.span_elemname),
(2, 3, hl.tokenizers[0].tokens.htmltag.span_elemws),
(3, 6, hl.tokenizers[0].tokens.htmltag.span_attrname),
(6, 7, hl.tokenizers[0].tokens.htmltag.span_elemws),
(7, 8, hl.tokenizers[0].tokens.htmltag.span_attrvalue),
(8, 10, hl.tokenizers[0].tokens.jsattr1.subtokenizer.tokens.keywords.tokenid),
(10, 11, hl.tokenizers[0].tokens.htmltag.span_attrvalue),
(11, 12, hl.tokenizers[0].tokens.htmltag.span_gt),
] == list((f, t, style) for f, t, style in hl.highlight(doc, 0))
def test_javascriptattr2(self):
hl = highlight.Highlighter(tokenizers=self.tokenizers)
doc = self._getdoc('<a ona="if">')
assert [
(0, 1, hl.tokenizers[0].tokens.htmltag.span_lt),
(1, 2, hl.tokenizers[0].tokens.htmltag.span_elemname),
(2, 3, hl.tokenizers[0].tokens.htmltag.span_elemws),
(3, 6, hl.tokenizers[0].tokens.htmltag.span_attrname),
(6, 7, hl.tokenizers[0].tokens.htmltag.span_elemws),
(7, 8, hl.tokenizers[0].tokens.htmltag.span_attrvalue),
(8, 10, hl.tokenizers[0].tokens.jsattr2.subtokenizer.tokens.keywords.tokenid),
(10, 11, hl.tokenizers[0].tokens.htmltag.span_attrvalue),
(11, 12, hl.tokenizers[0].tokens.htmltag.span_gt),
] == list((f, t, style) for f, t, style in hl.highlight(doc, 0))
def test_javascriptattr3(self):
hl = highlight.Highlighter(tokenizers=self.tokenizers)
doc = self._getdoc('<a ona="if>')
assert [
(0, 1, hl.tokenizers[0].tokens.htmltag.span_lt),
(1, 2, hl.tokenizers[0].tokens.htmltag.span_elemname),
(2, 3, hl.tokenizers[0].tokens.htmltag.span_elemws),
(3, 6, hl.tokenizers[0].tokens.htmltag.span_attrname),
(6, 7, hl.tokenizers[0].tokens.htmltag.span_elemws),
(7, 8, hl.tokenizers[0].tokens.htmltag.span_elemws),
(8, 10, hl.tokenizers[0].tokens.htmltag.span_attrname),
(10, 11, hl.tokenizers[0].tokens.htmltag.span_gt),
] == list((f, t, style) for f, t, style in hl.highlight(doc, 0))
def test_cssattr(self):
hl = highlight.Highlighter(tokenizers=self.tokenizers)
doc = self._getdoc("<a style=''>")
assert [
(0, 1, hl.tokenizers[0].tokens.htmltag.span_lt),
(1, 2, hl.tokenizers[0].tokens.htmltag.span_elemname),
(2, 3, hl.tokenizers[0].tokens.htmltag.span_elemws),
(3, 8, hl.tokenizers[0].tokens.htmltag.span_attrname),
(8, 9, hl.tokenizers[0].tokens.htmltag.span_elemws),
(9, 10, hl.tokenizers[0].tokens.htmltag.span_attrvalue),
(10, 11, hl.tokenizers[0].tokens.cssattr1.subtokenizer.tokens[0].span_close),
(11, 12, hl.tokenizers[0].tokens.htmltag.span_gt),
] == list((f, t, style) for f, t, style in hl.highlight(doc, 0))
| 49.545024 | 90 | 0.586952 | 1,414 | 10,454 | 4.251768 | 0.0686 | 0.186627 | 0.274285 | 0.27179 | 0.889721 | 0.879574 | 0.841484 | 0.781603 | 0.770126 | 0.770126 | 0 | 0.053245 | 0.245456 | 10,454 | 210 | 91 | 49.780952 | 0.708925 | 0 | 0 | 0.578378 | 0 | 0 | 0.023723 | 0.005261 | 0 | 0 | 0 | 0 | 0.097297 | 1 | 0.054054 | false | 0 | 0.016216 | 0 | 0.081081 | 0 | 0 | 0 | 0 | null | 0 | 1 | 1 | 1 | 1 | 1 | 1 | 1 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 8 |
d1bfd80bda1af7ffd19e3d0468b4bbf1d84be81d | 900 | py | Python | WEEKS/CD_Sata-Structures/_MISC/misc-examples/python3-book-examples/filecmp/filecmp_cmp.py | webdevhub42/Lambda | b04b84fb5b82fe7c8b12680149e25ae0d27a0960 | [
"MIT"
] | null | null | null | WEEKS/CD_Sata-Structures/_MISC/misc-examples/python3-book-examples/filecmp/filecmp_cmp.py | webdevhub42/Lambda | b04b84fb5b82fe7c8b12680149e25ae0d27a0960 | [
"MIT"
] | null | null | null | WEEKS/CD_Sata-Structures/_MISC/misc-examples/python3-book-examples/filecmp/filecmp_cmp.py | webdevhub42/Lambda | b04b84fb5b82fe7c8b12680149e25ae0d27a0960 | [
"MIT"
] | null | null | null | #
"""Compare two files.
"""
# end_pymotw_header
import filecmp
print("common_file :", end=" ")
print(
filecmp.cmp("example/dir1/common_file", "example/dir2/common_file", shallow=True),
end=" ",
)
print(
filecmp.cmp("example/dir1/common_file", "example/dir2/common_file", shallow=False)
)
print("contents_differ:", end=" ")
print(
filecmp.cmp(
"example/dir1/contents_differ", "example/dir2/contents_differ", shallow=True
),
end=" ",
)
print(
filecmp.cmp(
"example/dir1/contents_differ", "example/dir2/contents_differ", shallow=False
)
)
print("identical :", end=" ")
print(
filecmp.cmp(
"example/dir1/file_only_in_dir1", "example/dir1/file_only_in_dir1", shallow=True
),
end=" ",
)
print(
filecmp.cmp(
"example/dir1/file_only_in_dir1",
"example/dir1/file_only_in_dir1",
shallow=False,
)
)
| 20.454545 | 88 | 0.64 | 108 | 900 | 5.111111 | 0.212963 | 0.15942 | 0.163043 | 0.195652 | 0.807971 | 0.807971 | 0.807971 | 0.807971 | 0.786232 | 0.786232 | 0 | 0.022099 | 0.195556 | 900 | 43 | 89 | 20.930233 | 0.740331 | 0.041111 | 0 | 0.485714 | 0 | 0 | 0.446784 | 0.383626 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | true | 0 | 0.028571 | 0 | 0.028571 | 0.257143 | 0 | 0 | 0 | null | 0 | 0 | 1 | 1 | 1 | 1 | 1 | 1 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 8 |
884dc14ece3d310eca1e6e484753b98bea1d0ab5 | 48,297 | py | Python | projects/src/main/python/CodeJam/Y13R5P1/nwin/generated_py_77f0c66792644e1da5039395fc14534a.py | DynamicCodeSearch/CodeSeer | ee985ece7691691585952eb88565f0e08bdc9113 | [
"MIT"
] | 5 | 2020-04-05T18:04:13.000Z | 2021-04-13T20:34:19.000Z | projects/src/main/python/CodeJam/Y13R5P1/nwin/generated_py_77f0c66792644e1da5039395fc14534a.py | DynamicCodeSearch/CodeSeer | ee985ece7691691585952eb88565f0e08bdc9113 | [
"MIT"
] | 1 | 2020-04-29T21:42:26.000Z | 2020-05-01T23:45:45.000Z | projects/src/main/python/CodeJam/Y13R5P1/nwin/generated_py_77f0c66792644e1da5039395fc14534a.py | DynamicCodeSearch/CodeSeer | ee985ece7691691585952eb88565f0e08bdc9113 | [
"MIT"
] | 3 | 2020-01-27T16:02:14.000Z | 2021-02-08T13:25:15.000Z | import sys
sys.path.append('/home/george2/Raise/ProgramRepair/CodeSeer/projects/src/main/python')
from CodeJam.Y13R5P1.nwin.a import *
def func_6a16c606541c416eb2b58a44ce24aec8():
s = 10 ** 20
t = 0
return s
def func_4557fa6fa69e47c2b43919141fcb0ca2():
s = 10 ** 20
t = 0
return t
def func_905aa45390e048bc8a9a20387f648679():
t = 0
u = 0
return t
def func_71cf123689a945abb1a5842de7e57fd1():
t = 0
u = 0
return u
def func_36d785efed4841529d660312795177c7(u, z, t):
tmp = 36.0 * u / t - z
res = max(res, tmp)
return res
def func_ff5c42e603214275a0cb83266b901558(u, z, t):
tmp = 36.0 * u / t - z
res = max(res, tmp)
return tmp
def func_a4ea6167db2645c9b075a02768b20cac():
s = 10 ** 20
t = 0
u = 0
return s
def func_b8655e64b1f74167848f9b4f345a2bc6():
s = 10 ** 20
t = 0
u = 0
return u
def func_f1127e3ef4c34a77922bb35cb879d345():
s = 10 ** 20
t = 0
u = 0
return t
def func_4e67cda3f7a7407b9feb3a64eb1ce450(infile):
b, n = map(int, infile.readline().split())
z = map(int, infile.readline().split())
return n
def func_1620df784d8846f8948567cb582a451b(infile):
b, n = map(int, infile.readline().split())
z = map(int, infile.readline().split())
return b
def func_e8da2474739243dbb2438a4203793158(infile):
b, n = map(int, infile.readline().split())
z = map(int, infile.readline().split())
return z
def func_a249e36fe99d4665aa9638b041035610(infile, n):
z = map(int, infile.readline().split())
x = z + [0] * (37 - n)
return x
def func_4796b6a8ba5640d4be7becb3dc938d5c(infile, n):
z = map(int, infile.readline().split())
x = z + [0] * (37 - n)
return z
def func_5f6ca15bd3df4d019b20f3883be1e1b9(z, n):
x = z + [0] * (37 - n)
l = [(i, 0) for i in x]
return l
def func_6499c14590c7478f99b70989a4f7b377(z, n):
x = z + [0] * (37 - n)
l = [(i, 0) for i in x]
return x
def func_ca64e693e0014d09853cbdda848d2d5d(z, n):
x = z + [0] * (37 - n)
l = [(i, 0) for i in x]
return i
def func_ef286deffdb84a2f9fd58c8e58ebd208(l):
heapq.heapify(l)
res = 0
return res
def func_513aa35af4484ebb9353269ecc25fe4f(infile):
b, n = map(int, infile.readline().split())
z = map(int, infile.readline().split())
x = z + [0] * (37 - n)
return n
def func_c0fac357a2884198936a35f553932d6a(infile):
b, n = map(int, infile.readline().split())
z = map(int, infile.readline().split())
x = z + [0] * (37 - n)
return b
def func_4e246a9e26824db485ef047518202af4(infile):
b, n = map(int, infile.readline().split())
z = map(int, infile.readline().split())
x = z + [0] * (37 - n)
return z
def func_a8fe9ac3f1f74b69be5bf9d00e464372(infile):
b, n = map(int, infile.readline().split())
z = map(int, infile.readline().split())
x = z + [0] * (37 - n)
return x
def func_846e4d0f741c4dec88a49d96937f3d2e(infile, n):
z = map(int, infile.readline().split())
x = z + [0] * (37 - n)
l = [(i, 0) for i in x]
return l
def func_a1498bca66074f3fb9e0fd68e6ac6c0c(infile, n):
z = map(int, infile.readline().split())
x = z + [0] * (37 - n)
l = [(i, 0) for i in x]
return x
def func_4a955493b0734e24913d60ec94f8bb23(infile, n):
z = map(int, infile.readline().split())
x = z + [0] * (37 - n)
l = [(i, 0) for i in x]
return z
def func_46b832fc0fe040b4acbb75dcaa82bf15(infile, n):
z = map(int, infile.readline().split())
x = z + [0] * (37 - n)
l = [(i, 0) for i in x]
return i
def func_16cbb72072e8462493a7a35d2911cc1b(z, n):
x = z + [0] * (37 - n)
l = [(i, 0) for i in x]
heapq.heapify(l)
return l
def func_f5551cf5dd854a1baee86044a3746662(z, n):
x = z + [0] * (37 - n)
l = [(i, 0) for i in x]
heapq.heapify(l)
return i
def func_a1c51c0ec3c04c43ba216f4af98d7475(z, n):
x = z + [0] * (37 - n)
l = [(i, 0) for i in x]
heapq.heapify(l)
return x
def func_dfa3019eb52d445399c442e3f8fd4ed0(infile):
b, n = map(int, infile.readline().split())
z = map(int, infile.readline().split())
x = z + [0] * (37 - n)
l = [(i, 0) for i in x]
return i
def func_5e9fc7bc8606492f9f0b80438539298e(infile):
b, n = map(int, infile.readline().split())
z = map(int, infile.readline().split())
x = z + [0] * (37 - n)
l = [(i, 0) for i in x]
return l
def func_758fc3c93949447ebbb9c0df9d5aa670(infile):
b, n = map(int, infile.readline().split())
z = map(int, infile.readline().split())
x = z + [0] * (37 - n)
l = [(i, 0) for i in x]
return z
def func_67ef7a33b60e414282c84637dda07d88(infile):
b, n = map(int, infile.readline().split())
z = map(int, infile.readline().split())
x = z + [0] * (37 - n)
l = [(i, 0) for i in x]
return b
def func_4b16ed7e60d640fe8c4f76608f603bcc(infile):
b, n = map(int, infile.readline().split())
z = map(int, infile.readline().split())
x = z + [0] * (37 - n)
l = [(i, 0) for i in x]
return x
def func_cdf13a8154044738a13782fa7872a05e(infile):
b, n = map(int, infile.readline().split())
z = map(int, infile.readline().split())
x = z + [0] * (37 - n)
l = [(i, 0) for i in x]
return n
def func_40d24e9e701c4c64a14879bacb773f48(infile, n):
z = map(int, infile.readline().split())
x = z + [0] * (37 - n)
l = [(i, 0) for i in x]
heapq.heapify(l)
return x
def func_9303783261ca4de3a144b9b6faaba6d6(infile, n):
z = map(int, infile.readline().split())
x = z + [0] * (37 - n)
l = [(i, 0) for i in x]
heapq.heapify(l)
return i
def func_e2b56637811040b1bfb17d47bb661816(infile, n):
z = map(int, infile.readline().split())
x = z + [0] * (37 - n)
l = [(i, 0) for i in x]
heapq.heapify(l)
return z
def func_37f8c7493ada4f41b2d7889eb3eee9f6(infile, n):
z = map(int, infile.readline().split())
x = z + [0] * (37 - n)
l = [(i, 0) for i in x]
heapq.heapify(l)
return l
def func_dba4a2ae57bc4513953aa37b388815e3(z, n):
x = z + [0] * (37 - n)
l = [(i, 0) for i in x]
heapq.heapify(l)
res = 0
return x
def func_dff16c4fb044427294d751951e816181(z, n):
x = z + [0] * (37 - n)
l = [(i, 0) for i in x]
heapq.heapify(l)
res = 0
return l
def func_286d77b2d6b541d1894c284d234b2428(z, n):
x = z + [0] * (37 - n)
l = [(i, 0) for i in x]
heapq.heapify(l)
res = 0
return res
def func_1fb1416b09524cfb9241d4fa95317878(z, n):
x = z + [0] * (37 - n)
l = [(i, 0) for i in x]
heapq.heapify(l)
res = 0
return i
def func_cc59bcdadd02402683f916f4f2fda74f(infile):
b, n = map(int, infile.readline().split())
z = map(int, infile.readline().split())
x = z + [0] * (37 - n)
l = [(i, 0) for i in x]
heapq.heapify(l)
return z
def func_ab81d2136c9541ada964679373ff3a42(infile):
b, n = map(int, infile.readline().split())
z = map(int, infile.readline().split())
x = z + [0] * (37 - n)
l = [(i, 0) for i in x]
heapq.heapify(l)
return l
def func_9a2e41a23ac2434d9ed0fdc2086702c6(infile):
b, n = map(int, infile.readline().split())
z = map(int, infile.readline().split())
x = z + [0] * (37 - n)
l = [(i, 0) for i in x]
heapq.heapify(l)
return i
def func_b48bc4b0f50c417bb3e0baebf2c72106(infile):
b, n = map(int, infile.readline().split())
z = map(int, infile.readline().split())
x = z + [0] * (37 - n)
l = [(i, 0) for i in x]
heapq.heapify(l)
return n
def func_62c12578310545f2ad9ba3ca1acb341a(infile):
b, n = map(int, infile.readline().split())
z = map(int, infile.readline().split())
x = z + [0] * (37 - n)
l = [(i, 0) for i in x]
heapq.heapify(l)
return b
def func_6c9bc0d9a9ce4dba914f4ed099e6ecff(infile):
b, n = map(int, infile.readline().split())
z = map(int, infile.readline().split())
x = z + [0] * (37 - n)
l = [(i, 0) for i in x]
heapq.heapify(l)
return x
def func_313d08cfc9be4eaf97aeec3b8eb7d1d5(infile, n):
z = map(int, infile.readline().split())
x = z + [0] * (37 - n)
l = [(i, 0) for i in x]
heapq.heapify(l)
res = 0
return z
def func_8d328e28693446c18d65a661e413d964(infile, n):
z = map(int, infile.readline().split())
x = z + [0] * (37 - n)
l = [(i, 0) for i in x]
heapq.heapify(l)
res = 0
return res
def func_c62afcca982d4b748a4d0da14950de08(infile, n):
z = map(int, infile.readline().split())
x = z + [0] * (37 - n)
l = [(i, 0) for i in x]
heapq.heapify(l)
res = 0
return i
def func_b039f7f9160f4a28a0c4b3b777d06025(infile, n):
z = map(int, infile.readline().split())
x = z + [0] * (37 - n)
l = [(i, 0) for i in x]
heapq.heapify(l)
res = 0
return x
def func_7dc5f7713749444ebd2f7782373ff614(infile, n):
z = map(int, infile.readline().split())
x = z + [0] * (37 - n)
l = [(i, 0) for i in x]
heapq.heapify(l)
res = 0
return l
def func_c21e608ccfd84a648038fbc2afb4db35(n, b):
x = z + [0] * (37 - n)
l = [(i, 0) for i in x]
heapq.heapify(l)
res = 0
for z in xrange(1, b + 1):
x = heapq.heappop(l)
x = x[0] + 1, x[1] + 1
heapq.heappush(l, x)
s = 10 ** 20
t = 0
u = 0
for x in l:
s = min(s, x[0])
for x in l:
if s == x[0]:
t += 1
u += x[1]
tmp = 36.0 * u / t - z
res = max(res, tmp)
return res
def func_2e89088f574c43b280e7a314372ae2d0(n, b):
x = z + [0] * (37 - n)
l = [(i, 0) for i in x]
heapq.heapify(l)
res = 0
for z in xrange(1, b + 1):
x = heapq.heappop(l)
x = x[0] + 1, x[1] + 1
heapq.heappush(l, x)
s = 10 ** 20
t = 0
u = 0
for x in l:
s = min(s, x[0])
for x in l:
if s == x[0]:
t += 1
u += x[1]
tmp = 36.0 * u / t - z
res = max(res, tmp)
return z
def func_8ec051e850db41059339b693115ba042(n, b):
x = z + [0] * (37 - n)
l = [(i, 0) for i in x]
heapq.heapify(l)
res = 0
for z in xrange(1, b + 1):
x = heapq.heappop(l)
x = x[0] + 1, x[1] + 1
heapq.heappush(l, x)
s = 10 ** 20
t = 0
u = 0
for x in l:
s = min(s, x[0])
for x in l:
if s == x[0]:
t += 1
u += x[1]
tmp = 36.0 * u / t - z
res = max(res, tmp)
return u
def func_4f9c92f3f72b4fd59e81e4b90b995f0b(n, b):
x = z + [0] * (37 - n)
l = [(i, 0) for i in x]
heapq.heapify(l)
res = 0
for z in xrange(1, b + 1):
x = heapq.heappop(l)
x = x[0] + 1, x[1] + 1
heapq.heappush(l, x)
s = 10 ** 20
t = 0
u = 0
for x in l:
s = min(s, x[0])
for x in l:
if s == x[0]:
t += 1
u += x[1]
tmp = 36.0 * u / t - z
res = max(res, tmp)
return x
def func_4465d3f5da9f46cfa7384772b6e088df(n, b):
x = z + [0] * (37 - n)
l = [(i, 0) for i in x]
heapq.heapify(l)
res = 0
for z in xrange(1, b + 1):
x = heapq.heappop(l)
x = x[0] + 1, x[1] + 1
heapq.heappush(l, x)
s = 10 ** 20
t = 0
u = 0
for x in l:
s = min(s, x[0])
for x in l:
if s == x[0]:
t += 1
u += x[1]
tmp = 36.0 * u / t - z
res = max(res, tmp)
return s
def func_b12c5de8836f47f9b720fcff13eca0b1(n, b):
x = z + [0] * (37 - n)
l = [(i, 0) for i in x]
heapq.heapify(l)
res = 0
for z in xrange(1, b + 1):
x = heapq.heappop(l)
x = x[0] + 1, x[1] + 1
heapq.heappush(l, x)
s = 10 ** 20
t = 0
u = 0
for x in l:
s = min(s, x[0])
for x in l:
if s == x[0]:
t += 1
u += x[1]
tmp = 36.0 * u / t - z
res = max(res, tmp)
return l
def func_e3ab4862ff8342a08149ea5d87c973e4(n, b):
x = z + [0] * (37 - n)
l = [(i, 0) for i in x]
heapq.heapify(l)
res = 0
for z in xrange(1, b + 1):
x = heapq.heappop(l)
x = x[0] + 1, x[1] + 1
heapq.heappush(l, x)
s = 10 ** 20
t = 0
u = 0
for x in l:
s = min(s, x[0])
for x in l:
if s == x[0]:
t += 1
u += x[1]
tmp = 36.0 * u / t - z
res = max(res, tmp)
return t
def func_922749db1624474bb41d563b30684375(n, b):
x = z + [0] * (37 - n)
l = [(i, 0) for i in x]
heapq.heapify(l)
res = 0
for z in xrange(1, b + 1):
x = heapq.heappop(l)
x = x[0] + 1, x[1] + 1
heapq.heappush(l, x)
s = 10 ** 20
t = 0
u = 0
for x in l:
s = min(s, x[0])
for x in l:
if s == x[0]:
t += 1
u += x[1]
tmp = 36.0 * u / t - z
res = max(res, tmp)
return i
def func_836fcb0a12f345efbc47b76aa6709610(n, b):
x = z + [0] * (37 - n)
l = [(i, 0) for i in x]
heapq.heapify(l)
res = 0
for z in xrange(1, b + 1):
x = heapq.heappop(l)
x = x[0] + 1, x[1] + 1
heapq.heappush(l, x)
s = 10 ** 20
t = 0
u = 0
for x in l:
s = min(s, x[0])
for x in l:
if s == x[0]:
t += 1
u += x[1]
tmp = 36.0 * u / t - z
res = max(res, tmp)
return tmp
def func_b8b6b27007894152adfbef68c4f17a6b(infile):
b, n = map(int, infile.readline().split())
z = map(int, infile.readline().split())
x = z + [0] * (37 - n)
l = [(i, 0) for i in x]
heapq.heapify(l)
res = 0
return res
def func_b8b539a1cd5c45ab937c5ac0e87cd0ad(infile):
b, n = map(int, infile.readline().split())
z = map(int, infile.readline().split())
x = z + [0] * (37 - n)
l = [(i, 0) for i in x]
heapq.heapify(l)
res = 0
return n
def func_c47db68760dc44288119faf538171172(infile):
b, n = map(int, infile.readline().split())
z = map(int, infile.readline().split())
x = z + [0] * (37 - n)
l = [(i, 0) for i in x]
heapq.heapify(l)
res = 0
return x
def func_6bd522bc90c140659c7a219f07858d50(infile):
b, n = map(int, infile.readline().split())
z = map(int, infile.readline().split())
x = z + [0] * (37 - n)
l = [(i, 0) for i in x]
heapq.heapify(l)
res = 0
return z
def func_2deec1814b0141078b292d1cdc14bbeb(infile):
b, n = map(int, infile.readline().split())
z = map(int, infile.readline().split())
x = z + [0] * (37 - n)
l = [(i, 0) for i in x]
heapq.heapify(l)
res = 0
return l
def func_93ddf64b81034c439bf7a1124fd0e71e(infile):
b, n = map(int, infile.readline().split())
z = map(int, infile.readline().split())
x = z + [0] * (37 - n)
l = [(i, 0) for i in x]
heapq.heapify(l)
res = 0
return i
def func_88ba79e8049d4c8e8dac4000cc52b5f8(infile):
b, n = map(int, infile.readline().split())
z = map(int, infile.readline().split())
x = z + [0] * (37 - n)
l = [(i, 0) for i in x]
heapq.heapify(l)
res = 0
return b
def func_178e4809b7c64c0890a84b7a29924bfb(infile, n, b):
z = map(int, infile.readline().split())
x = z + [0] * (37 - n)
l = [(i, 0) for i in x]
heapq.heapify(l)
res = 0
for z in xrange(1, b + 1):
x = heapq.heappop(l)
x = x[0] + 1, x[1] + 1
heapq.heappush(l, x)
s = 10 ** 20
t = 0
u = 0
for x in l:
s = min(s, x[0])
for x in l:
if s == x[0]:
t += 1
u += x[1]
tmp = 36.0 * u / t - z
res = max(res, tmp)
return l
def func_f4301ef7a7ba40a8a83538f7bda68ec5(infile, n, b):
z = map(int, infile.readline().split())
x = z + [0] * (37 - n)
l = [(i, 0) for i in x]
heapq.heapify(l)
res = 0
for z in xrange(1, b + 1):
x = heapq.heappop(l)
x = x[0] + 1, x[1] + 1
heapq.heappush(l, x)
s = 10 ** 20
t = 0
u = 0
for x in l:
s = min(s, x[0])
for x in l:
if s == x[0]:
t += 1
u += x[1]
tmp = 36.0 * u / t - z
res = max(res, tmp)
return i
def func_c8179b9696744dfea5acd6430e4d6c9d(infile, n, b):
z = map(int, infile.readline().split())
x = z + [0] * (37 - n)
l = [(i, 0) for i in x]
heapq.heapify(l)
res = 0
for z in xrange(1, b + 1):
x = heapq.heappop(l)
x = x[0] + 1, x[1] + 1
heapq.heappush(l, x)
s = 10 ** 20
t = 0
u = 0
for x in l:
s = min(s, x[0])
for x in l:
if s == x[0]:
t += 1
u += x[1]
tmp = 36.0 * u / t - z
res = max(res, tmp)
return res
def func_3f9c00676e5d40929a2c9d0ec61f508c(infile, n, b):
z = map(int, infile.readline().split())
x = z + [0] * (37 - n)
l = [(i, 0) for i in x]
heapq.heapify(l)
res = 0
for z in xrange(1, b + 1):
x = heapq.heappop(l)
x = x[0] + 1, x[1] + 1
heapq.heappush(l, x)
s = 10 ** 20
t = 0
u = 0
for x in l:
s = min(s, x[0])
for x in l:
if s == x[0]:
t += 1
u += x[1]
tmp = 36.0 * u / t - z
res = max(res, tmp)
return tmp
def func_d0d97418ac7e40e09b7e298bc19b7653(infile, n, b):
z = map(int, infile.readline().split())
x = z + [0] * (37 - n)
l = [(i, 0) for i in x]
heapq.heapify(l)
res = 0
for z in xrange(1, b + 1):
x = heapq.heappop(l)
x = x[0] + 1, x[1] + 1
heapq.heappush(l, x)
s = 10 ** 20
t = 0
u = 0
for x in l:
s = min(s, x[0])
for x in l:
if s == x[0]:
t += 1
u += x[1]
tmp = 36.0 * u / t - z
res = max(res, tmp)
return z
def func_e6904bac0d50436d838d405d9e315a07(infile, n, b):
z = map(int, infile.readline().split())
x = z + [0] * (37 - n)
l = [(i, 0) for i in x]
heapq.heapify(l)
res = 0
for z in xrange(1, b + 1):
x = heapq.heappop(l)
x = x[0] + 1, x[1] + 1
heapq.heappush(l, x)
s = 10 ** 20
t = 0
u = 0
for x in l:
s = min(s, x[0])
for x in l:
if s == x[0]:
t += 1
u += x[1]
tmp = 36.0 * u / t - z
res = max(res, tmp)
return u
def func_15b1a2e833c4488d9fbfba5eca0cf32e(infile, n, b):
z = map(int, infile.readline().split())
x = z + [0] * (37 - n)
l = [(i, 0) for i in x]
heapq.heapify(l)
res = 0
for z in xrange(1, b + 1):
x = heapq.heappop(l)
x = x[0] + 1, x[1] + 1
heapq.heappush(l, x)
s = 10 ** 20
t = 0
u = 0
for x in l:
s = min(s, x[0])
for x in l:
if s == x[0]:
t += 1
u += x[1]
tmp = 36.0 * u / t - z
res = max(res, tmp)
return t
def func_83e47c50029949e3a9b066744154849e(infile, n, b):
z = map(int, infile.readline().split())
x = z + [0] * (37 - n)
l = [(i, 0) for i in x]
heapq.heapify(l)
res = 0
for z in xrange(1, b + 1):
x = heapq.heappop(l)
x = x[0] + 1, x[1] + 1
heapq.heappush(l, x)
s = 10 ** 20
t = 0
u = 0
for x in l:
s = min(s, x[0])
for x in l:
if s == x[0]:
t += 1
u += x[1]
tmp = 36.0 * u / t - z
res = max(res, tmp)
return x
def func_e9ec6d7d759c4284ab6feb33bf1389b4(infile, n, b):
z = map(int, infile.readline().split())
x = z + [0] * (37 - n)
l = [(i, 0) for i in x]
heapq.heapify(l)
res = 0
for z in xrange(1, b + 1):
x = heapq.heappop(l)
x = x[0] + 1, x[1] + 1
heapq.heappush(l, x)
s = 10 ** 20
t = 0
u = 0
for x in l:
s = min(s, x[0])
for x in l:
if s == x[0]:
t += 1
u += x[1]
tmp = 36.0 * u / t - z
res = max(res, tmp)
return s
def func_f1d2246d870948b28479a6ae3e4ba1b5(n, b):
x = z + [0] * (37 - n)
l = [(i, 0) for i in x]
heapq.heapify(l)
res = 0
for z in xrange(1, b + 1):
x = heapq.heappop(l)
x = x[0] + 1, x[1] + 1
heapq.heappush(l, x)
s = 10 ** 20
t = 0
u = 0
for x in l:
s = min(s, x[0])
for x in l:
if s == x[0]:
t += 1
u += x[1]
tmp = 36.0 * u / t - z
res = max(res, tmp)
if s == x[0]:
t += 1
u += x[1]
return t
def func_841378c1517e4102990e4c17dc5b1101(n, b):
x = z + [0] * (37 - n)
l = [(i, 0) for i in x]
heapq.heapify(l)
res = 0
for z in xrange(1, b + 1):
x = heapq.heappop(l)
x = x[0] + 1, x[1] + 1
heapq.heappush(l, x)
s = 10 ** 20
t = 0
u = 0
for x in l:
s = min(s, x[0])
for x in l:
if s == x[0]:
t += 1
u += x[1]
tmp = 36.0 * u / t - z
res = max(res, tmp)
if s == x[0]:
t += 1
u += x[1]
return i
def func_b2a1eda53c17475c95fa1d626bc36014(n, b):
x = z + [0] * (37 - n)
l = [(i, 0) for i in x]
heapq.heapify(l)
res = 0
for z in xrange(1, b + 1):
x = heapq.heappop(l)
x = x[0] + 1, x[1] + 1
heapq.heappush(l, x)
s = 10 ** 20
t = 0
u = 0
for x in l:
s = min(s, x[0])
for x in l:
if s == x[0]:
t += 1
u += x[1]
tmp = 36.0 * u / t - z
res = max(res, tmp)
if s == x[0]:
t += 1
u += x[1]
return z
def func_9816c5607df2454e8ef717a2f2408eff(n, b):
x = z + [0] * (37 - n)
l = [(i, 0) for i in x]
heapq.heapify(l)
res = 0
for z in xrange(1, b + 1):
x = heapq.heappop(l)
x = x[0] + 1, x[1] + 1
heapq.heappush(l, x)
s = 10 ** 20
t = 0
u = 0
for x in l:
s = min(s, x[0])
for x in l:
if s == x[0]:
t += 1
u += x[1]
tmp = 36.0 * u / t - z
res = max(res, tmp)
if s == x[0]:
t += 1
u += x[1]
return l
def func_98f197257a904387a106d494beb01884(n, b):
x = z + [0] * (37 - n)
l = [(i, 0) for i in x]
heapq.heapify(l)
res = 0
for z in xrange(1, b + 1):
x = heapq.heappop(l)
x = x[0] + 1, x[1] + 1
heapq.heappush(l, x)
s = 10 ** 20
t = 0
u = 0
for x in l:
s = min(s, x[0])
for x in l:
if s == x[0]:
t += 1
u += x[1]
tmp = 36.0 * u / t - z
res = max(res, tmp)
if s == x[0]:
t += 1
u += x[1]
return s
def func_650dca48c0bd4a0ea1d9625582eda242(n, b):
x = z + [0] * (37 - n)
l = [(i, 0) for i in x]
heapq.heapify(l)
res = 0
for z in xrange(1, b + 1):
x = heapq.heappop(l)
x = x[0] + 1, x[1] + 1
heapq.heappush(l, x)
s = 10 ** 20
t = 0
u = 0
for x in l:
s = min(s, x[0])
for x in l:
if s == x[0]:
t += 1
u += x[1]
tmp = 36.0 * u / t - z
res = max(res, tmp)
if s == x[0]:
t += 1
u += x[1]
return res
def func_7fc914f49d7e4182b4be7bd19239bfcb(n, b):
x = z + [0] * (37 - n)
l = [(i, 0) for i in x]
heapq.heapify(l)
res = 0
for z in xrange(1, b + 1):
x = heapq.heappop(l)
x = x[0] + 1, x[1] + 1
heapq.heappush(l, x)
s = 10 ** 20
t = 0
u = 0
for x in l:
s = min(s, x[0])
for x in l:
if s == x[0]:
t += 1
u += x[1]
tmp = 36.0 * u / t - z
res = max(res, tmp)
if s == x[0]:
t += 1
u += x[1]
return x
def func_33fab4706ea14a8c84bfada0395ff675(n, b):
x = z + [0] * (37 - n)
l = [(i, 0) for i in x]
heapq.heapify(l)
res = 0
for z in xrange(1, b + 1):
x = heapq.heappop(l)
x = x[0] + 1, x[1] + 1
heapq.heappush(l, x)
s = 10 ** 20
t = 0
u = 0
for x in l:
s = min(s, x[0])
for x in l:
if s == x[0]:
t += 1
u += x[1]
tmp = 36.0 * u / t - z
res = max(res, tmp)
if s == x[0]:
t += 1
u += x[1]
return u
def func_bc41769fce974d73a11985f9dc3874de(infile):
b, n = map(int, infile.readline().split())
z = map(int, infile.readline().split())
x = z + [0] * (37 - n)
l = [(i, 0) for i in x]
heapq.heapify(l)
res = 0
for z in xrange(1, b + 1):
x = heapq.heappop(l)
x = x[0] + 1, x[1] + 1
heapq.heappush(l, x)
s = 10 ** 20
t = 0
u = 0
for x in l:
s = min(s, x[0])
for x in l:
if s == x[0]:
t += 1
u += x[1]
tmp = 36.0 * u / t - z
res = max(res, tmp)
return z
def func_dce5e4798bf24355b5c8cc61940fdd3a(infile):
b, n = map(int, infile.readline().split())
z = map(int, infile.readline().split())
x = z + [0] * (37 - n)
l = [(i, 0) for i in x]
heapq.heapify(l)
res = 0
for z in xrange(1, b + 1):
x = heapq.heappop(l)
x = x[0] + 1, x[1] + 1
heapq.heappush(l, x)
s = 10 ** 20
t = 0
u = 0
for x in l:
s = min(s, x[0])
for x in l:
if s == x[0]:
t += 1
u += x[1]
tmp = 36.0 * u / t - z
res = max(res, tmp)
return u
def func_dd25e470a47243159fb7380d409b2233(infile):
b, n = map(int, infile.readline().split())
z = map(int, infile.readline().split())
x = z + [0] * (37 - n)
l = [(i, 0) for i in x]
heapq.heapify(l)
res = 0
for z in xrange(1, b + 1):
x = heapq.heappop(l)
x = x[0] + 1, x[1] + 1
heapq.heappush(l, x)
s = 10 ** 20
t = 0
u = 0
for x in l:
s = min(s, x[0])
for x in l:
if s == x[0]:
t += 1
u += x[1]
tmp = 36.0 * u / t - z
res = max(res, tmp)
return x
def func_9fc166d8589f45bb95785eb4247ddee7(infile):
b, n = map(int, infile.readline().split())
z = map(int, infile.readline().split())
x = z + [0] * (37 - n)
l = [(i, 0) for i in x]
heapq.heapify(l)
res = 0
for z in xrange(1, b + 1):
x = heapq.heappop(l)
x = x[0] + 1, x[1] + 1
heapq.heappush(l, x)
s = 10 ** 20
t = 0
u = 0
for x in l:
s = min(s, x[0])
for x in l:
if s == x[0]:
t += 1
u += x[1]
tmp = 36.0 * u / t - z
res = max(res, tmp)
return s
def func_c75a9904a976463f917711b282553b35(infile):
b, n = map(int, infile.readline().split())
z = map(int, infile.readline().split())
x = z + [0] * (37 - n)
l = [(i, 0) for i in x]
heapq.heapify(l)
res = 0
for z in xrange(1, b + 1):
x = heapq.heappop(l)
x = x[0] + 1, x[1] + 1
heapq.heappush(l, x)
s = 10 ** 20
t = 0
u = 0
for x in l:
s = min(s, x[0])
for x in l:
if s == x[0]:
t += 1
u += x[1]
tmp = 36.0 * u / t - z
res = max(res, tmp)
return t
def func_6183adf82f494d2c932fa703cc3e85ab(infile):
b, n = map(int, infile.readline().split())
z = map(int, infile.readline().split())
x = z + [0] * (37 - n)
l = [(i, 0) for i in x]
heapq.heapify(l)
res = 0
for z in xrange(1, b + 1):
x = heapq.heappop(l)
x = x[0] + 1, x[1] + 1
heapq.heappush(l, x)
s = 10 ** 20
t = 0
u = 0
for x in l:
s = min(s, x[0])
for x in l:
if s == x[0]:
t += 1
u += x[1]
tmp = 36.0 * u / t - z
res = max(res, tmp)
return l
def func_c72a6755397f428b8423186914857d91(infile):
b, n = map(int, infile.readline().split())
z = map(int, infile.readline().split())
x = z + [0] * (37 - n)
l = [(i, 0) for i in x]
heapq.heapify(l)
res = 0
for z in xrange(1, b + 1):
x = heapq.heappop(l)
x = x[0] + 1, x[1] + 1
heapq.heappush(l, x)
s = 10 ** 20
t = 0
u = 0
for x in l:
s = min(s, x[0])
for x in l:
if s == x[0]:
t += 1
u += x[1]
tmp = 36.0 * u / t - z
res = max(res, tmp)
return i
def func_93f70b0a802b4101b2b5a10b16933330(infile):
b, n = map(int, infile.readline().split())
z = map(int, infile.readline().split())
x = z + [0] * (37 - n)
l = [(i, 0) for i in x]
heapq.heapify(l)
res = 0
for z in xrange(1, b + 1):
x = heapq.heappop(l)
x = x[0] + 1, x[1] + 1
heapq.heappush(l, x)
s = 10 ** 20
t = 0
u = 0
for x in l:
s = min(s, x[0])
for x in l:
if s == x[0]:
t += 1
u += x[1]
tmp = 36.0 * u / t - z
res = max(res, tmp)
return tmp
def func_851e2aed5f6c408aa54964580798066c(infile):
b, n = map(int, infile.readline().split())
z = map(int, infile.readline().split())
x = z + [0] * (37 - n)
l = [(i, 0) for i in x]
heapq.heapify(l)
res = 0
for z in xrange(1, b + 1):
x = heapq.heappop(l)
x = x[0] + 1, x[1] + 1
heapq.heappush(l, x)
s = 10 ** 20
t = 0
u = 0
for x in l:
s = min(s, x[0])
for x in l:
if s == x[0]:
t += 1
u += x[1]
tmp = 36.0 * u / t - z
res = max(res, tmp)
return n
def func_47d10a4393c542edb1c694d11760331e(infile):
b, n = map(int, infile.readline().split())
z = map(int, infile.readline().split())
x = z + [0] * (37 - n)
l = [(i, 0) for i in x]
heapq.heapify(l)
res = 0
for z in xrange(1, b + 1):
x = heapq.heappop(l)
x = x[0] + 1, x[1] + 1
heapq.heappush(l, x)
s = 10 ** 20
t = 0
u = 0
for x in l:
s = min(s, x[0])
for x in l:
if s == x[0]:
t += 1
u += x[1]
tmp = 36.0 * u / t - z
res = max(res, tmp)
return b
def func_2adb6853bdb248a8a1c5894549d5ebad(infile):
b, n = map(int, infile.readline().split())
z = map(int, infile.readline().split())
x = z + [0] * (37 - n)
l = [(i, 0) for i in x]
heapq.heapify(l)
res = 0
for z in xrange(1, b + 1):
x = heapq.heappop(l)
x = x[0] + 1, x[1] + 1
heapq.heappush(l, x)
s = 10 ** 20
t = 0
u = 0
for x in l:
s = min(s, x[0])
for x in l:
if s == x[0]:
t += 1
u += x[1]
tmp = 36.0 * u / t - z
res = max(res, tmp)
return res
def func_b1a656d05bf1422899fa5ae7e5c020bd(infile, n, b):
z = map(int, infile.readline().split())
x = z + [0] * (37 - n)
l = [(i, 0) for i in x]
heapq.heapify(l)
res = 0
for z in xrange(1, b + 1):
x = heapq.heappop(l)
x = x[0] + 1, x[1] + 1
heapq.heappush(l, x)
s = 10 ** 20
t = 0
u = 0
for x in l:
s = min(s, x[0])
for x in l:
if s == x[0]:
t += 1
u += x[1]
tmp = 36.0 * u / t - z
res = max(res, tmp)
if s == x[0]:
t += 1
u += x[1]
return res
def func_6cd03d7c762a4104b9a1d0cbb484a659(infile, n, b):
z = map(int, infile.readline().split())
x = z + [0] * (37 - n)
l = [(i, 0) for i in x]
heapq.heapify(l)
res = 0
for z in xrange(1, b + 1):
x = heapq.heappop(l)
x = x[0] + 1, x[1] + 1
heapq.heappush(l, x)
s = 10 ** 20
t = 0
u = 0
for x in l:
s = min(s, x[0])
for x in l:
if s == x[0]:
t += 1
u += x[1]
tmp = 36.0 * u / t - z
res = max(res, tmp)
if s == x[0]:
t += 1
u += x[1]
return u
def func_324e0d95271544da8e5a0bfdf31f8cee(infile, n, b):
z = map(int, infile.readline().split())
x = z + [0] * (37 - n)
l = [(i, 0) for i in x]
heapq.heapify(l)
res = 0
for z in xrange(1, b + 1):
x = heapq.heappop(l)
x = x[0] + 1, x[1] + 1
heapq.heappush(l, x)
s = 10 ** 20
t = 0
u = 0
for x in l:
s = min(s, x[0])
for x in l:
if s == x[0]:
t += 1
u += x[1]
tmp = 36.0 * u / t - z
res = max(res, tmp)
if s == x[0]:
t += 1
u += x[1]
return i
def func_4c68331ff464457a9f457cc229ec3854(infile, n, b):
z = map(int, infile.readline().split())
x = z + [0] * (37 - n)
l = [(i, 0) for i in x]
heapq.heapify(l)
res = 0
for z in xrange(1, b + 1):
x = heapq.heappop(l)
x = x[0] + 1, x[1] + 1
heapq.heappush(l, x)
s = 10 ** 20
t = 0
u = 0
for x in l:
s = min(s, x[0])
for x in l:
if s == x[0]:
t += 1
u += x[1]
tmp = 36.0 * u / t - z
res = max(res, tmp)
if s == x[0]:
t += 1
u += x[1]
return x
def func_db68df36271a41b792ce7b0863766cde(infile, n, b):
z = map(int, infile.readline().split())
x = z + [0] * (37 - n)
l = [(i, 0) for i in x]
heapq.heapify(l)
res = 0
for z in xrange(1, b + 1):
x = heapq.heappop(l)
x = x[0] + 1, x[1] + 1
heapq.heappush(l, x)
s = 10 ** 20
t = 0
u = 0
for x in l:
s = min(s, x[0])
for x in l:
if s == x[0]:
t += 1
u += x[1]
tmp = 36.0 * u / t - z
res = max(res, tmp)
if s == x[0]:
t += 1
u += x[1]
return l
def func_5dfd4939f1124416abc8736276d7ce1c(infile, n, b):
z = map(int, infile.readline().split())
x = z + [0] * (37 - n)
l = [(i, 0) for i in x]
heapq.heapify(l)
res = 0
for z in xrange(1, b + 1):
x = heapq.heappop(l)
x = x[0] + 1, x[1] + 1
heapq.heappush(l, x)
s = 10 ** 20
t = 0
u = 0
for x in l:
s = min(s, x[0])
for x in l:
if s == x[0]:
t += 1
u += x[1]
tmp = 36.0 * u / t - z
res = max(res, tmp)
if s == x[0]:
t += 1
u += x[1]
return s
def func_2fea06b919194dbc9493fa084192942c(infile, n, b):
z = map(int, infile.readline().split())
x = z + [0] * (37 - n)
l = [(i, 0) for i in x]
heapq.heapify(l)
res = 0
for z in xrange(1, b + 1):
x = heapq.heappop(l)
x = x[0] + 1, x[1] + 1
heapq.heappush(l, x)
s = 10 ** 20
t = 0
u = 0
for x in l:
s = min(s, x[0])
for x in l:
if s == x[0]:
t += 1
u += x[1]
tmp = 36.0 * u / t - z
res = max(res, tmp)
if s == x[0]:
t += 1
u += x[1]
return t
def func_913aa1e4b9e145378acca76d754f8617(infile, n, b):
z = map(int, infile.readline().split())
x = z + [0] * (37 - n)
l = [(i, 0) for i in x]
heapq.heapify(l)
res = 0
for z in xrange(1, b + 1):
x = heapq.heappop(l)
x = x[0] + 1, x[1] + 1
heapq.heappush(l, x)
s = 10 ** 20
t = 0
u = 0
for x in l:
s = min(s, x[0])
for x in l:
if s == x[0]:
t += 1
u += x[1]
tmp = 36.0 * u / t - z
res = max(res, tmp)
if s == x[0]:
t += 1
u += x[1]
return z
def func_1ceeee562ca64298942dee0ca1393fcc(n, b):
x = z + [0] * (37 - n)
l = [(i, 0) for i in x]
heapq.heapify(l)
res = 0
for z in xrange(1, b + 1):
x = heapq.heappop(l)
x = x[0] + 1, x[1] + 1
heapq.heappush(l, x)
s = 10 ** 20
t = 0
u = 0
for x in l:
s = min(s, x[0])
for x in l:
if s == x[0]:
t += 1
u += x[1]
tmp = 36.0 * u / t - z
res = max(res, tmp)
if s == x[0]:
t += 1
u += x[1]
return res
def func_6dc5887b32534c97a64bb02dd405879b(infile):
b, n = map(int, infile.readline().split())
z = map(int, infile.readline().split())
x = z + [0] * (37 - n)
l = [(i, 0) for i in x]
heapq.heapify(l)
res = 0
for z in xrange(1, b + 1):
x = heapq.heappop(l)
x = x[0] + 1, x[1] + 1
heapq.heappush(l, x)
s = 10 ** 20
t = 0
u = 0
for x in l:
s = min(s, x[0])
for x in l:
if s == x[0]:
t += 1
u += x[1]
tmp = 36.0 * u / t - z
res = max(res, tmp)
if s == x[0]:
t += 1
u += x[1]
return b
def func_8f8f9d9e17b649bc9d22f7f303df696b(infile):
b, n = map(int, infile.readline().split())
z = map(int, infile.readline().split())
x = z + [0] * (37 - n)
l = [(i, 0) for i in x]
heapq.heapify(l)
res = 0
for z in xrange(1, b + 1):
x = heapq.heappop(l)
x = x[0] + 1, x[1] + 1
heapq.heappush(l, x)
s = 10 ** 20
t = 0
u = 0
for x in l:
s = min(s, x[0])
for x in l:
if s == x[0]:
t += 1
u += x[1]
tmp = 36.0 * u / t - z
res = max(res, tmp)
if s == x[0]:
t += 1
u += x[1]
return z
def func_f567a28353e84c9299da92f69385317b(infile):
b, n = map(int, infile.readline().split())
z = map(int, infile.readline().split())
x = z + [0] * (37 - n)
l = [(i, 0) for i in x]
heapq.heapify(l)
res = 0
for z in xrange(1, b + 1):
x = heapq.heappop(l)
x = x[0] + 1, x[1] + 1
heapq.heappush(l, x)
s = 10 ** 20
t = 0
u = 0
for x in l:
s = min(s, x[0])
for x in l:
if s == x[0]:
t += 1
u += x[1]
tmp = 36.0 * u / t - z
res = max(res, tmp)
if s == x[0]:
t += 1
u += x[1]
return n
def func_5755e7280fa74637b6dfaaf3e265a1e4(infile):
b, n = map(int, infile.readline().split())
z = map(int, infile.readline().split())
x = z + [0] * (37 - n)
l = [(i, 0) for i in x]
heapq.heapify(l)
res = 0
for z in xrange(1, b + 1):
x = heapq.heappop(l)
x = x[0] + 1, x[1] + 1
heapq.heappush(l, x)
s = 10 ** 20
t = 0
u = 0
for x in l:
s = min(s, x[0])
for x in l:
if s == x[0]:
t += 1
u += x[1]
tmp = 36.0 * u / t - z
res = max(res, tmp)
if s == x[0]:
t += 1
u += x[1]
return t
def func_4607783431f44f9ba1d36b9cac0146b6(infile):
b, n = map(int, infile.readline().split())
z = map(int, infile.readline().split())
x = z + [0] * (37 - n)
l = [(i, 0) for i in x]
heapq.heapify(l)
res = 0
for z in xrange(1, b + 1):
x = heapq.heappop(l)
x = x[0] + 1, x[1] + 1
heapq.heappush(l, x)
s = 10 ** 20
t = 0
u = 0
for x in l:
s = min(s, x[0])
for x in l:
if s == x[0]:
t += 1
u += x[1]
tmp = 36.0 * u / t - z
res = max(res, tmp)
if s == x[0]:
t += 1
u += x[1]
return l
def func_b22f9d4d99ae46578491846cd3fd472f(infile):
b, n = map(int, infile.readline().split())
z = map(int, infile.readline().split())
x = z + [0] * (37 - n)
l = [(i, 0) for i in x]
heapq.heapify(l)
res = 0
for z in xrange(1, b + 1):
x = heapq.heappop(l)
x = x[0] + 1, x[1] + 1
heapq.heappush(l, x)
s = 10 ** 20
t = 0
u = 0
for x in l:
s = min(s, x[0])
for x in l:
if s == x[0]:
t += 1
u += x[1]
tmp = 36.0 * u / t - z
res = max(res, tmp)
if s == x[0]:
t += 1
u += x[1]
return u
def func_c255878aa78549e9b637e4c64dabb514(infile):
b, n = map(int, infile.readline().split())
z = map(int, infile.readline().split())
x = z + [0] * (37 - n)
l = [(i, 0) for i in x]
heapq.heapify(l)
res = 0
for z in xrange(1, b + 1):
x = heapq.heappop(l)
x = x[0] + 1, x[1] + 1
heapq.heappush(l, x)
s = 10 ** 20
t = 0
u = 0
for x in l:
s = min(s, x[0])
for x in l:
if s == x[0]:
t += 1
u += x[1]
tmp = 36.0 * u / t - z
res = max(res, tmp)
if s == x[0]:
t += 1
u += x[1]
return res
def func_e5904136de24499ba11de4960b835b06(infile):
b, n = map(int, infile.readline().split())
z = map(int, infile.readline().split())
x = z + [0] * (37 - n)
l = [(i, 0) for i in x]
heapq.heapify(l)
res = 0
for z in xrange(1, b + 1):
x = heapq.heappop(l)
x = x[0] + 1, x[1] + 1
heapq.heappush(l, x)
s = 10 ** 20
t = 0
u = 0
for x in l:
s = min(s, x[0])
for x in l:
if s == x[0]:
t += 1
u += x[1]
tmp = 36.0 * u / t - z
res = max(res, tmp)
if s == x[0]:
t += 1
u += x[1]
return x
def func_659edfa6181241f7b4b8ff420d2fc6b0(infile):
b, n = map(int, infile.readline().split())
z = map(int, infile.readline().split())
x = z + [0] * (37 - n)
l = [(i, 0) for i in x]
heapq.heapify(l)
res = 0
for z in xrange(1, b + 1):
x = heapq.heappop(l)
x = x[0] + 1, x[1] + 1
heapq.heappush(l, x)
s = 10 ** 20
t = 0
u = 0
for x in l:
s = min(s, x[0])
for x in l:
if s == x[0]:
t += 1
u += x[1]
tmp = 36.0 * u / t - z
res = max(res, tmp)
if s == x[0]:
t += 1
u += x[1]
return s
def func_3c24813e169141faaac7a71d99167087(infile):
b, n = map(int, infile.readline().split())
z = map(int, infile.readline().split())
x = z + [0] * (37 - n)
l = [(i, 0) for i in x]
heapq.heapify(l)
res = 0
for z in xrange(1, b + 1):
x = heapq.heappop(l)
x = x[0] + 1, x[1] + 1
heapq.heappush(l, x)
s = 10 ** 20
t = 0
u = 0
for x in l:
s = min(s, x[0])
for x in l:
if s == x[0]:
t += 1
u += x[1]
tmp = 36.0 * u / t - z
res = max(res, tmp)
if s == x[0]:
t += 1
u += x[1]
return i
def func_32a98e7c6fc6468aae304881ff26450a(infile, n, b):
z = map(int, infile.readline().split())
x = z + [0] * (37 - n)
l = [(i, 0) for i in x]
heapq.heapify(l)
res = 0
for z in xrange(1, b + 1):
x = heapq.heappop(l)
x = x[0] + 1, x[1] + 1
heapq.heappush(l, x)
s = 10 ** 20
t = 0
u = 0
for x in l:
s = min(s, x[0])
for x in l:
if s == x[0]:
t += 1
u += x[1]
tmp = 36.0 * u / t - z
res = max(res, tmp)
if s == x[0]:
t += 1
u += x[1]
return res
def func_2e1d8ac38a614e7d8459a3115719b910(infile):
b, n = map(int, infile.readline().split())
z = map(int, infile.readline().split())
x = z + [0] * (37 - n)
l = [(i, 0) for i in x]
heapq.heapify(l)
res = 0
for z in xrange(1, b + 1):
x = heapq.heappop(l)
x = x[0] + 1, x[1] + 1
heapq.heappush(l, x)
s = 10 ** 20
t = 0
u = 0
for x in l:
s = min(s, x[0])
for x in l:
if s == x[0]:
t += 1
u += x[1]
tmp = 36.0 * u / t - z
res = max(res, tmp)
if s == x[0]:
t += 1
u += x[1]
return res
def func_f47873d2daa14d1091750dbc6c23d410():
infile = open('codejam/test_files/Y13R5P1/A.in')
T = int(infile.readline())
return infile
def func_36019f34f30c43a19d40331ec896082f():
infile = open('codejam/test_files/Y13R5P1/A.in')
T = int(infile.readline())
return T
def func_a3eebf053c094f40951af958ecdeadfe(infile):
T = int(infile.readline())
for i in xrange(T):
print 'Case #%d: %.12f' % (i + 1, solve(infile))
return i
def func_60062a43fa7c4256b54d5b72c2f75a53(infile):
T = int(infile.readline())
for i in xrange(T):
print 'Case #%d: %.12f' % (i + 1, solve(infile))
return T
def func_253a67cd62f84258a4f1801fc8acc83b(infile, T):
for i in xrange(T):
print 'Case #%d: %.12f' % (i + 1, solve(infile))
infile.close()
return i
def func_1ac07eeddafc4545a52ad097f70fb81d():
infile = open('codejam/test_files/Y13R5P1/A.in')
T = int(infile.readline())
for i in xrange(T):
print 'Case #%d: %.12f' % (i + 1, solve(infile))
return infile
def func_c71975c65ef04faa8edb981019564788():
infile = open('codejam/test_files/Y13R5P1/A.in')
T = int(infile.readline())
for i in xrange(T):
print 'Case #%d: %.12f' % (i + 1, solve(infile))
return T
def func_972dcb40b5e64baebedba293d452d022():
infile = open('codejam/test_files/Y13R5P1/A.in')
T = int(infile.readline())
for i in xrange(T):
print 'Case #%d: %.12f' % (i + 1, solve(infile))
return i
def func_0c1d2f177a9c413789ab26a268f9293a(infile):
T = int(infile.readline())
for i in xrange(T):
print 'Case #%d: %.12f' % (i + 1, solve(infile))
infile.close()
return i
def func_0feada7e3f0f4f8da84e85022f516ab2(infile):
T = int(infile.readline())
for i in xrange(T):
print 'Case #%d: %.12f' % (i + 1, solve(infile))
infile.close()
return T
def func_4757c0f628774f04a979111594899c55():
infile = open('codejam/test_files/Y13R5P1/A.in')
T = int(infile.readline())
for i in xrange(T):
print 'Case #%d: %.12f' % (i + 1, solve(infile))
infile.close()
return i
def func_67d706887c53425eb48a2d3dba77d5c8():
infile = open('codejam/test_files/Y13R5P1/A.in')
T = int(infile.readline())
for i in xrange(T):
print 'Case #%d: %.12f' % (i + 1, solve(infile))
infile.close()
return T
def func_e9bfa71f0a34449ea31064a4e3d4d38c():
infile = open('codejam/test_files/Y13R5P1/A.in')
T = int(infile.readline())
for i in xrange(T):
print 'Case #%d: %.12f' % (i + 1, solve(infile))
infile.close()
return infile
| 23.50219 | 86 | 0.442284 | 7,472 | 48,297 | 2.84007 | 0.025964 | 0.051647 | 0.020499 | 0.121578 | 0.787569 | 0.786438 | 0.785213 | 0.785213 | 0.780642 | 0.779087 | 0 | 0.156781 | 0.403069 | 48,297 | 2,054 | 87 | 23.513632 | 0.579292 | 0 | 0 | 0.924623 | 0 | 0 | 0.009939 | 0.006522 | 0 | 0 | 0 | 0 | 0 | 0 | null | null | 0 | 0.001117 | null | null | 0.006142 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 1 | 1 | 1 | 1 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 7 |
8891b4ae92c741489ab522bb6a12de2ff74ca04d | 8,347 | py | Python | checklisten/migrations/0001_initial.py | mribrgr/StuRa-Mitgliederdatenbank | 87a261d66c279ff86056e315b05e6966b79df9fa | [
"MIT"
] | 8 | 2019-11-26T13:34:46.000Z | 2021-06-21T13:41:57.000Z | src/checklisten/migrations/0001_initial.py | Sumarbrander/Stura-Mitgliederdatenbank | 691dbd33683b2c2d408efe7a3eb28e083ebcd62a | [
"MIT"
] | 93 | 2019-12-16T09:29:10.000Z | 2021-04-24T12:03:33.000Z | src/checklisten/migrations/0001_initial.py | Sumarbrander/Stura-Mitgliederdatenbank | 691dbd33683b2c2d408efe7a3eb28e083ebcd62a | [
"MIT"
] | 2 | 2020-12-03T12:43:19.000Z | 2020-12-22T21:48:47.000Z | # Generated by Django 3.0.8 on 2020-08-13 15:51
from django.conf import settings
from django.db import migrations, models
import django.db.models.deletion
import simple_history.models
class Migration(migrations.Migration):
initial = True
dependencies = [
migrations.swappable_dependency(settings.AUTH_USER_MODEL),
('mitglieder', '0001_initial'),
('aemter', '0001_initial'),
]
operations = [
migrations.CreateModel(
name='Aufgabe',
fields=[
('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
('bezeichnung', models.CharField(max_length=50)),
],
options={
'verbose_name': 'Aufgabe',
'verbose_name_plural': 'Aufgaben',
},
),
migrations.CreateModel(
name='Checkliste',
fields=[
('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
('amt', models.ForeignKey(null=True, on_delete=django.db.models.deletion.CASCADE, to='mitglieder.MitgliedAmt')),
('mitglied', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to='mitglieder.Mitglied')),
],
options={
'verbose_name': 'Checkliste',
'verbose_name_plural': 'Checklisten',
},
),
migrations.CreateModel(
name='HistoricalChecklisteRecht',
fields=[
('id', models.IntegerField(auto_created=True, blank=True, db_index=True, verbose_name='ID')),
('abgehakt', models.BooleanField(default=False)),
('history_id', models.AutoField(primary_key=True, serialize=False)),
('history_date', models.DateTimeField()),
('history_change_reason', models.CharField(max_length=100, null=True)),
('history_type', models.CharField(choices=[('+', 'Created'), ('~', 'Changed'), ('-', 'Deleted')], max_length=1)),
('checkliste', models.ForeignKey(blank=True, db_constraint=False, null=True, on_delete=django.db.models.deletion.DO_NOTHING, related_name='+', to='checklisten.Checkliste')),
('history_user', models.ForeignKey(null=True, on_delete=django.db.models.deletion.SET_NULL, related_name='+', to=settings.AUTH_USER_MODEL)),
('recht', models.ForeignKey(blank=True, db_constraint=False, null=True, on_delete=django.db.models.deletion.DO_NOTHING, related_name='+', to='aemter.Recht')),
],
options={
'verbose_name': 'historical Zuordnung Checkliste-Recht',
'ordering': ('-history_date', '-history_id'),
'get_latest_by': 'history_date',
},
bases=(simple_history.models.HistoricalChanges, models.Model),
),
migrations.CreateModel(
name='HistoricalChecklisteAufgabe',
fields=[
('id', models.IntegerField(auto_created=True, blank=True, db_index=True, verbose_name='ID')),
('abgehakt', models.BooleanField(default=False)),
('history_id', models.AutoField(primary_key=True, serialize=False)),
('history_date', models.DateTimeField()),
('history_change_reason', models.CharField(max_length=100, null=True)),
('history_type', models.CharField(choices=[('+', 'Created'), ('~', 'Changed'), ('-', 'Deleted')], max_length=1)),
('aufgabe', models.ForeignKey(blank=True, db_constraint=False, null=True, on_delete=django.db.models.deletion.DO_NOTHING, related_name='+', to='checklisten.Aufgabe')),
('checkliste', models.ForeignKey(blank=True, db_constraint=False, null=True, on_delete=django.db.models.deletion.DO_NOTHING, related_name='+', to='checklisten.Checkliste')),
('history_user', models.ForeignKey(null=True, on_delete=django.db.models.deletion.SET_NULL, related_name='+', to=settings.AUTH_USER_MODEL)),
],
options={
'verbose_name': 'historical Zuordnung Checkliste-Aufgabe',
'ordering': ('-history_date', '-history_id'),
'get_latest_by': 'history_date',
},
bases=(simple_history.models.HistoricalChanges, models.Model),
),
migrations.CreateModel(
name='HistoricalCheckliste',
fields=[
('id', models.IntegerField(auto_created=True, blank=True, db_index=True, verbose_name='ID')),
('history_id', models.AutoField(primary_key=True, serialize=False)),
('history_date', models.DateTimeField()),
('history_change_reason', models.CharField(max_length=100, null=True)),
('history_type', models.CharField(choices=[('+', 'Created'), ('~', 'Changed'), ('-', 'Deleted')], max_length=1)),
('amt', models.ForeignKey(blank=True, db_constraint=False, null=True, on_delete=django.db.models.deletion.DO_NOTHING, related_name='+', to='mitglieder.MitgliedAmt')),
('history_user', models.ForeignKey(null=True, on_delete=django.db.models.deletion.SET_NULL, related_name='+', to=settings.AUTH_USER_MODEL)),
('mitglied', models.ForeignKey(blank=True, db_constraint=False, null=True, on_delete=django.db.models.deletion.DO_NOTHING, related_name='+', to='mitglieder.Mitglied')),
],
options={
'verbose_name': 'historical Checkliste',
'ordering': ('-history_date', '-history_id'),
'get_latest_by': 'history_date',
},
bases=(simple_history.models.HistoricalChanges, models.Model),
),
migrations.CreateModel(
name='HistoricalAufgabe',
fields=[
('id', models.IntegerField(auto_created=True, blank=True, db_index=True, verbose_name='ID')),
('bezeichnung', models.CharField(max_length=50)),
('history_id', models.AutoField(primary_key=True, serialize=False)),
('history_date', models.DateTimeField()),
('history_change_reason', models.CharField(max_length=100, null=True)),
('history_type', models.CharField(choices=[('+', 'Created'), ('~', 'Changed'), ('-', 'Deleted')], max_length=1)),
('history_user', models.ForeignKey(null=True, on_delete=django.db.models.deletion.SET_NULL, related_name='+', to=settings.AUTH_USER_MODEL)),
],
options={
'verbose_name': 'historical Aufgabe',
'ordering': ('-history_date', '-history_id'),
'get_latest_by': 'history_date',
},
bases=(simple_history.models.HistoricalChanges, models.Model),
),
migrations.CreateModel(
name='ChecklisteRecht',
fields=[
('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
('abgehakt', models.BooleanField(default=False)),
('checkliste', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to='checklisten.Checkliste')),
('recht', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to='aemter.Recht')),
],
options={
'verbose_name': 'Zuordnung Checkliste-Recht',
'verbose_name_plural': 'Zuordnungen Checkliste-Recht',
},
),
migrations.CreateModel(
name='ChecklisteAufgabe',
fields=[
('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
('abgehakt', models.BooleanField(default=False)),
('aufgabe', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to='checklisten.Aufgabe')),
('checkliste', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to='checklisten.Checkliste')),
],
options={
'verbose_name': 'Zuordnung Checkliste-Aufgabe',
'verbose_name_plural': 'Zuordnungen Checkliste-Aufgabe',
},
),
]
| 56.782313 | 189 | 0.597101 | 807 | 8,347 | 5.980173 | 0.127633 | 0.045586 | 0.049316 | 0.077497 | 0.845421 | 0.818069 | 0.782429 | 0.782429 | 0.782429 | 0.761086 | 0 | 0.006901 | 0.253504 | 8,347 | 146 | 190 | 57.171233 | 0.767614 | 0.005391 | 0 | 0.647482 | 1 | 0 | 0.19506 | 0.032289 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | false | 0 | 0.028777 | 0 | 0.057554 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 1 | 1 | 1 | 1 | 1 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 7 |
ee39353134f29b568d9b45c569b92afe9500c1c9 | 8,903 | py | Python | rsl_comm_py/examples/example_shearwater_spi.py | RedshiftLabsPtyLtd/rsl_comm_py | e53b4e85079898c894dac25842a08bcc303edfbb | [
"MIT"
] | null | null | null | rsl_comm_py/examples/example_shearwater_spi.py | RedshiftLabsPtyLtd/rsl_comm_py | e53b4e85079898c894dac25842a08bcc303edfbb | [
"MIT"
] | null | null | null | rsl_comm_py/examples/example_shearwater_spi.py | RedshiftLabsPtyLtd/rsl_comm_py | e53b4e85079898c894dac25842a08bcc303edfbb | [
"MIT"
] | null | null | null | #!/usr/bin/env python3
# Author: Dr. Konstantin Selyunin
# License: MIT
# Date: 31 March 2021
import logging
import sys
from pathlib import Path
from rsl_comm_py.shearwater_serial import ShearWaterSerial
from rsl_comm_py.shearwater_spi import ShearWaterSpiUsbIss
if __name__ == '__main__':
logging.basicConfig(
level=logging.WARNING,
format='[%(asctime)s.%(msecs)03d] [%(levelname)-8s]: %(message)s',
datefmt='%Y-%m-%d %H:%M:%S',
handlers=[
logging.FileHandler(f'{Path(__file__).stem}.log', mode='w'),
logging.StreamHandler(sys.stdout),
])
script_dir = Path(__file__).parent
device_file = script_dir.parent / "rsl_A500CNHD.json"
shearwater_spi = ShearWaterSpiUsbIss(port='/dev/ttyACM0')
shearwater_serial = ShearWaterSerial(device=device_file)
print(f"\n========== DATA REGISTERS ===================================")
for _ in range(100):
print(f"dreg_mag_1_raw_x_spi : {shearwater_spi.dreg_mag_1_raw_x[0].raw_value}")
print(f"dreg_mag_1_raw_x_serial : {shearwater_serial.dreg_mag_1_raw_x[0].raw_value}")
print(f"dreg_mag_1_raw_y_spi : {shearwater_spi.dreg_mag_1_raw_y[0].raw_value}")
print(f"dreg_mag_1_raw_y_serial : {shearwater_serial.dreg_mag_1_raw_y[0].raw_value}")
print(f"dreg_mag_1_raw_z_spi : {shearwater_spi.dreg_mag_1_raw_z[0].raw_value}")
print(f"dreg_mag_1_raw_z_serial : {shearwater_serial.dreg_mag_1_raw_z[0].raw_value}")
print(f"dreg_mag_1_raw_time_spi : {shearwater_spi.dreg_mag_1_raw_time[0].raw_value}")
print(f"dreg_mag_1_raw_time_serial : {shearwater_serial.dreg_mag_1_raw_time[0].raw_value}")
print(f"dreg_mag_2_raw_xy_spi : {shearwater_spi.dreg_mag_2_raw_xy[0].raw_value}")
print(f"dreg_mag_2_raw_xy_serial : {shearwater_serial.dreg_mag_2_raw_xy[0].raw_value}")
print(f"dreg_mag_2_raw_z_spi : {shearwater_spi.dreg_mag_2_raw_z[0].raw_value}")
print(f"dreg_mag_2_raw_z_serial : {shearwater_serial.dreg_mag_2_raw_z[0].raw_value}")
print(f"dreg_mag_2_raw_time_spi : {shearwater_spi.dreg_mag_2_raw_time[0].raw_value}")
print(f"dreg_mag_2_raw_time_serial : {shearwater_serial.dreg_mag_2_raw_time[0].raw_value}")
print(f"dreg_temperature_spi : {shearwater_spi.dreg_temperature[0].raw_value}")
print(f"dreg_temperature_serial : {shearwater_serial.dreg_temperature[0].raw_value}")
print(f"dreg_temperature_time_spi : {shearwater_spi.dreg_temperature_time[0].raw_value}")
print(f"dreg_temperature_time_serial : {shearwater_serial.dreg_temperature_time[0].raw_value}")
print(f"dreg_gyro_1_proc_x_spi : {shearwater_spi.dreg_gyro_1_proc_x[0].raw_value}")
print(f"dreg_gyro_1_proc_x_serial : {shearwater_serial.dreg_gyro_1_proc_x[0].raw_value}")
print(f"dreg_gyro_1_proc_y_spi : {shearwater_spi.dreg_gyro_1_proc_y[0].raw_value}")
print(f"dreg_gyro_1_proc_y_serial : {shearwater_serial.dreg_gyro_1_proc_y[0].raw_value}")
print(f"dreg_gyro_1_proc_z_spi : {shearwater_spi.dreg_gyro_1_proc_z[0].raw_value}")
print(f"dreg_gyro_1_proc_z_serial : {shearwater_serial.dreg_gyro_1_proc_z[0].raw_value}")
print(f"dreg_gyro_1_proc_time_spi : {shearwater_spi.dreg_gyro_1_proc_time[0].raw_value}")
print(f"dreg_gyro_1_proc_time_serial : {shearwater_serial.dreg_gyro_1_proc_time[0].raw_value}")
print(f"dreg_gyro_2_proc_x_spi : {shearwater_spi.dreg_gyro_2_proc_x[0].raw_value}")
print(f"dreg_gyro_2_proc_x_serial : {shearwater_serial.dreg_gyro_2_proc_x[0].raw_value}")
print(f"dreg_gyro_2_proc_y_spi : {shearwater_spi.dreg_gyro_2_proc_y[0].raw_value}")
print(f"dreg_gyro_2_proc_y_serial : {shearwater_serial.dreg_gyro_2_proc_y[0].raw_value}")
print(f"dreg_gyro_2_proc_z_spi : {shearwater_spi.dreg_gyro_2_proc_z[0].raw_value}")
print(f"dreg_gyro_2_proc_z_serial : {shearwater_serial.dreg_gyro_2_proc_z[0].raw_value}")
print(f"dreg_gyro_2_proc_time_spi : {shearwater_spi.dreg_gyro_2_proc_time[0].raw_value}")
print(f"dreg_gyro_2_proc_time_serial : {shearwater_serial.dreg_gyro_2_proc_time[0].raw_value}")
print(f"dreg_accel_1_proc_x_spi : {shearwater_spi.dreg_accel_1_proc_x[0].raw_value}")
print(f"dreg_accel_1_proc_x_serial : {shearwater_serial.dreg_accel_1_proc_x[0].raw_value}")
print(f"dreg_accel_1_proc_y_spi : {shearwater_spi.dreg_accel_1_proc_y[0].raw_value}")
print(f"dreg_accel_1_proc_y_serial : {shearwater_serial.dreg_accel_1_proc_y[0].raw_value}")
print(f"dreg_accel_1_proc_z_spi : {shearwater_spi.dreg_accel_1_proc_z[0].raw_value}")
print(f"dreg_accel_1_proc_z_serial : {shearwater_serial.dreg_accel_1_proc_z[0].raw_value}")
print(f"dreg_accel_1_proc_time_spi : {shearwater_spi.dreg_accel_1_proc_time[0].raw_value}")
print(f"dreg_accel_1_proc_time_serial : {shearwater_serial.dreg_accel_1_proc_time[0].raw_value}")
print(f"dreg_mag_1_proc_x_spi : {shearwater_spi.dreg_mag_1_proc_x[0].raw_value}")
print(f"dreg_mag_1_proc_x_serial : {shearwater_serial.dreg_mag_1_proc_x[0].raw_value}")
print(f"dreg_mag_1_proc_y_spi : {shearwater_spi.dreg_mag_1_proc_y[0].raw_value}")
print(f"dreg_mag_1_proc_y_serial : {shearwater_serial.dreg_mag_1_proc_y[0].raw_value}")
print(f"dreg_mag_1_proc_z_spi : {shearwater_spi.dreg_mag_1_proc_z[0].raw_value}")
print(f"dreg_mag_1_proc_z_serial : {shearwater_serial.dreg_mag_1_proc_z[0].raw_value}")
print(f"dreg_mag_1_norm_spi : {shearwater_spi.dreg_mag_1_norm[0].raw_value}")
print(f"dreg_mag_1_norm_serial : {shearwater_serial.dreg_mag_1_norm[0].raw_value}")
print(f"dreg_mag_1_proc_time_spi : {shearwater_spi.dreg_mag_1_proc_time[0].raw_value}")
print(f"dreg_mag_1_proc_time_serial : {shearwater_serial.dreg_mag_1_proc_time[0].raw_value}")
print(f"dreg_mag_2_proc_x_spi : {shearwater_spi.dreg_mag_2_proc_x[0].raw_value}")
print(f"dreg_mag_2_proc_x_serial : {shearwater_serial.dreg_mag_2_proc_x[0].raw_value}")
print(f"dreg_mag_2_proc_y_spi : {shearwater_spi.dreg_mag_2_proc_y[0].raw_value}")
print(f"dreg_mag_2_proc_y_serial : {shearwater_serial.dreg_mag_2_proc_y[0].raw_value}")
print(f"dreg_mag_2_proc_z_spi : {shearwater_spi.dreg_mag_2_proc_z[0].raw_value}")
print(f"dreg_mag_2_proc_z_serial : {shearwater_serial.dreg_mag_2_proc_z[0].raw_value}")
print(f"dreg_mag_2_norm_spi : {shearwater_spi.dreg_mag_2_norm[0].raw_value}")
print(f"dreg_mag_2_norm_serial : {shearwater_serial.dreg_mag_2_norm[0].raw_value}")
print(f"dreg_mag_2_proc_time_spi : {shearwater_spi.dreg_mag_2_proc_time[0].raw_value}")
print(f"dreg_mag_2_proc_time_serial : {shearwater_serial.dreg_mag_2_proc_time[0].raw_value}")
print(f"dreg_quat_ab_spi : {shearwater_spi.dreg_quat_ab[0].raw_value}")
print(f"dreg_quat_ab_serial : {shearwater_serial.dreg_quat_ab[0].raw_value}")
print(f"dreg_quat_cd_spi : {shearwater_spi.dreg_quat_cd[0].raw_value}")
print(f"dreg_quat_cd_serial : {shearwater_serial.dreg_quat_cd[0].raw_value}")
print(f"dreg_quat_time_spi : {shearwater_spi.dreg_quat_time[0].raw_value}")
print(f"dreg_quat_time_serial : {shearwater_serial.dreg_quat_time[0].raw_value}")
print(f"dreg_euler_phi_theta_spi : {shearwater_spi.dreg_euler_phi_theta[0].raw_value}")
print(f"dreg_euler_phi_theta_serial : {shearwater_serial.dreg_euler_phi_theta[0].raw_value}")
print(f"dreg_euler_psi_spi : {shearwater_spi.dreg_euler_psi[0].raw_value}")
print(f"dreg_euler_psi_serial : {shearwater_serial.dreg_euler_psi[0].raw_value}")
print(f"dreg_euler_phi_theta_dot_spi : {shearwater_spi.dreg_euler_phi_theta_dot[0].raw_value}")
print(f"dreg_euler_phi_theta_dot_serial : {shearwater_serial.dreg_euler_phi_theta_dot[0].raw_value}")
print(f"dreg_euler_psi_dot_spi : {shearwater_spi.dreg_euler_psi_dot[0].raw_value}")
print(f"dreg_euler_psi_dot_serial : {shearwater_serial.dreg_euler_psi_dot[0].raw_value}")
print(f"dreg_euler_time_spi : {shearwater_spi.dreg_euler_time[0].raw_value}")
print(f"dreg_euler_time_serial : {shearwater_serial.dreg_euler_time[0].raw_value}")
| 80.207207 | 109 | 0.700775 | 1,438 | 8,903 | 3.773992 | 0.06815 | 0.087341 | 0.143726 | 0.198636 | 0.901787 | 0.851299 | 0.817579 | 0.611019 | 0.59333 | 0.548738 | 0 | 0.029071 | 0.184769 | 8,903 | 110 | 110 | 80.936364 | 0.718655 | 0.00966 | 0 | 0 | 0 | 0 | 0.758171 | 0.618702 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | false | 0 | 0.05102 | 0 | 0.05102 | 0.806122 | 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 | 1 | 1 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 7 |
c9ac9ee78b7b125e8b53c10a1b6ece9d4eab90fc | 226 | py | Python | novainstrumentation/tests/__init__.py | novabiosignals/novainstrumentation | 02d29983f970077613143db66d8df2bce59f8714 | [
"MIT"
] | 7 | 2018-11-07T14:40:13.000Z | 2019-11-03T20:38:52.000Z | biosignalsnotebooks/build/lib/biosignalsnotebooks/external_packages/novainstrumentation/tests/__init__.py | csavur/biosignalsnotebooks | c99596741a854c58bdefb429906023ac48ddc3b7 | [
"MIT"
] | null | null | null | biosignalsnotebooks/build/lib/biosignalsnotebooks/external_packages/novainstrumentation/tests/__init__.py | csavur/biosignalsnotebooks | c99596741a854c58bdefb429906023ac48ddc3b7 | [
"MIT"
] | 1 | 2019-06-02T07:50:41.000Z | 2019-06-02T07:50:41.000Z | from novainstrumentation.test_filter import *
from novainstrumentation.test_peaks import *
from novainstrumentation.test_smooth import *
from novainstrumentation.test_tools import *
from novainstrumentation.test_waves import * | 45.2 | 45 | 0.871681 | 25 | 226 | 7.68 | 0.36 | 0.598958 | 0.703125 | 0.6875 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0.084071 | 226 | 5 | 46 | 45.2 | 0.927536 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | true | 0 | 1 | 0 | 1 | 0 | 1 | 0 | 0 | null | 1 | 1 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 1 | 0 | 1 | 0 | 0 | 8 |
c9d45e003a7faa5e387390fd0f4fc642b04d8e0d | 885 | py | Python | python/src/tests/t_init_in_advance.py | atrsoftgmbh/atrshmlog | 4ca1a2cc6ff26890a02d74db378e597353f197d3 | [
"Apache-2.0"
] | null | null | null | python/src/tests/t_init_in_advance.py | atrsoftgmbh/atrshmlog | 4ca1a2cc6ff26890a02d74db378e597353f197d3 | [
"Apache-2.0"
] | null | null | null | python/src/tests/t_init_in_advance.py | atrsoftgmbh/atrshmlog | 4ca1a2cc6ff26890a02d74db378e597353f197d3 | [
"Apache-2.0"
] | null | null | null | #!/usr/bin/python3
#
# Id:
#
# We test a bit of the atrshmlog here.
#
# This is for the first starter, so only the basic things.
import sys
import atrshmlog
result = atrshmlog.attach()
f = atrshmlog.get_init_buffers_in_advance()
print('init in advance : ' + str(f) + ' : ')
old = atrshmlog.set_init_buffers_in_advance_on()
print('init in advance : ' + str(old) + ' : ')
f = atrshmlog.get_init_buffers_in_advance()
print('init in advance : ' + str(f) + ' : ')
old = atrshmlog.set_init_buffers_in_advance_off()
print('init in advance : ' + str(old) + ' : ')
f = atrshmlog.get_init_buffers_in_advance()
print('init in advance : ' + str(f) + ' : ')
old = atrshmlog.set_init_buffers_in_advance_on()
print('init in advance : ' + str(old) + ' : ')
f = atrshmlog.get_init_buffers_in_advance()
print('init in advance : ' + str(f) + ' : ')
print (' ')
exit(0)
# end of test
| 18.061224 | 58 | 0.662147 | 130 | 885 | 4.269231 | 0.307692 | 0.227027 | 0.163964 | 0.252252 | 0.722523 | 0.722523 | 0.722523 | 0.722523 | 0.722523 | 0.722523 | 0 | 0.002762 | 0.181921 | 885 | 48 | 59 | 18.4375 | 0.763812 | 0.143503 | 0 | 0.684211 | 0 | 0 | 0.197597 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | false | 0 | 0.105263 | 0 | 0.105263 | 0.421053 | 0 | 0 | 0 | null | 1 | 0 | 1 | 0 | 1 | 1 | 1 | 1 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 8 |
4eb91de41e7a6ecb5986ccc1fa53e08ec3ea2c6c | 180 | py | Python | bookwyrm/connectors/__init__.py | daveross/bookwyrm | d3251f511c184ae6b94b191b33919849c81ef2c2 | [
"CC0-1.0"
] | null | null | null | bookwyrm/connectors/__init__.py | daveross/bookwyrm | d3251f511c184ae6b94b191b33919849c81ef2c2 | [
"CC0-1.0"
] | null | null | null | bookwyrm/connectors/__init__.py | daveross/bookwyrm | d3251f511c184ae6b94b191b33919849c81ef2c2 | [
"CC0-1.0"
] | null | null | null | ''' bring connectors into the namespace '''
from .settings import CONNECTORS
from .abstract_connector import ConnectorException
from .abstract_connector import get_data, get_image
| 36 | 51 | 0.833333 | 22 | 180 | 6.636364 | 0.636364 | 0.164384 | 0.287671 | 0.369863 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0.111111 | 180 | 4 | 52 | 45 | 0.9125 | 0.194444 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | true | 0 | 1 | 0 | 1 | 0 | 1 | 0 | 0 | null | 0 | 1 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 1 | 0 | 1 | 0 | 0 | 7 |
4ebb365210ebefe01b944a8358787900a551dbaf | 23,641 | py | Python | Plant_Disease_Detection.py | Mehmetzahitangi/Plant_Disease_Detection | b6a007c4ad89ba4e8d2894dab47d1b2065f6a47d | [
"MIT"
] | null | null | null | Plant_Disease_Detection.py | Mehmetzahitangi/Plant_Disease_Detection | b6a007c4ad89ba4e8d2894dab47d1b2065f6a47d | [
"MIT"
] | null | null | null | Plant_Disease_Detection.py | Mehmetzahitangi/Plant_Disease_Detection | b6a007c4ad89ba4e8d2894dab47d1b2065f6a47d | [
"MIT"
] | null | null | null | # -*- coding: utf-8 -*-
"""SonDenemeler.ipynb
Automatically generated by Colaboratory.
Original file is located at
https://colab.research.google.com/drive/19x1FeWR8BZ3sWyZqbRuUR8msEuL1RXzm
"""
from google.colab import drive
drive.mount("/content/drive")
"""# Model 1"""
from __future__ import print_function
import numpy as np # For numerical fast numerical calculations
import matplotlib.pyplot as plt # For making plots
import pandas as pd # Deals with data
import seaborn as sns # Makes beautiful plots
import keras
import sys
from pandas import pandas as pd
#from sklearn.preprocessing import CategoricalEncoder as ce #import category_encoders as ce
import datetime
from keras.models import Sequential
from keras.layers import Dense, Dropout
from keras.optimizers import RMSprop
from sklearn.model_selection import train_test_split
from sklearn.svm import SVC
import os
import glob
import numpy as np
import scipy as sp
import pandas as pd
# skimage
from skimage.io import imshow, imread, imsave
from skimage.transform import rotate, AffineTransform, warp,rescale, resize, downscale_local_mean
from skimage import color,data
from skimage.exposure import adjust_gamma
from skimage.util import random_noise
# imgaug
import imageio
import imgaug as ia
import imgaug.augmenters as iaa
# Albumentations
import albumentations as A
# Keras
from keras.preprocessing.image import ImageDataGenerator,array_to_img, img_to_array, load_img
#visualisation
import matplotlib.pyplot as plt
import matplotlib.image as mpimg
#%matplotlib inline
import seaborn as sns
from IPython.display import HTML, Image
import cv2
import os
import matplotlib.ticker as ticker
import matplotlib.pyplot as plt
import seaborn as sns
# load data
#p_train=pd.read_csv('/content/drive/MyDrive/Plant_Pathology_2020/train.csv')
#p_test=pd.read_csv('/content/drive/MyDrive/Plant_Pathology_2020/test.csv')
import numpy as np # For numerical fast numerical calculations
#import matplotlib.pyplot as plt # For making plots
import pandas as pd # Deals with data
#import seaborn as sns # Makes beautiful plots
import keras
#import sys
#from pandas import pandas as pd
#from sklearn.preprocessing import CategoricalEncoder as ce #import category_encoders as ce
#import datetime
from keras.models import Sequential
#from keras.layers import Dense, Dropout
from keras.optimizers import RMSprop
from sklearn.model_selection import train_test_split
from keras.layers import Conv2D, MaxPooling2D, AveragePooling2D
from keras.layers import Dense, Activation, Dropout, Flatten
from keras.preprocessing import image
#from keras.preprocessing.image import ImageDataGenerator
import keras.optimizers
from tensorflow.python.keras.optimizer_v2.adam import Adam
#from sklearn.svm import SVC
import os
import glob
#import numpy as np
#import scipy as sp
#import pandas as pd
# skimage
from skimage.io import imshow, imread, imsave
#from skimage.transform import rotate, AffineTransform, warp,rescale, resize, downscale_local_mean
#from skimage import color,data
#from skimage.exposure import adjust_gamma
#from skimage.util import random_noise
# imgaug
#import imageio
#import imgaug as ia
#import imgaug.augmenters as iaa
# Albumentations
#import albumentations as A
# Keras
from keras.preprocessing.image import ImageDataGenerator,array_to_img, img_to_array, load_img
#visualisation
import matplotlib.pyplot as plt
#import matplotlib.image as mpimg
#%matplotlib inline
#import seaborn as sns
#from IPython.display import HTML, Image
import cv2
p_train=pd.read_csv('/content/drive/MyDrive/Plant_Pathology_2020/train.csv')
p_test=pd.read_csv('/content/drive/MyDrive/Plant_Pathology_2020/test.csv')
target = p_train[['healthy', 'multiple_diseases', 'rust', 'scab']]
test_ids = p_test['image_id']
img_size=224
# Direkt görüntüleri listeye aktarmış oluyoruz
train_image=[]
for name in p_train['image_id']:
path='/content/drive/MyDrive/Plant_Pathology_2020/images/'+name+'.jpg'
img=cv2.imread(path)
image=cv2.resize(img,(img_size,img_size),interpolation=cv2.INTER_AREA)
train_image.append(image)
fig, ax = plt.subplots(1, 4, figsize=(15, 15))
for i in range(4):
ax[i].set_axis_off()
ax[i].imshow(train_image[i])
test_image=[]
for name in p_test['image_id']:
path='/content/drive/MyDrive/Plant_Pathology_2020/test_images/'+name+'.jpg'
img=cv2.imread(path)
image=cv2.resize(img,(img_size,img_size),interpolation=cv2.INTER_AREA)
test_image.append(image)
fig, ax = plt.subplots(1, 4, figsize=(15, 15))
for i in range(4):
ax[i].set_axis_off()
ax[i].imshow(test_image[i])
#sorted_data.to_csv ('/content/drive/MyDrive/Plant_Pathology_2020/merge_data.csv', index = False, header=True)
#csv_pandas = pd.DataFrame(train_image)
#csv_pandas.to_csv ('/content/drive/MyDrive/Plant_Pathology_2020/train_image.csv', index = False, header=True)
#csv_pandas = pd.DataFrame(test_image)
#csv_pandas.to_csv ('/content/drive/MyDrive/Plant_Pathology_2020/test_image.csv', index = False, header=True)
print(train_image[0].shape)
print(type(train_image[0]))
a = np.array(train_image)
print(a.shape)
#YAPMA
#from keras.preprocessing.image import img_to_array
#x_train = np.ndarray(shape=(len(train_image), img_size, img_size, 3),dtype = np.float32)
#i=0
#for image in train_image:
# x_train[i]=img_to_array(image)
# x_train[i]=train_image[i]
# i=i+1
#x_train=x_train/255
#print('Train Shape: {}'.format(x_train.shape))
#YAPMA
#Burada ise görüntüleri arraylere çeviriyoruz
#from keras.preprocessing.image import img_to_array
#x_train = np.ndarray(shape=(len(train_image), img_size, img_size, 3),dtype = np.float32)
#i=0
#for image in train_image:
# x_train[i]=img_to_array(image)
# x_train[i]=train_image[i]
# i=i+1
#x_train=x_train/255
#print('Train Shape: {}'.format(x_train.shape))######
#x_test = np.ndarray(shape=(len(test_image), img_size, img_size, 3),dtype = np.float32)
#i=0
#for image in test_image:
# x_test[i]=img_to_array(image)
# x_test[i]=test_image[i]
# i=i+1
#x_test=x_test/255
#print('Test Shape: {}'.format(x_test.shape))
#listeden arraye dönüştürüyoruz
#x_train = np.ndarray(train_image) # bu şekilde olmuyor
#x_test = np.ndarray(test_image)
x_train = np.ndarray(shape=(len(train_image), img_size, img_size, 3),dtype = np.float32)
i=0
for image in train_image:
x_train[i]=img_to_array(image)
x_train[i]=train_image[i]
i=i+1
x_train=x_train/255 # scale
print('Train Shape: {}'.format(x_train.shape))
x_train[0]
x_test = np.ndarray(shape=(len(test_image), img_size, img_size, 3),dtype = np.float32)
i=0
for image in test_image:
x_test[i]=img_to_array(image)
x_test[i]=test_image[i]
i=i+1
x_test=x_test/255 # scale
print('Test Shape: {}'.format(x_test.shape))
x_test[0]
y = p_train.copy()
del y['image_id'] # image_id kolonunu sildik
y.head()
y_train = np.array(y.values)
print(y_train.shape,y_train[0])
from sklearn.model_selection import train_test_split
x_train, x_val, y_train, y_val = train_test_split(x_train, y_train, test_size=0.2, random_state=42)
x_train.shape, x_val.shape, y_train.shape, y_val.shape
#YAPMA
#from imblearn.over_sampling import SMOTE
#sm = SMOTE(random_state = 115)
#a_train, b_train = sm.fit_resample(x_train.reshape((-1, img_size * img_size * 3)), y_train)
#a_train = a_train.reshape((-1, img_size, img_size, 3))
#x_train.shape, y_train.sum(axis=0)
#a_train.shape, b_train.shape
#a_train[0].shape
from keras.callbacks import ReduceLROnPlateau
from keras.callbacks import EarlyStopping
LR_reduce=ReduceLROnPlateau(monitor='val_accuracy',
factor=.5,
patience=10,
min_lr=.000001,
verbose=1)
ES_monitor=EarlyStopping(monitor='val_loss',
patience=20)
#reg = .0005
#import keras
#from keras.models import Sequential
#from keras.layers import Conv2D, MaxPooling2D, AveragePooling2D,Conv3D
#from keras.layers import Dense, Activation, Dropout, Flatten
#from keras.preprocessing import image
#from keras.preprocessing.image import ImageDataGenerator
#import keras.optimizers
#from tensorflow.python.keras.optimizer_v2.adam import Adam
#%%
#------------------------------
#Evrişimli Sinir Ağı Mimarisini Oluşturma
model2 = Sequential()
#1. evrişim katmanı
model2.add(Conv2D(128, (5, 5), activation='LeakyReLU', input_shape=(224,224,3)))
model2.add(MaxPooling2D(pool_size=(5,5), strides=(2, 2)))
#64den 128
#2. Evrişim katmanı
model2.add(Conv2D(256, (3, 3), activation='LeakyReLU')) #128 den 256
model2.add(Conv2D(256, (3, 3), activation='LeakyReLU'))
#model.add(AveragePooling2D(pool_size=(3,3), strides=(2, 2)))
model2.add(MaxPooling2D(pool_size=(3,3), strides=(2, 2)))
#3. Evrişim katmanı
model2.add(Conv2D(512, (3, 3), activation='LeakyReLU')) #256 dan 512
model2.add(Conv2D(512, (3, 3), activation='LeakyReLU'))
#model.add(AveragePooling2D(pool_size=(3,3), strides=(2, 2)))
model2.add(MaxPooling2D(pool_size=(3,3), strides=(2, 2)))
model2.add(Flatten())
# Tam bağlantı katmanı
model2.add(Dense(1024, activation='LeakyReLU'))
#model2.add(Dropout(0.1))
model2.add(Dense(1024, activation='LeakyReLU'))
#model2.add(Dropout(0.1))
model2.add(Dense(1, activation='softmax')) #model.add(Dense(num_classes, activation='softmax'))
#------------------------------
model2.summary()
#------------------------------
opt = keras.optimizers.Adam(learning_rate=0.3)
#adam = Adam() #tf.keras.optimizers.Adam(learning_rate=0.1)
model2.compile(optimizer='rmsprop',
loss='categorical_crossentropy',
metrics=['accuracy']
)
#------------------------------
#Batch (Küme) işlemleri
#gen = ImageDataGenerator()
#train_generator = gen.flow(X_train, y_train)#, batch_size=batch_size)
"""ImageDataGenerator, Keras'ın derin öğrenme için görüntü verilerinin ardışık düzenlenmesi için başvurduğu sınıftır.
Yerel dosya sisteminize kolay erişim ve farklı yapılardan veri yüklemek için birden fazla farklı yöntem sağlar.
Ayrıca oldukça güçlü veri ön işleme ve artırma yeteneklerine sahiptir"""
datagen = ImageDataGenerator(rotation_range=45,
shear_range=0.25,
zoom_range=0.25,
width_shift_range=0.25,
height_shift_range=0.25,
rescale=1/255,
brightness_range=[0.5,1.5],
horizontal_flip=True,
vertical_flip=True,
fill_mode='nearest'
# featurewise_center=True,
# samplewise_center=True,
# featurewise_std_normalization=True,
# samplewise_std_normalization=True,
# zca_whitening=True
)
from keras.callbacks import ModelCheckpoint
root = '/content/drive/MyDrive/Plant_Pathology_2020/'
# en başarılı ağırlıkları kaydet
checkpointer = ModelCheckpoint(filepath=root + 'data/face_model.h5', verbose=1, save_best_only=True)
history = model2.fit_generator(datagen.flow(x_train, y_train, batch_size=24), # train verileri için veri artırma
epochs=300,
steps_per_epoch=x_train.shape[0] // 24,
verbose=1,
callbacks=[ES_monitor,LR_reduce],
validation_data=datagen.flow(x_val, y_val,batch_size=24), # validation verileri için veri artırma
validation_steps=x_val.shape[0]//24
)
x_train[0]
x_test[0]
# save model to json
model_json = model2.to_json()
with open(root + "data/face_model.json", "w") as json_file:
json_file.write(model_json)
from matplotlib import pyplot as plt
h = history.history
offset = 5
epochs = range(offset, len(h['loss']))
plt.figure(1, figsize=(20, 6))
plt.subplot(121)
plt.xlabel('epochs')
plt.ylabel('loss')
plt.plot(epochs, h['loss'][offset:], label='train')
plt.plot(epochs, h['val_loss'][offset:], label='val')
plt.legend()
plt.subplot(122)
plt.xlabel('epochs')
plt.ylabel('accuracy')
plt.plot(h[f'accuracy'], label='train')
plt.plot(h[f'val_accuracy'], label='val')
plt.legend()
plt.show()
from sklearn.metrics import roc_auc_score
pred_test = model2.predict(x_val)
roc_sum = 0
for i in range(4):
score = roc_auc_score(y_val[:, i], pred_test[:, i])
roc_sum += score
print(f'{score:.3f}')
roc_sum /= 4
print(f'totally:{roc_sum:.3f}')
pred = model2.predict(x_test)
res = pd.DataFrame()
res['image_id'] = test_ids
res['healthy'] = pred[:, 0]
res['multiple_diseases'] = pred[:, 1]
res['rust'] = pred[:, 2]
res['scab'] = pred[:, 3]
res.to_csv('Mysubmission.csv', index=False)
res.head(10)
# en iyi ağırlıkları yükle
model2.load_weights(root + 'data/face_model.h5')
"""# MODEL 2"""
from keras.callbacks import ReduceLROnPlateau
from keras.callbacks import EarlyStopping
LR_reduce=ReduceLROnPlateau(monitor='val_accuracy',
factor=.5,
patience=10,
min_lr=.000001,
verbose=1)
ES_monitor=EarlyStopping(monitor='val_loss',
patience=20)
#import keras
#from keras.models import Sequential
#from keras.layers import Conv2D, MaxPooling2D, AveragePooling2D,Conv3D
#from keras.layers import Dense, Activation, Dropout, Flatten
#from keras.preprocessing import image
#from keras.preprocessing.image import ImageDataGenerator
#import keras.optimizers
#from tensorflow.python.keras.optimizer_v2.adam import Adam
#%%
#------------------------------
#Evrişimli Sinir Ağı Mimarisini Oluşturma
model3 = Sequential()
#1. evrişim katmanı
model3.add(Conv2D(128, (5, 5), activation='ReLU', input_shape=(224,224,3)))
model3.add(MaxPooling2D(pool_size=(5,5), strides=(2, 2)))
#64den 128
#2. Evrişim katmanı
model3.add(Conv2D(256, (3, 3), activation='ReLU')) #128 den 256
model3.add(Conv2D(256, (3, 3), activation='ReLU'))
#model.add(AveragePooling2D(pool_size=(3,3), strides=(2, 2)))
model3.add(MaxPooling2D(pool_size=(3,3), strides=(2, 2)))
#3. Evrişim katmanı
model3.add(Conv2D(512, (3, 3), activation='ReLU')) #256 dan 512
model3.add(Conv2D(512, (3, 3), activation='ReLU'))
#model.add(AveragePooling2D(pool_size=(3,3), strides=(2, 2)))
model3.add(MaxPooling2D(pool_size=(3,3), strides=(2, 2)))
model3.add(Flatten())
# Tam bağlantı katmanı
model3.add(Dense(1024, activation='ReLU'))
model3.add(Dropout(0.25))
model3.add(Dense(1024, activation='ReLU'))
model3.add(Dropout(0.25))
model3.add(Dense(1, activation='softmax')) #model.add(Dense(num_classes, activation='softmax'))
#------------------------------
model3.summary()
#------------------------------
#opt = keras.optimizers.Adam(learning_rate=0.3)
#adam = Adam() #tf.keras.optimizers.Adam(learning_rate=0.1)
model3.compile(optimizer='rmsprop',
loss='categorical_crossentropy',
metrics=['accuracy']
)
#------------------------------
"""ImageDataGenerator, Keras'ın derin öğrenme için görüntü verilerinin ardışık düzenlenmesi için başvurduğu sınıftır.
Yerel dosya sisteminize kolay erişim ve farklı yapılardan veri yüklemek için birden fazla farklı yöntem sağlar.
Ayrıca oldukça güçlü veri ön işleme ve artırma yeteneklerine sahiptir"""
datagen = ImageDataGenerator(rotation_range=45,
shear_range=0.25,
zoom_range=0.25,
width_shift_range=0.25,
height_shift_range=0.25,
rescale=1/255,
brightness_range=[0.5,1.5],
horizontal_flip=True,
vertical_flip=True,
fill_mode='nearest'
# featurewise_center=True,
# samplewise_center=True,
# featurewise_std_normalization=True,
# samplewise_std_normalization=True,
# zca_whitening=True
)
from keras.callbacks import ModelCheckpoint
root = '/content/drive/MyDrive/Plant_Pathology_2020/'
# en başarılı ağırlıkları kaydet
checkpointer = ModelCheckpoint(filepath=root + 'plant_model.h5', verbose=1, save_best_only=True)
history = model3.fit_generator(datagen.flow(x_train, y_train, batch_size=24), # train verileri için veri artırma
epochs=300,
steps_per_epoch=x_train.shape[0] // 24,
verbose=1,
callbacks=[ES_monitor,LR_reduce],
validation_data=datagen.flow(x_val, y_val,batch_size=24), # validation verileri için veri artırma
validation_steps=x_val.shape[0]//24
)
# save model to json
model_json = model3.to_json()
with open(root + "plant_model.json", "w") as json_file:
json_file.write(model_json)
x_train[0]
x_test[0]
from matplotlib import pyplot as plt
h = history.history
offset = 5
epochs = range(offset, len(h['loss']))
plt.figure(1, figsize=(20, 6))
plt.subplot(121)
plt.xlabel('epochs')
plt.ylabel('loss')
plt.plot(epochs, h['loss'][offset:], label='train')
plt.plot(epochs, h['val_loss'][offset:], label='val')
plt.legend()
plt.subplot(122)
plt.xlabel('epochs')
plt.ylabel('accuracy')
plt.plot(h[f'accuracy'], label='train')
plt.plot(h[f'val_accuracy'], label='val')
plt.legend()
plt.show()
from sklearn.metrics import roc_auc_score
print("ROC-AUC SCORE")
pred_test = model3.predict(x_val)
roc_sum = 0
for i in range(4):
score = roc_auc_score(y_val[:, i], pred_test[:, i])
roc_sum += score
print(f'{score:.3f}')
roc_sum /= 4
print(f'totally:{roc_sum:.3f}')
pred = model3.predict(x_test)
res = pd.DataFrame()
res['image_id'] = test_ids
res['healthy'] = pred[:, 0]
res['multiple_diseases'] = pred[:, 1]
res['rust'] = pred[:, 2]
res['scab'] = pred[:, 3]
res.to_csv('Mysubmission2.csv', index=False)
res.head(10)
"""# MODEL 1 TEKRAR"""
from keras.callbacks import ReduceLROnPlateau
from keras.callbacks import EarlyStopping
LR_reduce=ReduceLROnPlateau(monitor='val_accuracy',
factor=.5,
patience=10,
min_lr=.000001,
verbose=1)
ES_monitor=EarlyStopping(monitor='val_loss',
patience=20)
#reg = .0005
#import keras
#from keras.models import Sequential
#from keras.layers import Conv2D, MaxPooling2D, AveragePooling2D,Conv3D
#from keras.layers import Dense, Activation, Dropout, Flatten
#from keras.preprocessing import image
#from keras.preprocessing.image import ImageDataGenerator
#import keras.optimizers
#from tensorflow.python.keras.optimizer_v2.adam import Adam
#%%
#------------------------------
#Evrişimli Sinir Ağı Mimarisini Oluşturma
model2_2 = Sequential()
#1. evrişim katmanı
model2_2.add(Conv2D(128, (5, 5), activation='LeakyReLU', input_shape=(224,224,3)))
model2_2.add(MaxPooling2D(pool_size=(5,5), strides=(2, 2)))
#64den 128
#2. Evrişim katmanı
model2_2.add(Conv2D(256, (3, 3), activation='LeakyReLU')) #128 den 256
model2_2.add(Conv2D(256, (3, 3), activation='LeakyReLU'))
#model.add(AveragePooling2D(pool_size=(3,3), strides=(2, 2)))
model2_2.add(MaxPooling2D(pool_size=(3,3), strides=(2, 2)))
#3. Evrişim katmanı
model2_2.add(Conv2D(512, (3, 3), activation='LeakyReLU')) #256 dan 512
model2_2.add(Conv2D(512, (3, 3), activation='LeakyReLU'))
#model.add(AveragePooling2D(pool_size=(3,3), strides=(2, 2)))
model2_2.add(MaxPooling2D(pool_size=(3,3), strides=(2, 2)))
model2_2.add(Flatten())
# Tam bağlantı katmanı
model2_2.add(Dense(1024, activation='LeakyReLU'))
#model2.add(Dropout(0.1))
model2_2.add(Dense(1024, activation='LeakyReLU'))
#model2.add(Dropout(0.1))
model2_2.add(Dense(1, activation='softmax')) #model.add(Dense(num_classes, activation='softmax'))
#------------------------------
model2_2.summary()
#------------------------------
#opt = keras.optimizers.Adam(learning_rate=0.3)
#adam = Adam() #tf.keras.optimizers.Adam(learning_rate=0.1)
model2_2.compile(optimizer='rmsprop',
loss='categorical_crossentropy',
metrics=['accuracy']
)
#------------------------------
"""ImageDataGenerator, Keras'ın derin öğrenme için görüntü verilerinin ardışık düzenlenmesi için başvurduğu sınıftır.
Yerel dosya sisteminize kolay erişim ve farklı yapılardan veri yüklemek için birden fazla farklı yöntem sağlar.
Ayrıca oldukça güçlü veri ön işleme ve artırma yeteneklerine sahiptir"""
datagen = ImageDataGenerator(rotation_range=45,
shear_range=0.25,
zoom_range=0.25,
width_shift_range=0.25,
height_shift_range=0.25,
rescale=1/255,
brightness_range=[0.5,1.5],
horizontal_flip=True,
vertical_flip=True,
fill_mode='nearest'
# featurewise_center=True,
# samplewise_center=True,
# featurewise_std_normalization=True,
# samplewise_std_normalization=True,
# zca_whitening=True
)
from keras.callbacks import ModelCheckpoint
root = '/content/drive/MyDrive/Plant_Pathology_2020/'
# en başarılı ağırlıkları kaydet
checkpointer = ModelCheckpoint(filepath=root + 'data/plant_model2.h5', verbose=1, save_best_only=True)
history = model2_2.fit_generator(datagen.flow(x_train, y_train, batch_size=24), # train verileri için veri artırma
epochs=300,
steps_per_epoch=x_train.shape[0] // 24,
verbose=1,
callbacks=[ES_monitor,LR_reduce],
validation_data=datagen.flow(x_val, y_val,batch_size=24), # validation verileri için veri artırma
validation_steps=x_val.shape[0]//24
)
# save model to json
model_json = model2_2.to_json()
with open(root + "data/plant_model2.json", "w") as json_file:
json_file.write(model_json)
x_train[0]
x_test[0]
from matplotlib import pyplot as plt
h = history.history
offset = 5
epochs = range(offset, len(h['loss']))
plt.figure(1, figsize=(20, 6))
plt.subplot(121)
plt.xlabel('epochs')
plt.ylabel('loss')
plt.plot(epochs, h['loss'][offset:], label='train')
plt.plot(epochs, h['val_loss'][offset:], label='val')
plt.legend()
plt.subplot(122)
plt.xlabel('epochs')
plt.ylabel('accuracy')
plt.plot(h[f'accuracy'], label='train')
plt.plot(h[f'val_accuracy'], label='val')
plt.legend()
plt.show()
from sklearn.metrics import roc_auc_score
pred_test = model2_2.predict(x_val)
roc_sum = 0
for i in range(4):
score = roc_auc_score(y_val[:, i], pred_test[:, i])
roc_sum += score
print(f'{score:.3f}')
roc_sum /= 4
print(f'totally:{roc_sum:.3f}')
pred = model2_2.predict(x_test)
res = pd.DataFrame()
res['image_id'] = test_ids
res['healthy'] = pred[:, 0]
res['multiple_diseases'] = pred[:, 1]
res['rust'] = pred[:, 2]
res['scab'] = pred[:, 3]
res.to_csv('Mysubmission3.csv', index=False)
res.head(10)
| 30.742523 | 127 | 0.667104 | 3,206 | 23,641 | 4.767623 | 0.123206 | 0.022375 | 0.008832 | 0.018842 | 0.913445 | 0.898266 | 0.879621 | 0.868106 | 0.844946 | 0.824076 | 0 | 0.04098 | 0.196946 | 23,641 | 768 | 128 | 30.782552 | 0.76413 | 0.314792 | 0 | 0.697674 | 1 | 0 | 0.097974 | 0.033391 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | false | 0 | 0.186047 | 0 | 0.186047 | 0.036176 | 0 | 0 | 0 | null | 0 | 0 | 0 | 1 | 1 | 1 | 1 | 1 | 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 | 7 |
14da09930456b312ce0606c0dbf7849f29401233 | 4,841 | py | Python | new_important_engine.py | prakharrathi25/Sentiment-Extraction-using-Bert | 89d50e57f6e73812930654ec636f1219e7ecb334 | [
"MIT"
] | 3 | 2020-12-12T07:40:47.000Z | 2021-11-28T17:08:38.000Z | new_important_engine.py | prakharrathi25/Sentiment-Extraction-using-Bert | 89d50e57f6e73812930654ec636f1219e7ecb334 | [
"MIT"
] | 4 | 2021-06-08T21:50:32.000Z | 2022-03-12T00:36:47.000Z | new_important_engine.py | prakharrathi25/Sentiment-Extraction-using-Bert | 89d50e57f6e73812930654ec636f1219e7ecb334 | [
"MIT"
] | 1 | 2020-09-30T19:42:31.000Z | 2020-09-30T19:42:31.000Z | import utils
import torch
from tqdm import tqdm
import torch.nn as nn
import numpy as np
def loss_fn(o1,o2,t1,t2):
l = nn.CrossEntropyLoss()
loss_s = l(o1,t1)
loss_e = l(o2,t2)
return loss_s+loss_e
def train_fn(data_loader,model,optimizer,device,scheduler):
model.train()
losses = utils.AverageMeter()
jaccard = utils.AverageMeter()
tk0 = tqdm(data_loader,total = len(data_loader))
for bi,d in enumerate(tk0):
ids = d['ids']
offsets = d['offsets']
orig_tweet = d['orig_tweet']
orig_selected = d['orig_selected_text']
token_type_ids = d['token_type_ids']
sentiments = d['orig_sentiment']
mask = d['mask']
target_start = d['targets_start']
target_end = d['targets_end']
ids = ids.to(device,dtype = torch.long)
token_type_ids = token_type_ids.to(device,dtype = torch.long)
mask = mask.to(device,dtype = torch.long)
target_start = target_start.to(device,dtype = torch.long)
target_end = target_end.to(device,dtype = torch.long)
model.zero_grad()
out_start,out_end = model(
ids,
mask,
token_type_ids
)
loss = loss_fn(out_start,out_end,target_start,target_end)
loss.backward()
optimizer.step()
scheduler.step()
out_start = torch.softmax(out_start,dim = 1).cpu().detach().numpy()
out_end = torch.softmax(out_end,dim = 1).cpu().detach().numpy()
jac_scores = []
# print(sentiment)
# print(offsets,len(offsets),type(offsets))
for j,tweet in enumerate(orig_tweet):
# print(j)
offset = offsets[j]
selected_text = orig_selected[j]
sentiment = sentiments[j]
idx_start = np.argmax(out_start[j,:])
idx_end = np.argmax(out_end[j,:])
_,jac = utils.calculate_jaccard(tweet,offset,selected_text,
idx_start,idx_end,sentiment)
jac_scores.append(jac)
jaccard.update(np.mean(jac_scores),ids.size(0))
losses.update(loss.item(),ids.size(0))
tk0.set_postfix(loss = losses.avg,jaccard = jaccard.avg)
def eval_fn(data_loader,model,device):
model.eval()
losses = utils.AverageMeter()
jaccard = utils.AverageMeter()
with torch.no_grad():
losses = utils.AverageMeter()
jaccard = utils.AverageMeter()
tk0 = tqdm(data_loader,total = len(data_loader))
for bi,d in enumerate(tk0):
ids = d['ids']
offsets = d['offsets']
orig_selected = d['orig_selected_text']
token_type_ids = d['token_type_ids']
sentiments = d['orig_sentiment']
mask = d['mask']
target_start = d['targets_start']
target_end = d['targets_end']
orig_tweet = d['orig_tweet']
ids = ids.to(device,dtype = torch.long)
token_type_ids = token_type_ids.to(device,dtype = torch.long)
mask = mask.to(device,dtype = torch.long)
target_start = target_start.to(device,dtype = torch.long)
target_end = target_end.to(device,dtype = torch.long)
out_start,out_end = model(
ids,
mask,
token_type_ids
)
loss = loss_fn(out_start,out_end,target_start,target_end)
out_start = torch.softmax(out_start,dim = 1).cpu().detach().numpy()
out_end = torch.softmax(out_end,dim = 1).cpu().detach().numpy()
# print(out_start.shape,out_end.shape)
jac_scores = []
# print(offsets,len(offsets),type(offsets))
for j,tweet in enumerate(orig_tweet):
offset = offsets[j]
selected_text = orig_selected[j]
idx_start = np.argmax(out_start[j,:])
sentiment = sentiments[j]
idx_end = np.argmax(out_end[j,:])
_,jac = utils.calculate_jaccard(tweet,offset,selected_text,
idx_start,idx_end,sentiment)
jac_scores.append(jac)
jaccard.update(np.mean(jac_scores),ids.size(0))
losses.update(loss.item(),ids.size(0))
tk0.set_postfix(loss = losses.avg,jaccard = jaccard.avg)
return np.mean(jac_scores)
| 36.954198 | 80 | 0.526957 | 555 | 4,841 | 4.38018 | 0.158559 | 0.036199 | 0.049362 | 0.074044 | 0.837104 | 0.807487 | 0.788153 | 0.788153 | 0.7355 | 0.7355 | 0 | 0.007157 | 0.365007 | 4,841 | 130 | 81 | 37.238462 | 0.783669 | 0.030366 | 0 | 0.78 | 0 | 0 | 0.041246 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0.03 | false | 0 | 0.05 | 0 | 0.1 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 1 | 1 | 1 | 1 | 1 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 7 |
0948ecdcd3c81680bee5c0b176de144f60b71837 | 2,391 | py | Python | model/resnet.py | zah-tane/stanford-cars-model | b299f9d9b7c55c6e925484ee31355f062066fdf4 | [
"MIT"
] | 25 | 2019-06-02T12:47:45.000Z | 2022-01-28T06:44:06.000Z | model/resnet.py | zah-tane/stanford-cars-model | b299f9d9b7c55c6e925484ee31355f062066fdf4 | [
"MIT"
] | 1 | 2019-09-04T02:25:48.000Z | 2019-09-04T02:25:48.000Z | model/resnet.py | zah-tane/stanford-cars-model | b299f9d9b7c55c6e925484ee31355f062066fdf4 | [
"MIT"
] | 12 | 2019-10-13T20:31:44.000Z | 2022-03-22T18:42:23.000Z | import torch.nn as nn
from torchvision.models import resnet34, resnet18, resnet50 , resnet101, resnet152
from base import BaseModel
class ResNet152(BaseModel):
def __init__(self, num_classes=196, use_pretrained=True):
super(BaseModel, self).__init__()
self.model = resnet152(pretrained=use_pretrained)
# replace last layer with total cars classes
n_inputs = self.model.fc.in_features
classifier = nn.Sequential(nn.Linear(n_inputs, num_classes))
self.model.fc = classifier
def forward(self, x):
return self.model(x)
class ResNet101(BaseModel):
def __init__(self, num_classes=196, use_pretrained=True):
super(BaseModel, self).__init__()
self.model = resnet101(pretrained=use_pretrained)
# replace last layer with total cars classes
n_inputs = self.model.fc.in_features
classifier = nn.Sequential(nn.Linear(n_inputs, num_classes))
self.model.fc = classifier
def forward(self, x):
return self.model(x)
class ResNet50(BaseModel):
def __init__(self, num_classes=196, use_pretrained=True):
super(BaseModel, self).__init__()
self.model = resnet50(pretrained=use_pretrained)
# replace last layer with total cars classes
n_inputs = self.model.fc.in_features
classifier = nn.Sequential(nn.Linear(n_inputs, num_classes))
self.model.fc = classifier
def forward(self, x):
return self.model(x)
class ResNet34(BaseModel):
def __init__(self, num_classes=196, use_pretrained=True):
super(BaseModel, self).__init__()
self.model = resnet34(pretrained=use_pretrained)
# replace last layer with total cars classes
n_inputs = self.model.fc.in_features
classifier = nn.Sequential(nn.Linear(n_inputs, num_classes))
self.model.fc = classifier
def forward(self, x):
return self.model(x)
class ResNet18(BaseModel):
def __init__(self, num_classes=196, use_pretrained=True):
super(BaseModel, self).__init__()
self.model = resnet18(pretrained=use_pretrained)
# replace last layer with total cars classes
n_inputs = self.model.fc.in_features
classifier = nn.Sequential(nn.Linear(n_inputs, num_classes))
self.model.fc = classifier
def forward(self, x):
return self.model(x)
| 28.464286 | 82 | 0.680887 | 303 | 2,391 | 5.125413 | 0.141914 | 0.115905 | 0.070831 | 0.064392 | 0.872505 | 0.872505 | 0.872505 | 0.872505 | 0.872505 | 0.872505 | 0 | 0.027508 | 0.224592 | 2,391 | 83 | 83 | 28.807229 | 0.81014 | 0.089502 | 0 | 0.729167 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0.208333 | false | 0 | 0.0625 | 0.104167 | 0.479167 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 1 | 1 | 1 | 1 | 1 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | 9 |
11987eb6184a6391967e78d2e2186adb9d26a886 | 245,810 | py | Python | model/bisim/bisim.py | ondrejba/discrete_abstractions | 444def53ae2ca6c8a5b5b453448f7c4bbaba07e1 | [
"MIT"
] | 6 | 2020-09-14T22:48:00.000Z | 2021-12-11T04:14:07.000Z | model/bisim/bisim.py | ondrejba/discrete_abstractions | 444def53ae2ca6c8a5b5b453448f7c4bbaba07e1 | [
"MIT"
] | null | null | null | model/bisim/bisim.py | ondrejba/discrete_abstractions | 444def53ae2ca6c8a5b5b453448f7c4bbaba07e1 | [
"MIT"
] | null | null | null | import os
import numpy as np
import matplotlib.pyplot as plt
import tensorflow as tf
import agents.utils as agent_utils
class FullOracleModel:
def __init__(self, env, input_shape, num_blocks, encoder_filters, encoder_filter_sizes, encoder_strides,
encoder_neurons, learning_rate, weight_decay, gamma, batch_norm=False):
self.env = env
self.input_shape = input_shape
self.num_blocks = num_blocks
self.encoder_filters = encoder_filters
self.encoder_filter_sizes = encoder_filter_sizes
self.encoder_strides = encoder_strides
self.encoder_neurons = encoder_neurons
self.learning_rate = learning_rate
self.weight_decay = weight_decay
self.gamma = gamma
self.batch_norm = batch_norm
def encode(self, states, batch_size=100):
assert states.shape[0]
num_steps = int(np.ceil(states.shape[0] / batch_size))
embeddings = []
for i in range(num_steps):
batch_slice = np.index_exp[i * batch_size:(i + 1) * batch_size]
embedding = self.session.run(self.state_block_t, feed_dict={
self.states_pl: states[batch_slice]
})
embeddings.append(embedding)
embeddings = np.concatenate(embeddings, axis=0)
return embeddings
def build(self):
self.build_placeholders_and_constants()
self.build_model()
self.build_training()
def build_placeholders_and_constants(self):
self.states_pl = tf.placeholder(tf.float32, shape=(None, *self.input_shape), name="states_pl")
self.actions_pl = tf.placeholder(tf.int32, shape=(None,), name="actions_pl")
self.rewards_pl = tf.placeholder(tf.float32, shape=(None,), name="rewards_pl")
self.dones_pl = tf.placeholder(tf.bool, shape=(None,), name="dones_pl")
self.next_states_pl = tf.placeholder(tf.float32, shape=(None, *self.input_shape), name="next_states_pl")
self.is_training_pl = tf.placeholder(tf.bool, shape=[], name="is_training_pl")
self.r_c = tf.constant(self.env.r, dtype=tf.float32)
self.p_c = tf.constant(self.env.p, dtype=tf.float32)
def build_model(self):
self.state_block_t = self.build_encoder(self.states_pl)
self.next_state_block_t = self.build_encoder(self.next_states_pl, share_weights=True)
def build_training(self):
r_t = tf.gather(self.r_c, self.actions_pl)
p_t = tf.gather(self.p_c, self.actions_pl)
dones_t = tf.cast(self.dones_pl, tf.float32)
self.reward_loss_t = tf.square(self.rewards_pl - tf.reduce_sum(self.state_block_t * r_t, axis=1))
self.transition_loss_t = tf.reduce_sum(
tf.square(tf.stop_gradient(self.next_state_block_t) - tf.matmul(tf.expand_dims(self.state_block_t, axis=1), p_t)[:, 0, :]),
axis=1
) * (1 - dones_t)
reg = tf.get_collection(tf.GraphKeys.REGULARIZATION_LOSSES)
if len(reg) > 0:
self.regularization_loss_t = tf.add_n(reg)
else:
self.regularization_loss_t = 0
self.loss_t = tf.reduce_mean(
(1 / 2) * (self.reward_loss_t + self.gamma * self.transition_loss_t), axis=0
) + self.regularization_loss_t
self.train_step = tf.train.AdamOptimizer(self.learning_rate).minimize(self.loss_t)
if self.batch_norm:
self.update_op = tf.group(*tf.get_collection(tf.GraphKeys.UPDATE_OPS))
self.train_step = tf.group(self.train_step, self.update_op)
def build_encoder(self, input_t, share_weights=False):
x = tf.expand_dims(input_t, axis=-1)
with tf.variable_scope("encoder", reuse=share_weights):
for idx in range(len(self.encoder_filters)):
with tf.variable_scope("conv{:d}".format(idx + 1)):
x = tf.layers.conv2d(
x, self.encoder_filters[idx], self.encoder_filter_sizes[idx], self.encoder_strides[idx],
padding="SAME", activation=tf.nn.relu if not self.batch_norm else None,
kernel_regularizer=agent_utils.get_weight_regularizer(self.weight_decay),
kernel_initializer=agent_utils.get_mrsa_initializer(),
use_bias=not self.batch_norm
)
if self.batch_norm and idx != len(self.encoder_filters) - 1:
x = tf.layers.batch_normalization(x, training=self.is_training_pl)
x = tf.nn.relu(x)
x = tf.layers.flatten(x)
if self.batch_norm:
x = tf.layers.batch_normalization(x, training=self.is_training_pl)
x = tf.nn.relu(x)
for idx, neurons in enumerate(self.encoder_neurons):
with tf.variable_scope("fc{:d}".format(idx + 1)):
x = tf.layers.dense(
x, neurons, activation=tf.nn.relu if not self.batch_norm else None,
kernel_regularizer=agent_utils.get_weight_regularizer(self.weight_decay),
kernel_initializer=agent_utils.get_mrsa_initializer(),
use_bias=not self.batch_norm
)
if self.batch_norm:
x = tf.layers.batch_normalization(x, training=self.is_training_pl)
x = tf.nn.relu(x)
with tf.variable_scope("predict"):
x = tf.layers.dense(
x, self.num_blocks, activation=tf.nn.softmax,
kernel_regularizer=agent_utils.get_weight_regularizer(self.weight_decay),
kernel_initializer=agent_utils.get_mrsa_initializer()
)
return x
def start_session(self, gpu_memory=None):
gpu_options = None
if gpu_memory is not None:
gpu_options = tf.GPUOptions(per_process_gpu_memory_fraction=gpu_memory)
tf_config = tf.ConfigProto(gpu_options=gpu_options)
self.session = tf.Session(config=tf_config)
self.session.run(tf.global_variables_initializer())
def stop_session(self):
if self.session is not None:
self.session.close()
class PartialOracleModel:
ENCODER_NAMESPACE = "encoder"
TARGET_ENCODER_NAMESPACE = "target_encoder"
def __init__(self, input_shape, num_blocks, num_actions, encoder_filters, encoder_filter_sizes,
encoder_strides, encoder_neurons, learning_rate_encoder, learning_rate_model, weight_decay, gamma,
optimizer_encoder, optimizer_model, max_steps, batch_norm=True, target_network=False,
add_hand_state=False, add_entropy=False, entropy_from=10000, entropy_start=0.0, entropy_end=0.1,
ce_transitions=False):
self.input_shape = input_shape
self.num_blocks = num_blocks
self.num_actions = num_actions
self.encoder_filters = encoder_filters
self.encoder_filter_sizes = encoder_filter_sizes
self.encoder_strides = encoder_strides
self.encoder_neurons = encoder_neurons
self.learning_rate_encoder = learning_rate_encoder
self.learning_rate_model = learning_rate_model
self.weight_decay = weight_decay
self.gamma = gamma
self.optimizer_encoder = optimizer_encoder
self.optimizer_model = optimizer_model
self.max_steps = max_steps
self.batch_norm = batch_norm
self.target_network = target_network
self.add_hand_state = add_hand_state
self.add_entropy = add_entropy
self.entropy_from = entropy_from
self.entropy_start = entropy_start
self.entropy_end = entropy_end
self.ce_transitions = ce_transitions
self.hand_states_pl, self.next_hand_states_pl = None, None
def encode(self, states, batch_size=100, hand_states=None):
assert states.shape[0]
num_steps = int(np.ceil(states.shape[0] / batch_size))
embeddings = []
for i in range(num_steps):
batch_slice = np.index_exp[i * batch_size:(i + 1) * batch_size]
feed_dict = {
self.states_pl: states[batch_slice],
self.is_training_pl: False
}
if hand_states is not None:
feed_dict[self.hand_states_pl] = hand_states[batch_slice]
embedding = self.session.run(self.state_block_t, feed_dict=feed_dict)
embeddings.append(embedding)
embeddings = np.concatenate(embeddings, axis=0)
return embeddings
def build(self):
self.build_placeholders()
self.build_model()
self.build_training()
def build_placeholders(self):
self.states_pl = tf.placeholder(tf.float32, shape=(None, *self.input_shape), name="states_pl")
self.actions_pl = tf.placeholder(tf.int32, shape=(None,), name="actions_pl")
self.rewards_pl = tf.placeholder(tf.float32, shape=(None,), name="rewards_pl")
self.dones_pl = tf.placeholder(tf.bool, shape=(None,), name="dones_pl")
self.next_states_pl = tf.placeholder(tf.float32, shape=(None, *self.input_shape), name="next_states_pl")
self.is_training_pl = tf.placeholder(tf.bool, shape=[], name="is_training_pl")
if self.add_hand_state:
self.hand_states_pl = tf.placeholder(tf.float32, shape=(None, 1), name="hand_states_pl")
self.next_hand_states_pl = tf.placeholder(tf.float32, shape=(None, 1), name="next_hand_states_pl")
def build_model(self):
self.state_block_t = self.build_encoder(self.states_pl, hand_state=self.hand_states_pl)
if self.target_network:
self.next_state_block_t = self.build_encoder(
self.next_states_pl, share_weights=False, namespace=self.TARGET_ENCODER_NAMESPACE,
hand_state=self.next_hand_states_pl
)
self.build_target_update()
else:
self.next_state_block_t = self.build_encoder(
self.next_states_pl, share_weights=True, hand_state=self.next_hand_states_pl
)
self.r_t = tf.get_variable(
"reward_matrix", shape=(self.num_actions, self.num_blocks), dtype=tf.float32,
initializer=tf.random_uniform_initializer(minval=0, maxval=1, dtype=tf.float32)
)
self.p_t = tf.get_variable(
"transition_matrix", shape=(self.num_actions, self.num_blocks, self.num_blocks), dtype=tf.float32,
initializer=tf.random_uniform_initializer(minval=0, maxval=1, dtype=tf.float32)
)
def build_training(self):
self.global_step = tf.train.get_or_create_global_step()
r_t = tf.gather(self.r_t, self.actions_pl)
p_t = tf.gather(self.p_t, self.actions_pl)
dones_t = tf.cast(self.dones_pl, tf.float32)
self.reward_loss_t = (1 / 2) * tf.square(self.rewards_pl - tf.reduce_sum(self.state_block_t * r_t, axis=1))
if self.ce_transitions:
# treat p_t as log probabilities
p_t = tf.nn.softmax(p_t, axis=-1)
# predict next state
next_state = tf.matmul(tf.expand_dims(self.state_block_t, axis=1), p_t)[:, 0, :]
# cross entropy between next state probs and predicted probs
self.transition_loss_t = - self.next_state_block_t * tf.log(next_state + 1e-7)
self.transition_loss_t = tf.reduce_sum(self.transition_loss_t, axis=-1)
self.transition_loss_t = self.transition_loss_t * (1 - dones_t)
else:
self.transition_loss_t = (1 / 2) * tf.reduce_sum(
tf.square(tf.stop_gradient(self.next_state_block_t) -
tf.matmul(tf.expand_dims(self.state_block_t, axis=1), p_t)[:, 0, :]),
axis=1
) * (1 - dones_t)
reg = tf.get_collection(tf.GraphKeys.REGULARIZATION_LOSSES)
if len(reg) > 0:
self.regularization_loss_t = tf.add_n(reg)
else:
self.regularization_loss_t = 0
self.loss_t = tf.reduce_mean(
self.reward_loss_t + self.gamma * self.transition_loss_t, axis=0
) + self.regularization_loss_t
if self.add_entropy:
plogs = self.state_block_t * tf.log(self.state_block_t + 1e-7)
self.entropy_loss_t = tf.reduce_mean(tf.reduce_sum(- plogs, axis=1), axis=0)
f = tf.maximum(0.0, tf.cast(self.global_step - self.entropy_from, tf.float32)) / \
(self.max_steps - self.entropy_from)
f = f * (self.entropy_end - self.entropy_start) + self.entropy_start
self.loss_t += f * self.entropy_loss_t
encoder_variables = tf.get_collection(tf.GraphKeys.TRAINABLE_VARIABLES, scope=self.ENCODER_NAMESPACE)
model_variables = [self.r_t, self.p_t]
encoder_optimizer = agent_utils.get_optimizer(self.optimizer_encoder, self.learning_rate_encoder)
model_optimizer = agent_utils.get_optimizer(self.optimizer_model, self.learning_rate_model)
self.encoder_train_step = encoder_optimizer.minimize(
self.loss_t, global_step=self.global_step, var_list=encoder_variables
)
if self.batch_norm:
self.update_op = tf.group(*tf.get_collection(tf.GraphKeys.UPDATE_OPS))
self.encoder_train_step = tf.group(self.encoder_train_step, self.update_op)
self.model_train_step = model_optimizer.minimize(
self.loss_t, var_list=model_variables
)
self.train_step = tf.group(self.encoder_train_step, self.model_train_step)
def build_encoder(self, input_t, share_weights=False, namespace=ENCODER_NAMESPACE, hand_state=None):
x = tf.expand_dims(input_t, axis=-1)
with tf.variable_scope(namespace, reuse=share_weights):
for idx in range(len(self.encoder_filters)):
with tf.variable_scope("conv{:d}".format(idx + 1)):
x = tf.layers.conv2d(
x, self.encoder_filters[idx], self.encoder_filter_sizes[idx], self.encoder_strides[idx],
padding="SAME", activation=tf.nn.relu if not self.batch_norm else None,
kernel_regularizer=agent_utils.get_weight_regularizer(self.weight_decay),
kernel_initializer=agent_utils.get_mrsa_initializer(),
use_bias=not self.batch_norm
)
if self.batch_norm and idx != len(self.encoder_filters) - 1:
x = tf.layers.batch_normalization(x, training=self.is_training_pl)
x = tf.nn.relu(x)
x = tf.layers.flatten(x)
if self.batch_norm:
x = tf.layers.batch_normalization(x, training=self.is_training_pl)
x = tf.nn.relu(x)
if hand_state is not None:
x = tf.concat([x, hand_state], axis=1)
for idx, neurons in enumerate(self.encoder_neurons):
with tf.variable_scope("fc{:d}".format(idx + 1)):
x = tf.layers.dense(
x, neurons, activation=tf.nn.relu if not self.batch_norm else None,
kernel_regularizer=agent_utils.get_weight_regularizer(self.weight_decay),
kernel_initializer=agent_utils.get_mrsa_initializer(),
use_bias=not self.batch_norm
)
if self.batch_norm:
x = tf.layers.batch_normalization(x, training=self.is_training_pl)
x = tf.nn.relu(x)
with tf.variable_scope("predict"):
x = tf.layers.dense(
x, self.num_blocks, activation=tf.nn.softmax,
kernel_regularizer=agent_utils.get_weight_regularizer(self.weight_decay),
kernel_initializer=agent_utils.get_mrsa_initializer()
)
return x
def build_target_update(self):
source_vars = tf.get_collection(tf.GraphKeys.GLOBAL_VARIABLES, scope=self.ENCODER_NAMESPACE)
target_vars = tf.get_collection(tf.GraphKeys.GLOBAL_VARIABLES, scope=self.TARGET_ENCODER_NAMESPACE)
assert len(source_vars) == len(target_vars) and len(source_vars) > 0
update_ops = []
for source_var, target_var in zip(source_vars, target_vars):
update_ops.append(tf.assign(target_var, source_var))
self.target_update_op = tf.group(*update_ops)
def start_session(self, gpu_memory=None):
gpu_options = None
if gpu_memory is not None:
gpu_options = tf.GPUOptions(per_process_gpu_memory_fraction=gpu_memory)
tf_config = tf.ConfigProto(gpu_options=gpu_options)
self.session = tf.Session(config=tf_config)
self.session.run(tf.global_variables_initializer())
def stop_session(self):
if self.session is not None:
self.session.close()
class GumbelModel:
ENCODER_NAMESPACE = "encoder"
TARGET_ENCODER_NAMESPACE = "target_encoder"
def __init__(self, input_shape, num_blocks, num_actions, encoder_filters, encoder_filter_sizes,
encoder_strides, encoder_neurons, learning_rate_encoder, learning_rate_r, learning_rate_p,
weight_decay, gamma, optimizer_encoder, optimizer_model, max_steps, batch_norm=True,
target_network=True, gamma_schedule=None, straight_through=False, kl=False, kl_weight=1.0,
oracle_r=None, oracle_p=None, transitions_mse=False, correct_ce=False):
self.input_shape = input_shape
self.num_blocks = num_blocks
self.num_actions = num_actions
self.encoder_filters = encoder_filters
self.encoder_filter_sizes = encoder_filter_sizes
self.encoder_strides = encoder_strides
self.encoder_neurons = encoder_neurons
self.learning_rate_encoder = learning_rate_encoder
self.learning_rate_r = learning_rate_r
self.learning_rate_p = learning_rate_p
self.weight_decay = weight_decay
self.gamma = gamma
self.optimizer_encoder = optimizer_encoder
self.optimizer_model = optimizer_model
self.max_steps = max_steps
self.batch_norm = batch_norm
self.target_network = target_network
self.gamma_schedule = gamma_schedule
self.straight_through = straight_through
self.kl = kl
self.kl_weight = kl_weight
self.oracle_r = oracle_r
self.oracle_p = oracle_p
self.transitions_mse = transitions_mse
self.correct_ce = correct_ce
if self.gamma_schedule is not None:
assert len(self.gamma) == len(self.gamma_schedule) + 1
self.hand_states_pl, self.next_hand_states_pl = None, None
def encode(self, states, batch_size=100, hand_states=None):
assert states.shape[0]
num_steps = int(np.ceil(states.shape[0] / batch_size))
embeddings = []
for i in range(num_steps):
batch_slice = np.index_exp[i * batch_size:(i + 1) * batch_size]
feed_dict = {
self.states_pl: states[batch_slice],
self.is_training_pl: False
}
if hand_states is not None:
feed_dict[self.hand_states_pl] = hand_states[batch_slice]
embedding = self.session.run(self.state_block_samples_t, feed_dict=feed_dict)
embeddings.append(embedding)
embeddings = np.concatenate(embeddings, axis=0)
return embeddings
def build(self):
self.build_placeholders()
self.build_model()
self.build_training()
def build_placeholders(self):
self.states_pl = tf.placeholder(tf.float32, shape=(None, *self.input_shape), name="states_pl")
self.actions_pl = tf.placeholder(tf.int32, shape=(None,), name="actions_pl")
self.rewards_pl = tf.placeholder(tf.float32, shape=(None,), name="rewards_pl")
self.dones_pl = tf.placeholder(tf.bool, shape=(None,), name="dones_pl")
self.next_states_pl = tf.placeholder(tf.float32, shape=(None, *self.input_shape), name="next_states_pl")
self.is_training_pl = tf.placeholder(tf.bool, shape=[], name="is_training_pl")
self.hand_states_pl = tf.placeholder(tf.float32, shape=(None, 1), name="hand_states_pl")
self.next_hand_states_pl = tf.placeholder(tf.float32, shape=(None, 1), name="next_hand_states_pl")
self.temperature_pl = tf.placeholder(tf.float32, shape=[], name="temperature_pl")
def build_model(self):
# encode state block
self.state_block_logits_t = self.build_encoder(self.states_pl, hand_state=self.hand_states_pl)
agent_utils.summarize(self.state_block_logits_t, "state_block_logits_t")
self.state_block_cat_dist = tf.contrib.distributions.OneHotCategorical(
logits=self.state_block_logits_t
)
self.state_block_samples_t = tf.cast(self.state_block_cat_dist.sample(), tf.int32)
self.state_block_sg_dist = tf.contrib.distributions.RelaxedOneHotCategorical(
self.temperature_pl, logits=self.state_block_logits_t
)
self.state_block_sg_samples_t = self.state_block_sg_dist.sample()
agent_utils.summarize(self.state_block_sg_samples_t, "state_block_sg_samples_t")
if self.straight_through:
# hard sample
self.state_block_sg_samples_hard_t = \
tf.cast(tf.one_hot(tf.argmax(self.state_block_sg_samples_t, -1), self.num_blocks), tf.float32)
# fake gradients for the hard sample
self.state_block_sg_samples_t = \
tf.stop_gradient(self.state_block_sg_samples_hard_t - self.state_block_sg_samples_t) + \
self.state_block_sg_samples_t
agent_utils.summarize(self.state_block_sg_samples_hard_t, "state_block_sg_samples_hard_t")
# encode next state block
if self.target_network:
self.next_state_block_logits_t = self.build_encoder(
self.next_states_pl, share_weights=False, namespace=self.TARGET_ENCODER_NAMESPACE,
hand_state=self.next_hand_states_pl
)
self.build_target_update()
else:
self.next_state_block_logits_t = self.build_encoder(
self.next_states_pl, share_weights=True, hand_state=self.next_hand_states_pl
)
self.next_state_block_cat_dist = tf.contrib.distributions.OneHotCategorical(
logits=self.next_state_block_logits_t
)
self.next_state_block_samples_t = tf.cast(self.next_state_block_cat_dist.sample(), tf.float32)
self.r_v = tf.get_variable(
"reward_matrix", shape=(self.num_actions, self.num_blocks), dtype=tf.float32,
initializer=tf.random_uniform_initializer(minval=0, maxval=1, dtype=tf.float32)
)
self.r_t = self.r_v
self.p_v = tf.get_variable(
"transition_matrix", shape=(self.num_actions, self.num_blocks, self.num_blocks), dtype=tf.float32,
initializer=tf.random_uniform_initializer(minval=0, maxval=1, dtype=tf.float32)
)
if not self.transitions_mse:
self.p_t = tf.nn.softmax(self.p_v, axis=-1)
else:
self.p_t = self.p_v
def build_training(self):
# set up global step variable
self.global_step = tf.train.get_or_create_global_step()
# gather reward and transition matrices for each action
if self.oracle_r is not None:
r_t = tf.gather(self.oracle_r, self.actions_pl)
else:
r_t = tf.gather(self.r_t, self.actions_pl)
if self.oracle_p is not None:
p_t = tf.gather(self.oracle_p, self.actions_pl)
else:
p_t = tf.gather(self.p_t, self.actions_pl)
dones_t = tf.cast(self.dones_pl, tf.float32)
# reward loss
self.reward_loss_t = tf.square(self.rewards_pl - tf.reduce_sum(self.state_block_sg_samples_t * r_t, axis=1))
# transition loss
next_state = tf.matmul(tf.expand_dims(self.state_block_sg_samples_t, axis=1), p_t)[:, 0, :]
if self.transitions_mse:
self.transition_loss_t = tf.reduce_sum(
tf.square(tf.stop_gradient(self.next_state_block_samples_t) - next_state),
axis=1
) * (1 - dones_t)
else:
if self.correct_ce:
self.transition_loss_t = tf.reduce_sum(
- tf.stop_gradient(tf.nn.softmax(self.next_state_block_logits_t)) * tf.log(next_state + 1e-7),
axis=1
) * (1 - dones_t)
else:
self.transition_loss_t = tf.reduce_sum(
- tf.stop_gradient(self.next_state_block_samples_t) * tf.log(next_state + 1e-7),
axis=1
) * (1 - dones_t)
# weight decay regularizer
reg = tf.get_collection(tf.GraphKeys.REGULARIZATION_LOSSES)
if len(reg) > 0:
self.regularization_loss_t = tf.add_n(reg)
else:
self.regularization_loss_t = 0.0
# kl divergence regularizer
if self.kl:
prior_logits_t = tf.ones_like(self.state_block_logits_t) / self.num_blocks
prior_cat_dist = tf.contrib.distributions.OneHotCategorical(logits=prior_logits_t)
kl_divergence_t = tf.contrib.distributions.kl_divergence(self.state_block_cat_dist, prior_cat_dist)
self.kl_loss_t = tf.reduce_mean(kl_divergence_t)
else:
self.kl_loss_t = 0.0
# final loss
if self.gamma_schedule is not None:
gamma = tf.train.piecewise_constant(self.global_step, self.gamma_schedule, self.gamma)
else:
gamma = self.gamma
self.loss_t = tf.reduce_mean(
self.reward_loss_t + gamma * self.transition_loss_t, axis=0
) + self.regularization_loss_t + self.kl_weight * self.kl_loss_t
# encoder optimizer
encoder_variables = tf.get_collection(tf.GraphKeys.TRAINABLE_VARIABLES, scope=self.ENCODER_NAMESPACE)
encoder_optimizer = agent_utils.get_optimizer(self.optimizer_encoder, self.learning_rate_encoder)
self.encoder_train_step = encoder_optimizer.minimize(
self.loss_t, global_step=self.global_step, var_list=encoder_variables
)
# add batch norm updates
if self.batch_norm:
self.update_op = tf.group(*tf.get_collection(tf.GraphKeys.UPDATE_OPS))
self.encoder_train_step = tf.group(self.encoder_train_step, self.update_op)
# model optimizer if not full oracle
if self.oracle_r is None or self.oracle_p is None:
r_optimizer = agent_utils.get_optimizer(self.optimizer_model, self.learning_rate_r)
r_step = r_optimizer.minimize(
self.reward_loss_t, var_list=[self.r_v]
)
p_optimizer = agent_utils.get_optimizer(self.optimizer_model, self.learning_rate_p)
p_step = p_optimizer.minimize(
self.transition_loss_t, var_list=[self.p_v]
)
self.model_train_step = tf.group(r_step, p_step)
self.train_step = tf.group(self.encoder_train_step, self.model_train_step)
else:
self.train_step = self.encoder_train_step
def build_encoder(self, input_t, share_weights=False, namespace=ENCODER_NAMESPACE, hand_state=None):
x = tf.expand_dims(input_t, axis=-1)
with tf.variable_scope(namespace, reuse=share_weights):
for idx in range(len(self.encoder_filters)):
with tf.variable_scope("conv{:d}".format(idx + 1)):
x = tf.layers.conv2d(
x, self.encoder_filters[idx], self.encoder_filter_sizes[idx], self.encoder_strides[idx],
padding="SAME", activation=tf.nn.relu if not self.batch_norm else None,
kernel_regularizer=agent_utils.get_weight_regularizer(self.weight_decay),
kernel_initializer=agent_utils.get_mrsa_initializer(),
use_bias=not self.batch_norm
)
if self.batch_norm and idx != len(self.encoder_filters) - 1:
x = tf.layers.batch_normalization(x, training=self.is_training_pl)
x = tf.nn.relu(x)
x = tf.layers.flatten(x)
if self.batch_norm:
x = tf.layers.batch_normalization(x, training=self.is_training_pl)
x = tf.nn.relu(x)
if hand_state is not None:
x = tf.concat([x, hand_state], axis=1)
for idx, neurons in enumerate(self.encoder_neurons):
with tf.variable_scope("fc{:d}".format(idx + 1)):
x = tf.layers.dense(
x, neurons, activation=tf.nn.relu if not self.batch_norm else None,
kernel_regularizer=agent_utils.get_weight_regularizer(self.weight_decay),
kernel_initializer=agent_utils.get_mrsa_initializer(),
use_bias=not self.batch_norm
)
if self.batch_norm:
x = tf.layers.batch_normalization(x, training=self.is_training_pl)
x = tf.nn.relu(x)
with tf.variable_scope("predict"):
x = tf.layers.dense(
x, self.num_blocks, activation=None,
kernel_regularizer=agent_utils.get_weight_regularizer(self.weight_decay),
kernel_initializer=agent_utils.get_mrsa_initializer()
)
return x
def build_target_update(self):
source_vars = tf.get_collection(tf.GraphKeys.GLOBAL_VARIABLES, scope=self.ENCODER_NAMESPACE)
target_vars = tf.get_collection(tf.GraphKeys.GLOBAL_VARIABLES, scope=self.TARGET_ENCODER_NAMESPACE)
assert len(source_vars) == len(target_vars) and len(source_vars) > 0
update_ops = []
for source_var, target_var in zip(source_vars, target_vars):
update_ops.append(tf.assign(target_var, source_var))
self.target_update_op = tf.group(*update_ops)
def build_summaries(self):
# losses
tf.summary.scalar("loss", self.loss_t)
tf.summary.scalar("transition_loss", tf.reduce_mean(self.transition_loss_t))
tf.summary.scalar("reward_loss", tf.reduce_mean(self.reward_loss_t))
# logits grads
grad_t = tf.gradients(tf.reduce_mean(self.transition_loss_t), self.state_block_logits_t)
grad_r = tf.gradients(tf.reduce_mean(self.reward_loss_t), self.state_block_logits_t)
norm_grad_t = tf.norm(grad_t, ord=2, axis=-1)[0]
norm_grad_r = tf.norm(grad_r, ord=2, axis=-1)[0]
agent_utils.summarize(norm_grad_t, "logits_grad_t")
agent_utils.summarize(norm_grad_r, "logits_grad_r")
# samples grads
grad_t = tf.gradients(tf.reduce_mean(self.transition_loss_t), self.state_block_sg_samples_t)
grad_r = tf.gradients(tf.reduce_mean(self.reward_loss_t), self.state_block_sg_samples_t)
norm_grad_t = tf.norm(grad_t, ord=2, axis=-1)[0]
norm_grad_r = tf.norm(grad_r, ord=2, axis=-1)[0]
agent_utils.summarize(norm_grad_t, "sg_samples_grad_t")
agent_utils.summarize(norm_grad_r, "sg_samples_grad_r")
def start_session(self, gpu_memory=None):
gpu_options = None
if gpu_memory is not None:
gpu_options = tf.GPUOptions(per_process_gpu_memory_fraction=gpu_memory)
tf_config = tf.ConfigProto(gpu_options=gpu_options)
self.session = tf.Session(config=tf_config)
self.session.run(tf.global_variables_initializer())
def stop_session(self):
if self.session is not None:
self.session.close()
class ExpectationModel:
ENCODER_NAMESPACE = "encoder"
TARGET_ENCODER_NAMESPACE = "target_encoder"
def __init__(self, input_shape, num_blocks, num_actions, encoder_filters, encoder_filter_sizes,
encoder_strides, encoder_neurons, learning_rate_encoder, learning_rate_r, learning_rate_t,
weight_decay, gamma, optimizer_encoder, optimizer_model, max_steps, batch_norm=True,
target_network=True, oracle_r=None, oracle_t=None, propagate_next_state=False,
z_transform=False, abs_z_transform=False, sigsoftmax=False, encoder_tau=1.0, model_tau=1.0,
no_tau_target_encoder=False, kl_penalty=False, kl_penalty_weight=0.01, small_r_init=False,
small_t_init=False):
if propagate_next_state:
assert not target_network
self.input_shape = input_shape
self.num_blocks = num_blocks
self.num_actions = num_actions
self.encoder_filters = encoder_filters
self.encoder_filter_sizes = encoder_filter_sizes
self.encoder_strides = encoder_strides
self.encoder_neurons = encoder_neurons
self.learning_rate_encoder = learning_rate_encoder
self.learning_rate_r = learning_rate_r
self.learning_rate_t = learning_rate_t
self.weight_decay = weight_decay
self.gamma = gamma
self.optimizer_encoder = optimizer_encoder
self.optimizer_model = optimizer_model
self.max_steps = max_steps
self.batch_norm = batch_norm
self.target_network = target_network
self.oracle_r = oracle_r
self.oracle_t = oracle_t
self.propagate_next_state = propagate_next_state
self.z_transform = z_transform
self.abs_z_transform = abs_z_transform
self.sigsoftmax = sigsoftmax
self.encoder_tau = encoder_tau
self.model_tau = model_tau
self.no_tau_target_encoder = no_tau_target_encoder
self.kl_penalty = kl_penalty
self.kl_penalty_weight = kl_penalty_weight
self.small_r_init = small_r_init
self.small_t_init = small_t_init
self.hand_states_pl, self.next_hand_states_pl = None, None
def encode(self, depths, hand_states, batch_size=100):
num_steps = int(np.ceil(depths.shape[0] / batch_size))
embeddings = []
for i in range(num_steps):
batch_slice = np.index_exp[i * batch_size:(i + 1) * batch_size]
feed_dict = {
self.states_pl: depths[batch_slice],
self.hand_states_pl: hand_states[batch_slice],
self.is_training_pl: False
}
embedding = self.session.run(self.state_softmax_t, feed_dict=feed_dict)
embeddings.append(embedding)
embeddings = np.concatenate(embeddings, axis=0)
return embeddings
def validate(self, depths, hand_states, actions, rewards, next_depths, next_hand_states, dones, batch_size=100):
num_steps = int(np.ceil(depths.shape[0] / batch_size))
losses = []
for i in range(num_steps):
batch_slice = np.index_exp[i * batch_size:(i + 1) * batch_size]
feed_dict = {
self.states_pl: depths[batch_slice],
self.hand_states_pl: hand_states[:, np.newaxis][batch_slice],
self.actions_pl: actions[batch_slice],
self.rewards_pl: rewards[batch_slice],
self.next_states_pl: next_depths[batch_slice],
self.next_hand_states_pl: next_hand_states[:, np.newaxis][batch_slice],
self.dones_pl: dones[batch_slice],
self.is_training_pl: False
}
l1, l2 = self.session.run([self.full_transition_loss_t, self.full_reward_loss_t], feed_dict=feed_dict)
losses.append(np.transpose(np.array([l1, l2]), axes=(1, 0)))
losses = np.concatenate(losses, axis=0)
return losses
def validate_and_encode(self, depths, hand_states, actions, rewards, next_depths, next_hand_states, dones,
batch_size=100):
num_steps = int(np.ceil(depths.shape[0] / batch_size))
losses = []
embeddings = []
for i in range(num_steps):
batch_slice = np.index_exp[i * batch_size:(i + 1) * batch_size]
feed_dict = {
self.states_pl: depths[batch_slice],
self.hand_states_pl: hand_states[:, np.newaxis][batch_slice],
self.actions_pl: actions[batch_slice],
self.rewards_pl: rewards[batch_slice],
self.next_states_pl: next_depths[batch_slice],
self.next_hand_states_pl: next_hand_states[:, np.newaxis][batch_slice],
self.dones_pl: dones[batch_slice],
self.is_training_pl: False
}
tmp_embeddings, l1, l2 = self.session.run([
self.state_softmax_t, self.full_transition_loss_t, self.full_reward_loss_t], feed_dict=feed_dict
)
losses.append(np.transpose(np.array([l1, l2]), axes=(1, 0)))
embeddings.append(tmp_embeddings)
losses = np.concatenate(losses, axis=0)
embeddings = np.concatenate(embeddings)
return losses, embeddings
def build(self):
self.build_placeholders()
self.build_model()
self.build_training()
def build_placeholders(self):
self.states_pl = tf.placeholder(tf.float32, shape=(None, *self.input_shape), name="states_pl")
self.actions_pl = tf.placeholder(tf.int32, shape=(None,), name="actions_pl")
self.rewards_pl = tf.placeholder(tf.float32, shape=(None,), name="rewards_pl")
self.dones_pl = tf.placeholder(tf.bool, shape=(None,), name="dones_pl")
self.next_states_pl = tf.placeholder(tf.float32, shape=(None, *self.input_shape), name="next_states_pl")
self.is_training_pl = tf.placeholder(tf.bool, shape=[], name="is_training_pl")
self.hand_states_pl = tf.placeholder(tf.float32, shape=(None, 1), name="hand_states_pl")
self.next_hand_states_pl = tf.placeholder(tf.float32, shape=(None, 1), name="next_hand_states_pl")
def build_model(self):
self.state_logits_t, self.state_softmax_t = self.build_encoder(
self.states_pl, self.hand_states_pl, self.encoder_tau
)
self.perplexity_t = tf.constant(2, dtype=tf.float32) ** (
- tf.reduce_mean(
tf.reduce_sum(
self.state_softmax_t * tf.log(self.state_softmax_t + 1e-7) /
tf.log(tf.constant(2, dtype=self.state_softmax_t.dtype)),
axis=1
),
axis=0
)
)
if self.no_tau_target_encoder:
target_tau = 1.0
else:
target_tau = self.encoder_tau
if self.target_network:
self.next_state_logits_t, self.next_state_softmax_t = self.build_encoder(
self.next_states_pl, self.next_hand_states_pl, target_tau, share_weights=False,
namespace=self.TARGET_ENCODER_NAMESPACE
)
self.build_target_update()
else:
self.next_state_logits_t, self.next_state_softmax_t = self.build_encoder(
self.next_states_pl, self.next_hand_states_pl, target_tau, share_weights=True
)
self.build_r_model()
self.build_t_model()
def build_r_model(self):
if self.small_r_init:
r_init = tf.random_normal_initializer(mean=0, stddev=0.1, dtype=tf.float32)
else:
r_init = tf.random_uniform_initializer(minval=0, maxval=1, dtype=tf.float32)
self.r_v = tf.get_variable(
"reward_matrix", shape=(self.num_actions, self.num_blocks), dtype=tf.float32,
initializer=r_init
)
self.r_t = self.r_v
def build_t_model(self):
if self.small_t_init:
t_init = tf.random_normal_initializer(mean=0, stddev=0.1, dtype=tf.float32)
else:
t_init = tf.random_uniform_initializer(minval=0, maxval=1, dtype=tf.float32)
self.t_v = tf.get_variable(
"transition_matrix", shape=(self.num_actions, self.num_blocks, self.num_blocks), dtype=tf.float32,
initializer=t_init
)
self.t_softmax_t = tf.nn.softmax(self.t_v / self.model_tau, axis=2)
self.t_logsoftmax_t = tf.nn.log_softmax(self.t_v / self.model_tau, axis=2)
def build_training(self):
# prep
self.global_step = tf.train.get_or_create_global_step()
self.gather_matrices()
self.dones_float_t = tf.cast(self.dones_pl, tf.float32)
# build losses
self.build_reward_loss()
self.build_transition_loss()
self.build_regularization_loss()
self.build_kl_penalty()
# build full loss
self.gamma_v = tf.Variable(initial_value=self.gamma, trainable=False)
self.loss_t = self.reward_loss_t + tf.stop_gradient(self.gamma_v) * self.transition_loss_t + \
self.regularization_loss_t + self.kl_penalty_weight_v * self.kl_penalty_t
# build training
self.build_encoder_training()
self.build_model_training()
# integrate training into a single op
if self.model_train_step is None:
self.train_step = self.encoder_train_step
else:
self.train_step = tf.group(self.encoder_train_step, self.model_train_step)
def gather_matrices(self):
if self.oracle_r is not None:
self.r_gather_t = tf.gather(self.oracle_r, self.actions_pl)
else:
self.r_gather_t = tf.gather(self.r_t, self.actions_pl)
if self.oracle_t is not None:
self.t_logsoftmax_gather_t = tf.gather(self.oracle_t, self.actions_pl)
else:
self.t_logsoftmax_gather_t = tf.gather(self.t_logsoftmax_t, self.actions_pl)
def build_reward_loss(self):
term1 = tf.square(self.rewards_pl[:, tf.newaxis] - self.r_gather_t)
term2 = term1 * self.state_softmax_t
self.full_reward_loss_t = (1 / 2) * tf.reduce_sum(term2, axis=1)
self.reward_loss_t = (1 / 2) * tf.reduce_mean(tf.reduce_sum(term2, axis=1), axis=0)
def build_transition_loss(self):
if self.propagate_next_state:
self.transition_term1 = self.state_softmax_t[:, :, tf.newaxis] * self.next_state_softmax_t[:, tf.newaxis, :]
else:
self.transition_term1 = self.state_softmax_t[:, :, tf.newaxis] * tf.stop_gradient(
self.next_state_softmax_t[:, tf.newaxis, :]
)
self.transition_term2 = self.transition_term1 * self.t_logsoftmax_gather_t
self.full_transition_loss_t = - tf.reduce_sum(self.transition_term2, axis=[1, 2]) * (1 - self.dones_float_t)
self.transition_loss_t = tf.reduce_sum(self.full_transition_loss_t, axis=0) / tf.reduce_max(
[1.0, tf.reduce_sum(1 - self.dones_float_t)]
)
def build_regularization_loss(self):
reg = tf.get_collection(tf.GraphKeys.REGULARIZATION_LOSSES)
if len(reg) > 0:
self.regularization_loss_t = tf.add_n(reg)
else:
self.regularization_loss_t = 0
def build_kl_penalty(self):
self.kl_penalty_weight_v = tf.Variable(self.kl_penalty_weight, trainable=False, dtype=tf.float32)
self.kl_penalty_weight_pl = tf.placeholder(tf.float32, shape=[], name="kl_penalty_weight_pl")
self.kl_penalty_weight_assign = tf.assign(self.kl_penalty_weight_v, self.kl_penalty_weight_pl)
if self.kl_penalty:
log_softmax = tf.nn.log_softmax(self.state_logits_t, axis=-1)
self.kl_penalty_t = tf.reduce_mean(tf.reduce_sum(self.state_softmax_t * log_softmax, axis=-1), axis=0)
else:
self.kl_penalty_t = 0.0
def build_encoder_training(self):
encoder_variables = tf.get_collection(tf.GraphKeys.TRAINABLE_VARIABLES, scope=self.ENCODER_NAMESPACE)
encoder_optimizer = agent_utils.get_optimizer(self.optimizer_encoder, self.learning_rate_encoder)
self.encoder_train_step = encoder_optimizer.minimize(
self.loss_t, global_step=self.global_step, var_list=encoder_variables
)
if self.batch_norm:
self.update_op = tf.group(*tf.get_collection(tf.GraphKeys.UPDATE_OPS))
self.encoder_train_step = tf.group(self.encoder_train_step, self.update_op)
def build_model_training(self):
model_train_step = []
if self.oracle_r is None:
r_optimizer = agent_utils.get_optimizer(self.optimizer_model, self.learning_rate_r)
self.r_step = r_optimizer.minimize(
self.reward_loss_t, var_list=[self.r_v]
)
model_train_step.append(self.r_step)
if self.oracle_t is None:
t_optimizer = agent_utils.get_optimizer(self.optimizer_model, self.learning_rate_t)
self.t_step = t_optimizer.minimize(
self.transition_loss_t, var_list=[self.t_v]
)
model_train_step.append(self.t_step)
if len(model_train_step) > 0:
self.model_train_step = tf.group(*model_train_step)
else:
self.model_train_step = None
def build_encoder(self, depth_pl, hand_state_pl, tau, share_weights=False, namespace=ENCODER_NAMESPACE):
x = tf.expand_dims(depth_pl, axis=-1)
with tf.variable_scope(namespace, reuse=share_weights):
for idx in range(len(self.encoder_filters)):
with tf.variable_scope("conv{:d}".format(idx + 1)):
x = tf.layers.conv2d(
x, self.encoder_filters[idx], self.encoder_filter_sizes[idx], self.encoder_strides[idx],
padding="SAME", activation=tf.nn.relu if not self.batch_norm else None,
kernel_regularizer=agent_utils.get_weight_regularizer(self.weight_decay),
kernel_initializer=agent_utils.get_mrsa_initializer(),
use_bias=not self.batch_norm
)
if self.batch_norm and idx != len(self.encoder_filters) - 1:
x = tf.layers.batch_normalization(x, training=self.is_training_pl)
x = tf.nn.relu(x)
x = tf.layers.flatten(x)
if self.batch_norm:
x = tf.layers.batch_normalization(x, training=self.is_training_pl)
x = tf.nn.relu(x)
x = tf.concat([x, hand_state_pl], axis=1)
for idx, neurons in enumerate(self.encoder_neurons):
with tf.variable_scope("fc{:d}".format(idx + 1)):
x = tf.layers.dense(
x, neurons, activation=tf.nn.relu if not self.batch_norm else None,
kernel_regularizer=agent_utils.get_weight_regularizer(self.weight_decay),
kernel_initializer=agent_utils.get_mrsa_initializer(),
use_bias=not self.batch_norm
)
if self.batch_norm:
x = tf.layers.batch_normalization(x, training=self.is_training_pl)
x = tf.nn.relu(x)
with tf.variable_scope("predict"):
x = tf.layers.dense(
x, self.num_blocks, activation=None,
kernel_regularizer=agent_utils.get_weight_regularizer(self.weight_decay),
kernel_initializer=agent_utils.get_mrsa_initializer()
)
if self.z_transform:
dist = x - tf.reduce_min(x, axis=1)[:, tf.newaxis]
dist = dist / tf.reduce_sum(dist, axis=1)[:, tf.newaxis]
elif self.abs_z_transform:
abs_x = tf.abs(x)
dist = abs_x / tf.reduce_sum(abs_x, axis=1)[:, tf.newaxis]
elif self.sigsoftmax:
e_x = tf.exp(x - tf.reduce_max(x, axis=1)[:, tf.newaxis])
sig_e_x = e_x * tf.nn.sigmoid(x)
dist = sig_e_x / tf.reduce_sum(sig_e_x, axis=1)[:, tf.newaxis]
else:
dist = tf.nn.softmax(x / tau)
return x, dist
def build_target_update(self):
source_vars = tf.get_collection(tf.GraphKeys.GLOBAL_VARIABLES, scope=self.ENCODER_NAMESPACE)
target_vars = tf.get_collection(tf.GraphKeys.GLOBAL_VARIABLES, scope=self.TARGET_ENCODER_NAMESPACE)
assert len(source_vars) == len(target_vars) and len(source_vars) > 0
update_ops = []
for source_var, target_var in zip(source_vars, target_vars):
update_ops.append(tf.assign(target_var, source_var))
self.target_update_op = tf.group(*update_ops)
def build_summaries(self):
# losses
tf.summary.scalar("loss", self.loss_t)
tf.summary.scalar("transition_loss", tf.reduce_mean(self.transition_loss_t))
tf.summary.scalar("reward_loss", tf.reduce_mean(self.reward_loss_t))
# logits and softmax
agent_utils.summarize(self.state_logits_t, "logits")
agent_utils.summarize(self.state_softmax_t, "softmax")
# gradients
self.grad_norms_d = dict()
for target, target_name in zip(
[self.loss_t, self.transition_loss_t, self.reward_loss_t], ["total_loss", "t_loss", "r_loss"]
):
for source, source_name in zip([self.state_logits_t, self.state_softmax_t], ["logits", "softmax"]):
grads = tf.gradients(tf.reduce_mean(target), source)
grad_norms = tf.norm(grads, ord=1, axis=-1)[0]
name = "state_{}_grad_{}".format(source_name, target_name)
self.grad_norms_d[name] = tf.reduce_mean(grad_norms)
agent_utils.summarize(grad_norms, name)
def set_gamma(self, value):
self.session.run(tf.assign(self.gamma_v, value))
def set_kl_penalty_weight(self, value):
self.session.run(self.kl_penalty_weight_assign, feed_dict={self.kl_penalty_weight_pl: value})
def start_session(self, gpu_memory=None):
gpu_options = None
if gpu_memory is not None:
gpu_options = tf.GPUOptions(per_process_gpu_memory_fraction=gpu_memory)
tf_config = tf.ConfigProto(gpu_options=gpu_options)
self.session = tf.Session(config=tf_config)
self.session.run(tf.global_variables_initializer())
def stop_session(self):
if self.session is not None:
self.session.close()
def save_matrices_as_images(self, step, save_dir, ext="pdf"):
r, p = self.session.run([self.r_t, self.t_softmax_t])
r = np.reshape(r, (r.shape[0], -1))
p = np.reshape(p, (p.shape[0], -1))
r_path = os.path.join(save_dir, "r_{:d}.{}".format(step, ext))
p_path = os.path.join(save_dir, "p_{:d}.{}".format(step, ext))
plt.clf()
plt.imshow(r, vmin=-0.5, vmax=1.5)
plt.colorbar()
plt.savefig(r_path)
plt.clf()
plt.imshow(p, vmin=0, vmax=1)
plt.colorbar()
plt.savefig(p_path)
class ExpectationModelGaussian(ExpectationModel):
def __init__(self, input_shape, num_blocks, num_actions, encoder_filters, encoder_filter_sizes,
encoder_strides, encoder_neurons, learning_rate_encoder, learning_rate_r, learning_rate_t,
weight_decay, gamma, optimizer_encoder, optimizer_model, max_steps, batch_norm=True,
target_network=True, oracle_r=None, oracle_t=None, propagate_next_state=False,
z_transform=False, abs_z_transform=False, sigsoftmax=False, encoder_tau=1.0, model_tau=1.0,
no_tau_target_encoder=False, kl_penalty=False, kl_penalty_weight=0.01, small_r_init=False,
small_t_init=False):
super(ExpectationModelGaussian, self).__init__(
input_shape, num_blocks, num_actions, encoder_filters, encoder_filter_sizes, encoder_strides,
encoder_neurons, learning_rate_encoder, learning_rate_r, learning_rate_t, weight_decay, gamma,
optimizer_encoder, optimizer_model, max_steps, batch_norm=batch_norm, target_network=target_network,
oracle_r=oracle_r, oracle_t=oracle_t, propagate_next_state=propagate_next_state, z_transform=z_transform,
abs_z_transform=abs_z_transform, sigsoftmax=sigsoftmax, encoder_tau=encoder_tau, model_tau=model_tau,
no_tau_target_encoder=no_tau_target_encoder, kl_penalty=kl_penalty,
kl_penalty_weight=kl_penalty_weight, small_r_init=small_r_init, small_t_init=small_t_init
)
def build_model(self):
self.state_mu_t, self.state_sd_t, self.state_var_t, self.state_logits_t, self.state_softmax_t = \
self.build_encoder(
self.states_pl, self.hand_states_pl, self.encoder_tau, namespace=self.ENCODER_NAMESPACE
)
self.perplexity_t = tf.constant(2, dtype=tf.float32) ** (
- tf.reduce_mean(
tf.reduce_sum(
self.state_softmax_t * tf.log(self.state_softmax_t + 1e-7) /
tf.log(tf.constant(2, dtype=self.state_softmax_t.dtype)),
axis=1
),
axis=0
)
)
if self.no_tau_target_encoder:
target_tau = 1.0
else:
target_tau = self.encoder_tau
if self.target_network:
self.next_state_mu_t, self.next_state_sd_t, self.next_state_var_t, self.next_state_logits_t, \
self.next_state_softmax_t = \
self.build_encoder(
self.next_states_pl, self.next_hand_states_pl, target_tau, share_weights=False,
namespace=self.TARGET_ENCODER_NAMESPACE
)
self.build_target_update()
else:
self.next_state_mu_t, self.next_state_sd_t, self.next_state_var_t, self.next_state_logits_t, \
self.next_state_softmax_t = \
self.build_encoder(
self.next_states_pl, self.next_hand_states_pl, target_tau, share_weights=True,
namespace=self.ENCODER_NAMESPACE
)
self.build_r_model()
self.build_t_model()
def build_encoder(self, depth_pl, hand_state_pl, tau, share_weights=False, namespace=None):
x = tf.expand_dims(depth_pl, axis=-1)
with tf.variable_scope(namespace, reuse=share_weights):
for idx in range(len(self.encoder_filters)):
with tf.variable_scope("conv{:d}".format(idx + 1)):
x = tf.layers.conv2d(
x, self.encoder_filters[idx], self.encoder_filter_sizes[idx], self.encoder_strides[idx],
padding="SAME", activation=tf.nn.relu if not self.batch_norm else None,
kernel_regularizer=agent_utils.get_weight_regularizer(self.weight_decay),
kernel_initializer=agent_utils.get_mrsa_initializer(),
use_bias=not self.batch_norm
)
if self.batch_norm and idx != len(self.encoder_filters) - 1:
x = tf.layers.batch_normalization(x, training=self.is_training_pl)
x = tf.nn.relu(x)
x = tf.layers.flatten(x)
if self.batch_norm:
x = tf.layers.batch_normalization(x, training=self.is_training_pl)
x = tf.nn.relu(x)
x = tf.concat([x, hand_state_pl], axis=1)
for idx, neurons in enumerate(self.encoder_neurons):
with tf.variable_scope("fc{:d}".format(idx + 1)):
x = tf.layers.dense(
x, neurons, activation=tf.nn.relu if not self.batch_norm else None,
kernel_regularizer=agent_utils.get_weight_regularizer(self.weight_decay),
kernel_initializer=agent_utils.get_mrsa_initializer(),
use_bias=not self.batch_norm
)
if self.batch_norm:
x = tf.layers.batch_normalization(x, training=self.is_training_pl)
x = tf.nn.relu(x)
with tf.variable_scope("predict"):
mu_t = tf.layers.dense(
x, self.num_blocks, activation=None,
kernel_regularizer=agent_utils.get_weight_regularizer(self.weight_decay),
kernel_initializer=agent_utils.get_mrsa_initializer()
)
log_var_t = tf.layers.dense(
x, self.num_blocks, activation=None,
kernel_regularizer=agent_utils.get_weight_regularizer(self.weight_decay),
kernel_initializer=agent_utils.get_mrsa_initializer()
)
var_t = tf.exp(log_var_t)
sd_t = tf.sqrt(var_t)
noise_t = tf.random_normal(
shape=(tf.shape(mu_t)[0], self.num_blocks), mean=0, stddev=1.0
)
sample_t = mu_t + sd_t * noise_t
dist_t = tf.nn.softmax(sample_t / tau)
return mu_t, sd_t, var_t, sample_t, dist_t
def build_kl_penalty(self):
self.kl_penalty_weight_v = tf.Variable(self.kl_penalty_weight, trainable=False, dtype=tf.float32)
self.kl_penalty_weight_pl = tf.placeholder(tf.float32, shape=[], name="kl_penalty_weight_pl")
self.kl_penalty_weight_assign = tf.assign(self.kl_penalty_weight_v, self.kl_penalty_weight_pl)
if self.kl_penalty:
kl_divergence_t = 0.5 * (tf.square(self.state_mu_t) + self.state_var_t - tf.log(self.state_var_t) - 1.0)
self.kl_penalty_t = tf.reduce_mean(tf.reduce_sum(kl_divergence_t, axis=1), axis=0)
else:
self.kl_penalty_t = 0.0
class ExpectationModelGaussianWithQ(ExpectationModelGaussian):
def __init__(self, input_shape, num_blocks, num_actions, encoder_filters, encoder_filter_sizes,
encoder_strides, encoder_neurons, learning_rate_encoder, learning_rate_r, learning_rate_t, learning_rate_q,
weight_decay, reward_gamma, transition_gamma, optimizer_encoder, optimizer_model, max_steps, batch_norm=True,
target_network=True, oracle_r=None, oracle_t=None, propagate_next_state=False,
z_transform=False, abs_z_transform=False, sigsoftmax=False, encoder_tau=1.0, model_tau=1.0,
no_tau_target_encoder=False, kl_penalty=False, kl_penalty_weight=0.01, small_r_init=False,
small_t_init=False, small_q_init=False):
super(ExpectationModelGaussianWithQ, self).__init__(
input_shape, num_blocks, num_actions, encoder_filters, encoder_filter_sizes, encoder_strides,
encoder_neurons, learning_rate_encoder, learning_rate_r, learning_rate_t, weight_decay, transition_gamma,
optimizer_encoder, optimizer_model, max_steps, batch_norm=batch_norm, target_network=target_network,
oracle_r=oracle_r, oracle_t=oracle_t, propagate_next_state=propagate_next_state, z_transform=z_transform,
abs_z_transform=abs_z_transform, sigsoftmax=sigsoftmax, encoder_tau=encoder_tau, model_tau=model_tau,
no_tau_target_encoder=no_tau_target_encoder, kl_penalty=kl_penalty, kl_penalty_weight=kl_penalty_weight,
small_r_init=small_r_init, small_t_init=small_t_init
)
self.learning_rate_q = learning_rate_q
self.small_q_init = small_q_init
self.reward_gamma = reward_gamma
def validate(self, depths, hand_states, actions, rewards, q_values, next_depths, next_hand_states, dones,
batch_size=100):
num_steps = int(np.ceil(depths.shape[0] / batch_size))
losses = []
for i in range(num_steps):
batch_slice = np.index_exp[i * batch_size:(i + 1) * batch_size]
feed_dict = {
self.states_pl: depths[batch_slice],
self.hand_states_pl: hand_states[:, np.newaxis][batch_slice],
self.actions_pl: actions[batch_slice],
self.rewards_pl: rewards[batch_slice],
self.q_values_pl: q_values[batch_slice],
self.next_states_pl: next_depths[batch_slice],
self.next_hand_states_pl: next_hand_states[:, np.newaxis][batch_slice],
self.dones_pl: dones[batch_slice],
self.is_training_pl: False
}
l1, l2, l3 = self.session.run(
[self.full_q_loss_t, self.full_transition_loss_t, self.full_reward_loss_t], feed_dict=feed_dict
)
losses.append(np.transpose(np.array([l1, l2, l3]), axes=(1, 0)))
losses = np.concatenate(losses, axis=0)
return losses
def validate_and_encode(self, depths, hand_states, actions, rewards, q_values, next_depths, next_hand_states, dones,
batch_size=100):
num_steps = int(np.ceil(depths.shape[0] / batch_size))
losses = []
embeddings = []
for i in range(num_steps):
batch_slice = np.index_exp[i * batch_size:(i + 1) * batch_size]
feed_dict = {
self.states_pl: depths[batch_slice],
self.hand_states_pl: hand_states[:, np.newaxis][batch_slice],
self.actions_pl: actions[batch_slice],
self.rewards_pl: rewards[batch_slice],
self.q_values_pl: q_values[batch_slice],
self.next_states_pl: next_depths[batch_slice],
self.next_hand_states_pl: next_hand_states[:, np.newaxis][batch_slice],
self.dones_pl: dones[batch_slice],
self.is_training_pl: False
}
tmp_embeddings, l1, l2, l3 = self.session.run([
self.state_softmax_t, self.full_q_loss_t, self.full_transition_loss_t, self.full_reward_loss_t],
feed_dict=feed_dict
)
losses.append(np.transpose(np.array([l1, l2, l3]), axes=(1, 0)))
embeddings.append(tmp_embeddings)
losses = np.concatenate(losses, axis=0)
embeddings = np.concatenate(embeddings)
return losses, embeddings
def build_placeholders(self):
self.states_pl = tf.placeholder(tf.float32, shape=(None, *self.input_shape), name="states_pl")
self.actions_pl = tf.placeholder(tf.int32, shape=(None,), name="actions_pl")
self.rewards_pl = tf.placeholder(tf.float32, shape=(None,), name="rewards_pl")
self.q_values_pl = tf.placeholder(tf.float32, shape=(None, self.num_actions), name="q_values_pl")
self.dones_pl = tf.placeholder(tf.bool, shape=(None,), name="dones_pl")
self.next_states_pl = tf.placeholder(tf.float32, shape=(None, *self.input_shape), name="next_states_pl")
self.is_training_pl = tf.placeholder(tf.bool, shape=[], name="is_training_pl")
self.hand_states_pl = tf.placeholder(tf.float32, shape=(None, 1), name="hand_states_pl")
self.next_hand_states_pl = tf.placeholder(tf.float32, shape=(None, 1), name="next_hand_states_pl")
def build_model(self):
self.state_mu_t, self.state_sd_t, self.state_var_t, self.state_logits_t, self.state_softmax_t = \
self.build_encoder(
self.states_pl, self.hand_states_pl, self.encoder_tau, namespace=self.ENCODER_NAMESPACE
)
self.perplexity_t = tf.constant(2, dtype=tf.float32) ** (
- tf.reduce_mean(
tf.reduce_sum(
self.state_softmax_t * tf.log(self.state_softmax_t + 1e-7) /
tf.log(tf.constant(2, dtype=self.state_softmax_t.dtype)),
axis=1
),
axis=0
)
)
if self.no_tau_target_encoder:
target_tau = 1.0
else:
target_tau = self.encoder_tau
if self.target_network:
self.next_state_mu_t, self.next_state_sd_t, self.next_state_var_t, self.next_state_logits_t, \
self.next_state_softmax_t = \
self.build_encoder(
self.next_states_pl, self.next_hand_states_pl, target_tau, share_weights=False,
namespace=self.TARGET_ENCODER_NAMESPACE
)
self.build_target_update()
else:
self.next_state_mu_t, self.next_state_sd_t, self.next_state_var_t, self.next_state_logits_t, \
self.next_state_softmax_t = \
self.build_encoder(
self.next_states_pl, self.next_hand_states_pl, target_tau, share_weights=True,
namespace=self.ENCODER_NAMESPACE
)
self.build_r_model()
self.build_t_model()
self.build_q_model()
def build_q_model(self):
if self.small_q_init:
q_init = tf.random_normal_initializer(mean=0, stddev=0.1, dtype=tf.float32)
else:
q_init = tf.random_uniform_initializer(minval=0, maxval=1, dtype=tf.float32)
self.q_v = tf.get_variable(
"q_matrix", shape=(self.num_actions, self.num_blocks), dtype=tf.float32,
initializer=q_init
)
self.q_t = self.q_v
def build_training(self):
# prep
self.global_step = tf.train.get_or_create_global_step()
self.gather_matrices()
self.dones_float_t = tf.cast(self.dones_pl, tf.float32)
# build losses
self.build_q_loss()
self.build_reward_loss()
self.build_transition_loss()
self.build_regularization_loss()
self.build_kl_penalty()
# build full loss
self.gamma_v = tf.Variable(initial_value=self.gamma, trainable=False)
self.loss_t = self.q_loss_t + self.reward_gamma * self.reward_loss_t + \
tf.stop_gradient(self.gamma_v) * self.transition_loss_t + \
self.regularization_loss_t + self.kl_penalty_weight_v * self.kl_penalty_t
# build training
self.build_encoder_training()
self.build_model_training()
self.build_q_model_training()
if self.model_train_step is None:
self.model_train_step = self.q_step
else:
self.model_train_step = tf.group(self.model_train_step, self.q_step)
# integrate training into a single op
self.train_step = tf.group(self.encoder_train_step, self.model_train_step)
def build_q_loss(self):
term1 = tf.square(self.q_values_pl[:, :, tf.newaxis] - self.q_t[tf.newaxis, :, :])
term1 = tf.reduce_sum(term1, axis=1)
term2 = term1 * self.state_softmax_t
self.full_q_loss_t = (1 / 2) * tf.reduce_sum(term2, axis=1)
self.q_loss_t = tf.reduce_mean(self.full_q_loss_t, axis=0)
def build_q_model_training(self):
q_optimizer = agent_utils.get_optimizer(self.optimizer_model, self.learning_rate_q)
self.q_step = q_optimizer.minimize(
self.q_loss_t, var_list=[self.q_v]
)
class ExpectationModelContinuous:
ENCODER_NAMESPACE = "encoder"
TARGET_ENCODER_NAMESPACE = "target_encoder"
def __init__(self, input_shape, num_blocks, num_actions, encoder_filters, encoder_filter_sizes,
encoder_strides, encoder_neurons, learning_rate_encoder, learning_rate_r, learning_rate_t,
weight_decay, gamma, optimizer_encoder, optimizer_model, max_steps, batch_norm=True,
target_network=True, propagate_next_state=False, no_sample=False, softplus=False,
beta=0.0, zero_embedding_variance=False, old_bn_settings=False, bn_momentum=0.99):
if propagate_next_state:
assert not target_network
self.input_shape = input_shape
self.num_blocks = num_blocks
self.num_actions = num_actions
self.encoder_filters = encoder_filters
self.encoder_filter_sizes = encoder_filter_sizes
self.encoder_strides = encoder_strides
self.encoder_neurons = encoder_neurons
self.learning_rate_encoder = learning_rate_encoder
self.learning_rate_r = learning_rate_r
self.learning_rate_t = learning_rate_t
self.weight_decay = weight_decay
self.gamma = gamma
self.optimizer_encoder = optimizer_encoder
self.optimizer_model = optimizer_model
self.max_steps = max_steps
self.batch_norm = batch_norm
self.target_network = target_network
self.propagate_next_state = propagate_next_state
self.no_sample = no_sample
self.softplus = softplus
self.beta = beta
self.zero_embedding_variance = zero_embedding_variance
self.old_bn_settings = old_bn_settings
self.bn_momentum = bn_momentum
self.hand_states_pl, self.next_hand_states_pl = None, None
def encode(self, depths, hand_states, batch_size=100, zero_sd=False):
num_steps = int(np.ceil(depths.shape[0] / batch_size))
embeddings = []
for i in range(num_steps):
batch_slice = np.index_exp[i * batch_size:(i + 1) * batch_size]
feed_dict = {
self.states_pl: depths[batch_slice],
self.hand_states_pl: hand_states[batch_slice],
self.is_training_pl: False
}
if zero_sd:
feed_dict[self.state_sd_t] = np.zeros(
(len(depths[batch_slice]), self.num_blocks), dtype=np.float32
)
embedding = self.session.run(self.state_mu_t, feed_dict=feed_dict)
embeddings.append(embedding)
embeddings = np.concatenate(embeddings, axis=0)
return embeddings
def predict_next_states(self, depths, hand_states, actions, batch_size=100, zero_sd=False):
num_steps = int(np.ceil(depths.shape[0] / batch_size))
next_states = []
for i in range(num_steps):
batch_slice = np.index_exp[i * batch_size:(i + 1) * batch_size]
feed_dict = {
self.states_pl: depths[batch_slice],
self.hand_states_pl: hand_states[batch_slice],
self.actions_pl: actions[batch_slice],
self.is_training_pl: False
}
if zero_sd:
feed_dict[self.state_sd_t] = np.zeros(
(len(depths[batch_slice]), self.num_blocks), dtype=np.float32
)
tmp_next_states = self.session.run(self.transformed_logits, feed_dict=feed_dict)
next_states.append(tmp_next_states)
next_states = np.concatenate(next_states, axis=0)
return next_states
def predict_rewards(self, depths, hand_states, actions, batch_size=100, zero_sd=False):
num_steps = int(np.ceil(depths.shape[0] / batch_size))
rewards = []
for i in range(num_steps):
batch_slice = np.index_exp[i * batch_size:(i + 1) * batch_size]
feed_dict = {
self.states_pl: depths[batch_slice],
self.hand_states_pl: hand_states[batch_slice],
self.actions_pl: actions[batch_slice],
self.is_training_pl: False
}
if zero_sd:
feed_dict[self.state_sd_t] = np.zeros(
(len(depths[batch_slice]), self.num_blocks), dtype=np.float32
)
tmp_rewards = self.session.run(self.reward_prediction_t, feed_dict=feed_dict)
rewards.append(tmp_rewards)
rewards = np.concatenate(rewards, axis=0)
return rewards
def validate(self, depths, hand_states, actions, rewards, next_depths, next_hand_states, dones, batch_size=100):
num_steps = int(np.ceil(depths.shape[0] / batch_size))
losses = []
for i in range(num_steps):
batch_slice = np.index_exp[i * batch_size:(i + 1) * batch_size]
feed_dict = {
self.states_pl: depths[batch_slice],
self.hand_states_pl: hand_states[:, np.newaxis][batch_slice],
self.actions_pl: actions[batch_slice],
self.rewards_pl: rewards[batch_slice],
self.next_states_pl: next_depths[batch_slice],
self.next_hand_states_pl: next_hand_states[:, np.newaxis][batch_slice],
self.dones_pl: dones[batch_slice],
self.is_training_pl: False
}
l1, l2 = self.session.run([self.full_transition_loss_t, self.full_reward_loss_t], feed_dict=feed_dict)
losses.append(np.transpose(np.array([l1, l2]), axes=(1, 0)))
losses = np.concatenate(losses, axis=0)
return losses
def validate_and_encode(self, depths, hand_states, actions, rewards, next_depths, next_hand_states, dones,
batch_size=100):
num_steps = int(np.ceil(depths.shape[0] / batch_size))
losses = []
embeddings = []
for i in range(num_steps):
batch_slice = np.index_exp[i * batch_size:(i + 1) * batch_size]
feed_dict = {
self.states_pl: depths[batch_slice],
self.hand_states_pl: hand_states[:, np.newaxis][batch_slice],
self.actions_pl: actions[batch_slice],
self.rewards_pl: rewards[batch_slice],
self.next_states_pl: next_depths[batch_slice],
self.next_hand_states_pl: next_hand_states[:, np.newaxis][batch_slice],
self.dones_pl: dones[batch_slice],
self.is_training_pl: False
}
tmp_embeddings, l1, l2 = self.session.run([
self.state_mu_t, self.full_transition_loss_t, self.full_reward_loss_t], feed_dict=feed_dict
)
losses.append(np.transpose(np.array([l1, l2]), axes=(1, 0)))
embeddings.append(tmp_embeddings)
losses = np.concatenate(losses, axis=0)
embeddings = np.concatenate(embeddings)
return losses, embeddings
def build(self):
self.build_placeholders()
self.build_model()
self.build_training()
self.saver = tf.train.Saver()
def build_placeholders(self):
self.states_pl = tf.placeholder(tf.float32, shape=(None, *self.input_shape), name="states_pl")
self.actions_pl = tf.placeholder(tf.int32, shape=(None,), name="actions_pl")
self.rewards_pl = tf.placeholder(tf.float32, shape=(None,), name="rewards_pl")
self.dones_pl = tf.placeholder(tf.bool, shape=(None,), name="dones_pl")
self.next_states_pl = tf.placeholder(tf.float32, shape=(None, *self.input_shape), name="next_states_pl")
self.is_training_pl = tf.placeholder(tf.bool, shape=[], name="is_training_pl")
self.hand_states_pl = tf.placeholder(tf.float32, shape=(None, 1), name="hand_states_pl")
self.next_hand_states_pl = tf.placeholder(tf.float32, shape=(None, 1), name="next_hand_states_pl")
def build_model(self):
self.state_mu_t, self.state_var_t, self.state_sd_t, self.state_sample_t = \
self.build_encoder(self.states_pl, self.hand_states_pl)
if self.target_network:
self.next_state_mu_t, self.next_state_var_t, self.next_state_sd_t, self.next_state_sample_t = self.build_encoder(
self.next_states_pl, self.next_hand_states_pl, share_weights=False,
namespace=self.TARGET_ENCODER_NAMESPACE
)
self.build_target_update()
else:
self.next_state_mu_t, self.next_state_var_t, self.next_state_sd_t, self.next_state_sample_t = self.build_encoder(
self.next_states_pl, self.next_hand_states_pl, share_weights=True
)
self.r_v = tf.get_variable(
"reward_matrix", shape=(self.num_actions, self.num_blocks), dtype=tf.float32,
initializer=tf.random_normal_initializer(mean=0, stddev=np.sqrt(2 / self.num_blocks), dtype=tf.float32)
)
self.t_v = tf.get_variable(
"transition_matrix", shape=(self.num_actions, self.num_blocks, self.num_blocks), dtype=tf.float32,
initializer=tf.random_normal_initializer(mean=0, stddev=np.sqrt(2 / self.num_blocks), dtype=tf.float32)
)
def build_training(self):
# create global training step variable
self.global_step = tf.train.get_or_create_global_step()
self.float_dones_t = tf.cast(self.dones_pl, tf.float32)
# gather appropriate transition matrices
self.gather_r_t = tf.gather(self.r_v, self.actions_pl)
self.gather_t_t = tf.gather(self.t_v, self.actions_pl)
# build losses
self.build_reward_loss()
self.build_transition_loss()
self.build_weight_decay_loss()
self.build_kl_loss()
# build the whole loss
self.gamma_v = tf.Variable(initial_value=self.gamma, trainable=False)
self.loss_t = self.reward_loss_t + tf.stop_gradient(self.gamma_v) * self.transition_loss_t + \
self.regularization_loss_t + self.beta * self.kl_loss_t
# build training
self.build_encoder_training()
self.build_r_model_training()
self.build_t_model_training()
self.model_train_step = tf.group(self.r_step, self.t_step)
self.train_step = tf.group(self.encoder_train_step, self.model_train_step)
def build_reward_loss(self):
self.reward_prediction_t = tf.reduce_sum(self.state_sample_t * self.gather_r_t, axis=1)
term1 = tf.square(
self.rewards_pl - self.reward_prediction_t
)
self.full_reward_loss_t = (1 / 2) * term1
self.reward_loss_t = tf.reduce_mean(self.full_reward_loss_t, axis=0)
def build_transition_loss(self):
self.transformed_logits = tf.matmul(self.state_sample_t[:, tf.newaxis, :], self.gather_t_t)
self.transformed_logits = self.transformed_logits[:, 0, :]
if self.propagate_next_state:
term1 = tf.reduce_sum(tf.square(self.next_state_sample_t - self.transformed_logits), axis=1)
else:
term1 = tf.reduce_sum(tf.square(tf.stop_gradient(self.next_state_sample_t) - self.transformed_logits),
axis=1)
self.full_transition_loss_t = (1 / 2) * term1 * (1 - self.float_dones_t)
self.transition_loss_t = tf.reduce_sum(self.full_transition_loss_t, axis=0) / tf.reduce_max(
[1.0, tf.reduce_sum(1 - self.float_dones_t)])
def build_weight_decay_loss(self):
reg = tf.get_collection(tf.GraphKeys.REGULARIZATION_LOSSES)
if len(reg) > 0:
self.regularization_loss_t = tf.add_n(reg)
else:
self.regularization_loss_t = 0
def build_kl_loss(self):
self.kl_loss_t = 0.0
if self.beta is not None and self.beta > 0.0:
self.kl_divergence_t = 0.5 * (
tf.square(self.state_mu_t) + self.state_var_t - tf.log(self.state_var_t + 1e-5) - 1.0)
self.kl_loss_t = tf.reduce_mean(tf.reduce_sum(self.kl_divergence_t, axis=1))
def build_encoder_training(self):
encoder_variables = tf.get_collection(tf.GraphKeys.TRAINABLE_VARIABLES, scope=self.ENCODER_NAMESPACE)
encoder_optimizer = agent_utils.get_optimizer(self.optimizer_encoder, self.learning_rate_encoder)
self.encoder_train_step = encoder_optimizer.minimize(
self.loss_t, global_step=self.global_step, var_list=encoder_variables
)
if self.batch_norm:
self.update_op = tf.group(*tf.get_collection(tf.GraphKeys.UPDATE_OPS))
self.encoder_train_step = tf.group(self.encoder_train_step, self.update_op)
def build_r_model_training(self):
r_optimizer = agent_utils.get_optimizer(self.optimizer_model, self.learning_rate_r)
self.r_step = r_optimizer.minimize(
self.reward_loss_t, var_list=[self.r_v]
)
def build_t_model_training(self):
t_optimizer = agent_utils.get_optimizer(self.optimizer_model, self.learning_rate_t)
self.t_step = t_optimizer.minimize(
self.transition_loss_t, var_list=[self.t_v]
)
def build_encoder(self, depth_pl, hand_state_pl, share_weights=False, namespace=ENCODER_NAMESPACE):
if len(depth_pl.shape) == 3:
x = tf.expand_dims(depth_pl, axis=-1)
elif len(depth_pl.shape) != 4:
raise ValueError("Weird depth shape?")
else:
x = depth_pl
with tf.variable_scope(namespace, reuse=share_weights):
for idx in range(len(self.encoder_filters)):
with tf.variable_scope("conv{:d}".format(idx + 1)):
x = tf.layers.conv2d(
x, self.encoder_filters[idx], self.encoder_filter_sizes[idx], self.encoder_strides[idx],
padding="SAME", activation=tf.nn.relu if not self.batch_norm else None,
kernel_regularizer=agent_utils.get_weight_regularizer(self.weight_decay),
kernel_initializer=agent_utils.get_mrsa_initializer(),
use_bias=not self.batch_norm
)
if self.batch_norm and idx != len(self.encoder_filters) - 1:
if self.old_bn_settings:
x = tf.layers.batch_normalization(
x, training=self.is_training_pl, trainable=not share_weights, momentum=self.bn_momentum
)
else:
x = tf.layers.batch_normalization(
x, training=self.is_training_pl if not share_weights else False,
trainable=not share_weights, momentum=self.bn_momentum
)
x = tf.nn.relu(x)
x = tf.layers.flatten(x)
if self.batch_norm:
if self.old_bn_settings:
x = tf.layers.batch_normalization(
x, training=self.is_training_pl, trainable=not share_weights, momentum=self.bn_momentum
)
else:
x = tf.layers.batch_normalization(
x, training=self.is_training_pl if not share_weights else False,
trainable=not share_weights, momentum=self.bn_momentum
)
x = tf.nn.relu(x)
x = tf.concat([x, hand_state_pl], axis=1)
for idx, neurons in enumerate(self.encoder_neurons):
with tf.variable_scope("fc{:d}".format(idx + 1)):
x = tf.layers.dense(
x, neurons, activation=tf.nn.relu if not self.batch_norm else None,
kernel_regularizer=agent_utils.get_weight_regularizer(self.weight_decay),
kernel_initializer=agent_utils.get_mrsa_initializer(),
use_bias=not self.batch_norm
)
if self.batch_norm:
if self.old_bn_settings:
x = tf.layers.batch_normalization(
x, training=self.is_training_pl, trainable=not share_weights, momentum=self.bn_momentum
)
else:
x = tf.layers.batch_normalization(
x, training=self.is_training_pl if not share_weights else False,
trainable=not share_weights, momentum=self.bn_momentum
)
x = tf.nn.relu(x)
with tf.variable_scope("predict"):
mu = tf.layers.dense(
x, self.num_blocks, activation=None,
kernel_regularizer=agent_utils.get_weight_regularizer(self.weight_decay),
kernel_initializer=agent_utils.get_mrsa_initializer()
)
sigma = tf.layers.dense(
x, self.num_blocks, activation=None,
kernel_regularizer=agent_utils.get_weight_regularizer(self.weight_decay),
kernel_initializer=agent_utils.get_mrsa_initializer()
)
if self.no_sample:
sample = mu
var_t = None
else:
noise = tf.random_normal(
shape=(tf.shape(mu)[0], self.num_blocks), mean=0, stddev=1.0
)
if self.softplus:
# log var is sd
sd = tf.nn.softplus(sigma)
if self.zero_embedding_variance:
sd = sd * 0.0
sd_noise_t = noise * sd
sample = mu + sd_noise_t
var_t = tf.square(sd)
else:
var_t = tf.exp(sigma)
if self.zero_embedding_variance:
var_t = var_t * 0.0
sd = tf.sqrt(var_t)
sd_noise_t = noise * sd
sample = mu + sd_noise_t
return mu, var_t, sd, sample
def build_target_update(self):
source_vars = tf.get_collection(tf.GraphKeys.GLOBAL_VARIABLES, scope=self.ENCODER_NAMESPACE)
target_vars = tf.get_collection(tf.GraphKeys.GLOBAL_VARIABLES, scope=self.TARGET_ENCODER_NAMESPACE)
assert len(source_vars) == len(target_vars) and len(source_vars) > 0
update_ops = []
for source_var, target_var in zip(source_vars, target_vars):
update_ops.append(tf.assign(target_var, source_var))
self.target_update_op = tf.group(*update_ops)
def build_summaries(self):
# losses
tf.summary.scalar("loss", self.loss_t)
tf.summary.scalar("transition_loss", tf.reduce_mean(self.transition_loss_t))
tf.summary.scalar("reward_loss", tf.reduce_mean(self.reward_loss_t))
# logits and softmax
self.summarize(self.state_mu_t, "means")
self.summarize(self.state_var_t, "vars")
self.summarize(self.state_sample_t, "samples")
# matrices
self.summarize(self.r_v, "R")
self.summarize(self.t_v, "T")
def set_gamma(self, value):
self.session.run(tf.assign(self.gamma_v, value))
def start_session(self, gpu_memory=None):
gpu_options = None
if gpu_memory is not None:
gpu_options = tf.GPUOptions(per_process_gpu_memory_fraction=gpu_memory)
tf_config = tf.ConfigProto(gpu_options=gpu_options)
self.session = tf.Session(config=tf_config)
self.session.run(tf.global_variables_initializer())
def stop_session(self):
if self.session is not None:
self.session.close()
def load(self, path):
self.saver.restore(self.session, path)
def save(self, path):
path_dir = os.path.dirname(path)
if len(path_dir) > 0 and not os.path.isdir(path_dir):
os.makedirs(path_dir)
self.saver.save(self.session, path)
def save_matrices_as_images(self, step, save_dir, ext="pdf"):
r, p = self.session.run([self.r_v, self.t_v])
r = np.reshape(r, (r.shape[0], -1))
p = np.reshape(p, (p.shape[0], -1))
r_path = os.path.join(save_dir, "r_{:d}.{}".format(step, ext))
p_path = os.path.join(save_dir, "p_{:d}.{}".format(step, ext))
plt.clf()
plt.imshow(r, vmin=-0.5, vmax=1.5)
plt.colorbar()
plt.savefig(r_path)
plt.clf()
plt.imshow(p, vmin=0, vmax=1)
plt.colorbar()
plt.savefig(p_path)
def summarize(self, var, name):
tf.summary.scalar(name + "_mean", tf.reduce_mean(var))
tf.summary.scalar(name + "_min", tf.reduce_min(var))
tf.summary.scalar(name + "_max", tf.reduce_max(var))
tf.summary.histogram(name + "_hist", var)
class ExpectationModelVQ(ExpectationModelContinuous):
def __init__(self, input_shape, num_embeddings, dimensionality, num_actions, encoder_filters, encoder_filter_sizes,
encoder_strides, encoder_neurons, learning_rate_encoder, learning_rate_r, learning_rate_t,
weight_decay, gamma_1, optimizer_encoder, optimizer_model,
max_steps, batch_norm=True, target_network=True, propagate_next_state=False, no_sample=False,
softplus=False, alpha=0.1, beta=0.0):
ExpectationModelContinuous.__init__(
self, input_shape, dimensionality, num_actions, encoder_filters, encoder_filter_sizes, encoder_strides,
encoder_neurons, learning_rate_encoder, learning_rate_r, learning_rate_t, weight_decay, gamma_1,
optimizer_encoder, optimizer_model, max_steps, batch_norm=batch_norm, target_network=target_network,
propagate_next_state=propagate_next_state, no_sample=no_sample, softplus=softplus, beta=beta
)
self.num_embeddings = num_embeddings
self.dimensionality = dimensionality
self.aplha = alpha
def build_model(self):
self.state_mu_t = \
self.build_encoder(self.states_pl, self.hand_states_pl, namespace=self.ENCODER_NAMESPACE)
self.embeds = tf.get_variable(
"embeddings", [self.num_embeddings, self.dimensionality],
initializer=tf.truncated_normal_initializer(stddev=0.02)
)
self.state_sample_t, self.state_classes_t = self.quantize(self.state_mu_t)
if self.target_network:
self.next_state_mu_t = self.build_encoder(
self.next_states_pl, self.next_hand_states_pl, share_weights=False,
namespace=self.TARGET_ENCODER_NAMESPACE
)
self.build_target_update()
else:
self.next_state_mu_t = self.build_encoder(
self.next_states_pl, self.next_hand_states_pl, share_weights=True, namespace=self.ENCODER_NAMESPACE
)
self.next_state_sample_t, self.next_state_classes_t = self.quantize(self.next_state_mu_t)
self.r_v = tf.get_variable(
"reward_matrix", shape=(self.num_actions, self.dimensionality), dtype=tf.float32,
initializer=tf.random_normal_initializer(mean=0, stddev=np.sqrt(2 / self.dimensionality), dtype=tf.float32)
)
self.t_v = tf.get_variable(
"transition_matrix", shape=(self.num_actions, self.dimensionality, self.dimensionality), dtype=tf.float32,
initializer=tf.random_normal_initializer(mean=0, stddev=np.sqrt(2 / self.dimensionality), dtype=tf.float32)
)
def quantize(self, prediction):
diff = prediction[:, tf.newaxis, :] - self.embeds[tf.newaxis, :, :]
norm = tf.norm(diff, axis=2)
classes = tf.argmin(norm, axis=1)
return tf.gather(self.embeds, classes), classes
def build_training(self):
# create global training step variable
self.global_step = tf.train.get_or_create_global_step()
self.float_dones_t = tf.cast(self.dones_pl, tf.float32)
# gather appropriate transition matrices
self.gather_r_t = tf.gather(self.r_v, self.actions_pl)
self.gather_t_t = tf.gather(self.t_v, self.actions_pl)
# build losses
self.build_reward_loss()
self.build_transition_loss()
self.build_left_and_right_embedding_losses()
self.build_weight_decay_loss()
# build the whole loss
self.gamma_v = tf.Variable(initial_value=self.gamma, trainable=False)
self.main_loss_t = self.reward_loss_t + tf.stop_gradient(self.gamma_v) * self.transition_loss_t + \
self.regularization_loss_t
self.loss_t = self.main_loss_t + self.right_loss_t
# build training
self.build_encoder_and_embedding_training()
self.build_r_model_training()
self.build_t_model_training()
self.model_train_step = tf.group(self.r_step, self.t_step)
self.train_step = tf.group(self.encoder_train_step, self.model_train_step)
def build_left_and_right_embedding_losses(self):
self.left_loss_t = tf.reduce_mean(
tf.norm(tf.stop_gradient(self.state_mu_t) - self.state_sample_t, axis=1) ** 2
)
self.right_loss_t = tf.reduce_mean(
tf.norm(self.state_mu_t - tf.stop_gradient(self.state_sample_t), axis=1) ** 2
)
def build_reward_loss(self):
self.reward_prediction_t = tf.reduce_sum(self.state_sample_t * self.gather_r_t, axis=1)
term1 = tf.square(
self.rewards_pl - self.reward_prediction_t
)
self.full_reward_loss_t = (1 / 2) * term1
self.reward_loss_t = tf.reduce_mean(self.full_reward_loss_t, axis=0)
def build_transition_loss(self):
self.transformed_logits = tf.matmul(self.state_sample_t[:, tf.newaxis, :], self.gather_t_t)
self.transformed_logits = self.transformed_logits[:, 0, :]
if self.propagate_next_state:
term1 = tf.reduce_mean(tf.square(self.next_state_sample_t - self.transformed_logits), axis=1)
else:
term1 = tf.reduce_mean(tf.square(tf.stop_gradient(self.next_state_sample_t) - self.transformed_logits),
axis=1)
self.full_transition_loss_t = (1 / 2) * term1 * (1 - self.float_dones_t)
self.transition_loss_t = tf.reduce_sum(self.full_transition_loss_t, axis=0) / tf.reduce_max(
[1.0, tf.reduce_sum(1 - self.float_dones_t)])
def build_encoder_and_embedding_training(self):
encoder_variables = tf.get_collection(tf.GraphKeys.TRAINABLE_VARIABLES, scope=self.ENCODER_NAMESPACE)
encoder_optimizer = agent_utils.get_optimizer(self.optimizer_encoder, self.learning_rate_encoder)
grad_z = tf.gradients(self.main_loss_t, self.state_sample_t)
encoder_grads = [(tf.gradients(self.state_mu_t, var, grad_z)[0] + self.aplha *
tf.gradients(self.right_loss_t, var)[0], var) for var in encoder_variables]
embed_grads = list(zip(tf.gradients(self.left_loss_t, self.embeds), [self.embeds]))
self.encoder_train_step = encoder_optimizer.apply_gradients(
encoder_grads + embed_grads
)
if self.batch_norm:
self.update_op = tf.group(*tf.get_collection(tf.GraphKeys.UPDATE_OPS))
self.encoder_train_step = tf.group(self.encoder_train_step, self.update_op)
def build_encoder(self, depth_pl, hand_state_pl, share_weights=False, namespace=None):
x = tf.expand_dims(depth_pl, axis=-1)
with tf.variable_scope(namespace, reuse=share_weights):
for idx in range(len(self.encoder_filters)):
with tf.variable_scope("conv{:d}".format(idx + 1)):
x = tf.layers.conv2d(
x, self.encoder_filters[idx], self.encoder_filter_sizes[idx], self.encoder_strides[idx],
padding="SAME", activation=tf.nn.relu if not self.batch_norm else None,
kernel_regularizer=agent_utils.get_weight_regularizer(self.weight_decay),
kernel_initializer=agent_utils.get_mrsa_initializer(),
use_bias=not self.batch_norm
)
if self.batch_norm and idx != len(self.encoder_filters) - 1:
x = tf.layers.batch_normalization(x, training=self.is_training_pl)
x = tf.nn.relu(x)
x = tf.layers.flatten(x)
if self.batch_norm:
x = tf.layers.batch_normalization(x, training=self.is_training_pl)
x = tf.nn.relu(x)
x = tf.concat([x, hand_state_pl], axis=1)
for idx, neurons in enumerate(self.encoder_neurons):
with tf.variable_scope("fc{:d}".format(idx + 1)):
x = tf.layers.dense(
x, neurons, activation=tf.nn.relu if not self.batch_norm else None,
kernel_regularizer=agent_utils.get_weight_regularizer(self.weight_decay),
kernel_initializer=agent_utils.get_mrsa_initializer(),
use_bias=not self.batch_norm
)
if self.batch_norm:
x = tf.layers.batch_normalization(x, training=self.is_training_pl)
x = tf.nn.relu(x)
with tf.variable_scope("predict"):
mu = tf.layers.dense(
x, self.num_blocks, activation=None,
kernel_regularizer=agent_utils.get_weight_regularizer(self.weight_decay),
kernel_initializer=agent_utils.get_mrsa_initializer()
)
return mu
class ExpectationModelContinuousNNTransitions(ExpectationModelContinuous):
def __init__(self, input_shape, num_blocks, num_actions, encoder_filters, encoder_filter_sizes,
encoder_strides, encoder_neurons, learning_rate_encoder, learning_rate_r, learning_rate_t,
transition_neurons, weight_decay, gamma_1, optimizer_encoder, optimizer_model,
max_steps, batch_norm=True, target_network=True, propagate_next_state=False, no_sample=False,
softplus=False, beta=0.0):
ExpectationModelContinuous.__init__(
self, input_shape, num_blocks, num_actions, encoder_filters, encoder_filter_sizes, encoder_strides,
encoder_neurons, learning_rate_encoder, learning_rate_r, learning_rate_t, weight_decay, gamma_1,
optimizer_encoder, optimizer_model, max_steps, batch_norm=batch_norm, target_network=target_network,
propagate_next_state=propagate_next_state, no_sample=no_sample, softplus=softplus, beta=beta
)
self.transition_neurons = transition_neurons
def build_model(self):
# TODO: throw out t_v; either accept mu_t or sample_t
self.state_mu_t, self.state_var_t, self.state_sd_t, self.state_sample_t = \
self.build_encoder(self.states_pl, self.hand_states_pl)
if self.target_network:
self.next_state_mu_t, self.next_state_var_t, self.next_state_sd_t, self.next_state_sample_t = self.build_encoder(
self.next_states_pl, self.next_hand_states_pl, share_weights=False,
namespace=self.TARGET_ENCODER_NAMESPACE
)
self.build_target_update()
else:
self.next_state_mu_t, self.next_state_var_t, self.next_state_sd_t, self.next_state_sample_t = self.build_encoder(
self.next_states_pl, self.next_hand_states_pl, share_weights=True
)
self.r_v = tf.get_variable(
"reward_matrix", shape=(self.num_actions, self.num_blocks), dtype=tf.float32,
initializer=tf.random_normal_initializer(mean=0, stddev=np.sqrt(2 / self.num_blocks), dtype=tf.float32)
)
self.t_v = tf.get_variable(
"transition_matrix", shape=(self.num_actions, self.num_blocks, self.num_blocks), dtype=tf.float32,
initializer=tf.random_normal_initializer(mean=0, stddev=np.sqrt(2 / self.num_blocks), dtype=tf.float32)
)
def build_transition_nn(self, embedding):
# TODO: needs to accept actions as well
x = embedding
with tf.variable_scope("transition"):
for idx, neurons in enumerate(self.transition_neurons):
with tf.variable_scope("fc{:d}".format(idx)):
if idx == len(self.transition_neurons) - 1:
x = tf.layers.dense(
x, neurons, activation=None,
kernel_regularizer=agent_utils.get_weight_regularizer(self.weight_decay),
kernel_initializer=agent_utils.get_mrsa_initializer()
)
else:
x = tf.layers.dense(
x, neurons, activation=tf.nn.relu if not self.batch_norm else None,
kernel_regularizer=agent_utils.get_weight_regularizer(self.weight_decay),
kernel_initializer=agent_utils.get_mrsa_initializer(),
use_bias=not self.batch_norm
)
if self.batch_norm:
x = tf.layers.batch_normalization(x, training=self.is_training_pl)
x = tf.nn.relu(x)
assert embedding.shape[1] == x.shape[1]
return x
class ExpectationModelContinuousWithQ(ExpectationModelContinuous):
def __init__(self, input_shape, num_blocks, num_actions, encoder_filters, encoder_filter_sizes,
encoder_strides, encoder_neurons, learning_rate_encoder, learning_rate_r, learning_rate_t,
learning_rate_q, weight_decay, gamma_1, gamma_2, optimizer_encoder, optimizer_model,
max_steps, batch_norm=True, target_network=True, propagate_next_state=False, no_sample=False,
softplus=False, beta=0.0, old_bn_settings=False, bn_momentum=0.99):
ExpectationModelContinuous.__init__(
self, input_shape, num_blocks, num_actions, encoder_filters, encoder_filter_sizes, encoder_strides,
encoder_neurons, learning_rate_encoder, learning_rate_r, learning_rate_t, weight_decay, gamma_1,
optimizer_encoder, optimizer_model, max_steps, batch_norm=batch_norm, target_network=target_network,
propagate_next_state=propagate_next_state, no_sample=no_sample, softplus=softplus, beta=beta,
old_bn_settings=old_bn_settings, bn_momentum=bn_momentum
)
self.gamma_2 = gamma_2
self.learning_rate_q = learning_rate_q
def validate(self, depths, hand_states, actions, rewards, q_values, next_depths, next_hand_states, dones,
batch_size=100):
num_steps = int(np.ceil(depths.shape[0] / batch_size))
losses = []
for i in range(num_steps):
batch_slice = np.index_exp[i * batch_size:(i + 1) * batch_size]
feed_dict = {
self.states_pl: depths[batch_slice],
self.hand_states_pl: hand_states[:, np.newaxis][batch_slice],
self.actions_pl: actions[batch_slice],
self.rewards_pl: rewards[batch_slice],
self.q_values_pl: q_values[batch_slice],
self.next_states_pl: next_depths[batch_slice],
self.next_hand_states_pl: next_hand_states[:, np.newaxis][batch_slice],
self.dones_pl: dones[batch_slice],
self.is_training_pl: False
}
l1, l2, l3 = self.session.run(
[self.full_q_loss_t, self.full_transition_loss_t, self.full_reward_loss_t], feed_dict=feed_dict
)
losses.append(np.transpose(np.array([l1, l2, l3]), axes=(1, 0)))
losses = np.concatenate(losses, axis=0)
return losses
def validate_and_encode(self, depths, hand_states, actions, rewards, q_values, next_depths, next_hand_states, dones,
batch_size=100):
num_steps = int(np.ceil(depths.shape[0] / batch_size))
losses = []
embeddings = []
for i in range(num_steps):
batch_slice = np.index_exp[i * batch_size:(i + 1) * batch_size]
feed_dict = {
self.states_pl: depths[batch_slice],
self.hand_states_pl: hand_states[:, np.newaxis][batch_slice],
self.actions_pl: actions[batch_slice],
self.rewards_pl: rewards[batch_slice],
self.q_values_pl: q_values[batch_slice],
self.next_states_pl: next_depths[batch_slice],
self.next_hand_states_pl: next_hand_states[:, np.newaxis][batch_slice],
self.dones_pl: dones[batch_slice],
self.is_training_pl: False
}
tmp_embeddings, l1, l2, l3 = self.session.run([
self.state_mu_t, self.full_q_loss_t, self.full_transition_loss_t, self.full_reward_loss_t],
feed_dict=feed_dict
)
losses.append(np.transpose(np.array([l1, l2, l3]), axes=(1, 0)))
embeddings.append(tmp_embeddings)
losses = np.concatenate(losses, axis=0)
embeddings = np.concatenate(embeddings)
return losses, embeddings
def build_placeholders(self):
self.states_pl = tf.placeholder(tf.float32, shape=(None, *self.input_shape), name="states_pl")
self.actions_pl = tf.placeholder(tf.int32, shape=(None,), name="actions_pl")
self.rewards_pl = tf.placeholder(tf.float32, shape=(None,), name="rewards_pl")
self.q_values_pl = tf.placeholder(tf.float32, shape=(None, self.num_actions), name="q_values_pl")
self.dones_pl = tf.placeholder(tf.bool, shape=(None,), name="dones_pl")
self.next_states_pl = tf.placeholder(tf.float32, shape=(None, *self.input_shape), name="next_states_pl")
self.is_training_pl = tf.placeholder(tf.bool, shape=[], name="is_training_pl")
self.hand_states_pl = tf.placeholder(tf.float32, shape=(None, 1), name="hand_states_pl")
self.next_hand_states_pl = tf.placeholder(tf.float32, shape=(None, 1), name="next_hand_states_pl")
def build_model(self):
self.build_encoders()
self.build_linear_models()
def build_encoders(self):
self.state_mu_t, self.state_var_t, self.state_sd_t, self.state_sample_t = \
self.build_encoder(self.states_pl, self.hand_states_pl)
if self.target_network:
self.next_state_mu_t, self.next_state_var_t, self.next_state_sd_t, self.next_state_sample_t = self.build_encoder(
self.next_states_pl, self.next_hand_states_pl, share_weights=False,
namespace=self.TARGET_ENCODER_NAMESPACE
)
self.build_target_update()
else:
self.next_state_mu_t, self.next_state_var_t, self.next_state_sd_t, self.next_state_sample_t = self.build_encoder(
self.next_states_pl, self.next_hand_states_pl, share_weights=True
)
def build_linear_models(self):
self.q_v = tf.get_variable(
"q_values_matrix", shape=(self.num_actions, self.num_blocks), dtype=tf.float32,
initializer=tf.random_normal_initializer(mean=0, stddev=np.sqrt(2 / self.num_blocks), dtype=tf.float32)
)
self.r_v = tf.get_variable(
"reward_matrix", shape=(self.num_actions, self.num_blocks), dtype=tf.float32,
initializer=tf.random_normal_initializer(mean=0, stddev=np.sqrt(2 / self.num_blocks), dtype=tf.float32)
)
self.t_v = tf.get_variable(
"transition_matrix", shape=(self.num_actions, self.num_blocks, self.num_blocks), dtype=tf.float32,
initializer=tf.random_normal_initializer(mean=0, stddev=np.sqrt(2 / self.num_blocks), dtype=tf.float32)
)
def build_training(self):
# create global training step variable
self.global_step = tf.train.get_or_create_global_step()
self.float_dones_t = tf.cast(self.dones_pl, tf.float32)
# gather appropriate transition matrices
self.gather_r_t = tf.gather(self.r_v, self.actions_pl)
self.gather_t_t = tf.gather(self.t_v, self.actions_pl)
# build losses
self.build_q_loss()
self.build_reward_loss()
self.build_transition_loss()
self.build_weight_decay_loss()
self.build_kl_loss()
# build the whole loss
self.gamma_v = tf.Variable(initial_value=self.gamma, trainable=False)
self.loss_t = self.q_loss_t + self.gamma_2 * self.reward_loss_t + \
tf.stop_gradient(self.gamma_v) * self.transition_loss_t + \
self.regularization_loss_t + self.beta * self.kl_loss_t
# build training
self.build_encoder_training()
self.build_q_model_training()
self.build_r_model_training()
self.build_t_model_training()
self.model_train_step = tf.group(self.q_step, self.r_step, self.t_step)
self.train_step = tf.group(self.encoder_train_step, self.model_train_step)
def build_q_loss(self):
self.q_prediction_t = tf.reduce_sum(self.state_sample_t[:, tf.newaxis, :] * self.q_v[tf.newaxis, :, :], axis=2)
term1 = tf.reduce_mean(tf.square(self.q_values_pl - self.q_prediction_t), axis=1)
self.full_q_loss_t = (1 / 2) * term1
self.q_loss_t = tf.reduce_mean(self.full_q_loss_t, axis=0)
def build_q_model_training(self):
q_optimizer = agent_utils.get_optimizer(self.optimizer_model, self.learning_rate_q)
self.q_step = q_optimizer.minimize(
self.q_loss_t, var_list=[self.q_v]
)
class ExpectationModelVQWithQ(ExpectationModelVQ):
def __init__(self, input_shape, num_blocks, dimensionality, num_actions, encoder_filters, encoder_filter_sizes,
encoder_strides, encoder_neurons, learning_rate_encoder, learning_rate_r, learning_rate_t,
learning_rate_q, weight_decay, gamma_1, gamma_2, optimizer_encoder, optimizer_model,
max_steps, batch_norm=True, target_network=True, propagate_next_state=False, no_sample=False,
softplus=False, alpha=0.1, beta=0.0):
ExpectationModelVQ.__init__(
self, input_shape, num_blocks, dimensionality, num_actions, encoder_filters, encoder_filter_sizes,
encoder_strides, encoder_neurons, learning_rate_encoder, learning_rate_r, learning_rate_t, weight_decay,
gamma_1, optimizer_encoder, optimizer_model, max_steps, batch_norm=batch_norm,
target_network=target_network, propagate_next_state=propagate_next_state, no_sample=no_sample,
softplus=softplus, alpha=alpha, beta=beta
)
self.gamma_2 = gamma_2
self.learning_rate_q = learning_rate_q
def validate(self, depths, hand_states, actions, rewards, q_values, next_depths, next_hand_states, dones,
batch_size=100):
num_steps = int(np.ceil(depths.shape[0] / batch_size))
losses = []
for i in range(num_steps):
batch_slice = np.index_exp[i * batch_size:(i + 1) * batch_size]
feed_dict = {
self.states_pl: depths[batch_slice],
self.hand_states_pl: hand_states[:, np.newaxis][batch_slice],
self.actions_pl: actions[batch_slice],
self.rewards_pl: rewards[batch_slice],
self.q_values_pl: q_values[batch_slice],
self.next_states_pl: next_depths[batch_slice],
self.next_hand_states_pl: next_hand_states[:, np.newaxis][batch_slice],
self.dones_pl: dones[batch_slice],
self.is_training_pl: False
}
l1, l2, l3 = self.session.run(
[self.full_q_loss_t, self.full_transition_loss_t, self.full_reward_loss_t], feed_dict=feed_dict
)
losses.append(np.transpose(np.array([l1, l2, l3]), axes=(1, 0)))
losses = np.concatenate(losses, axis=0)
return losses
def validate_and_encode(self, depths, hand_states, actions, rewards, q_values, next_depths, next_hand_states, dones,
batch_size=100):
num_steps = int(np.ceil(depths.shape[0] / batch_size))
losses = []
embeddings = []
for i in range(num_steps):
batch_slice = np.index_exp[i * batch_size:(i + 1) * batch_size]
feed_dict = {
self.states_pl: depths[batch_slice],
self.hand_states_pl: hand_states[:, np.newaxis][batch_slice],
self.actions_pl: actions[batch_slice],
self.rewards_pl: rewards[batch_slice],
self.q_values_pl: q_values[batch_slice],
self.next_states_pl: next_depths[batch_slice],
self.next_hand_states_pl: next_hand_states[:, np.newaxis][batch_slice],
self.dones_pl: dones[batch_slice],
self.is_training_pl: False
}
tmp_embeddings, l1, l2, l3 = self.session.run([
self.state_mu_t, self.full_q_loss_t, self.full_transition_loss_t, self.full_reward_loss_t],
feed_dict=feed_dict
)
losses.append(np.transpose(np.array([l1, l2, l3]), axes=(1, 0)))
embeddings.append(tmp_embeddings)
losses = np.concatenate(losses, axis=0)
embeddings = np.concatenate(embeddings)
return losses, embeddings
def build_placeholders(self):
self.states_pl = tf.placeholder(tf.float32, shape=(None, *self.input_shape), name="states_pl")
self.actions_pl = tf.placeholder(tf.int32, shape=(None,), name="actions_pl")
self.rewards_pl = tf.placeholder(tf.float32, shape=(None,), name="rewards_pl")
self.q_values_pl = tf.placeholder(tf.float32, shape=(None, self.num_actions), name="q_values_pl")
self.dones_pl = tf.placeholder(tf.bool, shape=(None,), name="dones_pl")
self.next_states_pl = tf.placeholder(tf.float32, shape=(None, *self.input_shape), name="next_states_pl")
self.is_training_pl = tf.placeholder(tf.bool, shape=[], name="is_training_pl")
self.hand_states_pl = tf.placeholder(tf.float32, shape=(None, 1), name="hand_states_pl")
self.next_hand_states_pl = tf.placeholder(tf.float32, shape=(None, 1), name="next_hand_states_pl")
def build_model(self):
self.state_mu_t = \
self.build_encoder(self.states_pl, self.hand_states_pl, namespace=self.ENCODER_NAMESPACE)
self.embeds = tf.get_variable(
"embeddings", [self.num_embeddings, self.dimensionality],
initializer=tf.truncated_normal_initializer(stddev=0.02)
)
self.state_sample_t, self.state_classes_t = self.quantize(self.state_mu_t)
if self.target_network:
self.next_state_mu_t = self.build_encoder(
self.next_states_pl, self.next_hand_states_pl, share_weights=False,
namespace=self.TARGET_ENCODER_NAMESPACE
)
self.build_target_update()
else:
self.next_state_mu_t = self.build_encoder(
self.next_states_pl, self.next_hand_states_pl, share_weights=True, namespace=self.ENCODER_NAMESPACE
)
self.next_state_sample_t, self.next_state_classes_t = self.quantize(self.next_state_mu_t)
self.q_v = tf.get_variable(
"q_values_matrix", shape=(self.num_actions, self.dimensionality), dtype=tf.float32,
initializer=tf.random_normal_initializer(mean=0, stddev=np.sqrt(2 / self.dimensionality), dtype=tf.float32)
)
self.r_v = tf.get_variable(
"reward_matrix", shape=(self.num_actions, self.dimensionality), dtype=tf.float32,
initializer=tf.random_normal_initializer(mean=0, stddev=np.sqrt(2 / self.dimensionality), dtype=tf.float32)
)
self.t_v = tf.get_variable(
"transition_matrix", shape=(self.num_actions, self.dimensionality, self.dimensionality), dtype=tf.float32,
initializer=tf.random_normal_initializer(mean=0, stddev=np.sqrt(2 / self.dimensionality), dtype=tf.float32)
)
def build_training(self):
# create global training step variable
self.global_step = tf.train.get_or_create_global_step()
self.float_dones_t = tf.cast(self.dones_pl, tf.float32)
# gather appropriate transition matrices
self.gather_r_t = tf.gather(self.r_v, self.actions_pl)
self.gather_t_t = tf.gather(self.t_v, self.actions_pl)
# build losses
self.build_q_loss()
self.build_reward_loss()
self.build_transition_loss()
self.build_left_and_right_embedding_losses()
self.build_weight_decay_loss()
# build the whole loss
self.gamma_v = tf.Variable(initial_value=self.gamma, trainable=False)
self.main_loss_t = self.q_loss_t + self.gamma_2 * self.reward_loss_t + \
tf.stop_gradient(self.gamma_v) * self.transition_loss_t + self.regularization_loss_t
self.loss_t = self.main_loss_t + self.right_loss_t
# build training
self.build_encoder_and_embedding_training()
self.build_q_model_training()
self.build_r_model_training()
self.build_t_model_training()
self.model_train_step = tf.group(self.q_step, self.r_step, self.t_step)
self.train_step = tf.group(self.encoder_train_step, self.model_train_step)
def build_q_loss(self):
self.q_prediction_t = tf.reduce_sum(self.state_sample_t[:, tf.newaxis, :] * self.q_v[tf.newaxis, :, :], axis=2)
term1 = tf.reduce_mean(tf.square(self.q_values_pl - self.q_prediction_t), axis=1)
self.full_q_loss_t = (1 / 2) * term1
self.q_loss_t = tf.reduce_mean(self.full_q_loss_t, axis=0)
def build_q_model_training(self):
q_optimizer = agent_utils.get_optimizer(self.optimizer_model, self.learning_rate_q)
self.q_step = q_optimizer.minimize(
self.q_loss_t, var_list=[self.q_v]
)
class ExpectationModelVQWithQNeural(ExpectationModelVQWithQ):
def __init__(self, input_shape, num_blocks, dimensionality, num_actions, encoder_filters, encoder_filter_sizes,
encoder_strides, encoder_neurons, q_neurons, learning_rate_encoder, learning_rate_r, learning_rate_t,
learning_rate_q, weight_decay, gamma_1, gamma_2, optimizer_encoder, optimizer_model,
max_steps, batch_norm=True, target_network=True, propagate_next_state=False, no_sample=False,
softplus=False, alpha=0.1, beta=0.0):
ExpectationModelVQWithQ.__init__(
self, input_shape, num_blocks, dimensionality, num_actions, encoder_filters, encoder_filter_sizes,
encoder_strides, encoder_neurons, learning_rate_encoder, learning_rate_r, learning_rate_t, learning_rate_q,
weight_decay, gamma_1, gamma_2, optimizer_encoder, optimizer_model, max_steps, batch_norm=batch_norm,
target_network=target_network, propagate_next_state=propagate_next_state, no_sample=no_sample,
softplus=softplus, alpha=alpha, beta=beta
)
self.q_neurons = q_neurons
def build_model(self):
self.state_mu_t = \
self.build_encoder(self.states_pl, self.hand_states_pl, namespace=self.ENCODER_NAMESPACE)
self.embeds = tf.get_variable(
"embeddings", [self.num_embeddings, self.dimensionality],
initializer=tf.truncated_normal_initializer(stddev=0.02)
)
self.state_sample_t, self.state_classes_t = self.quantize(self.state_mu_t)
if self.target_network:
self.next_state_mu_t = self.build_encoder(
self.next_states_pl, self.next_hand_states_pl, share_weights=False,
namespace=self.TARGET_ENCODER_NAMESPACE
)
self.build_target_update()
else:
self.next_state_mu_t = self.build_encoder(
self.next_states_pl, self.next_hand_states_pl, share_weights=True, namespace=self.ENCODER_NAMESPACE
)
self.next_state_sample_t, self.next_state_classes_t = self.quantize(self.next_state_mu_t)
self.r_v = tf.get_variable(
"reward_matrix", shape=(self.num_actions, self.dimensionality), dtype=tf.float32,
initializer=tf.random_normal_initializer(mean=0, stddev=np.sqrt(2 / self.dimensionality), dtype=tf.float32)
)
self.t_v = tf.get_variable(
"transition_matrix", shape=(self.num_actions, self.dimensionality, self.dimensionality), dtype=tf.float32,
initializer=tf.random_normal_initializer(mean=0, stddev=np.sqrt(2 / self.dimensionality), dtype=tf.float32)
)
def build_q_loss(self):
self.q_prediction_t = self.build_q_model(self.state_sample_t)
term1 = tf.reduce_mean(tf.square(self.q_values_pl - self.q_prediction_t), axis=1)
self.full_q_loss_t = (1 / 2) * term1
self.q_loss_t = tf.reduce_mean(self.full_q_loss_t, axis=0)
def build_q_model_training(self):
q_optimizer = agent_utils.get_optimizer(self.optimizer_model, self.learning_rate_q)
self.q_step = q_optimizer.minimize(
self.q_loss_t, var_list=tf.get_collection(tf.GraphKeys.GLOBAL_VARIABLES, scope="q_model")
)
def build_q_model(self, embedding):
x = embedding
with tf.variable_scope("q_model"):
for idx, neurons in enumerate(self.q_neurons):
with tf.variable_scope("fc{:d}".format(idx)):
if idx == len(self.q_neurons) - 1:
x = tf.layers.dense(
x, neurons, activation=None,
kernel_regularizer=agent_utils.get_weight_regularizer(self.weight_decay),
kernel_initializer=agent_utils.get_mrsa_initializer()
)
else:
x = tf.layers.dense(
x, neurons, activation=tf.nn.relu if not self.batch_norm else None,
kernel_regularizer=agent_utils.get_weight_regularizer(self.weight_decay),
kernel_initializer=agent_utils.get_mrsa_initializer(),
use_bias=not self.batch_norm
)
if self.batch_norm:
x = tf.layers.batch_normalization(x, training=self.is_training_pl)
x = tf.nn.relu(x)
return x
class ExpectationModelHierarchy:
L1_NAMESPACE = "l1"
L1_TARGET_NAMESPACE = "target_l1"
L2_NAMESPACE = "l2"
L2_TARGET_NAMESPACE = "target_l2"
def __init__(self, input_shape, l1_num_blocks, l2_num_blocks, num_actions, encoder_filters, encoder_filter_sizes,
encoder_strides, encoder_neurons, l1_learning_rate_encoder, l2_learning_rate_encoder, learning_rate_r, learning_rate_t,
weight_decay, gamma, optimizer_encoder, optimizer_model, max_steps, l2_hiddens, batch_norm=True,
target_network=True, propagate_next_state=False, no_sample=False):
if propagate_next_state:
assert not target_network
self.input_shape = input_shape
self.l1_num_blocks = l1_num_blocks
self.l2_num_blocks = l2_num_blocks
self.num_actions = num_actions
self.encoder_filters = encoder_filters
self.encoder_filter_sizes = encoder_filter_sizes
self.encoder_strides = encoder_strides
self.encoder_neurons = encoder_neurons
self.l1_learning_rate_encoder = l1_learning_rate_encoder
self.l2_learning_rate_encoder = l2_learning_rate_encoder
self.learning_rate_r = learning_rate_r
self.learning_rate_t = learning_rate_t
self.weight_decay = weight_decay
self.gamma = gamma
self.optimizer_encoder = optimizer_encoder
self.optimizer_model = optimizer_model
self.max_steps = max_steps
self.l2_hiddens = l2_hiddens
self.batch_norm = batch_norm
self.target_network = target_network
self.propagate_next_state = propagate_next_state
self.no_sample = no_sample
self.hand_states_pl, self.next_hand_states_pl = None, None
def encode(self, depths, hand_states, level, batch_size=100):
num_steps = int(np.ceil(depths.shape[0] / batch_size))
embeddings = []
if level == self.L1_NAMESPACE:
to_run = self.l1_state_mu_t
else:
to_run = self.l2_softmax_t
for i in range(num_steps):
batch_slice = np.index_exp[i * batch_size:(i + 1) * batch_size]
feed_dict = {
self.states_pl: depths[batch_slice],
self.hand_states_pl: hand_states[batch_slice],
self.is_training_pl: False
}
embedding = self.session.run(to_run, feed_dict=feed_dict)
embeddings.append(embedding)
embeddings = np.concatenate(embeddings, axis=0)
return embeddings
def validate(self, depths, hand_states, actions, rewards, next_depths, next_hand_states, dones, level,
batch_size=100):
num_steps = int(np.ceil(depths.shape[0] / batch_size))
losses = []
if level == self.L1_NAMESPACE:
to_run = [self.l1_full_transition_loss_t, self.l1_full_reward_loss_t]
else:
to_run = [self.l2_full_transition_loss_t, self.l2_full_reward_loss_t]
for i in range(num_steps):
batch_slice = np.index_exp[i * batch_size:(i + 1) * batch_size]
feed_dict = {
self.states_pl: depths[batch_slice],
self.hand_states_pl: hand_states[:, np.newaxis][batch_slice],
self.actions_pl: actions[batch_slice],
self.rewards_pl: rewards[batch_slice],
self.next_states_pl: next_depths[batch_slice],
self.next_hand_states_pl: next_hand_states[:, np.newaxis][batch_slice],
self.dones_pl: dones[batch_slice],
self.is_training_pl: False
}
l1, l2 = self.session.run(to_run, feed_dict=feed_dict)
losses.append(np.transpose(np.array([l1, l2]), axes=(1, 0)))
losses = np.concatenate(losses, axis=0)
return losses
def validate_and_encode(self, depths, hand_states, actions, rewards, next_depths, next_hand_states, dones,
level, batch_size=100):
num_steps = int(np.ceil(depths.shape[0] / batch_size))
losses = []
embeddings = []
if level == self.L1_NAMESPACE:
to_run = [self.l1_state_mu_t, self.l1_full_transition_loss_t, self.l1_full_reward_loss_t]
else:
to_run = [self.l2_softmax_t, self.l2_full_transition_loss_t, self.l2_full_reward_loss_t]
for i in range(num_steps):
batch_slice = np.index_exp[i * batch_size:(i + 1) * batch_size]
feed_dict = {
self.states_pl: depths[batch_slice],
self.hand_states_pl: hand_states[:, np.newaxis][batch_slice],
self.actions_pl: actions[batch_slice],
self.rewards_pl: rewards[batch_slice],
self.next_states_pl: next_depths[batch_slice],
self.next_hand_states_pl: next_hand_states[:, np.newaxis][batch_slice],
self.dones_pl: dones[batch_slice],
self.is_training_pl: False
}
tmp_embeddings, l1, l2 = self.session.run(to_run, feed_dict=feed_dict)
losses.append(np.transpose(np.array([l1, l2]), axes=(1, 0)))
embeddings.append(tmp_embeddings)
losses = np.concatenate(losses, axis=0)
embeddings = np.concatenate(embeddings)
return losses, embeddings
def build(self):
self.build_placeholders()
self.build_model()
self.build_training()
def build_placeholders(self):
self.states_pl = tf.placeholder(tf.float32, shape=(None, *self.input_shape), name="states_pl")
self.actions_pl = tf.placeholder(tf.int32, shape=(None,), name="actions_pl")
self.rewards_pl = tf.placeholder(tf.float32, shape=(None,), name="rewards_pl")
self.dones_pl = tf.placeholder(tf.bool, shape=(None,), name="dones_pl")
self.next_states_pl = tf.placeholder(tf.float32, shape=(None, *self.input_shape), name="next_states_pl")
self.is_training_pl = tf.placeholder(tf.bool, shape=[], name="is_training_pl")
self.hand_states_pl = tf.placeholder(tf.float32, shape=(None, 1), name="hand_states_pl")
self.next_hand_states_pl = tf.placeholder(tf.float32, shape=(None, 1), name="next_hand_states_pl")
def build_model(self):
# level one
self.l1_state_mu_t, self.l1_state_log_var_t, self.l1_state_sample_t = \
self.build_l1(self.states_pl, self.hand_states_pl, namespace=self.L1_NAMESPACE)
if self.target_network:
self.l1_next_state_mu_t, self.l1_next_state_log_var_t, self.l1_next_state_sample_t = self.build_l1(
self.next_states_pl, self.next_hand_states_pl, share_weights=False,
namespace=self.L1_TARGET_NAMESPACE
)
else:
self.l1_next_state_mu_t, self.l1_next_state_log_var_t, self.l1_next_state_sample_t = self.build_l1(
self.next_states_pl, self.next_hand_states_pl, share_weights=True, namespace=self.L1_NAMESPACE
)
self.l1_r_v = tf.get_variable(
"reward_matrix_l1", shape=(self.num_actions, self.l1_num_blocks), dtype=tf.float32,
initializer=tf.random_normal_initializer(mean=0, stddev=np.sqrt(2 / self.l1_num_blocks), dtype=tf.float32)
)
self.l1_r_t = self.l1_r_v
self.l1_t_v = tf.get_variable(
"transition_matrix_l1", shape=(self.num_actions, self.l1_num_blocks, self.l1_num_blocks), dtype=tf.float32,
initializer=tf.random_normal_initializer(mean=0, stddev=np.sqrt(2 / self.l1_num_blocks), dtype=tf.float32)
)
self.l1_t_t = self.l1_t_v
# level two
self.l2_logits_t, self.l2_softmax_t = self.build_l2(self.l1_state_mu_t, self.L2_NAMESPACE)
if self.target_network:
self.l2_next_logits_t, self.l2_next_softmax_t = self.build_l2(
self.l1_state_mu_t, namespace=self.L2_TARGET_NAMESPACE, share_weights=False
)
else:
self.l2_next_logits_t, self.l2_next_softmax_t = self.build_l2(
self.l1_state_mu_t, namespace=self.L2_NAMESPACE, share_weights=True
)
self.l2_r_v = tf.get_variable(
"reward_matrix_l2", shape=(self.num_actions, self.l2_num_blocks), dtype=tf.float32,
initializer=tf.random_uniform_initializer(minval=0, maxval=1, dtype=tf.float32)
)
self.l2_r_t = self.l2_r_v
self.l2_t_v = tf.get_variable(
"transition_matrix_l2", shape=(self.num_actions, self.l2_num_blocks, self.l2_num_blocks), dtype=tf.float32,
initializer=tf.random_normal_initializer(mean=0, stddev=np.sqrt(2 / self.l2_num_blocks), dtype=tf.float32)
)
self.l2_t_t = tf.nn.softmax(self.l2_t_v, axis=-1)
# build target updates
if self.target_network:
self.build_target_update()
def build_training(self):
# create global training step variable
self.global_step = tf.train.get_or_create_global_step()
# gather appropriate transition matrices
l1_r_per_action_t = tf.gather(self.l1_r_t, self.actions_pl)
l2_r_per_action_t = tf.gather(self.l2_r_t, self.actions_pl)
l1_t_per_action_t = tf.gather(self.l1_t_t, self.actions_pl)
l2_t_per_action_t = tf.gather(tf.nn.log_softmax(self.l2_t_v), self.actions_pl)
# reward cross-entropy
dones_t = tf.cast(self.dones_pl, tf.float32)
self.l1_full_reward_loss_t = (1 / 2) * tf.square(
self.rewards_pl - tf.reduce_sum(self.l1_state_sample_t * l1_r_per_action_t, axis=1)
)
self.l1_reward_loss_t = tf.reduce_mean(self.l1_full_reward_loss_t, axis=0)
self.l2_full_reward_loss_t = (1 / 2) * tf.reduce_sum(
tf.square(self.rewards_pl[:, tf.newaxis] - l2_r_per_action_t) * self.l2_softmax_t, axis=1
)
self.l2_reward_loss_t = tf.reduce_mean(self.l2_full_reward_loss_t, axis=0)
# transition cross-entropy
l1_transformed_logits = tf.matmul(self.l1_state_sample_t[:, tf.newaxis, :], l1_t_per_action_t)
l1_transformed_logits = l1_transformed_logits[:, 0, :]
self.l1_full_transition_loss_t = (1 / 2) * tf.reduce_sum(
tf.square(tf.stop_gradient(self.l1_next_state_sample_t) - l1_transformed_logits), axis=1
) * (1 - dones_t)
self.l1_transition_loss_t = tf.reduce_sum(self.l1_full_transition_loss_t, axis=0) / tf.reduce_max([1.0, tf.reduce_sum(1 - dones_t)])
term1 = self.l2_softmax_t[:, :, tf.newaxis] * tf.stop_gradient(self.l2_next_softmax_t[:, tf.newaxis, :]) * \
l2_t_per_action_t
self.l2_full_transition_loss_t = - tf.reduce_sum(term1, axis=[1, 2]) * (1 - dones_t)
self.l2_transition_loss_t = tf.reduce_sum(self.l2_full_transition_loss_t, axis=0) / tf.reduce_max([1.0, tf.reduce_sum(1 - dones_t)])
# regularization
l1_reg = tf.get_collection(tf.GraphKeys.REGULARIZATION_LOSSES, scope=self.L1_NAMESPACE)
l2_reg = tf.get_collection(tf.GraphKeys.REGULARIZATION_LOSSES, scope=self.L2_NAMESPACE)
self.l1_regularization_loss_t = 0
self.l2_regularization_loss_t = 0
if len(l1_reg) > 0:
self.l1_regularization_loss_t = tf.add_n(l1_reg)
if len(l2_reg) > 0:
self.l2_regularization_loss_t = tf.add_n(l2_reg)
# full loss
self.gamma_v = tf.Variable(initial_value=self.gamma, trainable=False, dtype=tf.float32)
self.l1_loss_t = self.l1_reward_loss_t + \
tf.stop_gradient(self.gamma_v) * self.l1_transition_loss_t + \
self.l1_regularization_loss_t
self.l2_loss_t = self.l2_reward_loss_t + \
tf.stop_gradient(self.gamma_v) * self.l2_transition_loss_t + \
self.l2_regularization_loss_t
# optimizers
l1_encoder_variables = tf.get_collection(tf.GraphKeys.TRAINABLE_VARIABLES, scope=self.L1_NAMESPACE)
l2_encoder_variables = tf.get_collection(tf.GraphKeys.TRAINABLE_VARIABLES, scope=self.L2_NAMESPACE)
l1_encoder_optimizer = agent_utils.get_optimizer(self.optimizer_encoder, self.l1_learning_rate_encoder)
l2_encoder_optimizer = agent_utils.get_optimizer(self.optimizer_encoder, self.l2_learning_rate_encoder)
self.l1_encoder_train_step = l1_encoder_optimizer.minimize(
self.l1_loss_t, global_step=self.global_step, var_list=l1_encoder_variables
)
self.l2_encoder_train_step = l2_encoder_optimizer.minimize(
self.l2_loss_t, global_step=self.global_step, var_list=l2_encoder_variables
)
if self.batch_norm:
self.update_op = tf.group(*tf.get_collection(tf.GraphKeys.UPDATE_OPS))
self.l1_encoder_train_step = tf.group(self.l1_encoder_train_step, self.update_op)
l1_r_optimizer = agent_utils.get_optimizer(self.optimizer_model, self.learning_rate_r)
l2_r_optimizer = agent_utils.get_optimizer(self.optimizer_model, self.learning_rate_r)
self.l1_r_step = l1_r_optimizer.minimize(
self.l1_reward_loss_t, var_list=[self.l1_r_v]
)
self.l2_r_step = l2_r_optimizer.minimize(
self.l2_reward_loss_t, var_list=[self.l2_r_v]
)
l1_t_optimizer = agent_utils.get_optimizer(self.optimizer_model, self.learning_rate_t)
l2_t_optimizer = agent_utils.get_optimizer(self.optimizer_model, self.learning_rate_t)
self.l1_t_step = l1_t_optimizer.minimize(
self.l1_transition_loss_t, var_list=[self.l1_t_v]
)
self.l2_t_step = l2_t_optimizer.minimize(
self.l2_transition_loss_t, var_list=[self.l2_t_v]
)
self.l1_model_train_step = tf.group(self.l1_r_step, self.l1_t_step)
self.l2_model_train_step = tf.group(self.l2_r_step, self.l2_t_step)
self.l1_train_step = tf.group(self.l1_encoder_train_step, self.l1_model_train_step)
self.l2_train_step = tf.group(self.l2_encoder_train_step, self.l2_model_train_step)
def build_l1(self, depth_pl, hand_state_pl, share_weights=False, namespace=L1_NAMESPACE):
x = tf.expand_dims(depth_pl, axis=-1)
with tf.variable_scope(namespace, reuse=share_weights):
for idx in range(len(self.encoder_filters)):
with tf.variable_scope("conv{:d}".format(idx + 1)):
x = tf.layers.conv2d(
x, self.encoder_filters[idx], self.encoder_filter_sizes[idx], self.encoder_strides[idx],
padding="SAME", activation=tf.nn.relu if not self.batch_norm else None,
kernel_regularizer=agent_utils.get_weight_regularizer(self.weight_decay),
kernel_initializer=agent_utils.get_mrsa_initializer(),
use_bias=not self.batch_norm
)
if self.batch_norm and idx != len(self.encoder_filters) - 1:
x = tf.layers.batch_normalization(x, training=self.is_training_pl)
x = tf.nn.relu(x)
x = tf.layers.flatten(x)
if self.batch_norm:
x = tf.layers.batch_normalization(x, training=self.is_training_pl)
x = tf.nn.relu(x)
x = tf.concat([x, hand_state_pl], axis=1)
for idx, neurons in enumerate(self.encoder_neurons):
with tf.variable_scope("fc{:d}".format(idx + 1)):
x = tf.layers.dense(
x, neurons, activation=tf.nn.relu if not self.batch_norm else None,
kernel_regularizer=agent_utils.get_weight_regularizer(self.weight_decay),
kernel_initializer=agent_utils.get_mrsa_initializer(),
use_bias=not self.batch_norm
)
if self.batch_norm:
x = tf.layers.batch_normalization(x, training=self.is_training_pl)
x = tf.nn.relu(x)
with tf.variable_scope("predict"):
mu = tf.layers.dense(
x, self.l1_num_blocks, activation=None,
kernel_regularizer=agent_utils.get_weight_regularizer(self.weight_decay),
kernel_initializer=agent_utils.get_mrsa_initializer()
)
log_var = tf.layers.dense(
x, self.l1_num_blocks, activation=None,
kernel_regularizer=agent_utils.get_weight_regularizer(self.weight_decay),
kernel_initializer=agent_utils.get_mrsa_initializer()
)
if self.no_sample:
sample = mu
else:
noise = tf.random_normal(
shape=(tf.shape(mu)[0], self.l1_num_blocks), mean=0, stddev=1.0
)
var_t = tf.exp(log_var)
sd = tf.sqrt(var_t)
sd_noise_t = noise * sd
sample = mu + sd_noise_t
return mu, log_var, sample
def build_l2(self, l1_output, namespace, share_weights=False):
x = l1_output
with tf.variable_scope(namespace, reuse=share_weights):
for idx, neurons in enumerate(self.l2_hiddens):
with tf.variable_scope("fc{:d}".format(idx + 1)):
x = tf.layers.dense(
x, neurons, activation=tf.nn.relu,
kernel_regularizer=agent_utils.get_weight_regularizer(self.weight_decay),
kernel_initializer=agent_utils.get_mrsa_initializer()
)
l2_logits = tf.layers.dense(
x, self.l2_num_blocks, activation=None,
kernel_regularizer=agent_utils.get_weight_regularizer(self.weight_decay),
kernel_initializer=agent_utils.get_mrsa_initializer()
)
l2_softmax = tf.nn.softmax(l2_logits)
return l2_logits, l2_softmax
def build_target_update(self):
ops = []
for source, target in zip([self.L1_NAMESPACE, self.L2_NAMESPACE],
[self.L1_TARGET_NAMESPACE, self.L2_TARGET_NAMESPACE]):
source_vars = tf.get_collection(tf.GraphKeys.GLOBAL_VARIABLES, scope=source)
target_vars = tf.get_collection(tf.GraphKeys.GLOBAL_VARIABLES, scope=target)
assert len(source_vars) == len(target_vars) and len(source_vars) > 0
for source_var, target_var in zip(source_vars, target_vars):
ops.append(tf.assign(target_var, source_var))
self.target_update_op = tf.group(*ops)
def set_gamma(self, value):
self.session.run(tf.assign(self.gamma_v, value))
def start_session(self, gpu_memory=None):
gpu_options = None
if gpu_memory is not None:
gpu_options = tf.GPUOptions(per_process_gpu_memory_fraction=gpu_memory)
tf_config = tf.ConfigProto(gpu_options=gpu_options)
self.session = tf.Session(config=tf_config)
self.session.run(tf.global_variables_initializer())
def stop_session(self):
if self.session is not None:
self.session.close()
class RobsTwoStepModel:
ENCODER_NAMESPACE = "encoder"
TARGET_ENCODER_NAMESPACE = "target_encoder"
def __init__(self, input_shape, num_blocks, num_actions, encoder_filters, encoder_filter_sizes,
encoder_strides, encoder_neurons, learning_rate_encoder, learning_rate_r, learning_rate_t,
weight_decay, gamma, optimizer_encoder, optimizer_model, max_steps, batch_norm=True,
tau=1.0, stop_step_two_reward_gradients=False, normal_t_init=False):
self.input_shape = input_shape
self.num_blocks = num_blocks
self.num_actions = num_actions
self.encoder_filters = encoder_filters
self.encoder_filter_sizes = encoder_filter_sizes
self.encoder_strides = encoder_strides
self.encoder_neurons = encoder_neurons
self.learning_rate_encoder = learning_rate_encoder
self.learning_rate_r = learning_rate_r
self.learning_rate_t = learning_rate_t
self.weight_decay = weight_decay
self.gamma = gamma
self.optimizer_encoder = optimizer_encoder
self.optimizer_model = optimizer_model
self.max_steps = max_steps
self.batch_norm = batch_norm
self.tau = tau
self.stop_step_two_reward_gradients = stop_step_two_reward_gradients
self.normal_t_init = normal_t_init
self.hand_states_pl, self.next_hand_states_pl = None, None
def encode(self, depths, hand_states, batch_size=100):
num_steps = int(np.ceil(depths.shape[0] / batch_size))
embeddings = []
for i in range(num_steps):
batch_slice = np.index_exp[i * batch_size:(i + 1) * batch_size]
feed_dict = {
self.states_pl: depths[batch_slice],
self.hand_states_pl: hand_states[batch_slice],
self.is_training_pl: False
}
embedding = self.session.run(self.state_softmax_t, feed_dict=feed_dict)
embeddings.append(embedding)
embeddings = np.concatenate(embeddings, axis=0)
return embeddings
def validate(self, depths, hand_states, actions, rewards, next_actions, next_rewards, dones, batch_size=100):
num_steps = int(np.ceil(depths.shape[0] / batch_size))
losses = []
for i in range(num_steps):
batch_slice = np.index_exp[i * batch_size:(i + 1) * batch_size]
feed_dict = {
self.states_pl: depths[batch_slice],
self.hand_states_pl: hand_states[:, np.newaxis][batch_slice],
self.actions_pl: actions[batch_slice],
self.rewards_pl: rewards[batch_slice],
self.next_actions_pl: next_actions[batch_slice],
self.next_rewards_pl: next_rewards[batch_slice],
self.dones_pl: dones[batch_slice],
self.is_training_pl: False
}
l1, l2 = self.session.run(
[self.full_step_one_reward_loss_t, self.full_step_two_reward_loss_t], feed_dict=feed_dict
)
losses.append(np.transpose(np.array([l1, l2]), axes=(1, 0)))
losses = np.concatenate(losses, axis=0)
return losses
def validate_and_encode(self, depths, hand_states, actions, rewards, next_actions, next_rewards, dones,
batch_size=100):
num_steps = int(np.ceil(depths.shape[0] / batch_size))
losses = []
embeddings = []
for i in range(num_steps):
batch_slice = np.index_exp[i * batch_size:(i + 1) * batch_size]
feed_dict = {
self.states_pl: depths[batch_slice],
self.hand_states_pl: hand_states[:, np.newaxis][batch_slice],
self.actions_pl: actions[batch_slice],
self.rewards_pl: rewards[batch_slice],
self.next_actions_pl: next_actions[batch_slice],
self.next_rewards_pl: next_rewards[batch_slice],
self.dones_pl: dones[batch_slice],
self.is_training_pl: False
}
tmp_embeddings, l1, l2 = self.session.run([
self.state_softmax_t, self.full_step_one_reward_loss_t, self.full_step_two_reward_loss_t],
feed_dict=feed_dict
)
losses.append(np.transpose(np.array([l1, l2]), axes=(1, 0)))
embeddings.append(tmp_embeddings)
losses = np.concatenate(losses, axis=0)
embeddings = np.concatenate(embeddings)
return losses, embeddings
def build(self):
self.build_placeholders()
self.build_model()
self.build_training()
def build_placeholders(self):
self.states_pl = tf.placeholder(tf.float32, shape=(None, *self.input_shape), name="states_pl")
self.hand_states_pl = tf.placeholder(tf.float32, shape=(None, 1), name="hand_states_pl")
self.actions_pl = tf.placeholder(tf.int32, shape=(None,), name="actions_pl")
self.rewards_pl = tf.placeholder(tf.float32, shape=(None,), name="rewards_pl")
self.dones_pl = tf.placeholder(tf.bool, shape=(None,), name="dones_pl")
self.next_actions_pl = tf.placeholder(tf.int32, shape=(None,), name="next_actions_pl")
self.next_rewards_pl = tf.placeholder(tf.float32, shape=(None,), name="next_rewards_pl")
self.is_training_pl = tf.placeholder(tf.bool, shape=[], name="is_training_pl")
def build_model(self):
self.state_logits_t, self.state_softmax_t = self.build_encoder(self.states_pl, self.hand_states_pl)
self.perplexity_t = tf.constant(2, dtype=tf.float32) ** (
- tf.reduce_mean(
tf.reduce_sum(
self.state_softmax_t * tf.log(self.state_softmax_t + 1e-7) /
tf.log(tf.constant(2, dtype=self.state_softmax_t.dtype)),
axis=1
),
axis=0
)
)
self.r_v = tf.get_variable(
"reward_matrix", shape=(self.num_actions, self.num_blocks), dtype=tf.float32,
initializer=tf.random_uniform_initializer(minval=0, maxval=1, dtype=tf.float32)
)
self.r_t = self.r_v
if self.normal_t_init:
init = tf.random_normal_initializer(mean=0, stddev=np.sqrt(2 / self.num_blocks))
else:
init = tf.random_uniform_initializer(minval=0, maxval=1, dtype=tf.float32)
self.t_v = tf.get_variable(
"transition_matrix", shape=(self.num_actions, self.num_blocks, self.num_blocks), dtype=tf.float32,
initializer=init
)
self.t_t = tf.nn.softmax(self.t_v, axis=-1)
def build_training(self):
# create global training step variable
self.global_step = tf.train.get_or_create_global_step()
# gather appropriate transition matrices
r_per_action_t = tf.gather(self.r_t, self.actions_pl)
t_per_action_t = tf.gather(self.t_t, self.actions_pl)
next_r_per_action_t = tf.gather(self.r_t, self.next_actions_pl)
if self.stop_step_two_reward_gradients:
next_r_per_action_t = tf.stop_gradient(next_r_per_action_t)
# one step reward loss
self.full_step_one_reward_loss_t, self.step_one_reward_loss_t = \
self.build_reward_loss(r_per_action_t, self.rewards_pl, self.state_softmax_t)
# two step reward loss
self.transformed_next_state_softmax_t = \
tf.matmul(self.state_softmax_t[:, tf.newaxis, :], t_per_action_t)[:, 0, :]
self.full_step_two_reward_loss_t, self.step_two_reward_loss_t = \
self.build_reward_loss(
next_r_per_action_t, self.next_rewards_pl, self.transformed_next_state_softmax_t, dones=self.dones_pl
)
# regularization
reg = tf.get_collection(tf.GraphKeys.REGULARIZATION_LOSSES)
if len(reg) > 0:
self.regularization_loss_t = tf.add_n(reg)
else:
self.regularization_loss_t = 0
# full loss
self.gamma_v = tf.Variable(initial_value=self.gamma, trainable=False, dtype=tf.float32)
self.loss_t = self.step_one_reward_loss_t + tf.stop_gradient(self.gamma_v) * self.step_two_reward_loss_t + \
self.regularization_loss_t
# optimizers
encoder_variables = tf.get_collection(tf.GraphKeys.TRAINABLE_VARIABLES, scope=self.ENCODER_NAMESPACE)
encoder_optimizer = agent_utils.get_optimizer(self.optimizer_encoder, self.learning_rate_encoder)
self.encoder_train_step = encoder_optimizer.minimize(
self.loss_t, global_step=self.global_step, var_list=encoder_variables
)
if self.batch_norm:
self.update_op = tf.group(*tf.get_collection(tf.GraphKeys.UPDATE_OPS))
self.encoder_train_step = tf.group(self.encoder_train_step, self.update_op)
model_train_step = []
r_optimizer = agent_utils.get_optimizer(self.optimizer_model, self.learning_rate_r)
self.r_step = r_optimizer.minimize(
self.loss_t, var_list=[self.r_v]
)
model_train_step.append(self.r_step)
t_optimizer = agent_utils.get_optimizer(self.optimizer_model, self.learning_rate_t)
self.t_step = t_optimizer.minimize(
self.loss_t, var_list=[self.t_v]
)
model_train_step.append(self.t_step)
self.model_train_step = tf.group(*model_train_step)
self.train_step = tf.group(self.encoder_train_step, self.model_train_step)
@staticmethod
def build_reward_loss(expected_rewards, observed_rewards, encodings, dones=None):
# compute the reward loss
term1_t = tf.square(observed_rewards[:, tf.newaxis] - expected_rewards)
term2_t = term1_t * encodings
full_reward_loss_t = (1 / 2) * tf.reduce_sum(term2_t, axis=1)
if dones is not None:
dones = (1.0 - tf.cast(dones, dtype=tf.float32))
full_reward_loss_t = full_reward_loss_t * dones
reward_loss_t = tf.reduce_sum(full_reward_loss_t) / tf.reduce_max([tf.reduce_sum(dones), 1.0])
else:
reward_loss_t = tf.reduce_mean(full_reward_loss_t)
return full_reward_loss_t, reward_loss_t
def build_encoder(self, depth_pl, hand_state_pl, share_weights=False, namespace=ENCODER_NAMESPACE):
x = tf.expand_dims(depth_pl, axis=-1)
with tf.variable_scope(namespace, reuse=share_weights):
for idx in range(len(self.encoder_filters)):
with tf.variable_scope("conv{:d}".format(idx + 1)):
x = tf.layers.conv2d(
x, self.encoder_filters[idx], self.encoder_filter_sizes[idx], self.encoder_strides[idx],
padding="SAME", activation=tf.nn.relu if not self.batch_norm else None,
kernel_regularizer=agent_utils.get_weight_regularizer(self.weight_decay),
kernel_initializer=agent_utils.get_mrsa_initializer(),
use_bias=not self.batch_norm
)
if self.batch_norm and idx != len(self.encoder_filters) - 1:
x = tf.layers.batch_normalization(x, training=self.is_training_pl)
x = tf.nn.relu(x)
x = tf.layers.flatten(x)
if self.batch_norm:
x = tf.layers.batch_normalization(x, training=self.is_training_pl)
x = tf.nn.relu(x)
x = tf.concat([x, hand_state_pl], axis=1)
for idx, neurons in enumerate(self.encoder_neurons):
with tf.variable_scope("fc{:d}".format(idx + 1)):
x = tf.layers.dense(
x, neurons, activation=tf.nn.relu if not self.batch_norm else None,
kernel_regularizer=agent_utils.get_weight_regularizer(self.weight_decay),
kernel_initializer=agent_utils.get_mrsa_initializer(),
use_bias=not self.batch_norm
)
if self.batch_norm:
x = tf.layers.batch_normalization(x, training=self.is_training_pl)
x = tf.nn.relu(x)
with tf.variable_scope("predict"):
x = tf.layers.dense(
x, self.num_blocks, activation=None,
kernel_regularizer=agent_utils.get_weight_regularizer(self.weight_decay),
kernel_initializer=agent_utils.get_mrsa_initializer()
)
dist = tf.nn.softmax(x / self.tau)
return x, dist
def build_summaries(self):
# losses
tf.summary.scalar("loss", self.loss_t)
tf.summary.scalar("step_one_reward_loss", tf.reduce_mean(self.step_one_reward_loss_t))
tf.summary.scalar("step_two_reward_loss", tf.reduce_mean(self.step_two_reward_loss_t))
# logits and softmax
agent_utils.summarize(self.state_logits_t, "logits")
agent_utils.summarize(self.state_softmax_t, "softmax")
# grad norms
self.build_gradient_norm_summary(self.loss_t, self.state_logits_t, "state_logits_grad_norm")
self.build_gradient_norm_summary(self.loss_t, self.state_softmax_t, "state_softmax_grad_norm")
self.build_gradient_norm_summary(self.loss_t, self.r_v, "r_grad_norm", matrix_grad=True)
self.build_gradient_norm_summary(self.loss_t, self.t_v, "t_grad_norm", matrix_grad=True)
def build_gradient_norm_summary(self, y, x, name, matrix_grad=False):
# TODO: different dimensions of r_t and t_t
grad_t = tf.gradients(y, x)
if matrix_grad:
grad_t = grad_t[0]
norm_t = tf.norm(grad_t, ord=2, axis=-1)[0]
agent_utils.summarize(norm_t, name)
def set_gamma(self, value):
self.session.run(tf.assign(self.gamma_v, value))
def start_session(self, gpu_memory=None):
gpu_options = None
if gpu_memory is not None:
gpu_options = tf.GPUOptions(per_process_gpu_memory_fraction=gpu_memory)
tf_config = tf.ConfigProto(gpu_options=gpu_options)
self.session = tf.Session(config=tf_config)
self.session.run(tf.global_variables_initializer())
def stop_session(self):
if self.session is not None:
self.session.close()
def save_matrices_as_images(self, step, save_dir, ext="pdf"):
r, p = self.session.run([self.r_t, self.t_t])
r = np.reshape(r, (r.shape[0], -1))
p = np.reshape(p, (p.shape[0], -1))
r_path = os.path.join(save_dir, "r_{:d}.{}".format(step, ext))
p_path = os.path.join(save_dir, "p_{:d}.{}".format(step, ext))
plt.clf()
plt.imshow(r, vmin=-0.5, vmax=1.5)
plt.colorbar()
plt.savefig(r_path)
plt.clf()
plt.imshow(p, vmin=0, vmax=1)
plt.colorbar()
plt.savefig(p_path)
class RobsTwoStepModelContinuous:
ENCODER_NAMESPACE = "encoder"
TARGET_ENCODER_NAMESPACE = "target_encoder"
def __init__(self, input_shape, num_blocks, num_actions, encoder_filters, encoder_filter_sizes,
encoder_strides, encoder_neurons, learning_rate_encoder, learning_rate_r, learning_rate_t,
weight_decay, gamma, optimizer_encoder, optimizer_model, max_steps, batch_norm=True,
stop_step_two_reward_gradients=False, model_init_std=0.1, no_sample=False):
self.input_shape = input_shape
self.num_blocks = num_blocks
self.num_actions = num_actions
self.encoder_filters = encoder_filters
self.encoder_filter_sizes = encoder_filter_sizes
self.encoder_strides = encoder_strides
self.encoder_neurons = encoder_neurons
self.learning_rate_encoder = learning_rate_encoder
self.learning_rate_r = learning_rate_r
self.learning_rate_t = learning_rate_t
self.weight_decay = weight_decay
self.gamma = gamma
self.optimizer_encoder = optimizer_encoder
self.optimizer_model = optimizer_model
self.max_steps = max_steps
self.batch_norm = batch_norm
self.stop_step_two_reward_gradients = stop_step_two_reward_gradients
self.model_init_std = model_init_std
self.no_sample = no_sample
self.hand_states_pl, self.next_hand_states_pl = None, None
def encode(self, depths, hand_states, batch_size=100):
num_steps = int(np.ceil(depths.shape[0] / batch_size))
embeddings = []
for i in range(num_steps):
batch_slice = np.index_exp[i * batch_size:(i + 1) * batch_size]
feed_dict = {
self.states_pl: depths[batch_slice],
self.hand_states_pl: hand_states[batch_slice],
self.is_training_pl: False
}
# TODO: I could sample
embedding = self.session.run(self.mu_t, feed_dict=feed_dict)
embeddings.append(embedding)
embeddings = np.concatenate(embeddings, axis=0)
return embeddings
def validate(self, depths, hand_states, actions, rewards, next_actions, next_rewards, dones, batch_size=100):
num_steps = int(np.ceil(depths.shape[0] / batch_size))
losses = []
for i in range(num_steps):
batch_slice = np.index_exp[i * batch_size:(i + 1) * batch_size]
feed_dict = {
self.states_pl: depths[batch_slice],
self.hand_states_pl: hand_states[:, np.newaxis][batch_slice],
self.actions_pl: actions[batch_slice],
self.rewards_pl: rewards[batch_slice],
self.next_actions_pl: next_actions[batch_slice],
self.next_rewards_pl: next_rewards[batch_slice],
self.dones_pl: dones[batch_slice],
self.is_training_pl: False
}
l1, l2 = self.session.run(
[self.full_step_one_reward_loss_t, self.full_step_two_reward_loss_t], feed_dict=feed_dict
)
losses.append(np.transpose(np.array([l1, l2]), axes=(1, 0)))
losses = np.concatenate(losses, axis=0)
return losses
def validate_and_encode(self, depths, hand_states, actions, rewards, next_actions, next_rewards, dones,
batch_size=100):
num_steps = int(np.ceil(depths.shape[0] / batch_size))
losses = []
embeddings = []
for i in range(num_steps):
batch_slice = np.index_exp[i * batch_size:(i + 1) * batch_size]
feed_dict = {
self.states_pl: depths[batch_slice],
self.hand_states_pl: hand_states[:, np.newaxis][batch_slice],
self.actions_pl: actions[batch_slice],
self.rewards_pl: rewards[batch_slice],
self.next_actions_pl: next_actions[batch_slice],
self.next_rewards_pl: next_rewards[batch_slice],
self.dones_pl: dones[batch_slice],
self.is_training_pl: False
}
tmp_embeddings, l1, l2 = self.session.run([
self.mu_t, self.full_step_one_reward_loss_t, self.full_step_two_reward_loss_t],
feed_dict=feed_dict
)
losses.append(np.transpose(np.array([l1, l2]), axes=(1, 0)))
embeddings.append(tmp_embeddings)
losses = np.concatenate(losses, axis=0)
embeddings = np.concatenate(embeddings)
return losses, embeddings
def build(self):
self.build_placeholders()
self.build_model()
self.build_training()
def build_placeholders(self):
self.states_pl = tf.placeholder(tf.float32, shape=(None, *self.input_shape), name="states_pl")
self.hand_states_pl = tf.placeholder(tf.float32, shape=(None, 1), name="hand_states_pl")
self.actions_pl = tf.placeholder(tf.int32, shape=(None,), name="actions_pl")
self.rewards_pl = tf.placeholder(tf.float32, shape=(None,), name="rewards_pl")
self.dones_pl = tf.placeholder(tf.bool, shape=(None,), name="dones_pl")
self.next_actions_pl = tf.placeholder(tf.int32, shape=(None,), name="next_actions_pl")
self.next_rewards_pl = tf.placeholder(tf.float32, shape=(None,), name="next_rewards_pl")
self.is_training_pl = tf.placeholder(tf.bool, shape=[], name="is_training_pl")
def build_model(self):
self.mu_t, self.log_var_t, self.sample_t = self.build_encoder(self.states_pl, self.hand_states_pl)
self.r_v = tf.get_variable(
"reward_matrix", shape=(self.num_actions, self.num_blocks), dtype=tf.float32,
initializer=tf.random_normal_initializer(mean=0, stddev=np.sqrt(2 / self.num_blocks), dtype=tf.float32)
)
self.r_t = self.r_v
self.t_v = tf.get_variable(
"transition_matrix", shape=(self.num_actions, self.num_blocks, self.num_blocks), dtype=tf.float32,
initializer=tf.random_normal_initializer(mean=0, stddev=np.sqrt(2 / self.num_blocks), dtype=tf.float32)
)
self.t_t = self.t_v
#self.t_t = tf.nn.softmax(self.t_v, axis=-1)
def build_training(self):
# create global training step variable
self.global_step = tf.train.get_or_create_global_step()
# gather appropriate transition matrices
r_per_action_t = tf.gather(self.r_t, self.actions_pl)
t_per_action_t = tf.gather(self.t_t, self.actions_pl)
next_r_per_action_t = tf.gather(self.r_t, self.next_actions_pl)
if self.stop_step_two_reward_gradients:
next_r_per_action_t = tf.stop_gradient(next_r_per_action_t)
# one step reward loss
self.full_step_one_reward_loss_t, self.step_one_reward_loss_t = \
self.build_reward_loss(r_per_action_t, self.rewards_pl, self.sample_t)
# two step reward loss
self.transformed_next_state_sample_t = \
tf.matmul(self.sample_t[:, tf.newaxis, :], t_per_action_t)[:, 0, :]
self.full_step_two_reward_loss_t, self.step_two_reward_loss_t = \
self.build_reward_loss(
next_r_per_action_t, self.next_rewards_pl, self.transformed_next_state_sample_t, dones=self.dones_pl
)
# regularization
reg = tf.get_collection(tf.GraphKeys.REGULARIZATION_LOSSES)
if len(reg) > 0:
self.regularization_loss_t = tf.add_n(reg)
else:
self.regularization_loss_t = 0
# full loss
self.gamma_v = tf.Variable(initial_value=self.gamma, trainable=False, dtype=tf.float32)
self.loss_t = self.step_one_reward_loss_t + tf.stop_gradient(self.gamma_v) * self.step_two_reward_loss_t + \
self.regularization_loss_t
# optimizers
encoder_variables = tf.get_collection(tf.GraphKeys.TRAINABLE_VARIABLES, scope=self.ENCODER_NAMESPACE)
encoder_optimizer = agent_utils.get_optimizer(self.optimizer_encoder, self.learning_rate_encoder)
self.encoder_train_step = encoder_optimizer.minimize(
self.loss_t, global_step=self.global_step, var_list=encoder_variables
)
if self.batch_norm:
self.update_op = tf.group(*tf.get_collection(tf.GraphKeys.UPDATE_OPS))
self.encoder_train_step = tf.group(self.encoder_train_step, self.update_op)
model_train_step = []
r_optimizer = agent_utils.get_optimizer(self.optimizer_model, self.learning_rate_r)
self.r_step = r_optimizer.minimize(
self.loss_t, var_list=[self.r_v]
)
model_train_step.append(self.r_step)
t_optimizer = agent_utils.get_optimizer(self.optimizer_model, self.learning_rate_t)
self.t_step = t_optimizer.minimize(
self.loss_t, var_list=[self.t_v]
)
model_train_step.append(self.t_step)
self.model_train_step = tf.group(*model_train_step)
self.train_step = tf.group(self.encoder_train_step, self.model_train_step)
@staticmethod
def build_reward_loss(expected_rewards, observed_rewards, encodings, dones=None):
# compute the reward loss
term1_t = tf.square(
observed_rewards - tf.reduce_sum(encodings * expected_rewards, axis=1)
)
full_reward_loss_t = (1 / 2) * term1_t
if dones is not None:
dones = (1.0 - tf.cast(dones, dtype=tf.float32))
full_reward_loss_t = full_reward_loss_t * dones
reward_loss_t = tf.reduce_sum(full_reward_loss_t) / tf.reduce_max([tf.reduce_sum(dones), 1.0])
else:
reward_loss_t = tf.reduce_mean(full_reward_loss_t)
return full_reward_loss_t, reward_loss_t
def build_encoder(self, depth_pl, hand_state_pl, share_weights=False, namespace=ENCODER_NAMESPACE):
x = tf.expand_dims(depth_pl, axis=-1)
with tf.variable_scope(namespace, reuse=share_weights):
for idx in range(len(self.encoder_filters)):
with tf.variable_scope("conv{:d}".format(idx + 1)):
x = tf.layers.conv2d(
x, self.encoder_filters[idx], self.encoder_filter_sizes[idx], self.encoder_strides[idx],
padding="SAME", activation=tf.nn.relu if not self.batch_norm else None,
kernel_regularizer=agent_utils.get_weight_regularizer(self.weight_decay),
kernel_initializer=agent_utils.get_mrsa_initializer(),
use_bias=not self.batch_norm
)
if self.batch_norm and idx != len(self.encoder_filters) - 1:
x = tf.layers.batch_normalization(x, training=self.is_training_pl)
x = tf.nn.relu(x)
x = tf.layers.flatten(x)
if self.batch_norm:
x = tf.layers.batch_normalization(x, training=self.is_training_pl)
x = tf.nn.relu(x)
x = tf.concat([x, hand_state_pl], axis=1)
for idx, neurons in enumerate(self.encoder_neurons):
with tf.variable_scope("fc{:d}".format(idx + 1)):
x = tf.layers.dense(
x, neurons, activation=tf.nn.relu if not self.batch_norm else None,
kernel_regularizer=agent_utils.get_weight_regularizer(self.weight_decay),
kernel_initializer=agent_utils.get_mrsa_initializer(),
use_bias=not self.batch_norm
)
if self.batch_norm:
x = tf.layers.batch_normalization(x, training=self.is_training_pl)
x = tf.nn.relu(x)
with tf.variable_scope("predict"):
mu = tf.layers.dense(
x, self.num_blocks, activation=None,
kernel_regularizer=agent_utils.get_weight_regularizer(self.weight_decay),
kernel_initializer=agent_utils.get_mrsa_initializer()
)
log_var = tf.layers.dense(
x, self.num_blocks, activation=None,
kernel_regularizer=agent_utils.get_weight_regularizer(self.weight_decay),
kernel_initializer=agent_utils.get_mrsa_initializer()
)
if self.no_sample:
sample = mu
else:
noise = tf.random_normal(
shape=(tf.shape(mu)[0], self.num_blocks), mean=0, stddev=1.0
)
var_t = tf.exp(log_var)
sd = tf.sqrt(var_t)
sd_noise_t = noise * sd
sample = mu + sd_noise_t
return mu, log_var, sample
def build_summaries(self):
# losses
tf.summary.scalar("loss", self.loss_t)
tf.summary.scalar("step_one_reward_loss", tf.reduce_mean(self.step_one_reward_loss_t))
tf.summary.scalar("step_two_reward_loss", tf.reduce_mean(self.step_two_reward_loss_t))
# means and variances
agent_utils.summarize(self.mu_t, "means")
agent_utils.summarize(self.log_var_t, "log_variances")
# grad norms
self.build_gradient_norm_summary(self.loss_t, self.mu_t, "means_grad_norm")
self.build_gradient_norm_summary(self.loss_t, self.log_var_t, "log_variances_grad_norm")
self.build_gradient_norm_summary(self.loss_t, self.r_v, "r_grad_norm", matrix_grad=True)
self.build_gradient_norm_summary(self.loss_t, self.t_v, "t_grad_norm", matrix_grad=True)
def build_gradient_norm_summary(self, y, x, name, matrix_grad=False):
# TODO: different dimensions of r_t and t_t
grad_t = tf.gradients(y, x)
if matrix_grad:
grad_t = grad_t[0]
norm_t = tf.norm(grad_t, ord=2, axis=-1)[0]
agent_utils.summarize(norm_t, name)
def set_gamma(self, value):
self.session.run(tf.assign(self.gamma_v, value))
def start_session(self, gpu_memory=None):
gpu_options = None
if gpu_memory is not None:
gpu_options = tf.GPUOptions(per_process_gpu_memory_fraction=gpu_memory)
tf_config = tf.ConfigProto(gpu_options=gpu_options)
self.session = tf.Session(config=tf_config)
self.session.run(tf.global_variables_initializer())
def stop_session(self):
if self.session is not None:
self.session.close()
def save_matrices_as_images(self, step, save_dir, ext="pdf"):
r, p = self.session.run([self.r_t, self.t_t])
r = np.reshape(r, (r.shape[0], -1))
p = np.reshape(p, (p.shape[0], -1))
r_path = os.path.join(save_dir, "r_{:d}.{}".format(step, ext))
p_path = os.path.join(save_dir, "p_{:d}.{}".format(step, ext))
plt.clf()
plt.imshow(r, vmin=-0.5, vmax=1.5)
plt.colorbar()
plt.savefig(r_path)
plt.clf()
plt.imshow(p, vmin=0, vmax=1)
plt.colorbar()
plt.savefig(p_path)
class RobsTwoStepModelHierarchy:
L1_NAMESPACE = "l1"
L2_NAMESPACE = "l2"
def __init__(self, input_shape, l1_num_blocks, l2_num_blocks, num_actions, encoder_filters, encoder_filter_sizes,
encoder_strides, encoder_neurons, l1_learning_rate_encoder, l2_learning_rate_encoder,
learning_rate_r, learning_rate_t,
weight_decay, gamma, optimizer_encoder, optimizer_model, max_steps, l2_hiddens, batch_norm=True,
stop_step_two_reward_gradients=False, model_init_std=0.1, no_sample=False):
self.input_shape = input_shape
self.l1_num_blocks = l1_num_blocks
self.l2_num_blocks = l2_num_blocks
self.num_actions = num_actions
self.encoder_filters = encoder_filters
self.encoder_filter_sizes = encoder_filter_sizes
self.encoder_strides = encoder_strides
self.encoder_neurons = encoder_neurons
self.l1_learning_rate_encoder = l1_learning_rate_encoder
self.l2_learning_rate_encoder = l2_learning_rate_encoder
self.learning_rate_r = learning_rate_r
self.learning_rate_t = learning_rate_t
self.weight_decay = weight_decay
self.gamma = gamma
self.optimizer_encoder = optimizer_encoder
self.optimizer_model = optimizer_model
self.max_steps = max_steps
self.l2_hiddens = l2_hiddens
self.batch_norm = batch_norm
self.stop_step_two_reward_gradients = stop_step_two_reward_gradients
self.model_init_std = model_init_std
self.no_sample = no_sample
self.hand_states_pl, self.next_hand_states_pl = None, None
def encode(self, depths, hand_states, level, batch_size=100):
num_steps = int(np.ceil(depths.shape[0] / batch_size))
embeddings = []
for i in range(num_steps):
batch_slice = np.index_exp[i * batch_size:(i + 1) * batch_size]
feed_dict = {
self.states_pl: depths[batch_slice],
self.hand_states_pl: hand_states[batch_slice],
self.is_training_pl: False
}
if level == self.L1_NAMESPACE:
to_run = self.l1_mu_t
else:
to_run = self.l2_softmax_t
embedding = self.session.run(to_run, feed_dict=feed_dict)
embeddings.append(embedding)
embeddings = np.concatenate(embeddings, axis=0)
return embeddings
def validate(self, depths, hand_states, actions, rewards, next_actions, next_rewards, dones, level, batch_size=100):
num_steps = int(np.ceil(depths.shape[0] / batch_size))
losses = []
for i in range(num_steps):
batch_slice = np.index_exp[i * batch_size:(i + 1) * batch_size]
feed_dict = {
self.states_pl: depths[batch_slice],
self.hand_states_pl: hand_states[:, np.newaxis][batch_slice],
self.actions_pl: actions[batch_slice],
self.rewards_pl: rewards[batch_slice],
self.next_actions_pl: next_actions[batch_slice],
self.next_rewards_pl: next_rewards[batch_slice],
self.dones_pl: dones[batch_slice],
self.is_training_pl: False
}
if level == self.L1_NAMESPACE:
to_run = [self.l1_full_step_one_reward_loss_t, self.l1_full_step_two_reward_loss_t]
else:
to_run = [self.l2_full_step_one_reward_loss_t, self.l2_full_step_two_reward_loss_t]
l1, l2 = self.session.run(to_run, feed_dict=feed_dict)
losses.append(np.transpose(np.array([l1, l2]), axes=(1, 0)))
losses = np.concatenate(losses, axis=0)
return losses
def validate_and_encode(self, depths, hand_states, actions, rewards, next_actions, next_rewards, dones,
level, batch_size=100):
num_steps = int(np.ceil(depths.shape[0] / batch_size))
losses = []
embeddings = []
for i in range(num_steps):
batch_slice = np.index_exp[i * batch_size:(i + 1) * batch_size]
feed_dict = {
self.states_pl: depths[batch_slice],
self.hand_states_pl: hand_states[:, np.newaxis][batch_slice],
self.actions_pl: actions[batch_slice],
self.rewards_pl: rewards[batch_slice],
self.next_actions_pl: next_actions[batch_slice],
self.next_rewards_pl: next_rewards[batch_slice],
self.dones_pl: dones[batch_slice],
self.is_training_pl: False
}
if level == self.L1_NAMESPACE:
to_run = [self.l1_mu_t, self.l1_full_step_one_reward_loss_t, self.l1_full_step_two_reward_loss_t]
else:
to_run = [self.l2_softmax_t, self.l2_full_step_one_reward_loss_t, self.l2_full_step_two_reward_loss_t]
tmp_embeddings, l1, l2 = self.session.run(to_run, feed_dict=feed_dict)
losses.append(np.transpose(np.array([l1, l2]), axes=(1, 0)))
embeddings.append(tmp_embeddings)
losses = np.concatenate(losses, axis=0)
embeddings = np.concatenate(embeddings)
return losses, embeddings
def build(self):
self.build_placeholders()
self.build_model()
self.build_training()
def build_placeholders(self):
self.states_pl = tf.placeholder(tf.float32, shape=(None, *self.input_shape), name="states_pl")
self.hand_states_pl = tf.placeholder(tf.float32, shape=(None, 1), name="hand_states_pl")
self.actions_pl = tf.placeholder(tf.int32, shape=(None,), name="actions_pl")
self.rewards_pl = tf.placeholder(tf.float32, shape=(None,), name="rewards_pl")
self.dones_pl = tf.placeholder(tf.bool, shape=(None,), name="dones_pl")
self.next_actions_pl = tf.placeholder(tf.int32, shape=(None,), name="next_actions_pl")
self.next_rewards_pl = tf.placeholder(tf.float32, shape=(None,), name="next_rewards_pl")
self.is_training_pl = tf.placeholder(tf.bool, shape=[], name="is_training_pl")
def build_model(self):
# build level one model
self.l1_mu_t, self.l1_log_var_t, self.l1_sample_t = self.build_l1(self.states_pl, self.hand_states_pl)
self.l1_r_v = tf.get_variable(
"reward_matrix_l1", shape=(self.num_actions, self.l1_num_blocks), dtype=tf.float32,
initializer=tf.random_normal_initializer(mean=0, stddev=np.sqrt(2 / self.l1_num_blocks), dtype=tf.float32)
)
self.l1_r_t = self.l1_r_v
self.l1_t_v = tf.get_variable(
"transition_matrix_l1", shape=(self.num_actions, self.l1_num_blocks, self.l1_num_blocks), dtype=tf.float32,
initializer=tf.random_normal_initializer(mean=0, stddev=np.sqrt(2 / self.l1_num_blocks), dtype=tf.float32)
)
self.l1_t_t = self.l1_t_v
# build level two model
self.l2_logits_t, self.l2_softmax_t = self.build_l2(self.l1_mu_t)
self.l2_r_v = tf.get_variable(
"reward_matrix_l2", shape=(self.num_actions, self.l2_num_blocks), dtype=tf.float32,
initializer=tf.random_uniform_initializer(minval=0, maxval=1, dtype=tf.float32)
)
self.l2_r_t = self.l2_r_v
self.l2_t_v = tf.get_variable(
"transition_matrix_l2", shape=(self.num_actions, self.l2_num_blocks, self.l2_num_blocks), dtype=tf.float32,
initializer=tf.random_normal_initializer(mean=0, stddev=np.sqrt(2 / self.l2_num_blocks), dtype=tf.float32)
)
self.l2_t_t = tf.nn.softmax(self.l2_t_v, axis=-1)
def build_training(self):
# create global training step variable
self.global_step = tf.train.get_or_create_global_step()
# gather appropriate transition matrices
l1_r_per_action_t = tf.gather(self.l1_r_t, self.actions_pl)
l2_r_per_action_t = tf.gather(self.l2_r_t, self.actions_pl)
l1_t_per_action_t = tf.gather(self.l1_t_t, self.actions_pl)
l2_t_per_action_t = tf.gather(self.l2_t_t, self.actions_pl)
next_l1_r_per_action_t = tf.gather(self.l1_r_t, self.next_actions_pl)
next_l2_r_per_action_t = tf.gather(self.l2_r_t, self.next_actions_pl)
if self.stop_step_two_reward_gradients:
next_l1_r_per_action_t = tf.stop_gradient(next_l1_r_per_action_t)
next_l2_r_per_action_t = tf.stop_gradient(next_l2_r_per_action_t)
# one step reward loss
self.l1_full_step_one_reward_loss_t, self.l1_step_one_reward_loss_t = \
self.build_reward_loss_continuous(l1_r_per_action_t, self.rewards_pl, self.l1_sample_t)
self.l2_full_step_one_reward_loss_t, self.l2_step_one_reward_loss_t = \
self.build_reward_loss_discrete(l2_r_per_action_t, self.rewards_pl, self.l2_softmax_t)
# two step reward loss
self.transformed_l1_next_state_sample_t = \
tf.matmul(self.l1_sample_t[:, tf.newaxis, :], l1_t_per_action_t)[:, 0, :]
self.transformed_l2_next_state_sample_t = \
tf.matmul(self.l2_softmax_t[:, tf.newaxis, :], l2_t_per_action_t)[:, 0, :]
self.l1_full_step_two_reward_loss_t, self.l1_step_two_reward_loss_t = \
self.build_reward_loss_continuous(
next_l1_r_per_action_t, self.next_rewards_pl, self.transformed_l1_next_state_sample_t,
dones=self.dones_pl
)
self.l2_full_step_two_reward_loss_t, self.l2_step_two_reward_loss_t = \
self.build_reward_loss_discrete(
next_l2_r_per_action_t, self.next_rewards_pl, self.transformed_l2_next_state_sample_t,
dones=self.dones_pl
)
# regularization
l1_reg = tf.get_collection(tf.GraphKeys.REGULARIZATION_LOSSES, scope=self.L1_NAMESPACE)
l2_reg = tf.get_collection(tf.GraphKeys.REGULARIZATION_LOSSES, scope=self.L2_NAMESPACE)
self.l1_regularization_loss_t = 0
self.l2_regularization_loss_t = 0
if len(l1_reg) > 0:
self.l1_regularization_loss_t = tf.add_n(l1_reg)
if len(l2_reg) > 0:
self.l2_regularization_loss_t = tf.add_n(l2_reg)
# full loss
self.gamma_v = tf.Variable(initial_value=self.gamma, trainable=False, dtype=tf.float32)
self.l1_loss_t = self.l1_step_one_reward_loss_t + \
tf.stop_gradient(self.gamma_v) * self.l1_step_two_reward_loss_t + \
self.l1_regularization_loss_t
self.l2_loss_t = self.l2_step_one_reward_loss_t + \
tf.stop_gradient(self.gamma_v) * self.l2_step_two_reward_loss_t + \
self.l2_regularization_loss_t
# optimizers
l1_encoder_variables = tf.get_collection(tf.GraphKeys.TRAINABLE_VARIABLES, scope=self.L1_NAMESPACE)
l2_encoder_variables = tf.get_collection(tf.GraphKeys.TRAINABLE_VARIABLES, scope=self.L2_NAMESPACE)
l1_encoder_optimizer = agent_utils.get_optimizer(self.optimizer_encoder, self.l1_learning_rate_encoder)
l2_encoder_optimizer = agent_utils.get_optimizer(self.optimizer_encoder, self.l2_learning_rate_encoder)
self.l1_encoder_train_step = l1_encoder_optimizer.minimize(
self.l1_loss_t, global_step=self.global_step, var_list=l1_encoder_variables
)
self.l2_encoder_train_step = l2_encoder_optimizer.minimize(
self.l2_loss_t, global_step=self.global_step, var_list=l2_encoder_variables
)
if self.batch_norm:
self.update_op = tf.group(*tf.get_collection(tf.GraphKeys.UPDATE_OPS))
self.l1_encoder_train_step = tf.group(self.l1_encoder_train_step, self.update_op)
l1_r_optimizer = agent_utils.get_optimizer(self.optimizer_model, self.learning_rate_r)
l2_r_optimizer = agent_utils.get_optimizer(self.optimizer_model, self.learning_rate_r)
self.l1_r_step = l1_r_optimizer.minimize(
self.l1_loss_t, var_list=[self.l1_r_v]
)
self.l2_r_step = l2_r_optimizer.minimize(
self.l2_loss_t, var_list=[self.l2_r_v]
)
l1_t_optimizer = agent_utils.get_optimizer(self.optimizer_model, self.learning_rate_t)
l2_t_optimizer = agent_utils.get_optimizer(self.optimizer_model, self.learning_rate_t)
self.l1_t_step = l1_t_optimizer.minimize(
self.l1_loss_t, var_list=[self.l1_t_v]
)
self.l2_t_step = l2_t_optimizer.minimize(
self.l2_loss_t, var_list=[self.l2_t_v]
)
self.l1_model_train_step = tf.group(self.l1_r_step, self.l1_t_step)
self.l2_model_train_step = tf.group(self.l2_r_step, self.l2_t_step)
self.l1_train_step = tf.group(self.l1_encoder_train_step, self.l1_model_train_step)
self.l2_train_step = tf.group(self.l2_encoder_train_step, self.l2_model_train_step)
@staticmethod
def build_reward_loss_continuous(expected_rewards, observed_rewards, encodings, dones=None):
# compute the reward loss
term1_t = tf.square(
observed_rewards - tf.reduce_sum(encodings * expected_rewards, axis=1)
)
full_reward_loss_t = (1 / 2) * term1_t
if dones is not None:
dones = (1.0 - tf.cast(dones, dtype=tf.float32))
full_reward_loss_t = full_reward_loss_t * dones
reward_loss_t = tf.reduce_sum(full_reward_loss_t) / tf.reduce_max([tf.reduce_sum(dones), 1.0])
else:
reward_loss_t = tf.reduce_mean(full_reward_loss_t)
return full_reward_loss_t, reward_loss_t
@staticmethod
def build_reward_loss_discrete(expected_rewards, observed_rewards, encodings, dones=None):
# compute the reward loss
term1_t = tf.square(observed_rewards[:, tf.newaxis] - expected_rewards)
term2_t = term1_t * encodings
full_reward_loss_t = (1 / 2) * tf.reduce_sum(term2_t, axis=1)
if dones is not None:
dones = (1.0 - tf.cast(dones, dtype=tf.float32))
full_reward_loss_t = full_reward_loss_t * dones
reward_loss_t = tf.reduce_sum(full_reward_loss_t) / tf.reduce_max([tf.reduce_sum(dones), 1.0])
else:
reward_loss_t = tf.reduce_mean(full_reward_loss_t)
return full_reward_loss_t, reward_loss_t
def build_l1(self, depth_pl, hand_state_pl, share_weights=False, namespace=L1_NAMESPACE):
x = tf.expand_dims(depth_pl, axis=-1)
with tf.variable_scope(namespace, reuse=share_weights):
for idx in range(len(self.encoder_filters)):
with tf.variable_scope("conv{:d}".format(idx + 1)):
x = tf.layers.conv2d(
x, self.encoder_filters[idx], self.encoder_filter_sizes[idx], self.encoder_strides[idx],
padding="SAME", activation=tf.nn.relu if not self.batch_norm else None,
kernel_regularizer=agent_utils.get_weight_regularizer(self.weight_decay),
kernel_initializer=agent_utils.get_mrsa_initializer(),
use_bias=not self.batch_norm
)
if self.batch_norm and idx != len(self.encoder_filters) - 1:
x = tf.layers.batch_normalization(x, training=self.is_training_pl)
x = tf.nn.relu(x)
x = tf.layers.flatten(x)
if self.batch_norm:
x = tf.layers.batch_normalization(x, training=self.is_training_pl)
x = tf.nn.relu(x)
x = tf.concat([x, hand_state_pl], axis=1)
for idx, neurons in enumerate(self.encoder_neurons):
with tf.variable_scope("fc{:d}".format(idx + 1)):
x = tf.layers.dense(
x, neurons, activation=tf.nn.relu if not self.batch_norm else None,
kernel_regularizer=agent_utils.get_weight_regularizer(self.weight_decay),
kernel_initializer=agent_utils.get_mrsa_initializer(),
use_bias=not self.batch_norm
)
if self.batch_norm:
x = tf.layers.batch_normalization(x, training=self.is_training_pl)
x = tf.nn.relu(x)
with tf.variable_scope("predict"):
mu = tf.layers.dense(
x, self.l1_num_blocks, activation=None,
kernel_regularizer=agent_utils.get_weight_regularizer(self.weight_decay),
kernel_initializer=agent_utils.get_mrsa_initializer()
)
log_var = tf.layers.dense(
x, self.l1_num_blocks, activation=None,
kernel_regularizer=agent_utils.get_weight_regularizer(self.weight_decay),
kernel_initializer=agent_utils.get_mrsa_initializer()
)
if self.no_sample:
sample = mu
else:
noise = tf.random_normal(
shape=(tf.shape(mu)[0], self.l1_num_blocks), mean=0, stddev=1.0
)
var_t = tf.exp(log_var)
sd = tf.sqrt(var_t)
sd_noise_t = noise * sd
sample = mu + sd_noise_t
return mu, log_var, sample
def build_l2(self, l1_output):
x = l1_output
with tf.variable_scope(self.L2_NAMESPACE):
for idx, neurons in enumerate(self.l2_hiddens):
with tf.variable_scope("fc{:d}".format(idx + 1)):
x = tf.layers.dense(
x, neurons, activation=tf.nn.relu,
kernel_regularizer=agent_utils.get_weight_regularizer(self.weight_decay),
kernel_initializer=agent_utils.get_mrsa_initializer()
)
l2_logits = tf.layers.dense(
x, self.l2_num_blocks, activation=None,
kernel_regularizer=agent_utils.get_weight_regularizer(self.weight_decay),
kernel_initializer=agent_utils.get_mrsa_initializer()
)
l2_softmax = tf.nn.softmax(l2_logits)
return l2_logits, l2_softmax
def set_gamma(self, value):
self.session.run(tf.assign(self.gamma_v, value))
def start_session(self, gpu_memory=None):
gpu_options = None
if gpu_memory is not None:
gpu_options = tf.GPUOptions(per_process_gpu_memory_fraction=gpu_memory)
tf_config = tf.ConfigProto(gpu_options=gpu_options)
self.session = tf.Session(config=tf_config)
self.session.run(tf.global_variables_initializer())
def stop_session(self):
if self.session is not None:
self.session.close()
class ExpectationModelContinuousVampPrior(ExpectationModelContinuous):
def __init__(self, input_shape, num_blocks, num_actions, num_pseudo_inputs, encoder_filters, encoder_filter_sizes,
encoder_strides, encoder_neurons, learning_rate_encoder, learning_rate_r, learning_rate_t,
pseudo_inputs_learning_rate, weight_decay, beta1, beta2, gamma, optimizer_encoder, optimizer_model,
max_steps, batch_norm=True, target_network=True, propagate_next_state=False, no_sample=False,
softplus=False):
super(ExpectationModelContinuousVampPrior, self).__init__(
input_shape, num_blocks, num_actions, encoder_filters, encoder_filter_sizes, encoder_strides,
encoder_neurons, learning_rate_encoder, learning_rate_r, learning_rate_t, weight_decay, gamma,
optimizer_encoder, optimizer_model, max_steps, batch_norm=batch_norm, target_network=target_network,
propagate_next_state=propagate_next_state, no_sample=no_sample, softplus=softplus, beta=0.0
)
self.pseudo_inputs_learning_rate = pseudo_inputs_learning_rate
self.beta1 = beta1
self.beta2 = beta2
self.num_pseudo_inputs = num_pseudo_inputs
def validate(self, depths, hand_states, actions, rewards, next_depths, next_hand_states, dones, batch_size=100):
num_steps = int(np.ceil(depths.shape[0] / batch_size))
losses = []
for i in range(num_steps):
batch_slice = np.index_exp[i * batch_size:(i + 1) * batch_size]
feed_dict = {
self.states_pl: depths[batch_slice],
self.hand_states_pl: hand_states[:, np.newaxis][batch_slice],
self.actions_pl: actions[batch_slice],
self.rewards_pl: rewards[batch_slice],
self.next_states_pl: next_depths[batch_slice],
self.next_hand_states_pl: next_hand_states[:, np.newaxis][batch_slice],
self.dones_pl: dones[batch_slice],
self.is_training_pl: False
}
l1, l2, l3, l4 = self.session.run(
[self.full_transition_loss_t, self.full_reward_loss_t, self.full_entropy_loss_t,
self.full_prior_loss_t],
feed_dict=feed_dict)
losses.append(np.transpose(np.array([l1, l2, l3, l4]), axes=(1, 0)))
losses = np.concatenate(losses, axis=0)
return losses
def get_pseudo_inputs(self):
return self.session.run([self.pseudo_depths_v, self.pseudo_hand_states_t, self.pseudo_mu_t, self.pseudo_sample_t], feed_dict={
self.is_training_pl: False
})
def build_model(self):
# encode states and next states
self.state_mu_t, self.state_var_t, self.state_sd_t, self.state_sample_t = \
self.build_encoder(self.states_pl, self.hand_states_pl)
if self.target_network:
self.next_state_mu_t, self.next_state_var_t, self.next_state_sd_t, self.next_state_sample_t = self.build_encoder(
self.next_states_pl, self.next_hand_states_pl, share_weights=False,
namespace=self.TARGET_ENCODER_NAMESPACE
)
self.build_target_update()
else:
self.next_state_mu_t, self.next_state_var_t, self.next_state_sd_t, self.next_state_sample_t = self.build_encoder(
self.next_states_pl, self.next_hand_states_pl, share_weights=True
)
# encode pseudo inputs
self.pseudo_depths_v = tf.get_variable(
"pseudo_depths", shape=(self.num_pseudo_inputs, *self.input_shape),
initializer=tf.random_normal_initializer(mean=0.0, stddev=0.1, dtype=tf.float32)
)
self.pseudo_hand_states_v = tf.get_variable(
"pseudo_hand_states", shape=(self.num_pseudo_inputs, 1),
initializer=tf.random_normal_initializer(mean=0.5, stddev=0.1, dtype=tf.float32)
)
self.pseudo_hand_states_t = agent_utils.hardtanh(self.pseudo_hand_states_v)
self.pseudo_mu_t, self.pseudo_var_t, self.pseudo_sd_t, self.pseudo_sample_t = self.build_encoder(
self.pseudo_depths_v, self.pseudo_hand_states_t, share_weights=True
)
self.r_v = tf.get_variable(
"reward_matrix", shape=(self.num_actions, self.num_blocks), dtype=tf.float32,
initializer=tf.random_normal_initializer(mean=0, stddev=np.sqrt(2 / self.num_blocks), dtype=tf.float32)
)
self.t_v = tf.get_variable(
"transition_matrix", shape=(self.num_actions, self.num_blocks, self.num_blocks), dtype=tf.float32,
initializer=tf.random_normal_initializer(mean=0, stddev=np.sqrt(2 / self.num_blocks), dtype=tf.float32)
)
def build_training(self):
# create global training step variable
self.global_step = tf.train.get_or_create_global_step()
self.float_dones_t = tf.cast(self.dones_pl, tf.float32)
# gather appropriate transition matrices
self.gather_r_t = tf.gather(self.r_v, self.actions_pl)
self.gather_t_t = tf.gather(self.t_v, self.actions_pl)
# build losses
self.build_reward_loss()
self.build_transition_loss()
self.build_weight_decay_loss()
self.build_entropy_loss()
self.build_prior_loss()
# build the whole loss
self.gamma_v = tf.Variable(initial_value=self.gamma, trainable=False)
self.loss_t = self.reward_loss_t + tf.stop_gradient(self.gamma_v) * self.transition_loss_t + \
self.regularization_loss_t + self.beta1 * self.entropy_loss_t + self.beta2 * self.prior_loss_t
# build training
self.build_encoder_training()
self.build_pseudo_inputs_train()
self.build_r_model_training()
self.build_t_model_training()
self.encoder_train_step = tf.group(self.encoder_train_step, self.pseudo_input_train_step)
self.model_train_step = tf.group(self.r_step, self.t_step)
self.train_step = tf.group(self.encoder_train_step, self.model_train_step)
def build_entropy_loss(self):
self.full_entropy_loss_t = - (1 / 2) * tf.reduce_sum(tf.log(self.state_var_t), axis=1) - \
(self.num_blocks / 2) * (1 + np.log(2 * np.pi))
self.entropy_loss_t = tf.reduce_mean(self.full_entropy_loss_t, axis=0)
def build_prior_loss(self):
self.sample_probs_t = agent_utils.many_multivariate_normals_log_pdf(
self.state_sample_t, self.pseudo_mu_t, self.pseudo_var_t, tf.log(self.pseudo_var_t)
)
self.sample_probs_t -= np.log(self.num_pseudo_inputs)
d_max = tf.reduce_max(self.sample_probs_t, axis=1)
self.pseudo_expectation_t = d_max + tf.log(
tf.reduce_sum(tf.exp(self.sample_probs_t - d_max[:, tf.newaxis]), axis=1)
)
self.full_prior_loss_t = - self.pseudo_expectation_t
self.prior_loss_t = tf.reduce_mean(self.full_prior_loss_t, axis=0)
def build_pseudo_inputs_train(self):
pseudo_input_optimizer = agent_utils.get_optimizer(self.optimizer_model, self.pseudo_inputs_learning_rate)
self.pseudo_input_train_step = pseudo_input_optimizer.minimize(
self.prior_loss_t, var_list=[self.pseudo_depths_v, self.pseudo_hand_states_v]
)
class QPredictionModel(ExpectationModelContinuousWithQ):
def __init__(self, input_shape, num_blocks, num_actions, encoder_filters, encoder_filter_sizes,
encoder_strides, encoder_neurons, learning_rate_encoder, weight_decay, optimizer_encoder,
max_steps, batch_norm=True, no_sample=False, softplus=False, only_one_q_value=False,
old_bn_settings=False, bn_momentum=0.99):
super(QPredictionModel, self).__init__(
input_shape, num_blocks, num_actions, encoder_filters, encoder_filter_sizes,
encoder_strides, encoder_neurons, learning_rate_encoder, None, None,
None, weight_decay, None, None, optimizer_encoder, None,
max_steps, batch_norm=batch_norm, target_network=False, propagate_next_state=False,
no_sample=no_sample, softplus=softplus, beta=None, old_bn_settings=old_bn_settings,
bn_momentum=bn_momentum
)
self.only_one_q_value = only_one_q_value
def validate(self, depths, hand_states, actions, q_values, batch_size=100):
num_steps = int(np.ceil(depths.shape[0] / batch_size))
losses = []
for i in range(num_steps):
batch_slice = np.index_exp[i * batch_size:(i + 1) * batch_size]
feed_dict = {
self.states_pl: depths[batch_slice],
self.hand_states_pl: hand_states[:, np.newaxis][batch_slice],
self.actions_pl: actions[batch_slice],
self.q_values_pl: q_values[batch_slice],
self.is_training_pl: False
}
l1 = self.session.run([self.full_q_loss_t], feed_dict=feed_dict)
losses.append(l1)
losses = np.concatenate(losses, axis=0)
return losses
def build_placeholders(self):
self.states_pl = tf.placeholder(tf.float32, shape=(None, *self.input_shape), name="states_pl")
self.hand_states_pl = tf.placeholder(tf.float32, shape=(None, 1), name="hand_states_pl")
self.actions_pl = tf.placeholder(tf.int32, shape=(None,), name="actions_pl")
self.q_values_pl = tf.placeholder(tf.float32, shape=(None, self.num_actions), name="q_values_pl")
self.is_training_pl = tf.placeholder(tf.bool, shape=[], name="is_training_pl")
def build_model(self):
self.build_encoders()
self.build_predictor()
def build_encoders(self):
self.state_mu_t, self.state_var_t, self.state_sd_t, self.state_sample_t = \
self.build_encoder(self.states_pl, self.hand_states_pl)
def build_predictor(self):
with tf.variable_scope(self.ENCODER_NAMESPACE):
with tf.variable_scope("q_predictions"):
self.q_prediction_t = tf.layers.dense(
self.state_sample_t, self.num_actions,
kernel_initializer=agent_utils.get_xavier_initializer(),
kernel_regularizer=agent_utils.get_weight_regularizer(self.weight_decay)
)
def build_training(self):
# create global training step variable
self.global_step = tf.train.get_or_create_global_step()
self.actions_mask_t = tf.one_hot(self.actions_pl, self.num_actions, dtype=tf.float32)
# build losses
self.build_q_loss()
self.build_weight_decay_loss()
# build the whole loss
self.loss_t = self.q_loss_t + self.regularization_loss_t
# build training
self.build_encoder_training()
self.train_step = self.encoder_train_step
def build_q_loss(self):
if self.only_one_q_value:
self.full_q_loss_t = (1 / 2) * tf.reduce_sum(
tf.square(self.q_values_pl - self.q_prediction_t) * self.actions_mask_t, axis=1
)
else:
self.full_q_loss_t = (1 / 2) * tf.reduce_mean(tf.square(self.q_values_pl - self.q_prediction_t), axis=1)
self.q_loss_t = tf.reduce_mean(self.full_q_loss_t, axis=0)
class QPredictionModelGMMPrior(QPredictionModel):
def __init__(self, input_shape, num_blocks, num_components, num_actions, encoder_filters, encoder_filter_sizes,
encoder_strides, encoder_neurons, learning_rate_encoder, beta0, beta1, beta2, weight_decay, optimizer_encoder,
max_steps, batch_norm=True, no_sample=False, softplus=False, only_one_q_value=False,
old_bn_settings=False):
super(QPredictionModelGMMPrior, self).__init__(
input_shape, num_blocks, num_actions, encoder_filters, encoder_filter_sizes,
encoder_strides, encoder_neurons, learning_rate_encoder, weight_decay, optimizer_encoder,
max_steps, batch_norm=batch_norm, no_sample=no_sample, softplus=softplus, only_one_q_value=only_one_q_value,
old_bn_settings=old_bn_settings
)
self.num_components = num_components
self.beta0 = beta0
self.beta1 = beta1
self.beta2 = beta2
def encode(self, depths, hand_states, batch_size=100, zero_sd=False):
num_steps = int(np.ceil(depths.shape[0] / batch_size))
embeddings = []
sample_probs = []
for i in range(num_steps):
batch_slice = np.index_exp[i * batch_size:(i + 1) * batch_size]
feed_dict = {
self.states_pl: depths[batch_slice],
self.hand_states_pl: hand_states[batch_slice],
self.is_training_pl: False
}
if zero_sd:
feed_dict[self.state_sd_t] = np.zeros(
(len(depths[batch_slice]), self.num_blocks), dtype=np.float32
)
embedding, sample_prob = self.session.run([self.state_mu_t, self.z1_log_cond_t], feed_dict=feed_dict)
embeddings.append(embedding)
sample_probs.append(sample_prob)
embeddings = np.concatenate(embeddings, axis=0)
sample_probs = np.concatenate(sample_probs, axis=0)
return embeddings, sample_probs
def validate(self, depths, hand_states, actions, q_values, batch_size=100):
num_steps = int(np.ceil(depths.shape[0] / batch_size))
losses = []
for i in range(num_steps):
batch_slice = np.index_exp[i * batch_size:(i + 1) * batch_size]
feed_dict = {
self.states_pl: depths[batch_slice],
self.hand_states_pl: hand_states[:, np.newaxis][batch_slice],
self.actions_pl: actions[batch_slice],
self.q_values_pl: q_values[batch_slice],
self.is_training_pl: False
}
tmp_losses = self.session.run(
[self.full_q_loss_t, self.full_prior_log_likelihood_t, self.full_encoder_entropy_t], feed_dict=feed_dict
)
losses.append(np.transpose(tmp_losses))
losses = np.concatenate(losses, axis=0)
return losses
def build_model(self):
self.build_encoders()
self.build_predictor()
self.build_mixture_components()
def build_mixture_components(self):
self.mixtures_mu_v = tf.get_variable(
"mixtures_mu", initializer=tf.random_normal_initializer(
mean=0.0, stddev=0.1, dtype=tf.float32
), shape=(self.num_components, self.num_blocks)
)
self.mixtures_logvar_v = tf.get_variable(
"mixtures_var", initializer=tf.random_normal_initializer(
mean=-1.0, stddev=0.1, dtype=tf.float32
), shape=(self.num_components, self.num_blocks)
)
self.mixtures_var_t = tf.exp(self.mixtures_logvar_v)
def build_training(self):
# create global training step variable
self.global_step = tf.train.get_or_create_global_step()
self.actions_mask_t = tf.one_hot(self.actions_pl, self.num_actions, dtype=tf.float32)
# build losses
self.build_q_loss()
self.build_encoder_entropy_loss()
self.build_prior_likelihood()
self.build_weight_decay_loss()
# build the whole loss
self.prior_loss_t = - self.prior_log_likelihood
self.loss_t = self.beta0 * self.q_loss_t + self.regularization_loss_t - self.beta1 * self.encoder_entropy_t - \
self.beta2 * self.prior_log_likelihood
# build training
self.build_encoder_training()
self.build_prior_training()
self.train_step = tf.group(self.encoder_train_step, self.prior_train_step)
def build_encoder_entropy_loss(self):
self.full_encoder_entropy_t = (1 / 2) * tf.reduce_sum(tf.log(self.state_var_t), axis=1) + \
(self.num_blocks / 2) * (1 + np.log(2 * np.pi))
self.encoder_entropy_t = tf.reduce_mean(self.full_encoder_entropy_t, axis=0)
def build_prior_likelihood(self):
self.z1_log_probs_t = self.many_multivariate_normals_log_pdf(
self.state_sample_t, self.mixtures_mu_v, self.mixtures_var_t, self.mixtures_logvar_v
)
self.z1_log_joint_t = self.z1_log_probs_t - np.log(self.num_components)
self.full_prior_log_likelihood_t = tf.reduce_logsumexp(self.z1_log_joint_t, axis=1)
self.prior_log_likelihood = tf.reduce_mean(self.full_prior_log_likelihood_t, axis=0)
self.z1_log_cond_t = self.z1_log_joint_t - self.full_prior_log_likelihood_t[:, tf.newaxis]
def build_encoder_training(self):
encoder_variables = tf.get_collection(tf.GraphKeys.TRAINABLE_VARIABLES, scope=self.ENCODER_NAMESPACE)
encoder_optimizer = agent_utils.get_optimizer(self.optimizer_encoder, self.learning_rate_encoder)
self.encoder_train_step = encoder_optimizer.minimize(
self.loss_t, global_step=self.global_step, var_list=encoder_variables
)
if self.batch_norm:
self.update_op = tf.group(*tf.get_collection(tf.GraphKeys.UPDATE_OPS, scope=self.ENCODER_NAMESPACE))
self.encoder_train_step = tf.group(self.encoder_train_step, self.update_op)
def build_prior_training(self):
mixture_variables = [self.mixtures_mu_v, self.mixtures_logvar_v]
mixture_optimizer = agent_utils.get_optimizer(self.optimizer_encoder, self.learning_rate_encoder)
self.prior_train_step = mixture_optimizer.minimize(
self.prior_loss_t, global_step=self.global_step, var_list=mixture_variables
)
def build_summaries(self):
# losses
tf.summary.scalar("loss", tf.reduce_mean(self.loss_t))
tf.summary.scalar("q loss", tf.reduce_mean(self.q_loss_t))
tf.summary.scalar("reg loss", tf.reduce_mean(self.regularization_loss_t))
tf.summary.scalar("entropy loss", tf.reduce_mean(- self.encoder_entropy_t))
tf.summary.scalar("prior loss", tf.reduce_mean(- self.prior_log_likelihood))
tf.summary.scalar("entropy loss weighted", tf.reduce_mean(- self.beta1 * self.encoder_entropy_t))
tf.summary.scalar("prior loss weighted", tf.reduce_mean(- self.beta2 * self.prior_log_likelihood))
# encoder outputs
self.summarize(self.state_mu_t, "means")
self.summarize(self.state_var_t, "vars")
self.summarize(self.state_sample_t, "samples")
# mixture
self.summarize(self.mixtures_mu_v, "mixture_means")
self.summarize(self.mixtures_var_t, "mixture_vars")
# encoder gradients
self.summarize(
tf.norm(tf.gradients(self.q_loss_t, self.state_sample_t), ord=2, axis=1),
"q_state_sample_grads"
)
self.summarize(
tf.norm(tf.gradients(- self.beta1 * self.encoder_entropy_t, self.state_var_t), ord=2, axis=1),
"entropy_state_var_grads"
)
self.summarize(
tf.norm(tf.gradients(- self.beta2 * self.prior_log_likelihood, self.state_sample_t), ord=2, axis=1),
"prior_state_sample_grads"
)
@staticmethod
def many_multivariate_normals_log_pdf(x, mu, var, logvar):
x = x[:, tf.newaxis, :]
mu = mu[tf.newaxis, :, :]
var = var[tf.newaxis, :, :]
logvar = logvar[tf.newaxis, :, :]
term1 = - (mu.shape[2].value / 2) * np.log(2 * np.pi)
term2 = - (1 / 2) * tf.reduce_sum(logvar, axis=2)
term3 = - (1 / 2) * tf.reduce_sum(tf.square(x - mu) / var, axis=2)
return term1 + term2 + term3
class ClusterQPredictionModelGMMPrior(QPredictionModelGMMPrior):
def __init__(self, input_shape, num_blocks, num_components, num_actions, encoder_filters, encoder_filter_sizes,
encoder_strides, encoder_neurons, learning_rate_encoder, beta0, beta1, beta2, weight_decay, optimizer_encoder,
max_steps, batch_norm=True, no_sample=False, softplus=False, only_one_q_value=False,
mixtures_logvar_mean=-1.0):
super(ClusterQPredictionModelGMMPrior, self).__init__(
input_shape, num_blocks, num_components, num_actions, encoder_filters, encoder_filter_sizes,
encoder_strides, encoder_neurons, learning_rate_encoder, beta0, beta1, beta2, weight_decay,
optimizer_encoder, max_steps, batch_norm=batch_norm, no_sample=no_sample, softplus=softplus,
only_one_q_value=only_one_q_value
)
self.mixtures_logvar_mean = mixtures_logvar_mean
def build_model(self):
self.build_encoders()
self.build_mixture_components()
def build_mixture_components(self):
self.mixtures_mu_v = tf.get_variable(
"mixtures_mu", initializer=tf.random_normal_initializer(
mean=0.0, stddev=0.1, dtype=tf.float32
), shape=(self.num_components, self.num_blocks)
)
self.mixtures_logvar_v = tf.get_variable(
"mixtures_var", initializer=tf.random_normal_initializer(
mean=self.mixtures_logvar_mean, stddev=0.1, dtype=tf.float32
), shape=(self.num_components, self.num_blocks)
)
self.mixtures_var_t = tf.exp(self.mixtures_logvar_v)
self.mixtures_qs = tf.get_variable(
"mixtures_qs", initializer=tf.random_normal_initializer(
mean=0.0, stddev=0.1, dtype=tf.float32
), shape=(self.num_components, self.num_actions)
)
def build_training(self):
# create global training step variable
self.global_step = tf.train.get_or_create_global_step()
self.actions_mask_t = tf.one_hot(self.actions_pl, self.num_actions, dtype=tf.float32)
# build losses
self.build_encoder_entropy_loss()
self.build_prior_likelihood()
self.build_q_loss()
self.build_weight_decay_loss()
# build the whole loss
self.prior_loss_t = - self.prior_log_likelihood
self.loss_t = self.beta0 * self.q_loss_t + self.regularization_loss_t - self.beta1 * self.encoder_entropy_t - \
self.beta2 * self.prior_log_likelihood
# build training
self.build_encoder_training()
self.build_prior_training()
self.train_step = tf.group(self.encoder_train_step, self.prior_train_step)
def build_prior_likelihood(self):
self.sample_probs_t = self.many_multivariate_normals_log_pdf(
self.state_sample_t, self.mixtures_mu_v, self.mixtures_var_t, self.mixtures_logvar_v
)
self.sample_probs_t -= np.log(self.num_components)
d_max = tf.reduce_max(self.sample_probs_t, axis=1)
self.full_prior_log_likelihood_t = d_max + tf.log(
tf.reduce_sum(tf.exp(self.sample_probs_t - d_max[:, tf.newaxis]), axis=1)
)
self.prior_log_likelihood = tf.reduce_mean(self.full_prior_log_likelihood_t, axis=0)
self.sample_log_cond_t = self.sample_probs_t - self.full_prior_log_likelihood_t[:, tf.newaxis]
def build_q_loss(self):
# B x A
self.q_prediction_t = tf.matmul(self.sample_log_cond_t, self.mixtures_qs)
if self.only_one_q_value:
self.full_q_loss_t = (1 / 2) * tf.reduce_sum(
tf.square(self.q_values_pl - self.q_prediction_t) * self.actions_mask_t, axis=1
)
else:
self.full_q_loss_t = (1 / 2) * tf.reduce_mean(tf.square(self.q_values_pl - self.q_prediction_t), axis=1)
self.q_loss_t = tf.reduce_mean(self.full_q_loss_t, axis=0)
def build_prior_training(self):
mixture_variables = [self.mixtures_mu_v, self.mixtures_logvar_v, self.mixtures_qs]
mixture_optimizer = agent_utils.get_optimizer(self.optimizer_encoder, self.learning_rate_encoder)
self.prior_train_step = mixture_optimizer.minimize(
self.prior_loss_t, global_step=self.global_step, var_list=mixture_variables
)
class QPredictionModelGMMPriorWithTransitions(QPredictionModelGMMPrior):
def __init__(self, input_shape, num_blocks, num_components, num_actions, encoder_filters, encoder_filter_sizes,
encoder_strides, encoder_neurons, learning_rate_encoder, beta0, beta1, beta2, beta3, weight_decay,
optimizer_encoder, max_steps, batch_norm=True, no_sample=False, softplus=False,
only_one_q_value=False, transition_hiddens=tuple()):
super(QPredictionModelGMMPriorWithTransitions, self).__init__(
input_shape, num_blocks, num_components, num_actions, encoder_filters, encoder_filter_sizes,
encoder_strides, encoder_neurons, learning_rate_encoder, beta0, beta1, beta2, weight_decay,
optimizer_encoder, max_steps, batch_norm=batch_norm, no_sample=no_sample, softplus=softplus,
only_one_q_value=only_one_q_value
)
self.beta3 = beta3
self.transition_hiddens = transition_hiddens
def validate(self, depths, hand_states, actions, q_values, next_depths, next_hand_states, dones, batch_size=100):
num_steps = int(np.ceil(depths.shape[0] / batch_size))
losses = []
for i in range(num_steps):
batch_slice = np.index_exp[i * batch_size:(i + 1) * batch_size]
feed_dict = {
self.states_pl: depths[batch_slice],
self.hand_states_pl: hand_states[:, np.newaxis][batch_slice],
self.actions_pl: actions[batch_slice],
self.q_values_pl: q_values[batch_slice],
self.next_states_pl: next_depths[batch_slice],
self.next_hand_states_pl: next_hand_states[:, np.newaxis][batch_slice],
self.dones_pl: dones[batch_slice],
self.is_training_pl: False
}
l1, l2 = self.session.run([self.full_q_loss_t, self.full_transition_loss_t], feed_dict=feed_dict)
losses.append(np.transpose(np.array([l1, l2]), axes=(1, 0)))
losses = np.concatenate(losses, axis=0)
return losses
def build_placeholders(self):
self.states_pl = tf.placeholder(tf.float32, shape=(None, *self.input_shape), name="states_pl")
self.actions_pl = tf.placeholder(tf.int32, shape=(None,), name="actions_pl")
self.q_values_pl = tf.placeholder(tf.float32, shape=(None, self.num_actions), name="q_values_pl")
self.dones_pl = tf.placeholder(tf.bool, shape=(None,), name="dones_pl")
self.next_states_pl = tf.placeholder(tf.float32, shape=(None, *self.input_shape), name="next_states_pl")
self.is_training_pl = tf.placeholder(tf.bool, shape=[], name="is_training_pl")
self.hand_states_pl = tf.placeholder(tf.float32, shape=(None, 1), name="hand_states_pl")
self.next_hand_states_pl = tf.placeholder(tf.float32, shape=(None, 1), name="next_hand_states_pl")
def build_encoders(self):
self.state_mu_t, self.state_var_t, self.state_sd_t, self.state_sample_t = \
self.build_encoder(
self.states_pl, self.hand_states_pl, share_weights=False, namespace=self.ENCODER_NAMESPACE
)
self.next_state_mu_t, self.next_state_var_t, self.next_state_sd_t, self.next_state_sample_t = \
self.build_encoder(
self.next_states_pl, self.next_hand_states_pl, share_weights=True, namespace=self.ENCODER_NAMESPACE
)
def build_predictor(self):
with tf.variable_scope(self.ENCODER_NAMESPACE):
with tf.variable_scope("q_predictions"):
self.q_prediction_t = tf.layers.dense(
self.state_sample_t, self.num_actions,
kernel_initializer=agent_utils.get_xavier_initializer(),
kernel_regularizer=agent_utils.get_weight_regularizer(self.weight_decay)
)
with tf.variable_scope(self.ENCODER_NAMESPACE):
with tf.variable_scope("transition_predictions"):
x = self.state_sample_t
for idx, neurons in enumerate(self.transition_hiddens):
with tf.variable_scope("fc{:d}".format(idx)):
x = tf.layers.dense(
x, neurons, activation=tf.nn.relu if not self.batch_norm else None,
kernel_regularizer=agent_utils.get_weight_regularizer(self.weight_decay),
kernel_initializer=agent_utils.get_mrsa_initializer(),
use_bias=not self.batch_norm
)
if self.batch_norm:
x = tf.layers.batch_normalization(x, training=self.is_training_pl)
x = tf.nn.relu(x)
self.transition_prediction_t = tf.layers.dense(
x, self.num_blocks * self.num_actions,
kernel_initializer=agent_utils.get_xavier_initializer(),
kernel_regularizer=agent_utils.get_weight_regularizer(self.weight_decay)
)
self.transition_prediction_t = tf.reshape(
self.transition_prediction_t, (-1, self.num_actions, self.num_blocks)
)
def build_training(self):
# create global training step variable
self.global_step = tf.train.get_or_create_global_step()
self.actions_mask_t = tf.one_hot(self.actions_pl, self.num_actions, dtype=tf.float32)
self.float_dones_t = tf.cast(self.dones_pl, tf.float32)
# build losses
self.build_q_loss()
self.build_encoder_entropy_loss()
self.build_prior_likelihood()
self.build_transition_loss()
self.build_weight_decay_loss()
# build the whole loss
self.loss_t = self.beta0 * self.q_loss_t + self.regularization_loss_t - self.beta1 * self.encoder_entropy_t - \
self.beta2 * self.prior_log_likelihood + self.beta3 * self.transition_loss_t
# build training
self.build_encoder_training()
self.train_step = self.encoder_train_step
def build_transition_loss(self):
self.masked_transition_prediction_t = tf.reduce_sum(
self.transition_prediction_t * self.actions_mask_t[:, :, tf.newaxis], axis=1
)
if self.propagate_next_state:
term1 = tf.reduce_sum(
tf.square(self.next_state_sample_t - self.masked_transition_prediction_t), axis=1
)
else:
term1 = tf.reduce_sum(
tf.square(tf.stop_gradient(self.next_state_sample_t) - self.masked_transition_prediction_t), axis=1
)
self.full_transition_loss_t = (1 / 2) * term1 * (1 - self.float_dones_t)
self.transition_loss_t = tf.reduce_sum(self.full_transition_loss_t, axis=0) / tf.reduce_max(
[1.0, tf.reduce_sum(1 - self.float_dones_t)])
class QPredictionModelFakeHMMPrior(QPredictionModelGMMPrior):
def __init__(self, input_shape, num_blocks, num_components, num_actions, encoder_filters, encoder_filter_sizes,
encoder_strides, encoder_neurons, learning_rate_encoder, beta0, beta1, beta2, weight_decay,
optimizer_encoder, max_steps, batch_norm=True, no_sample=False, softplus=False,
only_one_q_value=False):
super(QPredictionModelFakeHMMPrior, self).__init__(
input_shape, num_blocks, num_components, num_actions, encoder_filters, encoder_filter_sizes,
encoder_strides, encoder_neurons, learning_rate_encoder, beta0, beta1, beta2, weight_decay,
optimizer_encoder, max_steps, batch_norm=batch_norm, no_sample=no_sample, softplus=softplus,
only_one_q_value=only_one_q_value
)
def predict_next_states(self, depths, hand_states, actions, batch_size=100):
num_steps = int(np.ceil(depths.shape[0] / batch_size))
embeddings = []
for i in range(num_steps):
batch_slice = np.index_exp[i * batch_size:(i + 1) * batch_size]
feed_dict = {
self.states_pl: depths[batch_slice],
self.hand_states_pl: hand_states[:, np.newaxis][batch_slice],
self.actions_pl: actions[batch_slice],
self.is_training_pl: False
}
tmp_embeddings = self.session.run(self.next_state_observations, feed_dict=feed_dict)
embeddings.append(tmp_embeddings)
embeddings = np.concatenate(embeddings, axis=0)
return embeddings
def build_placeholders(self):
self.states_pl = tf.placeholder(tf.float32, shape=(None, *self.input_shape), name="states_pl")
self.actions_pl = tf.placeholder(tf.int32, shape=(None,), name="actions_pl")
self.q_values_pl = tf.placeholder(tf.float32, shape=(None, self.num_actions), name="q_values_pl")
self.dones_pl = tf.placeholder(tf.bool, shape=(None,), name="dones_pl")
self.next_states_pl = tf.placeholder(tf.float32, shape=(None, *self.input_shape), name="next_states_pl")
self.is_training_pl = tf.placeholder(tf.bool, shape=[], name="is_training_pl")
self.hand_states_pl = tf.placeholder(tf.float32, shape=(None, 1), name="hand_states_pl")
self.next_hand_states_pl = tf.placeholder(tf.float32, shape=(None, 1), name="next_hand_states_pl")
def build_encoders(self):
self.state_mu_t, self.state_var_t, self.state_sd_t, self.state_sample_t = \
self.build_encoder(
self.states_pl, self.hand_states_pl, share_weights=False, namespace=self.ENCODER_NAMESPACE
)
self.next_state_mu_t, self.next_state_var_t, self.next_state_sd_t, self.next_state_sample_t = \
self.build_encoder(
self.next_states_pl, self.next_hand_states_pl, share_weights=True, namespace=self.ENCODER_NAMESPACE
)
def build_model(self):
self.build_encoders()
self.build_predictor()
self.build_mixture_components()
self.build_transition_matrix()
def build_transition_matrix(self):
self.t_v = tf.get_variable(
"transition_matrix", shape=(self.num_actions, self.num_components, self.num_components), dtype=tf.float32,
initializer=tf.random_normal_initializer(mean=0.0, stddev=1.0, dtype=tf.float32)
)
self.t_softmax_t = tf.nn.softmax(self.t_v, axis=2)
self.t_logsoftmax_t = tf.nn.log_softmax(self.t_v, axis=2)
def build_training(self):
# create global training step variable
self.global_step = tf.train.get_or_create_global_step()
self.actions_mask_t = tf.one_hot(self.actions_pl, self.num_actions, dtype=tf.float32)
self.gather_t_logsoftmax_t = tf.gather(self.t_logsoftmax_t, self.actions_pl)
# build losses
self.build_q_loss()
self.build_encoder_entropy_loss()
self.build_prior_likelihood()
self.build_weight_decay_loss()
# build the whole loss
self.loss_t = self.beta0 * self.q_loss_t + self.regularization_loss_t - self.beta1 * self.encoder_entropy_t - \
self.beta2 * self.prior_log_likelihood
# build training
self.build_encoder_training()
self.train_step = self.encoder_train_step
def build_prior_likelihood(self):
self.z1_ll, self.z1_log_probs, self.d1 = self.build_sample_likelihood(self.state_sample_t)
self.z2_ll, self.z2_log_probs, self.d2 = self.build_sample_likelihood(self.next_state_sample_t)
self.sample_probs_t = self.z1_log_probs
self.z1_log_cond = self.z1_log_probs - self.z1_ll[:, tf.newaxis]
self.z2_log_cond = self.z2_log_probs - self.z2_ll[:, tf.newaxis]
self.prior_log_likelihood = self.z1_ll[:, tf.newaxis, tf.newaxis] + self.gather_t_logsoftmax_t + \
tf.stop_gradient(self.z1_log_cond[:, :, tf.newaxis]) + tf.stop_gradient(self.z2_log_cond[:, tf.newaxis, :])
self.full_prior_log_likelihood = tf.reduce_logsumexp(self.prior_log_likelihood, axis=[1, 2])
self.prior_log_likelihood = tf.reduce_mean(self.full_prior_log_likelihood, axis=0)
self.next_cluster_prediction = tf.reduce_logsumexp(
self.z1_log_cond[:, :, tf.newaxis] + self.gather_t_logsoftmax_t, axis=1
)
self.next_cluster_assignment = tf.argmax(self.next_cluster_prediction, axis=1, output_type=tf.int32)
self.next_state_observations = self.d2.sample(tf.shape(self.next_cluster_assignment)[0])
self.next_cluster_mask = tf.one_hot(self.next_cluster_assignment, self.num_components, dtype=tf.float32)
self.next_state_observations = tf.reduce_sum(
self.next_state_observations * self.next_cluster_mask[:, :, tf.newaxis], axis=1
)
def build_sample_likelihood(self, sample_t):
d = tf.contrib.distributions.MultivariateNormalDiag(
loc=self.mixtures_mu_v, scale_diag=tf.sqrt(self.mixtures_var_t)
)
sample_probs_t = d.log_prob(sample_t[:, tf.newaxis, :])
sample_probs_t -= np.log(self.num_components)
d_max = tf.reduce_max(sample_probs_t, axis=1)
full_sample_log_likelihood_t = d_max + tf.log(
tf.reduce_sum(tf.exp(sample_probs_t - d_max[:, tf.newaxis]), axis=1)
)
return full_sample_log_likelihood_t, sample_probs_t, d
def build_encoder_training(self):
encoder_variables = tf.get_collection(tf.GraphKeys.TRAINABLE_VARIABLES, scope=self.ENCODER_NAMESPACE)
mixture_variables = [self.mixtures_mu_v, self.mixtures_logvar_v, self.t_v]
all_variables = encoder_variables + mixture_variables
encoder_optimizer = agent_utils.get_optimizer(self.optimizer_encoder, self.learning_rate_encoder)
self.encoder_train_step = encoder_optimizer.minimize(
self.loss_t, global_step=self.global_step, var_list=all_variables
)
if self.batch_norm:
self.update_op = tf.group(*tf.get_collection(tf.GraphKeys.UPDATE_OPS))
self.encoder_train_step = tf.group(self.encoder_train_step, self.update_op)
class QPredictionModelHMMPrior(QPredictionModelGMMPrior):
def __init__(self, input_shape, num_blocks, num_components, num_actions, encoder_filters, encoder_filter_sizes,
encoder_strides, encoder_neurons, learning_rate_encoder, beta0, beta1, beta2,
weight_decay, optimizer_encoder, max_steps, batch_norm=True, no_sample=False, softplus=False,
only_one_q_value=False, beta3=0.0, alpha=0.1, cluster_predict_qs=False,
cluster_predict_qs_weight=0.1, old_bn_settings=False, fix_prior_training=True,
learning_rate_steps=None, learning_rate_values=None, model_learning_rate=None):
super(QPredictionModelHMMPrior, self).__init__(
input_shape, num_blocks, num_components, num_actions, encoder_filters, encoder_filter_sizes,
encoder_strides, encoder_neurons, learning_rate_encoder, beta0, beta1, beta2, weight_decay,
optimizer_encoder, max_steps, batch_norm=batch_norm, no_sample=no_sample, softplus=softplus,
only_one_q_value=only_one_q_value, old_bn_settings=old_bn_settings
)
self.beta3 = beta3
self.alpha = alpha
self.cluster_predict_qs = cluster_predict_qs
self.cluster_predict_qs_weight = cluster_predict_qs_weight
self.fix_prior_training = fix_prior_training
self.learning_rate_steps = learning_rate_steps
self.learning_rate_values = learning_rate_values
self.learning_rate_model = model_learning_rate
def encode(self, depths, hand_states, batch_size=100, zero_sd=False, new_means=None):
num_steps = int(np.ceil(depths.shape[0] / batch_size))
embeddings = []
sample_probs = []
for i in range(num_steps):
batch_slice = np.index_exp[i * batch_size:(i + 1) * batch_size]
feed_dict = {
self.states_pl: depths[batch_slice],
self.hand_states_pl: hand_states[batch_slice],
self.is_training_pl: False
}
if zero_sd:
feed_dict[self.state_sd_t] = np.zeros(
(len(depths[batch_slice]), self.num_blocks), dtype=np.float32
)
if new_means is not None:
feed_dict[self.mixtures_mu_v] = new_means
embedding, sample_prob = self.session.run([self.state_mu_t, self.z1_log_cond], feed_dict=feed_dict)
embeddings.append(embedding)
sample_probs.append(sample_prob)
embeddings = np.concatenate(embeddings, axis=0)
sample_probs = np.concatenate(sample_probs, axis=0)
return embeddings, sample_probs
def validate(self, depths, hand_states, actions, q_values, next_depths, next_hand_states, dones, batch_size=100):
num_steps = int(np.ceil(depths.shape[0] / batch_size))
losses = []
for i in range(num_steps):
batch_slice = np.index_exp[i * batch_size:(i + 1) * batch_size]
feed_dict = {
self.states_pl: depths[batch_slice],
self.hand_states_pl: hand_states[:, np.newaxis][batch_slice],
self.next_states_pl: next_depths[batch_slice],
self.next_hand_states_pl: next_hand_states[:, np.newaxis][batch_slice],
self.actions_pl: actions[batch_slice],
self.q_values_pl: q_values[batch_slice],
self.dones_pl: dones[batch_slice],
self.is_training_pl: False
}
tmp_losses = self.session.run(
[self.full_q_loss_t, self.full_prior_log_likelihood, self.full_encoder_entropy_t], feed_dict=feed_dict
)
losses.append(np.transpose(tmp_losses))
losses = np.concatenate(losses, axis=0)
return losses
def predict_next_states(self, depths, hand_states, actions, batch_size=100, zero_sd=False, new_means=None):
num_steps = int(np.ceil(depths.shape[0] / batch_size))
embeddings = []
predictions = []
assignments = []
assignments_hard = []
for i in range(num_steps):
batch_slice = np.index_exp[i * batch_size:(i + 1) * batch_size]
feed_dict = {
self.states_pl: depths[batch_slice],
self.hand_states_pl: hand_states[:, np.newaxis][batch_slice],
self.actions_pl: actions[batch_slice],
self.is_training_pl: False
}
if zero_sd:
feed_dict[self.state_sd_t] = np.zeros(
(len(depths[batch_slice]), self.num_blocks), dtype=np.float32
)
if new_means is not None:
feed_dict[self.mixtures_mu_v] = new_means
tmp_embeddings, tmp_prediction, tmp_assignment, tmp_assignment_hard = self.session.run(
[self.next_state_observations, self.next_cluster_prediction, self.next_cluster_assignment,
self.next_cluster_assignment_hard],
feed_dict=feed_dict
)
embeddings.append(tmp_embeddings)
predictions.append(tmp_prediction)
assignments.append(tmp_assignment)
assignments_hard.append(tmp_assignment_hard)
embeddings = np.concatenate(embeddings, axis=0)
predictions = np.concatenate(predictions, axis=0)
assignments = np.concatenate(assignments, axis=0)
assignments_hard = np.concatenate(assignments_hard, axis=0)
return embeddings, predictions, assignments, assignments_hard
def build_placeholders(self):
self.states_pl = tf.placeholder(tf.float32, shape=(None, *self.input_shape), name="states_pl")
self.actions_pl = tf.placeholder(tf.int32, shape=(None,), name="actions_pl")
self.q_values_pl = tf.placeholder(tf.float32, shape=(None, self.num_actions), name="q_values_pl")
self.dones_pl = tf.placeholder(tf.bool, shape=(None,), name="dones_pl")
self.float_dones_t = tf.cast(self.dones_pl, tf.float32)
self.next_states_pl = tf.placeholder(tf.float32, shape=(None, *self.input_shape), name="next_states_pl")
self.is_training_pl = tf.placeholder(tf.bool, shape=[], name="is_training_pl")
self.hand_states_pl = tf.placeholder(tf.float32, shape=(None, 1), name="hand_states_pl")
self.next_hand_states_pl = tf.placeholder(tf.float32, shape=(None, 1), name="next_hand_states_pl")
def build_encoders(self):
self.state_mu_t, self.state_var_t, self.state_sd_t, self.state_sample_t = \
self.build_encoder(
self.states_pl, self.hand_states_pl, share_weights=False, namespace=self.ENCODER_NAMESPACE
)
self.next_state_mu_t, self.next_state_var_t, self.next_state_sd_t, self.next_state_sample_t = \
self.build_encoder(
self.next_states_pl, self.next_hand_states_pl, share_weights=True, namespace=self.ENCODER_NAMESPACE
)
def build_model(self):
self.build_encoders()
self.build_predictor()
self.build_mixture_components()
self.build_hmm_variables()
def build_hmm_variables(self):
self.t_v = tf.get_variable(
"transition_matrix", shape=(self.num_actions, self.num_components, self.num_components), dtype=tf.float32,
initializer=tf.random_normal_initializer(mean=0.0, stddev=1.0, dtype=tf.float32)
)
self.t_softmax_t = tf.nn.softmax(self.t_v, axis=2)
self.t_logsoftmax_t = tf.nn.log_softmax(self.t_v, axis=2)
self.prior_v = tf.get_variable(
"prior", shape=(self.num_components,),
initializer=tf.constant_initializer(value=0, dtype=tf.float32)
)
self.prior_softmax_t = tf.nn.softmax(self.prior_v, axis=0)
self.prior_logsoftmax_t = tf.nn.log_softmax(self.prior_v, axis=0)
def build_training(self):
# create global training step variable
self.global_step = tf.train.get_or_create_global_step()
self.actions_mask_t = tf.one_hot(self.actions_pl, self.num_actions, dtype=tf.float32)
self.gather_t_logsoftmax_t = tf.gather(self.t_logsoftmax_t, self.actions_pl)
# setup learning rate
if self.learning_rate_steps is not None and self.learning_rate_values is not None:
assert len(self.learning_rate_steps) == len(self.learning_rate_values) - 1
self.learning_rate_steps_to_tensor()
# build losses
self.build_q_loss()
self.build_encoder_entropy_loss()
self.build_prior_likelihood()
self.build_weight_decay_loss()
self.beta1_v = tf.get_variable(
"beta1", initializer=tf.constant_initializer(self.beta1, dtype=tf.float32), shape=[]
)
# build the whole loss
self.loss_t = self.beta0 * self.q_loss_t + self.regularization_loss_t - \
tf.stop_gradient(self.beta1_v) * self.encoder_entropy_t - \
self.beta2 * self.prior_log_likelihood
self.prior_loss_t = - self.prior_log_likelihood
# predict q values for clusters as well
if self.cluster_predict_qs:
self.build_cluster_qs_predictor()
self.loss_t += self.cluster_predict_qs_weight * self.cluster_q_loss_t
# build training
if self.fix_prior_training:
self.build_encoder_training_fixed()
self.train_step = tf.group(self.encoder_train_step, self.prior_train_step)
else:
self.build_encoder_training()
self.train_step = self.encoder_train_step
def build_cluster_qs_predictor(self):
self.cluster_qs_v = tf.get_variable(
"cluster_qs", shape=(self.num_components, self.num_actions),
initializer=tf.random_normal_initializer(mean=0.0, stddev=0.1)
)
self.cluster_q_prediction_t = tf.reduce_sum(
self.z1_log_cond[:, :, tf.newaxis] * self.cluster_qs_v[tf.newaxis, :, :], axis=1
)
if self.only_one_q_value:
self.full_cluster_q_loss_t = (1 / 2) * tf.reduce_sum(
tf.square(self.q_values_pl - self.cluster_q_prediction_t) * self.actions_mask_t, axis=1
)
else:
self.full_cluster_q_loss_t = (1 / 2) * tf.reduce_mean(
tf.square(self.q_values_pl - self.cluster_q_prediction_t), axis=1
)
self.cluster_q_loss_t = tf.reduce_mean(self.full_cluster_q_loss_t, axis=0)
def build_prior_likelihood(self):
self.z2_prior = tf.reduce_logsumexp(
self.gather_t_logsoftmax_t + self.prior_logsoftmax_t[tf.newaxis, :, tf.newaxis], axis=1
)
self.z1_ll, self.z1_log_probs, self.d1 = self.build_sample_likelihood(
self.state_sample_t, self.prior_logsoftmax_t[tf.newaxis, :]
)
self.z2_ll, self.z2_log_probs, self.d2 = self.build_sample_likelihood(
self.next_state_sample_t, self.z2_prior
)
self.sample_probs_t = self.z1_log_probs
self.z1_log_cond = self.z1_log_probs + self.prior_logsoftmax_t - self.z1_ll[:, tf.newaxis]
self.z2_log_cond = self.z2_log_probs + self.z2_prior - self.z2_ll[:, tf.newaxis]
self.build_dirichlet_prior()
self.prior_log_likelihood = self.z1_log_probs[:, :, tf.newaxis] + \
self.prior_logsoftmax_t[tf.newaxis, :, tf.newaxis] + \
self.beta3 * self.dirichlet_prior_log_prob + \
(
tf.stop_gradient(self.z2_log_probs[:, tf.newaxis, :]) +
self.gather_t_logsoftmax_t
) * (1 - self.float_dones_t)[:, tf.newaxis, tf.newaxis]
self.full_prior_log_likelihood = tf.reduce_logsumexp(self.prior_log_likelihood, axis=[1, 2])
self.prior_log_likelihood = tf.reduce_mean(self.full_prior_log_likelihood, axis=0)
self.next_cluster_prediction = tf.reduce_logsumexp(
self.z1_log_cond[:, :, tf.newaxis] + self.gather_t_logsoftmax_t, axis=1
)
self.next_cluster_prediction_hard = tf.reduce_logsumexp(
tf.one_hot(
tf.argmax(self.z1_log_cond, axis=1), self.z1_log_cond.shape[1].value, dtype=tf.float32
)[:, :, tf.newaxis] + self.gather_t_logsoftmax_t, axis=1
)
self.next_cluster_assignment = tf.argmax(self.next_cluster_prediction, axis=1, output_type=tf.int32)
self.next_cluster_assignment_hard = tf.argmax(self.next_cluster_prediction_hard, axis=1, output_type=tf.int32)
self.next_state_observations = self.d2.sample(tf.shape(self.next_cluster_assignment)[0])
self.next_cluster_mask = tf.one_hot(self.next_cluster_assignment, self.num_components, dtype=tf.float32)
self.next_state_observations = tf.reduce_sum(
self.next_state_observations * self.next_cluster_mask[:, :, tf.newaxis], axis=1
)
def build_dirichlet_prior(self):
self.dirichlet_prior_d = tf.contrib.distributions.Dirichlet(
np.ones(self.num_components, dtype=np.float32) * self.alpha, allow_nan_stats=False
)
self.dirichlet_prior_log_prob = self.dirichlet_prior_d.log_prob(self.prior_softmax_t)
def build_sample_likelihood(self, sample_t, log_prior_t):
d = tf.contrib.distributions.MultivariateNormalDiag(
loc=self.mixtures_mu_v, scale_diag=tf.sqrt(self.mixtures_var_t)
)
sample_log_probs_t = d.log_prob(sample_t[:, tf.newaxis, :])
sample_log_joint_t = sample_log_probs_t + log_prior_t
d_max = tf.reduce_max(sample_log_joint_t, axis=1)
full_sample_log_likelihood_t = d_max + tf.log(
tf.reduce_sum(tf.exp(sample_log_joint_t - d_max[:, tf.newaxis]), axis=1)
)
return full_sample_log_likelihood_t, sample_log_probs_t, d
def build_encoder_training(self):
encoder_variables = tf.get_collection(tf.GraphKeys.TRAINABLE_VARIABLES, scope=self.ENCODER_NAMESPACE)
mixture_variables = [self.mixtures_mu_v, self.mixtures_logvar_v, self.t_v]
all_variables = encoder_variables + mixture_variables
encoder_optimizer = agent_utils.get_optimizer(self.optimizer_encoder, self.learning_rate_encoder)
hmm_optimizer = agent_utils.get_optimizer(self.optimizer_encoder, self.learning_rate_encoder)
T_and_prior_optimizer = agent_utils.get_optimizer(self.optimizer_encoder, self.learning_rate_encoder)
prior_optimizer = agent_utils.get_optimizer(self.optimizer_encoder, self.learning_rate_encoder)
self.encoder_train_step = encoder_optimizer.minimize(
self.loss_t, global_step=self.global_step, var_list=all_variables
)
self.hmm_train_step = hmm_optimizer.minimize(
self.loss_t, var_list=[self.t_v, self.prior_v, self.mixtures_mu_v, self.mixtures_logvar_v]
)
self.T_and_prior_train_step = T_and_prior_optimizer.minimize(
self.loss_t, var_list=[self.t_v, self.prior_v]
)
self.prior_train_step = prior_optimizer.minimize(
self.loss_t, var_list=[self.prior_v]
)
if self.batch_norm:
self.update_op = tf.group(*tf.get_collection(tf.GraphKeys.UPDATE_OPS))
self.encoder_train_step = tf.group(self.encoder_train_step, self.update_op)
def build_encoder_training_fixed(self):
encoder_variables = tf.get_collection(tf.GraphKeys.TRAINABLE_VARIABLES, scope=self.ENCODER_NAMESPACE)
mixture_variables = [self.mixtures_mu_v, self.mixtures_logvar_v, self.t_v]
all_mixture_variables = [self.mixtures_mu_v, self.mixtures_logvar_v, self.t_v, self.prior_v]
encoder_optimizer = agent_utils.get_optimizer(self.optimizer_encoder, self.learning_rate_encoder)
prior_optimizer = agent_utils.get_optimizer(self.optimizer_encoder, self.learning_rate_model)
self.encoder_train_step = encoder_optimizer.minimize(
self.loss_t, global_step=self.global_step, var_list=encoder_variables
)
self.prior_train_step = prior_optimizer.minimize(
self.prior_loss_t, global_step=self.global_step, var_list=mixture_variables
)
self.hmm_train_step = prior_optimizer.minimize(
self.prior_loss_t, global_step=self.global_step, var_list=all_mixture_variables
)
if self.batch_norm:
self.update_op = tf.group(*tf.get_collection(tf.GraphKeys.UPDATE_OPS))
self.encoder_train_step = tf.group(self.encoder_train_step, self.update_op)
def learning_rate_steps_to_tensor(self):
self.learning_rate_encoder = tf.train.piecewise_constant(
self.global_step, self.learning_rate_steps, self.learning_rate_values
)
| 42.712424 | 140 | 0.643875 | 32,747 | 245,810 | 4.482304 | 0.014505 | 0.015806 | 0.01879 | 0.014941 | 0.938037 | 0.916979 | 0.899831 | 0.882152 | 0.868294 | 0.857169 | 0 | 0.012156 | 0.2604 | 245,810 | 5,754 | 141 | 42.719847 | 0.795221 | 0.012831 | 0 | 0.739861 | 0 | 0 | 0.015195 | 0.000783 | 0 | 0 | 0 | 0.000174 | 0.00336 | 1 | 0.062155 | false | 0 | 0.0012 | 0.00024 | 0.088073 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 1 | 1 | 1 | 1 | 1 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 7 |
119d9ec651980bee1e5cf26dc261f17a521a702f | 28,333 | py | Python | src/utils/lstm.py | TranQuangDuc/SceneMover | 6d9b683baf909198eb206fdd64bfe8cc3ef0428e | [
"MIT"
] | 80 | 2020-08-06T14:21:19.000Z | 2022-03-01T02:11:05.000Z | src/utils/lstm.py | TranQuangDuc/SceneMover | 6d9b683baf909198eb206fdd64bfe8cc3ef0428e | [
"MIT"
] | 5 | 2020-10-19T06:55:06.000Z | 2021-06-17T09:47:32.000Z | src/utils/lstm.py | TranQuangDuc/SceneMover | 6d9b683baf909198eb206fdd64bfe8cc3ef0428e | [
"MIT"
] | 16 | 2020-08-09T14:59:12.000Z | 2021-07-28T08:40:29.000Z | import tensorflow as tf
class DQNetwork18_eval:
def __init__(self, batch_size, state_size=[5,5,4], action_space=5, num_objects=5, learning_rate=0.0002, seq_len = 50, name='DQNetwork'):
self.state_size = state_size
self.action_size = action_space*num_objects
self.learning_rate = learning_rate
self.seq_len = seq_len
with tf.variable_scope(name, reuse = True):
# We create the placeholders
# *state_size means that we take each elements of state_size in tuple hence is like if we wrote
# [None, 84, 84, 4]
self.inputs_ = tf.placeholder(tf.float32, [None, self.seq_len, *state_size], name="inputs")
# self.action_chain = tf.placeholder(tf.float32, [None, self.action_size * (frame_num-1)], name="action_chain")
# Remember that target_Q is the R(s,a) + ymax Qhat(s', a')
# self.conflict_matrix = tf.placeholder(tf.float32, [None, num_objects, num_objects, 2], name="conflict_matrix")
self.finish_tag = tf.placeholder(tf.float32,[None, self.seq_len, num_objects], name="finish_tag")
# conflict_matrix_and = tf.logical_and(tf.cast(self.conflict_matrix[...,0],tf.bool),tf.cast(self.conflict_matrix[...,1],tf.bool))
# self.conflict_matrix = tf.cast(self.conflict_matrix,tf.float32)
# conflict_matrix_and = tf.cast(conflict_matrix_and,tf.float32)
#self.state_in = ((tf.placeholder(tf.float32, [None, 256], name = "state_in_c1"), tf.placeholder(tf.float32, [None, 256], name = "state_in_h1")),
# (tf.placeholder(tf.float32, [None, 256], name = "state_in_c2"), tf.placeholder(tf.float32, [None, 256], name = "state_in_h2")))
self.state_in = tf.nn.rnn_cell.LSTMStateTuple(tf.placeholder(tf.float32, [None, 256], name = "lstm_c1"),
tf.placeholder(tf.float32, [None, 256], name = "lstm_h1"))
"""
First convnet:
CNN
BatchNormalization
ELU
"""
# Input is 15*15*55
self.inputs = tf.reshape(self.inputs_, [-1, *self.state_size])# combine the first two dims
self.conv1 = tf.layers.conv2d(inputs = self.inputs,
filters = 64,
kernel_size = [5,5],
strides = [2,2],
padding = "SAME",
kernel_initializer=tf.contrib.layers.xavier_initializer_conv2d(),
name = "conv1")
self.conv1_batchnorm = tf.layers.batch_normalization(self.conv1,
training = False,
epsilon = 1e-5,
name = 'batch_norm1')
self.conv1_out = tf.nn.elu(self.conv1_batchnorm, name="conv1_out")
## --> [8, 8, 64]
print('conv1_out',self.conv1_out)
"""
Second convnet:
ResNet block
BatchNormalization
ELU
"""
self.conv2_1 = tf.layers.conv2d(inputs = self.conv1_out,
filters = 64,
kernel_size = [3,3],
strides = [1,1],
padding = "SAME",
kernel_initializer=tf.contrib.layers.xavier_initializer_conv2d(),
name = "conv2_1")
self.conv2_batchnorm_1 = tf.layers.batch_normalization(self.conv2_1,
training = False,
epsilon = 1e-5,
name = 'batch_norm2_1')
self.conv2_out_1 = tf.nn.elu(self.conv2_batchnorm_1, name="conv2_out_1")
self.conv2_2 = tf.layers.conv2d(inputs = self.conv2_out_1,
filters = 64,
kernel_size = [1,1],
strides = [1,1],
padding = "SAME",
kernel_initializer=tf.contrib.layers.xavier_initializer_conv2d(),
name = "conv2_2")
self.conv2_batchnorm_2 = tf.layers.batch_normalization(self.conv2_2,
training = False,
epsilon = 1e-5,
name = 'batch_norm2_2')
self.conv2_out_2 = tf.nn.elu(self.conv2_batchnorm_2+self.conv1_out, name="conv2_out_2")
## --> [4, 4, 128]
print('conv2_out',self.conv2_out_2)
"""
Third convnet:
CNN
BatchNormalization
ELU
"""
# Input is 15*15*55
self.conv3 = tf.layers.conv2d(inputs = self.conv2_out_2,
filters = 128,
kernel_size = [3,3],
strides = [2,2],
padding = "SAME",
kernel_initializer=tf.contrib.layers.xavier_initializer_conv2d(),
name = "conv3")
self.conv3_batchnorm = tf.layers.batch_normalization(self.conv3,
training = False,
epsilon = 1e-5,
name = 'batch_norm3')
self.conv3_out = tf.nn.elu(self.conv3_batchnorm, name="conv3_out")
print('conv3_out',self.conv3_out)
"""
Forth convnet:
ResNet block
BatchNormalization
ELU
"""
self.conv4_1 = tf.layers.conv2d(inputs = self.conv3_out,
filters = 128,
kernel_size = [3,3],
strides = [1,1],
padding = "SAME",
kernel_initializer=tf.contrib.layers.xavier_initializer_conv2d(),
name = "conv4_1")
self.conv4_batchnorm_1 = tf.layers.batch_normalization(self.conv4_1,
training = False,
epsilon = 1e-5,
name = 'batch_norm4_1')
self.conv4_out_1 = tf.nn.elu(self.conv4_batchnorm_1, name="conv4_out_1")
self.conv4_2 = tf.layers.conv2d(inputs = self.conv4_out_1,
filters = 128,
kernel_size = [1,1],
strides = [1,1],
padding = "SAME",
kernel_initializer=tf.contrib.layers.xavier_initializer_conv2d(),
name = "conv4_2")
self.conv4_batchnorm_2 = tf.layers.batch_normalization(self.conv4_2,
training = False,
epsilon = 1e-5,
name = 'batch_norm4_2')
self.conv4_out_2 = tf.nn.elu(self.conv4_batchnorm_2+self.conv3_out, name="conv4_out_2")
print('conv4_out',self.conv4_out_2)
## --> [4, 4, 128]
"""
Fifth convnet:
CNN
BatchNormalization
ELU
"""
# Input is 15*15*55
self.conv5 = tf.layers.conv2d(inputs = self.conv4_out_2,
filters = 256,
kernel_size = [3,3],
strides = [2,2],
padding = "SAME",
kernel_initializer=tf.contrib.layers.xavier_initializer_conv2d(),
name = "conv5")
self.conv5_batchnorm = tf.layers.batch_normalization(self.conv5,
training = False,
epsilon = 1e-5,
name = 'batch_norm5')
self.conv5_out = tf.nn.elu(self.conv5_batchnorm, name="conv5_out")
print('conv5_out',self.conv5_out)
"""
Sixth convnet:
ResNet block
BatchNormalization
ELU
"""
self.conv6_1 = tf.layers.conv2d(inputs = self.conv5_out,
filters = 256,
kernel_size = [3,3],
strides = [1,1],
padding = "SAME",
kernel_initializer=tf.contrib.layers.xavier_initializer_conv2d(),
name = "conv6_1")
self.conv6_batchnorm_1 = tf.layers.batch_normalization(self.conv6_1,
training = False,
epsilon = 1e-5,
name = 'batch_norm6_1')
self.conv6_out_1 = tf.nn.elu(self.conv6_batchnorm_1, name="conv6_out_1")
self.conv6_2 = tf.layers.conv2d(inputs = self.conv6_out_1,
filters = 256,
kernel_size = [1,1],
strides = [1,1],
padding = "SAME",
kernel_initializer=tf.contrib.layers.xavier_initializer_conv2d(),
name = "conv6_2")
self.conv6_batchnorm_2 = tf.layers.batch_normalization(self.conv6_2,
training = False,
epsilon = 1e-5,
name = 'batch_norm6_2')
self.conv6_out_2 = tf.nn.elu(self.conv6_batchnorm_2+self.conv5_out, name="conv6_out_2")
print('conv6_out',self.conv6_out_2)
self.finish_tag_ = tf.reshape(self.finish_tag, [-1, num_objects])
#print("finish_tag")
#print(self.finish_tag_.shape)
self.flatten_ = tf.concat([tf.contrib.layers.flatten(self.conv6_out_2), self.finish_tag_], -1)
#print("flatten_")
#print(self.flatten_.shape)
self.flatten = tf.reshape(self.flatten_, [-1, self.seq_len, int(self.flatten_.shape[-1])])
#print("flatten")
#print(self.flatten.shape)
## --> [1152]
def lstm_layer(lstm_size, number_of_layers):
'''
This method is used to create LSTM layer/s for PixelRNN
Input(s): lstm_cell_unitis - used to define the number of units in a LSTM layer
number_of_layers - used to define how many of LSTM layers do we want in the network
batch_size - in this method this information is used to build starting state for the network
Output(s): cell - lstm layer
init_state - zero vectors used as a starting state for the network
'''
def cell_f(size):
return tf.nn.rnn_cell.LSTMCell(lstm_size, name='basic_lstm_cell')
# cell = tf.contrib.rnn.MultiRNNCell([cell(lstm_size) for _ in range(number_of_layers)])
cell = cell_f(lstm_size)
init_state = cell.zero_state(batch_size, tf.float32)
return cell, init_state
cell, self.init_state = lstm_layer(256, 1)
self.rnn, self.state_out = tf.nn.dynamic_rnn(cell, self.flatten, initial_state = self.state_in)
print(self.rnn)
self.output_ = tf.layers.dense(inputs = self.rnn,
kernel_initializer=tf.contrib.layers.xavier_initializer(),
units = self.action_size,
activation=None,
name = "output_internal")
self.output = tf.reshape(self.output_, [-1, self.seq_len, self.action_size], name = "output_external")
print(self.output_)
print(self.output)
class DQNetwork18_2:
def __init__(self, batch_size, state_size=[5,5,4], action_space=5, num_objects=5, learning_rate=0.0002, seq_len = 50, name='DQNetwork'):
self.state_size = state_size
self.action_size = action_space*num_objects
self.learning_rate = learning_rate
self.seq_len = seq_len
with tf.variable_scope(name):
# We create the placeholders
# *state_size means that we take each elements of state_size in tuple hence is like if we wrote
# [None, 84, 84, 4]
self.inputs_ = tf.placeholder(tf.float32, [None, self.seq_len, *state_size], name="inputs")
self.actions_ = tf.placeholder(tf.float32, [None, self.seq_len, self.action_size], name="actions_")
# self.action_chain = tf.placeholder(tf.float32, [None, self.action_size * (frame_num-1)], name="action_chain")
# Remember that target_Q is the R(s,a) + ymax Qhat(s', a')
self.target_Q_ = tf.placeholder(tf.float32, [None, self.seq_len], name="target")
# self.conflict_matrix = tf.placeholder(tf.float32, [None, num_objects, num_objects, 2], name="conflict_matrix")
self.finish_tag = tf.placeholder(tf.float32,[None, self.seq_len, num_objects], name="finish_tag")
#mask
self.mask = tf.placeholder(tf.float32, [None, self.seq_len])
self.lr = tf.placeholder(tf.float32, name="learnig_rate")
# conflict_matrix_and = tf.logical_and(tf.cast(self.conflict_matrix[...,0],tf.bool),tf.cast(self.conflict_matrix[...,1],tf.bool))
# self.conflict_matrix = tf.cast(self.conflict_matrix,tf.float32)
# conflict_matrix_and = tf.cast(conflict_matrix_and,tf.float32)
"""
First convnet:
CNN
BatchNormalization
ELU
"""
# Input is 15*15*55
self.inputs = tf.reshape(self.inputs_, [-1, *self.state_size])# combine the first two dims
self.conv1 = tf.layers.conv2d(inputs = self.inputs,
filters = 64,
kernel_size = [5,5],
strides = [2,2],
padding = "SAME",
kernel_initializer=tf.contrib.layers.xavier_initializer_conv2d(),
name = "conv1")
self.conv1_batchnorm = tf.layers.batch_normalization(self.conv1,
training = True,
epsilon = 1e-5,
name = 'batch_norm1')
self.conv1_out = tf.nn.elu(self.conv1_batchnorm, name="conv1_out")
## --> [8, 8, 64]
print('conv1_out',self.conv1_out)
"""
Second convnet:
ResNet block
BatchNormalization
ELU
"""
self.conv2_1 = tf.layers.conv2d(inputs = self.conv1_out,
filters = 64,
kernel_size = [3,3],
strides = [1,1],
padding = "SAME",
kernel_initializer=tf.contrib.layers.xavier_initializer_conv2d(),
name = "conv2_1")
self.conv2_batchnorm_1 = tf.layers.batch_normalization(self.conv2_1,
training = True,
epsilon = 1e-5,
name = 'batch_norm2_1')
self.conv2_out_1 = tf.nn.elu(self.conv2_batchnorm_1, name="conv2_out_1")
self.conv2_2 = tf.layers.conv2d(inputs = self.conv2_out_1,
filters = 64,
kernel_size = [1,1],
strides = [1,1],
padding = "SAME",
kernel_initializer=tf.contrib.layers.xavier_initializer_conv2d(),
name = "conv2_2")
self.conv2_batchnorm_2 = tf.layers.batch_normalization(self.conv2_2,
training = True,
epsilon = 1e-5,
name = 'batch_norm2_2')
self.conv2_out_2 = tf.nn.elu(self.conv2_batchnorm_2+self.conv1_out, name="conv2_out_2")
## --> [4, 4, 128]
print('conv2_out',self.conv2_out_2)
"""
Third convnet:
CNN
BatchNormalization
ELU
"""
# Input is 15*15*55
self.conv3 = tf.layers.conv2d(inputs = self.conv2_out_2,
filters = 128,
kernel_size = [3,3],
strides = [2,2],
padding = "SAME",
kernel_initializer=tf.contrib.layers.xavier_initializer_conv2d(),
name = "conv3")
self.conv3_batchnorm = tf.layers.batch_normalization(self.conv3,
training = True,
epsilon = 1e-5,
name = 'batch_norm3')
self.conv3_out = tf.nn.elu(self.conv3_batchnorm, name="conv3_out")
print('conv3_out',self.conv3_out)
"""
Forth convnet:
ResNet block
BatchNormalization
ELU
"""
self.conv4_1 = tf.layers.conv2d(inputs = self.conv3_out,
filters = 128,
kernel_size = [3,3],
strides = [1,1],
padding = "SAME",
kernel_initializer=tf.contrib.layers.xavier_initializer_conv2d(),
name = "conv4_1")
self.conv4_batchnorm_1 = tf.layers.batch_normalization(self.conv4_1,
training = True,
epsilon = 1e-5,
name = 'batch_norm4_1')
self.conv4_out_1 = tf.nn.elu(self.conv4_batchnorm_1, name="conv4_out_1")
self.conv4_2 = tf.layers.conv2d(inputs = self.conv4_out_1,
filters = 128,
kernel_size = [1,1],
strides = [1,1],
padding = "SAME",
kernel_initializer=tf.contrib.layers.xavier_initializer_conv2d(),
name = "conv4_2")
self.conv4_batchnorm_2 = tf.layers.batch_normalization(self.conv4_2,
training = True,
epsilon = 1e-5,
name = 'batch_norm4_2')
self.conv4_out_2 = tf.nn.elu(self.conv4_batchnorm_2+self.conv3_out, name="conv4_out_2")
print('conv4_out',self.conv4_out_2)
## --> [4, 4, 128]
"""
Fifth convnet:
CNN
BatchNormalization
ELU
"""
# Input is 15*15*55
self.conv5 = tf.layers.conv2d(inputs = self.conv4_out_2,
filters = 256,
kernel_size = [3,3],
strides = [2,2],
padding = "SAME",
kernel_initializer=tf.contrib.layers.xavier_initializer_conv2d(),
name = "conv5")
self.conv5_batchnorm = tf.layers.batch_normalization(self.conv5,
training = True,
epsilon = 1e-5,
name = 'batch_norm5')
self.conv5_out = tf.nn.elu(self.conv5_batchnorm, name="conv5_out")
print('conv5_out',self.conv5_out)
"""
Sixth convnet:
ResNet block
BatchNormalization
ELU
"""
self.conv6_1 = tf.layers.conv2d(inputs = self.conv5_out,
filters = 256,
kernel_size = [3,3],
strides = [1,1],
padding = "SAME",
kernel_initializer=tf.contrib.layers.xavier_initializer_conv2d(),
name = "conv6_1")
self.conv6_batchnorm_1 = tf.layers.batch_normalization(self.conv6_1,
training = True,
epsilon = 1e-5,
name = 'batch_norm6_1')
self.conv6_out_1 = tf.nn.elu(self.conv6_batchnorm_1, name="conv6_out_1")
self.conv6_2 = tf.layers.conv2d(inputs = self.conv6_out_1,
filters = 256,
kernel_size = [1,1],
strides = [1,1],
padding = "SAME",
kernel_initializer=tf.contrib.layers.xavier_initializer_conv2d(),
name = "conv6_2")
self.conv6_batchnorm_2 = tf.layers.batch_normalization(self.conv6_2,
training = True,
epsilon = 1e-5,
name = 'batch_norm6_2')
self.conv6_out_2 = tf.nn.elu(self.conv6_batchnorm_2+self.conv5_out, name="conv6_out_2")
print('conv6_out',self.conv6_out_2)
# """
# Third convnet:
# CNN
# BatchNormalization
# ELU
# """
# self.conv3 = tf.layers.conv2d(inputs = self.conv2_out,
# filters = 128,
# kernel_size = [4,4],
# strides = [2,2],
# padding = "VALID",
# kernel_initializer=tf.contrib.layers.xavier_initializer_conv2d(),
# name = "conv3")
# self.conv3_batchnorm = tf.layers.batch_normalization(self.conv3,
# training = True,
# epsilon = 1e-5,
# name = 'batch_norm3')
# self.conv3_out = tf.nn.elu(self.conv3_batchnorm, name="conv3_out")
# ## --> [3, 3, 128]
# self.flatten = tf.layers.flatten(self.inputs_)
# self.flatten = tf.concat([tf.contrib.layers.flatten(self.conv6_out_2),tf.contrib.layers.flatten(self.conflict_matrix), tf.contrib.layers.flatten(conflict_matrix_and), self.finish_tag], -1)
self.finish_tag_ = tf.reshape(self.finish_tag, [-1, num_objects])
self.flatten = tf.concat([tf.contrib.layers.flatten(self.conv6_out_2), self.finish_tag_], -1)
self.flatten = tf.reshape(self.flatten, [-1, self.seq_len, int(self.flatten.shape[-1])])
## --> [1152]
def lstm_layer(lstm_size, number_of_layers, batch_size):
'''
This method is used to create LSTM layer/s for PixelRNN
Input(s): lstm_cell_unitis - used to define the number of units in a LSTM layer
number_of_layers - used to define how many of LSTM layers do we want in the network
batch_size - in this method this information is used to build starting state for the network
Output(s): cell - lstm layer
init_state - zero vectors used as a starting state for the network
'''
def cell_f(size):
return tf.nn.rnn_cell.LSTMCell(size, name='basic_lstm_cell')
# cell = tf.contrib.rnn.MultiRNNCell([cell(lstm_size) for _ in range(number_of_layers)])
cell = cell_f(lstm_size)
init_state = cell.zero_state(batch_size, tf.float32)
return cell, init_state
cell, init_state = lstm_layer(256, 1, batch_size)
outputs, states = tf.nn.dynamic_rnn(cell, self.flatten, initial_state=init_state)
print(outputs)
self.rnn = tf.reshape(outputs, [-1, 256])
self.output_ = tf.layers.dense(inputs = self.rnn,
kernel_initializer=tf.contrib.layers.xavier_initializer(),
units = self.action_size,
activation=None,
name = "output_internal")
self.output = tf.reshape(self.output_, [-1, self.seq_len, self.action_size], name = "output_external")
print(self.output_)
print(self.output)
# Q is our predicted Q value.
self.Q = tf.reduce_sum(tf.multiply(self.output, self.actions_), axis=2) # bs x seq_len
# The loss is the difference between our predicted Q_values and the Q_target
# Sum(Qtarget - Q)^2
self.target_Q = self.target_Q_
temp = tf.square(self.target_Q - self.Q) # bs x seq_len
temp = tf.multiply(temp, self.mask)
# loss_details = tf.reduce_mean(tf.reshape(temp,[-1, num_objects, action_space]),axis=[0,1], name = "loss_details")
# print(loss_details)
# self.loss_details = [loss_details[i] for i in range(action_space)]
# temp = tf.reshape(tf.reduce_mean(temp, axis = 1), [-1, seq_len])
# self.loss = tf.reduce_mean(tf.multiply(temp, self.mask))
self.loss = tf.reduce_mean(temp)
self.optimizer = tf.train.RMSPropOptimizer(self.lr).minimize(self.loss)
# self.optimizer2 = tf.train.RMSPropOptimizer(0.00005).minimize(self.loss)
| 49.103986 | 202 | 0.446229 | 2,704 | 28,333 | 4.448965 | 0.077293 | 0.027265 | 0.032419 | 0.045387 | 0.916043 | 0.904073 | 0.900416 | 0.888861 | 0.874896 | 0.838404 | 0 | 0.04972 | 0.464053 | 28,333 | 576 | 203 | 49.189236 | 0.742509 | 0.16059 | 0 | 0.89404 | 0 | 0 | 0.039991 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0.019868 | false | 0 | 0.003311 | 0.006623 | 0.043046 | 0.059603 | 0 | 0 | 0 | null | 0 | 0 | 0 | 1 | 1 | 1 | 1 | 1 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 7 |
eec3a6df92c44ca3794bbe0d5764aa5adffb76d6 | 23,405 | py | Python | test/test_track_geometry/test_track_geometry.py | aws-deepracer/deepracer-track-geometry | e001769a88f6b2c1a64248bafdcd5b0fa56c8fc8 | [
"Apache-2.0"
] | 1 | 2022-03-25T07:20:44.000Z | 2022-03-25T07:20:44.000Z | test/test_track_geometry/test_track_geometry.py | aws-deepracer/deepracer-track-geometry | e001769a88f6b2c1a64248bafdcd5b0fa56c8fc8 | [
"Apache-2.0"
] | null | null | null | test/test_track_geometry/test_track_geometry.py | aws-deepracer/deepracer-track-geometry | e001769a88f6b2c1a64248bafdcd5b0fa56c8fc8 | [
"Apache-2.0"
] | null | null | null | #################################################################################
# Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. #
# #
# Licensed under the Apache License, Version 2.0 (the "License"). #
# You may not use this file except in compliance with the License. #
# You may obtain a copy of the License at #
# #
# http://www.apache.org/licenses/LICENSE-2.0 #
# #
# Unless required by applicable law or agreed to in writing, software #
# distributed under the License is distributed on an "AS IS" BASIS, #
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. #
# See the License for the specific language governing permissions and #
# limitations under the License. #
#################################################################################
import pkg_resources
from unittest import TestCase
from shapely.geometry import Point
from deepracer_track_geometry.track_geometry import TrackGeometry
from deepracer_track_geometry.constants import TrackDirection, TrackRegion, NdistMode, FiniteDifference
class TrackGeometryTest(TestCase):
def setUp(self) -> None:
self.track_name = "monaco"
self.track = TrackGeometry(self.track_name)
def test_get_track_name(self) -> None:
self.assertEqual(self.track.track_name, self.track_name)
def test_get_track_length(self) -> None:
self.assertEqual(self.track.length, self.track.track_center_line.length)
def test_set_finish_line_wrap(self) -> None:
self.track.finish_line = -0.3
self.assertEqual(self.track.finish_line, 0.7)
def test_set_finish_line_positive(self) -> None:
# positive
self.track.finish_line = 0.3
self.assertEqual(self.track.finish_line, 0.3)
def test_set_direction_invalid(self) -> None:
with self.assertRaises(ValueError):
# Invalid finish line value
self.track.direction = "reverse"
def test_set_direction_cw(self) -> None:
self.track.direction = TrackDirection.CLOCKWISE.value
self.assertEqual(self.track.direction, TrackDirection.CLOCKWISE)
def test_set_direction_ccw(self) -> None:
self.track.direction = TrackDirection.COUNTER_CLOCKWISE.value
self.assertEqual(self.track.direction, TrackDirection.COUNTER_CLOCKWISE)
def test_is_on_track_invalid_dimension(self) -> None:
with self.assertRaises(ValueError) as ex:
# Invalid coordinate value
self.assertFalse(self.track.is_on_track(coordinates=[-0.60]))
self.assertEqual("need at least 2 dimension coordinates.", str(ex.exception))
with self.assertRaises(ValueError) as ex:
# Invalid coordinate value
self.assertFalse(self.track.is_on_track(coordinates=[-0.60, 0.93, 0.1, 0.1]))
self.assertEqual("max dimension of coordinates is 3.", str(ex.exception))
with self.assertRaises(ValueError) as ex:
# Invalid coordinate value
self.assertFalse(self.track.get_region_on_track(coordinates=[-0.60]))
self.assertEqual("need at least 2 dimension coordinates.", str(ex.exception))
with self.assertRaises(ValueError) as ex:
# Invalid coordinate value
self.assertFalse(self.track.get_region_on_track(coordinates=[-0.60, 0.93, 0.1, 0.1]))
self.assertEqual("max dimension of coordinates is 3.", str(ex.exception))
def test_is_on_track_inner_offtrack(self) -> None:
coords = [-0.60, 0.93] # Inner Offtrack
self.assertFalse(self.track.is_on_track(coordinates=coords))
self.assertEqual(self.track.get_region_on_track(coordinates=coords),
TrackRegion.INNER_OFFTRACK)
coords = [-0.60, 0.93, 3] # Inner Offtrack, z coord doesn't matter
self.assertFalse(self.track.is_on_track(coordinates=coords))
self.assertEqual(self.track.get_region_on_track(coordinates=coords),
TrackRegion.INNER_OFFTRACK)
def test_is_on_track_inner_border(self) -> None:
coords = [-6.38, 0.93] # Inner border
self.assertFalse(self.track.is_on_track(coordinates=coords))
self.assertEqual(self.track.get_region_on_track(coordinates=coords),
TrackRegion.INNER_OFFTRACK)
coords = [-6.38, 0.93, 1] # Inner border, z coord doesn't matter
self.assertFalse(self.track.is_on_track(coordinates=coords))
self.assertEqual(self.track.get_region_on_track(coordinates=coords),
TrackRegion.INNER_OFFTRACK)
def test_is_on_track_center_line(self) -> None:
coords = [-7.014, 1.28] # Center Line
self.assertTrue(self.track.is_on_track(coordinates=coords))
self.assertEqual(self.track.get_region_on_track(coordinates=coords),
TrackRegion.INNER_LANE)
coords = [-7.014, 1.28, 1] # Center Line, z coord doesn't matter
self.assertTrue(self.track.is_on_track(coordinates=coords))
self.assertEqual(self.track.get_region_on_track(coordinates=coords),
TrackRegion.INNER_LANE)
def test_is_on_track_outer_lane(self) -> None:
coords = [-7.2, 1.28] # Outer Lane
self.assertTrue(self.track.is_on_track(coordinates=coords))
self.assertEqual(self.track.get_region_on_track(coordinates=coords),
TrackRegion.OUTER_LANE)
coords = [-7.2, 1.28, 3] # Outer lane, z coord doesn't matter
self.assertTrue(self.track.is_on_track(coordinates=coords))
self.assertEqual(self.track.get_region_on_track(coordinates=coords),
TrackRegion.OUTER_LANE)
def test_is_on_track_outer_offtrack_shapely_point(self) -> None:
coords = [-8.2, 1.28] # Outer Offtrack
self.assertFalse(self.track.is_on_track(coordinates=Point(coords)))
self.assertEqual(self.track.get_region_on_track(coordinates=Point(coords)),
TrackRegion.OUTER_OFFTRACK)
coords = [-8.2, 1.28, 3] # Outer Offtrack, z coord doesn't matter
self.assertFalse(self.track.is_on_track(coordinates=Point(coords)))
self.assertEqual(self.track.get_region_on_track(coordinates=Point(coords)),
TrackRegion.OUTER_OFFTRACK)
def test_is_on_track_inner_offtrack_shapely_point(self) -> None:
coords = [-0.60, 0.93] # Inner Offtrack
self.assertFalse(self.track.is_on_track(coordinates=Point(coords)))
self.assertEqual(self.track.get_region_on_track(coordinates=Point(coords)),
TrackRegion.INNER_OFFTRACK)
coords = [-0.60, 0.93, 3] # Inner Offtrack, z coord doesn't matter
self.assertFalse(self.track.is_on_track(coordinates=Point(coords)))
self.assertEqual(self.track.get_region_on_track(coordinates=Point(coords)),
TrackRegion.INNER_OFFTRACK)
def test_is_on_track_inner_border_shapely_point(self) -> None:
coords = [-6.38, 0.93] # Inner border
self.assertFalse(self.track.is_on_track(coordinates=Point(coords)))
self.assertEqual(self.track.get_region_on_track(coordinates=Point(coords)),
TrackRegion.INNER_OFFTRACK)
coords = [-6.38, 0.93, 1] # Inner border, z coord doesn't matter
self.assertFalse(self.track.is_on_track(coordinates=Point(coords)))
self.assertEqual(self.track.get_region_on_track(coordinates=Point(coords)),
TrackRegion.INNER_OFFTRACK)
def test_is_on_track_center_line_shapely_point(self) -> None:
coords = [-7.014, 1.28] # Center Line
self.assertTrue(self.track.is_on_track(coordinates=Point(coords)))
self.assertEqual(self.track.get_region_on_track(coordinates=Point(coords)),
TrackRegion.INNER_LANE)
coords = [-7.014, 1.28, 1] # Center Line, z coord doesn't matter
self.assertTrue(self.track.is_on_track(coordinates=Point(coords)))
self.assertEqual(self.track.get_region_on_track(coordinates=Point(coords)),
TrackRegion.INNER_LANE)
def test_is_on_track_outer_lane_shapely_point(self) -> None:
coords = [-7.2, 1.28] # Outer Lane
self.assertTrue(self.track.is_on_track(coordinates=Point(coords)))
self.assertEqual(self.track.get_region_on_track(coordinates=Point(coords)),
TrackRegion.OUTER_LANE)
coords = [-7.2, 1.28, 3] # Outer lane, z coord doesn't matter
self.assertTrue(self.track.is_on_track(coordinates=Point(coords)))
self.assertEqual(self.track.get_region_on_track(coordinates=Point(coords)),
TrackRegion.OUTER_LANE)
def test_is_on_track_outer_offtrack(self) -> None:
coords = [-8.2, 1.28] # Outer Offtrack
self.assertFalse(self.track.is_on_track(coordinates=coords))
self.assertEqual(self.track.get_region_on_track(coordinates=coords),
TrackRegion.OUTER_OFFTRACK)
coords = [-8.2, 1.28, 3] # Outer Offtrack, z coord doesn't matter
self.assertFalse(self.track.is_on_track(coordinates=coords))
self.assertEqual(self.track.get_region_on_track(coordinates=coords),
TrackRegion.OUTER_OFFTRACK)
def _test_ndist(self, ndist_mode) -> None:
test_ndist = 0.1
coords = self.track.get_point_from_ndist(test_ndist, ndist_mode=ndist_mode)
ndist = self.track.get_ndist_from_point(coords, ndist_mode=ndist_mode)
self.assertAlmostEqual(ndist, test_ndist)
test_ndist = 0.3
coords = self.track.get_point_from_ndist(test_ndist, ndist_mode=ndist_mode)
ndist = self.track.get_ndist_from_point(coords, ndist_mode=ndist_mode)
self.assertAlmostEqual(ndist, test_ndist)
test_ndist = 0.5
coords = self.track.get_point_from_ndist(test_ndist, ndist_mode=ndist_mode)
ndist = self.track.get_ndist_from_point(coords, ndist_mode=ndist_mode)
self.assertAlmostEqual(ndist, test_ndist)
test_ndist = 0.8
coords = self.track.get_point_from_ndist(test_ndist, ndist_mode=ndist_mode)
ndist = self.track.get_ndist_from_point(coords, ndist_mode=ndist_mode)
self.assertAlmostEqual(ndist, test_ndist)
test_ndist = 0.0
coords = self.track.get_point_from_ndist(test_ndist, ndist_mode=ndist_mode)
ndist = self.track.get_ndist_from_point(coords, ndist_mode=ndist_mode)
self.assertAlmostEqual(ndist, test_ndist)
test_ndist = 1.0
coords = self.track.get_point_from_ndist(test_ndist, ndist_mode=ndist_mode)
ndist = self.track.get_ndist_from_point(coords, ndist_mode=ndist_mode)
self.assertAlmostEqual(ndist, 0.0)
def _test_ndist_shapely_point(self, ndist_mode) -> None:
test_ndist = 0.1
coords = self.track.get_point_from_ndist(test_ndist, ndist_mode=ndist_mode)
ndist = self.track.get_ndist_from_point(Point(coords), ndist_mode=ndist_mode)
self.assertAlmostEqual(ndist, test_ndist)
test_ndist = 0.3
coords = self.track.get_point_from_ndist(test_ndist, ndist_mode=ndist_mode)
ndist = self.track.get_ndist_from_point(Point(coords), ndist_mode=ndist_mode)
self.assertAlmostEqual(ndist, test_ndist)
test_ndist = 0.5
coords = self.track.get_point_from_ndist(test_ndist, ndist_mode=ndist_mode)
ndist = self.track.get_ndist_from_point(Point(coords), ndist_mode=ndist_mode)
self.assertAlmostEqual(ndist, test_ndist)
test_ndist = 0.8
coords = self.track.get_point_from_ndist(test_ndist, ndist_mode=ndist_mode)
ndist = self.track.get_ndist_from_point(Point(coords), ndist_mode=ndist_mode)
self.assertAlmostEqual(ndist, test_ndist)
test_ndist = 0.0
coords = self.track.get_point_from_ndist(test_ndist, ndist_mode=ndist_mode)
ndist = self.track.get_ndist_from_point(Point(coords), ndist_mode=ndist_mode)
self.assertAlmostEqual(ndist, test_ndist)
test_ndist = 1.0
coords = self.track.get_point_from_ndist(test_ndist, ndist_mode=ndist_mode)
ndist = self.track.get_ndist_from_point(Point(coords), ndist_mode=ndist_mode)
self.assertAlmostEqual(ndist, 0.0)
def test_ndist_finish_line_0_0_to_finish_line_ccw(self) -> None:
self.track.direction = TrackDirection.COUNTER_CLOCKWISE.value
self.track.finish_line = 0.0 # Change finish line
self.assertEqual(self.track.finish_line, 0.0)
self._test_ndist(ndist_mode=NdistMode.TO_FINISH_LINE)
self._test_ndist_shapely_point(ndist_mode=NdistMode.TO_FINISH_LINE)
def test_ndist_finish_line_0_0_from_finish_line_ccw(self) -> None:
self.track.direction = TrackDirection.COUNTER_CLOCKWISE.value
self.track.finish_line = 0.0 # Change finish line
self.assertEqual(self.track.finish_line, 0.0)
self._test_ndist(ndist_mode=NdistMode.FROM_FINISH_LINE)
self._test_ndist_shapely_point(ndist_mode=NdistMode.TO_FINISH_LINE)
def test_ndist_finish_line_0_3_to_finish_line_ccw(self) -> None:
self.track.direction = TrackDirection.COUNTER_CLOCKWISE.value
self.track.finish_line = 0.3 # Change finish line
self.assertEqual(self.track.finish_line, 0.3)
self._test_ndist(ndist_mode=NdistMode.TO_FINISH_LINE)
self._test_ndist_shapely_point(ndist_mode=NdistMode.TO_FINISH_LINE)
def test_ndist_finish_line_0_3_from_finish_line_ccw(self) -> None:
self.track.direction = TrackDirection.COUNTER_CLOCKWISE.value
self.track.finish_line = 0.3 # Change finish line
self.assertEqual(self.track.finish_line, 0.3)
self._test_ndist(ndist_mode=NdistMode.FROM_FINISH_LINE)
self._test_ndist_shapely_point(ndist_mode=NdistMode.TO_FINISH_LINE)
def test_ndist_finish_line_neg_0_3_to_finish_line_ccw(self) -> None:
self.track.direction = TrackDirection.COUNTER_CLOCKWISE.value
self.track.finish_line = -0.3 # Change finish line
self.assertEqual(self.track.finish_line, 0.7)
self._test_ndist(ndist_mode=NdistMode.TO_FINISH_LINE)
self._test_ndist_shapely_point(ndist_mode=NdistMode.TO_FINISH_LINE)
def test_ndist_finish_line_neg_0_3_from_finish_line_ccw(self) -> None:
self.track.direction = TrackDirection.COUNTER_CLOCKWISE.value
self.track.finish_line = -0.3 # Change finish line
self.assertEqual(self.track.finish_line, 0.7)
self._test_ndist(ndist_mode=NdistMode.FROM_FINISH_LINE)
self._test_ndist_shapely_point(ndist_mode=NdistMode.TO_FINISH_LINE)
def test_get_closest_waypoint_indices_0_1_cw(self) -> None:
self.track.direction = TrackDirection.CLOCKWISE.value
test_ndist = 0.1
prev_idx, next_idx = self.track.get_closest_waypoint_indices(test_ndist, ndist_mode=NdistMode.TO_FINISH_LINE)
self.assertEqual(prev_idx, 214)
self.assertEqual(next_idx, 215)
test_ndist = 0.9
prev_idx, next_idx = self.track.get_closest_waypoint_indices(test_ndist, ndist_mode=NdistMode.FROM_FINISH_LINE)
self.assertEqual(prev_idx, 214)
self.assertEqual(next_idx, 215)
def test_get_closest_waypoint_indices_0_1_ccw(self) -> None:
self.track.direction = TrackDirection.COUNTER_CLOCKWISE.value
test_ndist = 0.1
prev_idx, next_idx = self.track.get_closest_waypoint_indices(test_ndist, ndist_mode=NdistMode.TO_FINISH_LINE)
self.assertEqual(prev_idx, 211)
self.assertEqual(next_idx, 212)
test_ndist = 0.9
prev_idx, next_idx = self.track.get_closest_waypoint_indices(test_ndist, ndist_mode=NdistMode.FROM_FINISH_LINE)
self.assertEqual(prev_idx, 211)
self.assertEqual(next_idx, 212)
def test_get_closest_waypoint_indices_0_5_cw(self) -> None:
self.track.direction = TrackDirection.CLOCKWISE.value
test_ndist = 0.5
prev_idx, next_idx = self.track.get_closest_waypoint_indices(test_ndist, ndist_mode=NdistMode.TO_FINISH_LINE)
self.assertEqual(prev_idx, 116)
self.assertEqual(next_idx, 117)
prev_idx, next_idx = self.track.get_closest_waypoint_indices(test_ndist, ndist_mode=NdistMode.FROM_FINISH_LINE)
self.assertEqual(prev_idx, 116)
self.assertEqual(next_idx, 117)
def test_get_closest_waypoint_indices_0_5_ccw(self) -> None:
self.track.direction = TrackDirection.COUNTER_CLOCKWISE.value
test_ndist = 0.5
prev_idx, next_idx = self.track.get_closest_waypoint_indices(test_ndist, ndist_mode=NdistMode.TO_FINISH_LINE)
self.assertEqual(prev_idx, 117)
self.assertEqual(next_idx, 118)
prev_idx, next_idx = self.track.get_closest_waypoint_indices(test_ndist, ndist_mode=NdistMode.FROM_FINISH_LINE)
self.assertEqual(prev_idx, 117)
self.assertEqual(next_idx, 118)
def test_get_closest_waypoints_0_1_cw(self) -> None:
self.track.direction = TrackDirection.CLOCKWISE.value
test_ndist = 0.1
prev_coords, next_coords = self.track.get_closest_waypoints(test_ndist, ndist_mode=NdistMode.TO_FINISH_LINE)
self.assertAlmostEqual(prev_coords[0], -8.01600242)
self.assertAlmostEqual(prev_coords[1], -5.12338257)
self.assertAlmostEqual(next_coords[0], -8.15831709)
self.assertAlmostEqual(next_coords[1], -4.93767357)
test_ndist = 0.9
prev_coords, next_coords = self.track.get_closest_waypoints(test_ndist, ndist_mode=NdistMode.FROM_FINISH_LINE)
self.assertAlmostEqual(prev_coords[0], -8.01600242)
self.assertAlmostEqual(prev_coords[1], -5.12338257)
self.assertAlmostEqual(next_coords[0], -8.15831709)
self.assertAlmostEqual(next_coords[1], -4.93767357)
def test_get_closest_waypoints_0_1_ccw(self) -> None:
self.track.direction = TrackDirection.COUNTER_CLOCKWISE.value
test_ndist = 0.1
prev_coords, next_coords = self.track.get_closest_waypoints(test_ndist, ndist_mode=NdistMode.TO_FINISH_LINE)
self.assertAlmostEqual(prev_coords[0], -2.43641901)
self.assertAlmostEqual(prev_coords[1], 2.26828957)
self.assertAlmostEqual(next_coords[0], -2.75742698)
self.assertAlmostEqual(next_coords[1], 2.34699249)
test_ndist = 0.9
prev_coords, next_coords = self.track.get_closest_waypoints(test_ndist, ndist_mode=NdistMode.FROM_FINISH_LINE)
self.assertAlmostEqual(prev_coords[0], -2.43641901)
self.assertAlmostEqual(prev_coords[1], 2.26828957)
self.assertAlmostEqual(next_coords[0], -2.75742698)
self.assertAlmostEqual(next_coords[1], 2.34699249)
def test_get_closest_waypoints_0_5_cw(self) -> None:
self.track.direction = TrackDirection.CLOCKWISE.value
test_ndist = 0.5
prev_coords, next_coords = self.track.get_closest_waypoints(test_ndist, ndist_mode=NdistMode.TO_FINISH_LINE)
self.assertAlmostEqual(prev_coords[0], 8.9961977)
self.assertAlmostEqual(prev_coords[1], 0.3554957)
self.assertAlmostEqual(next_coords[0], 8.7407155)
self.assertAlmostEqual(next_coords[1], 0.1251201)
prev_coords, next_coords = self.track.get_closest_waypoints(test_ndist, ndist_mode=NdistMode.FROM_FINISH_LINE)
self.assertAlmostEqual(prev_coords[0], 8.9961977)
self.assertAlmostEqual(prev_coords[1], 0.3554957)
self.assertAlmostEqual(next_coords[0], 8.7407155)
self.assertAlmostEqual(next_coords[1], 0.1251201)
def test_get_closest_waypoints_0_5_ccw(self) -> None:
self.track.direction = TrackDirection.COUNTER_CLOCKWISE.value
test_ndist = 0.5
prev_coords, next_coords = self.track.get_closest_waypoints(test_ndist, ndist_mode=NdistMode.TO_FINISH_LINE)
self.assertAlmostEqual(prev_coords[0], 8.7407155)
self.assertAlmostEqual(prev_coords[1], 0.1251201)
self.assertAlmostEqual(next_coords[0], 8.9961977)
self.assertAlmostEqual(next_coords[1], 0.3554957)
prev_coords, next_coords = self.track.get_closest_waypoints(test_ndist, ndist_mode=NdistMode.FROM_FINISH_LINE)
self.assertAlmostEqual(prev_coords[0], 8.7407155)
self.assertAlmostEqual(prev_coords[1], 0.1251201)
self.assertAlmostEqual(next_coords[0], 8.9961977)
self.assertAlmostEqual(next_coords[1], 0.3554957)
def test_get_orientation_central_difference(self) -> None:
self.track.direction = TrackDirection.COUNTER_CLOCKWISE.value
test_ndist = 0.1
orientation = self.track.get_orientation(test_ndist,
ndist_mode=NdistMode.TO_FINISH_LINE,
finite_difference=FiniteDifference.CENTRAL_DIFFERENCE)
self.assertEqual(len(orientation), 4)
self.assertEqual(orientation[0], 0.0)
self.assertEqual(orientation[1], 0.0)
self.assertAlmostEqual(orientation[2], 0.9927828)
self.assertAlmostEqual(orientation[3], 0.1199265)
self.track.direction = TrackDirection.CLOCKWISE.value
test_ndist = 0.1
orientation = self.track.get_orientation(test_ndist,
ndist_mode=NdistMode.TO_FINISH_LINE,
finite_difference=FiniteDifference.CENTRAL_DIFFERENCE)
self.assertEqual(len(orientation), 4)
self.assertEqual(orientation[0], 0.0)
self.assertEqual(orientation[1], 0.0)
self.assertAlmostEqual(orientation[2], 0.8967341)
self.assertAlmostEqual(orientation[3], 0.4425698)
def test_get_orientation_forward_difference(self) -> None:
self.track.direction = TrackDirection.COUNTER_CLOCKWISE.value
test_ndist = 0.1
orientation = self.track.get_orientation(test_ndist,
ndist_mode=NdistMode.TO_FINISH_LINE,
finite_difference=FiniteDifference.FORWARD_DIFFERENCE)
self.assertEqual(len(orientation), 4)
self.assertEqual(orientation[0], 0.0)
self.assertEqual(orientation[1], 0.0)
self.assertAlmostEqual(orientation[2], 0.9927828)
self.assertAlmostEqual(orientation[3], 0.1199265)
self.track.direction = TrackDirection.CLOCKWISE.value
test_ndist = 0.1
orientation = self.track.get_orientation(test_ndist,
ndist_mode=NdistMode.TO_FINISH_LINE,
finite_difference=FiniteDifference.FORWARD_DIFFERENCE)
self.assertEqual(len(orientation), 4)
self.assertEqual(orientation[0], 0.0)
self.assertEqual(orientation[1], 0.0)
self.assertAlmostEqual(orientation[2], 0.8967341)
self.assertAlmostEqual(orientation[3], 0.4425698)
| 52.595506 | 119 | 0.681222 | 2,974 | 23,405 | 5.079354 | 0.063887 | 0.079836 | 0.05243 | 0.04528 | 0.929167 | 0.92407 | 0.912088 | 0.896796 | 0.882696 | 0.878988 | 0 | 0.040035 | 0.218799 | 23,405 | 444 | 120 | 52.713964 | 0.786152 | 0.075924 | 0 | 0.843305 | 0 | 0 | 0.007335 | 0 | 0 | 0 | 0 | 0 | 0.413105 | 1 | 0.105413 | false | 0 | 0.014245 | 0 | 0.122507 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 1 | 1 | 1 | 1 | 1 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 8 |
eedbeae25ea43f44293827e09ee5ffd6599f0007 | 4,935 | py | Python | src/abaqus/BoundaryCondition/EulerianBCState.py | Haiiliin/PyAbaqus | f20db6ebea19b73059fe875a53be370253381078 | [
"MIT"
] | 7 | 2022-01-21T09:15:45.000Z | 2022-02-15T09:31:58.000Z | src/abaqus/BoundaryCondition/EulerianBCState.py | Haiiliin/PyAbaqus | f20db6ebea19b73059fe875a53be370253381078 | [
"MIT"
] | null | null | null | src/abaqus/BoundaryCondition/EulerianBCState.py | Haiiliin/PyAbaqus | f20db6ebea19b73059fe875a53be370253381078 | [
"MIT"
] | null | null | null | from abaqusConstants import *
from .BoundaryConditionState import BoundaryConditionState
class EulerianBCState(BoundaryConditionState):
"""The EulerianBCState object stores the propagating data for an Eulerian boundary
condition in a step. One instance of this object is created internally by the EulerianBC
object for each step. The instance is also deleted internally by the EulerianBC object.
The EulerianBCState object has no constructor or methods.
The EulerianBCState object is derived from the BoundaryConditionState object.
Attributes
----------
definition: SymbolicConstant
A SymbolicConstant specifying the material flow conditions to be defined. Possible
values are INFLOW, OUTFLOW, and BOTH. The default value is INFLOW.
definitionState: SymbolicConstant
A SymbolicConstant specifying the propagation state of the definition member. Possible
values are UNSET, SET, and UNCHANGED.
inflowType: SymbolicConstant
A SymbolicConstant specifying the material flow conditions to be defined. Possible
values are FREE, NONE, and VOID. The default value is FREE.
inflowTypeState: SymbolicConstant
A SymbolicConstant specifying the propagation state of the definition member. Possible
values are UNSET, SET, and UNCHANGED.
outflowType: SymbolicConstant
A SymbolicConstant specifying the material flow conditions to be defined. Possible
values are ZERO_PRESSURE, FREE, NON_REFLECTING, and EQUILIBRIUM. The default value is
ZERO_PRESSURE.
outflowTypeState: SymbolicConstant
A SymbolicConstant specifying the propagation state of the definition member. Possible
values are UNSET, SET, and UNCHANGED.
amplitudeState: SymbolicConstant
A SymbolicConstant specifying the propagation state of the amplitude reference. Possible
values are UNSET, SET, UNCHANGED, FREED, and MODIFIED.
status: SymbolicConstant
A SymbolicConstant specifying the propagation state of the :py:class:`~abaqus.BoundaryCondition.BoundaryConditionState.BoundaryConditionState` object. Possible values are:
NOT_YET_ACTIVE
CREATED
PROPAGATED
MODIFIED
DEACTIVATED
NO_LONGER_ACTIVE
TYPE_NOT_APPLICABLE
INSTANCE_NOT_APPLICABLE
PROPAGATED_FROM_BASE_STATE
MODIFIED_FROM_BASE_STATE
DEACTIVATED_FROM_BASE_STATE
BUILT_INTO_MODES
amplitude: str
A String specifying the name of the amplitude reference. The String is empty if the
boundary condition has no amplitude reference.
Notes
-----
This object can be accessed by:
.. code-block:: python
import load
mdb.models[name].steps[name].boundaryConditionStates[name]
The corresponding analysis keywords are:
- EULERIAN BOUNDARY
"""
# A SymbolicConstant specifying the material flow conditions to be defined. Possible
# values are INFLOW, OUTFLOW, and BOTH. The default value is INFLOW.
definition: SymbolicConstant = INFLOW
# A SymbolicConstant specifying the propagation state of the definition member. Possible
# values are UNSET, SET, and UNCHANGED.
definitionState: SymbolicConstant = None
# A SymbolicConstant specifying the material flow conditions to be defined. Possible
# values are FREE, NONE, and VOID. The default value is FREE.
inflowType: SymbolicConstant = FREE
# A SymbolicConstant specifying the propagation state of the definition member. Possible
# values are UNSET, SET, and UNCHANGED.
inflowTypeState: SymbolicConstant = None
# A SymbolicConstant specifying the material flow conditions to be defined. Possible
# values are ZERO_PRESSURE, FREE, NON_REFLECTING, and EQUILIBRIUM. The default value is
# ZERO_PRESSURE.
outflowType: SymbolicConstant = ZERO_PRESSURE
# A SymbolicConstant specifying the propagation state of the definition member. Possible
# values are UNSET, SET, and UNCHANGED.
outflowTypeState: SymbolicConstant = None
# A SymbolicConstant specifying the propagation state of the amplitude reference. Possible
# values are UNSET, SET, UNCHANGED, FREED, and MODIFIED.
amplitudeState: SymbolicConstant = None
# A SymbolicConstant specifying the propagation state of the BoundaryConditionState object. Possible values are:
# NOT_YET_ACTIVE
# CREATED
# PROPAGATED
# MODIFIED
# DEACTIVATED
# NO_LONGER_ACTIVE
# TYPE_NOT_APPLICABLE
# INSTANCE_NOT_APPLICABLE
# PROPAGATED_FROM_BASE_STATE
# MODIFIED_FROM_BASE_STATE
# DEACTIVATED_FROM_BASE_STATE
# BUILT_INTO_MODES
status: SymbolicConstant = None
# A String specifying the name of the amplitude reference. The String is empty if the
# boundary condition has no amplitude reference.
amplitude: str = ''
| 42.543103 | 179 | 0.738804 | 554 | 4,935 | 6.5 | 0.207581 | 0.064982 | 0.119967 | 0.133296 | 0.745904 | 0.728686 | 0.728686 | 0.728686 | 0.728686 | 0.705637 | 0 | 0 | 0.22229 | 4,935 | 115 | 180 | 42.913043 | 0.938249 | 0.810334 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | true | 0 | 0.166667 | 0 | 1 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 1 | 1 | 1 | 1 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 7 |
eef83f50913ef865a6b81d7f05a5ade188fe04b3 | 78,884 | py | Python | sdk/python/pulumi_akamai/edgedns/dns_record.py | pulumi/pulumi-akamai | 85f933ccf2f61738b3074a13fa718132280f8364 | [
"ECL-2.0",
"Apache-2.0"
] | 3 | 2021-01-21T15:22:12.000Z | 2021-08-25T14:15:29.000Z | sdk/python/pulumi_akamai/edgedns/dns_record.py | pulumi/pulumi-akamai | 85f933ccf2f61738b3074a13fa718132280f8364 | [
"ECL-2.0",
"Apache-2.0"
] | 59 | 2020-08-13T14:39:36.000Z | 2022-03-31T15:19:48.000Z | sdk/python/pulumi_akamai/edgedns/dns_record.py | pulumi/pulumi-akamai | 85f933ccf2f61738b3074a13fa718132280f8364 | [
"ECL-2.0",
"Apache-2.0"
] | null | null | null | # coding=utf-8
# *** WARNING: this file was generated by the Pulumi Terraform Bridge (tfgen) Tool. ***
# *** Do not edit by hand unless you're certain you know what you are doing! ***
import warnings
import pulumi
import pulumi.runtime
from typing import Any, Mapping, Optional, Sequence, Union, overload
from .. import _utilities
__all__ = ['DnsRecordArgs', 'DnsRecord']
@pulumi.input_type
class DnsRecordArgs:
def __init__(__self__, *,
recordtype: pulumi.Input[str],
ttl: pulumi.Input[int],
zone: pulumi.Input[str],
active: Optional[pulumi.Input[bool]] = None,
algorithm: Optional[pulumi.Input[int]] = None,
certificate: Optional[pulumi.Input[str]] = None,
digest: Optional[pulumi.Input[str]] = None,
digest_type: Optional[pulumi.Input[int]] = None,
email_address: Optional[pulumi.Input[str]] = None,
expiration: Optional[pulumi.Input[str]] = None,
expiry: Optional[pulumi.Input[int]] = None,
fingerprint: Optional[pulumi.Input[str]] = None,
fingerprint_type: Optional[pulumi.Input[int]] = None,
flags: Optional[pulumi.Input[int]] = None,
flagsnaptr: Optional[pulumi.Input[str]] = None,
hardware: Optional[pulumi.Input[str]] = None,
inception: Optional[pulumi.Input[str]] = None,
iterations: Optional[pulumi.Input[int]] = None,
key: Optional[pulumi.Input[str]] = None,
keytag: Optional[pulumi.Input[int]] = None,
labels: Optional[pulumi.Input[int]] = None,
mailbox: Optional[pulumi.Input[str]] = None,
match_type: Optional[pulumi.Input[int]] = None,
name: Optional[pulumi.Input[str]] = None,
name_server: Optional[pulumi.Input[str]] = None,
next_hashed_owner_name: Optional[pulumi.Input[str]] = None,
nxdomain_ttl: Optional[pulumi.Input[int]] = None,
order: Optional[pulumi.Input[int]] = None,
original_ttl: Optional[pulumi.Input[int]] = None,
port: Optional[pulumi.Input[int]] = None,
preference: Optional[pulumi.Input[int]] = None,
priority: Optional[pulumi.Input[int]] = None,
priority_increment: Optional[pulumi.Input[int]] = None,
protocol: Optional[pulumi.Input[int]] = None,
refresh: Optional[pulumi.Input[int]] = None,
regexp: Optional[pulumi.Input[str]] = None,
replacement: Optional[pulumi.Input[str]] = None,
retry: Optional[pulumi.Input[int]] = None,
salt: Optional[pulumi.Input[str]] = None,
selector: Optional[pulumi.Input[int]] = None,
service: Optional[pulumi.Input[str]] = None,
signature: Optional[pulumi.Input[str]] = None,
signer: Optional[pulumi.Input[str]] = None,
software: Optional[pulumi.Input[str]] = None,
subtype: Optional[pulumi.Input[int]] = None,
svc_params: Optional[pulumi.Input[str]] = None,
svc_priority: Optional[pulumi.Input[int]] = None,
target_name: Optional[pulumi.Input[str]] = None,
targets: Optional[pulumi.Input[Sequence[pulumi.Input[str]]]] = None,
txt: Optional[pulumi.Input[str]] = None,
type_bitmaps: Optional[pulumi.Input[str]] = None,
type_covered: Optional[pulumi.Input[str]] = None,
type_mnemonic: Optional[pulumi.Input[str]] = None,
type_value: Optional[pulumi.Input[int]] = None,
usage: Optional[pulumi.Input[int]] = None,
weight: Optional[pulumi.Input[int]] = None):
"""
The set of arguments for constructing a DnsRecord resource.
"""
pulumi.set(__self__, "recordtype", recordtype)
pulumi.set(__self__, "ttl", ttl)
pulumi.set(__self__, "zone", zone)
if active is not None:
pulumi.set(__self__, "active", active)
if algorithm is not None:
pulumi.set(__self__, "algorithm", algorithm)
if certificate is not None:
pulumi.set(__self__, "certificate", certificate)
if digest is not None:
pulumi.set(__self__, "digest", digest)
if digest_type is not None:
pulumi.set(__self__, "digest_type", digest_type)
if email_address is not None:
pulumi.set(__self__, "email_address", email_address)
if expiration is not None:
pulumi.set(__self__, "expiration", expiration)
if expiry is not None:
pulumi.set(__self__, "expiry", expiry)
if fingerprint is not None:
pulumi.set(__self__, "fingerprint", fingerprint)
if fingerprint_type is not None:
pulumi.set(__self__, "fingerprint_type", fingerprint_type)
if flags is not None:
pulumi.set(__self__, "flags", flags)
if flagsnaptr is not None:
pulumi.set(__self__, "flagsnaptr", flagsnaptr)
if hardware is not None:
pulumi.set(__self__, "hardware", hardware)
if inception is not None:
pulumi.set(__self__, "inception", inception)
if iterations is not None:
pulumi.set(__self__, "iterations", iterations)
if key is not None:
pulumi.set(__self__, "key", key)
if keytag is not None:
pulumi.set(__self__, "keytag", keytag)
if labels is not None:
pulumi.set(__self__, "labels", labels)
if mailbox is not None:
pulumi.set(__self__, "mailbox", mailbox)
if match_type is not None:
pulumi.set(__self__, "match_type", match_type)
if name is not None:
pulumi.set(__self__, "name", name)
if name_server is not None:
pulumi.set(__self__, "name_server", name_server)
if next_hashed_owner_name is not None:
pulumi.set(__self__, "next_hashed_owner_name", next_hashed_owner_name)
if nxdomain_ttl is not None:
pulumi.set(__self__, "nxdomain_ttl", nxdomain_ttl)
if order is not None:
pulumi.set(__self__, "order", order)
if original_ttl is not None:
pulumi.set(__self__, "original_ttl", original_ttl)
if port is not None:
pulumi.set(__self__, "port", port)
if preference is not None:
pulumi.set(__self__, "preference", preference)
if priority is not None:
pulumi.set(__self__, "priority", priority)
if priority_increment is not None:
pulumi.set(__self__, "priority_increment", priority_increment)
if protocol is not None:
pulumi.set(__self__, "protocol", protocol)
if refresh is not None:
pulumi.set(__self__, "refresh", refresh)
if regexp is not None:
pulumi.set(__self__, "regexp", regexp)
if replacement is not None:
pulumi.set(__self__, "replacement", replacement)
if retry is not None:
pulumi.set(__self__, "retry", retry)
if salt is not None:
pulumi.set(__self__, "salt", salt)
if selector is not None:
pulumi.set(__self__, "selector", selector)
if service is not None:
pulumi.set(__self__, "service", service)
if signature is not None:
pulumi.set(__self__, "signature", signature)
if signer is not None:
pulumi.set(__self__, "signer", signer)
if software is not None:
pulumi.set(__self__, "software", software)
if subtype is not None:
pulumi.set(__self__, "subtype", subtype)
if svc_params is not None:
pulumi.set(__self__, "svc_params", svc_params)
if svc_priority is not None:
pulumi.set(__self__, "svc_priority", svc_priority)
if target_name is not None:
pulumi.set(__self__, "target_name", target_name)
if targets is not None:
pulumi.set(__self__, "targets", targets)
if txt is not None:
pulumi.set(__self__, "txt", txt)
if type_bitmaps is not None:
pulumi.set(__self__, "type_bitmaps", type_bitmaps)
if type_covered is not None:
pulumi.set(__self__, "type_covered", type_covered)
if type_mnemonic is not None:
pulumi.set(__self__, "type_mnemonic", type_mnemonic)
if type_value is not None:
pulumi.set(__self__, "type_value", type_value)
if usage is not None:
pulumi.set(__self__, "usage", usage)
if weight is not None:
pulumi.set(__self__, "weight", weight)
@property
@pulumi.getter
def recordtype(self) -> pulumi.Input[str]:
return pulumi.get(self, "recordtype")
@recordtype.setter
def recordtype(self, value: pulumi.Input[str]):
pulumi.set(self, "recordtype", value)
@property
@pulumi.getter
def ttl(self) -> pulumi.Input[int]:
return pulumi.get(self, "ttl")
@ttl.setter
def ttl(self, value: pulumi.Input[int]):
pulumi.set(self, "ttl", value)
@property
@pulumi.getter
def zone(self) -> pulumi.Input[str]:
return pulumi.get(self, "zone")
@zone.setter
def zone(self, value: pulumi.Input[str]):
pulumi.set(self, "zone", value)
@property
@pulumi.getter
def active(self) -> Optional[pulumi.Input[bool]]:
return pulumi.get(self, "active")
@active.setter
def active(self, value: Optional[pulumi.Input[bool]]):
pulumi.set(self, "active", value)
@property
@pulumi.getter
def algorithm(self) -> Optional[pulumi.Input[int]]:
return pulumi.get(self, "algorithm")
@algorithm.setter
def algorithm(self, value: Optional[pulumi.Input[int]]):
pulumi.set(self, "algorithm", value)
@property
@pulumi.getter
def certificate(self) -> Optional[pulumi.Input[str]]:
return pulumi.get(self, "certificate")
@certificate.setter
def certificate(self, value: Optional[pulumi.Input[str]]):
pulumi.set(self, "certificate", value)
@property
@pulumi.getter
def digest(self) -> Optional[pulumi.Input[str]]:
return pulumi.get(self, "digest")
@digest.setter
def digest(self, value: Optional[pulumi.Input[str]]):
pulumi.set(self, "digest", value)
@property
@pulumi.getter(name="digestType")
def digest_type(self) -> Optional[pulumi.Input[int]]:
return pulumi.get(self, "digest_type")
@digest_type.setter
def digest_type(self, value: Optional[pulumi.Input[int]]):
pulumi.set(self, "digest_type", value)
@property
@pulumi.getter(name="emailAddress")
def email_address(self) -> Optional[pulumi.Input[str]]:
return pulumi.get(self, "email_address")
@email_address.setter
def email_address(self, value: Optional[pulumi.Input[str]]):
pulumi.set(self, "email_address", value)
@property
@pulumi.getter
def expiration(self) -> Optional[pulumi.Input[str]]:
return pulumi.get(self, "expiration")
@expiration.setter
def expiration(self, value: Optional[pulumi.Input[str]]):
pulumi.set(self, "expiration", value)
@property
@pulumi.getter
def expiry(self) -> Optional[pulumi.Input[int]]:
return pulumi.get(self, "expiry")
@expiry.setter
def expiry(self, value: Optional[pulumi.Input[int]]):
pulumi.set(self, "expiry", value)
@property
@pulumi.getter
def fingerprint(self) -> Optional[pulumi.Input[str]]:
return pulumi.get(self, "fingerprint")
@fingerprint.setter
def fingerprint(self, value: Optional[pulumi.Input[str]]):
pulumi.set(self, "fingerprint", value)
@property
@pulumi.getter(name="fingerprintType")
def fingerprint_type(self) -> Optional[pulumi.Input[int]]:
return pulumi.get(self, "fingerprint_type")
@fingerprint_type.setter
def fingerprint_type(self, value: Optional[pulumi.Input[int]]):
pulumi.set(self, "fingerprint_type", value)
@property
@pulumi.getter
def flags(self) -> Optional[pulumi.Input[int]]:
return pulumi.get(self, "flags")
@flags.setter
def flags(self, value: Optional[pulumi.Input[int]]):
pulumi.set(self, "flags", value)
@property
@pulumi.getter
def flagsnaptr(self) -> Optional[pulumi.Input[str]]:
return pulumi.get(self, "flagsnaptr")
@flagsnaptr.setter
def flagsnaptr(self, value: Optional[pulumi.Input[str]]):
pulumi.set(self, "flagsnaptr", value)
@property
@pulumi.getter
def hardware(self) -> Optional[pulumi.Input[str]]:
return pulumi.get(self, "hardware")
@hardware.setter
def hardware(self, value: Optional[pulumi.Input[str]]):
pulumi.set(self, "hardware", value)
@property
@pulumi.getter
def inception(self) -> Optional[pulumi.Input[str]]:
return pulumi.get(self, "inception")
@inception.setter
def inception(self, value: Optional[pulumi.Input[str]]):
pulumi.set(self, "inception", value)
@property
@pulumi.getter
def iterations(self) -> Optional[pulumi.Input[int]]:
return pulumi.get(self, "iterations")
@iterations.setter
def iterations(self, value: Optional[pulumi.Input[int]]):
pulumi.set(self, "iterations", value)
@property
@pulumi.getter
def key(self) -> Optional[pulumi.Input[str]]:
return pulumi.get(self, "key")
@key.setter
def key(self, value: Optional[pulumi.Input[str]]):
pulumi.set(self, "key", value)
@property
@pulumi.getter
def keytag(self) -> Optional[pulumi.Input[int]]:
return pulumi.get(self, "keytag")
@keytag.setter
def keytag(self, value: Optional[pulumi.Input[int]]):
pulumi.set(self, "keytag", value)
@property
@pulumi.getter
def labels(self) -> Optional[pulumi.Input[int]]:
return pulumi.get(self, "labels")
@labels.setter
def labels(self, value: Optional[pulumi.Input[int]]):
pulumi.set(self, "labels", value)
@property
@pulumi.getter
def mailbox(self) -> Optional[pulumi.Input[str]]:
return pulumi.get(self, "mailbox")
@mailbox.setter
def mailbox(self, value: Optional[pulumi.Input[str]]):
pulumi.set(self, "mailbox", value)
@property
@pulumi.getter(name="matchType")
def match_type(self) -> Optional[pulumi.Input[int]]:
return pulumi.get(self, "match_type")
@match_type.setter
def match_type(self, value: Optional[pulumi.Input[int]]):
pulumi.set(self, "match_type", value)
@property
@pulumi.getter
def name(self) -> Optional[pulumi.Input[str]]:
return pulumi.get(self, "name")
@name.setter
def name(self, value: Optional[pulumi.Input[str]]):
pulumi.set(self, "name", value)
@property
@pulumi.getter(name="nameServer")
def name_server(self) -> Optional[pulumi.Input[str]]:
return pulumi.get(self, "name_server")
@name_server.setter
def name_server(self, value: Optional[pulumi.Input[str]]):
pulumi.set(self, "name_server", value)
@property
@pulumi.getter(name="nextHashedOwnerName")
def next_hashed_owner_name(self) -> Optional[pulumi.Input[str]]:
return pulumi.get(self, "next_hashed_owner_name")
@next_hashed_owner_name.setter
def next_hashed_owner_name(self, value: Optional[pulumi.Input[str]]):
pulumi.set(self, "next_hashed_owner_name", value)
@property
@pulumi.getter(name="nxdomainTtl")
def nxdomain_ttl(self) -> Optional[pulumi.Input[int]]:
return pulumi.get(self, "nxdomain_ttl")
@nxdomain_ttl.setter
def nxdomain_ttl(self, value: Optional[pulumi.Input[int]]):
pulumi.set(self, "nxdomain_ttl", value)
@property
@pulumi.getter
def order(self) -> Optional[pulumi.Input[int]]:
return pulumi.get(self, "order")
@order.setter
def order(self, value: Optional[pulumi.Input[int]]):
pulumi.set(self, "order", value)
@property
@pulumi.getter(name="originalTtl")
def original_ttl(self) -> Optional[pulumi.Input[int]]:
return pulumi.get(self, "original_ttl")
@original_ttl.setter
def original_ttl(self, value: Optional[pulumi.Input[int]]):
pulumi.set(self, "original_ttl", value)
@property
@pulumi.getter
def port(self) -> Optional[pulumi.Input[int]]:
return pulumi.get(self, "port")
@port.setter
def port(self, value: Optional[pulumi.Input[int]]):
pulumi.set(self, "port", value)
@property
@pulumi.getter
def preference(self) -> Optional[pulumi.Input[int]]:
return pulumi.get(self, "preference")
@preference.setter
def preference(self, value: Optional[pulumi.Input[int]]):
pulumi.set(self, "preference", value)
@property
@pulumi.getter
def priority(self) -> Optional[pulumi.Input[int]]:
return pulumi.get(self, "priority")
@priority.setter
def priority(self, value: Optional[pulumi.Input[int]]):
pulumi.set(self, "priority", value)
@property
@pulumi.getter(name="priorityIncrement")
def priority_increment(self) -> Optional[pulumi.Input[int]]:
return pulumi.get(self, "priority_increment")
@priority_increment.setter
def priority_increment(self, value: Optional[pulumi.Input[int]]):
pulumi.set(self, "priority_increment", value)
@property
@pulumi.getter
def protocol(self) -> Optional[pulumi.Input[int]]:
return pulumi.get(self, "protocol")
@protocol.setter
def protocol(self, value: Optional[pulumi.Input[int]]):
pulumi.set(self, "protocol", value)
@property
@pulumi.getter
def refresh(self) -> Optional[pulumi.Input[int]]:
return pulumi.get(self, "refresh")
@refresh.setter
def refresh(self, value: Optional[pulumi.Input[int]]):
pulumi.set(self, "refresh", value)
@property
@pulumi.getter
def regexp(self) -> Optional[pulumi.Input[str]]:
return pulumi.get(self, "regexp")
@regexp.setter
def regexp(self, value: Optional[pulumi.Input[str]]):
pulumi.set(self, "regexp", value)
@property
@pulumi.getter
def replacement(self) -> Optional[pulumi.Input[str]]:
return pulumi.get(self, "replacement")
@replacement.setter
def replacement(self, value: Optional[pulumi.Input[str]]):
pulumi.set(self, "replacement", value)
@property
@pulumi.getter
def retry(self) -> Optional[pulumi.Input[int]]:
return pulumi.get(self, "retry")
@retry.setter
def retry(self, value: Optional[pulumi.Input[int]]):
pulumi.set(self, "retry", value)
@property
@pulumi.getter
def salt(self) -> Optional[pulumi.Input[str]]:
return pulumi.get(self, "salt")
@salt.setter
def salt(self, value: Optional[pulumi.Input[str]]):
pulumi.set(self, "salt", value)
@property
@pulumi.getter
def selector(self) -> Optional[pulumi.Input[int]]:
return pulumi.get(self, "selector")
@selector.setter
def selector(self, value: Optional[pulumi.Input[int]]):
pulumi.set(self, "selector", value)
@property
@pulumi.getter
def service(self) -> Optional[pulumi.Input[str]]:
return pulumi.get(self, "service")
@service.setter
def service(self, value: Optional[pulumi.Input[str]]):
pulumi.set(self, "service", value)
@property
@pulumi.getter
def signature(self) -> Optional[pulumi.Input[str]]:
return pulumi.get(self, "signature")
@signature.setter
def signature(self, value: Optional[pulumi.Input[str]]):
pulumi.set(self, "signature", value)
@property
@pulumi.getter
def signer(self) -> Optional[pulumi.Input[str]]:
return pulumi.get(self, "signer")
@signer.setter
def signer(self, value: Optional[pulumi.Input[str]]):
pulumi.set(self, "signer", value)
@property
@pulumi.getter
def software(self) -> Optional[pulumi.Input[str]]:
return pulumi.get(self, "software")
@software.setter
def software(self, value: Optional[pulumi.Input[str]]):
pulumi.set(self, "software", value)
@property
@pulumi.getter
def subtype(self) -> Optional[pulumi.Input[int]]:
return pulumi.get(self, "subtype")
@subtype.setter
def subtype(self, value: Optional[pulumi.Input[int]]):
pulumi.set(self, "subtype", value)
@property
@pulumi.getter(name="svcParams")
def svc_params(self) -> Optional[pulumi.Input[str]]:
return pulumi.get(self, "svc_params")
@svc_params.setter
def svc_params(self, value: Optional[pulumi.Input[str]]):
pulumi.set(self, "svc_params", value)
@property
@pulumi.getter(name="svcPriority")
def svc_priority(self) -> Optional[pulumi.Input[int]]:
return pulumi.get(self, "svc_priority")
@svc_priority.setter
def svc_priority(self, value: Optional[pulumi.Input[int]]):
pulumi.set(self, "svc_priority", value)
@property
@pulumi.getter(name="targetName")
def target_name(self) -> Optional[pulumi.Input[str]]:
return pulumi.get(self, "target_name")
@target_name.setter
def target_name(self, value: Optional[pulumi.Input[str]]):
pulumi.set(self, "target_name", value)
@property
@pulumi.getter
def targets(self) -> Optional[pulumi.Input[Sequence[pulumi.Input[str]]]]:
return pulumi.get(self, "targets")
@targets.setter
def targets(self, value: Optional[pulumi.Input[Sequence[pulumi.Input[str]]]]):
pulumi.set(self, "targets", value)
@property
@pulumi.getter
def txt(self) -> Optional[pulumi.Input[str]]:
return pulumi.get(self, "txt")
@txt.setter
def txt(self, value: Optional[pulumi.Input[str]]):
pulumi.set(self, "txt", value)
@property
@pulumi.getter(name="typeBitmaps")
def type_bitmaps(self) -> Optional[pulumi.Input[str]]:
return pulumi.get(self, "type_bitmaps")
@type_bitmaps.setter
def type_bitmaps(self, value: Optional[pulumi.Input[str]]):
pulumi.set(self, "type_bitmaps", value)
@property
@pulumi.getter(name="typeCovered")
def type_covered(self) -> Optional[pulumi.Input[str]]:
return pulumi.get(self, "type_covered")
@type_covered.setter
def type_covered(self, value: Optional[pulumi.Input[str]]):
pulumi.set(self, "type_covered", value)
@property
@pulumi.getter(name="typeMnemonic")
def type_mnemonic(self) -> Optional[pulumi.Input[str]]:
return pulumi.get(self, "type_mnemonic")
@type_mnemonic.setter
def type_mnemonic(self, value: Optional[pulumi.Input[str]]):
pulumi.set(self, "type_mnemonic", value)
@property
@pulumi.getter(name="typeValue")
def type_value(self) -> Optional[pulumi.Input[int]]:
return pulumi.get(self, "type_value")
@type_value.setter
def type_value(self, value: Optional[pulumi.Input[int]]):
pulumi.set(self, "type_value", value)
@property
@pulumi.getter
def usage(self) -> Optional[pulumi.Input[int]]:
return pulumi.get(self, "usage")
@usage.setter
def usage(self, value: Optional[pulumi.Input[int]]):
pulumi.set(self, "usage", value)
@property
@pulumi.getter
def weight(self) -> Optional[pulumi.Input[int]]:
return pulumi.get(self, "weight")
@weight.setter
def weight(self, value: Optional[pulumi.Input[int]]):
pulumi.set(self, "weight", value)
@pulumi.input_type
class _DnsRecordState:
def __init__(__self__, *,
active: Optional[pulumi.Input[bool]] = None,
algorithm: Optional[pulumi.Input[int]] = None,
answer_type: Optional[pulumi.Input[str]] = None,
certificate: Optional[pulumi.Input[str]] = None,
digest: Optional[pulumi.Input[str]] = None,
digest_type: Optional[pulumi.Input[int]] = None,
dns_name: Optional[pulumi.Input[str]] = None,
email_address: Optional[pulumi.Input[str]] = None,
expiration: Optional[pulumi.Input[str]] = None,
expiry: Optional[pulumi.Input[int]] = None,
fingerprint: Optional[pulumi.Input[str]] = None,
fingerprint_type: Optional[pulumi.Input[int]] = None,
flags: Optional[pulumi.Input[int]] = None,
flagsnaptr: Optional[pulumi.Input[str]] = None,
hardware: Optional[pulumi.Input[str]] = None,
inception: Optional[pulumi.Input[str]] = None,
iterations: Optional[pulumi.Input[int]] = None,
key: Optional[pulumi.Input[str]] = None,
keytag: Optional[pulumi.Input[int]] = None,
labels: Optional[pulumi.Input[int]] = None,
mailbox: Optional[pulumi.Input[str]] = None,
match_type: Optional[pulumi.Input[int]] = None,
name: Optional[pulumi.Input[str]] = None,
name_server: Optional[pulumi.Input[str]] = None,
next_hashed_owner_name: Optional[pulumi.Input[str]] = None,
nxdomain_ttl: Optional[pulumi.Input[int]] = None,
order: Optional[pulumi.Input[int]] = None,
original_ttl: Optional[pulumi.Input[int]] = None,
port: Optional[pulumi.Input[int]] = None,
preference: Optional[pulumi.Input[int]] = None,
priority: Optional[pulumi.Input[int]] = None,
priority_increment: Optional[pulumi.Input[int]] = None,
protocol: Optional[pulumi.Input[int]] = None,
record_sha: Optional[pulumi.Input[str]] = None,
recordtype: Optional[pulumi.Input[str]] = None,
refresh: Optional[pulumi.Input[int]] = None,
regexp: Optional[pulumi.Input[str]] = None,
replacement: Optional[pulumi.Input[str]] = None,
retry: Optional[pulumi.Input[int]] = None,
salt: Optional[pulumi.Input[str]] = None,
selector: Optional[pulumi.Input[int]] = None,
serial: Optional[pulumi.Input[int]] = None,
service: Optional[pulumi.Input[str]] = None,
signature: Optional[pulumi.Input[str]] = None,
signer: Optional[pulumi.Input[str]] = None,
software: Optional[pulumi.Input[str]] = None,
subtype: Optional[pulumi.Input[int]] = None,
svc_params: Optional[pulumi.Input[str]] = None,
svc_priority: Optional[pulumi.Input[int]] = None,
target_name: Optional[pulumi.Input[str]] = None,
targets: Optional[pulumi.Input[Sequence[pulumi.Input[str]]]] = None,
ttl: Optional[pulumi.Input[int]] = None,
txt: Optional[pulumi.Input[str]] = None,
type_bitmaps: Optional[pulumi.Input[str]] = None,
type_covered: Optional[pulumi.Input[str]] = None,
type_mnemonic: Optional[pulumi.Input[str]] = None,
type_value: Optional[pulumi.Input[int]] = None,
usage: Optional[pulumi.Input[int]] = None,
weight: Optional[pulumi.Input[int]] = None,
zone: Optional[pulumi.Input[str]] = None):
"""
Input properties used for looking up and filtering DnsRecord resources.
"""
if active is not None:
pulumi.set(__self__, "active", active)
if algorithm is not None:
pulumi.set(__self__, "algorithm", algorithm)
if answer_type is not None:
pulumi.set(__self__, "answer_type", answer_type)
if certificate is not None:
pulumi.set(__self__, "certificate", certificate)
if digest is not None:
pulumi.set(__self__, "digest", digest)
if digest_type is not None:
pulumi.set(__self__, "digest_type", digest_type)
if dns_name is not None:
pulumi.set(__self__, "dns_name", dns_name)
if email_address is not None:
pulumi.set(__self__, "email_address", email_address)
if expiration is not None:
pulumi.set(__self__, "expiration", expiration)
if expiry is not None:
pulumi.set(__self__, "expiry", expiry)
if fingerprint is not None:
pulumi.set(__self__, "fingerprint", fingerprint)
if fingerprint_type is not None:
pulumi.set(__self__, "fingerprint_type", fingerprint_type)
if flags is not None:
pulumi.set(__self__, "flags", flags)
if flagsnaptr is not None:
pulumi.set(__self__, "flagsnaptr", flagsnaptr)
if hardware is not None:
pulumi.set(__self__, "hardware", hardware)
if inception is not None:
pulumi.set(__self__, "inception", inception)
if iterations is not None:
pulumi.set(__self__, "iterations", iterations)
if key is not None:
pulumi.set(__self__, "key", key)
if keytag is not None:
pulumi.set(__self__, "keytag", keytag)
if labels is not None:
pulumi.set(__self__, "labels", labels)
if mailbox is not None:
pulumi.set(__self__, "mailbox", mailbox)
if match_type is not None:
pulumi.set(__self__, "match_type", match_type)
if name is not None:
pulumi.set(__self__, "name", name)
if name_server is not None:
pulumi.set(__self__, "name_server", name_server)
if next_hashed_owner_name is not None:
pulumi.set(__self__, "next_hashed_owner_name", next_hashed_owner_name)
if nxdomain_ttl is not None:
pulumi.set(__self__, "nxdomain_ttl", nxdomain_ttl)
if order is not None:
pulumi.set(__self__, "order", order)
if original_ttl is not None:
pulumi.set(__self__, "original_ttl", original_ttl)
if port is not None:
pulumi.set(__self__, "port", port)
if preference is not None:
pulumi.set(__self__, "preference", preference)
if priority is not None:
pulumi.set(__self__, "priority", priority)
if priority_increment is not None:
pulumi.set(__self__, "priority_increment", priority_increment)
if protocol is not None:
pulumi.set(__self__, "protocol", protocol)
if record_sha is not None:
pulumi.set(__self__, "record_sha", record_sha)
if recordtype is not None:
pulumi.set(__self__, "recordtype", recordtype)
if refresh is not None:
pulumi.set(__self__, "refresh", refresh)
if regexp is not None:
pulumi.set(__self__, "regexp", regexp)
if replacement is not None:
pulumi.set(__self__, "replacement", replacement)
if retry is not None:
pulumi.set(__self__, "retry", retry)
if salt is not None:
pulumi.set(__self__, "salt", salt)
if selector is not None:
pulumi.set(__self__, "selector", selector)
if serial is not None:
pulumi.set(__self__, "serial", serial)
if service is not None:
pulumi.set(__self__, "service", service)
if signature is not None:
pulumi.set(__self__, "signature", signature)
if signer is not None:
pulumi.set(__self__, "signer", signer)
if software is not None:
pulumi.set(__self__, "software", software)
if subtype is not None:
pulumi.set(__self__, "subtype", subtype)
if svc_params is not None:
pulumi.set(__self__, "svc_params", svc_params)
if svc_priority is not None:
pulumi.set(__self__, "svc_priority", svc_priority)
if target_name is not None:
pulumi.set(__self__, "target_name", target_name)
if targets is not None:
pulumi.set(__self__, "targets", targets)
if ttl is not None:
pulumi.set(__self__, "ttl", ttl)
if txt is not None:
pulumi.set(__self__, "txt", txt)
if type_bitmaps is not None:
pulumi.set(__self__, "type_bitmaps", type_bitmaps)
if type_covered is not None:
pulumi.set(__self__, "type_covered", type_covered)
if type_mnemonic is not None:
pulumi.set(__self__, "type_mnemonic", type_mnemonic)
if type_value is not None:
pulumi.set(__self__, "type_value", type_value)
if usage is not None:
pulumi.set(__self__, "usage", usage)
if weight is not None:
pulumi.set(__self__, "weight", weight)
if zone is not None:
pulumi.set(__self__, "zone", zone)
@property
@pulumi.getter
def active(self) -> Optional[pulumi.Input[bool]]:
return pulumi.get(self, "active")
@active.setter
def active(self, value: Optional[pulumi.Input[bool]]):
pulumi.set(self, "active", value)
@property
@pulumi.getter
def algorithm(self) -> Optional[pulumi.Input[int]]:
return pulumi.get(self, "algorithm")
@algorithm.setter
def algorithm(self, value: Optional[pulumi.Input[int]]):
pulumi.set(self, "algorithm", value)
@property
@pulumi.getter(name="answerType")
def answer_type(self) -> Optional[pulumi.Input[str]]:
return pulumi.get(self, "answer_type")
@answer_type.setter
def answer_type(self, value: Optional[pulumi.Input[str]]):
pulumi.set(self, "answer_type", value)
@property
@pulumi.getter
def certificate(self) -> Optional[pulumi.Input[str]]:
return pulumi.get(self, "certificate")
@certificate.setter
def certificate(self, value: Optional[pulumi.Input[str]]):
pulumi.set(self, "certificate", value)
@property
@pulumi.getter
def digest(self) -> Optional[pulumi.Input[str]]:
return pulumi.get(self, "digest")
@digest.setter
def digest(self, value: Optional[pulumi.Input[str]]):
pulumi.set(self, "digest", value)
@property
@pulumi.getter(name="digestType")
def digest_type(self) -> Optional[pulumi.Input[int]]:
return pulumi.get(self, "digest_type")
@digest_type.setter
def digest_type(self, value: Optional[pulumi.Input[int]]):
pulumi.set(self, "digest_type", value)
@property
@pulumi.getter(name="dnsName")
def dns_name(self) -> Optional[pulumi.Input[str]]:
return pulumi.get(self, "dns_name")
@dns_name.setter
def dns_name(self, value: Optional[pulumi.Input[str]]):
pulumi.set(self, "dns_name", value)
@property
@pulumi.getter(name="emailAddress")
def email_address(self) -> Optional[pulumi.Input[str]]:
return pulumi.get(self, "email_address")
@email_address.setter
def email_address(self, value: Optional[pulumi.Input[str]]):
pulumi.set(self, "email_address", value)
@property
@pulumi.getter
def expiration(self) -> Optional[pulumi.Input[str]]:
return pulumi.get(self, "expiration")
@expiration.setter
def expiration(self, value: Optional[pulumi.Input[str]]):
pulumi.set(self, "expiration", value)
@property
@pulumi.getter
def expiry(self) -> Optional[pulumi.Input[int]]:
return pulumi.get(self, "expiry")
@expiry.setter
def expiry(self, value: Optional[pulumi.Input[int]]):
pulumi.set(self, "expiry", value)
@property
@pulumi.getter
def fingerprint(self) -> Optional[pulumi.Input[str]]:
return pulumi.get(self, "fingerprint")
@fingerprint.setter
def fingerprint(self, value: Optional[pulumi.Input[str]]):
pulumi.set(self, "fingerprint", value)
@property
@pulumi.getter(name="fingerprintType")
def fingerprint_type(self) -> Optional[pulumi.Input[int]]:
return pulumi.get(self, "fingerprint_type")
@fingerprint_type.setter
def fingerprint_type(self, value: Optional[pulumi.Input[int]]):
pulumi.set(self, "fingerprint_type", value)
@property
@pulumi.getter
def flags(self) -> Optional[pulumi.Input[int]]:
return pulumi.get(self, "flags")
@flags.setter
def flags(self, value: Optional[pulumi.Input[int]]):
pulumi.set(self, "flags", value)
@property
@pulumi.getter
def flagsnaptr(self) -> Optional[pulumi.Input[str]]:
return pulumi.get(self, "flagsnaptr")
@flagsnaptr.setter
def flagsnaptr(self, value: Optional[pulumi.Input[str]]):
pulumi.set(self, "flagsnaptr", value)
@property
@pulumi.getter
def hardware(self) -> Optional[pulumi.Input[str]]:
return pulumi.get(self, "hardware")
@hardware.setter
def hardware(self, value: Optional[pulumi.Input[str]]):
pulumi.set(self, "hardware", value)
@property
@pulumi.getter
def inception(self) -> Optional[pulumi.Input[str]]:
return pulumi.get(self, "inception")
@inception.setter
def inception(self, value: Optional[pulumi.Input[str]]):
pulumi.set(self, "inception", value)
@property
@pulumi.getter
def iterations(self) -> Optional[pulumi.Input[int]]:
return pulumi.get(self, "iterations")
@iterations.setter
def iterations(self, value: Optional[pulumi.Input[int]]):
pulumi.set(self, "iterations", value)
@property
@pulumi.getter
def key(self) -> Optional[pulumi.Input[str]]:
return pulumi.get(self, "key")
@key.setter
def key(self, value: Optional[pulumi.Input[str]]):
pulumi.set(self, "key", value)
@property
@pulumi.getter
def keytag(self) -> Optional[pulumi.Input[int]]:
return pulumi.get(self, "keytag")
@keytag.setter
def keytag(self, value: Optional[pulumi.Input[int]]):
pulumi.set(self, "keytag", value)
@property
@pulumi.getter
def labels(self) -> Optional[pulumi.Input[int]]:
return pulumi.get(self, "labels")
@labels.setter
def labels(self, value: Optional[pulumi.Input[int]]):
pulumi.set(self, "labels", value)
@property
@pulumi.getter
def mailbox(self) -> Optional[pulumi.Input[str]]:
return pulumi.get(self, "mailbox")
@mailbox.setter
def mailbox(self, value: Optional[pulumi.Input[str]]):
pulumi.set(self, "mailbox", value)
@property
@pulumi.getter(name="matchType")
def match_type(self) -> Optional[pulumi.Input[int]]:
return pulumi.get(self, "match_type")
@match_type.setter
def match_type(self, value: Optional[pulumi.Input[int]]):
pulumi.set(self, "match_type", value)
@property
@pulumi.getter
def name(self) -> Optional[pulumi.Input[str]]:
return pulumi.get(self, "name")
@name.setter
def name(self, value: Optional[pulumi.Input[str]]):
pulumi.set(self, "name", value)
@property
@pulumi.getter(name="nameServer")
def name_server(self) -> Optional[pulumi.Input[str]]:
return pulumi.get(self, "name_server")
@name_server.setter
def name_server(self, value: Optional[pulumi.Input[str]]):
pulumi.set(self, "name_server", value)
@property
@pulumi.getter(name="nextHashedOwnerName")
def next_hashed_owner_name(self) -> Optional[pulumi.Input[str]]:
return pulumi.get(self, "next_hashed_owner_name")
@next_hashed_owner_name.setter
def next_hashed_owner_name(self, value: Optional[pulumi.Input[str]]):
pulumi.set(self, "next_hashed_owner_name", value)
@property
@pulumi.getter(name="nxdomainTtl")
def nxdomain_ttl(self) -> Optional[pulumi.Input[int]]:
return pulumi.get(self, "nxdomain_ttl")
@nxdomain_ttl.setter
def nxdomain_ttl(self, value: Optional[pulumi.Input[int]]):
pulumi.set(self, "nxdomain_ttl", value)
@property
@pulumi.getter
def order(self) -> Optional[pulumi.Input[int]]:
return pulumi.get(self, "order")
@order.setter
def order(self, value: Optional[pulumi.Input[int]]):
pulumi.set(self, "order", value)
@property
@pulumi.getter(name="originalTtl")
def original_ttl(self) -> Optional[pulumi.Input[int]]:
return pulumi.get(self, "original_ttl")
@original_ttl.setter
def original_ttl(self, value: Optional[pulumi.Input[int]]):
pulumi.set(self, "original_ttl", value)
@property
@pulumi.getter
def port(self) -> Optional[pulumi.Input[int]]:
return pulumi.get(self, "port")
@port.setter
def port(self, value: Optional[pulumi.Input[int]]):
pulumi.set(self, "port", value)
@property
@pulumi.getter
def preference(self) -> Optional[pulumi.Input[int]]:
return pulumi.get(self, "preference")
@preference.setter
def preference(self, value: Optional[pulumi.Input[int]]):
pulumi.set(self, "preference", value)
@property
@pulumi.getter
def priority(self) -> Optional[pulumi.Input[int]]:
return pulumi.get(self, "priority")
@priority.setter
def priority(self, value: Optional[pulumi.Input[int]]):
pulumi.set(self, "priority", value)
@property
@pulumi.getter(name="priorityIncrement")
def priority_increment(self) -> Optional[pulumi.Input[int]]:
return pulumi.get(self, "priority_increment")
@priority_increment.setter
def priority_increment(self, value: Optional[pulumi.Input[int]]):
pulumi.set(self, "priority_increment", value)
@property
@pulumi.getter
def protocol(self) -> Optional[pulumi.Input[int]]:
return pulumi.get(self, "protocol")
@protocol.setter
def protocol(self, value: Optional[pulumi.Input[int]]):
pulumi.set(self, "protocol", value)
@property
@pulumi.getter(name="recordSha")
def record_sha(self) -> Optional[pulumi.Input[str]]:
return pulumi.get(self, "record_sha")
@record_sha.setter
def record_sha(self, value: Optional[pulumi.Input[str]]):
pulumi.set(self, "record_sha", value)
@property
@pulumi.getter
def recordtype(self) -> Optional[pulumi.Input[str]]:
return pulumi.get(self, "recordtype")
@recordtype.setter
def recordtype(self, value: Optional[pulumi.Input[str]]):
pulumi.set(self, "recordtype", value)
@property
@pulumi.getter
def refresh(self) -> Optional[pulumi.Input[int]]:
return pulumi.get(self, "refresh")
@refresh.setter
def refresh(self, value: Optional[pulumi.Input[int]]):
pulumi.set(self, "refresh", value)
@property
@pulumi.getter
def regexp(self) -> Optional[pulumi.Input[str]]:
return pulumi.get(self, "regexp")
@regexp.setter
def regexp(self, value: Optional[pulumi.Input[str]]):
pulumi.set(self, "regexp", value)
@property
@pulumi.getter
def replacement(self) -> Optional[pulumi.Input[str]]:
return pulumi.get(self, "replacement")
@replacement.setter
def replacement(self, value: Optional[pulumi.Input[str]]):
pulumi.set(self, "replacement", value)
@property
@pulumi.getter
def retry(self) -> Optional[pulumi.Input[int]]:
return pulumi.get(self, "retry")
@retry.setter
def retry(self, value: Optional[pulumi.Input[int]]):
pulumi.set(self, "retry", value)
@property
@pulumi.getter
def salt(self) -> Optional[pulumi.Input[str]]:
return pulumi.get(self, "salt")
@salt.setter
def salt(self, value: Optional[pulumi.Input[str]]):
pulumi.set(self, "salt", value)
@property
@pulumi.getter
def selector(self) -> Optional[pulumi.Input[int]]:
return pulumi.get(self, "selector")
@selector.setter
def selector(self, value: Optional[pulumi.Input[int]]):
pulumi.set(self, "selector", value)
@property
@pulumi.getter
def serial(self) -> Optional[pulumi.Input[int]]:
return pulumi.get(self, "serial")
@serial.setter
def serial(self, value: Optional[pulumi.Input[int]]):
pulumi.set(self, "serial", value)
@property
@pulumi.getter
def service(self) -> Optional[pulumi.Input[str]]:
return pulumi.get(self, "service")
@service.setter
def service(self, value: Optional[pulumi.Input[str]]):
pulumi.set(self, "service", value)
@property
@pulumi.getter
def signature(self) -> Optional[pulumi.Input[str]]:
return pulumi.get(self, "signature")
@signature.setter
def signature(self, value: Optional[pulumi.Input[str]]):
pulumi.set(self, "signature", value)
@property
@pulumi.getter
def signer(self) -> Optional[pulumi.Input[str]]:
return pulumi.get(self, "signer")
@signer.setter
def signer(self, value: Optional[pulumi.Input[str]]):
pulumi.set(self, "signer", value)
@property
@pulumi.getter
def software(self) -> Optional[pulumi.Input[str]]:
return pulumi.get(self, "software")
@software.setter
def software(self, value: Optional[pulumi.Input[str]]):
pulumi.set(self, "software", value)
@property
@pulumi.getter
def subtype(self) -> Optional[pulumi.Input[int]]:
return pulumi.get(self, "subtype")
@subtype.setter
def subtype(self, value: Optional[pulumi.Input[int]]):
pulumi.set(self, "subtype", value)
@property
@pulumi.getter(name="svcParams")
def svc_params(self) -> Optional[pulumi.Input[str]]:
return pulumi.get(self, "svc_params")
@svc_params.setter
def svc_params(self, value: Optional[pulumi.Input[str]]):
pulumi.set(self, "svc_params", value)
@property
@pulumi.getter(name="svcPriority")
def svc_priority(self) -> Optional[pulumi.Input[int]]:
return pulumi.get(self, "svc_priority")
@svc_priority.setter
def svc_priority(self, value: Optional[pulumi.Input[int]]):
pulumi.set(self, "svc_priority", value)
@property
@pulumi.getter(name="targetName")
def target_name(self) -> Optional[pulumi.Input[str]]:
return pulumi.get(self, "target_name")
@target_name.setter
def target_name(self, value: Optional[pulumi.Input[str]]):
pulumi.set(self, "target_name", value)
@property
@pulumi.getter
def targets(self) -> Optional[pulumi.Input[Sequence[pulumi.Input[str]]]]:
return pulumi.get(self, "targets")
@targets.setter
def targets(self, value: Optional[pulumi.Input[Sequence[pulumi.Input[str]]]]):
pulumi.set(self, "targets", value)
@property
@pulumi.getter
def ttl(self) -> Optional[pulumi.Input[int]]:
return pulumi.get(self, "ttl")
@ttl.setter
def ttl(self, value: Optional[pulumi.Input[int]]):
pulumi.set(self, "ttl", value)
@property
@pulumi.getter
def txt(self) -> Optional[pulumi.Input[str]]:
return pulumi.get(self, "txt")
@txt.setter
def txt(self, value: Optional[pulumi.Input[str]]):
pulumi.set(self, "txt", value)
@property
@pulumi.getter(name="typeBitmaps")
def type_bitmaps(self) -> Optional[pulumi.Input[str]]:
return pulumi.get(self, "type_bitmaps")
@type_bitmaps.setter
def type_bitmaps(self, value: Optional[pulumi.Input[str]]):
pulumi.set(self, "type_bitmaps", value)
@property
@pulumi.getter(name="typeCovered")
def type_covered(self) -> Optional[pulumi.Input[str]]:
return pulumi.get(self, "type_covered")
@type_covered.setter
def type_covered(self, value: Optional[pulumi.Input[str]]):
pulumi.set(self, "type_covered", value)
@property
@pulumi.getter(name="typeMnemonic")
def type_mnemonic(self) -> Optional[pulumi.Input[str]]:
return pulumi.get(self, "type_mnemonic")
@type_mnemonic.setter
def type_mnemonic(self, value: Optional[pulumi.Input[str]]):
pulumi.set(self, "type_mnemonic", value)
@property
@pulumi.getter(name="typeValue")
def type_value(self) -> Optional[pulumi.Input[int]]:
return pulumi.get(self, "type_value")
@type_value.setter
def type_value(self, value: Optional[pulumi.Input[int]]):
pulumi.set(self, "type_value", value)
@property
@pulumi.getter
def usage(self) -> Optional[pulumi.Input[int]]:
return pulumi.get(self, "usage")
@usage.setter
def usage(self, value: Optional[pulumi.Input[int]]):
pulumi.set(self, "usage", value)
@property
@pulumi.getter
def weight(self) -> Optional[pulumi.Input[int]]:
return pulumi.get(self, "weight")
@weight.setter
def weight(self, value: Optional[pulumi.Input[int]]):
pulumi.set(self, "weight", value)
@property
@pulumi.getter
def zone(self) -> Optional[pulumi.Input[str]]:
return pulumi.get(self, "zone")
@zone.setter
def zone(self, value: Optional[pulumi.Input[str]]):
pulumi.set(self, "zone", value)
warnings.warn("""akamai.edgedns.DnsRecord has been deprecated in favor of akamai.DnsRecord""", DeprecationWarning)
class DnsRecord(pulumi.CustomResource):
warnings.warn("""akamai.edgedns.DnsRecord has been deprecated in favor of akamai.DnsRecord""", DeprecationWarning)
@overload
def __init__(__self__,
resource_name: str,
opts: Optional[pulumi.ResourceOptions] = None,
active: Optional[pulumi.Input[bool]] = None,
algorithm: Optional[pulumi.Input[int]] = None,
certificate: Optional[pulumi.Input[str]] = None,
digest: Optional[pulumi.Input[str]] = None,
digest_type: Optional[pulumi.Input[int]] = None,
email_address: Optional[pulumi.Input[str]] = None,
expiration: Optional[pulumi.Input[str]] = None,
expiry: Optional[pulumi.Input[int]] = None,
fingerprint: Optional[pulumi.Input[str]] = None,
fingerprint_type: Optional[pulumi.Input[int]] = None,
flags: Optional[pulumi.Input[int]] = None,
flagsnaptr: Optional[pulumi.Input[str]] = None,
hardware: Optional[pulumi.Input[str]] = None,
inception: Optional[pulumi.Input[str]] = None,
iterations: Optional[pulumi.Input[int]] = None,
key: Optional[pulumi.Input[str]] = None,
keytag: Optional[pulumi.Input[int]] = None,
labels: Optional[pulumi.Input[int]] = None,
mailbox: Optional[pulumi.Input[str]] = None,
match_type: Optional[pulumi.Input[int]] = None,
name: Optional[pulumi.Input[str]] = None,
name_server: Optional[pulumi.Input[str]] = None,
next_hashed_owner_name: Optional[pulumi.Input[str]] = None,
nxdomain_ttl: Optional[pulumi.Input[int]] = None,
order: Optional[pulumi.Input[int]] = None,
original_ttl: Optional[pulumi.Input[int]] = None,
port: Optional[pulumi.Input[int]] = None,
preference: Optional[pulumi.Input[int]] = None,
priority: Optional[pulumi.Input[int]] = None,
priority_increment: Optional[pulumi.Input[int]] = None,
protocol: Optional[pulumi.Input[int]] = None,
recordtype: Optional[pulumi.Input[str]] = None,
refresh: Optional[pulumi.Input[int]] = None,
regexp: Optional[pulumi.Input[str]] = None,
replacement: Optional[pulumi.Input[str]] = None,
retry: Optional[pulumi.Input[int]] = None,
salt: Optional[pulumi.Input[str]] = None,
selector: Optional[pulumi.Input[int]] = None,
service: Optional[pulumi.Input[str]] = None,
signature: Optional[pulumi.Input[str]] = None,
signer: Optional[pulumi.Input[str]] = None,
software: Optional[pulumi.Input[str]] = None,
subtype: Optional[pulumi.Input[int]] = None,
svc_params: Optional[pulumi.Input[str]] = None,
svc_priority: Optional[pulumi.Input[int]] = None,
target_name: Optional[pulumi.Input[str]] = None,
targets: Optional[pulumi.Input[Sequence[pulumi.Input[str]]]] = None,
ttl: Optional[pulumi.Input[int]] = None,
txt: Optional[pulumi.Input[str]] = None,
type_bitmaps: Optional[pulumi.Input[str]] = None,
type_covered: Optional[pulumi.Input[str]] = None,
type_mnemonic: Optional[pulumi.Input[str]] = None,
type_value: Optional[pulumi.Input[int]] = None,
usage: Optional[pulumi.Input[int]] = None,
weight: Optional[pulumi.Input[int]] = None,
zone: Optional[pulumi.Input[str]] = None,
__props__=None):
"""
Create a DnsRecord resource with the given unique name, props, and options.
:param str resource_name: The name of the resource.
:param pulumi.ResourceOptions opts: Options for the resource.
"""
...
@overload
def __init__(__self__,
resource_name: str,
args: DnsRecordArgs,
opts: Optional[pulumi.ResourceOptions] = None):
"""
Create a DnsRecord resource with the given unique name, props, and options.
:param str resource_name: The name of the resource.
:param DnsRecordArgs args: The arguments to use to populate this resource's properties.
:param pulumi.ResourceOptions opts: Options for the resource.
"""
...
def __init__(__self__, resource_name: str, *args, **kwargs):
resource_args, opts = _utilities.get_resource_args_opts(DnsRecordArgs, pulumi.ResourceOptions, *args, **kwargs)
if resource_args is not None:
__self__._internal_init(resource_name, opts, **resource_args.__dict__)
else:
__self__._internal_init(resource_name, *args, **kwargs)
def _internal_init(__self__,
resource_name: str,
opts: Optional[pulumi.ResourceOptions] = None,
active: Optional[pulumi.Input[bool]] = None,
algorithm: Optional[pulumi.Input[int]] = None,
certificate: Optional[pulumi.Input[str]] = None,
digest: Optional[pulumi.Input[str]] = None,
digest_type: Optional[pulumi.Input[int]] = None,
email_address: Optional[pulumi.Input[str]] = None,
expiration: Optional[pulumi.Input[str]] = None,
expiry: Optional[pulumi.Input[int]] = None,
fingerprint: Optional[pulumi.Input[str]] = None,
fingerprint_type: Optional[pulumi.Input[int]] = None,
flags: Optional[pulumi.Input[int]] = None,
flagsnaptr: Optional[pulumi.Input[str]] = None,
hardware: Optional[pulumi.Input[str]] = None,
inception: Optional[pulumi.Input[str]] = None,
iterations: Optional[pulumi.Input[int]] = None,
key: Optional[pulumi.Input[str]] = None,
keytag: Optional[pulumi.Input[int]] = None,
labels: Optional[pulumi.Input[int]] = None,
mailbox: Optional[pulumi.Input[str]] = None,
match_type: Optional[pulumi.Input[int]] = None,
name: Optional[pulumi.Input[str]] = None,
name_server: Optional[pulumi.Input[str]] = None,
next_hashed_owner_name: Optional[pulumi.Input[str]] = None,
nxdomain_ttl: Optional[pulumi.Input[int]] = None,
order: Optional[pulumi.Input[int]] = None,
original_ttl: Optional[pulumi.Input[int]] = None,
port: Optional[pulumi.Input[int]] = None,
preference: Optional[pulumi.Input[int]] = None,
priority: Optional[pulumi.Input[int]] = None,
priority_increment: Optional[pulumi.Input[int]] = None,
protocol: Optional[pulumi.Input[int]] = None,
recordtype: Optional[pulumi.Input[str]] = None,
refresh: Optional[pulumi.Input[int]] = None,
regexp: Optional[pulumi.Input[str]] = None,
replacement: Optional[pulumi.Input[str]] = None,
retry: Optional[pulumi.Input[int]] = None,
salt: Optional[pulumi.Input[str]] = None,
selector: Optional[pulumi.Input[int]] = None,
service: Optional[pulumi.Input[str]] = None,
signature: Optional[pulumi.Input[str]] = None,
signer: Optional[pulumi.Input[str]] = None,
software: Optional[pulumi.Input[str]] = None,
subtype: Optional[pulumi.Input[int]] = None,
svc_params: Optional[pulumi.Input[str]] = None,
svc_priority: Optional[pulumi.Input[int]] = None,
target_name: Optional[pulumi.Input[str]] = None,
targets: Optional[pulumi.Input[Sequence[pulumi.Input[str]]]] = None,
ttl: Optional[pulumi.Input[int]] = None,
txt: Optional[pulumi.Input[str]] = None,
type_bitmaps: Optional[pulumi.Input[str]] = None,
type_covered: Optional[pulumi.Input[str]] = None,
type_mnemonic: Optional[pulumi.Input[str]] = None,
type_value: Optional[pulumi.Input[int]] = None,
usage: Optional[pulumi.Input[int]] = None,
weight: Optional[pulumi.Input[int]] = None,
zone: Optional[pulumi.Input[str]] = None,
__props__=None):
pulumi.log.warn("""DnsRecord is deprecated: akamai.edgedns.DnsRecord has been deprecated in favor of akamai.DnsRecord""")
if opts is None:
opts = pulumi.ResourceOptions()
if not isinstance(opts, pulumi.ResourceOptions):
raise TypeError('Expected resource options to be a ResourceOptions instance')
if opts.version is None:
opts.version = _utilities.get_version()
if opts.id is None:
if __props__ is not None:
raise TypeError('__props__ is only valid when passed in combination with a valid opts.id to get an existing resource')
__props__ = DnsRecordArgs.__new__(DnsRecordArgs)
__props__.__dict__["active"] = active
__props__.__dict__["algorithm"] = algorithm
__props__.__dict__["certificate"] = certificate
__props__.__dict__["digest"] = digest
__props__.__dict__["digest_type"] = digest_type
__props__.__dict__["email_address"] = email_address
__props__.__dict__["expiration"] = expiration
__props__.__dict__["expiry"] = expiry
__props__.__dict__["fingerprint"] = fingerprint
__props__.__dict__["fingerprint_type"] = fingerprint_type
__props__.__dict__["flags"] = flags
__props__.__dict__["flagsnaptr"] = flagsnaptr
__props__.__dict__["hardware"] = hardware
__props__.__dict__["inception"] = inception
__props__.__dict__["iterations"] = iterations
__props__.__dict__["key"] = key
__props__.__dict__["keytag"] = keytag
__props__.__dict__["labels"] = labels
__props__.__dict__["mailbox"] = mailbox
__props__.__dict__["match_type"] = match_type
__props__.__dict__["name"] = name
__props__.__dict__["name_server"] = name_server
__props__.__dict__["next_hashed_owner_name"] = next_hashed_owner_name
__props__.__dict__["nxdomain_ttl"] = nxdomain_ttl
__props__.__dict__["order"] = order
__props__.__dict__["original_ttl"] = original_ttl
__props__.__dict__["port"] = port
__props__.__dict__["preference"] = preference
__props__.__dict__["priority"] = priority
__props__.__dict__["priority_increment"] = priority_increment
__props__.__dict__["protocol"] = protocol
if recordtype is None and not opts.urn:
raise TypeError("Missing required property 'recordtype'")
__props__.__dict__["recordtype"] = recordtype
__props__.__dict__["refresh"] = refresh
__props__.__dict__["regexp"] = regexp
__props__.__dict__["replacement"] = replacement
__props__.__dict__["retry"] = retry
__props__.__dict__["salt"] = salt
__props__.__dict__["selector"] = selector
__props__.__dict__["service"] = service
__props__.__dict__["signature"] = signature
__props__.__dict__["signer"] = signer
__props__.__dict__["software"] = software
__props__.__dict__["subtype"] = subtype
__props__.__dict__["svc_params"] = svc_params
__props__.__dict__["svc_priority"] = svc_priority
__props__.__dict__["target_name"] = target_name
__props__.__dict__["targets"] = targets
if ttl is None and not opts.urn:
raise TypeError("Missing required property 'ttl'")
__props__.__dict__["ttl"] = ttl
__props__.__dict__["txt"] = txt
__props__.__dict__["type_bitmaps"] = type_bitmaps
__props__.__dict__["type_covered"] = type_covered
__props__.__dict__["type_mnemonic"] = type_mnemonic
__props__.__dict__["type_value"] = type_value
__props__.__dict__["usage"] = usage
__props__.__dict__["weight"] = weight
if zone is None and not opts.urn:
raise TypeError("Missing required property 'zone'")
__props__.__dict__["zone"] = zone
__props__.__dict__["answer_type"] = None
__props__.__dict__["dns_name"] = None
__props__.__dict__["record_sha"] = None
__props__.__dict__["serial"] = None
super(DnsRecord, __self__).__init__(
'akamai:edgedns/dnsRecord:DnsRecord',
resource_name,
__props__,
opts)
@staticmethod
def get(resource_name: str,
id: pulumi.Input[str],
opts: Optional[pulumi.ResourceOptions] = None,
active: Optional[pulumi.Input[bool]] = None,
algorithm: Optional[pulumi.Input[int]] = None,
answer_type: Optional[pulumi.Input[str]] = None,
certificate: Optional[pulumi.Input[str]] = None,
digest: Optional[pulumi.Input[str]] = None,
digest_type: Optional[pulumi.Input[int]] = None,
dns_name: Optional[pulumi.Input[str]] = None,
email_address: Optional[pulumi.Input[str]] = None,
expiration: Optional[pulumi.Input[str]] = None,
expiry: Optional[pulumi.Input[int]] = None,
fingerprint: Optional[pulumi.Input[str]] = None,
fingerprint_type: Optional[pulumi.Input[int]] = None,
flags: Optional[pulumi.Input[int]] = None,
flagsnaptr: Optional[pulumi.Input[str]] = None,
hardware: Optional[pulumi.Input[str]] = None,
inception: Optional[pulumi.Input[str]] = None,
iterations: Optional[pulumi.Input[int]] = None,
key: Optional[pulumi.Input[str]] = None,
keytag: Optional[pulumi.Input[int]] = None,
labels: Optional[pulumi.Input[int]] = None,
mailbox: Optional[pulumi.Input[str]] = None,
match_type: Optional[pulumi.Input[int]] = None,
name: Optional[pulumi.Input[str]] = None,
name_server: Optional[pulumi.Input[str]] = None,
next_hashed_owner_name: Optional[pulumi.Input[str]] = None,
nxdomain_ttl: Optional[pulumi.Input[int]] = None,
order: Optional[pulumi.Input[int]] = None,
original_ttl: Optional[pulumi.Input[int]] = None,
port: Optional[pulumi.Input[int]] = None,
preference: Optional[pulumi.Input[int]] = None,
priority: Optional[pulumi.Input[int]] = None,
priority_increment: Optional[pulumi.Input[int]] = None,
protocol: Optional[pulumi.Input[int]] = None,
record_sha: Optional[pulumi.Input[str]] = None,
recordtype: Optional[pulumi.Input[str]] = None,
refresh: Optional[pulumi.Input[int]] = None,
regexp: Optional[pulumi.Input[str]] = None,
replacement: Optional[pulumi.Input[str]] = None,
retry: Optional[pulumi.Input[int]] = None,
salt: Optional[pulumi.Input[str]] = None,
selector: Optional[pulumi.Input[int]] = None,
serial: Optional[pulumi.Input[int]] = None,
service: Optional[pulumi.Input[str]] = None,
signature: Optional[pulumi.Input[str]] = None,
signer: Optional[pulumi.Input[str]] = None,
software: Optional[pulumi.Input[str]] = None,
subtype: Optional[pulumi.Input[int]] = None,
svc_params: Optional[pulumi.Input[str]] = None,
svc_priority: Optional[pulumi.Input[int]] = None,
target_name: Optional[pulumi.Input[str]] = None,
targets: Optional[pulumi.Input[Sequence[pulumi.Input[str]]]] = None,
ttl: Optional[pulumi.Input[int]] = None,
txt: Optional[pulumi.Input[str]] = None,
type_bitmaps: Optional[pulumi.Input[str]] = None,
type_covered: Optional[pulumi.Input[str]] = None,
type_mnemonic: Optional[pulumi.Input[str]] = None,
type_value: Optional[pulumi.Input[int]] = None,
usage: Optional[pulumi.Input[int]] = None,
weight: Optional[pulumi.Input[int]] = None,
zone: Optional[pulumi.Input[str]] = None) -> 'DnsRecord':
"""
Get an existing DnsRecord resource's state with the given name, id, and optional extra
properties used to qualify the lookup.
:param str resource_name: The unique name of the resulting resource.
:param pulumi.Input[str] id: The unique provider ID of the resource to lookup.
:param pulumi.ResourceOptions opts: Options for the resource.
"""
opts = pulumi.ResourceOptions.merge(opts, pulumi.ResourceOptions(id=id))
__props__ = _DnsRecordState.__new__(_DnsRecordState)
__props__.__dict__["active"] = active
__props__.__dict__["algorithm"] = algorithm
__props__.__dict__["answer_type"] = answer_type
__props__.__dict__["certificate"] = certificate
__props__.__dict__["digest"] = digest
__props__.__dict__["digest_type"] = digest_type
__props__.__dict__["dns_name"] = dns_name
__props__.__dict__["email_address"] = email_address
__props__.__dict__["expiration"] = expiration
__props__.__dict__["expiry"] = expiry
__props__.__dict__["fingerprint"] = fingerprint
__props__.__dict__["fingerprint_type"] = fingerprint_type
__props__.__dict__["flags"] = flags
__props__.__dict__["flagsnaptr"] = flagsnaptr
__props__.__dict__["hardware"] = hardware
__props__.__dict__["inception"] = inception
__props__.__dict__["iterations"] = iterations
__props__.__dict__["key"] = key
__props__.__dict__["keytag"] = keytag
__props__.__dict__["labels"] = labels
__props__.__dict__["mailbox"] = mailbox
__props__.__dict__["match_type"] = match_type
__props__.__dict__["name"] = name
__props__.__dict__["name_server"] = name_server
__props__.__dict__["next_hashed_owner_name"] = next_hashed_owner_name
__props__.__dict__["nxdomain_ttl"] = nxdomain_ttl
__props__.__dict__["order"] = order
__props__.__dict__["original_ttl"] = original_ttl
__props__.__dict__["port"] = port
__props__.__dict__["preference"] = preference
__props__.__dict__["priority"] = priority
__props__.__dict__["priority_increment"] = priority_increment
__props__.__dict__["protocol"] = protocol
__props__.__dict__["record_sha"] = record_sha
__props__.__dict__["recordtype"] = recordtype
__props__.__dict__["refresh"] = refresh
__props__.__dict__["regexp"] = regexp
__props__.__dict__["replacement"] = replacement
__props__.__dict__["retry"] = retry
__props__.__dict__["salt"] = salt
__props__.__dict__["selector"] = selector
__props__.__dict__["serial"] = serial
__props__.__dict__["service"] = service
__props__.__dict__["signature"] = signature
__props__.__dict__["signer"] = signer
__props__.__dict__["software"] = software
__props__.__dict__["subtype"] = subtype
__props__.__dict__["svc_params"] = svc_params
__props__.__dict__["svc_priority"] = svc_priority
__props__.__dict__["target_name"] = target_name
__props__.__dict__["targets"] = targets
__props__.__dict__["ttl"] = ttl
__props__.__dict__["txt"] = txt
__props__.__dict__["type_bitmaps"] = type_bitmaps
__props__.__dict__["type_covered"] = type_covered
__props__.__dict__["type_mnemonic"] = type_mnemonic
__props__.__dict__["type_value"] = type_value
__props__.__dict__["usage"] = usage
__props__.__dict__["weight"] = weight
__props__.__dict__["zone"] = zone
return DnsRecord(resource_name, opts=opts, __props__=__props__)
@property
@pulumi.getter
def active(self) -> pulumi.Output[Optional[bool]]:
return pulumi.get(self, "active")
@property
@pulumi.getter
def algorithm(self) -> pulumi.Output[Optional[int]]:
return pulumi.get(self, "algorithm")
@property
@pulumi.getter(name="answerType")
def answer_type(self) -> pulumi.Output[str]:
return pulumi.get(self, "answer_type")
@property
@pulumi.getter
def certificate(self) -> pulumi.Output[Optional[str]]:
return pulumi.get(self, "certificate")
@property
@pulumi.getter
def digest(self) -> pulumi.Output[Optional[str]]:
return pulumi.get(self, "digest")
@property
@pulumi.getter(name="digestType")
def digest_type(self) -> pulumi.Output[Optional[int]]:
return pulumi.get(self, "digest_type")
@property
@pulumi.getter(name="dnsName")
def dns_name(self) -> pulumi.Output[str]:
return pulumi.get(self, "dns_name")
@property
@pulumi.getter(name="emailAddress")
def email_address(self) -> pulumi.Output[Optional[str]]:
return pulumi.get(self, "email_address")
@property
@pulumi.getter
def expiration(self) -> pulumi.Output[Optional[str]]:
return pulumi.get(self, "expiration")
@property
@pulumi.getter
def expiry(self) -> pulumi.Output[Optional[int]]:
return pulumi.get(self, "expiry")
@property
@pulumi.getter
def fingerprint(self) -> pulumi.Output[Optional[str]]:
return pulumi.get(self, "fingerprint")
@property
@pulumi.getter(name="fingerprintType")
def fingerprint_type(self) -> pulumi.Output[Optional[int]]:
return pulumi.get(self, "fingerprint_type")
@property
@pulumi.getter
def flags(self) -> pulumi.Output[Optional[int]]:
return pulumi.get(self, "flags")
@property
@pulumi.getter
def flagsnaptr(self) -> pulumi.Output[Optional[str]]:
return pulumi.get(self, "flagsnaptr")
@property
@pulumi.getter
def hardware(self) -> pulumi.Output[Optional[str]]:
return pulumi.get(self, "hardware")
@property
@pulumi.getter
def inception(self) -> pulumi.Output[Optional[str]]:
return pulumi.get(self, "inception")
@property
@pulumi.getter
def iterations(self) -> pulumi.Output[Optional[int]]:
return pulumi.get(self, "iterations")
@property
@pulumi.getter
def key(self) -> pulumi.Output[Optional[str]]:
return pulumi.get(self, "key")
@property
@pulumi.getter
def keytag(self) -> pulumi.Output[Optional[int]]:
return pulumi.get(self, "keytag")
@property
@pulumi.getter
def labels(self) -> pulumi.Output[Optional[int]]:
return pulumi.get(self, "labels")
@property
@pulumi.getter
def mailbox(self) -> pulumi.Output[Optional[str]]:
return pulumi.get(self, "mailbox")
@property
@pulumi.getter(name="matchType")
def match_type(self) -> pulumi.Output[Optional[int]]:
return pulumi.get(self, "match_type")
@property
@pulumi.getter
def name(self) -> pulumi.Output[str]:
return pulumi.get(self, "name")
@property
@pulumi.getter(name="nameServer")
def name_server(self) -> pulumi.Output[Optional[str]]:
return pulumi.get(self, "name_server")
@property
@pulumi.getter(name="nextHashedOwnerName")
def next_hashed_owner_name(self) -> pulumi.Output[Optional[str]]:
return pulumi.get(self, "next_hashed_owner_name")
@property
@pulumi.getter(name="nxdomainTtl")
def nxdomain_ttl(self) -> pulumi.Output[Optional[int]]:
return pulumi.get(self, "nxdomain_ttl")
@property
@pulumi.getter
def order(self) -> pulumi.Output[Optional[int]]:
return pulumi.get(self, "order")
@property
@pulumi.getter(name="originalTtl")
def original_ttl(self) -> pulumi.Output[Optional[int]]:
return pulumi.get(self, "original_ttl")
@property
@pulumi.getter
def port(self) -> pulumi.Output[Optional[int]]:
return pulumi.get(self, "port")
@property
@pulumi.getter
def preference(self) -> pulumi.Output[Optional[int]]:
return pulumi.get(self, "preference")
@property
@pulumi.getter
def priority(self) -> pulumi.Output[Optional[int]]:
return pulumi.get(self, "priority")
@property
@pulumi.getter(name="priorityIncrement")
def priority_increment(self) -> pulumi.Output[Optional[int]]:
return pulumi.get(self, "priority_increment")
@property
@pulumi.getter
def protocol(self) -> pulumi.Output[Optional[int]]:
return pulumi.get(self, "protocol")
@property
@pulumi.getter(name="recordSha")
def record_sha(self) -> pulumi.Output[str]:
return pulumi.get(self, "record_sha")
@property
@pulumi.getter
def recordtype(self) -> pulumi.Output[str]:
return pulumi.get(self, "recordtype")
@property
@pulumi.getter
def refresh(self) -> pulumi.Output[Optional[int]]:
return pulumi.get(self, "refresh")
@property
@pulumi.getter
def regexp(self) -> pulumi.Output[Optional[str]]:
return pulumi.get(self, "regexp")
@property
@pulumi.getter
def replacement(self) -> pulumi.Output[Optional[str]]:
return pulumi.get(self, "replacement")
@property
@pulumi.getter
def retry(self) -> pulumi.Output[Optional[int]]:
return pulumi.get(self, "retry")
@property
@pulumi.getter
def salt(self) -> pulumi.Output[Optional[str]]:
return pulumi.get(self, "salt")
@property
@pulumi.getter
def selector(self) -> pulumi.Output[Optional[int]]:
return pulumi.get(self, "selector")
@property
@pulumi.getter
def serial(self) -> pulumi.Output[int]:
return pulumi.get(self, "serial")
@property
@pulumi.getter
def service(self) -> pulumi.Output[Optional[str]]:
return pulumi.get(self, "service")
@property
@pulumi.getter
def signature(self) -> pulumi.Output[Optional[str]]:
return pulumi.get(self, "signature")
@property
@pulumi.getter
def signer(self) -> pulumi.Output[Optional[str]]:
return pulumi.get(self, "signer")
@property
@pulumi.getter
def software(self) -> pulumi.Output[Optional[str]]:
return pulumi.get(self, "software")
@property
@pulumi.getter
def subtype(self) -> pulumi.Output[Optional[int]]:
return pulumi.get(self, "subtype")
@property
@pulumi.getter(name="svcParams")
def svc_params(self) -> pulumi.Output[Optional[str]]:
return pulumi.get(self, "svc_params")
@property
@pulumi.getter(name="svcPriority")
def svc_priority(self) -> pulumi.Output[Optional[int]]:
return pulumi.get(self, "svc_priority")
@property
@pulumi.getter(name="targetName")
def target_name(self) -> pulumi.Output[Optional[str]]:
return pulumi.get(self, "target_name")
@property
@pulumi.getter
def targets(self) -> pulumi.Output[Optional[Sequence[str]]]:
return pulumi.get(self, "targets")
@property
@pulumi.getter
def ttl(self) -> pulumi.Output[int]:
return pulumi.get(self, "ttl")
@property
@pulumi.getter
def txt(self) -> pulumi.Output[Optional[str]]:
return pulumi.get(self, "txt")
@property
@pulumi.getter(name="typeBitmaps")
def type_bitmaps(self) -> pulumi.Output[Optional[str]]:
return pulumi.get(self, "type_bitmaps")
@property
@pulumi.getter(name="typeCovered")
def type_covered(self) -> pulumi.Output[Optional[str]]:
return pulumi.get(self, "type_covered")
@property
@pulumi.getter(name="typeMnemonic")
def type_mnemonic(self) -> pulumi.Output[Optional[str]]:
return pulumi.get(self, "type_mnemonic")
@property
@pulumi.getter(name="typeValue")
def type_value(self) -> pulumi.Output[Optional[int]]:
return pulumi.get(self, "type_value")
@property
@pulumi.getter
def usage(self) -> pulumi.Output[Optional[int]]:
return pulumi.get(self, "usage")
@property
@pulumi.getter
def weight(self) -> pulumi.Output[Optional[int]]:
return pulumi.get(self, "weight")
@property
@pulumi.getter
def zone(self) -> pulumi.Output[str]:
return pulumi.get(self, "zone")
| 37.707457 | 134 | 0.619403 | 8,885 | 78,884 | 5.262915 | 0.023973 | 0.125382 | 0.20763 | 0.121383 | 0.956395 | 0.949188 | 0.915507 | 0.903937 | 0.894934 | 0.829666 | 0 | 0.000017 | 0.251965 | 78,884 | 2,091 | 135 | 37.72549 | 0.792435 | 0.014135 | 0 | 0.909402 | 1 | 0 | 0.073951 | 0.003919 | 0 | 0 | 0 | 0 | 0 | 1 | 0.17037 | false | 0.00057 | 0.002849 | 0.100285 | 0.275783 | 0.02792 | 0 | 0 | 0 | null | 0 | 1 | 0 | 1 | 1 | 1 | 1 | 1 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 1 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | 10 |
010913d0ceb742bb7129fe1bbaeb51a8772220c1 | 91 | py | Python | simpleyt/__init__.py | VarthanV/simple-yt | 44e4ab094a4a2183ec89bdd4d378546ae9aebf52 | [
"MIT"
] | 3 | 2020-06-16T01:42:01.000Z | 2020-10-01T13:53:52.000Z | simpleyt/__init__.py | VarthanV/simple-yt | 44e4ab094a4a2183ec89bdd4d378546ae9aebf52 | [
"MIT"
] | null | null | null | simpleyt/__init__.py | VarthanV/simple-yt | 44e4ab094a4a2183ec89bdd4d378546ae9aebf52 | [
"MIT"
] | 1 | 2020-06-16T01:39:40.000Z | 2020-06-16T01:39:40.000Z | from simpleyt.youtube_api import YoutubeAPI
from simpleyt.youtube_video import YoutubeVideo | 45.5 | 47 | 0.901099 | 12 | 91 | 6.666667 | 0.666667 | 0.3 | 0.475 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0.076923 | 91 | 2 | 47 | 45.5 | 0.952381 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | true | 0 | 1 | 0 | 1 | 0 | 1 | 0 | 0 | null | 1 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 1 | 0 | 1 | 0 | 0 | 7 |
011c88dd51a9d48a13dfb68385cbc6b338727be0 | 109 | py | Python | src/fate_of_dice/system/tales_from_the_loop/__init__.py | bonczeq/FateOfDice | ce1704ac490f55bc600c0963958d4175104e85e5 | [
"MIT"
] | null | null | null | src/fate_of_dice/system/tales_from_the_loop/__init__.py | bonczeq/FateOfDice | ce1704ac490f55bc600c0963958d4175104e85e5 | [
"MIT"
] | null | null | null | src/fate_of_dice/system/tales_from_the_loop/__init__.py | bonczeq/FateOfDice | ce1704ac490f55bc600c0963958d4175104e85e5 | [
"MIT"
] | null | null | null | from .overcome_trouble_check import overcome_trouble_check, OvercomeTroubleResult, OvercomeTroubleResultType
| 54.5 | 108 | 0.917431 | 10 | 109 | 9.6 | 0.7 | 0.3125 | 0.416667 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0.055046 | 109 | 1 | 109 | 109 | 0.932039 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | true | 0 | 1 | 0 | 1 | 0 | 1 | 0 | 0 | null | 1 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 1 | 0 | 1 | 0 | 0 | 8 |
0126d9ae21fd09c2506623ae361b7cca2ce2b87e | 45,590 | py | Python | scripts/exploratory_Fall2012/DrawCharts.py | eclee25/flu-SDI-exploratory-age | 2f5a4d97b84d2116e179e85fe334edf4556aa946 | [
"MIT"
] | 3 | 2018-03-29T23:02:43.000Z | 2020-08-10T12:01:50.000Z | scripts/exploratory_Fall2012/DrawCharts.py | eclee25/flu-SDI-exploratory-age | 2f5a4d97b84d2116e179e85fe334edf4556aa946 | [
"MIT"
] | null | null | null | scripts/exploratory_Fall2012/DrawCharts.py | eclee25/flu-SDI-exploratory-age | 2f5a4d97b84d2116e179e85fe334edf4556aa946 | [
"MIT"
] | null | null | null | #!/usr/bin/python
##############################################
###Python template
###Author: Elizabeth Lee
###Date: 10/10/12
###Function: Draw exploratory charts for SDI data
###Import data: A1, A2, A3, B3, C1, C2, C3
###Command Line: ipython DrawCharts.py
##############################################
### notes ###
# can't read the same file multiple times in one program
# python closing index values are one greater than the actual index
### packages ###
import matplotlib
import csv
import numpy as np
import matplotlib.pyplot as plt
from pylab import *
## local packages ##
### data structures ###
yr=[]
wknum=[]
mag=[]
x01=[]
y01=[]
x02=[]
y02=[]
x03=[]
y03=[]
x04=[]
y04=[]
x05=[]
y05=[]
x06=[]
y06=[]
x07=[]
y07=[]
x08=[]
y08=[]
x09=[]
y09=[]
x=[]
y2yr=[]
y2_4yr=[]
y5_19yr=[]
y20_29yr=[]
y30_49yr=[]
y50_69yr=[]
y70yr=[]
wks_by_season=[]
peak=[]
weeks=[]
peakwk=[]
peakwk_shifted=[]
### parameters ###
#for single season charts
nextyr=np.arange(1,40,1)
firstyr=np.arange(40,54,1)
yr1 = '2001'
yr2 = '2002'
season = yr1+'-'+yr2
#for peak week charts
s_peak=0
s_wk=0
s_numshift=0
s_num=0
yax=[]
agelabel = ['<2 years', '2-4 years', '5-19 years', '20-29 years', '30-49 years', '50-69 years', '70+ years']
yr1vec = [2001,2002,2003,2004,2005,2006,2007,2008,2009]
yr2vec = [2002,2003,2004,2005,2006,2007,2008,2009,2010]
### functions ###
def G4season (csvreadfile, agevec):
for row in csvreadfile:
yr = row[2][:4]
wknum = int(row[3])
month = row[2][5:7]
if yr == yr1 and wknum in firstyr and month != "01":
agevec.append(row[6])
wks_by_season.append(wknum)
weeks.append(row[2])
elif yr == yr2 and wknum in nextyr:
agevec.append(row[6])
wks_by_season.append(wknum)
weeks.append(row[2])
else:
continue
def peakweek (csvreadfile, peakval, wkval, numval, peakwkval, yearct): # week numbers for peaks do not appear to be correct,
ct=0
for row in csvreadfile:
yr = int(row[2][:4])
wknum = int(row[3])
month = row[2][5:7]
null = float(row[6])
if ((yr==yr1vec[yearct] and wknum in firstyr and month != "01") or (yr==yr2vec[yearct] and wknum in nextyr)):
ct+=1
if null>peakval:
peakval=float(row[6])
wkval=row[2]
numval=ct
peakwkval=int(row[3])
peak.append(peakval)
weeks.append(wkval)
peakwk_shifted.append(numval)
peakwk.append(peakwkval) #not needed for plotting, just as a check
def season_grabaxes (csvreadfile): #2001 and 2002 have 52 weeks
ct=0
for row in csvreadfile:
yr = row[2][:4]
wknum = int(row[3])
month = row[2][5:7]
if ((yr=='2001' and wknum in firstyr and month != "01") or (yr=='2002' and wknum in nextyr)):
ct += 1
yax.append(ct)
wks_by_season.append(wknum)
### import data ###
A1in=open('/home/elizabeth/Documents/Georgetown/Bansal/SDI/SQL_export/A1.csv','r')
A2in=open('/home/elizabeth/Documents/Georgetown/Bansal/SDI/SQL_export/A2.csv','r')
A3in=open('/home/elizabeth/Documents/Georgetown/Bansal/SDI/SQL_export/A3.csv','r')
B3in=A3in=open('/home/elizabeth/Documents/Georgetown/Bansal/SDI/SQL_export/B3.csv','r')
C1in=open('/home/elizabeth/Documents/Georgetown/Bansal/SDI/R_export/C1.csv','r')
C2in=open('/home/elizabeth/Documents/Georgetown/Bansal/SDI/R_export/C2.csv','r')
C3in=open('/home/elizabeth/Documents/Georgetown/Bansal/SDI/R_export/C3.csv','r')
D1ain=open('/home/elizabeth/Documents/Georgetown/Bansal/SDI/SQL_export/D1a.csv','r')
D1cin=open('/home/elizabeth/Documents/Georgetown/Bansal/SDI/SQL_export/D1c.csv','r')
D1din=open('/home/elizabeth/Documents/Georgetown/Bansal/SDI/SQL_export/D1d.csv','r')
D1fin=open('/home/elizabeth/Documents/Georgetown/Bansal/SDI/SQL_export/D1f.csv','r')
E1cin=open('/home/elizabeth/Documents/Georgetown/Bansal/SDI/SQL_export/E1c.csv','r')
E1fin=open('/home/elizabeth/Documents/Georgetown/Bansal/SDI/SQL_export/E1f.csv','r')
E4ain=open('/home/elizabeth/Documents/Georgetown/Bansal/SDI/SQL_export/E4a.csv','r')
E4bin=open('/home/elizabeth/Documents/Georgetown/Bansal/SDI/SQL_export/E4b.csv','r')
E4cin=open('/home/elizabeth/Documents/Georgetown/Bansal/SDI/SQL_export/E4c.csv','r')
E4din=open('/home/elizabeth/Documents/Georgetown/Bansal/SDI/SQL_export/E4d.csv','r')
E4ein=open('/home/elizabeth/Documents/Georgetown/Bansal/SDI/SQL_export/E4e.csv','r')
E4fin=open('/home/elizabeth/Documents/Georgetown/Bansal/SDI/SQL_export/E4f.csv','r')
E4gin=open('/home/elizabeth/Documents/Georgetown/Bansal/SDI/SQL_export/E4g.csv','r')
D4ain=open('/home/elizabeth/Documents/Georgetown/Bansal/SDI/SQL_export/D4a.csv','r')
D4bin=open('/home/elizabeth/Documents/Georgetown/Bansal/SDI/SQL_export/D4b.csv','r')
D4cin=open('/home/elizabeth/Documents/Georgetown/Bansal/SDI/SQL_export/D4c.csv','r')
D4din=open('/home/elizabeth/Documents/Georgetown/Bansal/SDI/SQL_export/D4d.csv','r')
D4ein=open('/home/elizabeth/Documents/Georgetown/Bansal/SDI/SQL_export/D4e.csv','r')
D4fin=open('/home/elizabeth/Documents/Georgetown/Bansal/SDI/SQL_export/D4f.csv','r')
D4gin=open('/home/elizabeth/Documents/Georgetown/Bansal/SDI/SQL_export/D4g.csv','r')
G4ain=open('/home/elizabeth/Documents/Georgetown/Bansal/SDI/SQL_export/G4a.csv','r')
G4bin=open('/home/elizabeth/Documents/Georgetown/Bansal/SDI/SQL_export/G4b.csv','r')
G4cin=open('/home/elizabeth/Documents/Georgetown/Bansal/SDI/SQL_export/G4c.csv','r')
G4din=open('/home/elizabeth/Documents/Georgetown/Bansal/SDI/SQL_export/G4d.csv','r')
G4ein=open('/home/elizabeth/Documents/Georgetown/Bansal/SDI/SQL_export/G4e.csv','r')
G4fin=open('/home/elizabeth/Documents/Georgetown/Bansal/SDI/SQL_export/G4f.csv','r')
G4gin=open('/home/elizabeth/Documents/Georgetown/Bansal/SDI/SQL_export/G4g.csv','r')
E4ain_2=open('/home/elizabeth/Documents/Georgetown/Bansal/SDI/SQL_export/E4a.csv','r')
E4bin_2=open('/home/elizabeth/Documents/Georgetown/Bansal/SDI/SQL_export/E4b.csv','r')
E4cin_2=open('/home/elizabeth/Documents/Georgetown/Bansal/SDI/SQL_export/E4c.csv','r')
E4din_2=open('/home/elizabeth/Documents/Georgetown/Bansal/SDI/SQL_export/E4d.csv','r')
E4ein_2=open('/home/elizabeth/Documents/Georgetown/Bansal/SDI/SQL_export/E4e.csv','r')
E4fin_2=open('/home/elizabeth/Documents/Georgetown/Bansal/SDI/SQL_export/E4f.csv','r')
E4gin_2=open('/home/elizabeth/Documents/Georgetown/Bansal/SDI/SQL_export/E4g.csv','r')
E4ain_3=open('/home/elizabeth/Documents/Georgetown/Bansal/SDI/SQL_export/E4a.csv','r')
E4bin_3=open('/home/elizabeth/Documents/Georgetown/Bansal/SDI/SQL_export/E4b.csv','r')
E4cin_3=open('/home/elizabeth/Documents/Georgetown/Bansal/SDI/SQL_export/E4c.csv','r')
E4din_3=open('/home/elizabeth/Documents/Georgetown/Bansal/SDI/SQL_export/E4d.csv','r')
E4ein_3=open('/home/elizabeth/Documents/Georgetown/Bansal/SDI/SQL_export/E4e.csv','r')
E4fin_3=open('/home/elizabeth/Documents/Georgetown/Bansal/SDI/SQL_export/E4f.csv','r')
E4gin_3=open('/home/elizabeth/Documents/Georgetown/Bansal/SDI/SQL_export/E4g.csv','r')
E4ain_4=open('/home/elizabeth/Documents/Georgetown/Bansal/SDI/SQL_export/E4a.csv','r')
E4bin_4=open('/home/elizabeth/Documents/Georgetown/Bansal/SDI/SQL_export/E4b.csv','r')
E4cin_4=open('/home/elizabeth/Documents/Georgetown/Bansal/SDI/SQL_export/E4c.csv','r')
E4din_4=open('/home/elizabeth/Documents/Georgetown/Bansal/SDI/SQL_export/E4d.csv','r')
E4ein_4=open('/home/elizabeth/Documents/Georgetown/Bansal/SDI/SQL_export/E4e.csv','r')
E4fin_4=open('/home/elizabeth/Documents/Georgetown/Bansal/SDI/SQL_export/E4f.csv','r')
E4gin_4=open('/home/elizabeth/Documents/Georgetown/Bansal/SDI/SQL_export/E4g.csv','r')
E4ain_5=open('/home/elizabeth/Documents/Georgetown/Bansal/SDI/SQL_export/E4a.csv','r')
E4bin_5=open('/home/elizabeth/Documents/Georgetown/Bansal/SDI/SQL_export/E4b.csv','r')
E4cin_5=open('/home/elizabeth/Documents/Georgetown/Bansal/SDI/SQL_export/E4c.csv','r')
E4din_5=open('/home/elizabeth/Documents/Georgetown/Bansal/SDI/SQL_export/E4d.csv','r')
E4ein_5=open('/home/elizabeth/Documents/Georgetown/Bansal/SDI/SQL_export/E4e.csv','r')
E4fin_5=open('/home/elizabeth/Documents/Georgetown/Bansal/SDI/SQL_export/E4f.csv','r')
E4gin_5=open('/home/elizabeth/Documents/Georgetown/Bansal/SDI/SQL_export/E4g.csv','r')
E4ain_6=open('/home/elizabeth/Documents/Georgetown/Bansal/SDI/SQL_export/E4a.csv','r')
E4bin_6=open('/home/elizabeth/Documents/Georgetown/Bansal/SDI/SQL_export/E4b.csv','r')
E4cin_6=open('/home/elizabeth/Documents/Georgetown/Bansal/SDI/SQL_export/E4c.csv','r')
E4din_6=open('/home/elizabeth/Documents/Georgetown/Bansal/SDI/SQL_export/E4d.csv','r')
E4ein_6=open('/home/elizabeth/Documents/Georgetown/Bansal/SDI/SQL_export/E4e.csv','r')
E4fin_6=open('/home/elizabeth/Documents/Georgetown/Bansal/SDI/SQL_export/E4f.csv','r')
E4gin_6=open('/home/elizabeth/Documents/Georgetown/Bansal/SDI/SQL_export/E4g.csv','r')
E4ain_7=open('/home/elizabeth/Documents/Georgetown/Bansal/SDI/SQL_export/E4a.csv','r')
E4bin_7=open('/home/elizabeth/Documents/Georgetown/Bansal/SDI/SQL_export/E4b.csv','r')
E4cin_7=open('/home/elizabeth/Documents/Georgetown/Bansal/SDI/SQL_export/E4c.csv','r')
E4din_7=open('/home/elizabeth/Documents/Georgetown/Bansal/SDI/SQL_export/E4d.csv','r')
E4ein_7=open('/home/elizabeth/Documents/Georgetown/Bansal/SDI/SQL_export/E4e.csv','r')
E4fin_7=open('/home/elizabeth/Documents/Georgetown/Bansal/SDI/SQL_export/E4f.csv','r')
E4gin_7=open('/home/elizabeth/Documents/Georgetown/Bansal/SDI/SQL_export/E4g.csv','r')
E4ain_8=open('/home/elizabeth/Documents/Georgetown/Bansal/SDI/SQL_export/E4a.csv','r')
E4bin_8=open('/home/elizabeth/Documents/Georgetown/Bansal/SDI/SQL_export/E4b.csv','r')
E4cin_8=open('/home/elizabeth/Documents/Georgetown/Bansal/SDI/SQL_export/E4c.csv','r')
E4din_8=open('/home/elizabeth/Documents/Georgetown/Bansal/SDI/SQL_export/E4d.csv','r')
E4ein_8=open('/home/elizabeth/Documents/Georgetown/Bansal/SDI/SQL_export/E4e.csv','r')
E4fin_8=open('/home/elizabeth/Documents/Georgetown/Bansal/SDI/SQL_export/E4f.csv','r')
E4gin_8=open('/home/elizabeth/Documents/Georgetown/Bansal/SDI/SQL_export/E4g.csv','r')
G4ain_2=open('/home/elizabeth/Documents/Georgetown/Bansal/SDI/SQL_export/G4a.csv','r')
G4bin_2=open('/home/elizabeth/Documents/Georgetown/Bansal/SDI/SQL_export/G4b.csv','r')
G4cin_2=open('/home/elizabeth/Documents/Georgetown/Bansal/SDI/SQL_export/G4c.csv','r')
G4din_2=open('/home/elizabeth/Documents/Georgetown/Bansal/SDI/SQL_export/G4d.csv','r')
G4ein_2=open('/home/elizabeth/Documents/Georgetown/Bansal/SDI/SQL_export/G4e.csv','r')
G4fin_2=open('/home/elizabeth/Documents/Georgetown/Bansal/SDI/SQL_export/G4f.csv','r')
G4gin_2=open('/home/elizabeth/Documents/Georgetown/Bansal/SDI/SQL_export/G4g.csv','r')
G4ain_3=open('/home/elizabeth/Documents/Georgetown/Bansal/SDI/SQL_export/G4a.csv','r')
G4bin_3=open('/home/elizabeth/Documents/Georgetown/Bansal/SDI/SQL_export/G4b.csv','r')
G4cin_3=open('/home/elizabeth/Documents/Georgetown/Bansal/SDI/SQL_export/G4c.csv','r')
G4din_3=open('/home/elizabeth/Documents/Georgetown/Bansal/SDI/SQL_export/G4d.csv','r')
G4ein_3=open('/home/elizabeth/Documents/Georgetown/Bansal/SDI/SQL_export/G4e.csv','r')
G4fin_3=open('/home/elizabeth/Documents/Georgetown/Bansal/SDI/SQL_export/G4f.csv','r')
G4gin_3=open('/home/elizabeth/Documents/Georgetown/Bansal/SDI/SQL_export/G4g.csv','r')
G4ain_4=open('/home/elizabeth/Documents/Georgetown/Bansal/SDI/SQL_export/G4a.csv','r')
G4bin_4=open('/home/elizabeth/Documents/Georgetown/Bansal/SDI/SQL_export/G4b.csv','r')
G4cin_4=open('/home/elizabeth/Documents/Georgetown/Bansal/SDI/SQL_export/G4c.csv','r')
G4din_4=open('/home/elizabeth/Documents/Georgetown/Bansal/SDI/SQL_export/G4d.csv','r')
G4ein_4=open('/home/elizabeth/Documents/Georgetown/Bansal/SDI/SQL_export/G4e.csv','r')
G4fin_4=open('/home/elizabeth/Documents/Georgetown/Bansal/SDI/SQL_export/G4f.csv','r')
G4gin_4=open('/home/elizabeth/Documents/Georgetown/Bansal/SDI/SQL_export/G4g.csv','r')
G4ain_5=open('/home/elizabeth/Documents/Georgetown/Bansal/SDI/SQL_export/G4a.csv','r')
G4bin_5=open('/home/elizabeth/Documents/Georgetown/Bansal/SDI/SQL_export/G4b.csv','r')
G4cin_5=open('/home/elizabeth/Documents/Georgetown/Bansal/SDI/SQL_export/G4c.csv','r')
G4din_5=open('/home/elizabeth/Documents/Georgetown/Bansal/SDI/SQL_export/G4d.csv','r')
G4ein_5=open('/home/elizabeth/Documents/Georgetown/Bansal/SDI/SQL_export/G4e.csv','r')
G4fin_5=open('/home/elizabeth/Documents/Georgetown/Bansal/SDI/SQL_export/G4f.csv','r')
G4gin_5=open('/home/elizabeth/Documents/Georgetown/Bansal/SDI/SQL_export/G4g.csv','r')
G4ain_6=open('/home/elizabeth/Documents/Georgetown/Bansal/SDI/SQL_export/G4a.csv','r')
G4bin_6=open('/home/elizabeth/Documents/Georgetown/Bansal/SDI/SQL_export/G4b.csv','r')
G4cin_6=open('/home/elizabeth/Documents/Georgetown/Bansal/SDI/SQL_export/G4c.csv','r')
G4din_6=open('/home/elizabeth/Documents/Georgetown/Bansal/SDI/SQL_export/G4d.csv','r')
G4ein_6=open('/home/elizabeth/Documents/Georgetown/Bansal/SDI/SQL_export/G4e.csv','r')
G4fin_6=open('/home/elizabeth/Documents/Georgetown/Bansal/SDI/SQL_export/G4f.csv','r')
G4gin_6=open('/home/elizabeth/Documents/Georgetown/Bansal/SDI/SQL_export/G4g.csv','r')
G4ain_7=open('/home/elizabeth/Documents/Georgetown/Bansal/SDI/SQL_export/G4a.csv','r')
G4bin_7=open('/home/elizabeth/Documents/Georgetown/Bansal/SDI/SQL_export/G4b.csv','r')
G4cin_7=open('/home/elizabeth/Documents/Georgetown/Bansal/SDI/SQL_export/G4c.csv','r')
G4din_7=open('/home/elizabeth/Documents/Georgetown/Bansal/SDI/SQL_export/G4d.csv','r')
G4ein_7=open('/home/elizabeth/Documents/Georgetown/Bansal/SDI/SQL_export/G4e.csv','r')
G4fin_7=open('/home/elizabeth/Documents/Georgetown/Bansal/SDI/SQL_export/G4f.csv','r')
G4gin_7=open('/home/elizabeth/Documents/Georgetown/Bansal/SDI/SQL_export/G4g.csv','r')
G4ain_8=open('/home/elizabeth/Documents/Georgetown/Bansal/SDI/SQL_export/G4a.csv','r')
G4bin_8=open('/home/elizabeth/Documents/Georgetown/Bansal/SDI/SQL_export/G4b.csv','r')
G4cin_8=open('/home/elizabeth/Documents/Georgetown/Bansal/SDI/SQL_export/G4c.csv','r')
G4din_8=open('/home/elizabeth/Documents/Georgetown/Bansal/SDI/SQL_export/G4d.csv','r')
G4ein_8=open('/home/elizabeth/Documents/Georgetown/Bansal/SDI/SQL_export/G4e.csv','r')
G4fin_8=open('/home/elizabeth/Documents/Georgetown/Bansal/SDI/SQL_export/G4f.csv','r')
G4gin_8=open('/home/elizabeth/Documents/Georgetown/Bansal/SDI/SQL_export/G4g.csv','r')
A1=csv.reader(A1in, delimiter=',')
A2=csv.reader(A2in, delimiter=',')
A3=csv.reader(A3in, delimiter=',')
B3=csv.reader(B3in, delimiter=',')
C1=csv.reader(C1in, delimiter=',')
C2=csv.reader(C2in, delimiter=',')
C3=csv.reader(C3in, delimiter=',')
D1a=csv.reader(D1ain, delimiter=',')
D1c=csv.reader(D1cin, delimiter=',')
D1d=csv.reader(D1din, delimiter=',')
D1f=csv.reader(D1fin, delimiter=',')
E1c=csv.reader(E1cin, delimiter=',')
E1f=csv.reader(E1fin, delimiter=',')
E4a=csv.reader(E4ain, delimiter=',')
E4b=csv.reader(E4bin, delimiter=',')
E4c=csv.reader(E4cin, delimiter=',')
E4d=csv.reader(E4din, delimiter=',')
E4e=csv.reader(E4ein, delimiter=',')
E4f=csv.reader(E4fin, delimiter=',')
E4g=csv.reader(E4gin, delimiter=',')
D4a=csv.reader(D4ain, delimiter=',')
D4b=csv.reader(D4bin, delimiter=',')
D4c=csv.reader(D4cin, delimiter=',')
D4d=csv.reader(D4din, delimiter=',')
D4e=csv.reader(D4ein, delimiter=',')
D4f=csv.reader(D4fin, delimiter=',')
D4g=csv.reader(D4gin, delimiter=',')
G4a=csv.reader(G4ain, delimiter=',')
G4b=csv.reader(G4bin, delimiter=',')
G4c=csv.reader(G4cin, delimiter=',')
G4d=csv.reader(G4din, delimiter=',')
G4e=csv.reader(G4ein, delimiter=',')
G4f=csv.reader(G4fin, delimiter=',')
G4g=csv.reader(G4gin, delimiter=',')
E4a_2=csv.reader(E4ain_2, delimiter=',')
E4b_2=csv.reader(E4bin_2, delimiter=',')
E4c_2=csv.reader(E4cin_2, delimiter=',')
E4d_2=csv.reader(E4din_2, delimiter=',')
E4e_2=csv.reader(E4ein_2, delimiter=',')
E4f_2=csv.reader(E4fin_2, delimiter=',')
E4g_2=csv.reader(E4gin_2, delimiter=',')
E4a_3=csv.reader(E4ain_3, delimiter=',')
E4b_3=csv.reader(E4bin_3, delimiter=',')
E4c_3=csv.reader(E4cin_3, delimiter=',')
E4d_3=csv.reader(E4din_3, delimiter=',')
E4e_3=csv.reader(E4ein_3, delimiter=',')
E4f_3=csv.reader(E4fin_3, delimiter=',')
E4g_3=csv.reader(E4gin_3, delimiter=',')
E4a_4=csv.reader(E4ain_4, delimiter=',')
E4b_4=csv.reader(E4bin_4, delimiter=',')
E4c_4=csv.reader(E4cin_4, delimiter=',')
E4d_4=csv.reader(E4din_4, delimiter=',')
E4e_4=csv.reader(E4ein_4, delimiter=',')
E4f_4=csv.reader(E4fin_4, delimiter=',')
E4g_4=csv.reader(E4gin_4, delimiter=',')
E4a_5=csv.reader(E4ain_5, delimiter=',')
E4b_5=csv.reader(E4bin_5, delimiter=',')
E4c_5=csv.reader(E4cin_5, delimiter=',')
E4d_5=csv.reader(E4din_5, delimiter=',')
E4e_5=csv.reader(E4ein_5, delimiter=',')
E4f_5=csv.reader(E4fin_5, delimiter=',')
E4g_5=csv.reader(E4gin_5, delimiter=',')
E4a_6=csv.reader(E4ain_6, delimiter=',')
E4b_6=csv.reader(E4bin_6, delimiter=',')
E4c_6=csv.reader(E4cin_6, delimiter=',')
E4d_6=csv.reader(E4din_6, delimiter=',')
E4e_6=csv.reader(E4ein_6, delimiter=',')
E4f_6=csv.reader(E4fin_6, delimiter=',')
E4g_6=csv.reader(E4gin_6, delimiter=',')
E4a_7=csv.reader(E4ain_7, delimiter=',')
E4b_7=csv.reader(E4bin_7, delimiter=',')
E4c_7=csv.reader(E4cin_7, delimiter=',')
E4d_7=csv.reader(E4din_7, delimiter=',')
E4e_7=csv.reader(E4ein_7, delimiter=',')
E4f_7=csv.reader(E4fin_7, delimiter=',')
E4g_7=csv.reader(E4gin_7, delimiter=',')
E4a_8=csv.reader(E4ain_8, delimiter=',')
E4b_8=csv.reader(E4bin_8, delimiter=',')
E4c_8=csv.reader(E4cin_8, delimiter=',')
E4d_8=csv.reader(E4din_8, delimiter=',')
E4e_8=csv.reader(E4ein_8, delimiter=',')
E4f_8=csv.reader(E4fin_8, delimiter=',')
E4g_8=csv.reader(E4gin_8, delimiter=',')
G4a_2=csv.reader(G4ain_2, delimiter=',')
G4b_2=csv.reader(G4bin_2, delimiter=',')
G4c_2=csv.reader(G4cin_2, delimiter=',')
G4d_2=csv.reader(G4din_2, delimiter=',')
G4e_2=csv.reader(G4ein_2, delimiter=',')
G4f_2=csv.reader(G4fin_2, delimiter=',')
G4g_2=csv.reader(G4gin_2, delimiter=',')
G4a_3=csv.reader(G4ain_3, delimiter=',')
G4b_3=csv.reader(G4bin_3, delimiter=',')
G4c_3=csv.reader(G4cin_3, delimiter=',')
G4d_3=csv.reader(G4din_3, delimiter=',')
G4e_3=csv.reader(G4ein_3, delimiter=',')
G4f_3=csv.reader(G4fin_3, delimiter=',')
G4g_3=csv.reader(G4gin_3, delimiter=',')
G4a_4=csv.reader(G4ain_4, delimiter=',')
G4b_4=csv.reader(G4bin_4, delimiter=',')
G4c_4=csv.reader(G4cin_4, delimiter=',')
G4d_4=csv.reader(G4din_4, delimiter=',')
G4e_4=csv.reader(G4ein_4, delimiter=',')
G4f_4=csv.reader(G4fin_4, delimiter=',')
G4g_4=csv.reader(G4gin_4, delimiter=',')
G4a_5=csv.reader(G4ain_5, delimiter=',')
G4b_5=csv.reader(G4bin_5, delimiter=',')
G4c_5=csv.reader(G4cin_5, delimiter=',')
G4d_5=csv.reader(G4din_5, delimiter=',')
G4e_5=csv.reader(G4ein_5, delimiter=',')
G4f_5=csv.reader(G4fin_5, delimiter=',')
G4g_5=csv.reader(G4gin_5, delimiter=',')
G4a_6=csv.reader(G4ain_6, delimiter=',')
G4b_6=csv.reader(G4bin_6, delimiter=',')
G4c_6=csv.reader(G4cin_6, delimiter=',')
G4d_6=csv.reader(G4din_6, delimiter=',')
G4e_6=csv.reader(G4ein_6, delimiter=',')
G4f_6=csv.reader(G4fin_6, delimiter=',')
G4g_6=csv.reader(G4gin_6, delimiter=',')
G4a_7=csv.reader(G4ain_7, delimiter=',')
G4b_7=csv.reader(G4bin_7, delimiter=',')
G4c_7=csv.reader(G4cin_7, delimiter=',')
G4d_7=csv.reader(G4din_7, delimiter=',')
G4e_7=csv.reader(G4ein_7, delimiter=',')
G4f_7=csv.reader(G4fin_7, delimiter=',')
G4g_7=csv.reader(G4gin_7, delimiter=',')
G4a_8=csv.reader(G4ain_8, delimiter=',')
G4b_8=csv.reader(G4bin_8, delimiter=',')
G4c_8=csv.reader(G4cin_8, delimiter=',')
G4d_8=csv.reader(G4din_8, delimiter=',')
G4e_8=csv.reader(G4ein_8, delimiter=',')
G4f_8=csv.reader(G4fin_8, delimiter=',')
G4g_8=csv.reader(G4gin_8, delimiter=',')
### program ###
#for row in A1:
# x = np.arange(2000,2011,1)
# y = row[2:]
# plt.plot(x,y,label=row[1])
#plt.legend(loc=2)
#plt.ylabel('Number of ILI cases')
#plt.show()
#for row in A2:
# x = np.arange(2000,2011,1)
# y = row[2:]
# plt.plot(x,y,label=row[1])
#plt.legend(loc=2)
#plt.ylabel('Number of total visits')
#plt.show()
#for row in A3:
# x = np.arange(2000,2011,1)
# y = row[2:]
# plt.plot(x,y,label=row[1])
#plt.legend(loc=2)
#plt.ylabel('Proportion of ILI cases from total visits')
#plt.axis([2000,2010,0,0.1])
#plt.show()
#for row in B3:
# yr.append(int(row[1]))
# wknum.append(int(row[3]))
# mag.append(float(row[4]))
#mag2 = array(mag)*5000
#scatter(yr,wknum,marker = 'o',s=mag2)
#plt.ylabel('Week Number')
#plt.xlabel('Year')
#plt.text(1999,30,'Week 1-11: Winter\nWeek 12-24: Spring\nWeek 25-37: Summer\nWeek 38-50: Fall\nWeek 51-52: Winter')
#plt.text(1999,-7,'Peak season is defined as ILI proportion > .02 for 10-14 year olds')
#plt.show()
#ct=0
#dates=[]
#for row in C1:
# if ct==0:
# dates=row[1:]
# ct+=1
# continue
# if row[1]=='NA':
# row[1]=0
# x = np.arange(0,496,1)
# y = row[1:]
# plt.plot(x,y,label=row[0])
# ct+=1
#plt.legend(loc=2)
#plt.ylabel('Number of ILI cases')
#plt.show()
#ct=0
#dates=[]
#for row in C2:
# if ct==0:
# dates=row[1:]
# ct+=1
# continue
# if row[1]=='NA':
# row[1]=0
# x = np.arange(0,496,1)
# y = row[1:]
# plt.plot(x,y,label=row[0])
# ct+=1
#plt.legend(loc=2)
#plt.ylabel('Number of total visits')
#plt.show()
#ct=0
#dates=[]
#for row in C3:
# if ct==0:
# dates=row[1:]
# ct+=1
# continue
# if row[1]=='NA':
# row[1]=0
# x = np.arange(0,496,1)
# y = row[1:]
# plt.plot(x,y,label=row[0])
# ct+=1
#plt.legend(loc=2)
#plt.ylabel('Proportion of ILI cases from total visits')
#plt.show()
#for row in D1a:
# yr = row[2][:4]
# if yr == "2000" or yr == "2010":
# continue
# if yr == '2001':
# x01.append(row[3])
# y01.append(row[4])
# elif yr == '2002':
# x02.append(row[3])
# y02.append(row[4])
# elif yr == '2003':
# x03.append(row[3])
# y03.append(row[4])
# elif yr == '2004':
# x04.append(row[3])
# y04.append(row[4])
# elif yr == '2005' and row[3]=='53':
# x04.append(row[3])
# y04.append(row[4])
# elif yr == '2005' and row[3]<'53':
# x05.append(row[3])
# y05.append(row[4])
# elif yr == '2006' and row[3]=='52':
# x05.append(row[3])
# y05.append(row[4])
# elif yr == '2006' and row[3]<'52':
# x06.append(row[3])
# y06.append(row[4])
# elif yr == '2007':
# x07.append(row[3])
# y07.append(row[4])
# elif yr == '2008':
# x08.append(row[3])
# y08.append(row[4])
# elif yr == '2009':
# x09.append(row[3])
# y09.append(row[4])
#plt.plot(x01,y01, label = '2001')
#plt.plot(x02,y02, label = '2002')
#plt.plot(x03,y03, label = '2003')
#plt.plot(x04,y04, label = '2004')
#plt.plot(x05,y05, label = '2005')
#plt.plot(x06,y06, label = '2006')
#plt.plot(x07,y07, label = '2007')
#plt.plot(x08,y08, label = '2008')
#plt.plot(x09,y09, label = '2009')
#plt.legend(loc=2)
#plt.xlim(xmax=55)
#plt.ylabel('Number of ER ILI cases, ages <2')
#plt.xlabel('Week Number')
#plt.show()
#for row in D1c:
# yr = row[2][:4]
# if yr == "2000" or yr == "2010":
# continue
# if yr == '2001':
# x01.append(row[3])
# y01.append(row[4])
# elif yr == '2002':
# x02.append(row[3])
# y02.append(row[4])
# elif yr == '2003':
# x03.append(row[3])
# y03.append(row[4])
# elif yr == '2004':
# x04.append(row[3])
# y04.append(row[4])
# elif yr == '2005' and row[3]=='53':
# x04.append(row[3])
# y04.append(row[4])
# elif yr == '2005' and row[3]<'53':
# x05.append(row[3])
# y05.append(row[4])
# elif yr == '2006' and row[3]=='52':
# x05.append(row[3])
# y05.append(row[4])
# elif yr == '2006' and row[3]<'52':
# x06.append(row[3])
# y06.append(row[4])
# elif yr == '2007':
# x07.append(row[3])
# y07.append(row[4])
# elif yr == '2008':
# x08.append(row[3])
# y08.append(row[4])
# elif yr == '2009':
# x09.append(row[3])
# y09.append(row[4])
#plt.plot(x01,y01, label = '2001')
#plt.plot(x02,y02, label = '2002')
#plt.plot(x03,y03, label = '2003')
#plt.plot(x04,y04, label = '2004')
#plt.plot(x05,y05, label = '2005')
#plt.plot(x06,y06, label = '2006')
#plt.plot(x07,y07, label = '2007')
#plt.plot(x08,y08, label = '2008')
#plt.plot(x09,y09, label = '2009')
#plt.legend(loc=2)
#plt.xlim(xmax=55)
#plt.ylabel('Number of ER ILI cases, ages 5-19')
#plt.xlabel('Week Number')
#plt.show()
#for row in D1d:
# yr = row[2][:4]
# if yr == "2000" or yr == "2010":
# continue
# if yr == '2001':
# x01.append(row[3])
# y01.append(row[4])
# elif yr == '2002':
# x02.append(row[3])
# y02.append(row[4])
# elif yr == '2003':
# x03.append(row[3])
# y03.append(row[4])
# elif yr == '2004':
# x04.append(row[3])
# y04.append(row[4])
# elif yr == '2005' and row[3]=='53':
# x04.append(row[3])
# y04.append(row[4])
# elif yr == '2005' and row[3]<'53':
# x05.append(row[3])
# y05.append(row[4])
# elif yr == '2006' and row[3]=='52':
# x05.append(row[3])
# y05.append(row[4])
# elif yr == '2006' and row[3]<'52':
# x06.append(row[3])
# y06.append(row[4])
# elif yr == '2007':
# x07.append(row[3])
# y07.append(row[4])
# elif yr == '2008':
# x08.append(row[3])
# y08.append(row[4])
# elif yr == '2009':
# x09.append(row[3])
# y09.append(row[4])
#plt.plot(x01,y01, label = '2001')
#plt.plot(x02,y02, label = '2002')
#plt.plot(x03,y03, label = '2003')
#plt.plot(x04,y04, label = '2004')
#plt.plot(x05,y05, label = '2005')
#plt.plot(x06,y06, label = '2006')
#plt.plot(x07,y07, label = '2007')
#plt.plot(x08,y08, label = '2008')
#plt.plot(x09,y09, label = '2009')
#plt.legend(loc=2)
#plt.xlim(xmax=55)
#plt.ylabel('Number of ER ILI cases, ages 20-29')
#plt.xlabel('Week Number')
#plt.show()
#for row in D1f:
# yr = row[2][:4]
# if yr == "2000" or yr == "2010":
# continue
# if yr == '2001':
# x01.append(row[3])
# y01.append(row[4])
# elif yr == '2002':
# x02.append(row[3])
# y02.append(row[4])
# elif yr == '2003':
# x03.append(row[3])
# y03.append(row[4])
# elif yr == '2004':
# x04.append(row[3])
# y04.append(row[4])
# elif yr == '2005' and row[3]=='53':
# x04.append(row[3])
# y04.append(row[4])
# elif yr == '2005' and row[3]<'53':
# x05.append(row[3])
# y05.append(row[4])
# elif yr == '2006' and row[3]=='52':
# x05.append(row[3])
# y05.append(row[4])
# elif yr == '2006' and row[3]<'52':
# x06.append(row[3])
# y06.append(row[4])
# elif yr == '2007':
# x07.append(row[3])
# y07.append(row[4])
# elif yr == '2008':
# x08.append(row[3])
# y08.append(row[4])
# elif yr == '2009':
# x09.append(row[3])
# y09.append(row[4])
#plt.plot(x01,y01, label = '2001')
#plt.plot(x02,y02, label = '2002')
#plt.plot(x03,y03, label = '2003')
#plt.plot(x04,y04, label = '2004')
#plt.plot(x05,y05, label = '2005')
#plt.plot(x06,y06, label = '2006')
#plt.plot(x07,y07, label = '2007')
#plt.plot(x08,y08, label = '2008')
#plt.plot(x09,y09, label = '2009')
#plt.legend(loc=1)
#plt.xlim(xmax=55)
#plt.ylabel('Number of ER ILI cases, ages 50-69')
#plt.xlabel('Week Number')
#plt.show()
#for row in E1c:
# yr = row[2][:4]
# if yr == "2000" or yr == "2010":
# continue
# if yr == '2001':
# x01.append(row[3])
# y01.append(row[4])
# elif yr == '2002':
# x02.append(row[3])
# y02.append(row[4])
# elif yr == '2003':
# x03.append(row[3])
# y03.append(row[4])
# elif yr == '2004':
# x04.append(row[3])
# y04.append(row[4])
# elif yr == '2005' and row[3]=='53':
# x04.append(row[3])
# y04.append(row[4])
# elif yr == '2005' and row[3]<'53':
# x05.append(row[3])
# y05.append(row[4])
# elif yr == '2006' and row[3]=='52':
# x05.append(row[3])
# y05.append(row[4])
# elif yr == '2006' and row[3]<'52':
# x06.append(row[3])
# y06.append(row[4])
# elif yr == '2007':
# x07.append(row[3])
# y07.append(row[4])
# elif yr == '2008':
# x08.append(row[3])
# y08.append(row[4])
# elif yr == '2009':
# x09.append(row[3])
# y09.append(row[4])
#plt.plot(x01,y01, label = '2001')
#plt.plot(x02,y02, label = '2002')
#plt.plot(x03,y03, label = '2003')
#plt.plot(x04,y04, label = '2004')
#plt.plot(x05,y05, label = '2005')
#plt.plot(x06,y06, label = '2006')
#plt.plot(x07,y07, label = '2007')
#plt.plot(x08,y08, label = '2008')
#plt.plot(x09,y09, label = '2009')
#plt.legend(loc=2)
#plt.xlim(xmax=55)
#plt.ylabel('Number of ILI cases, ages 5-19')
#plt.xlabel('Week Number')
#plt.show()
#for row in E1f:
# yr = row[2][:4]
# if yr == "2000" or yr == "2010":
# continue
# if yr == '2001':
# x01.append(row[3])
# y01.append(row[4])
# elif yr == '2002':
# x02.append(row[3])
# y02.append(row[4])
# elif yr == '2003':
# x03.append(row[3])
# y03.append(row[4])
# elif yr == '2004':
# x04.append(row[3])
# y04.append(row[4])
# elif yr == '2005' and row[3]=='53':
# x04.append(row[3])
# y04.append(row[4])
# elif yr == '2005' and row[3]<'53':
# x05.append(row[3])
# y05.append(row[4])
# elif yr == '2006' and row[3]=='52':
# x05.append(row[3])
# y05.append(row[4])
# elif yr == '2006' and row[3]<'52':
# x06.append(row[3])
# y06.append(row[4])
# elif yr == '2007':
# x07.append(row[3])
# y07.append(row[4])
# elif yr == '2008':
# x08.append(row[3])
# y08.append(row[4])
# elif yr == '2009':
# x09.append(row[3])
# y09.append(row[4])
#plt.plot(x01,y01, label = '2001')
#plt.plot(x02,y02, label = '2002')
#plt.plot(x03,y03, label = '2003')
#plt.plot(x04,y04, label = '2004')
#plt.plot(x05,y05, label = '2005')
#plt.plot(x06,y06, label = '2006')
#plt.plot(x07,y07, label = '2007')
#plt.plot(x08,y08, label = '2008')
#plt.plot(x09,y09, label = '2009')
#plt.legend(loc=1)
#plt.xlim(xmax=55)
#plt.ylabel('Number of ILI cases, ages 50-69')
#plt.xlabel('Week Number')
#plt.show()
## E4 all years
#x = np.arange(0,496,1)
#for row in E4a:
# y2yr.append(row[6])
#for row in E4b:
# y2_4yr.append(row[6])
#for row in E4c:
# y5_19yr.append(row[6])
#for row in E4d:
# y20_29yr.append(row[6])
#for row in E4e:
# y30_49yr.append(row[6])
#for row in E4f:
# y50_69yr.append(row[6])
#for row in E4g:
# y70yr.append(row[6])
#print len(y2yr), len(y2_4yr), len(y5_19yr), len(y20_29yr), len(y30_49yr), len(y50_69yr), len(y70yr)
#plt.plot(x,y2yr, label = '<2 years')
#plt.plot(x,y2_4yr, label = '2-4 years')
#plt.plot(x,y5_19yr, label = '5-19 years')
#plt.plot(x,y20_29yr, label = '20-29 years')
#plt.plot(x,y30_49yr, label = '30-49 years')
#plt.plot(x,y50_69yr, label = '50-69 years')
#plt.plot(x,y70yr, label = '70+ years')
#plt.legend(loc=2)
#plt.ylabel('Number of ILI cases per 100,000')
#plt.xlabel('Week Number 12-31-2000 to 6-27-2010')
#plt.show()
## E4 seasonal series
#G4season(E4a, y2yr)
#G4season(E4b, y2_4yr)
#G4season(E4c, y5_19yr)
#G4season(E4d, y20_29yr)
#G4season(E4e, y30_49yr)
#G4season(E4f, y50_69yr)
#G4season(E4g, y70yr)
#x=np.arange(1,len(y2yr)+1,1)
#plt.plot(x,y2yr, label = '<2 years')
#plt.plot(x,y2_4yr, label = '2-4 years')
#plt.plot(x,y5_19yr, label = '5-19 years')
#plt.plot(x,y20_29yr, label = '20-29 years')
#plt.plot(x,y30_49yr, label = '30-49 years')
#plt.plot(x,y50_69yr, label = '50-69 years')
#plt.plot(x,y70yr, label = '70+ years')
#plt.legend(loc=2)
#plt.xticks(x, wks_by_season, rotation = 90)
#plt.ylabel('Number of ILI cases per 100,000')
#plt.xlabel('Week Number ('+season+' flu season)')
#plt.xlim(xmax=55)
#plt.show()
#D4 all years
#x = np.arange(0,496,1)
#for row in D4a:
# y2yr.append(row[6])
#for row in D4b:
# y2_4yr.append(row[6])
#for row in D4c:
# y5_19yr.append(row[6])
#for row in D4d:
# y20_29yr.append(row[6])
#for row in D4e:
# y30_49yr.append(row[6])
#for row in D4f:
# y50_69yr.append(row[6])
#for row in D4g:
# y70yr.append(row[6])
#print len(y2yr), len(y2_4yr), len(y5_19yr), len(y20_29yr), len(y30_49yr), len(y50_69yr), len(y70yr)
#plt.plot(x,y2yr, label = '<2 years')
#plt.plot(x,y2_4yr, label = '2-4 years')
#plt.plot(x,y5_19yr, label = '5-19 years')
#plt.plot(x,y20_29yr, label = '20-29 years')
#plt.plot(x,y30_49yr, label = '30-49 years')
#plt.plot(x,y50_69yr, label = '50-69 years')
#plt.plot(x,y70yr, label = '70+ years')
#plt.legend(loc=2)
#plt.ylabel('Number of ILI cases at the ER per 10,000')
#plt.xlabel('Week Number 12-31-2000 to 6-27-2010')
#plt.show()
## D4 seasonal series
#G4season(D4a, y2yr)
#G4season(D4b, y2_4yr)
#G4season(D4c, y5_19yr)
#G4season(D4d, y20_29yr)
#G4season(D4e, y30_49yr)
#G4season(D4f, y50_69yr)
#G4season(D4g, y70yr)
#x=np.arange(1,len(y2yr)+1,1)
#plt.plot(x,y2yr, label = '<2 years')
#plt.plot(x,y2_4yr, label = '2-4 years')
#plt.plot(x,y5_19yr, label = '5-19 years')
#plt.plot(x,y20_29yr, label = '20-29 years')
#plt.plot(x,y30_49yr, label = '30-49 years')
#plt.plot(x,y50_69yr, label = '50-69 years')
#plt.plot(x,y70yr, label = '70+ years')
#plt.legend(loc=1)
#plt.xticks(x, wks_by_season, rotation = 90)
#plt.ylabel('Number of ILI cases at the ER per 10,000')
#plt.xlabel('Week Number ('+season+' flu season)')
#plt.xlim(xmax=55)
#plt.show()
## G4 all years
#x = np.arange(0,496,1)
#for row in G4a:
# y2yr.append(row[6])
#for row in G4b:
# y2_4yr.append(row[6])
#for row in G4c:
# y5_19yr.append(row[6])
#for row in G4d:
# y20_29yr.append(row[6])
#for row in G4e:
# y30_49yr.append(row[6])
#for row in G4f:
# y50_69yr.append(row[6])
#for row in G4g:
# y70yr.append(row[6])
#plt.plot(x,y2yr, label = '<2 years')
#plt.plot(x,y2_4yr, label = '2-4 years')
#plt.plot(x,y5_19yr, label = '5-19 years')
#plt.plot(x,y20_29yr, label = '20-29 years')
#plt.plot(x,y30_49yr, label = '30-49 years')
#plt.plot(x,y50_69yr, label = '50-69 years')
#plt.plot(x,y70yr, label = '70+ years')
#plt.legend(loc=2)
#plt.ylabel('Number of ILI cases in acute care facilities per 10,000')
#plt.xlabel('Week Number 12-31-2000 to 6-27-2010')
#plt.show()
# G4 seasonal series
G4season(G4a, y2yr)
G4season(G4b, y2_4yr)
G4season(G4c, y5_19yr)
G4season(G4d, y20_29yr)
G4season(G4e, y30_49yr)
G4season(G4f, y50_69yr)
G4season(G4g, y70yr)
x=np.arange(1,len(y2yr)+1,1)
plt.plot(x,y2yr, label = '<2 years')
plt.plot(x,y2_4yr, label = '2-4 years')
plt.plot(x,y5_19yr, label = '5-19 years')
plt.plot(x,y20_29yr, label = '20-29 years')
plt.plot(x,y30_49yr, label = '30-49 years')
plt.plot(x,y50_69yr, label = '50-69 years')
plt.plot(x,y70yr, label = '70+ years')
plt.legend(loc=2)
plt.xticks(x, wks_by_season, rotation = 90)
plt.ylabel('ILI cases in acute care facilities per 10,000', fontsize=24)
plt.xlabel('Week Number ('+season+' flu season)')
plt.xlim(xmax=55)
plt.show()
### E4peak_season series
#season_grabaxes(D4a) #grabs only values for axes, chose a year with all weeks (already hardcoded in function)
#yrct=0
#x=np.arange(1,8,1) #there are seven age groups along the x axis
#seasontext = str(yr1vec[yrct]) +"-"+ str(yr2vec[yrct])
#peakweek(E4a, s_peak, s_wk, s_numshift, s_num, yrct)
#peakweek(E4b, s_peak, s_wk, s_numshift, s_num, yrct)
#peakweek(E4c, s_peak, s_wk, s_numshift, s_num, yrct)
#peakweek(E4d, s_peak, s_wk, s_numshift, s_num, yrct)
#peakweek(E4e, s_peak, s_wk, s_numshift, s_num, yrct)
#peakweek(E4f, s_peak, s_wk, s_numshift, s_num, yrct)
#peakweek(E4g, s_peak, s_wk, s_numshift, s_num, yrct)
#scatter(x, peakwk_shifted[0:7], marker = 'o', label = seasontext, color='r')
#plt.ylabel('Week Number in the Year')
#plt.xlabel('Age Group')
#plt.yticks(yax, wks_by_season)
#plt.xticks(x, agelabel)
#plt.legend(loc=2)
#plt.show()
#yrct +=1
#seasontext = str(yr1vec[yrct])+ "-"+ str(yr2vec[yrct])
#peakweek(E4a_2, s_peak, s_wk, s_numshift, s_num, yrct)
#peakweek(E4b_2, s_peak, s_wk, s_numshift, s_num, yrct)
#peakweek(E4c_2, s_peak, s_wk, s_numshift, s_num, yrct)
#peakweek(E4d_2, s_peak, s_wk, s_numshift, s_num, yrct)
#peakweek(E4e_2, s_peak, s_wk, s_numshift, s_num, yrct)
#peakweek(E4f_2, s_peak, s_wk, s_numshift, s_num, yrct)
#peakweek(E4g_2, s_peak, s_wk, s_numshift, s_num, yrct)
#scatter(x, peakwk_shifted[7:14], marker = 'o', label = seasontext, color='orange')
#plt.ylabel('Week Number in the Year')
#plt.xlabel('Age Group')
#plt.yticks(yax, wks_by_season)
#plt.xticks(x, agelabel)
#plt.legend(loc=2)
#plt.show()
#yrct +=1
#seasontext = str(yr1vec[yrct])+ "-"+ str(yr2vec[yrct])
#peakweek(E4a_3, s_peak, s_wk, s_numshift, s_num, yrct)
#peakweek(E4b_3, s_peak, s_wk, s_numshift, s_num, yrct)
#peakweek(E4c_3, s_peak, s_wk, s_numshift, s_num, yrct)
#peakweek(E4d_3, s_peak, s_wk, s_numshift, s_num, yrct)
#peakweek(E4e_3, s_peak, s_wk, s_numshift, s_num, yrct)
#peakweek(E4f_3, s_peak, s_wk, s_numshift, s_num, yrct)
#peakweek(E4g_3, s_peak, s_wk, s_numshift, s_num, yrct)
#scatter(x, peakwk_shifted[14:21], marker = 'o', label = seasontext, color='y')
#plt.ylabel('Week Number in the Year')
#plt.xlabel('Age Group')
#plt.yticks(yax, wks_by_season)
#plt.xticks(x, agelabel)
#plt.legend(loc=2)
#plt.show()
#yrct +=1
#seasontext = str(yr1vec[yrct])+ "-"+ str(yr2vec[yrct])
#peakweek(E4a_4, s_peak, s_wk, s_numshift, s_num, yrct)
#peakweek(E4b_4, s_peak, s_wk, s_numshift, s_num, yrct)
#peakweek(E4c_4, s_peak, s_wk, s_numshift, s_num, yrct)
#peakweek(E4d_4, s_peak, s_wk, s_numshift, s_num, yrct)
#peakweek(E4e_4, s_peak, s_wk, s_numshift, s_num, yrct)
#peakweek(E4f_4, s_peak, s_wk, s_numshift, s_num, yrct)
#peakweek(E4g_4, s_peak, s_wk, s_numshift, s_num, yrct)
#scatter(x, peakwk_shifted[21:28], marker = 'o', label = seasontext, color='g')
#plt.ylabel('Week Number in the Year')
#plt.xlabel('Age Group')
#plt.yticks(yax, wks_by_season)
#plt.xticks(x, agelabel)
#plt.legend(loc=2)
#plt.show()
#yrct +=1
#seasontext = str(yr1vec[yrct])+ "-"+ str(yr2vec[yrct])
#peakweek(E4a_5, s_peak, s_wk, s_numshift, s_num, yrct)
#peakweek(E4b_5, s_peak, s_wk, s_numshift, s_num, yrct)
#peakweek(E4c_5, s_peak, s_wk, s_numshift, s_num, yrct)
#peakweek(E4d_5, s_peak, s_wk, s_numshift, s_num, yrct)
#peakweek(E4e_5, s_peak, s_wk, s_numshift, s_num, yrct)
#peakweek(E4f_5, s_peak, s_wk, s_numshift, s_num, yrct)
#peakweek(E4g_5, s_peak, s_wk, s_numshift, s_num, yrct)
#scatter(x, peakwk_shifted[28:35], marker = 'o', label = seasontext, color='b')
#plt.ylabel('Week Number in the Year')
#plt.xlabel('Age Group')
#plt.yticks(yax, wks_by_season)
#plt.xticks(x, agelabel)
#plt.legend(loc=2)
#plt.show()
#yrct +=1
#seasontext = str(yr1vec[yrct])+ "-"+ str(yr2vec[yrct])
#peakweek(E4a_6, s_peak, s_wk, s_numshift, s_num, yrct)
#peakweek(E4b_6, s_peak, s_wk, s_numshift, s_num, yrct)
#peakweek(E4c_6, s_peak, s_wk, s_numshift, s_num, yrct)
#peakweek(E4d_6, s_peak, s_wk, s_numshift, s_num, yrct)
#peakweek(E4e_6, s_peak, s_wk, s_numshift, s_num, yrct)
#peakweek(E4f_6, s_peak, s_wk, s_numshift, s_num, yrct)
#peakweek(E4g_6, s_peak, s_wk, s_numshift, s_num, yrct)
#scatter(x, peakwk_shifted[35:42], marker = 'o', label = seasontext, color='violet')
#plt.ylabel('Week Number in the Year')
#plt.xlabel('Age Group')
#plt.yticks(yax, wks_by_season)
#plt.xticks(x, agelabel)
#plt.legend(loc=2)
#plt.show()
#yrct +=1
#seasontext = str(yr1vec[yrct])+ "-"+ str(yr2vec[yrct])
#peakweek(E4a_7, s_peak, s_wk, s_numshift, s_num, yrct)
#peakweek(E4b_7, s_peak, s_wk, s_numshift, s_num, yrct)
#peakweek(E4c_7, s_peak, s_wk, s_numshift, s_num, yrct)
#peakweek(E4d_7, s_peak, s_wk, s_numshift, s_num, yrct)
#peakweek(E4e_7, s_peak, s_wk, s_numshift, s_num, yrct)
#peakweek(E4f_7, s_peak, s_wk, s_numshift, s_num, yrct)
#peakweek(E4g_7, s_peak, s_wk, s_numshift, s_num, yrct)
#scatter(x, peakwk_shifted[42:49], marker = 'o', label = seasontext, color='black')
#plt.ylabel('Week Number in the Year')
#plt.xlabel('Age Group')
#plt.yticks(yax, wks_by_season)
#plt.xticks(x, agelabel)
#plt.legend(loc=2)
#plt.show()
#yrct +=1
#seasontext = str(yr1vec[yrct])+ "-"+ str(yr2vec[yrct])
#peakweek(E4a_8, s_peak, s_wk, s_numshift, s_num, yrct)
#peakweek(E4b_8, s_peak, s_wk, s_numshift, s_num, yrct)
#peakweek(E4c_8, s_peak, s_wk, s_numshift, s_num, yrct)
#peakweek(E4d_8, s_peak, s_wk, s_numshift, s_num, yrct)
#peakweek(E4e_8, s_peak, s_wk, s_numshift, s_num, yrct)
#peakweek(E4f_8, s_peak, s_wk, s_numshift, s_num, yrct)
#peakweek(E4g_8, s_peak, s_wk, s_numshift, s_num, yrct)
#print peakwk_shifted
#scatter(x, peakwk_shifted[49:56], marker = 'o', label = seasontext, color='cyan')
#plt.ylabel('Week Number in the Year')
#plt.xlabel('Age Group')
#plt.yticks(yax, wks_by_season)
#plt.xticks(x, agelabel)
#plt.legend(loc=2)
#plt.show()
# ## G4peak_season series
# season_grabaxes(D4a) #grabs only values for axes, chose a year with all weeks (already hardcoded in function)
# yrct=0
# x=np.arange(1,8,1) #there are seven age groups along the x axis
# seasontext = str(yr1vec[yrct]) +"-"+ str(yr2vec[yrct])+" acute peak"
# peakweek(G4a, s_peak, s_wk, s_numshift, s_num, yrct)
# peakweek(G4b, s_peak, s_wk, s_numshift, s_num, yrct)
# peakweek(G4c, s_peak, s_wk, s_numshift, s_num, yrct)
# peakweek(G4d, s_peak, s_wk, s_numshift, s_num, yrct)
# peakweek(G4e, s_peak, s_wk, s_numshift, s_num, yrct)
# peakweek(G4f, s_peak, s_wk, s_numshift, s_num, yrct)
# peakweek(G4g, s_peak, s_wk, s_numshift, s_num, yrct)
# scatter(x, peakwk_shifted[0:7], marker = 'o', label = seasontext, color='r')
# plt.ylabel('Week Number in the Year')
# plt.xlabel('Age Group')
# plt.yticks(yax, wks_by_season)
# plt.xticks(x, agelabel)
# plt.legend(loc=2)
# plt.show()
# yrct +=1
# seasontext = str(yr1vec[yrct])+ "-"+ str(yr2vec[yrct])+" acute peak"
# peakweek(G4a_2, s_peak, s_wk, s_numshift, s_num, yrct)
# peakweek(G4b_2, s_peak, s_wk, s_numshift, s_num, yrct)
# peakweek(G4c_2, s_peak, s_wk, s_numshift, s_num, yrct)
# peakweek(G4d_2, s_peak, s_wk, s_numshift, s_num, yrct)
# peakweek(G4e_2, s_peak, s_wk, s_numshift, s_num, yrct)
# peakweek(G4f_2, s_peak, s_wk, s_numshift, s_num, yrct)
# peakweek(G4g_2, s_peak, s_wk, s_numshift, s_num, yrct)
# scatter(x, peakwk_shifted[7:14], marker = 'o', label = seasontext, color='orange')
# plt.ylabel('Week Number in the Year')
# plt.xlabel('Age Group')
# plt.yticks(yax, wks_by_season)
# plt.xticks(x, agelabel)
# plt.legend(loc=2)
# plt.show()
# yrct +=1
# seasontext = str(yr1vec[yrct])+ "-"+ str(yr2vec[yrct])+" acute peak"
# peakweek(G4a_3, s_peak, s_wk, s_numshift, s_num, yrct)
# peakweek(G4b_3, s_peak, s_wk, s_numshift, s_num, yrct)
# peakweek(G4c_3, s_peak, s_wk, s_numshift, s_num, yrct)
# peakweek(G4d_3, s_peak, s_wk, s_numshift, s_num, yrct)
# peakweek(G4e_3, s_peak, s_wk, s_numshift, s_num, yrct)
# peakweek(G4f_3, s_peak, s_wk, s_numshift, s_num, yrct)
# peakweek(G4g_3, s_peak, s_wk, s_numshift, s_num, yrct)
# scatter(x, peakwk_shifted[14:21], marker = 'o', label = seasontext, color='y')
# plt.ylabel('Week Number in the Year')
# plt.xlabel('Age Group')
# plt.yticks(yax, wks_by_season)
# plt.xticks(x, agelabel)
# plt.legend(loc=2)
# plt.show()
# yrct +=1
# seasontext = str(yr1vec[yrct])+ "-"+ str(yr2vec[yrct])+" acute peak"
# peakweek(G4a_4, s_peak, s_wk, s_numshift, s_num, yrct)
# peakweek(G4b_4, s_peak, s_wk, s_numshift, s_num, yrct)
# peakweek(G4c_4, s_peak, s_wk, s_numshift, s_num, yrct)
# peakweek(G4d_4, s_peak, s_wk, s_numshift, s_num, yrct)
# peakweek(G4e_4, s_peak, s_wk, s_numshift, s_num, yrct)
# peakweek(G4f_4, s_peak, s_wk, s_numshift, s_num, yrct)
# peakweek(G4g_4, s_peak, s_wk, s_numshift, s_num, yrct)
# scatter(x, peakwk_shifted[21:28], marker = 'o', label = seasontext, color='g')
# plt.ylabel('Week Number in the Year')
# plt.xlabel('Age Group')
# plt.yticks(yax, wks_by_season)
# plt.xticks(x, agelabel)
# plt.legend(loc=2)
# plt.show()
# yrct +=1
# seasontext = str(yr1vec[yrct])+ "-"+ str(yr2vec[yrct])+" acute peak"
# peakweek(G4a_5, s_peak, s_wk, s_numshift, s_num, yrct)
# peakweek(G4b_5, s_peak, s_wk, s_numshift, s_num, yrct)
# peakweek(G4c_5, s_peak, s_wk, s_numshift, s_num, yrct)
# peakweek(G4d_5, s_peak, s_wk, s_numshift, s_num, yrct)
# peakweek(G4e_5, s_peak, s_wk, s_numshift, s_num, yrct)
# peakweek(G4f_5, s_peak, s_wk, s_numshift, s_num, yrct)
# peakweek(G4g_5, s_peak, s_wk, s_numshift, s_num, yrct)
# scatter(x, peakwk_shifted[28:35], marker = 'o', label = seasontext, color='b')
# plt.ylabel('Week Number in the Year')
# plt.xlabel('Age Group')
# plt.yticks(yax, wks_by_season)
# plt.xticks(x, agelabel)
# plt.legend(loc=2)
# plt.show()
# yrct +=1
# seasontext = str(yr1vec[yrct])+ "-"+ str(yr2vec[yrct])+" acute peak"
# peakweek(G4a_6, s_peak, s_wk, s_numshift, s_num, yrct)
# peakweek(G4b_6, s_peak, s_wk, s_numshift, s_num, yrct)
# peakweek(G4c_6, s_peak, s_wk, s_numshift, s_num, yrct)
# peakweek(G4d_6, s_peak, s_wk, s_numshift, s_num, yrct)
# peakweek(G4e_6, s_peak, s_wk, s_numshift, s_num, yrct)
# peakweek(G4f_6, s_peak, s_wk, s_numshift, s_num, yrct)
# peakweek(G4g_6, s_peak, s_wk, s_numshift, s_num, yrct)
# scatter(x, peakwk_shifted[35:42], marker = 'o', label = seasontext, color='violet')
# plt.ylabel('Week Number in the Year')
# plt.xlabel('Age Group')
# plt.yticks(yax, wks_by_season)
# plt.xticks(x, agelabel)
# plt.legend(loc=2)
# plt.show()
# yrct +=1
# seasontext = str(yr1vec[yrct])+ "-"+ str(yr2vec[yrct])+" acute peak"
# peakweek(G4a_7, s_peak, s_wk, s_numshift, s_num, yrct)
# peakweek(G4b_7, s_peak, s_wk, s_numshift, s_num, yrct)
# peakweek(G4c_7, s_peak, s_wk, s_numshift, s_num, yrct)
# peakweek(G4d_7, s_peak, s_wk, s_numshift, s_num, yrct)
# peakweek(G4e_7, s_peak, s_wk, s_numshift, s_num, yrct)
# peakweek(G4f_7, s_peak, s_wk, s_numshift, s_num, yrct)
# peakweek(G4g_7, s_peak, s_wk, s_numshift, s_num, yrct)
# scatter(x, peakwk_shifted[42:49], marker = 'o', label = seasontext, color='black')
# plt.ylabel('Week Number in the Year')
# plt.xlabel('Age Group')
# plt.yticks(yax, wks_by_season)
# plt.xticks(x, agelabel)
# plt.legend(loc=2)
# plt.show()
# yrct +=1
# seasontext = str(yr1vec[yrct])+ "-"+ str(yr2vec[yrct])+" acute peak"
# peakweek(G4a_8, s_peak, s_wk, s_numshift, s_num, yrct)
# peakweek(G4b_8, s_peak, s_wk, s_numshift, s_num, yrct)
# peakweek(G4c_8, s_peak, s_wk, s_numshift, s_num, yrct)
# peakweek(G4d_8, s_peak, s_wk, s_numshift, s_num, yrct)
# peakweek(G4e_8, s_peak, s_wk, s_numshift, s_num, yrct)
# peakweek(G4f_8, s_peak, s_wk, s_numshift, s_num, yrct)
# peakweek(G4g_8, s_peak, s_wk, s_numshift, s_num, yrct)
# print peakwk_shifted
# scatter(x, peakwk_shifted[49:56], marker = 'o', label = seasontext, color='cyan')
# plt.ylabel('Week Number in the Year')
# plt.xlabel('Age Group')
# plt.yticks(yax, wks_by_season)
# plt.xticks(x, agelabel)
# plt.legend(loc=2)
# plt.show()
#duration of peak above --baseline x percent of peak? (subgraph of D4 series)
#hypotheses: low crossover reaction between virus and vaccine changes magnitude of influenza but perhaps not the peak
#potential inverse relationship between duration and magnitude
| 37.246732 | 125 | 0.699079 | 7,960 | 45,590 | 3.86294 | 0.048367 | 0.045953 | 0.072978 | 0.111613 | 0.801424 | 0.799928 | 0.798693 | 0.79414 | 0.778367 | 0.740219 | 0 | 0.083182 | 0.09263 | 45,590 | 1,223 | 126 | 37.277187 | 0.66014 | 0.536982 | 0 | 0.057895 | 0 | 0 | 0.456301 | 0.431734 | 0 | 0 | 0 | 0 | 0 | 1 | 0.007895 | false | 0 | 0.013158 | 0 | 0.021053 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 1 | 1 | 1 | 1 | 1 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 7 |
018e24995a352bc4d7c4177b0b44e690c15e3f34 | 4,935 | py | Python | app/user/forms.py | vigov5/oshougatsu2015 | 38cbf325675ee2c08a6965b8689fad8308eb84eb | [
"MIT"
] | null | null | null | app/user/forms.py | vigov5/oshougatsu2015 | 38cbf325675ee2c08a6965b8689fad8308eb84eb | [
"MIT"
] | null | null | null | app/user/forms.py | vigov5/oshougatsu2015 | 38cbf325675ee2c08a6965b8689fad8308eb84eb | [
"MIT"
] | null | null | null | from flask_wtf import Form
from wtforms import TextField, SubmitField, validators, PasswordField
from wtforms_alchemy import model_form_factory
from app.user.models import User
ModelForm = model_form_factory(Form)
class SignupForm(Form):
email = TextField('Email', [
validators.Length(max=40, message='email is at most 40 characters.'),
validators.Required('Please enter your email address.'),
validators.Email('Please enter your email address.')
])
student_id = TextField('Student ID', [
validators.Required('Please enter your student id'),
])
submit = SubmitField('Create account')
def __init__(self, *args, **kwargs):
Form.__init__(self, *args, **kwargs)
def validate(self):
if not Form.validate(self):
return False
email = User.query.filter_by(email=self.email.data).first()
if email:
self.email.errors.append('That email is already taken.')
return False
student_id = User.query.filter_by(student_id=self.student_id.data).first()
if student_id:
self.student_id.errors.append('That student ID is already taken.')
return False
return True
class LoginForm(Form):
email = TextField('Email', [
validators.Length(max=40, message='email is at most 40 characters.'),
validators.Required('Please enter your email address.'),
validators.Email('Please enter your email address.')
])
password = PasswordField('Password', [
validators.Required('Please enter a password.'),
validators.Length(min=6, message='Passwords is at least 6 characters.'),
])
submit = SubmitField('Login In')
def __init__(self, *args, **kwargs):
Form.__init__(self, *args, **kwargs)
def validate(self):
if not Form.validate(self):
return False
user = User.query.filter_by(email = self.email.data).first()
if user:
if not user.check_password(self.password.data):
self.password.errors.append('Wrong password')
return False
else:
return True
else:
self.password.errors.append('Invalid e-mail or password')
return False
class ResendMailForm(Form):
email = TextField('Email', [
validators.Length(max=40, message='email is at most 40 characters.'),
validators.Required('Please enter your email address.'),
validators.Email('Please enter a valid email address.')
])
submit = SubmitField('Resend Activation Email')
def __init__(self, *args, **kwargs):
Form.__init__(self, *args, **kwargs)
def validate(self):
if not Form.validate(self):
return False
user = User.query.filter_by(email=self.email.data).first()
if not user:
self.email.errors.append('This email is not registered yet')
return False
else:
return True
class SendForgotPasswordForm(Form):
email = TextField('Email', [
validators.Length(max=40, message='email is at most 40 characters.'),
validators.Required('Please enter your email address.'),
validators.Email('Please enter a valid email address.')
])
submit = SubmitField('Send Forgot Password Email')
def __init__(self, *args, **kwargs):
Form.__init__(self, *args, **kwargs)
def validate(self):
if not Form.validate(self):
return False
user = User.query.filter_by(email=self.email.data).first()
if not user:
self.email.errors.append('This email is not registered yet')
return False
else:
return True
class ResetPasswordForm(Form):
new_password = PasswordField('Password', [
validators.Required('Please enter new password.'),
validators.Length(min=6, message='Passwords is at least 6 characters.'),
validators.EqualTo('new_confirm', message='Passwords must match')
])
new_confirm = PasswordField('Repeat Password')
submit = SubmitField('Reset password')
def __init__(self, *args, **kwargs):
Form.__init__(self, *args, **kwargs)
def validate(self):
if not Form.validate(self):
return False
return True
class ChangePasswordForm(Form):
new_password = PasswordField('Password', [
validators.Required('Please enter new password.'),
validators.Length(min=6, message='Passwords is at least 6 characters.'),
validators.EqualTo('new_confirm', message='Passwords must match')
])
new_confirm = PasswordField('Repeat Password')
submit = SubmitField('Change password')
def __init__(self, *args, **kwargs):
Form.__init__(self, *args, **kwargs)
def validate(self):
if not Form.validate(self):
return False
return True | 32.045455 | 82 | 0.633029 | 566 | 4,935 | 5.392226 | 0.167845 | 0.04325 | 0.047182 | 0.070773 | 0.785059 | 0.728702 | 0.728702 | 0.709699 | 0.709699 | 0.709699 | 0 | 0.005988 | 0.255522 | 4,935 | 154 | 83 | 32.045455 | 0.824714 | 0 | 0 | 0.739496 | 0 | 0 | 0.203809 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0.10084 | false | 0.193277 | 0.033613 | 0 | 0.470588 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 1 | 1 | 1 | 1 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | 0 | 0 | 7 |
6d72864d910fc6fae6068924325788d032529920 | 36,742 | py | Python | oops/weapon_creation_functions.py | mtasa-typescript/mtasa-wiki-dump | edea1746850fb6c99d6155d1d7891e2cceb33a5c | [
"MIT"
] | null | null | null | oops/weapon_creation_functions.py | mtasa-typescript/mtasa-wiki-dump | edea1746850fb6c99d6155d1d7891e2cceb33a5c | [
"MIT"
] | 1 | 2021-02-24T21:50:18.000Z | 2021-02-24T21:50:18.000Z | oops/weapon_creation_functions.py | mtasa-typescript/mtasa-wiki-dump | edea1746850fb6c99d6155d1d7891e2cceb33a5c | [
"MIT"
] | null | null | null | # Autogenerated file. ANY CHANGES WILL BE OVERWRITTEN
from to_python.core.types import FunctionType, \
FunctionArgument, \
FunctionArgumentValues, \
FunctionReturnTypes, \
FunctionSignature, \
FunctionDoc, \
FunctionOOP, \
FunctionOOPField, \
CompoundOOPData, \
FunctionData, \
CompoundFunctionData
DUMP_PARTIAL = [
CompoundOOPData(
server=[
],
client=[
FunctionOOP(
description=None,
base_function_name="createWeapon",
class_name='Element/Weapon|Weapon',
method=None,
field=None,
is_static=True,
)
],
),
CompoundOOPData(
server=[
],
client=[
FunctionOOP(
description=None,
base_function_name="fireWeapon",
class_name='Element/Weapon|weapon',
method=FunctionData(
signature=FunctionSignature(
name='fire',
return_types=FunctionReturnTypes(
return_types=[
FunctionType(
names=['bool'],
is_optional=False,
)
],
variable_length=False,
),
arguments=FunctionArgumentValues(
arguments=[
[
FunctionArgument(
name='theWeapon',
argument_type=FunctionType(
names=['weapon'],
is_optional=False,
),
default_value=None,
)
]
],
variable_length=False,
),
generic_types=[
],
),
docs=FunctionDoc(
description='Fires one shot from a Element/Weapon|custom weapon.' ,
arguments={
"theWeapon": """The weapon to be fired. """
},
result='returns true if the shot weapon is valid and therefore the shot was fired, false otherwise.' ,
),
url='fireWeapon',
),
field=None,
is_static=False,
)
],
),
CompoundOOPData(
server=[
],
client=[
FunctionOOP(
description=None,
base_function_name="getWeaponAmmo",
class_name='Element/Weapon|weapon',
method=FunctionData(
signature=FunctionSignature(
name='getAmmo',
return_types=FunctionReturnTypes(
return_types=[
FunctionType(
names=['int'],
is_optional=False,
)
],
variable_length=False,
),
arguments=FunctionArgumentValues(
arguments=[
[
FunctionArgument(
name='theWeapon',
argument_type=FunctionType(
names=['weapon'],
is_optional=False,
),
default_value=None,
)
]
],
variable_length=False,
),
generic_types=[
],
),
docs=FunctionDoc(
description='This function gets the total ammo a Element/Weapon|custom weapon has.' ,
arguments={
"theWeapon": """: The weapon to get the ammo of. """
},
result='returns an int|integer containing how many ammo left has the weapon. returns false if an error occured.' ,
),
url='getWeaponAmmo',
),
field=FunctionOOPField(
name='ammo',
types=[
FunctionType(
names=['int'],
is_optional=False,
)
],
),
is_static=False,
)
],
),
CompoundOOPData(
server=[
],
client=[
FunctionOOP(
description=None,
base_function_name="getWeaponClipAmmo",
class_name='Element/Weapon|weapon',
method=FunctionData(
signature=FunctionSignature(
name='getClipAmmo',
return_types=FunctionReturnTypes(
return_types=[
FunctionType(
names=['int'],
is_optional=False,
)
],
variable_length=False,
),
arguments=FunctionArgumentValues(
arguments=[
[
FunctionArgument(
name='theWeapon',
argument_type=FunctionType(
names=['weapon'],
is_optional=False,
),
default_value=None,
)
]
],
variable_length=False,
),
generic_types=[
],
),
docs=FunctionDoc(
description='This function gets the amount of ammo left in a Element/Weapon|custom weapons magazine/clip.' ,
arguments={
"theWeapon": """the weapon to get the clip ammo of. """
},
result='returns the amount of ammo in the element/weapon|custom weapons clip, false if an error occured.' ,
),
url='getWeaponClipAmmo',
),
field=FunctionOOPField(
name='clipAmmo',
types=[
FunctionType(
names=['int'],
is_optional=False,
)
],
),
is_static=False,
)
],
),
CompoundOOPData(
server=[
],
client=[
FunctionOOP(
description=None,
base_function_name="getWeaponFiringRate",
class_name='Element/Weapon|weapon',
method=FunctionData(
signature=FunctionSignature(
name='getFiringRate',
return_types=FunctionReturnTypes(
return_types=[
FunctionType(
names=['int'],
is_optional=False,
)
],
variable_length=False,
),
arguments=FunctionArgumentValues(
arguments=[
[
FunctionArgument(
name='theWeapon',
argument_type=FunctionType(
names=['weapon'],
is_optional=False,
),
default_value=None,
)
]
],
variable_length=False,
),
generic_types=[
],
),
docs=FunctionDoc(
description='This gets the firing rate to be used when a Element/Weapon|custom weapon opens fire.' ,
arguments={
"theWeapon": """The weapon to modify the firing rate of. """
},
result='returns an integer with the firing rate of the custom weapon, false otherwise.' ,
),
url='getWeaponFiringRate',
),
field=FunctionOOPField(
name='firingRate',
types=[
FunctionType(
names=['int'],
is_optional=False,
)
],
),
is_static=False,
)
],
),
CompoundOOPData(
server=[
],
client=[
FunctionOOP(
description=None,
base_function_name="getWeaponFlags",
class_name='Element/Weapon|weapon',
method=FunctionData(
signature=FunctionSignature(
name='getFlags',
return_types=FunctionReturnTypes(
return_types=[
FunctionType(
names=['bool'],
is_optional=False,
)
],
variable_length=False,
),
arguments=FunctionArgumentValues(
arguments=[
[
FunctionArgument(
name='theWeapon',
argument_type=FunctionType(
names=['weapon'],
is_optional=False,
),
default_value=None,
)
],
[
FunctionArgument(
name='theFlag',
argument_type=FunctionType(
names=['string'],
is_optional=False,
),
default_value=None,
)
]
],
variable_length=False,
),
generic_types=[
],
),
docs=FunctionDoc(
description='This function gets the flags of a Element/Weapon|custom weapon.' ,
arguments={
"theWeapon": """the weapon to get the flag of. """,
"theFlag": """the weapon flag to get: """,
"disable_model": """: makes the weapon and muzzle effect invisible or not. """,
"flags": """: returns the flags used to get where the gun shoots at. These flags are (by order): """,
"checkBuildings": """: allows the shoot to be blocked by GTAs internally placed buildings, i.e. the world map. """,
"checkCarTires": """: allows the shoot to be blocked by vehicle tires. """,
"checkDummies": """: allows the shoot to be blocked by GTAs internal dummies. These are not used in the current MTA version so this argument can be set to false. """,
"checkObjects": """: allows the shoot to be blocked by object|objects. """,
"checkPeds": """: allows the shoot to be blocked by ped|peds and player|players. """,
"checkVehicles": """: allows the shoot to be blocked by vehicle|vehicles. """,
"checkSeeThroughStuff": """: allows the shoot to be blocked by translucent game objects, e.g. glass. """,
"checkShootThroughStuff": """: allows the shoot to be blocked by things that can be shot through. """,
"instant_reload": """: if enabled, the weapon reloads instantly rather than waiting the reload time until shooting again. """,
"shoot_if_out_of_range": """: if enabled, the weapon still fires its target beyond the weapon range distance. """,
"shoot_if_blocked": """: if enabled, the weapon still fires its target even if its blocked by something. """
},
result='returns the true or false on success (flags flag returns 8 values) if the flag is enabled or not. returns false if the weapon element isnt valid or an error occured.' ,
),
url='getWeaponFlags',
),
field=None,
is_static=False,
)
],
),
CompoundOOPData(
server=[
],
client=[
FunctionOOP(
description="""Pair is completely disabled at the moment (its value is ''[[nil]]'').""",
base_function_name="getWeaponOwner",
class_name='Element/Weapon|weapon',
method=FunctionData(
signature=FunctionSignature(
name='getOwner',
return_types=FunctionReturnTypes(
return_types=[
FunctionType(
names=['bool'],
is_optional=False,
)
],
variable_length=False,
),
arguments=FunctionArgumentValues(
arguments=[
[
FunctionArgument(
name='theWeapon',
argument_type=FunctionType(
names=['weapon'],
is_optional=False,
),
default_value=None,
)
]
],
variable_length=False,
),
generic_types=[
],
),
docs=FunctionDoc(
description='This function gets the owner of a Element/Weapon|custom weapon. Weapon ownership system was, however, disabled, so this function always returns false. Please refer to setWeaponOwner for details.' ,
arguments={
"theWeapon": """The weapon to get the owner of. """
},
result='this function was intended to return the player which owns the element/weapon|custom weapon, and false if an error occured. however, at the moment it always returns false.' ,
),
url='getWeaponOwner',
),
field=FunctionOOPField(
name='owner',
types=[
FunctionType(
names=['bool'],
is_optional=False,
)
],
),
is_static=False,
)
],
),
CompoundOOPData(
server=[
],
client=[
FunctionOOP(
description=None,
base_function_name="getWeaponState",
class_name='Element/Weapon|weapon',
method=FunctionData(
signature=FunctionSignature(
name='getState',
return_types=FunctionReturnTypes(
return_types=[
FunctionType(
names=['string'],
is_optional=False,
)
],
variable_length=False,
),
arguments=FunctionArgumentValues(
arguments=[
[
FunctionArgument(
name='theWeapon',
argument_type=FunctionType(
names=['weapon'],
is_optional=False,
),
default_value=None,
)
]
],
variable_length=False,
),
generic_types=[
],
),
docs=FunctionDoc(
description='This function gets the state of a Element/Weapon|custom weapon.' ,
arguments={
"theWeapon": """the Element/Weapon|weapon to get the state of. """
},
result='* a string if the element/weapon|weapon is valid, indicating the weapon state, which can be:\n** reloading: the weapon is reloading.\n** firing: the weapon is constantly shooting (unless any shooting blocking flags are set) according to its assigned firing rate.\n** ready: the weapon is idle.\n* false if an error occured or the element/weapon|weapon is invalid.' ,
),
url='getWeaponState',
),
field=FunctionOOPField(
name='state',
types=[
FunctionType(
names=['string'],
is_optional=False,
)
],
),
is_static=False,
)
],
),
CompoundOOPData(
server=[
],
client=[
FunctionOOP(
description="""Variable is read only.""",
base_function_name="getWeaponTarget",
class_name='Element/Weapon|weapon',
method=FunctionData(
signature=FunctionSignature(
name='getTarget',
return_types=FunctionReturnTypes(
return_types=[
FunctionType(
names=['nil', 'element', 'float'],
is_optional=False,
)
],
variable_length=False,
),
arguments=FunctionArgumentValues(
arguments=[
[
FunctionArgument(
name='theWeapon',
argument_type=FunctionType(
names=['weapon'],
is_optional=False,
),
default_value=None,
)
]
],
variable_length=False,
),
generic_types=[
],
),
docs=FunctionDoc(
description='This functions gets the target of a Element/Weapon|custom weapon.' ,
arguments={
"theWeapon": """The weapon to get the target of. """
},
result='* returns the target of the element/weapon|custom weapon, which can be:\n**nil if the weapon is in rotation based targeting.\n**3 float|floats if the weapon is firing at a fixed point.\n**an element if the weapon is firing an entity.\n* returns false if the weapon element is not valid.' ,
),
url='getWeaponTarget',
),
field=FunctionOOPField(
name='target',
types=[
FunctionType(
names=['nil', 'element', 'float'],
is_optional=False,
)
],
),
is_static=False,
)
],
),
CompoundOOPData(
server=[
],
client=[
FunctionOOP(
description=None,
base_function_name="resetWeaponFiringRate",
class_name='Element/Weapon|weapon',
method=FunctionData(
signature=FunctionSignature(
name='resetFiringRate',
return_types=FunctionReturnTypes(
return_types=[
FunctionType(
names=['bool'],
is_optional=False,
)
],
variable_length=False,
),
arguments=FunctionArgumentValues(
arguments=[
[
FunctionArgument(
name='theWeapon',
argument_type=FunctionType(
names=['weapon'],
is_optional=False,
),
default_value=None,
)
]
],
variable_length=False,
),
generic_types=[
],
),
docs=FunctionDoc(
description='This function resets the firing rate of a Element/Weapon|custom weapon to the default one.' ,
arguments={
"theWeapon": """the weapon to reset the firing rate of. """
},
result='returns true on success, false otherwise.' ,
),
url='resetWeaponFiringRate',
),
field=None,
is_static=False,
)
],
),
CompoundOOPData(
server=[
],
client=[
FunctionOOP(
description=None,
base_function_name="setWeaponClipAmmo",
class_name='Element/Weapon|weapon',
method=FunctionData(
signature=FunctionSignature(
name='setClipAmmo',
return_types=FunctionReturnTypes(
return_types=[
FunctionType(
names=['bool'],
is_optional=False,
)
],
variable_length=False,
),
arguments=FunctionArgumentValues(
arguments=[
[
FunctionArgument(
name='theWeapon',
argument_type=FunctionType(
names=['weapon'],
is_optional=False,
),
default_value=None,
)
],
[
FunctionArgument(
name='clipAmmo',
argument_type=FunctionType(
names=['int'],
is_optional=False,
),
default_value=None,
)
]
],
variable_length=False,
),
generic_types=[
],
),
docs=FunctionDoc(
description='This function sets the ammo left in a Element/Weapon|custom weapons magazine/clip.' ,
arguments={
"theWeapon": """The Element/Weapon|weapon to set the clip ammo of. """,
"clipAmmo": """The amount of ammo in the clip. """
},
result='this function returns true if the arguments are valid and the weapon clip ammo could be changed; false otherwise.' ,
),
url='setWeaponClipAmmo',
),
field=FunctionOOPField(
name='clipAmmo',
types=[
FunctionType(
names=['bool'],
is_optional=False,
)
],
),
is_static=False,
)
],
),
CompoundOOPData(
server=[
],
client=[
FunctionOOP(
description=None,
base_function_name="setWeaponFiringRate",
class_name='Element/Weapon|weapon',
method=FunctionData(
signature=FunctionSignature(
name='setFiringRate',
return_types=FunctionReturnTypes(
return_types=[
FunctionType(
names=['bool'],
is_optional=False,
)
],
variable_length=False,
),
arguments=FunctionArgumentValues(
arguments=[
[
FunctionArgument(
name='theWeapon',
argument_type=FunctionType(
names=['weapon'],
is_optional=False,
),
default_value=None,
)
],
[
FunctionArgument(
name='firingRate',
argument_type=FunctionType(
names=['int'],
is_optional=False,
),
default_value=None,
)
]
],
variable_length=False,
),
generic_types=[
],
),
docs=FunctionDoc(
description='This function sets the firing rate to be used when a Element/Weapon|custom weapon is in firing state.' ,
arguments={
"theWeapon": """The weapon to modify the firing rate of. """,
"firingRate": """The weapon firing rate. It seems to be a kind of frecuency value, so the lower the quicker the Element/Weapon|custom weapon will shoot. """
},
result='returns true on success, false otherwise.' ,
),
url='setWeaponFiringRate',
),
field=FunctionOOPField(
name='firingRate',
types=[
FunctionType(
names=['bool'],
is_optional=False,
)
],
),
is_static=False,
)
],
),
CompoundOOPData(
server=[
],
client=[
FunctionOOP(
description=None,
base_function_name="setWeaponFlags",
class_name='Element/Weapon|weapon',
method=FunctionData(
signature=FunctionSignature(
name='setFlags',
return_types=FunctionReturnTypes(
return_types=[
FunctionType(
names=['bool'],
is_optional=False,
)
],
variable_length=False,
),
arguments=FunctionArgumentValues(
arguments=[
[
FunctionArgument(
name='theWeapon',
argument_type=FunctionType(
names=['weapon'],
is_optional=False,
),
default_value=None,
)
],
[
FunctionArgument(
name='theFlag',
argument_type=FunctionType(
names=['string'],
is_optional=False,
),
default_value=None,
)
],
[
FunctionArgument(
name='enable',
argument_type=FunctionType(
names=['bool'],
is_optional=False,
),
default_value=None,
)
]
],
variable_length=False,
),
generic_types=[
],
),
docs=FunctionDoc(
description='This function sets a Element/Weapon|custom weapon flags, used to change how it behaves or finds a possible target to shoot.' ,
arguments={
"theWeapon": """the Element/Weapon|weapon element to set the flag of. """,
"theFlag": """the weapon flag to change (all of them can be true or false): """,
"disable_model": """: makes the weapon and muzzle effect invisible or not. """,
"flags": """: configures the flags used to get where the gun shoots at. They are based on processLineOfSights. You have to specify all the eight flags for the function to succeed. These flags are (by order): """,
"checkBuildings": """: allows the shoot to be blocked by GTAs internally placed buildings, i.e. the world map. """,
"checkCarTires": """: allows the shoot to be blocked by vehicle tires. """,
"checkDummies": """: allows the shoot to be blocked by GTAs internal dummies. These are not used in the current MTA version so this argument can be set to false. """,
"checkObjects": """: allows the shoot to be blocked by object|objects. """,
"checkPeds": """: allows the shoot to be blocked by ped|peds and player|players. """,
"checkVehicles": """: allows the shoot to be blocked by vehicle|vehicles. """,
"checkSeeThroughStuff": """: allows the shoot to be blocked by translucent game objects, e.g. glass. """,
"checkShootThroughStuff": """: allows the shoot to be blocked by things that can be shot through. """,
"instant_reload": """: if enabled, the weapon will reload instantly rather than waiting the reload time until shooting again. """,
"shoot_if_out_of_range": """: if enabled, the weapon will still fire its target beyond the weapon range distance. """,
"shoot_if_blocked": """: if enabled, the weapon will still fire its target even if its blocked by something. """,
"enable": """: whether to enable or disable the specified flag. """
},
result='returns true if all arguments are valid and the flags where changed; false otherwise.' ,
),
url='setWeaponFlags',
),
field=None,
is_static=False,
)
],
),
CompoundOOPData(
server=[
],
client=[
FunctionOOP(
description=None,
base_function_name="setWeaponState",
class_name='Element/Weapon|weapon',
method=FunctionData(
signature=FunctionSignature(
name='setState',
return_types=FunctionReturnTypes(
return_types=[
FunctionType(
names=['bool'],
is_optional=False,
)
],
variable_length=False,
),
arguments=FunctionArgumentValues(
arguments=[
[
FunctionArgument(
name='theWeapon',
argument_type=FunctionType(
names=['weapon'],
is_optional=False,
),
default_value=None,
)
],
[
FunctionArgument(
name='theState',
argument_type=FunctionType(
names=['string'],
is_optional=False,
),
default_value=None,
)
]
],
variable_length=False,
),
generic_types=[
],
),
docs=FunctionDoc(
description='This function sets a Element/Weapon|custom weapons state.' ,
arguments={
"theWeapon": """: the weapon you wish to set the state of. """,
"theState": """: the state you wish to set: """,
"reloading": """: makes the weapon reload. """,
"firing": """: makes the weapon constantly fire its target (unless any shooting blocking flags are set) according to its assigned firing rate. """,
"ready": """: makes the weapon stop reloading or firing. """
},
result='returns true on success, false otherwise.' ,
),
url='setWeaponState',
),
field=FunctionOOPField(
name='state',
types=[
FunctionType(
names=['bool'],
is_optional=False,
)
],
),
is_static=False,
)
],
),
CompoundOOPData(
server=[
],
client=[
],
)
]
| 40.464758 | 390 | 0.375075 | 2,249 | 36,742 | 6.03068 | 0.129835 | 0.05139 | 0.045344 | 0.040625 | 0.795399 | 0.76834 | 0.744231 | 0.711052 | 0.689597 | 0.667773 | 0 | 0.000122 | 0.552311 | 36,742 | 907 | 391 | 40.509372 | 0.824427 | 0.001388 | 0 | 0.752283 | 1 | 0.019406 | 0.215051 | 0.024094 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | false | 0 | 0.001142 | 0 | 0.001142 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 1 | 1 | 1 | 0 | 1 | 0 | 0 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 1 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 7 |
09aeec2661f9065b554e1db057318bda897bf15a | 198 | py | Python | devito/dle/__init__.py | jrt54/devito | 5a63696db03ae77c0925fd4a96a531fd21308727 | [
"MIT"
] | 1 | 2020-09-17T02:53:06.000Z | 2020-09-17T02:53:06.000Z | devito/dle/__init__.py | jrt54/devito | 5a63696db03ae77c0925fd4a96a531fd21308727 | [
"MIT"
] | null | null | null | devito/dle/__init__.py | jrt54/devito | 5a63696db03ae77c0925fd4a96a531fd21308727 | [
"MIT"
] | 1 | 2020-01-13T01:17:24.000Z | 2020-01-13T01:17:24.000Z | from devito.dle.blocking_utils import * # noqa
from devito.dle.parallelizer import NThreads, Ompizer # noqa
from devito.dle.rewriters import * # noqa
from devito.dle.transformer import * # noqa
| 39.6 | 61 | 0.772727 | 27 | 198 | 5.62963 | 0.444444 | 0.263158 | 0.342105 | 0.335526 | 0.302632 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0.146465 | 198 | 4 | 62 | 49.5 | 0.899408 | 0.09596 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | true | 0 | 1 | 0 | 1 | 0 | 1 | 0 | 0 | null | 1 | 1 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 1 | 0 | 0 | 0 | 0 | 7 |
1138ac5d8fd75d449b03114780fd2abc522cb8ce | 38,347 | py | Python | whoville/cloudbreak/apis/v3workspaces_api.py | balazsgaspar/whoville | 0d26853bf5cfd3485067b0c23f886e2b4ab742f8 | [
"Apache-2.0"
] | 30 | 2017-06-12T13:05:24.000Z | 2021-08-03T09:00:48.000Z | whoville/cloudbreak/apis/v3workspaces_api.py | balazsgaspar/whoville | 0d26853bf5cfd3485067b0c23f886e2b4ab742f8 | [
"Apache-2.0"
] | 6 | 2017-12-27T23:12:45.000Z | 2019-03-07T22:14:24.000Z | whoville/cloudbreak/apis/v3workspaces_api.py | balazsgaspar/whoville | 0d26853bf5cfd3485067b0c23f886e2b4ab742f8 | [
"Apache-2.0"
] | 31 | 2017-06-12T13:05:28.000Z | 2019-09-20T01:50:29.000Z | # coding: utf-8
"""
Cloudbreak API
Cloudbreak is a powerful left surf that breaks over a coral reef, a mile off southwest the island of Tavarua, Fiji. Cloudbreak is a cloud agnostic Hadoop as a Service API. Abstracts the provisioning and ease management and monitoring of on-demand clusters. SequenceIQ's Cloudbreak is a RESTful application development platform with the goal of helping developers to build solutions for deploying Hadoop YARN clusters in different environments. Once it is deployed in your favourite servlet container it exposes a REST API allowing to span up Hadoop clusters of arbitary sizes and cloud providers. Provisioning Hadoop has never been easier. Cloudbreak is built on the foundation of cloud providers API (Amazon AWS, Microsoft Azure, Google Cloud Platform, Openstack), Apache Ambari, Docker lightweight containers, Swarm and Consul. For further product documentation follow the link: <a href=\"http://hortonworks.com/apache/cloudbreak/\">http://hortonworks.com/apache/cloudbreak/</a>
OpenAPI spec version: 2.9.0
Generated by: https://github.com/swagger-api/swagger-codegen.git
"""
from __future__ import absolute_import
import sys
import os
import re
# python 2 and python 3 compatibility library
from six import iteritems
from ..configuration import Configuration
from ..api_client import ApiClient
class V3workspacesApi(object):
"""
NOTE: This class is auto generated by the swagger code generator program.
Do not edit the class manually.
Ref: https://github.com/swagger-api/swagger-codegen
"""
def __init__(self, api_client=None):
config = Configuration()
if api_client:
self.api_client = api_client
else:
if not config.api_client:
config.api_client = ApiClient()
self.api_client = config.api_client
def add_workspace_users(self, name, **kwargs):
"""
adds users to the given workspace
Workspaces are a way of grouping resources, workspace owners can add users to their workspaces with different permission sets
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please define a `callback` function
to be invoked when receiving the response.
>>> def callback_function(response):
>>> pprint(response)
>>>
>>> thread = api.add_workspace_users(name, callback=callback_function)
:param callback function: The callback function
for asynchronous request. (optional)
:param str name: (required)
:param list[ChangeWorkspaceUsersJson] body:
:return: list[UserResponseJson]
If the method is called asynchronously,
returns the request thread.
"""
kwargs['_return_http_data_only'] = True
if kwargs.get('callback'):
return self.add_workspace_users_with_http_info(name, **kwargs)
else:
(data) = self.add_workspace_users_with_http_info(name, **kwargs)
return data
def add_workspace_users_with_http_info(self, name, **kwargs):
"""
adds users to the given workspace
Workspaces are a way of grouping resources, workspace owners can add users to their workspaces with different permission sets
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please define a `callback` function
to be invoked when receiving the response.
>>> def callback_function(response):
>>> pprint(response)
>>>
>>> thread = api.add_workspace_users_with_http_info(name, callback=callback_function)
:param callback function: The callback function
for asynchronous request. (optional)
:param str name: (required)
:param list[ChangeWorkspaceUsersJson] body:
:return: list[UserResponseJson]
If the method is called asynchronously,
returns the request thread.
"""
all_params = ['name', 'body']
all_params.append('callback')
all_params.append('_return_http_data_only')
all_params.append('_preload_content')
all_params.append('_request_timeout')
params = locals()
for key, val in iteritems(params['kwargs']):
if key not in all_params:
raise TypeError(
"Got an unexpected keyword argument '%s'"
" to method add_workspace_users" % key
)
params[key] = val
del params['kwargs']
# verify the required parameter 'name' is set
if ('name' not in params) or (params['name'] is None):
raise ValueError("Missing the required parameter `name` when calling `add_workspace_users`")
collection_formats = {}
path_params = {}
if 'name' in params:
path_params['name'] = params['name']
query_params = []
header_params = {}
form_params = []
local_var_files = {}
body_params = None
if 'body' in params:
body_params = params['body']
# HTTP header `Accept`
header_params['Accept'] = self.api_client.\
select_header_accept(['application/json'])
# HTTP header `Content-Type`
header_params['Content-Type'] = self.api_client.\
select_header_content_type(['application/json'])
# Authentication setting
auth_settings = ['tokenAuth']
return self.api_client.call_api('/v3/workspaces/name/{name}/addUsers', 'PUT',
path_params,
query_params,
header_params,
body=body_params,
post_params=form_params,
files=local_var_files,
response_type='list[UserResponseJson]',
auth_settings=auth_settings,
callback=params.get('callback'),
_return_http_data_only=params.get('_return_http_data_only'),
_preload_content=params.get('_preload_content', True),
_request_timeout=params.get('_request_timeout'),
collection_formats=collection_formats)
def change_workspace_users(self, name, **kwargs):
"""
change users and their permissions in the workspace
Workspaces are a way of grouping resources, workspace owners can add users to their workspaces with different permission sets
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please define a `callback` function
to be invoked when receiving the response.
>>> def callback_function(response):
>>> pprint(response)
>>>
>>> thread = api.change_workspace_users(name, callback=callback_function)
:param callback function: The callback function
for asynchronous request. (optional)
:param str name: (required)
:param list[ChangeWorkspaceUsersJson] body:
:return: list[UserResponseJson]
If the method is called asynchronously,
returns the request thread.
"""
kwargs['_return_http_data_only'] = True
if kwargs.get('callback'):
return self.change_workspace_users_with_http_info(name, **kwargs)
else:
(data) = self.change_workspace_users_with_http_info(name, **kwargs)
return data
def change_workspace_users_with_http_info(self, name, **kwargs):
"""
change users and their permissions in the workspace
Workspaces are a way of grouping resources, workspace owners can add users to their workspaces with different permission sets
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please define a `callback` function
to be invoked when receiving the response.
>>> def callback_function(response):
>>> pprint(response)
>>>
>>> thread = api.change_workspace_users_with_http_info(name, callback=callback_function)
:param callback function: The callback function
for asynchronous request. (optional)
:param str name: (required)
:param list[ChangeWorkspaceUsersJson] body:
:return: list[UserResponseJson]
If the method is called asynchronously,
returns the request thread.
"""
all_params = ['name', 'body']
all_params.append('callback')
all_params.append('_return_http_data_only')
all_params.append('_preload_content')
all_params.append('_request_timeout')
params = locals()
for key, val in iteritems(params['kwargs']):
if key not in all_params:
raise TypeError(
"Got an unexpected keyword argument '%s'"
" to method change_workspace_users" % key
)
params[key] = val
del params['kwargs']
# verify the required parameter 'name' is set
if ('name' not in params) or (params['name'] is None):
raise ValueError("Missing the required parameter `name` when calling `change_workspace_users`")
collection_formats = {}
path_params = {}
if 'name' in params:
path_params['name'] = params['name']
query_params = []
header_params = {}
form_params = []
local_var_files = {}
body_params = None
if 'body' in params:
body_params = params['body']
# HTTP header `Accept`
header_params['Accept'] = self.api_client.\
select_header_accept(['application/json'])
# HTTP header `Content-Type`
header_params['Content-Type'] = self.api_client.\
select_header_content_type(['application/json'])
# Authentication setting
auth_settings = ['tokenAuth']
return self.api_client.call_api('/v3/workspaces/name/{name}', 'PUT',
path_params,
query_params,
header_params,
body=body_params,
post_params=form_params,
files=local_var_files,
response_type='list[UserResponseJson]',
auth_settings=auth_settings,
callback=params.get('callback'),
_return_http_data_only=params.get('_return_http_data_only'),
_preload_content=params.get('_preload_content', True),
_request_timeout=params.get('_request_timeout'),
collection_formats=collection_formats)
def create_workspace(self, **kwargs):
"""
create an workspace
Workspaces are a way of grouping resources, workspace owners can add users to their workspaces with different permission sets
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please define a `callback` function
to be invoked when receiving the response.
>>> def callback_function(response):
>>> pprint(response)
>>>
>>> thread = api.create_workspace(callback=callback_function)
:param callback function: The callback function
for asynchronous request. (optional)
:param WorkspaceRequest body:
:return: WorkspaceResponse
If the method is called asynchronously,
returns the request thread.
"""
kwargs['_return_http_data_only'] = True
if kwargs.get('callback'):
return self.create_workspace_with_http_info(**kwargs)
else:
(data) = self.create_workspace_with_http_info(**kwargs)
return data
def create_workspace_with_http_info(self, **kwargs):
"""
create an workspace
Workspaces are a way of grouping resources, workspace owners can add users to their workspaces with different permission sets
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please define a `callback` function
to be invoked when receiving the response.
>>> def callback_function(response):
>>> pprint(response)
>>>
>>> thread = api.create_workspace_with_http_info(callback=callback_function)
:param callback function: The callback function
for asynchronous request. (optional)
:param WorkspaceRequest body:
:return: WorkspaceResponse
If the method is called asynchronously,
returns the request thread.
"""
all_params = ['body']
all_params.append('callback')
all_params.append('_return_http_data_only')
all_params.append('_preload_content')
all_params.append('_request_timeout')
params = locals()
for key, val in iteritems(params['kwargs']):
if key not in all_params:
raise TypeError(
"Got an unexpected keyword argument '%s'"
" to method create_workspace" % key
)
params[key] = val
del params['kwargs']
collection_formats = {}
path_params = {}
query_params = []
header_params = {}
form_params = []
local_var_files = {}
body_params = None
if 'body' in params:
body_params = params['body']
# HTTP header `Accept`
header_params['Accept'] = self.api_client.\
select_header_accept(['application/json'])
# HTTP header `Content-Type`
header_params['Content-Type'] = self.api_client.\
select_header_content_type(['application/json'])
# Authentication setting
auth_settings = ['tokenAuth']
return self.api_client.call_api('/v3/workspaces', 'POST',
path_params,
query_params,
header_params,
body=body_params,
post_params=form_params,
files=local_var_files,
response_type='WorkspaceResponse',
auth_settings=auth_settings,
callback=params.get('callback'),
_return_http_data_only=params.get('_return_http_data_only'),
_preload_content=params.get('_preload_content', True),
_request_timeout=params.get('_request_timeout'),
collection_formats=collection_formats)
def delete_workspace_by_name(self, name, **kwargs):
"""
delete an workspace by name
Workspaces are a way of grouping resources, workspace owners can add users to their workspaces with different permission sets
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please define a `callback` function
to be invoked when receiving the response.
>>> def callback_function(response):
>>> pprint(response)
>>>
>>> thread = api.delete_workspace_by_name(name, callback=callback_function)
:param callback function: The callback function
for asynchronous request. (optional)
:param str name: (required)
:return: WorkspaceResponse
If the method is called asynchronously,
returns the request thread.
"""
kwargs['_return_http_data_only'] = True
if kwargs.get('callback'):
return self.delete_workspace_by_name_with_http_info(name, **kwargs)
else:
(data) = self.delete_workspace_by_name_with_http_info(name, **kwargs)
return data
def delete_workspace_by_name_with_http_info(self, name, **kwargs):
"""
delete an workspace by name
Workspaces are a way of grouping resources, workspace owners can add users to their workspaces with different permission sets
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please define a `callback` function
to be invoked when receiving the response.
>>> def callback_function(response):
>>> pprint(response)
>>>
>>> thread = api.delete_workspace_by_name_with_http_info(name, callback=callback_function)
:param callback function: The callback function
for asynchronous request. (optional)
:param str name: (required)
:return: WorkspaceResponse
If the method is called asynchronously,
returns the request thread.
"""
all_params = ['name']
all_params.append('callback')
all_params.append('_return_http_data_only')
all_params.append('_preload_content')
all_params.append('_request_timeout')
params = locals()
for key, val in iteritems(params['kwargs']):
if key not in all_params:
raise TypeError(
"Got an unexpected keyword argument '%s'"
" to method delete_workspace_by_name" % key
)
params[key] = val
del params['kwargs']
# verify the required parameter 'name' is set
if ('name' not in params) or (params['name'] is None):
raise ValueError("Missing the required parameter `name` when calling `delete_workspace_by_name`")
collection_formats = {}
path_params = {}
if 'name' in params:
path_params['name'] = params['name']
query_params = []
header_params = {}
form_params = []
local_var_files = {}
body_params = None
# HTTP header `Accept`
header_params['Accept'] = self.api_client.\
select_header_accept(['application/json'])
# HTTP header `Content-Type`
header_params['Content-Type'] = self.api_client.\
select_header_content_type(['application/json'])
# Authentication setting
auth_settings = ['tokenAuth']
return self.api_client.call_api('/v3/workspaces/name/{name}', 'DELETE',
path_params,
query_params,
header_params,
body=body_params,
post_params=form_params,
files=local_var_files,
response_type='WorkspaceResponse',
auth_settings=auth_settings,
callback=params.get('callback'),
_return_http_data_only=params.get('_return_http_data_only'),
_preload_content=params.get('_preload_content', True),
_request_timeout=params.get('_request_timeout'),
collection_formats=collection_formats)
def get_workspace_by_name(self, name, **kwargs):
"""
retrieve an workspace by name
Workspaces are a way of grouping resources, workspace owners can add users to their workspaces with different permission sets
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please define a `callback` function
to be invoked when receiving the response.
>>> def callback_function(response):
>>> pprint(response)
>>>
>>> thread = api.get_workspace_by_name(name, callback=callback_function)
:param callback function: The callback function
for asynchronous request. (optional)
:param str name: (required)
:return: WorkspaceResponse
If the method is called asynchronously,
returns the request thread.
"""
kwargs['_return_http_data_only'] = True
if kwargs.get('callback'):
return self.get_workspace_by_name_with_http_info(name, **kwargs)
else:
(data) = self.get_workspace_by_name_with_http_info(name, **kwargs)
return data
def get_workspace_by_name_with_http_info(self, name, **kwargs):
"""
retrieve an workspace by name
Workspaces are a way of grouping resources, workspace owners can add users to their workspaces with different permission sets
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please define a `callback` function
to be invoked when receiving the response.
>>> def callback_function(response):
>>> pprint(response)
>>>
>>> thread = api.get_workspace_by_name_with_http_info(name, callback=callback_function)
:param callback function: The callback function
for asynchronous request. (optional)
:param str name: (required)
:return: WorkspaceResponse
If the method is called asynchronously,
returns the request thread.
"""
all_params = ['name']
all_params.append('callback')
all_params.append('_return_http_data_only')
all_params.append('_preload_content')
all_params.append('_request_timeout')
params = locals()
for key, val in iteritems(params['kwargs']):
if key not in all_params:
raise TypeError(
"Got an unexpected keyword argument '%s'"
" to method get_workspace_by_name" % key
)
params[key] = val
del params['kwargs']
# verify the required parameter 'name' is set
if ('name' not in params) or (params['name'] is None):
raise ValueError("Missing the required parameter `name` when calling `get_workspace_by_name`")
collection_formats = {}
path_params = {}
if 'name' in params:
path_params['name'] = params['name']
query_params = []
header_params = {}
form_params = []
local_var_files = {}
body_params = None
# HTTP header `Accept`
header_params['Accept'] = self.api_client.\
select_header_accept(['application/json'])
# HTTP header `Content-Type`
header_params['Content-Type'] = self.api_client.\
select_header_content_type(['application/json'])
# Authentication setting
auth_settings = ['tokenAuth']
return self.api_client.call_api('/v3/workspaces/name/{name}', 'GET',
path_params,
query_params,
header_params,
body=body_params,
post_params=form_params,
files=local_var_files,
response_type='WorkspaceResponse',
auth_settings=auth_settings,
callback=params.get('callback'),
_return_http_data_only=params.get('_return_http_data_only'),
_preload_content=params.get('_preload_content', True),
_request_timeout=params.get('_request_timeout'),
collection_formats=collection_formats)
def get_workspaces(self, **kwargs):
"""
retrieve workspaces
Workspaces are a way of grouping resources, workspace owners can add users to their workspaces with different permission sets
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please define a `callback` function
to be invoked when receiving the response.
>>> def callback_function(response):
>>> pprint(response)
>>>
>>> thread = api.get_workspaces(callback=callback_function)
:param callback function: The callback function
for asynchronous request. (optional)
:return: list[WorkspaceResponse]
If the method is called asynchronously,
returns the request thread.
"""
kwargs['_return_http_data_only'] = True
if kwargs.get('callback'):
return self.get_workspaces_with_http_info(**kwargs)
else:
(data) = self.get_workspaces_with_http_info(**kwargs)
return data
def get_workspaces_with_http_info(self, **kwargs):
"""
retrieve workspaces
Workspaces are a way of grouping resources, workspace owners can add users to their workspaces with different permission sets
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please define a `callback` function
to be invoked when receiving the response.
>>> def callback_function(response):
>>> pprint(response)
>>>
>>> thread = api.get_workspaces_with_http_info(callback=callback_function)
:param callback function: The callback function
for asynchronous request. (optional)
:return: list[WorkspaceResponse]
If the method is called asynchronously,
returns the request thread.
"""
all_params = []
all_params.append('callback')
all_params.append('_return_http_data_only')
all_params.append('_preload_content')
all_params.append('_request_timeout')
params = locals()
for key, val in iteritems(params['kwargs']):
if key not in all_params:
raise TypeError(
"Got an unexpected keyword argument '%s'"
" to method get_workspaces" % key
)
params[key] = val
del params['kwargs']
collection_formats = {}
path_params = {}
query_params = []
header_params = {}
form_params = []
local_var_files = {}
body_params = None
# HTTP header `Accept`
header_params['Accept'] = self.api_client.\
select_header_accept(['application/json'])
# HTTP header `Content-Type`
header_params['Content-Type'] = self.api_client.\
select_header_content_type(['application/json'])
# Authentication setting
auth_settings = ['tokenAuth']
return self.api_client.call_api('/v3/workspaces', 'GET',
path_params,
query_params,
header_params,
body=body_params,
post_params=form_params,
files=local_var_files,
response_type='list[WorkspaceResponse]',
auth_settings=auth_settings,
callback=params.get('callback'),
_return_http_data_only=params.get('_return_http_data_only'),
_preload_content=params.get('_preload_content', True),
_request_timeout=params.get('_request_timeout'),
collection_formats=collection_formats)
def remove_workspace_users(self, name, **kwargs):
"""
removes users from the given workspace by their userIds
Workspaces are a way of grouping resources, workspace owners can add users to their workspaces with different permission sets
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please define a `callback` function
to be invoked when receiving the response.
>>> def callback_function(response):
>>> pprint(response)
>>>
>>> thread = api.remove_workspace_users(name, callback=callback_function)
:param callback function: The callback function
for asynchronous request. (optional)
:param str name: (required)
:param list[str] body:
:return: list[UserResponseJson]
If the method is called asynchronously,
returns the request thread.
"""
kwargs['_return_http_data_only'] = True
if kwargs.get('callback'):
return self.remove_workspace_users_with_http_info(name, **kwargs)
else:
(data) = self.remove_workspace_users_with_http_info(name, **kwargs)
return data
def remove_workspace_users_with_http_info(self, name, **kwargs):
"""
removes users from the given workspace by their userIds
Workspaces are a way of grouping resources, workspace owners can add users to their workspaces with different permission sets
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please define a `callback` function
to be invoked when receiving the response.
>>> def callback_function(response):
>>> pprint(response)
>>>
>>> thread = api.remove_workspace_users_with_http_info(name, callback=callback_function)
:param callback function: The callback function
for asynchronous request. (optional)
:param str name: (required)
:param list[str] body:
:return: list[UserResponseJson]
If the method is called asynchronously,
returns the request thread.
"""
all_params = ['name', 'body']
all_params.append('callback')
all_params.append('_return_http_data_only')
all_params.append('_preload_content')
all_params.append('_request_timeout')
params = locals()
for key, val in iteritems(params['kwargs']):
if key not in all_params:
raise TypeError(
"Got an unexpected keyword argument '%s'"
" to method remove_workspace_users" % key
)
params[key] = val
del params['kwargs']
# verify the required parameter 'name' is set
if ('name' not in params) or (params['name'] is None):
raise ValueError("Missing the required parameter `name` when calling `remove_workspace_users`")
collection_formats = {}
path_params = {}
if 'name' in params:
path_params['name'] = params['name']
query_params = []
header_params = {}
form_params = []
local_var_files = {}
body_params = None
if 'body' in params:
body_params = params['body']
# HTTP header `Accept`
header_params['Accept'] = self.api_client.\
select_header_accept(['application/json'])
# HTTP header `Content-Type`
header_params['Content-Type'] = self.api_client.\
select_header_content_type(['application/json'])
# Authentication setting
auth_settings = ['tokenAuth']
return self.api_client.call_api('/v3/workspaces/name/{name}/removeUsers', 'PUT',
path_params,
query_params,
header_params,
body=body_params,
post_params=form_params,
files=local_var_files,
response_type='list[UserResponseJson]',
auth_settings=auth_settings,
callback=params.get('callback'),
_return_http_data_only=params.get('_return_http_data_only'),
_preload_content=params.get('_preload_content', True),
_request_timeout=params.get('_request_timeout'),
collection_formats=collection_formats)
def update_workspace_users(self, name, **kwargs):
"""
updates the users' permissions in the given workspace
Workspaces are a way of grouping resources, workspace owners can add users to their workspaces with different permission sets
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please define a `callback` function
to be invoked when receiving the response.
>>> def callback_function(response):
>>> pprint(response)
>>>
>>> thread = api.update_workspace_users(name, callback=callback_function)
:param callback function: The callback function
for asynchronous request. (optional)
:param str name: (required)
:param list[ChangeWorkspaceUsersJson] body:
:return: list[UserResponseJson]
If the method is called asynchronously,
returns the request thread.
"""
kwargs['_return_http_data_only'] = True
if kwargs.get('callback'):
return self.update_workspace_users_with_http_info(name, **kwargs)
else:
(data) = self.update_workspace_users_with_http_info(name, **kwargs)
return data
def update_workspace_users_with_http_info(self, name, **kwargs):
"""
updates the users' permissions in the given workspace
Workspaces are a way of grouping resources, workspace owners can add users to their workspaces with different permission sets
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please define a `callback` function
to be invoked when receiving the response.
>>> def callback_function(response):
>>> pprint(response)
>>>
>>> thread = api.update_workspace_users_with_http_info(name, callback=callback_function)
:param callback function: The callback function
for asynchronous request. (optional)
:param str name: (required)
:param list[ChangeWorkspaceUsersJson] body:
:return: list[UserResponseJson]
If the method is called asynchronously,
returns the request thread.
"""
all_params = ['name', 'body']
all_params.append('callback')
all_params.append('_return_http_data_only')
all_params.append('_preload_content')
all_params.append('_request_timeout')
params = locals()
for key, val in iteritems(params['kwargs']):
if key not in all_params:
raise TypeError(
"Got an unexpected keyword argument '%s'"
" to method update_workspace_users" % key
)
params[key] = val
del params['kwargs']
# verify the required parameter 'name' is set
if ('name' not in params) or (params['name'] is None):
raise ValueError("Missing the required parameter `name` when calling `update_workspace_users`")
collection_formats = {}
path_params = {}
if 'name' in params:
path_params['name'] = params['name']
query_params = []
header_params = {}
form_params = []
local_var_files = {}
body_params = None
if 'body' in params:
body_params = params['body']
# HTTP header `Accept`
header_params['Accept'] = self.api_client.\
select_header_accept(['application/json'])
# HTTP header `Content-Type`
header_params['Content-Type'] = self.api_client.\
select_header_content_type(['application/json'])
# Authentication setting
auth_settings = ['tokenAuth']
return self.api_client.call_api('/v3/workspaces/name/{name}/updateUsers', 'PUT',
path_params,
query_params,
header_params,
body=body_params,
post_params=form_params,
files=local_var_files,
response_type='list[UserResponseJson]',
auth_settings=auth_settings,
callback=params.get('callback'),
_return_http_data_only=params.get('_return_http_data_only'),
_preload_content=params.get('_preload_content', True),
_request_timeout=params.get('_request_timeout'),
collection_formats=collection_formats)
| 42.84581 | 984 | 0.57809 | 3,881 | 38,347 | 5.500902 | 0.067508 | 0.059956 | 0.020985 | 0.02698 | 0.936297 | 0.925523 | 0.923135 | 0.910956 | 0.906085 | 0.901588 | 0 | 0.000598 | 0.345712 | 38,347 | 894 | 985 | 42.893736 | 0.850299 | 0.36081 | 0 | 0.815668 | 0 | 0 | 0.153877 | 0.048652 | 0 | 0 | 0 | 0 | 0 | 1 | 0.039171 | false | 0 | 0.016129 | 0 | 0.112903 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 1 | 1 | 1 | 1 | 1 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 7 |
116afb6b83d9b12336169316ba84248094720a14 | 33 | py | Python | liboptpy/unconstr_solvers/__init__.py | amkatrutsa/liboptpy | 8e89b3f5a16aaed759c3cd727639c927ed5741cf | [
"MIT"
] | 57 | 2018-08-17T12:58:07.000Z | 2022-03-22T16:18:28.000Z | liboptpy/unconstr_solvers/__init__.py | amkatrutsa/liboptpy | 8e89b3f5a16aaed759c3cd727639c927ed5741cf | [
"MIT"
] | 6 | 2018-05-13T10:00:15.000Z | 2021-04-04T12:08:02.000Z | liboptpy/unconstr_solvers/__init__.py | amkatrutsa/liboptpy | 8e89b3f5a16aaed759c3cd727639c927ed5741cf | [
"MIT"
] | 16 | 2019-01-12T07:15:29.000Z | 2022-03-22T11:52:29.000Z | from . import so
from . import fo | 16.5 | 16 | 0.727273 | 6 | 33 | 4 | 0.666667 | 0.833333 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0.212121 | 33 | 2 | 17 | 16.5 | 0.923077 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | true | 0 | 1 | 0 | 1 | 0 | 1 | 1 | 0 | null | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 1 | 0 | 1 | 0 | 0 | 7 |
fed9dd1ccb3893d9f79f5ee68c7e72869a5d658e | 6,505 | py | Python | test_board_state.py | srpkdyy/geister_rl | 8190243d6b3ccd48aa6dfbc3920b903bedb79901 | [
"MIT"
] | 8 | 2021-03-12T00:06:44.000Z | 2022-01-15T20:09:51.000Z | test_board_state.py | srpkdyy/geister_rl | 8190243d6b3ccd48aa6dfbc3920b903bedb79901 | [
"MIT"
] | null | null | null | test_board_state.py | srpkdyy/geister_rl | 8190243d6b3ccd48aa6dfbc3920b903bedb79901 | [
"MIT"
] | 1 | 2021-10-04T07:42:01.000Z | 2021-10-04T07:42:01.000Z | import unittest
from geister2 import Geister2
class TestState(unittest.TestCase):
def setUp(self):
game = Geister2()
game.setRed(["E", "F", "G", "H"])
game.changeSide()
game.setRed(["E", "F", "G", "H"])
self.game = game
def test_after_state1(self):
expected = [[
0, 3, 3, 3, 3, 0,
0, 3, 3, 3, 3, 0,
0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0,
1, 0, 1, 1, 1, 0,
0, 2, 2, 2, 2, 0,
0, 0, 0, 0, 0, 0
], [
0, 3, 3, 3, 3, 0,
0, 3, 3, 3, 3, 0,
0, 0, 0, 0, 0, 0,
0, 1, 0, 0, 0, 0,
0, 0, 1, 1, 1, 0,
0, 2, 2, 2, 2, 0,
0, 0, 0, 0, 0, 0
], [
0, 3, 3, 3, 3, 0,
0, 3, 3, 3, 3, 0,
0, 0, 0, 0, 0, 0,
0, 0, 1, 0, 0, 0,
0, 1, 0, 1, 1, 0,
0, 2, 2, 2, 2, 0,
0, 0, 0, 0, 0, 0
], [
0, 3, 3, 3, 3, 0,
0, 3, 3, 3, 3, 0,
0, 0, 0, 0, 0, 0,
0, 0, 0, 1, 0, 0,
0, 1, 1, 0, 1, 0,
0, 2, 2, 2, 2, 0,
0, 0, 0, 0, 0, 0
], [
0, 3, 3, 3, 3, 0,
0, 3, 3, 3, 3, 0,
0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0,
0, 1, 1, 1, 0, 1,
0, 2, 2, 2, 2, 0,
0, 0, 0, 0, 0, 0
], [
0, 3, 3, 3, 3, 0,
0, 3, 3, 3, 3, 0,
0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 1, 0,
0, 1, 1, 1, 0, 0,
0, 2, 2, 2, 2, 0,
0, 0, 0, 0, 0, 0
], [
0, 3, 3, 3, 3, 0,
0, 3, 3, 3, 3, 0,
0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0,
0, 1, 1, 1, 1, 0,
2, 0, 2, 2, 2, 0,
0, 0, 0, 0, 0, 0
], [
0, 3, 3, 3, 3, 0,
0, 3, 3, 3, 3, 0,
0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0,
0, 1, 1, 1, 1, 0,
0, 2, 2, 2, 0, 2,
0, 0, 0, 0, 0, 0
]
]
result = self.game.view_of_states(self.game.after_states())
self.assertEqual(expected, result)
def test_after_state2(self):
state = b"05R25R34R50B55R99B99B99B11u30u03u33u99r99b99r99r"
self.game.setState(state)
expected = [
0, 0, 0, 3, 0, 1,
0, 3, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0,
3, 0, 0, 3, 0, 0,
0, 0, 0, 2, 0, 0,
2, 0, 2, 0, 0, 2,
1, 3, 3, 0, 0, 0
]
result = self.game.view_of_states([self.game.crr_state()])[0]
self.assertEqual(result, expected)
expected = [[
0, 0, 0, 3, 0, 1,
0, 3, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0,
3, 0, 0, 3, 0, 0,
0, 0, 0, 2, 0, 0,
0, 2, 2, 0, 0, 2,
1, 3, 3, 0, 0, 0
], [
0, 0, 0, 3, 0, 1,
0, 3, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0,
3, 0, 0, 3, 0, 0,
2, 0, 0, 2, 0, 0,
0, 0, 2, 0, 0, 2,
1, 3, 3, 0, 0, 0
], [
0, 0, 0, 3, 0, 1,
0, 3, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0,
3, 0, 0, 3, 0, 0,
0, 0, 0, 2, 0, 0,
2, 0, 0, 2, 0, 2,
1, 3, 3, 0, 0, 0
], [
0, 0, 0, 3, 0, 1,
0, 3, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0,
3, 0, 0, 3, 0, 0,
0, 0, 0, 2, 0, 0,
2, 2, 0, 0, 0, 2,
1, 3, 3, 0, 0, 0
], [
0, 0, 0, 3, 0, 1,
0, 3, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0,
3, 0, 0, 3, 0, 0,
0, 0, 2, 2, 0, 0,
2, 0, 0, 0, 0, 2,
1, 3, 3, 0, 0, 0
], [
0, 0, 0, 3, 0, 1,
0, 3, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0,
3, 0, 0, 3, 0, 0,
0, 0, 0, 0, 2, 0,
2, 0, 2, 0, 0, 2,
1, 3, 3, 0, 0, 0
], [
0, 0, 0, 3, 0, 1,
0, 3, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0,
3, 0, 0, 3, 0, 0,
0, 0, 0, 0, 0, 0,
2, 0, 2, 2, 0, 2,
1, 3, 3, 0, 0, 0
], [
0, 0, 0, 3, 0, 1,
0, 3, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0,
3, 0, 0, 3, 0, 0,
0, 0, 2, 0, 0, 0,
2, 0, 2, 0, 0, 2,
1, 3, 3, 0, 0, 0
], [
0, 0, 0, 3, 0, 1,
0, 3, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0,
3, 0, 0, 2, 0, 0,
0, 0, 0, 0, 0, 0,
2, 0, 2, 0, 0, 2,
1, 3, 3, 0, 1, 0
], [
0, 0, 0, 3, 0, 0,
0, 3, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0,
3, 0, 0, 3, 0, 0,
0, 0, 0, 2, 0, 0,
2, 0, 2, 0, 0, 2,
1, 3, 3, 0, 0, 1
], [
0, 0, 0, 3, 0, 0,
0, 3, 0, 0, 0, 1,
0, 0, 0, 0, 0, 0,
3, 0, 0, 3, 0, 0,
0, 0, 0, 2, 0, 0,
2, 0, 2, 0, 0, 2,
1, 3, 3, 0, 0, 0
], [
0, 0, 0, 3, 1, 0,
0, 3, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0,
3, 0, 0, 3, 0, 0,
0, 0, 0, 2, 0, 0,
2, 0, 2, 0, 0, 2,
1, 3, 3, 0, 0, 0
], [
0, 0, 0, 3, 0, 1,
0, 3, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0,
3, 0, 0, 3, 0, 0,
0, 0, 0, 2, 0, 0,
2, 0, 2, 0, 2, 0,
1, 3, 3, 0, 0, 0
], [
0, 0, 0, 3, 0, 1,
0, 3, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0,
3, 0, 0, 3, 0, 0,
0, 0, 0, 2, 0, 2,
2, 0, 2, 0, 0, 0,
1, 3, 3, 0, 0, 0
]]
result = self.game.view_of_states(self.game.after_states())
self.assertEqual(expected, result)
def test_on_act_num_rcvd(self):
after_states = self.game.after_states()
for i in range(len(after_states)):
self.game.on_action_number_received(i)
expected = self.game.view_of_states(after_states)[i][:-6]
result = self.game.view_of_states([self.game.crr_state()])[0][:-6]
# print(result)
self.assertEqual(expected, result)
self.setUp()
if __name__ == "__main__":
unittest.main()
| 28.783186 | 78 | 0.273482 | 1,123 | 6,505 | 1.551202 | 0.047195 | 0.553387 | 0.613088 | 0.645235 | 0.747417 | 0.71814 | 0.700344 | 0.695752 | 0.687715 | 0.679104 | 0 | 0.340088 | 0.544812 | 6,505 | 225 | 79 | 28.911111 | 0.248227 | 0.001998 | 0 | 0.737327 | 0 | 0 | 0.009861 | 0.007396 | 0 | 0 | 0 | 0 | 0.018433 | 1 | 0.018433 | false | 0 | 0.009217 | 0 | 0.032258 | 0 | 0 | 0 | 1 | null | 1 | 1 | 1 | 0 | 1 | 1 | 0 | 0 | 1 | 0 | 1 | 1 | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 1 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 11 |
fedddbc5eb6fc620ba19dd5e9946eaf85be0e514 | 33,011 | py | Python | adminsec/tests/test_rules.py | bihealth/hpc-access | ff606b18b18230af2876a791ca706d3b24addb59 | [
"MIT"
] | null | null | null | adminsec/tests/test_rules.py | bihealth/hpc-access | ff606b18b18230af2876a791ca706d3b24addb59 | [
"MIT"
] | 27 | 2022-02-11T15:51:24.000Z | 2022-03-31T12:11:20.000Z | adminsec/tests/test_rules.py | bihealth/hpc-access | ff606b18b18230af2876a791ca706d3b24addb59 | [
"MIT"
] | null | null | null | from unittest.mock import patch
from django.conf import settings
from django.urls import reverse
from usersec.models import (
HpcUserCreateRequest,
HpcGroupCreateRequest,
REQUEST_STATUS_ACTIVE,
HpcUser,
HpcGroup,
HpcProjectCreateRequest,
HpcProject,
HpcGroupChangeRequest,
HpcUserChangeRequest,
)
from usersec.tests.factories import (
HPCGROUPCREATEREQUEST_FORM_DATA_VALID,
HPCUSERCREATEREQUEST_FORM_DATA_VALID,
HPCPROJECTCREATEREQUEST_FORM_DATA_VALID,
HPCGROUPCHANGEREQUEST_FORM_DATA_VALID,
HPCUSERCHANGEREQUEST_FORM_DATA_VALID,
)
from usersec.tests.test_rules import TestRulesBase
class TestPermissions(TestRulesBase):
"""Tests for permissions without views."""
def test_hpcadmin_is_not_superuser(self):
self.assertFalse(self.user_hpcadmin.is_superuser)
def test_superuser_is_not_hpcadmin(self):
self.assertFalse(self.superuser.is_hpcadmin)
def test_is_hpcadmin(self):
good_users = [self.superuser, self.user_hpcadmin]
bad_users = [
self.user_owner,
self.user_delegate,
self.user_member,
self.user_member_other_group,
self.user,
]
perm = "adminsec.is_hpcadmin"
self.assert_permissions_granted(perm, None, good_users)
self.assert_permissions_denied(perm, None, bad_users)
class TestPermissionsInViews(TestRulesBase):
"""Tests for permissions in views."""
def test_admin_view(self):
url = reverse("adminsec:overview")
good_users = [self.superuser, self.user_hpcadmin]
bad_users = [
self.user_owner,
self.user_delegate,
self.user_member,
self.user_member_other_group,
self.user,
]
self.assert_permissions_on_url(good_users, url, "GET", 200)
self.assert_permissions_on_url(bad_users, url, "GET", 302, redirect_url=reverse("home"))
def test_hpc_user_detail_view(self):
url = reverse(
"adminsec:hpcuser-detail",
kwargs={"hpcuser": self.hpc_member.uuid},
)
good_users = [self.superuser, self.user_hpcadmin]
bad_users = [
self.user_owner,
self.user_delegate,
self.user_member,
self.user_member_other_group,
self.user,
]
self.assert_permissions_on_url(good_users, url, "GET", 200)
self.assert_permissions_on_url(bad_users, url, "GET", 302, redirect_url=reverse("home"))
def test_hpc_project_detail_view(self):
url = reverse(
"adminsec:hpcproject-detail",
kwargs={"hpcproject": self.hpc_project.uuid},
)
good_users = [self.superuser, self.user_hpcadmin]
bad_users = [
self.user_owner,
self.user_delegate,
self.user_member,
self.user_member_other_group,
self.user,
]
self.assert_permissions_on_url(good_users, url, "GET", 200)
self.assert_permissions_on_url(bad_users, url, "GET", 302, redirect_url=reverse("home"))
def test_hpc_group_detail_view(self):
url = reverse(
"adminsec:hpcgroup-detail",
kwargs={"hpcgroup": self.hpc_group.uuid},
)
good_users = [self.superuser, self.user_hpcadmin]
bad_users = [
self.user_owner,
self.user_delegate,
self.user_member,
self.user_member_other_group,
self.user,
]
self.assert_permissions_on_url(good_users, url, "GET", 200)
self.assert_permissions_on_url(bad_users, url, "GET", 302, redirect_url=reverse("home"))
def test_hpc_group_create_request_approve_view_get(self):
url = reverse(
"adminsec:hpcgroupcreaterequest-approve",
kwargs={"hpcgroupcreaterequest": self.hpc_group_create_request.uuid},
)
good_users = [self.superuser, self.user_hpcadmin]
bad_users = [
self.user_owner,
self.user_delegate,
self.user_member,
self.user_member_other_group,
self.user,
]
self.assert_permissions_on_url(good_users, url, "GET", 200)
self.assert_permissions_on_url(bad_users, url, "GET", 302, redirect_url=reverse("home"))
def test_hpc_group_create_request_approve_view_post(self):
url = reverse(
"adminsec:hpcgroupcreaterequest-approve",
kwargs={"hpcgroupcreaterequest": self.hpc_group_create_request.uuid},
)
good_users = [self.superuser, self.user_hpcadmin]
bad_users = [
self.user_owner,
self.user_delegate,
self.user_member,
self.user_member_other_group,
self.user,
]
def rollback_callback():
u = HpcGroupCreateRequest.objects.last()
u.status = REQUEST_STATUS_ACTIVE
u.save()
HpcUser.objects.last().delete()
HpcGroup.objects.last().delete()
self.assert_permissions_on_url(
good_users,
url,
"POST",
302,
redirect_url=reverse("adminsec:overview"),
rollback_callback=rollback_callback,
)
self.assert_permissions_on_url(bad_users, url, "POST", 302, redirect_url=reverse("home"))
def test_hpc_group_create_request_deny_view_get(self):
url = reverse(
"adminsec:hpcgroupcreaterequest-deny",
kwargs={"hpcgroupcreaterequest": self.hpc_group_create_request.uuid},
)
good_users = [self.superuser, self.user_hpcadmin]
bad_users = [
self.user_owner,
self.user_delegate,
self.user_member,
self.user_member_other_group,
self.user,
]
self.assert_permissions_on_url(good_users, url, "GET", 200)
self.assert_permissions_on_url(bad_users, url, "GET", 302, redirect_url=reverse("home"))
def test_hpc_group_create_request_deny_view_post(self):
url = reverse(
"adminsec:hpcgroupcreaterequest-deny",
kwargs={"hpcgroupcreaterequest": self.hpc_group_create_request.uuid},
)
data = {"comment": "Request denied!"}
good_users = [self.superuser, self.user_hpcadmin]
bad_users = [
self.user_owner,
self.user_delegate,
self.user_member,
self.user_member_other_group,
self.user,
]
def rollback_callback():
u = HpcGroupCreateRequest.objects.last()
u.status = REQUEST_STATUS_ACTIVE
u.save()
self.assert_permissions_on_url(
good_users,
url,
"POST",
302,
redirect_url=reverse("adminsec:overview"),
req_kwargs=data,
rollback_callback=rollback_callback,
)
self.assert_permissions_on_url(bad_users, url, "POST", 302, redirect_url=reverse("home"))
def test_hpc_group_create_request_revision_view_get(self):
url = reverse(
"adminsec:hpcgroupcreaterequest-revision",
kwargs={"hpcgroupcreaterequest": self.hpc_group_create_request.uuid},
)
good_users = [self.superuser, self.user_hpcadmin]
bad_users = [
self.user_owner,
self.user_delegate,
self.user_member,
self.user_member_other_group,
self.user,
]
self.assert_permissions_on_url(good_users, url, "GET", 200)
self.assert_permissions_on_url(bad_users, url, "GET", 302, redirect_url=reverse("home"))
def test_hpc_group_create_request_revision_view_post(self):
url = reverse(
"adminsec:hpcgroupcreaterequest-revision",
kwargs={"hpcgroupcreaterequest": self.hpc_group_create_request.uuid},
)
good_users = [self.superuser, self.user_hpcadmin]
bad_users = [
self.user_owner,
self.user_delegate,
self.user_member,
self.user_member_other_group,
self.user,
]
data = dict(HPCGROUPCREATEREQUEST_FORM_DATA_VALID)
def rollback_callback():
u = HpcGroupCreateRequest.objects.last()
u.status = REQUEST_STATUS_ACTIVE
u.save()
self.assert_permissions_on_url(
good_users,
url,
"POST",
302,
req_kwargs=data,
redirect_url=reverse("adminsec:overview"),
rollback_callback=rollback_callback,
)
self.assert_permissions_on_url(
bad_users,
url,
"POST",
302,
req_kwargs=data,
redirect_url=reverse("home"),
)
def test_hpc_group_create_request_detail_view(self):
url = reverse(
"adminsec:hpcgroupcreaterequest-detail",
kwargs={"hpcgroupcreaterequest": self.hpc_group_create_request.uuid},
)
good_users = [self.superuser, self.user_hpcadmin]
bad_users = [
self.user_owner,
self.user_delegate,
self.user_member,
self.user_member_other_group,
self.user,
]
self.assert_permissions_on_url(good_users, url, "GET", 200)
self.assert_permissions_on_url(bad_users, url, "GET", 302, redirect_url=reverse("home"))
def test_hpc_group_change_request_approve_view_get(self):
url = reverse(
"adminsec:hpcgroupchangerequest-approve",
kwargs={"hpcgroupchangerequest": self.hpc_group_change_request.uuid},
)
good_users = [self.superuser, self.user_hpcadmin]
bad_users = [
self.user_owner,
self.user_delegate,
self.user_member,
self.user_member_other_group,
self.user,
]
self.assert_permissions_on_url(good_users, url, "GET", 200)
self.assert_permissions_on_url(bad_users, url, "GET", 302, redirect_url=reverse("home"))
def test_hpc_group_change_request_approve_view_post(self):
url = reverse(
"adminsec:hpcgroupchangerequest-approve",
kwargs={"hpcgroupchangerequest": self.hpc_group_change_request.uuid},
)
good_users = [self.superuser, self.user_hpcadmin]
bad_users = [
self.user_owner,
self.user_delegate,
self.user_member,
self.user_member_other_group,
self.user,
]
def rollback_callback():
u = HpcGroupChangeRequest.objects.last()
u.status = REQUEST_STATUS_ACTIVE
u.save()
self.assert_permissions_on_url(
good_users,
url,
"POST",
302,
redirect_url=reverse("adminsec:overview"),
rollback_callback=rollback_callback,
)
self.assert_permissions_on_url(bad_users, url, "POST", 302, redirect_url=reverse("home"))
def test_hpc_group_change_request_deny_view_get(self):
url = reverse(
"adminsec:hpcgroupchangerequest-deny",
kwargs={"hpcgroupchangerequest": self.hpc_group_change_request.uuid},
)
good_users = [self.superuser, self.user_hpcadmin]
bad_users = [
self.user_owner,
self.user_delegate,
self.user_member,
self.user_member_other_group,
self.user,
]
self.assert_permissions_on_url(good_users, url, "GET", 200)
self.assert_permissions_on_url(bad_users, url, "GET", 302, redirect_url=reverse("home"))
def test_hpc_group_change_request_deny_view_post(self):
url = reverse(
"adminsec:hpcgroupchangerequest-deny",
kwargs={"hpcgroupchangerequest": self.hpc_group_change_request.uuid},
)
data = {"comment": "Request denied!"}
good_users = [self.superuser, self.user_hpcadmin]
bad_users = [
self.user_owner,
self.user_delegate,
self.user_member,
self.user_member_other_group,
self.user,
]
def rollback_callback():
u = HpcGroupChangeRequest.objects.last()
u.status = REQUEST_STATUS_ACTIVE
u.save()
self.assert_permissions_on_url(
good_users,
url,
"POST",
302,
redirect_url=reverse("adminsec:overview"),
req_kwargs=data,
rollback_callback=rollback_callback,
)
self.assert_permissions_on_url(bad_users, url, "POST", 302, redirect_url=reverse("home"))
def test_hpc_group_change_request_revision_view_get(self):
url = reverse(
"adminsec:hpcgroupchangerequest-revision",
kwargs={"hpcgroupchangerequest": self.hpc_group_change_request.uuid},
)
good_users = [self.superuser, self.user_hpcadmin]
bad_users = [
self.user_owner,
self.user_delegate,
self.user_member,
self.user_member_other_group,
self.user,
]
self.assert_permissions_on_url(good_users, url, "GET", 200)
self.assert_permissions_on_url(bad_users, url, "GET", 302, redirect_url=reverse("home"))
def test_hpc_group_change_request_revision_view_post(self):
url = reverse(
"adminsec:hpcgroupchangerequest-revision",
kwargs={"hpcgroupchangerequest": self.hpc_group_change_request.uuid},
)
good_users = [self.superuser, self.user_hpcadmin]
bad_users = [
self.user_owner,
self.user_delegate,
self.user_member,
self.user_member_other_group,
self.user,
]
data = dict(HPCGROUPCHANGEREQUEST_FORM_DATA_VALID)
def rollback_callback():
u = HpcGroupChangeRequest.objects.last()
u.status = REQUEST_STATUS_ACTIVE
u.save()
self.assert_permissions_on_url(
good_users,
url,
"POST",
302,
req_kwargs=data,
redirect_url=reverse("adminsec:overview"),
rollback_callback=rollback_callback,
)
self.assert_permissions_on_url(
bad_users,
url,
"POST",
302,
req_kwargs=data,
redirect_url=reverse("home"),
)
def test_hpc_group_change_request_detail_view(self):
url = reverse(
"adminsec:hpcgroupchangerequest-detail",
kwargs={"hpcgroupchangerequest": self.hpc_group_change_request.uuid},
)
good_users = [self.superuser, self.user_hpcadmin]
bad_users = [
self.user_owner,
self.user_delegate,
self.user_member,
self.user_member_other_group,
self.user,
]
self.assert_permissions_on_url(good_users, url, "GET", 200)
self.assert_permissions_on_url(bad_users, url, "GET", 302, redirect_url=reverse("home"))
def test_hpc_user_create_request_approve_view_get(self):
url = reverse(
"adminsec:hpcusercreaterequest-approve",
kwargs={"hpcusercreaterequest": self.hpc_user_create_request.uuid},
)
good_users = [self.superuser, self.user_hpcadmin]
bad_users = [
self.user_owner,
self.user_delegate,
self.user_member,
self.user_member_other_group,
self.user,
]
self.assert_permissions_on_url(good_users, url, "GET", 200)
self.assert_permissions_on_url(bad_users, url, "GET", 302, redirect_url=reverse("home"))
@patch("adminsec.ldap.LdapConnector.connect")
@patch("adminsec.ldap.LdapConnector.get_ldap_username_domain_by_mail")
def test_hpc_user_create_request_approve_view_post(
self, mock_get_ldap_username_domain_by_mail, mock_connect
):
mock_get_ldap_username_domain_by_mail.return_value = (
"new_user",
settings.AUTH_LDAP_USERNAME_DOMAIN,
)
url = reverse(
"adminsec:hpcusercreaterequest-approve",
kwargs={"hpcusercreaterequest": self.hpc_user_create_request.uuid},
)
good_users = [self.superuser, self.user_hpcadmin]
bad_users = [
self.user_owner,
self.user_delegate,
self.user_member,
self.user_member_other_group,
self.user,
]
def rollback_callback():
u = HpcUserCreateRequest.objects.last()
u.status = REQUEST_STATUS_ACTIVE
u.save()
HpcUser.objects.filter(
username="new_user_" + settings.INSTITUTE_USERNAME_SUFFIX
).delete()
self.assert_permissions_on_url(
good_users,
url,
"POST",
302,
redirect_url=reverse("adminsec:overview"),
rollback_callback=rollback_callback,
)
self.assert_permissions_on_url(bad_users, url, "POST", 302, redirect_url=reverse("home"))
def test_hpc_user_create_request_deny_view_get(self):
url = reverse(
"adminsec:hpcusercreaterequest-deny",
kwargs={"hpcusercreaterequest": self.hpc_user_create_request.uuid},
)
good_users = [self.superuser, self.user_hpcadmin]
bad_users = [
self.user_owner,
self.user_delegate,
self.user_member,
self.user_member_other_group,
self.user,
]
self.assert_permissions_on_url(good_users, url, "GET", 200)
self.assert_permissions_on_url(bad_users, url, "GET", 302, redirect_url=reverse("home"))
def test_hpc_user_create_request_deny_view_post(self):
url = reverse(
"adminsec:hpcusercreaterequest-deny",
kwargs={"hpcusercreaterequest": self.hpc_user_create_request.uuid},
)
data = {"comment": "Request denied!"}
good_users = [self.superuser, self.user_hpcadmin]
bad_users = [
self.user_owner,
self.user_delegate,
self.user_member,
self.user_member_other_group,
self.user,
]
def rollback_callback():
u = HpcUserCreateRequest.objects.last()
u.status = REQUEST_STATUS_ACTIVE
u.save()
self.assert_permissions_on_url(
good_users,
url,
"POST",
302,
redirect_url=reverse("adminsec:overview"),
req_kwargs=data,
rollback_callback=rollback_callback,
)
self.assert_permissions_on_url(bad_users, url, "POST", 302, redirect_url=reverse("home"))
def test_hpc_user_create_request_revision_view_get(self):
url = reverse(
"adminsec:hpcusercreaterequest-revision",
kwargs={"hpcusercreaterequest": self.hpc_user_create_request.uuid},
)
good_users = [self.superuser, self.user_hpcadmin]
bad_users = [
self.user_owner,
self.user_delegate,
self.user_member,
self.user_member_other_group,
self.user,
]
self.assert_permissions_on_url(good_users, url, "GET", 200)
self.assert_permissions_on_url(bad_users, url, "GET", 302, redirect_url=reverse("home"))
def test_hpc_user_create_request_revision_view_post(self):
url = reverse(
"adminsec:hpcusercreaterequest-revision",
kwargs={"hpcusercreaterequest": self.hpc_user_create_request.uuid},
)
good_users = [self.superuser, self.user_hpcadmin]
bad_users = [
self.user_owner,
self.user_delegate,
self.user_member,
self.user_member_other_group,
self.user,
]
data = dict(HPCUSERCREATEREQUEST_FORM_DATA_VALID)
def rollback_callback():
u = HpcUserCreateRequest.objects.last()
u.status = REQUEST_STATUS_ACTIVE
u.save()
self.assert_permissions_on_url(
good_users,
url,
"POST",
302,
req_kwargs=data,
redirect_url=reverse("adminsec:overview"),
rollback_callback=rollback_callback,
)
self.assert_permissions_on_url(
bad_users,
url,
"POST",
302,
req_kwargs=data,
redirect_url=reverse("home"),
)
def test_hpc_user_create_request_detail_view(self):
url = reverse(
"adminsec:hpcusercreaterequest-detail",
kwargs={"hpcusercreaterequest": self.hpc_user_create_request.uuid},
)
good_users = [self.superuser, self.user_hpcadmin]
bad_users = [
self.user_owner,
self.user_delegate,
self.user_member,
self.user_member_other_group,
self.user,
]
self.assert_permissions_on_url(good_users, url, "GET", 200)
self.assert_permissions_on_url(bad_users, url, "GET", 302, redirect_url=reverse("home"))
def test_hpc_user_change_request_approve_view_get(self):
url = reverse(
"adminsec:hpcuserchangerequest-approve",
kwargs={"hpcuserchangerequest": self.hpc_user_change_request.uuid},
)
good_users = [self.superuser, self.user_hpcadmin]
bad_users = [
self.user_owner,
self.user_delegate,
self.user_member,
self.user_member_other_group,
self.user,
]
self.assert_permissions_on_url(good_users, url, "GET", 200)
self.assert_permissions_on_url(bad_users, url, "GET", 302, redirect_url=reverse("home"))
def test_hpc_user_change_request_approve_view_post(self):
url = reverse(
"adminsec:hpcuserchangerequest-approve",
kwargs={"hpcuserchangerequest": self.hpc_user_change_request.uuid},
)
good_users = [self.superuser, self.user_hpcadmin]
bad_users = [
self.user_owner,
self.user_delegate,
self.user_member,
self.user_member_other_group,
self.user,
]
def rollback_callback():
u = HpcUserChangeRequest.objects.last()
u.status = REQUEST_STATUS_ACTIVE
u.save()
self.assert_permissions_on_url(
good_users,
url,
"POST",
302,
redirect_url=reverse("adminsec:overview"),
rollback_callback=rollback_callback,
)
self.assert_permissions_on_url(bad_users, url, "POST", 302, redirect_url=reverse("home"))
def test_hpc_user_change_request_deny_view_get(self):
url = reverse(
"adminsec:hpcuserchangerequest-deny",
kwargs={"hpcuserchangerequest": self.hpc_user_change_request.uuid},
)
good_users = [self.superuser, self.user_hpcadmin]
bad_users = [
self.user_owner,
self.user_delegate,
self.user_member,
self.user_member_other_group,
self.user,
]
self.assert_permissions_on_url(good_users, url, "GET", 200)
self.assert_permissions_on_url(bad_users, url, "GET", 302, redirect_url=reverse("home"))
def test_hpc_user_change_request_deny_view_post(self):
url = reverse(
"adminsec:hpcuserchangerequest-deny",
kwargs={"hpcuserchangerequest": self.hpc_user_change_request.uuid},
)
data = {"comment": "Request denied!"}
good_users = [self.superuser, self.user_hpcadmin]
bad_users = [
self.user_owner,
self.user_delegate,
self.user_member,
self.user_member_other_group,
self.user,
]
def rollback_callback():
u = HpcUserChangeRequest.objects.last()
u.status = REQUEST_STATUS_ACTIVE
u.save()
self.assert_permissions_on_url(
good_users,
url,
"POST",
302,
redirect_url=reverse("adminsec:overview"),
req_kwargs=data,
rollback_callback=rollback_callback,
)
self.assert_permissions_on_url(bad_users, url, "POST", 302, redirect_url=reverse("home"))
def test_hpc_user_change_request_revision_view_get(self):
url = reverse(
"adminsec:hpcuserchangerequest-revision",
kwargs={"hpcuserchangerequest": self.hpc_user_change_request.uuid},
)
good_users = [self.superuser, self.user_hpcadmin]
bad_users = [
self.user_owner,
self.user_delegate,
self.user_member,
self.user_member_other_group,
self.user,
]
self.assert_permissions_on_url(good_users, url, "GET", 200)
self.assert_permissions_on_url(bad_users, url, "GET", 302, redirect_url=reverse("home"))
def test_hpc_user_change_request_revision_view_post(self):
url = reverse(
"adminsec:hpcuserchangerequest-revision",
kwargs={"hpcuserchangerequest": self.hpc_user_change_request.uuid},
)
good_users = [self.superuser, self.user_hpcadmin]
bad_users = [
self.user_owner,
self.user_delegate,
self.user_member,
self.user_member_other_group,
self.user,
]
data = dict(HPCUSERCHANGEREQUEST_FORM_DATA_VALID)
def rollback_callback():
u = HpcUserChangeRequest.objects.last()
u.status = REQUEST_STATUS_ACTIVE
u.save()
self.assert_permissions_on_url(
good_users,
url,
"POST",
302,
req_kwargs=data,
redirect_url=reverse("adminsec:overview"),
rollback_callback=rollback_callback,
)
self.assert_permissions_on_url(
bad_users,
url,
"POST",
302,
req_kwargs=data,
redirect_url=reverse("home"),
)
def test_hpc_user_change_request_detail_view(self):
url = reverse(
"adminsec:hpcuserchangerequest-detail",
kwargs={"hpcuserchangerequest": self.hpc_user_change_request.uuid},
)
good_users = [self.superuser, self.user_hpcadmin]
bad_users = [
self.user_owner,
self.user_delegate,
self.user_member,
self.user_member_other_group,
self.user,
]
self.assert_permissions_on_url(good_users, url, "GET", 200)
self.assert_permissions_on_url(bad_users, url, "GET", 302, redirect_url=reverse("home"))
def test_hpc_project_create_request_approve_view_get(self):
url = reverse(
"adminsec:hpcprojectcreaterequest-approve",
kwargs={"hpcprojectcreaterequest": self.hpc_project_create_request.uuid},
)
good_users = [self.superuser, self.user_hpcadmin]
bad_users = [
self.user_owner,
self.user_delegate,
self.user_member,
self.user_member_other_group,
self.user,
]
self.assert_permissions_on_url(good_users, url, "GET", 200)
self.assert_permissions_on_url(bad_users, url, "GET", 302, redirect_url=reverse("home"))
def test_hpc_project_create_request_approve_view_post(self):
url = reverse(
"adminsec:hpcprojectcreaterequest-approve",
kwargs={"hpcprojectcreaterequest": self.hpc_project_create_request.uuid},
)
good_users = [self.superuser, self.user_hpcadmin]
bad_users = [
self.user_owner,
self.user_delegate,
self.user_member,
self.user_member_other_group,
self.user,
]
def rollback_callback():
u = HpcProjectCreateRequest.objects.last()
u.status = REQUEST_STATUS_ACTIVE
u.save()
HpcProject.objects.filter(name=self.hpc_project_create_request.name).delete()
self.assert_permissions_on_url(
good_users,
url,
"POST",
302,
redirect_url=reverse("adminsec:overview"),
rollback_callback=rollback_callback,
)
self.assert_permissions_on_url(bad_users, url, "POST", 302, redirect_url=reverse("home"))
def test_hpc_project_create_request_deny_view_get(self):
url = reverse(
"adminsec:hpcprojectcreaterequest-deny",
kwargs={"hpcprojectcreaterequest": self.hpc_project_create_request.uuid},
)
good_users = [self.superuser, self.user_hpcadmin]
bad_users = [
self.user_owner,
self.user_delegate,
self.user_member,
self.user_member_other_group,
self.user,
]
self.assert_permissions_on_url(good_users, url, "GET", 200)
self.assert_permissions_on_url(bad_users, url, "GET", 302, redirect_url=reverse("home"))
def test_hpc_project_create_request_deny_view_post(self):
url = reverse(
"adminsec:hpcprojectcreaterequest-deny",
kwargs={"hpcprojectcreaterequest": self.hpc_project_create_request.uuid},
)
data = {"comment": "Request denied!"}
good_users = [self.superuser, self.user_hpcadmin]
bad_users = [
self.user_owner,
self.user_delegate,
self.user_member,
self.user_member_other_group,
self.user,
]
def rollback_callback():
u = HpcProjectCreateRequest.objects.last()
u.status = REQUEST_STATUS_ACTIVE
u.save()
self.assert_permissions_on_url(
good_users,
url,
"POST",
302,
redirect_url=reverse("adminsec:overview"),
req_kwargs=data,
rollback_callback=rollback_callback,
)
self.assert_permissions_on_url(bad_users, url, "POST", 302, redirect_url=reverse("home"))
def test_hpc_project_create_request_revision_view_get(self):
url = reverse(
"adminsec:hpcprojectcreaterequest-revision",
kwargs={"hpcprojectcreaterequest": self.hpc_project_create_request.uuid},
)
good_users = [self.superuser, self.user_hpcadmin]
bad_users = [
self.user_owner,
self.user_delegate,
self.user_member,
self.user_member_other_group,
self.user,
]
self.assert_permissions_on_url(good_users, url, "GET", 200)
self.assert_permissions_on_url(bad_users, url, "GET", 302, redirect_url=reverse("home"))
def test_hpc_project_create_request_revision_view_post(self):
url = reverse(
"adminsec:hpcprojectcreaterequest-revision",
kwargs={"hpcprojectcreaterequest": self.hpc_project_create_request.uuid},
)
good_users = [self.superuser, self.user_hpcadmin]
bad_users = [
self.user_owner,
self.user_delegate,
self.user_member,
self.user_member_other_group,
self.user,
]
data = dict(HPCPROJECTCREATEREQUEST_FORM_DATA_VALID)
data["members"] = [m.id for m in self.hpc_project_create_request.members.all()]
def rollback_callback():
u = HpcProjectCreateRequest.objects.last()
u.status = REQUEST_STATUS_ACTIVE
u.save()
self.assert_permissions_on_url(
good_users,
url,
"POST",
302,
req_kwargs=data,
redirect_url=reverse("adminsec:overview"),
rollback_callback=rollback_callback,
)
self.assert_permissions_on_url(
bad_users,
url,
"POST",
302,
req_kwargs=data,
redirect_url=reverse("home"),
)
def test_hpc_project_create_request_detail_view(self):
url = reverse(
"adminsec:hpcprojectcreaterequest-detail",
kwargs={"hpcprojectcreaterequest": self.hpc_project_create_request.uuid},
)
good_users = [self.superuser, self.user_hpcadmin]
bad_users = [
self.user_owner,
self.user_delegate,
self.user_member,
self.user_member_other_group,
self.user,
]
self.assert_permissions_on_url(good_users, url, "GET", 200)
self.assert_permissions_on_url(bad_users, url, "GET", 302, redirect_url=reverse("home"))
| 34.314969 | 97 | 0.604738 | 3,453 | 33,011 | 5.415291 | 0.032146 | 0.103107 | 0.059896 | 0.095941 | 0.921547 | 0.911653 | 0.904647 | 0.898551 | 0.887962 | 0.881758 | 0 | 0.010198 | 0.304929 | 33,011 | 961 | 98 | 34.350676 | 0.80475 | 0.00206 | 0 | 0.765461 | 0 | 0 | 0.093496 | 0.058545 | 0 | 0 | 0 | 0 | 0.095683 | 1 | 0.066511 | false | 0 | 0.007001 | 0 | 0.075846 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 1 | 1 | 1 | 1 | 1 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 7 |
3a15c760a4dffb39c26f3ae635350887ce29e2b8 | 1,544 | py | Python | HDFN_photz.py | deapplegate/wtgpipeline | 9693e8562022cc97bf5a96427e22965e1a5e8497 | [
"MIT"
] | 1 | 2019-03-15T04:01:19.000Z | 2019-03-15T04:01:19.000Z | HDFN_photz.py | deapplegate/wtgpipeline | 9693e8562022cc97bf5a96427e22965e1a5e8497 | [
"MIT"
] | 5 | 2017-12-11T00:11:39.000Z | 2021-07-09T17:05:16.000Z | HDFN_photz.py | deapplegate/wtgpipeline | 9693e8562022cc97bf5a96427e22965e1a5e8497 | [
"MIT"
] | 2 | 2017-08-15T21:19:11.000Z | 2017-10-12T00:36:35.000Z | import os
#os.system('python $BPZPATH/bpz.py HDFN.cat -COLUMNS HDFN.columns -MAG yes -PRIOR hdfn_SB -ZMAX 4.0 -INTERP 8 -SPECTRA CWWSB_capak.list')
import cutout_bpz
#os.system('python $BPZPATH/bpz.py HDFN.cat -OUTPUT BVR.bpz -COLUMNS BVR.columns -MAG yes -PRIOR hdfn_SB -ZMAX 4.0 -INTERP 8 -SPECTRA CWWSB_capak.list')
#cutout_bpz.plot_res('BVR.bpz','BVR')
#os.system('python $BPZPATH/bpz.py HDFN.cat -OUTPUT VRI.bpz -COLUMNS VRI.columns -MAG yes -PRIOR hdfn_SB -ZMAX 4.0 -INTERP 8 -SPECTRA CWWSB_capak.list')
#cutout_bpz.plot_res('VRI.bpz','VRI')
#raw_input()
#os.system('python $BPZPATH/bpz.py HDFN.cat -OUTPUT BVRI.bpz -COLUMNS BVRI.columns -MAG yes -PRIOR hdfn_SB -ZMAX 4.0 -INTERP 8 -SPECTRA CWWSB_capak.list')
#cutout_bpz.plot_res('BVRI.bpz','BVRI')
#os.system('python $BPZPATH/bpz.py HDFN.cat -OUTPUT BVIz.bpz -COLUMNS BVIz.columns -MAG yes -PRIOR hdfn_SB -ZMAX 4.0 -INTERP 8 -SPECTRA CWWSB_capak.list')
#cutout_bpz.plot_res('BVIz.bpz','BVIz')
#os.system('python $BPZPATH/bpz.py HDFN.cat -OUTPUT VRIz.bpz -COLUMNS VRIz.columns -MAG yes -PRIOR hdfn_SB -ZMAX 4.0 -INTERP 8 -SPECTRA CWWSB_capak.list')
#cutout_bpz.plot_res('VRIz.bpz','VRIz')
#os.system('python $BPZPATH/bpz.py HDFN.cat -OUTPUT BVRIz.bpz -COLUMNS BVRIz.columns -MAG yes -PRIOR hdfn_SB -ZMAX 4.0 -INTERP 8 -SPECTRA CWWSB_capak.list')
#cutout_bpz.plot_res('BVRIz.bpz','BVRIz')
os.system('python $BPZPATH/bpz.py HDFN.cat -OUTPUT BVRI.bpz -COLUMNS BVRI.columns -MAG yes -PRIOR hdfn_SB -ZMAX 4.0 -INTERP 8 -SPECTRA CWWSB_capak.list')
cutout_bpz.plot_res('BVRI.bpz','BVRI')
| 61.76 | 156 | 0.748057 | 277 | 1,544 | 4.054152 | 0.126354 | 0.05699 | 0.099733 | 0.149599 | 0.837044 | 0.837044 | 0.837044 | 0.837044 | 0.807658 | 0.634016 | 0 | 0.017241 | 0.098446 | 1,544 | 24 | 157 | 64.333333 | 0.789511 | 0.834845 | 0 | 0 | 0 | 0.25 | 0.630705 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | true | 0 | 0.5 | 0 | 0.5 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 1 | 1 | 1 | 1 | 1 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | 1 | 1 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 1 | 0 | 0 | 0 | 0 | 11 |
28d8b8b3e0c59dcfe75f70d7fdf536610705fa41 | 9,412 | py | Python | training/utils_train.py | roinaveiro/aml_bayes | 03e7ef15ba7a260e51dbace68001f88e16cad394 | [
"MIT"
] | 2 | 2021-12-23T10:25:33.000Z | 2021-12-23T17:04:28.000Z | training/utils_train.py | roinaveiro/aml_bayes | 03e7ef15ba7a260e51dbace68001f88e16cad394 | [
"MIT"
] | null | null | null | training/utils_train.py | roinaveiro/aml_bayes | 03e7ef15ba7a260e51dbace68001f88e16cad394 | [
"MIT"
] | null | null | null | import torch
import torch.nn as nn
import torch.nn.functional as F
import torch.optim as optim
from torchvision import datasets, transforms
import torchvision
from optimizers import fgsmm
import numpy as np
def get_data_loaders(batch_size, test_batch_size):
train_loader = torch.utils.data.DataLoader(
datasets.KMNIST('../data', train=True, download=True,
transform=transforms.Compose([
transforms.ToTensor(),
transforms.Normalize((0.1307,), (0.3081,))
])),
batch_size=batch_size, shuffle=True)
test_loader = torch.utils.data.DataLoader(
datasets.KMNIST('../data', train=False, transform=transforms.Compose([
transforms.ToTensor(),
transforms.Normalize((0.1307,), (0.3081,))
])),
batch_size=test_batch_size, shuffle=True)
return train_loader, test_loader
def get_data_loaders_cifar(batch_size, test_batch_size):
transform = transforms.Compose(
[transforms.ToTensor(),
transforms.Normalize((0.5, 0.5, 0.5), (0.5, 0.5, 0.5))])
batch_size = 4
trainset = torchvision.datasets.CIFAR10(root='./data', train=True,
download=True, transform=transform)
trainloader = torch.utils.data.DataLoader(trainset, batch_size=batch_size,
shuffle=True, num_workers=2)
testset = torchvision.datasets.CIFAR10(root='./data', train=False,
download=True, transform=transform)
testloader = torch.utils.data.DataLoader(testset, batch_size=batch_size,
shuffle=False, num_workers=2)
return trainloader, testloader
def train(model, device, train_loader, optimizer, epoch, train_losses):
model.train()
for batch_idx, (data, target) in enumerate(train_loader):
data, target = data.to(device), target.to(device)
optimizer.zero_grad()
output = model(data)
loss = F.nll_loss(output, target)
loss.backward()
optimizer.step()
if batch_idx % 1000 == 0:
print('Train Epoch: {} [{}/{} ({:.0f}%)]\tLoss: {:.6f}'.format(
epoch, batch_idx * len(data), len(train_loader.dataset),
100. * batch_idx / len(train_loader), loss.item()))
train_losses.append(loss.item())
def train_at(model, device, train_loader, optimizer, epoch, train_losses):
model.train()
for batch_idx, (data, target) in enumerate(train_loader):
data, target = data.to(device), target.to(device)
optimizer.zero_grad()
data.requires_grad_(True)
v = torch.zeros_like(data)
xv = (data, v)
def adv_loss(x, y = target):
return -F.nll_loss(model(x), y)
xx, mmsgf = fgsmm(adv_loss, xv, T = 1, lr = 0.075, gamma = 0.)
output = model(torch.cat((data,xx[0]), 0))
loss = F.nll_loss(output, torch.cat((target, target), 0))
loss.backward()
optimizer.step()
if batch_idx % 1000 == 0:
print('Train Epoch: {} [{}/{} ({:.0f}%)]\tLoss: {:.6f}'.format(
epoch, batch_idx * len(data), len(train_loader.dataset),
100. * batch_idx / len(train_loader), loss.item()))
train_losses.append(loss.item())
def train_alp(model, device, train_loader, optimizer, epoch, train_losses):
model.train()
for batch_idx, (data, target) in enumerate(train_loader):
data, target = data.to(device), target.to(device)
optimizer.zero_grad()
data.requires_grad_(True)
v = torch.zeros_like(data)
xv = (data, v)
def adv_loss(x, y = target):
return -F.nll_loss(model(x), y)
xx, mmsgf = fgsmm(adv_loss, xv, T = 1, lr = 0.075, gamma = 0.)
output = model(data)
loss = F.nll_loss(output, target) + torch.mean(torch.abs(model.logits(data) - model.logits(xx[0])))
loss.backward()
optimizer.step()
if batch_idx % 1000 == 0:
print('Train Epoch: {} [{}/{} ({:.0f}%)]\tLoss: {:.6f}'.format(
epoch, batch_idx * len(data), len(train_loader.dataset),
100. * batch_idx / len(train_loader), loss.item()))
train_losses.append(loss.item())
def train_atpx(model, device, train_loader, optimizer, epoch, train_losses):
model.train()
def energy(x):
return -torch.logsumexp(model.logits(x), dim=1)
for batch_idx, (data, target) in enumerate(train_loader):
data, target = data.to(device), target.to(device)
optimizer.zero_grad()
data.requires_grad_(True)
v = torch.zeros_like(data)
xv = (data, v)
def adv_loss(x, y = target):
return -F.nll_loss(model(x), y)
xx, mmsgf = fgsmm(adv_loss, xv, T = 1, lr = 0.075, gamma = 0.)
output = model(torch.cat((data,xx[0]), 0))
loss = F.nll_loss(output, torch.cat((target, target), 0)) + torch.abs(energy(xx[0]).mean() - energy(data).mean())
loss.backward()
optimizer.step()
if batch_idx % 1000 == 0:
print('Train Epoch: {} [{}/{} ({:.0f}%)]\tLoss: {:.6f}'.format(
epoch, batch_idx * len(data), len(train_loader.dataset),
100. * batch_idx / len(train_loader), loss.item()))
train_losses.append(loss.item())
def train_ara(model, device, train_loader, optimizer, epoch, train_losses):
model.train()
for batch_idx, (data, target) in enumerate(train_loader):
data, target = data.to(device), target.to(device)
optimizer.zero_grad()
data.requires_grad_(True)
v = torch.zeros_like(data)
xv = (data, v)
def adv_loss(x, y = target):
return -F.nll_loss(model(x), y)
xxs = []
N = 1
# To do N > 1, we would have to use a Bayesian model to avoid overfitting.
for _ in range(N):
T = 1 + np.random.poisson(1)
#T = 5
lr_min, lr_max = 0.05, 0.15
lr_a = np.random.beta(1, 1)*(lr_max - lr_min) + lr_min
#lr = 0.05
gamma = 0.0
xx, mmsgf = fgsmm(adv_loss, xv, T = T, lr = lr_a, gamma = gamma)
xxs.append(xx[0])
xx = torch.cat(tuple(xxs), 0)
output = model(torch.cat((data,xx), 0))
loss = F.nll_loss(output, torch.cat((target, target.repeat(N)), 0))
loss.backward()
optimizer.step()
if batch_idx % 1000 == 0:
print('Train Epoch: {} [{}/{} ({:.0f}%)]\tLoss: {:.6f}'.format(
epoch, batch_idx * len(data), len(train_loader.dataset),
100. * batch_idx / len(train_loader), loss.item()))
train_losses.append(loss.item())
def train_arapx(model, device, train_loader, optimizer, epoch, train_losses):
def energy(x):
return -torch.logsumexp(model.logits(x), dim=1)
model.train()
for batch_idx, (data, target) in enumerate(train_loader):
data, target = data.to(device), target.to(device)
optimizer.zero_grad()
data.requires_grad_(True)
v = torch.zeros_like(data)
xv = (data, v)
def adv_loss(x, y = target):
return -F.nll_loss(model(x), y)
xxs = []
N = 1
# To do N > 1, we would have to use a Bayesian model to avoid overfitting.
for _ in range(N):
T = 1 + np.random.poisson(1)
#T = 5
lr_min, lr_max = 0.05, 0.15
lr_a = np.random.beta(1, 1)*(lr_max - lr_min) + lr_min
#lr = 0.05
gamma = 0.0
xx, mmsgf = fgsmm(adv_loss, xv, T = T, lr = lr_a, gamma = gamma)
xxs.append(xx[0])
xx = torch.cat(tuple(xxs), 0)
output = model(torch.cat((data,xx), 0))
loss = F.nll_loss(output, torch.cat((target, target.repeat(N)), 0)) + torch.abs(energy(xx).mean() - energy(data).mean())
loss.backward()
optimizer.step()
if batch_idx % 1000 == 0:
print('Train Epoch: {} [{}/{} ({:.0f}%)]\tLoss: {:.6f}'.format(
epoch, batch_idx * len(data), len(train_loader.dataset),
100. * batch_idx / len(train_loader), loss.item()))
train_losses.append(loss.item())
def test(model, device, test_loader):
model.eval()
test_loss = 0
correct = 0
with torch.no_grad():
for data, target in test_loader:
data, target = data.to(device), target.to(device)
output = model(data)
test_loss += F.nll_loss(output, target, reduction='sum').item() # sum up batch loss
pred = output.argmax(dim=1, keepdim=True) # get the index of the max log-probability
correct += pred.eq(target.view_as(pred)).sum().item()
test_loss /= len(test_loader.dataset)
print('\nTest set: Average loss: {:.4f}, Accuracy: {}/{} ({:.0f}%)\n'.format(
test_loss, correct, len(test_loader.dataset),
100. * correct / len(test_loader.dataset))) | 37.951613 | 128 | 0.551742 | 1,187 | 9,412 | 4.238416 | 0.127211 | 0.056848 | 0.019082 | 0.027827 | 0.829457 | 0.796064 | 0.757901 | 0.757901 | 0.736037 | 0.693302 | 0 | 0.027446 | 0.307055 | 9,412 | 248 | 129 | 37.951613 | 0.743944 | 0.024649 | 0 | 0.712766 | 0 | 0 | 0.040558 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0.085106 | false | 0 | 0.042553 | 0.037234 | 0.175532 | 0.037234 | 0 | 0 | 0 | null | 0 | 0 | 0 | 1 | 1 | 1 | 1 | 1 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 7 |
28eab3428dd486021f360201c462b6508035ce73 | 114,827 | py | Python | angr/procedures/definitions/win32_winspool.py | r4b3rt/angr | c133cfd4f83ffea2a1d9e064241e9459eaabc55f | [
"BSD-2-Clause"
] | null | null | null | angr/procedures/definitions/win32_winspool.py | r4b3rt/angr | c133cfd4f83ffea2a1d9e064241e9459eaabc55f | [
"BSD-2-Clause"
] | null | null | null | angr/procedures/definitions/win32_winspool.py | r4b3rt/angr | c133cfd4f83ffea2a1d9e064241e9459eaabc55f | [
"BSD-2-Clause"
] | null | null | null | # pylint:disable=line-too-long
import logging
from ...sim_type import SimTypeFunction, SimTypeShort, SimTypeInt, SimTypeLong, SimTypeLongLong, SimTypeDouble, SimTypeFloat, SimTypePointer, SimTypeChar, SimStruct, SimTypeFixedSizeArray, SimTypeBottom, SimUnion, SimTypeBool
from ...calling_conventions import SimCCStdcall, SimCCMicrosoftAMD64
from .. import SIM_PROCEDURES as P
from . import SimLibrary
_l = logging.getLogger(name=__name__)
lib = SimLibrary()
lib.set_default_cc('X86', SimCCStdcall)
lib.set_default_cc('AMD64', SimCCMicrosoftAMD64)
lib.set_library_names("winspool.dll")
prototypes = \
{
#
'EnumPrintersA': SimTypeFunction([SimTypeInt(signed=False, label="UInt32"), SimTypePointer(SimTypeChar(label="Byte"), offset=0), SimTypeInt(signed=False, label="UInt32"), SimTypePointer(SimTypeChar(label="Byte"), offset=0), SimTypeInt(signed=False, label="UInt32"), SimTypePointer(SimTypeInt(signed=False, label="UInt32"), offset=0), SimTypePointer(SimTypeInt(signed=False, label="UInt32"), offset=0)], SimTypeInt(signed=True, label="Int32"), arg_names=["Flags", "Name", "Level", "pPrinterEnum", "cbBuf", "pcbNeeded", "pcReturned"]),
#
'EnumPrintersW': SimTypeFunction([SimTypeInt(signed=False, label="UInt32"), SimTypePointer(SimTypeChar(label="Char"), offset=0), SimTypeInt(signed=False, label="UInt32"), SimTypePointer(SimTypeChar(label="Byte"), offset=0), SimTypeInt(signed=False, label="UInt32"), SimTypePointer(SimTypeInt(signed=False, label="UInt32"), offset=0), SimTypePointer(SimTypeInt(signed=False, label="UInt32"), offset=0)], SimTypeInt(signed=True, label="Int32"), arg_names=["Flags", "Name", "Level", "pPrinterEnum", "cbBuf", "pcbNeeded", "pcReturned"]),
#
'GetSpoolFileHandle': SimTypeFunction([SimTypePointer(SimTypeInt(signed=True, label="Int"), label="IntPtr", offset=0)], SimTypePointer(SimTypeInt(signed=True, label="Int"), label="IntPtr", offset=0), arg_names=["hPrinter"]),
#
'CommitSpoolData': SimTypeFunction([SimTypePointer(SimTypeInt(signed=True, label="Int"), label="IntPtr", offset=0), SimTypePointer(SimTypeInt(signed=True, label="Int"), label="IntPtr", offset=0), SimTypeInt(signed=False, label="UInt32")], SimTypePointer(SimTypeInt(signed=True, label="Int"), label="IntPtr", offset=0), arg_names=["hPrinter", "hSpoolFile", "cbCommit"]),
#
'CloseSpoolFileHandle': SimTypeFunction([SimTypePointer(SimTypeInt(signed=True, label="Int"), label="IntPtr", offset=0), SimTypePointer(SimTypeInt(signed=True, label="Int"), label="IntPtr", offset=0)], SimTypeInt(signed=True, label="Int32"), arg_names=["hPrinter", "hSpoolFile"]),
#
'OpenPrinterA': SimTypeFunction([SimTypePointer(SimTypeChar(label="Byte"), offset=0), SimTypePointer(SimTypePointer(SimTypeInt(signed=True, label="Int"), label="IntPtr", offset=0), offset=0), SimTypePointer(SimStruct({"pDatatype": SimTypePointer(SimTypeChar(label="Byte"), offset=0), "pDevMode": SimTypePointer(SimTypeBottom(label="DEVMODEA"), offset=0), "DesiredAccess": SimTypeInt(signed=False, label="UInt32")}, name="PRINTER_DEFAULTSA", pack=False, align=None), offset=0)], SimTypeInt(signed=True, label="Int32"), arg_names=["pPrinterName", "phPrinter", "pDefault"]),
#
'OpenPrinterW': SimTypeFunction([SimTypePointer(SimTypeChar(label="Char"), offset=0), SimTypePointer(SimTypePointer(SimTypeInt(signed=True, label="Int"), label="IntPtr", offset=0), offset=0), SimTypePointer(SimStruct({"pDatatype": SimTypePointer(SimTypeChar(label="Char"), offset=0), "pDevMode": SimTypePointer(SimTypeBottom(label="DEVMODEW"), offset=0), "DesiredAccess": SimTypeInt(signed=False, label="UInt32")}, name="PRINTER_DEFAULTSW", pack=False, align=None), offset=0)], SimTypeInt(signed=True, label="Int32"), arg_names=["pPrinterName", "phPrinter", "pDefault"]),
#
'ResetPrinterA': SimTypeFunction([SimTypePointer(SimTypeInt(signed=True, label="Int"), label="IntPtr", offset=0), SimTypePointer(SimStruct({"pDatatype": SimTypePointer(SimTypeChar(label="Byte"), offset=0), "pDevMode": SimTypePointer(SimTypeBottom(label="DEVMODEA"), offset=0), "DesiredAccess": SimTypeInt(signed=False, label="UInt32")}, name="PRINTER_DEFAULTSA", pack=False, align=None), offset=0)], SimTypeInt(signed=True, label="Int32"), arg_names=["hPrinter", "pDefault"]),
#
'ResetPrinterW': SimTypeFunction([SimTypePointer(SimTypeInt(signed=True, label="Int"), label="IntPtr", offset=0), SimTypePointer(SimStruct({"pDatatype": SimTypePointer(SimTypeChar(label="Char"), offset=0), "pDevMode": SimTypePointer(SimTypeBottom(label="DEVMODEW"), offset=0), "DesiredAccess": SimTypeInt(signed=False, label="UInt32")}, name="PRINTER_DEFAULTSW", pack=False, align=None), offset=0)], SimTypeInt(signed=True, label="Int32"), arg_names=["hPrinter", "pDefault"]),
#
'SetJobA': SimTypeFunction([SimTypePointer(SimTypeInt(signed=True, label="Int"), label="IntPtr", offset=0), SimTypeInt(signed=False, label="UInt32"), SimTypeInt(signed=False, label="UInt32"), SimTypePointer(SimTypeChar(label="Byte"), offset=0), SimTypeInt(signed=False, label="UInt32")], SimTypeInt(signed=True, label="Int32"), arg_names=["hPrinter", "JobId", "Level", "pJob", "Command"]),
#
'SetJobW': SimTypeFunction([SimTypePointer(SimTypeInt(signed=True, label="Int"), label="IntPtr", offset=0), SimTypeInt(signed=False, label="UInt32"), SimTypeInt(signed=False, label="UInt32"), SimTypePointer(SimTypeChar(label="Byte"), offset=0), SimTypeInt(signed=False, label="UInt32")], SimTypeInt(signed=True, label="Int32"), arg_names=["hPrinter", "JobId", "Level", "pJob", "Command"]),
#
'GetJobA': SimTypeFunction([SimTypePointer(SimTypeInt(signed=True, label="Int"), label="IntPtr", offset=0), SimTypeInt(signed=False, label="UInt32"), SimTypeInt(signed=False, label="UInt32"), SimTypePointer(SimTypeChar(label="Byte"), offset=0), SimTypeInt(signed=False, label="UInt32"), SimTypePointer(SimTypeInt(signed=False, label="UInt32"), offset=0)], SimTypeInt(signed=True, label="Int32"), arg_names=["hPrinter", "JobId", "Level", "pJob", "cbBuf", "pcbNeeded"]),
#
'GetJobW': SimTypeFunction([SimTypePointer(SimTypeInt(signed=True, label="Int"), label="IntPtr", offset=0), SimTypeInt(signed=False, label="UInt32"), SimTypeInt(signed=False, label="UInt32"), SimTypePointer(SimTypeChar(label="Byte"), offset=0), SimTypeInt(signed=False, label="UInt32"), SimTypePointer(SimTypeInt(signed=False, label="UInt32"), offset=0)], SimTypeInt(signed=True, label="Int32"), arg_names=["hPrinter", "JobId", "Level", "pJob", "cbBuf", "pcbNeeded"]),
#
'EnumJobsA': SimTypeFunction([SimTypePointer(SimTypeInt(signed=True, label="Int"), label="IntPtr", offset=0), SimTypeInt(signed=False, label="UInt32"), SimTypeInt(signed=False, label="UInt32"), SimTypeInt(signed=False, label="UInt32"), SimTypePointer(SimTypeChar(label="Byte"), offset=0), SimTypeInt(signed=False, label="UInt32"), SimTypePointer(SimTypeInt(signed=False, label="UInt32"), offset=0), SimTypePointer(SimTypeInt(signed=False, label="UInt32"), offset=0)], SimTypeInt(signed=True, label="Int32"), arg_names=["hPrinter", "FirstJob", "NoJobs", "Level", "pJob", "cbBuf", "pcbNeeded", "pcReturned"]),
#
'EnumJobsW': SimTypeFunction([SimTypePointer(SimTypeInt(signed=True, label="Int"), label="IntPtr", offset=0), SimTypeInt(signed=False, label="UInt32"), SimTypeInt(signed=False, label="UInt32"), SimTypeInt(signed=False, label="UInt32"), SimTypePointer(SimTypeChar(label="Byte"), offset=0), SimTypeInt(signed=False, label="UInt32"), SimTypePointer(SimTypeInt(signed=False, label="UInt32"), offset=0), SimTypePointer(SimTypeInt(signed=False, label="UInt32"), offset=0)], SimTypeInt(signed=True, label="Int32"), arg_names=["hPrinter", "FirstJob", "NoJobs", "Level", "pJob", "cbBuf", "pcbNeeded", "pcReturned"]),
#
'AddPrinterA': SimTypeFunction([SimTypePointer(SimTypeChar(label="Byte"), offset=0), SimTypeInt(signed=False, label="UInt32"), SimTypePointer(SimTypeChar(label="Byte"), offset=0)], SimTypePointer(SimTypeInt(signed=True, label="Int"), label="IntPtr", offset=0), arg_names=["pName", "Level", "pPrinter"]),
#
'AddPrinterW': SimTypeFunction([SimTypePointer(SimTypeChar(label="Char"), offset=0), SimTypeInt(signed=False, label="UInt32"), SimTypePointer(SimTypeChar(label="Byte"), offset=0)], SimTypePointer(SimTypeInt(signed=True, label="Int"), label="IntPtr", offset=0), arg_names=["pName", "Level", "pPrinter"]),
#
'DeletePrinter': SimTypeFunction([SimTypePointer(SimTypeInt(signed=True, label="Int"), label="IntPtr", offset=0)], SimTypeInt(signed=True, label="Int32"), arg_names=["hPrinter"]),
#
'SetPrinterA': SimTypeFunction([SimTypePointer(SimTypeInt(signed=True, label="Int"), label="IntPtr", offset=0), SimTypeInt(signed=False, label="UInt32"), SimTypePointer(SimTypeChar(label="Byte"), offset=0), SimTypeInt(signed=False, label="UInt32")], SimTypeInt(signed=True, label="Int32"), arg_names=["hPrinter", "Level", "pPrinter", "Command"]),
#
'SetPrinterW': SimTypeFunction([SimTypePointer(SimTypeInt(signed=True, label="Int"), label="IntPtr", offset=0), SimTypeInt(signed=False, label="UInt32"), SimTypePointer(SimTypeChar(label="Byte"), offset=0), SimTypeInt(signed=False, label="UInt32")], SimTypeInt(signed=True, label="Int32"), arg_names=["hPrinter", "Level", "pPrinter", "Command"]),
#
'GetPrinterA': SimTypeFunction([SimTypePointer(SimTypeInt(signed=True, label="Int"), label="IntPtr", offset=0), SimTypeInt(signed=False, label="UInt32"), SimTypePointer(SimTypeChar(label="Byte"), offset=0), SimTypeInt(signed=False, label="UInt32"), SimTypePointer(SimTypeInt(signed=False, label="UInt32"), offset=0)], SimTypeInt(signed=True, label="Int32"), arg_names=["hPrinter", "Level", "pPrinter", "cbBuf", "pcbNeeded"]),
#
'GetPrinterW': SimTypeFunction([SimTypePointer(SimTypeInt(signed=True, label="Int"), label="IntPtr", offset=0), SimTypeInt(signed=False, label="UInt32"), SimTypePointer(SimTypeChar(label="Byte"), offset=0), SimTypeInt(signed=False, label="UInt32"), SimTypePointer(SimTypeInt(signed=False, label="UInt32"), offset=0)], SimTypeInt(signed=True, label="Int32"), arg_names=["hPrinter", "Level", "pPrinter", "cbBuf", "pcbNeeded"]),
#
'AddPrinterDriverA': SimTypeFunction([SimTypePointer(SimTypeChar(label="Byte"), offset=0), SimTypeInt(signed=False, label="UInt32"), SimTypePointer(SimTypeChar(label="Byte"), offset=0)], SimTypeInt(signed=True, label="Int32"), arg_names=["pName", "Level", "pDriverInfo"]),
#
'AddPrinterDriverW': SimTypeFunction([SimTypePointer(SimTypeChar(label="Char"), offset=0), SimTypeInt(signed=False, label="UInt32"), SimTypePointer(SimTypeChar(label="Byte"), offset=0)], SimTypeInt(signed=True, label="Int32"), arg_names=["pName", "Level", "pDriverInfo"]),
#
'AddPrinterDriverExA': SimTypeFunction([SimTypePointer(SimTypeChar(label="Byte"), offset=0), SimTypeInt(signed=False, label="UInt32"), SimTypePointer(SimTypeChar(label="Byte"), offset=0), SimTypeInt(signed=False, label="UInt32")], SimTypeInt(signed=True, label="Int32"), arg_names=["pName", "Level", "lpbDriverInfo", "dwFileCopyFlags"]),
#
'AddPrinterDriverExW': SimTypeFunction([SimTypePointer(SimTypeChar(label="Char"), offset=0), SimTypeInt(signed=False, label="UInt32"), SimTypePointer(SimTypeChar(label="Byte"), offset=0), SimTypeInt(signed=False, label="UInt32")], SimTypeInt(signed=True, label="Int32"), arg_names=["pName", "Level", "lpbDriverInfo", "dwFileCopyFlags"]),
#
'EnumPrinterDriversA': SimTypeFunction([SimTypePointer(SimTypeChar(label="Byte"), offset=0), SimTypePointer(SimTypeChar(label="Byte"), offset=0), SimTypeInt(signed=False, label="UInt32"), SimTypePointer(SimTypeChar(label="Byte"), offset=0), SimTypeInt(signed=False, label="UInt32"), SimTypePointer(SimTypeInt(signed=False, label="UInt32"), offset=0), SimTypePointer(SimTypeInt(signed=False, label="UInt32"), offset=0)], SimTypeInt(signed=True, label="Int32"), arg_names=["pName", "pEnvironment", "Level", "pDriverInfo", "cbBuf", "pcbNeeded", "pcReturned"]),
#
'EnumPrinterDriversW': SimTypeFunction([SimTypePointer(SimTypeChar(label="Char"), offset=0), SimTypePointer(SimTypeChar(label="Char"), offset=0), SimTypeInt(signed=False, label="UInt32"), SimTypePointer(SimTypeChar(label="Byte"), offset=0), SimTypeInt(signed=False, label="UInt32"), SimTypePointer(SimTypeInt(signed=False, label="UInt32"), offset=0), SimTypePointer(SimTypeInt(signed=False, label="UInt32"), offset=0)], SimTypeInt(signed=True, label="Int32"), arg_names=["pName", "pEnvironment", "Level", "pDriverInfo", "cbBuf", "pcbNeeded", "pcReturned"]),
#
'GetPrinterDriverA': SimTypeFunction([SimTypePointer(SimTypeInt(signed=True, label="Int"), label="IntPtr", offset=0), SimTypePointer(SimTypeChar(label="Byte"), offset=0), SimTypeInt(signed=False, label="UInt32"), SimTypePointer(SimTypeChar(label="Byte"), offset=0), SimTypeInt(signed=False, label="UInt32"), SimTypePointer(SimTypeInt(signed=False, label="UInt32"), offset=0)], SimTypeInt(signed=True, label="Int32"), arg_names=["hPrinter", "pEnvironment", "Level", "pDriverInfo", "cbBuf", "pcbNeeded"]),
#
'GetPrinterDriverW': SimTypeFunction([SimTypePointer(SimTypeInt(signed=True, label="Int"), label="IntPtr", offset=0), SimTypePointer(SimTypeChar(label="Char"), offset=0), SimTypeInt(signed=False, label="UInt32"), SimTypePointer(SimTypeChar(label="Byte"), offset=0), SimTypeInt(signed=False, label="UInt32"), SimTypePointer(SimTypeInt(signed=False, label="UInt32"), offset=0)], SimTypeInt(signed=True, label="Int32"), arg_names=["hPrinter", "pEnvironment", "Level", "pDriverInfo", "cbBuf", "pcbNeeded"]),
#
'GetPrinterDriverDirectoryA': SimTypeFunction([SimTypePointer(SimTypeChar(label="Byte"), offset=0), SimTypePointer(SimTypeChar(label="Byte"), offset=0), SimTypeInt(signed=False, label="UInt32"), SimTypePointer(SimTypeChar(label="Byte"), offset=0), SimTypeInt(signed=False, label="UInt32"), SimTypePointer(SimTypeInt(signed=False, label="UInt32"), offset=0)], SimTypeInt(signed=True, label="Int32"), arg_names=["pName", "pEnvironment", "Level", "pDriverDirectory", "cbBuf", "pcbNeeded"]),
#
'GetPrinterDriverDirectoryW': SimTypeFunction([SimTypePointer(SimTypeChar(label="Char"), offset=0), SimTypePointer(SimTypeChar(label="Char"), offset=0), SimTypeInt(signed=False, label="UInt32"), SimTypePointer(SimTypeChar(label="Byte"), offset=0), SimTypeInt(signed=False, label="UInt32"), SimTypePointer(SimTypeInt(signed=False, label="UInt32"), offset=0)], SimTypeInt(signed=True, label="Int32"), arg_names=["pName", "pEnvironment", "Level", "pDriverDirectory", "cbBuf", "pcbNeeded"]),
#
'DeletePrinterDriverA': SimTypeFunction([SimTypePointer(SimTypeChar(label="Byte"), offset=0), SimTypePointer(SimTypeChar(label="Byte"), offset=0), SimTypePointer(SimTypeChar(label="Byte"), offset=0)], SimTypeInt(signed=True, label="Int32"), arg_names=["pName", "pEnvironment", "pDriverName"]),
#
'DeletePrinterDriverW': SimTypeFunction([SimTypePointer(SimTypeChar(label="Char"), offset=0), SimTypePointer(SimTypeChar(label="Char"), offset=0), SimTypePointer(SimTypeChar(label="Char"), offset=0)], SimTypeInt(signed=True, label="Int32"), arg_names=["pName", "pEnvironment", "pDriverName"]),
#
'DeletePrinterDriverExA': SimTypeFunction([SimTypePointer(SimTypeChar(label="Byte"), offset=0), SimTypePointer(SimTypeChar(label="Byte"), offset=0), SimTypePointer(SimTypeChar(label="Byte"), offset=0), SimTypeInt(signed=False, label="UInt32"), SimTypeInt(signed=False, label="UInt32")], SimTypeInt(signed=True, label="Int32"), arg_names=["pName", "pEnvironment", "pDriverName", "dwDeleteFlag", "dwVersionFlag"]),
#
'DeletePrinterDriverExW': SimTypeFunction([SimTypePointer(SimTypeChar(label="Char"), offset=0), SimTypePointer(SimTypeChar(label="Char"), offset=0), SimTypePointer(SimTypeChar(label="Char"), offset=0), SimTypeInt(signed=False, label="UInt32"), SimTypeInt(signed=False, label="UInt32")], SimTypeInt(signed=True, label="Int32"), arg_names=["pName", "pEnvironment", "pDriverName", "dwDeleteFlag", "dwVersionFlag"]),
#
'AddPrintProcessorA': SimTypeFunction([SimTypePointer(SimTypeChar(label="Byte"), offset=0), SimTypePointer(SimTypeChar(label="Byte"), offset=0), SimTypePointer(SimTypeChar(label="Byte"), offset=0), SimTypePointer(SimTypeChar(label="Byte"), offset=0)], SimTypeInt(signed=True, label="Int32"), arg_names=["pName", "pEnvironment", "pPathName", "pPrintProcessorName"]),
#
'AddPrintProcessorW': SimTypeFunction([SimTypePointer(SimTypeChar(label="Char"), offset=0), SimTypePointer(SimTypeChar(label="Char"), offset=0), SimTypePointer(SimTypeChar(label="Char"), offset=0), SimTypePointer(SimTypeChar(label="Char"), offset=0)], SimTypeInt(signed=True, label="Int32"), arg_names=["pName", "pEnvironment", "pPathName", "pPrintProcessorName"]),
#
'EnumPrintProcessorsA': SimTypeFunction([SimTypePointer(SimTypeChar(label="Byte"), offset=0), SimTypePointer(SimTypeChar(label="Byte"), offset=0), SimTypeInt(signed=False, label="UInt32"), SimTypePointer(SimTypeChar(label="Byte"), offset=0), SimTypeInt(signed=False, label="UInt32"), SimTypePointer(SimTypeInt(signed=False, label="UInt32"), offset=0), SimTypePointer(SimTypeInt(signed=False, label="UInt32"), offset=0)], SimTypeInt(signed=True, label="Int32"), arg_names=["pName", "pEnvironment", "Level", "pPrintProcessorInfo", "cbBuf", "pcbNeeded", "pcReturned"]),
#
'EnumPrintProcessorsW': SimTypeFunction([SimTypePointer(SimTypeChar(label="Char"), offset=0), SimTypePointer(SimTypeChar(label="Char"), offset=0), SimTypeInt(signed=False, label="UInt32"), SimTypePointer(SimTypeChar(label="Byte"), offset=0), SimTypeInt(signed=False, label="UInt32"), SimTypePointer(SimTypeInt(signed=False, label="UInt32"), offset=0), SimTypePointer(SimTypeInt(signed=False, label="UInt32"), offset=0)], SimTypeInt(signed=True, label="Int32"), arg_names=["pName", "pEnvironment", "Level", "pPrintProcessorInfo", "cbBuf", "pcbNeeded", "pcReturned"]),
#
'GetPrintProcessorDirectoryA': SimTypeFunction([SimTypePointer(SimTypeChar(label="Byte"), offset=0), SimTypePointer(SimTypeChar(label="Byte"), offset=0), SimTypeInt(signed=False, label="UInt32"), SimTypePointer(SimTypeChar(label="Byte"), offset=0), SimTypeInt(signed=False, label="UInt32"), SimTypePointer(SimTypeInt(signed=False, label="UInt32"), offset=0)], SimTypeInt(signed=True, label="Int32"), arg_names=["pName", "pEnvironment", "Level", "pPrintProcessorInfo", "cbBuf", "pcbNeeded"]),
#
'GetPrintProcessorDirectoryW': SimTypeFunction([SimTypePointer(SimTypeChar(label="Char"), offset=0), SimTypePointer(SimTypeChar(label="Char"), offset=0), SimTypeInt(signed=False, label="UInt32"), SimTypePointer(SimTypeChar(label="Byte"), offset=0), SimTypeInt(signed=False, label="UInt32"), SimTypePointer(SimTypeInt(signed=False, label="UInt32"), offset=0)], SimTypeInt(signed=True, label="Int32"), arg_names=["pName", "pEnvironment", "Level", "pPrintProcessorInfo", "cbBuf", "pcbNeeded"]),
#
'EnumPrintProcessorDatatypesA': SimTypeFunction([SimTypePointer(SimTypeChar(label="Byte"), offset=0), SimTypePointer(SimTypeChar(label="Byte"), offset=0), SimTypeInt(signed=False, label="UInt32"), SimTypePointer(SimTypeChar(label="Byte"), offset=0), SimTypeInt(signed=False, label="UInt32"), SimTypePointer(SimTypeInt(signed=False, label="UInt32"), offset=0), SimTypePointer(SimTypeInt(signed=False, label="UInt32"), offset=0)], SimTypeInt(signed=True, label="Int32"), arg_names=["pName", "pPrintProcessorName", "Level", "pDatatypes", "cbBuf", "pcbNeeded", "pcReturned"]),
#
'EnumPrintProcessorDatatypesW': SimTypeFunction([SimTypePointer(SimTypeChar(label="Char"), offset=0), SimTypePointer(SimTypeChar(label="Char"), offset=0), SimTypeInt(signed=False, label="UInt32"), SimTypePointer(SimTypeChar(label="Byte"), offset=0), SimTypeInt(signed=False, label="UInt32"), SimTypePointer(SimTypeInt(signed=False, label="UInt32"), offset=0), SimTypePointer(SimTypeInt(signed=False, label="UInt32"), offset=0)], SimTypeInt(signed=True, label="Int32"), arg_names=["pName", "pPrintProcessorName", "Level", "pDatatypes", "cbBuf", "pcbNeeded", "pcReturned"]),
#
'DeletePrintProcessorA': SimTypeFunction([SimTypePointer(SimTypeChar(label="Byte"), offset=0), SimTypePointer(SimTypeChar(label="Byte"), offset=0), SimTypePointer(SimTypeChar(label="Byte"), offset=0)], SimTypeInt(signed=True, label="Int32"), arg_names=["pName", "pEnvironment", "pPrintProcessorName"]),
#
'DeletePrintProcessorW': SimTypeFunction([SimTypePointer(SimTypeChar(label="Char"), offset=0), SimTypePointer(SimTypeChar(label="Char"), offset=0), SimTypePointer(SimTypeChar(label="Char"), offset=0)], SimTypeInt(signed=True, label="Int32"), arg_names=["pName", "pEnvironment", "pPrintProcessorName"]),
#
'StartDocPrinterA': SimTypeFunction([SimTypePointer(SimTypeInt(signed=True, label="Int"), label="IntPtr", offset=0), SimTypeInt(signed=False, label="UInt32"), SimTypePointer(SimStruct({"pDocName": SimTypePointer(SimTypeChar(label="Byte"), offset=0), "pOutputFile": SimTypePointer(SimTypeChar(label="Byte"), offset=0), "pDatatype": SimTypePointer(SimTypeChar(label="Byte"), offset=0)}, name="DOC_INFO_1A", pack=False, align=None), offset=0)], SimTypeInt(signed=False, label="UInt32"), arg_names=["hPrinter", "Level", "pDocInfo"]),
#
'StartDocPrinterW': SimTypeFunction([SimTypePointer(SimTypeInt(signed=True, label="Int"), label="IntPtr", offset=0), SimTypeInt(signed=False, label="UInt32"), SimTypePointer(SimStruct({"pDocName": SimTypePointer(SimTypeChar(label="Char"), offset=0), "pOutputFile": SimTypePointer(SimTypeChar(label="Char"), offset=0), "pDatatype": SimTypePointer(SimTypeChar(label="Char"), offset=0)}, name="DOC_INFO_1W", pack=False, align=None), offset=0)], SimTypeInt(signed=False, label="UInt32"), arg_names=["hPrinter", "Level", "pDocInfo"]),
#
'StartPagePrinter': SimTypeFunction([SimTypePointer(SimTypeInt(signed=True, label="Int"), label="IntPtr", offset=0)], SimTypeInt(signed=True, label="Int32"), arg_names=["hPrinter"]),
#
'WritePrinter': SimTypeFunction([SimTypePointer(SimTypeInt(signed=True, label="Int"), label="IntPtr", offset=0), SimTypePointer(SimTypeBottom(label="Void"), offset=0), SimTypeInt(signed=False, label="UInt32"), SimTypePointer(SimTypeInt(signed=False, label="UInt32"), offset=0)], SimTypeInt(signed=True, label="Int32"), arg_names=["hPrinter", "pBuf", "cbBuf", "pcWritten"]),
#
'FlushPrinter': SimTypeFunction([SimTypePointer(SimTypeInt(signed=True, label="Int"), label="IntPtr", offset=0), SimTypePointer(SimTypeBottom(label="Void"), offset=0), SimTypeInt(signed=False, label="UInt32"), SimTypePointer(SimTypeInt(signed=False, label="UInt32"), offset=0), SimTypeInt(signed=False, label="UInt32")], SimTypeInt(signed=True, label="Int32"), arg_names=["hPrinter", "pBuf", "cbBuf", "pcWritten", "cSleep"]),
#
'EndPagePrinter': SimTypeFunction([SimTypePointer(SimTypeInt(signed=True, label="Int"), label="IntPtr", offset=0)], SimTypeInt(signed=True, label="Int32"), arg_names=["hPrinter"]),
#
'AbortPrinter': SimTypeFunction([SimTypePointer(SimTypeInt(signed=True, label="Int"), label="IntPtr", offset=0)], SimTypeInt(signed=True, label="Int32"), arg_names=["hPrinter"]),
#
'ReadPrinter': SimTypeFunction([SimTypePointer(SimTypeInt(signed=True, label="Int"), label="IntPtr", offset=0), SimTypePointer(SimTypeBottom(label="Void"), offset=0), SimTypeInt(signed=False, label="UInt32"), SimTypePointer(SimTypeInt(signed=False, label="UInt32"), offset=0)], SimTypeInt(signed=True, label="Int32"), arg_names=["hPrinter", "pBuf", "cbBuf", "pNoBytesRead"]),
#
'EndDocPrinter': SimTypeFunction([SimTypePointer(SimTypeInt(signed=True, label="Int"), label="IntPtr", offset=0)], SimTypeInt(signed=True, label="Int32"), arg_names=["hPrinter"]),
#
'AddJobA': SimTypeFunction([SimTypePointer(SimTypeInt(signed=True, label="Int"), label="IntPtr", offset=0), SimTypeInt(signed=False, label="UInt32"), SimTypePointer(SimTypeChar(label="Byte"), offset=0), SimTypeInt(signed=False, label="UInt32"), SimTypePointer(SimTypeInt(signed=False, label="UInt32"), offset=0)], SimTypeInt(signed=True, label="Int32"), arg_names=["hPrinter", "Level", "pData", "cbBuf", "pcbNeeded"]),
#
'AddJobW': SimTypeFunction([SimTypePointer(SimTypeInt(signed=True, label="Int"), label="IntPtr", offset=0), SimTypeInt(signed=False, label="UInt32"), SimTypePointer(SimTypeChar(label="Byte"), offset=0), SimTypeInt(signed=False, label="UInt32"), SimTypePointer(SimTypeInt(signed=False, label="UInt32"), offset=0)], SimTypeInt(signed=True, label="Int32"), arg_names=["hPrinter", "Level", "pData", "cbBuf", "pcbNeeded"]),
#
'ScheduleJob': SimTypeFunction([SimTypePointer(SimTypeInt(signed=True, label="Int"), label="IntPtr", offset=0), SimTypeInt(signed=False, label="UInt32")], SimTypeInt(signed=True, label="Int32"), arg_names=["hPrinter", "JobId"]),
#
'PrinterProperties': SimTypeFunction([SimTypePointer(SimTypeInt(signed=True, label="Int"), label="IntPtr", offset=0), SimTypePointer(SimTypeInt(signed=True, label="Int"), label="IntPtr", offset=0)], SimTypeInt(signed=True, label="Int32"), arg_names=["hWnd", "hPrinter"]),
#
'DocumentPropertiesA': SimTypeFunction([SimTypePointer(SimTypeInt(signed=True, label="Int"), label="IntPtr", offset=0), SimTypePointer(SimTypeInt(signed=True, label="Int"), label="IntPtr", offset=0), SimTypePointer(SimTypeChar(label="Byte"), offset=0), SimTypePointer(SimStruct({"dmDeviceName": SimTypeFixedSizeArray(SimTypeChar(label="Byte"), 32), "dmSpecVersion": SimTypeShort(signed=False, label="UInt16"), "dmDriverVersion": SimTypeShort(signed=False, label="UInt16"), "dmSize": SimTypeShort(signed=False, label="UInt16"), "dmDriverExtra": SimTypeShort(signed=False, label="UInt16"), "dmFields": SimTypeInt(signed=False, label="UInt32"), "Anonymous1": SimUnion({"Anonymous1": SimStruct({"dmOrientation": SimTypeShort(signed=True, label="Int16"), "dmPaperSize": SimTypeShort(signed=True, label="Int16"), "dmPaperLength": SimTypeShort(signed=True, label="Int16"), "dmPaperWidth": SimTypeShort(signed=True, label="Int16"), "dmScale": SimTypeShort(signed=True, label="Int16"), "dmCopies": SimTypeShort(signed=True, label="Int16"), "dmDefaultSource": SimTypeShort(signed=True, label="Int16"), "dmPrintQuality": SimTypeShort(signed=True, label="Int16")}, name="_Anonymous1_e__Struct", pack=False, align=None), "Anonymous2": SimStruct({"dmPosition": SimStruct({"x": SimTypeInt(signed=True, label="Int32"), "y": SimTypeInt(signed=True, label="Int32")}, name="POINTL", pack=False, align=None), "dmDisplayOrientation": SimTypeInt(signed=False, label="UInt32"), "dmDisplayFixedOutput": SimTypeInt(signed=False, label="UInt32")}, name="_Anonymous2_e__Struct", pack=False, align=None)}, name="<anon>", label="None"), "dmColor": SimTypeShort(signed=True, label="Int16"), "dmDuplex": SimTypeShort(signed=True, label="Int16"), "dmYResolution": SimTypeShort(signed=True, label="Int16"), "dmTTOption": SimTypeShort(signed=True, label="Int16"), "dmCollate": SimTypeShort(signed=True, label="Int16"), "dmFormName": SimTypeFixedSizeArray(SimTypeChar(label="Byte"), 32), "dmLogPixels": SimTypeShort(signed=False, label="UInt16"), "dmBitsPerPel": SimTypeInt(signed=False, label="UInt32"), "dmPelsWidth": SimTypeInt(signed=False, label="UInt32"), "dmPelsHeight": SimTypeInt(signed=False, label="UInt32"), "Anonymous2": SimUnion({"dmDisplayFlags": SimTypeInt(signed=False, label="UInt32"), "dmNup": SimTypeInt(signed=False, label="UInt32")}, name="<anon>", label="None"), "dmDisplayFrequency": SimTypeInt(signed=False, label="UInt32"), "dmICMMethod": SimTypeInt(signed=False, label="UInt32"), "dmICMIntent": SimTypeInt(signed=False, label="UInt32"), "dmMediaType": SimTypeInt(signed=False, label="UInt32"), "dmDitherType": SimTypeInt(signed=False, label="UInt32"), "dmReserved1": SimTypeInt(signed=False, label="UInt32"), "dmReserved2": SimTypeInt(signed=False, label="UInt32"), "dmPanningWidth": SimTypeInt(signed=False, label="UInt32"), "dmPanningHeight": SimTypeInt(signed=False, label="UInt32")}, name="DEVMODEA", pack=False, align=None), offset=0), SimTypePointer(SimStruct({"dmDeviceName": SimTypeFixedSizeArray(SimTypeChar(label="Byte"), 32), "dmSpecVersion": SimTypeShort(signed=False, label="UInt16"), "dmDriverVersion": SimTypeShort(signed=False, label="UInt16"), "dmSize": SimTypeShort(signed=False, label="UInt16"), "dmDriverExtra": SimTypeShort(signed=False, label="UInt16"), "dmFields": SimTypeInt(signed=False, label="UInt32"), "Anonymous1": SimUnion({"Anonymous1": SimStruct({"dmOrientation": SimTypeShort(signed=True, label="Int16"), "dmPaperSize": SimTypeShort(signed=True, label="Int16"), "dmPaperLength": SimTypeShort(signed=True, label="Int16"), "dmPaperWidth": SimTypeShort(signed=True, label="Int16"), "dmScale": SimTypeShort(signed=True, label="Int16"), "dmCopies": SimTypeShort(signed=True, label="Int16"), "dmDefaultSource": SimTypeShort(signed=True, label="Int16"), "dmPrintQuality": SimTypeShort(signed=True, label="Int16")}, name="_Anonymous1_e__Struct", pack=False, align=None), "Anonymous2": SimStruct({"dmPosition": SimStruct({"x": SimTypeInt(signed=True, label="Int32"), "y": SimTypeInt(signed=True, label="Int32")}, name="POINTL", pack=False, align=None), "dmDisplayOrientation": SimTypeInt(signed=False, label="UInt32"), "dmDisplayFixedOutput": SimTypeInt(signed=False, label="UInt32")}, name="_Anonymous2_e__Struct", pack=False, align=None)}, name="<anon>", label="None"), "dmColor": SimTypeShort(signed=True, label="Int16"), "dmDuplex": SimTypeShort(signed=True, label="Int16"), "dmYResolution": SimTypeShort(signed=True, label="Int16"), "dmTTOption": SimTypeShort(signed=True, label="Int16"), "dmCollate": SimTypeShort(signed=True, label="Int16"), "dmFormName": SimTypeFixedSizeArray(SimTypeChar(label="Byte"), 32), "dmLogPixels": SimTypeShort(signed=False, label="UInt16"), "dmBitsPerPel": SimTypeInt(signed=False, label="UInt32"), "dmPelsWidth": SimTypeInt(signed=False, label="UInt32"), "dmPelsHeight": SimTypeInt(signed=False, label="UInt32"), "Anonymous2": SimUnion({"dmDisplayFlags": SimTypeInt(signed=False, label="UInt32"), "dmNup": SimTypeInt(signed=False, label="UInt32")}, name="<anon>", label="None"), "dmDisplayFrequency": SimTypeInt(signed=False, label="UInt32"), "dmICMMethod": SimTypeInt(signed=False, label="UInt32"), "dmICMIntent": SimTypeInt(signed=False, label="UInt32"), "dmMediaType": SimTypeInt(signed=False, label="UInt32"), "dmDitherType": SimTypeInt(signed=False, label="UInt32"), "dmReserved1": SimTypeInt(signed=False, label="UInt32"), "dmReserved2": SimTypeInt(signed=False, label="UInt32"), "dmPanningWidth": SimTypeInt(signed=False, label="UInt32"), "dmPanningHeight": SimTypeInt(signed=False, label="UInt32")}, name="DEVMODEA", pack=False, align=None), offset=0), SimTypeInt(signed=False, label="UInt32")], SimTypeInt(signed=True, label="Int32"), arg_names=["hWnd", "hPrinter", "pDeviceName", "pDevModeOutput", "pDevModeInput", "fMode"]),
#
'DocumentPropertiesW': SimTypeFunction([SimTypePointer(SimTypeInt(signed=True, label="Int"), label="IntPtr", offset=0), SimTypePointer(SimTypeInt(signed=True, label="Int"), label="IntPtr", offset=0), SimTypePointer(SimTypeChar(label="Char"), offset=0), SimTypePointer(SimStruct({"dmDeviceName": SimTypeFixedSizeArray(SimTypeChar(label="Char"), 32), "dmSpecVersion": SimTypeShort(signed=False, label="UInt16"), "dmDriverVersion": SimTypeShort(signed=False, label="UInt16"), "dmSize": SimTypeShort(signed=False, label="UInt16"), "dmDriverExtra": SimTypeShort(signed=False, label="UInt16"), "dmFields": SimTypeInt(signed=False, label="UInt32"), "Anonymous1": SimUnion({"Anonymous1": SimStruct({"dmOrientation": SimTypeShort(signed=True, label="Int16"), "dmPaperSize": SimTypeShort(signed=True, label="Int16"), "dmPaperLength": SimTypeShort(signed=True, label="Int16"), "dmPaperWidth": SimTypeShort(signed=True, label="Int16"), "dmScale": SimTypeShort(signed=True, label="Int16"), "dmCopies": SimTypeShort(signed=True, label="Int16"), "dmDefaultSource": SimTypeShort(signed=True, label="Int16"), "dmPrintQuality": SimTypeShort(signed=True, label="Int16")}, name="_Anonymous1_e__Struct", pack=False, align=None), "Anonymous2": SimStruct({"dmPosition": SimStruct({"x": SimTypeInt(signed=True, label="Int32"), "y": SimTypeInt(signed=True, label="Int32")}, name="POINTL", pack=False, align=None), "dmDisplayOrientation": SimTypeInt(signed=False, label="UInt32"), "dmDisplayFixedOutput": SimTypeInt(signed=False, label="UInt32")}, name="_Anonymous2_e__Struct", pack=False, align=None)}, name="<anon>", label="None"), "dmColor": SimTypeShort(signed=True, label="Int16"), "dmDuplex": SimTypeShort(signed=True, label="Int16"), "dmYResolution": SimTypeShort(signed=True, label="Int16"), "dmTTOption": SimTypeShort(signed=True, label="Int16"), "dmCollate": SimTypeShort(signed=True, label="Int16"), "dmFormName": SimTypeFixedSizeArray(SimTypeChar(label="Char"), 32), "dmLogPixels": SimTypeShort(signed=False, label="UInt16"), "dmBitsPerPel": SimTypeInt(signed=False, label="UInt32"), "dmPelsWidth": SimTypeInt(signed=False, label="UInt32"), "dmPelsHeight": SimTypeInt(signed=False, label="UInt32"), "Anonymous2": SimUnion({"dmDisplayFlags": SimTypeInt(signed=False, label="UInt32"), "dmNup": SimTypeInt(signed=False, label="UInt32")}, name="<anon>", label="None"), "dmDisplayFrequency": SimTypeInt(signed=False, label="UInt32"), "dmICMMethod": SimTypeInt(signed=False, label="UInt32"), "dmICMIntent": SimTypeInt(signed=False, label="UInt32"), "dmMediaType": SimTypeInt(signed=False, label="UInt32"), "dmDitherType": SimTypeInt(signed=False, label="UInt32"), "dmReserved1": SimTypeInt(signed=False, label="UInt32"), "dmReserved2": SimTypeInt(signed=False, label="UInt32"), "dmPanningWidth": SimTypeInt(signed=False, label="UInt32"), "dmPanningHeight": SimTypeInt(signed=False, label="UInt32")}, name="DEVMODEW", pack=False, align=None), offset=0), SimTypePointer(SimStruct({"dmDeviceName": SimTypeFixedSizeArray(SimTypeChar(label="Char"), 32), "dmSpecVersion": SimTypeShort(signed=False, label="UInt16"), "dmDriverVersion": SimTypeShort(signed=False, label="UInt16"), "dmSize": SimTypeShort(signed=False, label="UInt16"), "dmDriverExtra": SimTypeShort(signed=False, label="UInt16"), "dmFields": SimTypeInt(signed=False, label="UInt32"), "Anonymous1": SimUnion({"Anonymous1": SimStruct({"dmOrientation": SimTypeShort(signed=True, label="Int16"), "dmPaperSize": SimTypeShort(signed=True, label="Int16"), "dmPaperLength": SimTypeShort(signed=True, label="Int16"), "dmPaperWidth": SimTypeShort(signed=True, label="Int16"), "dmScale": SimTypeShort(signed=True, label="Int16"), "dmCopies": SimTypeShort(signed=True, label="Int16"), "dmDefaultSource": SimTypeShort(signed=True, label="Int16"), "dmPrintQuality": SimTypeShort(signed=True, label="Int16")}, name="_Anonymous1_e__Struct", pack=False, align=None), "Anonymous2": SimStruct({"dmPosition": SimStruct({"x": SimTypeInt(signed=True, label="Int32"), "y": SimTypeInt(signed=True, label="Int32")}, name="POINTL", pack=False, align=None), "dmDisplayOrientation": SimTypeInt(signed=False, label="UInt32"), "dmDisplayFixedOutput": SimTypeInt(signed=False, label="UInt32")}, name="_Anonymous2_e__Struct", pack=False, align=None)}, name="<anon>", label="None"), "dmColor": SimTypeShort(signed=True, label="Int16"), "dmDuplex": SimTypeShort(signed=True, label="Int16"), "dmYResolution": SimTypeShort(signed=True, label="Int16"), "dmTTOption": SimTypeShort(signed=True, label="Int16"), "dmCollate": SimTypeShort(signed=True, label="Int16"), "dmFormName": SimTypeFixedSizeArray(SimTypeChar(label="Char"), 32), "dmLogPixels": SimTypeShort(signed=False, label="UInt16"), "dmBitsPerPel": SimTypeInt(signed=False, label="UInt32"), "dmPelsWidth": SimTypeInt(signed=False, label="UInt32"), "dmPelsHeight": SimTypeInt(signed=False, label="UInt32"), "Anonymous2": SimUnion({"dmDisplayFlags": SimTypeInt(signed=False, label="UInt32"), "dmNup": SimTypeInt(signed=False, label="UInt32")}, name="<anon>", label="None"), "dmDisplayFrequency": SimTypeInt(signed=False, label="UInt32"), "dmICMMethod": SimTypeInt(signed=False, label="UInt32"), "dmICMIntent": SimTypeInt(signed=False, label="UInt32"), "dmMediaType": SimTypeInt(signed=False, label="UInt32"), "dmDitherType": SimTypeInt(signed=False, label="UInt32"), "dmReserved1": SimTypeInt(signed=False, label="UInt32"), "dmReserved2": SimTypeInt(signed=False, label="UInt32"), "dmPanningWidth": SimTypeInt(signed=False, label="UInt32"), "dmPanningHeight": SimTypeInt(signed=False, label="UInt32")}, name="DEVMODEW", pack=False, align=None), offset=0), SimTypeInt(signed=False, label="UInt32")], SimTypeInt(signed=True, label="Int32"), arg_names=["hWnd", "hPrinter", "pDeviceName", "pDevModeOutput", "pDevModeInput", "fMode"]),
#
'AdvancedDocumentPropertiesA': SimTypeFunction([SimTypePointer(SimTypeInt(signed=True, label="Int"), label="IntPtr", offset=0), SimTypePointer(SimTypeInt(signed=True, label="Int"), label="IntPtr", offset=0), SimTypePointer(SimTypeChar(label="Byte"), offset=0), SimTypePointer(SimStruct({"dmDeviceName": SimTypeFixedSizeArray(SimTypeChar(label="Byte"), 32), "dmSpecVersion": SimTypeShort(signed=False, label="UInt16"), "dmDriverVersion": SimTypeShort(signed=False, label="UInt16"), "dmSize": SimTypeShort(signed=False, label="UInt16"), "dmDriverExtra": SimTypeShort(signed=False, label="UInt16"), "dmFields": SimTypeInt(signed=False, label="UInt32"), "Anonymous1": SimUnion({"Anonymous1": SimStruct({"dmOrientation": SimTypeShort(signed=True, label="Int16"), "dmPaperSize": SimTypeShort(signed=True, label="Int16"), "dmPaperLength": SimTypeShort(signed=True, label="Int16"), "dmPaperWidth": SimTypeShort(signed=True, label="Int16"), "dmScale": SimTypeShort(signed=True, label="Int16"), "dmCopies": SimTypeShort(signed=True, label="Int16"), "dmDefaultSource": SimTypeShort(signed=True, label="Int16"), "dmPrintQuality": SimTypeShort(signed=True, label="Int16")}, name="_Anonymous1_e__Struct", pack=False, align=None), "Anonymous2": SimStruct({"dmPosition": SimStruct({"x": SimTypeInt(signed=True, label="Int32"), "y": SimTypeInt(signed=True, label="Int32")}, name="POINTL", pack=False, align=None), "dmDisplayOrientation": SimTypeInt(signed=False, label="UInt32"), "dmDisplayFixedOutput": SimTypeInt(signed=False, label="UInt32")}, name="_Anonymous2_e__Struct", pack=False, align=None)}, name="<anon>", label="None"), "dmColor": SimTypeShort(signed=True, label="Int16"), "dmDuplex": SimTypeShort(signed=True, label="Int16"), "dmYResolution": SimTypeShort(signed=True, label="Int16"), "dmTTOption": SimTypeShort(signed=True, label="Int16"), "dmCollate": SimTypeShort(signed=True, label="Int16"), "dmFormName": SimTypeFixedSizeArray(SimTypeChar(label="Byte"), 32), "dmLogPixels": SimTypeShort(signed=False, label="UInt16"), "dmBitsPerPel": SimTypeInt(signed=False, label="UInt32"), "dmPelsWidth": SimTypeInt(signed=False, label="UInt32"), "dmPelsHeight": SimTypeInt(signed=False, label="UInt32"), "Anonymous2": SimUnion({"dmDisplayFlags": SimTypeInt(signed=False, label="UInt32"), "dmNup": SimTypeInt(signed=False, label="UInt32")}, name="<anon>", label="None"), "dmDisplayFrequency": SimTypeInt(signed=False, label="UInt32"), "dmICMMethod": SimTypeInt(signed=False, label="UInt32"), "dmICMIntent": SimTypeInt(signed=False, label="UInt32"), "dmMediaType": SimTypeInt(signed=False, label="UInt32"), "dmDitherType": SimTypeInt(signed=False, label="UInt32"), "dmReserved1": SimTypeInt(signed=False, label="UInt32"), "dmReserved2": SimTypeInt(signed=False, label="UInt32"), "dmPanningWidth": SimTypeInt(signed=False, label="UInt32"), "dmPanningHeight": SimTypeInt(signed=False, label="UInt32")}, name="DEVMODEA", pack=False, align=None), offset=0), SimTypePointer(SimStruct({"dmDeviceName": SimTypeFixedSizeArray(SimTypeChar(label="Byte"), 32), "dmSpecVersion": SimTypeShort(signed=False, label="UInt16"), "dmDriverVersion": SimTypeShort(signed=False, label="UInt16"), "dmSize": SimTypeShort(signed=False, label="UInt16"), "dmDriverExtra": SimTypeShort(signed=False, label="UInt16"), "dmFields": SimTypeInt(signed=False, label="UInt32"), "Anonymous1": SimUnion({"Anonymous1": SimStruct({"dmOrientation": SimTypeShort(signed=True, label="Int16"), "dmPaperSize": SimTypeShort(signed=True, label="Int16"), "dmPaperLength": SimTypeShort(signed=True, label="Int16"), "dmPaperWidth": SimTypeShort(signed=True, label="Int16"), "dmScale": SimTypeShort(signed=True, label="Int16"), "dmCopies": SimTypeShort(signed=True, label="Int16"), "dmDefaultSource": SimTypeShort(signed=True, label="Int16"), "dmPrintQuality": SimTypeShort(signed=True, label="Int16")}, name="_Anonymous1_e__Struct", pack=False, align=None), "Anonymous2": SimStruct({"dmPosition": SimStruct({"x": SimTypeInt(signed=True, label="Int32"), "y": SimTypeInt(signed=True, label="Int32")}, name="POINTL", pack=False, align=None), "dmDisplayOrientation": SimTypeInt(signed=False, label="UInt32"), "dmDisplayFixedOutput": SimTypeInt(signed=False, label="UInt32")}, name="_Anonymous2_e__Struct", pack=False, align=None)}, name="<anon>", label="None"), "dmColor": SimTypeShort(signed=True, label="Int16"), "dmDuplex": SimTypeShort(signed=True, label="Int16"), "dmYResolution": SimTypeShort(signed=True, label="Int16"), "dmTTOption": SimTypeShort(signed=True, label="Int16"), "dmCollate": SimTypeShort(signed=True, label="Int16"), "dmFormName": SimTypeFixedSizeArray(SimTypeChar(label="Byte"), 32), "dmLogPixels": SimTypeShort(signed=False, label="UInt16"), "dmBitsPerPel": SimTypeInt(signed=False, label="UInt32"), "dmPelsWidth": SimTypeInt(signed=False, label="UInt32"), "dmPelsHeight": SimTypeInt(signed=False, label="UInt32"), "Anonymous2": SimUnion({"dmDisplayFlags": SimTypeInt(signed=False, label="UInt32"), "dmNup": SimTypeInt(signed=False, label="UInt32")}, name="<anon>", label="None"), "dmDisplayFrequency": SimTypeInt(signed=False, label="UInt32"), "dmICMMethod": SimTypeInt(signed=False, label="UInt32"), "dmICMIntent": SimTypeInt(signed=False, label="UInt32"), "dmMediaType": SimTypeInt(signed=False, label="UInt32"), "dmDitherType": SimTypeInt(signed=False, label="UInt32"), "dmReserved1": SimTypeInt(signed=False, label="UInt32"), "dmReserved2": SimTypeInt(signed=False, label="UInt32"), "dmPanningWidth": SimTypeInt(signed=False, label="UInt32"), "dmPanningHeight": SimTypeInt(signed=False, label="UInt32")}, name="DEVMODEA", pack=False, align=None), offset=0)], SimTypeInt(signed=True, label="Int32"), arg_names=["hWnd", "hPrinter", "pDeviceName", "pDevModeOutput", "pDevModeInput"]),
#
'AdvancedDocumentPropertiesW': SimTypeFunction([SimTypePointer(SimTypeInt(signed=True, label="Int"), label="IntPtr", offset=0), SimTypePointer(SimTypeInt(signed=True, label="Int"), label="IntPtr", offset=0), SimTypePointer(SimTypeChar(label="Char"), offset=0), SimTypePointer(SimStruct({"dmDeviceName": SimTypeFixedSizeArray(SimTypeChar(label="Char"), 32), "dmSpecVersion": SimTypeShort(signed=False, label="UInt16"), "dmDriverVersion": SimTypeShort(signed=False, label="UInt16"), "dmSize": SimTypeShort(signed=False, label="UInt16"), "dmDriverExtra": SimTypeShort(signed=False, label="UInt16"), "dmFields": SimTypeInt(signed=False, label="UInt32"), "Anonymous1": SimUnion({"Anonymous1": SimStruct({"dmOrientation": SimTypeShort(signed=True, label="Int16"), "dmPaperSize": SimTypeShort(signed=True, label="Int16"), "dmPaperLength": SimTypeShort(signed=True, label="Int16"), "dmPaperWidth": SimTypeShort(signed=True, label="Int16"), "dmScale": SimTypeShort(signed=True, label="Int16"), "dmCopies": SimTypeShort(signed=True, label="Int16"), "dmDefaultSource": SimTypeShort(signed=True, label="Int16"), "dmPrintQuality": SimTypeShort(signed=True, label="Int16")}, name="_Anonymous1_e__Struct", pack=False, align=None), "Anonymous2": SimStruct({"dmPosition": SimStruct({"x": SimTypeInt(signed=True, label="Int32"), "y": SimTypeInt(signed=True, label="Int32")}, name="POINTL", pack=False, align=None), "dmDisplayOrientation": SimTypeInt(signed=False, label="UInt32"), "dmDisplayFixedOutput": SimTypeInt(signed=False, label="UInt32")}, name="_Anonymous2_e__Struct", pack=False, align=None)}, name="<anon>", label="None"), "dmColor": SimTypeShort(signed=True, label="Int16"), "dmDuplex": SimTypeShort(signed=True, label="Int16"), "dmYResolution": SimTypeShort(signed=True, label="Int16"), "dmTTOption": SimTypeShort(signed=True, label="Int16"), "dmCollate": SimTypeShort(signed=True, label="Int16"), "dmFormName": SimTypeFixedSizeArray(SimTypeChar(label="Char"), 32), "dmLogPixels": SimTypeShort(signed=False, label="UInt16"), "dmBitsPerPel": SimTypeInt(signed=False, label="UInt32"), "dmPelsWidth": SimTypeInt(signed=False, label="UInt32"), "dmPelsHeight": SimTypeInt(signed=False, label="UInt32"), "Anonymous2": SimUnion({"dmDisplayFlags": SimTypeInt(signed=False, label="UInt32"), "dmNup": SimTypeInt(signed=False, label="UInt32")}, name="<anon>", label="None"), "dmDisplayFrequency": SimTypeInt(signed=False, label="UInt32"), "dmICMMethod": SimTypeInt(signed=False, label="UInt32"), "dmICMIntent": SimTypeInt(signed=False, label="UInt32"), "dmMediaType": SimTypeInt(signed=False, label="UInt32"), "dmDitherType": SimTypeInt(signed=False, label="UInt32"), "dmReserved1": SimTypeInt(signed=False, label="UInt32"), "dmReserved2": SimTypeInt(signed=False, label="UInt32"), "dmPanningWidth": SimTypeInt(signed=False, label="UInt32"), "dmPanningHeight": SimTypeInt(signed=False, label="UInt32")}, name="DEVMODEW", pack=False, align=None), offset=0), SimTypePointer(SimStruct({"dmDeviceName": SimTypeFixedSizeArray(SimTypeChar(label="Char"), 32), "dmSpecVersion": SimTypeShort(signed=False, label="UInt16"), "dmDriverVersion": SimTypeShort(signed=False, label="UInt16"), "dmSize": SimTypeShort(signed=False, label="UInt16"), "dmDriverExtra": SimTypeShort(signed=False, label="UInt16"), "dmFields": SimTypeInt(signed=False, label="UInt32"), "Anonymous1": SimUnion({"Anonymous1": SimStruct({"dmOrientation": SimTypeShort(signed=True, label="Int16"), "dmPaperSize": SimTypeShort(signed=True, label="Int16"), "dmPaperLength": SimTypeShort(signed=True, label="Int16"), "dmPaperWidth": SimTypeShort(signed=True, label="Int16"), "dmScale": SimTypeShort(signed=True, label="Int16"), "dmCopies": SimTypeShort(signed=True, label="Int16"), "dmDefaultSource": SimTypeShort(signed=True, label="Int16"), "dmPrintQuality": SimTypeShort(signed=True, label="Int16")}, name="_Anonymous1_e__Struct", pack=False, align=None), "Anonymous2": SimStruct({"dmPosition": SimStruct({"x": SimTypeInt(signed=True, label="Int32"), "y": SimTypeInt(signed=True, label="Int32")}, name="POINTL", pack=False, align=None), "dmDisplayOrientation": SimTypeInt(signed=False, label="UInt32"), "dmDisplayFixedOutput": SimTypeInt(signed=False, label="UInt32")}, name="_Anonymous2_e__Struct", pack=False, align=None)}, name="<anon>", label="None"), "dmColor": SimTypeShort(signed=True, label="Int16"), "dmDuplex": SimTypeShort(signed=True, label="Int16"), "dmYResolution": SimTypeShort(signed=True, label="Int16"), "dmTTOption": SimTypeShort(signed=True, label="Int16"), "dmCollate": SimTypeShort(signed=True, label="Int16"), "dmFormName": SimTypeFixedSizeArray(SimTypeChar(label="Char"), 32), "dmLogPixels": SimTypeShort(signed=False, label="UInt16"), "dmBitsPerPel": SimTypeInt(signed=False, label="UInt32"), "dmPelsWidth": SimTypeInt(signed=False, label="UInt32"), "dmPelsHeight": SimTypeInt(signed=False, label="UInt32"), "Anonymous2": SimUnion({"dmDisplayFlags": SimTypeInt(signed=False, label="UInt32"), "dmNup": SimTypeInt(signed=False, label="UInt32")}, name="<anon>", label="None"), "dmDisplayFrequency": SimTypeInt(signed=False, label="UInt32"), "dmICMMethod": SimTypeInt(signed=False, label="UInt32"), "dmICMIntent": SimTypeInt(signed=False, label="UInt32"), "dmMediaType": SimTypeInt(signed=False, label="UInt32"), "dmDitherType": SimTypeInt(signed=False, label="UInt32"), "dmReserved1": SimTypeInt(signed=False, label="UInt32"), "dmReserved2": SimTypeInt(signed=False, label="UInt32"), "dmPanningWidth": SimTypeInt(signed=False, label="UInt32"), "dmPanningHeight": SimTypeInt(signed=False, label="UInt32")}, name="DEVMODEW", pack=False, align=None), offset=0)], SimTypeInt(signed=True, label="Int32"), arg_names=["hWnd", "hPrinter", "pDeviceName", "pDevModeOutput", "pDevModeInput"]),
#
'GetPrinterDataA': SimTypeFunction([SimTypePointer(SimTypeInt(signed=True, label="Int"), label="IntPtr", offset=0), SimTypePointer(SimTypeChar(label="Byte"), offset=0), SimTypePointer(SimTypeInt(signed=False, label="UInt32"), offset=0), SimTypePointer(SimTypeChar(label="Byte"), offset=0), SimTypeInt(signed=False, label="UInt32"), SimTypePointer(SimTypeInt(signed=False, label="UInt32"), offset=0)], SimTypeInt(signed=False, label="UInt32"), arg_names=["hPrinter", "pValueName", "pType", "pData", "nSize", "pcbNeeded"]),
#
'GetPrinterDataW': SimTypeFunction([SimTypePointer(SimTypeInt(signed=True, label="Int"), label="IntPtr", offset=0), SimTypePointer(SimTypeChar(label="Char"), offset=0), SimTypePointer(SimTypeInt(signed=False, label="UInt32"), offset=0), SimTypePointer(SimTypeChar(label="Byte"), offset=0), SimTypeInt(signed=False, label="UInt32"), SimTypePointer(SimTypeInt(signed=False, label="UInt32"), offset=0)], SimTypeInt(signed=False, label="UInt32"), arg_names=["hPrinter", "pValueName", "pType", "pData", "nSize", "pcbNeeded"]),
#
'GetPrinterDataExA': SimTypeFunction([SimTypePointer(SimTypeInt(signed=True, label="Int"), label="IntPtr", offset=0), SimTypePointer(SimTypeChar(label="Byte"), offset=0), SimTypePointer(SimTypeChar(label="Byte"), offset=0), SimTypePointer(SimTypeInt(signed=False, label="UInt32"), offset=0), SimTypePointer(SimTypeChar(label="Byte"), offset=0), SimTypeInt(signed=False, label="UInt32"), SimTypePointer(SimTypeInt(signed=False, label="UInt32"), offset=0)], SimTypeInt(signed=False, label="UInt32"), arg_names=["hPrinter", "pKeyName", "pValueName", "pType", "pData", "nSize", "pcbNeeded"]),
#
'GetPrinterDataExW': SimTypeFunction([SimTypePointer(SimTypeInt(signed=True, label="Int"), label="IntPtr", offset=0), SimTypePointer(SimTypeChar(label="Char"), offset=0), SimTypePointer(SimTypeChar(label="Char"), offset=0), SimTypePointer(SimTypeInt(signed=False, label="UInt32"), offset=0), SimTypePointer(SimTypeChar(label="Byte"), offset=0), SimTypeInt(signed=False, label="UInt32"), SimTypePointer(SimTypeInt(signed=False, label="UInt32"), offset=0)], SimTypeInt(signed=False, label="UInt32"), arg_names=["hPrinter", "pKeyName", "pValueName", "pType", "pData", "nSize", "pcbNeeded"]),
#
'EnumPrinterDataA': SimTypeFunction([SimTypePointer(SimTypeInt(signed=True, label="Int"), label="IntPtr", offset=0), SimTypeInt(signed=False, label="UInt32"), SimTypePointer(SimTypeChar(label="Byte"), offset=0), SimTypeInt(signed=False, label="UInt32"), SimTypePointer(SimTypeInt(signed=False, label="UInt32"), offset=0), SimTypePointer(SimTypeInt(signed=False, label="UInt32"), offset=0), SimTypePointer(SimTypeChar(label="Byte"), label="LPArray", offset=0), SimTypeInt(signed=False, label="UInt32"), SimTypePointer(SimTypeInt(signed=False, label="UInt32"), offset=0)], SimTypeInt(signed=False, label="UInt32"), arg_names=["hPrinter", "dwIndex", "pValueName", "cbValueName", "pcbValueName", "pType", "pData", "cbData", "pcbData"]),
#
'EnumPrinterDataW': SimTypeFunction([SimTypePointer(SimTypeInt(signed=True, label="Int"), label="IntPtr", offset=0), SimTypeInt(signed=False, label="UInt32"), SimTypePointer(SimTypeChar(label="Char"), offset=0), SimTypeInt(signed=False, label="UInt32"), SimTypePointer(SimTypeInt(signed=False, label="UInt32"), offset=0), SimTypePointer(SimTypeInt(signed=False, label="UInt32"), offset=0), SimTypePointer(SimTypeChar(label="Byte"), label="LPArray", offset=0), SimTypeInt(signed=False, label="UInt32"), SimTypePointer(SimTypeInt(signed=False, label="UInt32"), offset=0)], SimTypeInt(signed=False, label="UInt32"), arg_names=["hPrinter", "dwIndex", "pValueName", "cbValueName", "pcbValueName", "pType", "pData", "cbData", "pcbData"]),
#
'EnumPrinterDataExA': SimTypeFunction([SimTypePointer(SimTypeInt(signed=True, label="Int"), label="IntPtr", offset=0), SimTypePointer(SimTypeChar(label="Byte"), offset=0), SimTypePointer(SimTypeChar(label="Byte"), offset=0), SimTypeInt(signed=False, label="UInt32"), SimTypePointer(SimTypeInt(signed=False, label="UInt32"), offset=0), SimTypePointer(SimTypeInt(signed=False, label="UInt32"), offset=0)], SimTypeInt(signed=False, label="UInt32"), arg_names=["hPrinter", "pKeyName", "pEnumValues", "cbEnumValues", "pcbEnumValues", "pnEnumValues"]),
#
'EnumPrinterDataExW': SimTypeFunction([SimTypePointer(SimTypeInt(signed=True, label="Int"), label="IntPtr", offset=0), SimTypePointer(SimTypeChar(label="Char"), offset=0), SimTypePointer(SimTypeChar(label="Byte"), offset=0), SimTypeInt(signed=False, label="UInt32"), SimTypePointer(SimTypeInt(signed=False, label="UInt32"), offset=0), SimTypePointer(SimTypeInt(signed=False, label="UInt32"), offset=0)], SimTypeInt(signed=False, label="UInt32"), arg_names=["hPrinter", "pKeyName", "pEnumValues", "cbEnumValues", "pcbEnumValues", "pnEnumValues"]),
#
'EnumPrinterKeyA': SimTypeFunction([SimTypePointer(SimTypeInt(signed=True, label="Int"), label="IntPtr", offset=0), SimTypePointer(SimTypeChar(label="Byte"), offset=0), SimTypePointer(SimTypeChar(label="Byte"), offset=0), SimTypeInt(signed=False, label="UInt32"), SimTypePointer(SimTypeInt(signed=False, label="UInt32"), offset=0)], SimTypeInt(signed=False, label="UInt32"), arg_names=["hPrinter", "pKeyName", "pSubkey", "cbSubkey", "pcbSubkey"]),
#
'EnumPrinterKeyW': SimTypeFunction([SimTypePointer(SimTypeInt(signed=True, label="Int"), label="IntPtr", offset=0), SimTypePointer(SimTypeChar(label="Char"), offset=0), SimTypePointer(SimTypeChar(label="Char"), offset=0), SimTypeInt(signed=False, label="UInt32"), SimTypePointer(SimTypeInt(signed=False, label="UInt32"), offset=0)], SimTypeInt(signed=False, label="UInt32"), arg_names=["hPrinter", "pKeyName", "pSubkey", "cbSubkey", "pcbSubkey"]),
#
'SetPrinterDataA': SimTypeFunction([SimTypePointer(SimTypeInt(signed=True, label="Int"), label="IntPtr", offset=0), SimTypePointer(SimTypeChar(label="Byte"), offset=0), SimTypeInt(signed=False, label="UInt32"), SimTypePointer(SimTypeChar(label="Byte"), offset=0), SimTypeInt(signed=False, label="UInt32")], SimTypeInt(signed=False, label="UInt32"), arg_names=["hPrinter", "pValueName", "Type", "pData", "cbData"]),
#
'SetPrinterDataW': SimTypeFunction([SimTypePointer(SimTypeInt(signed=True, label="Int"), label="IntPtr", offset=0), SimTypePointer(SimTypeChar(label="Char"), offset=0), SimTypeInt(signed=False, label="UInt32"), SimTypePointer(SimTypeChar(label="Byte"), offset=0), SimTypeInt(signed=False, label="UInt32")], SimTypeInt(signed=False, label="UInt32"), arg_names=["hPrinter", "pValueName", "Type", "pData", "cbData"]),
#
'SetPrinterDataExA': SimTypeFunction([SimTypePointer(SimTypeInt(signed=True, label="Int"), label="IntPtr", offset=0), SimTypePointer(SimTypeChar(label="Byte"), offset=0), SimTypePointer(SimTypeChar(label="Byte"), offset=0), SimTypeInt(signed=False, label="UInt32"), SimTypePointer(SimTypeChar(label="Byte"), offset=0), SimTypeInt(signed=False, label="UInt32")], SimTypeInt(signed=False, label="UInt32"), arg_names=["hPrinter", "pKeyName", "pValueName", "Type", "pData", "cbData"]),
#
'SetPrinterDataExW': SimTypeFunction([SimTypePointer(SimTypeInt(signed=True, label="Int"), label="IntPtr", offset=0), SimTypePointer(SimTypeChar(label="Char"), offset=0), SimTypePointer(SimTypeChar(label="Char"), offset=0), SimTypeInt(signed=False, label="UInt32"), SimTypePointer(SimTypeChar(label="Byte"), offset=0), SimTypeInt(signed=False, label="UInt32")], SimTypeInt(signed=False, label="UInt32"), arg_names=["hPrinter", "pKeyName", "pValueName", "Type", "pData", "cbData"]),
#
'DeletePrinterDataA': SimTypeFunction([SimTypePointer(SimTypeInt(signed=True, label="Int"), label="IntPtr", offset=0), SimTypePointer(SimTypeChar(label="Byte"), offset=0)], SimTypeInt(signed=False, label="UInt32"), arg_names=["hPrinter", "pValueName"]),
#
'DeletePrinterDataW': SimTypeFunction([SimTypePointer(SimTypeInt(signed=True, label="Int"), label="IntPtr", offset=0), SimTypePointer(SimTypeChar(label="Char"), offset=0)], SimTypeInt(signed=False, label="UInt32"), arg_names=["hPrinter", "pValueName"]),
#
'DeletePrinterDataExA': SimTypeFunction([SimTypePointer(SimTypeInt(signed=True, label="Int"), label="IntPtr", offset=0), SimTypePointer(SimTypeChar(label="Byte"), offset=0), SimTypePointer(SimTypeChar(label="Byte"), offset=0)], SimTypeInt(signed=False, label="UInt32"), arg_names=["hPrinter", "pKeyName", "pValueName"]),
#
'DeletePrinterDataExW': SimTypeFunction([SimTypePointer(SimTypeInt(signed=True, label="Int"), label="IntPtr", offset=0), SimTypePointer(SimTypeChar(label="Char"), offset=0), SimTypePointer(SimTypeChar(label="Char"), offset=0)], SimTypeInt(signed=False, label="UInt32"), arg_names=["hPrinter", "pKeyName", "pValueName"]),
#
'DeletePrinterKeyA': SimTypeFunction([SimTypePointer(SimTypeInt(signed=True, label="Int"), label="IntPtr", offset=0), SimTypePointer(SimTypeChar(label="Byte"), offset=0)], SimTypeInt(signed=False, label="UInt32"), arg_names=["hPrinter", "pKeyName"]),
#
'DeletePrinterKeyW': SimTypeFunction([SimTypePointer(SimTypeInt(signed=True, label="Int"), label="IntPtr", offset=0), SimTypePointer(SimTypeChar(label="Char"), offset=0)], SimTypeInt(signed=False, label="UInt32"), arg_names=["hPrinter", "pKeyName"]),
#
'WaitForPrinterChange': SimTypeFunction([SimTypePointer(SimTypeInt(signed=True, label="Int"), label="IntPtr", offset=0), SimTypeInt(signed=False, label="UInt32")], SimTypeInt(signed=False, label="UInt32"), arg_names=["hPrinter", "Flags"]),
#
'FindFirstPrinterChangeNotification': SimTypeFunction([SimTypePointer(SimTypeInt(signed=True, label="Int"), label="IntPtr", offset=0), SimTypeInt(signed=False, label="UInt32"), SimTypeInt(signed=False, label="UInt32"), SimTypePointer(SimTypeBottom(label="Void"), offset=0)], SimTypePointer(SimTypeInt(signed=True, label="Int"), label="IntPtr", offset=0), arg_names=["hPrinter", "fdwFilter", "fdwOptions", "pPrinterNotifyOptions"]),
#
'FindNextPrinterChangeNotification': SimTypeFunction([SimTypePointer(SimTypeInt(signed=True, label="Int"), label="IntPtr", offset=0), SimTypePointer(SimTypeInt(signed=False, label="UInt32"), offset=0), SimTypePointer(SimTypeBottom(label="Void"), offset=0), SimTypePointer(SimTypePointer(SimTypeBottom(label="Void"), offset=0), offset=0)], SimTypeInt(signed=True, label="Int32"), arg_names=["hChange", "pdwChange", "pvReserved", "ppPrinterNotifyInfo"]),
#
'FreePrinterNotifyInfo': SimTypeFunction([SimTypePointer(SimStruct({"Version": SimTypeInt(signed=False, label="UInt32"), "Flags": SimTypeInt(signed=False, label="UInt32"), "Count": SimTypeInt(signed=False, label="UInt32"), "aData": SimTypePointer(SimStruct({"Type": SimTypeShort(signed=False, label="UInt16"), "Field": SimTypeShort(signed=False, label="UInt16"), "Reserved": SimTypeInt(signed=False, label="UInt32"), "Id": SimTypeInt(signed=False, label="UInt32"), "NotifyData": SimUnion({"adwData": SimTypeFixedSizeArray(SimTypeInt(signed=False, label="UInt32"), 2), "Data": SimStruct({"cbBuf": SimTypeInt(signed=False, label="UInt32"), "pBuf": SimTypePointer(SimTypeBottom(label="Void"), offset=0)}, name="_Data_e__Struct", pack=False, align=None)}, name="<anon>", label="None")}, name="PRINTER_NOTIFY_INFO_DATA", pack=False, align=None), offset=0)}, name="PRINTER_NOTIFY_INFO", pack=False, align=None), offset=0)], SimTypeInt(signed=True, label="Int32"), arg_names=["pPrinterNotifyInfo"]),
#
'FindClosePrinterChangeNotification': SimTypeFunction([SimTypePointer(SimTypeInt(signed=True, label="Int"), label="IntPtr", offset=0)], SimTypeInt(signed=True, label="Int32"), arg_names=["hChange"]),
#
'PrinterMessageBoxA': SimTypeFunction([SimTypePointer(SimTypeInt(signed=True, label="Int"), label="IntPtr", offset=0), SimTypeInt(signed=False, label="UInt32"), SimTypePointer(SimTypeInt(signed=True, label="Int"), label="IntPtr", offset=0), SimTypePointer(SimTypeChar(label="Byte"), offset=0), SimTypePointer(SimTypeChar(label="Byte"), offset=0), SimTypeInt(signed=False, label="UInt32")], SimTypeInt(signed=False, label="UInt32"), arg_names=["hPrinter", "Error", "hWnd", "pText", "pCaption", "dwType"]),
#
'PrinterMessageBoxW': SimTypeFunction([SimTypePointer(SimTypeInt(signed=True, label="Int"), label="IntPtr", offset=0), SimTypeInt(signed=False, label="UInt32"), SimTypePointer(SimTypeInt(signed=True, label="Int"), label="IntPtr", offset=0), SimTypePointer(SimTypeChar(label="Char"), offset=0), SimTypePointer(SimTypeChar(label="Char"), offset=0), SimTypeInt(signed=False, label="UInt32")], SimTypeInt(signed=False, label="UInt32"), arg_names=["hPrinter", "Error", "hWnd", "pText", "pCaption", "dwType"]),
#
'ClosePrinter': SimTypeFunction([SimTypePointer(SimTypeInt(signed=True, label="Int"), label="IntPtr", offset=0)], SimTypeInt(signed=True, label="Int32"), arg_names=["hPrinter"]),
#
'AddFormA': SimTypeFunction([SimTypePointer(SimTypeInt(signed=True, label="Int"), label="IntPtr", offset=0), SimTypeInt(signed=False, label="UInt32"), SimTypePointer(SimTypeChar(label="Byte"), offset=0)], SimTypeInt(signed=True, label="Int32"), arg_names=["hPrinter", "Level", "pForm"]),
#
'AddFormW': SimTypeFunction([SimTypePointer(SimTypeInt(signed=True, label="Int"), label="IntPtr", offset=0), SimTypeInt(signed=False, label="UInt32"), SimTypePointer(SimTypeChar(label="Byte"), offset=0)], SimTypeInt(signed=True, label="Int32"), arg_names=["hPrinter", "Level", "pForm"]),
#
'DeleteFormA': SimTypeFunction([SimTypePointer(SimTypeInt(signed=True, label="Int"), label="IntPtr", offset=0), SimTypePointer(SimTypeChar(label="Byte"), offset=0)], SimTypeInt(signed=True, label="Int32"), arg_names=["hPrinter", "pFormName"]),
#
'DeleteFormW': SimTypeFunction([SimTypePointer(SimTypeInt(signed=True, label="Int"), label="IntPtr", offset=0), SimTypePointer(SimTypeChar(label="Char"), offset=0)], SimTypeInt(signed=True, label="Int32"), arg_names=["hPrinter", "pFormName"]),
#
'GetFormA': SimTypeFunction([SimTypePointer(SimTypeInt(signed=True, label="Int"), label="IntPtr", offset=0), SimTypePointer(SimTypeChar(label="Byte"), offset=0), SimTypeInt(signed=False, label="UInt32"), SimTypePointer(SimTypeChar(label="Byte"), offset=0), SimTypeInt(signed=False, label="UInt32"), SimTypePointer(SimTypeInt(signed=False, label="UInt32"), offset=0)], SimTypeInt(signed=True, label="Int32"), arg_names=["hPrinter", "pFormName", "Level", "pForm", "cbBuf", "pcbNeeded"]),
#
'GetFormW': SimTypeFunction([SimTypePointer(SimTypeInt(signed=True, label="Int"), label="IntPtr", offset=0), SimTypePointer(SimTypeChar(label="Char"), offset=0), SimTypeInt(signed=False, label="UInt32"), SimTypePointer(SimTypeChar(label="Byte"), offset=0), SimTypeInt(signed=False, label="UInt32"), SimTypePointer(SimTypeInt(signed=False, label="UInt32"), offset=0)], SimTypeInt(signed=True, label="Int32"), arg_names=["hPrinter", "pFormName", "Level", "pForm", "cbBuf", "pcbNeeded"]),
#
'SetFormA': SimTypeFunction([SimTypePointer(SimTypeInt(signed=True, label="Int"), label="IntPtr", offset=0), SimTypePointer(SimTypeChar(label="Byte"), offset=0), SimTypeInt(signed=False, label="UInt32"), SimTypePointer(SimTypeChar(label="Byte"), offset=0)], SimTypeInt(signed=True, label="Int32"), arg_names=["hPrinter", "pFormName", "Level", "pForm"]),
#
'SetFormW': SimTypeFunction([SimTypePointer(SimTypeInt(signed=True, label="Int"), label="IntPtr", offset=0), SimTypePointer(SimTypeChar(label="Char"), offset=0), SimTypeInt(signed=False, label="UInt32"), SimTypePointer(SimTypeChar(label="Byte"), offset=0)], SimTypeInt(signed=True, label="Int32"), arg_names=["hPrinter", "pFormName", "Level", "pForm"]),
#
'EnumFormsA': SimTypeFunction([SimTypePointer(SimTypeInt(signed=True, label="Int"), label="IntPtr", offset=0), SimTypeInt(signed=False, label="UInt32"), SimTypePointer(SimTypeChar(label="Byte"), offset=0), SimTypeInt(signed=False, label="UInt32"), SimTypePointer(SimTypeInt(signed=False, label="UInt32"), offset=0), SimTypePointer(SimTypeInt(signed=False, label="UInt32"), offset=0)], SimTypeInt(signed=True, label="Int32"), arg_names=["hPrinter", "Level", "pForm", "cbBuf", "pcbNeeded", "pcReturned"]),
#
'EnumFormsW': SimTypeFunction([SimTypePointer(SimTypeInt(signed=True, label="Int"), label="IntPtr", offset=0), SimTypeInt(signed=False, label="UInt32"), SimTypePointer(SimTypeChar(label="Byte"), offset=0), SimTypeInt(signed=False, label="UInt32"), SimTypePointer(SimTypeInt(signed=False, label="UInt32"), offset=0), SimTypePointer(SimTypeInt(signed=False, label="UInt32"), offset=0)], SimTypeInt(signed=True, label="Int32"), arg_names=["hPrinter", "Level", "pForm", "cbBuf", "pcbNeeded", "pcReturned"]),
#
'EnumMonitorsA': SimTypeFunction([SimTypePointer(SimTypeChar(label="Byte"), offset=0), SimTypeInt(signed=False, label="UInt32"), SimTypePointer(SimTypeChar(label="Byte"), offset=0), SimTypeInt(signed=False, label="UInt32"), SimTypePointer(SimTypeInt(signed=False, label="UInt32"), offset=0), SimTypePointer(SimTypeInt(signed=False, label="UInt32"), offset=0)], SimTypeInt(signed=True, label="Int32"), arg_names=["pName", "Level", "pMonitor", "cbBuf", "pcbNeeded", "pcReturned"]),
#
'EnumMonitorsW': SimTypeFunction([SimTypePointer(SimTypeChar(label="Char"), offset=0), SimTypeInt(signed=False, label="UInt32"), SimTypePointer(SimTypeChar(label="Byte"), offset=0), SimTypeInt(signed=False, label="UInt32"), SimTypePointer(SimTypeInt(signed=False, label="UInt32"), offset=0), SimTypePointer(SimTypeInt(signed=False, label="UInt32"), offset=0)], SimTypeInt(signed=True, label="Int32"), arg_names=["pName", "Level", "pMonitor", "cbBuf", "pcbNeeded", "pcReturned"]),
#
'AddMonitorA': SimTypeFunction([SimTypePointer(SimTypeChar(label="Byte"), offset=0), SimTypeInt(signed=False, label="UInt32"), SimTypePointer(SimTypeChar(label="Byte"), offset=0)], SimTypeInt(signed=True, label="Int32"), arg_names=["pName", "Level", "pMonitors"]),
#
'AddMonitorW': SimTypeFunction([SimTypePointer(SimTypeChar(label="Char"), offset=0), SimTypeInt(signed=False, label="UInt32"), SimTypePointer(SimTypeChar(label="Byte"), offset=0)], SimTypeInt(signed=True, label="Int32"), arg_names=["pName", "Level", "pMonitors"]),
#
'DeleteMonitorA': SimTypeFunction([SimTypePointer(SimTypeChar(label="Byte"), offset=0), SimTypePointer(SimTypeChar(label="Byte"), offset=0), SimTypePointer(SimTypeChar(label="Byte"), offset=0)], SimTypeInt(signed=True, label="Int32"), arg_names=["pName", "pEnvironment", "pMonitorName"]),
#
'DeleteMonitorW': SimTypeFunction([SimTypePointer(SimTypeChar(label="Char"), offset=0), SimTypePointer(SimTypeChar(label="Char"), offset=0), SimTypePointer(SimTypeChar(label="Char"), offset=0)], SimTypeInt(signed=True, label="Int32"), arg_names=["pName", "pEnvironment", "pMonitorName"]),
#
'EnumPortsA': SimTypeFunction([SimTypePointer(SimTypeChar(label="Byte"), offset=0), SimTypeInt(signed=False, label="UInt32"), SimTypePointer(SimTypeChar(label="Byte"), offset=0), SimTypeInt(signed=False, label="UInt32"), SimTypePointer(SimTypeInt(signed=False, label="UInt32"), offset=0), SimTypePointer(SimTypeInt(signed=False, label="UInt32"), offset=0)], SimTypeInt(signed=True, label="Int32"), arg_names=["pName", "Level", "pPort", "cbBuf", "pcbNeeded", "pcReturned"]),
#
'EnumPortsW': SimTypeFunction([SimTypePointer(SimTypeChar(label="Char"), offset=0), SimTypeInt(signed=False, label="UInt32"), SimTypePointer(SimTypeChar(label="Byte"), offset=0), SimTypeInt(signed=False, label="UInt32"), SimTypePointer(SimTypeInt(signed=False, label="UInt32"), offset=0), SimTypePointer(SimTypeInt(signed=False, label="UInt32"), offset=0)], SimTypeInt(signed=True, label="Int32"), arg_names=["pName", "Level", "pPort", "cbBuf", "pcbNeeded", "pcReturned"]),
#
'AddPortA': SimTypeFunction([SimTypePointer(SimTypeChar(label="Byte"), offset=0), SimTypePointer(SimTypeInt(signed=True, label="Int"), label="IntPtr", offset=0), SimTypePointer(SimTypeChar(label="Byte"), offset=0)], SimTypeInt(signed=True, label="Int32"), arg_names=["pName", "hWnd", "pMonitorName"]),
#
'AddPortW': SimTypeFunction([SimTypePointer(SimTypeChar(label="Char"), offset=0), SimTypePointer(SimTypeInt(signed=True, label="Int"), label="IntPtr", offset=0), SimTypePointer(SimTypeChar(label="Char"), offset=0)], SimTypeInt(signed=True, label="Int32"), arg_names=["pName", "hWnd", "pMonitorName"]),
#
'ConfigurePortA': SimTypeFunction([SimTypePointer(SimTypeChar(label="Byte"), offset=0), SimTypePointer(SimTypeInt(signed=True, label="Int"), label="IntPtr", offset=0), SimTypePointer(SimTypeChar(label="Byte"), offset=0)], SimTypeInt(signed=True, label="Int32"), arg_names=["pName", "hWnd", "pPortName"]),
#
'ConfigurePortW': SimTypeFunction([SimTypePointer(SimTypeChar(label="Char"), offset=0), SimTypePointer(SimTypeInt(signed=True, label="Int"), label="IntPtr", offset=0), SimTypePointer(SimTypeChar(label="Char"), offset=0)], SimTypeInt(signed=True, label="Int32"), arg_names=["pName", "hWnd", "pPortName"]),
#
'DeletePortA': SimTypeFunction([SimTypePointer(SimTypeChar(label="Byte"), offset=0), SimTypePointer(SimTypeInt(signed=True, label="Int"), label="IntPtr", offset=0), SimTypePointer(SimTypeChar(label="Byte"), offset=0)], SimTypeInt(signed=True, label="Int32"), arg_names=["pName", "hWnd", "pPortName"]),
#
'DeletePortW': SimTypeFunction([SimTypePointer(SimTypeChar(label="Char"), offset=0), SimTypePointer(SimTypeInt(signed=True, label="Int"), label="IntPtr", offset=0), SimTypePointer(SimTypeChar(label="Char"), offset=0)], SimTypeInt(signed=True, label="Int32"), arg_names=["pName", "hWnd", "pPortName"]),
#
'XcvDataW': SimTypeFunction([SimTypePointer(SimTypeInt(signed=True, label="Int"), label="IntPtr", offset=0), SimTypePointer(SimTypeChar(label="Char"), offset=0), SimTypePointer(SimTypeChar(label="Byte"), offset=0), SimTypeInt(signed=False, label="UInt32"), SimTypePointer(SimTypeChar(label="Byte"), offset=0), SimTypeInt(signed=False, label="UInt32"), SimTypePointer(SimTypeInt(signed=False, label="UInt32"), offset=0), SimTypePointer(SimTypeInt(signed=False, label="UInt32"), offset=0)], SimTypeInt(signed=True, label="Int32"), arg_names=["hXcv", "pszDataName", "pInputData", "cbInputData", "pOutputData", "cbOutputData", "pcbOutputNeeded", "pdwStatus"]),
#
'GetDefaultPrinterA': SimTypeFunction([SimTypePointer(SimTypeChar(label="Byte"), label="LPArray", offset=0), SimTypePointer(SimTypeInt(signed=False, label="UInt32"), offset=0)], SimTypeInt(signed=True, label="Int32"), arg_names=["pszBuffer", "pcchBuffer"]),
#
'GetDefaultPrinterW': SimTypeFunction([SimTypePointer(SimTypeChar(label="Char"), label="LPArray", offset=0), SimTypePointer(SimTypeInt(signed=False, label="UInt32"), offset=0)], SimTypeInt(signed=True, label="Int32"), arg_names=["pszBuffer", "pcchBuffer"]),
#
'SetDefaultPrinterA': SimTypeFunction([SimTypePointer(SimTypeChar(label="Byte"), offset=0)], SimTypeInt(signed=True, label="Int32"), arg_names=["pszPrinter"]),
#
'SetDefaultPrinterW': SimTypeFunction([SimTypePointer(SimTypeChar(label="Char"), offset=0)], SimTypeInt(signed=True, label="Int32"), arg_names=["pszPrinter"]),
#
'SetPortA': SimTypeFunction([SimTypePointer(SimTypeChar(label="Byte"), offset=0), SimTypePointer(SimTypeChar(label="Byte"), offset=0), SimTypeInt(signed=False, label="UInt32"), SimTypePointer(SimTypeChar(label="Byte"), offset=0)], SimTypeInt(signed=True, label="Int32"), arg_names=["pName", "pPortName", "dwLevel", "pPortInfo"]),
#
'SetPortW': SimTypeFunction([SimTypePointer(SimTypeChar(label="Char"), offset=0), SimTypePointer(SimTypeChar(label="Char"), offset=0), SimTypeInt(signed=False, label="UInt32"), SimTypePointer(SimTypeChar(label="Byte"), offset=0)], SimTypeInt(signed=True, label="Int32"), arg_names=["pName", "pPortName", "dwLevel", "pPortInfo"]),
#
'AddPrinterConnectionA': SimTypeFunction([SimTypePointer(SimTypeChar(label="Byte"), offset=0)], SimTypeInt(signed=True, label="Int32"), arg_names=["pName"]),
#
'AddPrinterConnectionW': SimTypeFunction([SimTypePointer(SimTypeChar(label="Char"), offset=0)], SimTypeInt(signed=True, label="Int32"), arg_names=["pName"]),
#
'DeletePrinterConnectionA': SimTypeFunction([SimTypePointer(SimTypeChar(label="Byte"), offset=0)], SimTypeInt(signed=True, label="Int32"), arg_names=["pName"]),
#
'DeletePrinterConnectionW': SimTypeFunction([SimTypePointer(SimTypeChar(label="Char"), offset=0)], SimTypeInt(signed=True, label="Int32"), arg_names=["pName"]),
#
'ConnectToPrinterDlg': SimTypeFunction([SimTypePointer(SimTypeInt(signed=True, label="Int"), label="IntPtr", offset=0), SimTypeInt(signed=False, label="UInt32")], SimTypePointer(SimTypeInt(signed=True, label="Int"), label="IntPtr", offset=0), arg_names=["hwnd", "Flags"]),
#
'AddPrintProvidorA': SimTypeFunction([SimTypePointer(SimTypeChar(label="Byte"), offset=0), SimTypeInt(signed=False, label="UInt32"), SimTypePointer(SimTypeChar(label="Byte"), offset=0)], SimTypeInt(signed=True, label="Int32"), arg_names=["pName", "Level", "pProvidorInfo"]),
#
'AddPrintProvidorW': SimTypeFunction([SimTypePointer(SimTypeChar(label="Char"), offset=0), SimTypeInt(signed=False, label="UInt32"), SimTypePointer(SimTypeChar(label="Byte"), offset=0)], SimTypeInt(signed=True, label="Int32"), arg_names=["pName", "Level", "pProvidorInfo"]),
#
'DeletePrintProvidorA': SimTypeFunction([SimTypePointer(SimTypeChar(label="Byte"), offset=0), SimTypePointer(SimTypeChar(label="Byte"), offset=0), SimTypePointer(SimTypeChar(label="Byte"), offset=0)], SimTypeInt(signed=True, label="Int32"), arg_names=["pName", "pEnvironment", "pPrintProvidorName"]),
#
'DeletePrintProvidorW': SimTypeFunction([SimTypePointer(SimTypeChar(label="Char"), offset=0), SimTypePointer(SimTypeChar(label="Char"), offset=0), SimTypePointer(SimTypeChar(label="Char"), offset=0)], SimTypeInt(signed=True, label="Int32"), arg_names=["pName", "pEnvironment", "pPrintProvidorName"]),
#
'IsValidDevmodeA': SimTypeFunction([SimTypePointer(SimStruct({"dmDeviceName": SimTypeFixedSizeArray(SimTypeChar(label="Byte"), 32), "dmSpecVersion": SimTypeShort(signed=False, label="UInt16"), "dmDriverVersion": SimTypeShort(signed=False, label="UInt16"), "dmSize": SimTypeShort(signed=False, label="UInt16"), "dmDriverExtra": SimTypeShort(signed=False, label="UInt16"), "dmFields": SimTypeInt(signed=False, label="UInt32"), "Anonymous1": SimUnion({"Anonymous1": SimStruct({"dmOrientation": SimTypeShort(signed=True, label="Int16"), "dmPaperSize": SimTypeShort(signed=True, label="Int16"), "dmPaperLength": SimTypeShort(signed=True, label="Int16"), "dmPaperWidth": SimTypeShort(signed=True, label="Int16"), "dmScale": SimTypeShort(signed=True, label="Int16"), "dmCopies": SimTypeShort(signed=True, label="Int16"), "dmDefaultSource": SimTypeShort(signed=True, label="Int16"), "dmPrintQuality": SimTypeShort(signed=True, label="Int16")}, name="_Anonymous1_e__Struct", pack=False, align=None), "Anonymous2": SimStruct({"dmPosition": SimStruct({"x": SimTypeInt(signed=True, label="Int32"), "y": SimTypeInt(signed=True, label="Int32")}, name="POINTL", pack=False, align=None), "dmDisplayOrientation": SimTypeInt(signed=False, label="UInt32"), "dmDisplayFixedOutput": SimTypeInt(signed=False, label="UInt32")}, name="_Anonymous2_e__Struct", pack=False, align=None)}, name="<anon>", label="None"), "dmColor": SimTypeShort(signed=True, label="Int16"), "dmDuplex": SimTypeShort(signed=True, label="Int16"), "dmYResolution": SimTypeShort(signed=True, label="Int16"), "dmTTOption": SimTypeShort(signed=True, label="Int16"), "dmCollate": SimTypeShort(signed=True, label="Int16"), "dmFormName": SimTypeFixedSizeArray(SimTypeChar(label="Byte"), 32), "dmLogPixels": SimTypeShort(signed=False, label="UInt16"), "dmBitsPerPel": SimTypeInt(signed=False, label="UInt32"), "dmPelsWidth": SimTypeInt(signed=False, label="UInt32"), "dmPelsHeight": SimTypeInt(signed=False, label="UInt32"), "Anonymous2": SimUnion({"dmDisplayFlags": SimTypeInt(signed=False, label="UInt32"), "dmNup": SimTypeInt(signed=False, label="UInt32")}, name="<anon>", label="None"), "dmDisplayFrequency": SimTypeInt(signed=False, label="UInt32"), "dmICMMethod": SimTypeInt(signed=False, label="UInt32"), "dmICMIntent": SimTypeInt(signed=False, label="UInt32"), "dmMediaType": SimTypeInt(signed=False, label="UInt32"), "dmDitherType": SimTypeInt(signed=False, label="UInt32"), "dmReserved1": SimTypeInt(signed=False, label="UInt32"), "dmReserved2": SimTypeInt(signed=False, label="UInt32"), "dmPanningWidth": SimTypeInt(signed=False, label="UInt32"), "dmPanningHeight": SimTypeInt(signed=False, label="UInt32")}, name="DEVMODEA", pack=False, align=None), offset=0), SimTypePointer(SimTypeInt(signed=False, label="UInt"), label="UIntPtr", offset=0)], SimTypeInt(signed=True, label="Int32"), arg_names=["pDevmode", "DevmodeSize"]),
#
'IsValidDevmodeW': SimTypeFunction([SimTypePointer(SimStruct({"dmDeviceName": SimTypeFixedSizeArray(SimTypeChar(label="Char"), 32), "dmSpecVersion": SimTypeShort(signed=False, label="UInt16"), "dmDriverVersion": SimTypeShort(signed=False, label="UInt16"), "dmSize": SimTypeShort(signed=False, label="UInt16"), "dmDriverExtra": SimTypeShort(signed=False, label="UInt16"), "dmFields": SimTypeInt(signed=False, label="UInt32"), "Anonymous1": SimUnion({"Anonymous1": SimStruct({"dmOrientation": SimTypeShort(signed=True, label="Int16"), "dmPaperSize": SimTypeShort(signed=True, label="Int16"), "dmPaperLength": SimTypeShort(signed=True, label="Int16"), "dmPaperWidth": SimTypeShort(signed=True, label="Int16"), "dmScale": SimTypeShort(signed=True, label="Int16"), "dmCopies": SimTypeShort(signed=True, label="Int16"), "dmDefaultSource": SimTypeShort(signed=True, label="Int16"), "dmPrintQuality": SimTypeShort(signed=True, label="Int16")}, name="_Anonymous1_e__Struct", pack=False, align=None), "Anonymous2": SimStruct({"dmPosition": SimStruct({"x": SimTypeInt(signed=True, label="Int32"), "y": SimTypeInt(signed=True, label="Int32")}, name="POINTL", pack=False, align=None), "dmDisplayOrientation": SimTypeInt(signed=False, label="UInt32"), "dmDisplayFixedOutput": SimTypeInt(signed=False, label="UInt32")}, name="_Anonymous2_e__Struct", pack=False, align=None)}, name="<anon>", label="None"), "dmColor": SimTypeShort(signed=True, label="Int16"), "dmDuplex": SimTypeShort(signed=True, label="Int16"), "dmYResolution": SimTypeShort(signed=True, label="Int16"), "dmTTOption": SimTypeShort(signed=True, label="Int16"), "dmCollate": SimTypeShort(signed=True, label="Int16"), "dmFormName": SimTypeFixedSizeArray(SimTypeChar(label="Char"), 32), "dmLogPixels": SimTypeShort(signed=False, label="UInt16"), "dmBitsPerPel": SimTypeInt(signed=False, label="UInt32"), "dmPelsWidth": SimTypeInt(signed=False, label="UInt32"), "dmPelsHeight": SimTypeInt(signed=False, label="UInt32"), "Anonymous2": SimUnion({"dmDisplayFlags": SimTypeInt(signed=False, label="UInt32"), "dmNup": SimTypeInt(signed=False, label="UInt32")}, name="<anon>", label="None"), "dmDisplayFrequency": SimTypeInt(signed=False, label="UInt32"), "dmICMMethod": SimTypeInt(signed=False, label="UInt32"), "dmICMIntent": SimTypeInt(signed=False, label="UInt32"), "dmMediaType": SimTypeInt(signed=False, label="UInt32"), "dmDitherType": SimTypeInt(signed=False, label="UInt32"), "dmReserved1": SimTypeInt(signed=False, label="UInt32"), "dmReserved2": SimTypeInt(signed=False, label="UInt32"), "dmPanningWidth": SimTypeInt(signed=False, label="UInt32"), "dmPanningHeight": SimTypeInt(signed=False, label="UInt32")}, name="DEVMODEW", pack=False, align=None), offset=0), SimTypePointer(SimTypeInt(signed=False, label="UInt"), label="UIntPtr", offset=0)], SimTypeInt(signed=True, label="Int32"), arg_names=["pDevmode", "DevmodeSize"]),
#
'OpenPrinter2A': SimTypeFunction([SimTypePointer(SimTypeChar(label="Byte"), offset=0), SimTypePointer(SimTypePointer(SimTypeInt(signed=True, label="Int"), label="IntPtr", offset=0), offset=0), SimTypePointer(SimStruct({"pDatatype": SimTypePointer(SimTypeChar(label="Byte"), offset=0), "pDevMode": SimTypePointer(SimTypeBottom(label="DEVMODEA"), offset=0), "DesiredAccess": SimTypeInt(signed=False, label="UInt32")}, name="PRINTER_DEFAULTSA", pack=False, align=None), offset=0), SimTypePointer(SimStruct({"cbSize": SimTypeInt(signed=False, label="UInt32"), "dwFlags": SimTypeInt(signed=False, label="UInt32")}, name="PRINTER_OPTIONSA", pack=False, align=None), offset=0)], SimTypeInt(signed=True, label="Int32"), arg_names=["pPrinterName", "phPrinter", "pDefault", "pOptions"]),
#
'OpenPrinter2W': SimTypeFunction([SimTypePointer(SimTypeChar(label="Char"), offset=0), SimTypePointer(SimTypePointer(SimTypeInt(signed=True, label="Int"), label="IntPtr", offset=0), offset=0), SimTypePointer(SimStruct({"pDatatype": SimTypePointer(SimTypeChar(label="Char"), offset=0), "pDevMode": SimTypePointer(SimTypeBottom(label="DEVMODEW"), offset=0), "DesiredAccess": SimTypeInt(signed=False, label="UInt32")}, name="PRINTER_DEFAULTSW", pack=False, align=None), offset=0), SimTypePointer(SimStruct({"cbSize": SimTypeInt(signed=False, label="UInt32"), "dwFlags": SimTypeInt(signed=False, label="UInt32")}, name="PRINTER_OPTIONSW", pack=False, align=None), offset=0)], SimTypeInt(signed=True, label="Int32"), arg_names=["pPrinterName", "phPrinter", "pDefault", "pOptions"]),
#
'AddPrinterConnection2A': SimTypeFunction([SimTypePointer(SimTypeInt(signed=True, label="Int"), label="IntPtr", offset=0), SimTypePointer(SimTypeChar(label="Byte"), offset=0), SimTypeInt(signed=False, label="UInt32"), SimTypePointer(SimTypeBottom(label="Void"), offset=0)], SimTypeInt(signed=True, label="Int32"), arg_names=["hWnd", "pszName", "dwLevel", "pConnectionInfo"]),
#
'AddPrinterConnection2W': SimTypeFunction([SimTypePointer(SimTypeInt(signed=True, label="Int"), label="IntPtr", offset=0), SimTypePointer(SimTypeChar(label="Char"), offset=0), SimTypeInt(signed=False, label="UInt32"), SimTypePointer(SimTypeBottom(label="Void"), offset=0)], SimTypeInt(signed=True, label="Int32"), arg_names=["hWnd", "pszName", "dwLevel", "pConnectionInfo"]),
#
'InstallPrinterDriverFromPackageA': SimTypeFunction([SimTypePointer(SimTypeChar(label="Byte"), offset=0), SimTypePointer(SimTypeChar(label="Byte"), offset=0), SimTypePointer(SimTypeChar(label="Byte"), offset=0), SimTypePointer(SimTypeChar(label="Byte"), offset=0), SimTypeInt(signed=False, label="UInt32")], SimTypeInt(signed=True, label="Int32"), arg_names=["pszServer", "pszInfPath", "pszDriverName", "pszEnvironment", "dwFlags"]),
#
'InstallPrinterDriverFromPackageW': SimTypeFunction([SimTypePointer(SimTypeChar(label="Char"), offset=0), SimTypePointer(SimTypeChar(label="Char"), offset=0), SimTypePointer(SimTypeChar(label="Char"), offset=0), SimTypePointer(SimTypeChar(label="Char"), offset=0), SimTypeInt(signed=False, label="UInt32")], SimTypeInt(signed=True, label="Int32"), arg_names=["pszServer", "pszInfPath", "pszDriverName", "pszEnvironment", "dwFlags"]),
#
'UploadPrinterDriverPackageA': SimTypeFunction([SimTypePointer(SimTypeChar(label="Byte"), offset=0), SimTypePointer(SimTypeChar(label="Byte"), offset=0), SimTypePointer(SimTypeChar(label="Byte"), offset=0), SimTypeInt(signed=False, label="UInt32"), SimTypePointer(SimTypeInt(signed=True, label="Int"), label="IntPtr", offset=0), SimTypePointer(SimTypeChar(label="Byte"), label="LPArray", offset=0), SimTypePointer(SimTypeInt(signed=False, label="UInt32"), offset=0)], SimTypeInt(signed=True, label="Int32"), arg_names=["pszServer", "pszInfPath", "pszEnvironment", "dwFlags", "hwnd", "pszDestInfPath", "pcchDestInfPath"]),
#
'UploadPrinterDriverPackageW': SimTypeFunction([SimTypePointer(SimTypeChar(label="Char"), offset=0), SimTypePointer(SimTypeChar(label="Char"), offset=0), SimTypePointer(SimTypeChar(label="Char"), offset=0), SimTypeInt(signed=False, label="UInt32"), SimTypePointer(SimTypeInt(signed=True, label="Int"), label="IntPtr", offset=0), SimTypePointer(SimTypeChar(label="Char"), label="LPArray", offset=0), SimTypePointer(SimTypeInt(signed=False, label="UInt32"), offset=0)], SimTypeInt(signed=True, label="Int32"), arg_names=["pszServer", "pszInfPath", "pszEnvironment", "dwFlags", "hwnd", "pszDestInfPath", "pcchDestInfPath"]),
#
'GetCorePrinterDriversA': SimTypeFunction([SimTypePointer(SimTypeChar(label="Byte"), offset=0), SimTypePointer(SimTypeChar(label="Byte"), offset=0), SimTypePointer(SimTypeChar(label="Byte"), offset=0), SimTypeInt(signed=False, label="UInt32"), SimTypePointer(SimStruct({"CoreDriverGUID": SimTypeBottom(label="Guid"), "ftDriverDate": SimStruct({"dwLowDateTime": SimTypeInt(signed=False, label="UInt32"), "dwHighDateTime": SimTypeInt(signed=False, label="UInt32")}, name="FILETIME", pack=False, align=None), "dwlDriverVersion": SimTypeLongLong(signed=False, label="UInt64"), "szPackageID": SimTypeFixedSizeArray(SimTypeBottom(label="CHAR"), 260)}, name="CORE_PRINTER_DRIVERA", pack=False, align=None), label="LPArray", offset=0)], SimTypeInt(signed=True, label="Int32"), arg_names=["pszServer", "pszEnvironment", "pszzCoreDriverDependencies", "cCorePrinterDrivers", "pCorePrinterDrivers"]),
#
'GetCorePrinterDriversW': SimTypeFunction([SimTypePointer(SimTypeChar(label="Char"), offset=0), SimTypePointer(SimTypeChar(label="Char"), offset=0), SimTypePointer(SimTypeChar(label="Char"), offset=0), SimTypeInt(signed=False, label="UInt32"), SimTypePointer(SimStruct({"CoreDriverGUID": SimTypeBottom(label="Guid"), "ftDriverDate": SimStruct({"dwLowDateTime": SimTypeInt(signed=False, label="UInt32"), "dwHighDateTime": SimTypeInt(signed=False, label="UInt32")}, name="FILETIME", pack=False, align=None), "dwlDriverVersion": SimTypeLongLong(signed=False, label="UInt64"), "szPackageID": SimTypeFixedSizeArray(SimTypeChar(label="Char"), 260)}, name="CORE_PRINTER_DRIVERW", pack=False, align=None), label="LPArray", offset=0)], SimTypeInt(signed=True, label="Int32"), arg_names=["pszServer", "pszEnvironment", "pszzCoreDriverDependencies", "cCorePrinterDrivers", "pCorePrinterDrivers"]),
#
'CorePrinterDriverInstalledA': SimTypeFunction([SimTypePointer(SimTypeChar(label="Byte"), offset=0), SimTypePointer(SimTypeChar(label="Byte"), offset=0), SimTypeBottom(label="Guid"), SimStruct({"dwLowDateTime": SimTypeInt(signed=False, label="UInt32"), "dwHighDateTime": SimTypeInt(signed=False, label="UInt32")}, name="FILETIME", pack=False, align=None), SimTypeLongLong(signed=False, label="UInt64"), SimTypePointer(SimTypeInt(signed=True, label="Int32"), offset=0)], SimTypeInt(signed=True, label="Int32"), arg_names=["pszServer", "pszEnvironment", "CoreDriverGUID", "ftDriverDate", "dwlDriverVersion", "pbDriverInstalled"]),
#
'CorePrinterDriverInstalledW': SimTypeFunction([SimTypePointer(SimTypeChar(label="Char"), offset=0), SimTypePointer(SimTypeChar(label="Char"), offset=0), SimTypeBottom(label="Guid"), SimStruct({"dwLowDateTime": SimTypeInt(signed=False, label="UInt32"), "dwHighDateTime": SimTypeInt(signed=False, label="UInt32")}, name="FILETIME", pack=False, align=None), SimTypeLongLong(signed=False, label="UInt64"), SimTypePointer(SimTypeInt(signed=True, label="Int32"), offset=0)], SimTypeInt(signed=True, label="Int32"), arg_names=["pszServer", "pszEnvironment", "CoreDriverGUID", "ftDriverDate", "dwlDriverVersion", "pbDriverInstalled"]),
#
'GetPrinterDriverPackagePathA': SimTypeFunction([SimTypePointer(SimTypeChar(label="Byte"), offset=0), SimTypePointer(SimTypeChar(label="Byte"), offset=0), SimTypePointer(SimTypeChar(label="Byte"), offset=0), SimTypePointer(SimTypeChar(label="Byte"), offset=0), SimTypePointer(SimTypeChar(label="Byte"), label="LPArray", offset=0), SimTypeInt(signed=False, label="UInt32"), SimTypePointer(SimTypeInt(signed=False, label="UInt32"), offset=0)], SimTypeInt(signed=True, label="Int32"), arg_names=["pszServer", "pszEnvironment", "pszLanguage", "pszPackageID", "pszDriverPackageCab", "cchDriverPackageCab", "pcchRequiredSize"]),
#
'GetPrinterDriverPackagePathW': SimTypeFunction([SimTypePointer(SimTypeChar(label="Char"), offset=0), SimTypePointer(SimTypeChar(label="Char"), offset=0), SimTypePointer(SimTypeChar(label="Char"), offset=0), SimTypePointer(SimTypeChar(label="Char"), offset=0), SimTypePointer(SimTypeChar(label="Char"), label="LPArray", offset=0), SimTypeInt(signed=False, label="UInt32"), SimTypePointer(SimTypeInt(signed=False, label="UInt32"), offset=0)], SimTypeInt(signed=True, label="Int32"), arg_names=["pszServer", "pszEnvironment", "pszLanguage", "pszPackageID", "pszDriverPackageCab", "cchDriverPackageCab", "pcchRequiredSize"]),
#
'DeletePrinterDriverPackageA': SimTypeFunction([SimTypePointer(SimTypeChar(label="Byte"), offset=0), SimTypePointer(SimTypeChar(label="Byte"), offset=0), SimTypePointer(SimTypeChar(label="Byte"), offset=0)], SimTypeInt(signed=True, label="Int32"), arg_names=["pszServer", "pszInfPath", "pszEnvironment"]),
#
'DeletePrinterDriverPackageW': SimTypeFunction([SimTypePointer(SimTypeChar(label="Char"), offset=0), SimTypePointer(SimTypeChar(label="Char"), offset=0), SimTypePointer(SimTypeChar(label="Char"), offset=0)], SimTypeInt(signed=True, label="Int32"), arg_names=["pszServer", "pszInfPath", "pszEnvironment"]),
#
'ReportJobProcessingProgress': SimTypeFunction([SimTypePointer(SimTypeInt(signed=True, label="Int"), label="IntPtr", offset=0), SimTypeInt(signed=False, label="UInt32"), SimTypeInt(signed=False, label="EPrintXPSJobOperation"), SimTypeInt(signed=False, label="EPrintXPSJobProgress")], SimTypeInt(signed=True, label="Int32"), arg_names=["printerHandle", "jobId", "jobOperation", "jobProgress"]),
#
'GetPrinterDriver2A': SimTypeFunction([SimTypePointer(SimTypeInt(signed=True, label="Int"), label="IntPtr", offset=0), SimTypePointer(SimTypeInt(signed=True, label="Int"), label="IntPtr", offset=0), SimTypePointer(SimTypeChar(label="Byte"), offset=0), SimTypeInt(signed=False, label="UInt32"), SimTypePointer(SimTypeChar(label="Byte"), offset=0), SimTypeInt(signed=False, label="UInt32"), SimTypePointer(SimTypeInt(signed=False, label="UInt32"), offset=0)], SimTypeInt(signed=True, label="Int32"), arg_names=["hWnd", "hPrinter", "pEnvironment", "Level", "pDriverInfo", "cbBuf", "pcbNeeded"]),
#
'GetPrinterDriver2W': SimTypeFunction([SimTypePointer(SimTypeInt(signed=True, label="Int"), label="IntPtr", offset=0), SimTypePointer(SimTypeInt(signed=True, label="Int"), label="IntPtr", offset=0), SimTypePointer(SimTypeChar(label="Char"), offset=0), SimTypeInt(signed=False, label="UInt32"), SimTypePointer(SimTypeChar(label="Byte"), offset=0), SimTypeInt(signed=False, label="UInt32"), SimTypePointer(SimTypeInt(signed=False, label="UInt32"), offset=0)], SimTypeInt(signed=True, label="Int32"), arg_names=["hWnd", "hPrinter", "pEnvironment", "Level", "pDriverInfo", "cbBuf", "pcbNeeded"]),
#
'GetPrintExecutionData': SimTypeFunction([SimTypePointer(SimStruct({"context": SimTypeInt(signed=False, label="PRINT_EXECUTION_CONTEXT"), "clientAppPID": SimTypeInt(signed=False, label="UInt32")}, name="PRINT_EXECUTION_DATA", pack=False, align=None), offset=0)], SimTypeInt(signed=True, label="Int32"), arg_names=["pData"]),
#
'GetJobNamedPropertyValue': SimTypeFunction([SimTypePointer(SimTypeInt(signed=True, label="Int"), label="IntPtr", offset=0), SimTypeInt(signed=False, label="UInt32"), SimTypePointer(SimTypeChar(label="Char"), offset=0), SimTypePointer(SimStruct({"ePropertyType": SimTypeInt(signed=False, label="EPrintPropertyType"), "value": SimUnion({"propertyByte": SimTypeChar(label="Byte"), "propertyString": SimTypePointer(SimTypeChar(label="Char"), offset=0), "propertyInt32": SimTypeInt(signed=True, label="Int32"), "propertyInt64": SimTypeLongLong(signed=True, label="Int64"), "propertyBlob": SimStruct({"cbBuf": SimTypeInt(signed=False, label="UInt32"), "pBuf": SimTypePointer(SimTypeBottom(label="Void"), offset=0)}, name="_propertyBlob_e__Struct", pack=False, align=None)}, name="<anon>", label="None")}, name="PrintPropertyValue", pack=False, align=None), offset=0)], SimTypeInt(signed=False, label="UInt32"), arg_names=["hPrinter", "JobId", "pszName", "pValue"]),
#
'FreePrintPropertyValue': SimTypeFunction([SimTypePointer(SimStruct({"ePropertyType": SimTypeInt(signed=False, label="EPrintPropertyType"), "value": SimUnion({"propertyByte": SimTypeChar(label="Byte"), "propertyString": SimTypePointer(SimTypeChar(label="Char"), offset=0), "propertyInt32": SimTypeInt(signed=True, label="Int32"), "propertyInt64": SimTypeLongLong(signed=True, label="Int64"), "propertyBlob": SimStruct({"cbBuf": SimTypeInt(signed=False, label="UInt32"), "pBuf": SimTypePointer(SimTypeBottom(label="Void"), offset=0)}, name="_propertyBlob_e__Struct", pack=False, align=None)}, name="<anon>", label="None")}, name="PrintPropertyValue", pack=False, align=None), offset=0)], SimTypeBottom(label="Void"), arg_names=["pValue"]),
#
'FreePrintNamedPropertyArray': SimTypeFunction([SimTypeInt(signed=False, label="UInt32"), SimTypePointer(SimTypePointer(SimStruct({"propertyName": SimTypePointer(SimTypeChar(label="Char"), offset=0), "propertyValue": SimStruct({"ePropertyType": SimTypeInt(signed=False, label="EPrintPropertyType"), "value": SimUnion({"propertyByte": SimTypeChar(label="Byte"), "propertyString": SimTypePointer(SimTypeChar(label="Char"), offset=0), "propertyInt32": SimTypeInt(signed=True, label="Int32"), "propertyInt64": SimTypeLongLong(signed=True, label="Int64"), "propertyBlob": SimStruct({"cbBuf": SimTypeInt(signed=False, label="UInt32"), "pBuf": SimTypePointer(SimTypeBottom(label="Void"), offset=0)}, name="_propertyBlob_e__Struct", pack=False, align=None)}, name="<anon>", label="None")}, name="PrintPropertyValue", pack=False, align=None)}, name="PrintNamedProperty", pack=False, align=None), offset=0), label="LPArray", offset=0)], SimTypeBottom(label="Void"), arg_names=["cProperties", "ppProperties"]),
#
'SetJobNamedProperty': SimTypeFunction([SimTypePointer(SimTypeInt(signed=True, label="Int"), label="IntPtr", offset=0), SimTypeInt(signed=False, label="UInt32"), SimTypePointer(SimStruct({"propertyName": SimTypePointer(SimTypeChar(label="Char"), offset=0), "propertyValue": SimStruct({"ePropertyType": SimTypeInt(signed=False, label="EPrintPropertyType"), "value": SimUnion({"propertyByte": SimTypeChar(label="Byte"), "propertyString": SimTypePointer(SimTypeChar(label="Char"), offset=0), "propertyInt32": SimTypeInt(signed=True, label="Int32"), "propertyInt64": SimTypeLongLong(signed=True, label="Int64"), "propertyBlob": SimStruct({"cbBuf": SimTypeInt(signed=False, label="UInt32"), "pBuf": SimTypePointer(SimTypeBottom(label="Void"), offset=0)}, name="_propertyBlob_e__Struct", pack=False, align=None)}, name="<anon>", label="None")}, name="PrintPropertyValue", pack=False, align=None)}, name="PrintNamedProperty", pack=False, align=None), offset=0)], SimTypeInt(signed=False, label="UInt32"), arg_names=["hPrinter", "JobId", "pProperty"]),
#
'DeleteJobNamedProperty': SimTypeFunction([SimTypePointer(SimTypeInt(signed=True, label="Int"), label="IntPtr", offset=0), SimTypeInt(signed=False, label="UInt32"), SimTypePointer(SimTypeChar(label="Char"), offset=0)], SimTypeInt(signed=False, label="UInt32"), arg_names=["hPrinter", "JobId", "pszName"]),
#
'EnumJobNamedProperties': SimTypeFunction([SimTypePointer(SimTypeInt(signed=True, label="Int"), label="IntPtr", offset=0), SimTypeInt(signed=False, label="UInt32"), SimTypePointer(SimTypeInt(signed=False, label="UInt32"), offset=0), SimTypePointer(SimTypePointer(SimStruct({"propertyName": SimTypePointer(SimTypeChar(label="Char"), offset=0), "propertyValue": SimStruct({"ePropertyType": SimTypeInt(signed=False, label="EPrintPropertyType"), "value": SimUnion({"propertyByte": SimTypeChar(label="Byte"), "propertyString": SimTypePointer(SimTypeChar(label="Char"), offset=0), "propertyInt32": SimTypeInt(signed=True, label="Int32"), "propertyInt64": SimTypeLongLong(signed=True, label="Int64"), "propertyBlob": SimStruct({"cbBuf": SimTypeInt(signed=False, label="UInt32"), "pBuf": SimTypePointer(SimTypeBottom(label="Void"), offset=0)}, name="_propertyBlob_e__Struct", pack=False, align=None)}, name="<anon>", label="None")}, name="PrintPropertyValue", pack=False, align=None)}, name="PrintNamedProperty", pack=False, align=None), offset=0), offset=0)], SimTypeInt(signed=False, label="UInt32"), arg_names=["hPrinter", "JobId", "pcProperties", "ppProperties"]),
#
'GetPrintOutputInfo': SimTypeFunction([SimTypePointer(SimTypeInt(signed=True, label="Int"), label="IntPtr", offset=0), SimTypePointer(SimTypeChar(label="Char"), offset=0), SimTypePointer(SimTypePointer(SimTypeInt(signed=True, label="Int"), label="IntPtr", offset=0), offset=0), SimTypePointer(SimTypePointer(SimTypeChar(label="Char"), offset=0), offset=0)], SimTypeInt(signed=True, label="Int32"), arg_names=["hWnd", "pszPrinter", "phFile", "ppszOutputFile"]),
#
'DevQueryPrintEx': SimTypeFunction([SimTypePointer(SimStruct({"cbSize": SimTypeShort(signed=False, label="UInt16"), "Level": SimTypeShort(signed=False, label="UInt16"), "hPrinter": SimTypePointer(SimTypeInt(signed=True, label="Int"), label="IntPtr", offset=0), "pDevMode": SimTypePointer(SimTypeBottom(label="DEVMODEA"), offset=0), "pszErrorStr": SimTypePointer(SimTypeChar(label="Char"), offset=0), "cchErrorStr": SimTypeInt(signed=False, label="UInt32"), "cchNeeded": SimTypeInt(signed=False, label="UInt32")}, name="DEVQUERYPRINT_INFO", pack=False, align=None), offset=0)], SimTypeInt(signed=True, label="Int32"), arg_names=["pDQPInfo"]),
#
'RegisterForPrintAsyncNotifications': SimTypeFunction([SimTypePointer(SimTypeChar(label="Char"), offset=0), SimTypePointer(SimTypeBottom(label="Guid"), offset=0), SimTypeInt(signed=False, label="PrintAsyncNotifyUserFilter"), SimTypeInt(signed=False, label="PrintAsyncNotifyConversationStyle"), SimTypeBottom(label="IPrintAsyncNotifyCallback"), SimTypePointer(SimTypePointer(SimTypeInt(signed=True, label="Int"), label="IntPtr", offset=0), offset=0)], SimTypeInt(signed=True, label="Int32"), arg_names=["pszName", "pNotificationType", "eUserFilter", "eConversationStyle", "pCallback", "phNotify"]),
#
'UnRegisterForPrintAsyncNotifications': SimTypeFunction([SimTypePointer(SimTypeInt(signed=True, label="Int"), label="IntPtr", offset=0)], SimTypeInt(signed=True, label="Int32"), arg_names=["param0"]),
#
'CreatePrintAsyncNotifyChannel': SimTypeFunction([SimTypePointer(SimTypeChar(label="Char"), offset=0), SimTypePointer(SimTypeBottom(label="Guid"), offset=0), SimTypeInt(signed=False, label="PrintAsyncNotifyUserFilter"), SimTypeInt(signed=False, label="PrintAsyncNotifyConversationStyle"), SimTypeBottom(label="IPrintAsyncNotifyCallback"), SimTypePointer(SimTypeBottom(label="IPrintAsyncNotifyChannel"), offset=0)], SimTypeInt(signed=True, label="Int32"), arg_names=["pszName", "pNotificationType", "eUserFilter", "eConversationStyle", "pCallback", "ppIAsynchNotification"]),
#
'CreatePrinterIC': SimTypeFunction([SimTypePointer(SimTypeInt(signed=True, label="Int"), label="IntPtr", offset=0), SimTypePointer(SimStruct({"dmDeviceName": SimTypeFixedSizeArray(SimTypeChar(label="Char"), 32), "dmSpecVersion": SimTypeShort(signed=False, label="UInt16"), "dmDriverVersion": SimTypeShort(signed=False, label="UInt16"), "dmSize": SimTypeShort(signed=False, label="UInt16"), "dmDriverExtra": SimTypeShort(signed=False, label="UInt16"), "dmFields": SimTypeInt(signed=False, label="UInt32"), "Anonymous1": SimUnion({"Anonymous1": SimStruct({"dmOrientation": SimTypeShort(signed=True, label="Int16"), "dmPaperSize": SimTypeShort(signed=True, label="Int16"), "dmPaperLength": SimTypeShort(signed=True, label="Int16"), "dmPaperWidth": SimTypeShort(signed=True, label="Int16"), "dmScale": SimTypeShort(signed=True, label="Int16"), "dmCopies": SimTypeShort(signed=True, label="Int16"), "dmDefaultSource": SimTypeShort(signed=True, label="Int16"), "dmPrintQuality": SimTypeShort(signed=True, label="Int16")}, name="_Anonymous1_e__Struct", pack=False, align=None), "Anonymous2": SimStruct({"dmPosition": SimStruct({"x": SimTypeInt(signed=True, label="Int32"), "y": SimTypeInt(signed=True, label="Int32")}, name="POINTL", pack=False, align=None), "dmDisplayOrientation": SimTypeInt(signed=False, label="UInt32"), "dmDisplayFixedOutput": SimTypeInt(signed=False, label="UInt32")}, name="_Anonymous2_e__Struct", pack=False, align=None)}, name="<anon>", label="None"), "dmColor": SimTypeShort(signed=True, label="Int16"), "dmDuplex": SimTypeShort(signed=True, label="Int16"), "dmYResolution": SimTypeShort(signed=True, label="Int16"), "dmTTOption": SimTypeShort(signed=True, label="Int16"), "dmCollate": SimTypeShort(signed=True, label="Int16"), "dmFormName": SimTypeFixedSizeArray(SimTypeChar(label="Char"), 32), "dmLogPixels": SimTypeShort(signed=False, label="UInt16"), "dmBitsPerPel": SimTypeInt(signed=False, label="UInt32"), "dmPelsWidth": SimTypeInt(signed=False, label="UInt32"), "dmPelsHeight": SimTypeInt(signed=False, label="UInt32"), "Anonymous2": SimUnion({"dmDisplayFlags": SimTypeInt(signed=False, label="UInt32"), "dmNup": SimTypeInt(signed=False, label="UInt32")}, name="<anon>", label="None"), "dmDisplayFrequency": SimTypeInt(signed=False, label="UInt32"), "dmICMMethod": SimTypeInt(signed=False, label="UInt32"), "dmICMIntent": SimTypeInt(signed=False, label="UInt32"), "dmMediaType": SimTypeInt(signed=False, label="UInt32"), "dmDitherType": SimTypeInt(signed=False, label="UInt32"), "dmReserved1": SimTypeInt(signed=False, label="UInt32"), "dmReserved2": SimTypeInt(signed=False, label="UInt32"), "dmPanningWidth": SimTypeInt(signed=False, label="UInt32"), "dmPanningHeight": SimTypeInt(signed=False, label="UInt32")}, name="DEVMODEW", pack=False, align=None), offset=0)], SimTypePointer(SimTypeInt(signed=True, label="Int"), label="IntPtr", offset=0), arg_names=["hPrinter", "pDevMode"]),
#
'PlayGdiScriptOnPrinterIC': SimTypeFunction([SimTypePointer(SimTypeInt(signed=True, label="Int"), label="IntPtr", offset=0), SimTypePointer(SimTypeChar(label="Byte"), offset=0), SimTypeInt(signed=False, label="UInt32"), SimTypePointer(SimTypeChar(label="Byte"), offset=0), SimTypeInt(signed=False, label="UInt32"), SimTypeInt(signed=False, label="UInt32")], SimTypeInt(signed=True, label="Int32"), arg_names=["hPrinterIC", "pIn", "cIn", "pOut", "cOut", "ul"]),
#
'DeletePrinterIC': SimTypeFunction([SimTypePointer(SimTypeInt(signed=True, label="Int"), label="IntPtr", offset=0)], SimTypeInt(signed=True, label="Int32"), arg_names=["hPrinterIC"]),
#
'DevQueryPrint': SimTypeFunction([SimTypePointer(SimTypeInt(signed=True, label="Int"), label="IntPtr", offset=0), SimTypePointer(SimStruct({"dmDeviceName": SimTypeFixedSizeArray(SimTypeChar(label="Byte"), 32), "dmSpecVersion": SimTypeShort(signed=False, label="UInt16"), "dmDriverVersion": SimTypeShort(signed=False, label="UInt16"), "dmSize": SimTypeShort(signed=False, label="UInt16"), "dmDriverExtra": SimTypeShort(signed=False, label="UInt16"), "dmFields": SimTypeInt(signed=False, label="UInt32"), "Anonymous1": SimUnion({"Anonymous1": SimStruct({"dmOrientation": SimTypeShort(signed=True, label="Int16"), "dmPaperSize": SimTypeShort(signed=True, label="Int16"), "dmPaperLength": SimTypeShort(signed=True, label="Int16"), "dmPaperWidth": SimTypeShort(signed=True, label="Int16"), "dmScale": SimTypeShort(signed=True, label="Int16"), "dmCopies": SimTypeShort(signed=True, label="Int16"), "dmDefaultSource": SimTypeShort(signed=True, label="Int16"), "dmPrintQuality": SimTypeShort(signed=True, label="Int16")}, name="_Anonymous1_e__Struct", pack=False, align=None), "Anonymous2": SimStruct({"dmPosition": SimStruct({"x": SimTypeInt(signed=True, label="Int32"), "y": SimTypeInt(signed=True, label="Int32")}, name="POINTL", pack=False, align=None), "dmDisplayOrientation": SimTypeInt(signed=False, label="UInt32"), "dmDisplayFixedOutput": SimTypeInt(signed=False, label="UInt32")}, name="_Anonymous2_e__Struct", pack=False, align=None)}, name="<anon>", label="None"), "dmColor": SimTypeShort(signed=True, label="Int16"), "dmDuplex": SimTypeShort(signed=True, label="Int16"), "dmYResolution": SimTypeShort(signed=True, label="Int16"), "dmTTOption": SimTypeShort(signed=True, label="Int16"), "dmCollate": SimTypeShort(signed=True, label="Int16"), "dmFormName": SimTypeFixedSizeArray(SimTypeChar(label="Byte"), 32), "dmLogPixels": SimTypeShort(signed=False, label="UInt16"), "dmBitsPerPel": SimTypeInt(signed=False, label="UInt32"), "dmPelsWidth": SimTypeInt(signed=False, label="UInt32"), "dmPelsHeight": SimTypeInt(signed=False, label="UInt32"), "Anonymous2": SimUnion({"dmDisplayFlags": SimTypeInt(signed=False, label="UInt32"), "dmNup": SimTypeInt(signed=False, label="UInt32")}, name="<anon>", label="None"), "dmDisplayFrequency": SimTypeInt(signed=False, label="UInt32"), "dmICMMethod": SimTypeInt(signed=False, label="UInt32"), "dmICMIntent": SimTypeInt(signed=False, label="UInt32"), "dmMediaType": SimTypeInt(signed=False, label="UInt32"), "dmDitherType": SimTypeInt(signed=False, label="UInt32"), "dmReserved1": SimTypeInt(signed=False, label="UInt32"), "dmReserved2": SimTypeInt(signed=False, label="UInt32"), "dmPanningWidth": SimTypeInt(signed=False, label="UInt32"), "dmPanningHeight": SimTypeInt(signed=False, label="UInt32")}, name="DEVMODEA", pack=False, align=None), offset=0), SimTypePointer(SimTypeInt(signed=False, label="UInt32"), offset=0)], SimTypeInt(signed=True, label="Int32"), arg_names=["hPrinter", "pDevMode", "pResID"]),
#
'RouterFreeBidiResponseContainer': SimTypeFunction([SimTypePointer(SimStruct({"Version": SimTypeInt(signed=False, label="UInt32"), "Flags": SimTypeInt(signed=False, label="UInt32"), "Count": SimTypeInt(signed=False, label="UInt32"), "aData": SimTypePointer(SimStruct({"dwResult": SimTypeInt(signed=False, label="UInt32"), "dwReqNumber": SimTypeInt(signed=False, label="UInt32"), "pSchema": SimTypePointer(SimTypeChar(label="Char"), offset=0), "data": SimStruct({"dwBidiType": SimTypeInt(signed=False, label="UInt32"), "u": SimUnion({"bData": SimTypeInt(signed=True, label="Int32"), "iData": SimTypeInt(signed=True, label="Int32"), "sData": SimTypePointer(SimTypeChar(label="Char"), offset=0), "fData": SimTypeFloat(size=32), "biData": SimStruct({"cbBuf": SimTypeInt(signed=False, label="UInt32"), "pData": SimTypePointer(SimTypeChar(label="Byte"), offset=0)}, name="BINARY_CONTAINER", pack=False, align=None)}, name="<anon>", label="None")}, name="BIDI_DATA", pack=False, align=None)}, name="BIDI_RESPONSE_DATA", pack=False, align=None), offset=0)}, name="BIDI_RESPONSE_CONTAINER", pack=False, align=None), offset=0)], SimTypeInt(signed=False, label="UInt32"), arg_names=["pData"]),
#
'DeviceCapabilitiesA': SimTypeFunction([SimTypePointer(SimTypeChar(label="Byte"), offset=0), SimTypePointer(SimTypeChar(label="Byte"), offset=0), SimTypeInt(signed=False, label="DEVICE_CAPABILITIES"), SimTypePointer(SimTypeChar(label="Byte"), offset=0), SimTypePointer(SimStruct({"dmDeviceName": SimTypeFixedSizeArray(SimTypeChar(label="Byte"), 32), "dmSpecVersion": SimTypeShort(signed=False, label="UInt16"), "dmDriverVersion": SimTypeShort(signed=False, label="UInt16"), "dmSize": SimTypeShort(signed=False, label="UInt16"), "dmDriverExtra": SimTypeShort(signed=False, label="UInt16"), "dmFields": SimTypeInt(signed=False, label="UInt32"), "Anonymous1": SimUnion({"Anonymous1": SimStruct({"dmOrientation": SimTypeShort(signed=True, label="Int16"), "dmPaperSize": SimTypeShort(signed=True, label="Int16"), "dmPaperLength": SimTypeShort(signed=True, label="Int16"), "dmPaperWidth": SimTypeShort(signed=True, label="Int16"), "dmScale": SimTypeShort(signed=True, label="Int16"), "dmCopies": SimTypeShort(signed=True, label="Int16"), "dmDefaultSource": SimTypeShort(signed=True, label="Int16"), "dmPrintQuality": SimTypeShort(signed=True, label="Int16")}, name="_Anonymous1_e__Struct", pack=False, align=None), "Anonymous2": SimStruct({"dmPosition": SimStruct({"x": SimTypeInt(signed=True, label="Int32"), "y": SimTypeInt(signed=True, label="Int32")}, name="POINTL", pack=False, align=None), "dmDisplayOrientation": SimTypeInt(signed=False, label="UInt32"), "dmDisplayFixedOutput": SimTypeInt(signed=False, label="UInt32")}, name="_Anonymous2_e__Struct", pack=False, align=None)}, name="<anon>", label="None"), "dmColor": SimTypeShort(signed=True, label="Int16"), "dmDuplex": SimTypeShort(signed=True, label="Int16"), "dmYResolution": SimTypeShort(signed=True, label="Int16"), "dmTTOption": SimTypeShort(signed=True, label="Int16"), "dmCollate": SimTypeShort(signed=True, label="Int16"), "dmFormName": SimTypeFixedSizeArray(SimTypeChar(label="Byte"), 32), "dmLogPixels": SimTypeShort(signed=False, label="UInt16"), "dmBitsPerPel": SimTypeInt(signed=False, label="UInt32"), "dmPelsWidth": SimTypeInt(signed=False, label="UInt32"), "dmPelsHeight": SimTypeInt(signed=False, label="UInt32"), "Anonymous2": SimUnion({"dmDisplayFlags": SimTypeInt(signed=False, label="UInt32"), "dmNup": SimTypeInt(signed=False, label="UInt32")}, name="<anon>", label="None"), "dmDisplayFrequency": SimTypeInt(signed=False, label="UInt32"), "dmICMMethod": SimTypeInt(signed=False, label="UInt32"), "dmICMIntent": SimTypeInt(signed=False, label="UInt32"), "dmMediaType": SimTypeInt(signed=False, label="UInt32"), "dmDitherType": SimTypeInt(signed=False, label="UInt32"), "dmReserved1": SimTypeInt(signed=False, label="UInt32"), "dmReserved2": SimTypeInt(signed=False, label="UInt32"), "dmPanningWidth": SimTypeInt(signed=False, label="UInt32"), "dmPanningHeight": SimTypeInt(signed=False, label="UInt32")}, name="DEVMODEA", pack=False, align=None), offset=0)], SimTypeInt(signed=True, label="Int32"), arg_names=["pDevice", "pPort", "fwCapability", "pOutput", "pDevMode"]),
#
'DeviceCapabilitiesW': SimTypeFunction([SimTypePointer(SimTypeChar(label="Char"), offset=0), SimTypePointer(SimTypeChar(label="Char"), offset=0), SimTypeInt(signed=False, label="DEVICE_CAPABILITIES"), SimTypePointer(SimTypeChar(label="Char"), offset=0), SimTypePointer(SimStruct({"dmDeviceName": SimTypeFixedSizeArray(SimTypeChar(label="Char"), 32), "dmSpecVersion": SimTypeShort(signed=False, label="UInt16"), "dmDriverVersion": SimTypeShort(signed=False, label="UInt16"), "dmSize": SimTypeShort(signed=False, label="UInt16"), "dmDriverExtra": SimTypeShort(signed=False, label="UInt16"), "dmFields": SimTypeInt(signed=False, label="UInt32"), "Anonymous1": SimUnion({"Anonymous1": SimStruct({"dmOrientation": SimTypeShort(signed=True, label="Int16"), "dmPaperSize": SimTypeShort(signed=True, label="Int16"), "dmPaperLength": SimTypeShort(signed=True, label="Int16"), "dmPaperWidth": SimTypeShort(signed=True, label="Int16"), "dmScale": SimTypeShort(signed=True, label="Int16"), "dmCopies": SimTypeShort(signed=True, label="Int16"), "dmDefaultSource": SimTypeShort(signed=True, label="Int16"), "dmPrintQuality": SimTypeShort(signed=True, label="Int16")}, name="_Anonymous1_e__Struct", pack=False, align=None), "Anonymous2": SimStruct({"dmPosition": SimStruct({"x": SimTypeInt(signed=True, label="Int32"), "y": SimTypeInt(signed=True, label="Int32")}, name="POINTL", pack=False, align=None), "dmDisplayOrientation": SimTypeInt(signed=False, label="UInt32"), "dmDisplayFixedOutput": SimTypeInt(signed=False, label="UInt32")}, name="_Anonymous2_e__Struct", pack=False, align=None)}, name="<anon>", label="None"), "dmColor": SimTypeShort(signed=True, label="Int16"), "dmDuplex": SimTypeShort(signed=True, label="Int16"), "dmYResolution": SimTypeShort(signed=True, label="Int16"), "dmTTOption": SimTypeShort(signed=True, label="Int16"), "dmCollate": SimTypeShort(signed=True, label="Int16"), "dmFormName": SimTypeFixedSizeArray(SimTypeChar(label="Char"), 32), "dmLogPixels": SimTypeShort(signed=False, label="UInt16"), "dmBitsPerPel": SimTypeInt(signed=False, label="UInt32"), "dmPelsWidth": SimTypeInt(signed=False, label="UInt32"), "dmPelsHeight": SimTypeInt(signed=False, label="UInt32"), "Anonymous2": SimUnion({"dmDisplayFlags": SimTypeInt(signed=False, label="UInt32"), "dmNup": SimTypeInt(signed=False, label="UInt32")}, name="<anon>", label="None"), "dmDisplayFrequency": SimTypeInt(signed=False, label="UInt32"), "dmICMMethod": SimTypeInt(signed=False, label="UInt32"), "dmICMIntent": SimTypeInt(signed=False, label="UInt32"), "dmMediaType": SimTypeInt(signed=False, label="UInt32"), "dmDitherType": SimTypeInt(signed=False, label="UInt32"), "dmReserved1": SimTypeInt(signed=False, label="UInt32"), "dmReserved2": SimTypeInt(signed=False, label="UInt32"), "dmPanningWidth": SimTypeInt(signed=False, label="UInt32"), "dmPanningHeight": SimTypeInt(signed=False, label="UInt32")}, name="DEVMODEW", pack=False, align=None), offset=0)], SimTypeInt(signed=True, label="Int32"), arg_names=["pDevice", "pPort", "fwCapability", "pOutput", "pDevMode"]),
}
lib.set_prototypes(prototypes)
| 315.458791 | 5,795 | 0.733843 | 11,929 | 114,827 | 7.034035 | 0.042753 | 0.164369 | 0.123753 | 0.17693 | 0.944917 | 0.938815 | 0.933511 | 0.928804 | 0.927433 | 0.925956 | 0 | 0.026036 | 0.07412 | 114,827 | 363 | 5,796 | 316.327824 | 0.763206 | 0.000244 | 0 | 0 | 0 | 0 | 0.239806 | 0.019947 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | false | 0 | 0.027027 | 0 | 0.027027 | 0.005405 | 0 | 0 | 0 | null | 0 | 0 | 1 | 1 | 1 | 1 | 1 | 1 | 1 | 0 | 0 | 0 | 0 | 0 | 1 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 9 |
e91168289cb5740be40ff675ba4c7c06bfc96e80 | 71 | py | Python | models/__init__.py | laiguokun/fairseq | 6c01c91aac81eb2e3173add4463dfa45c404ffa5 | [
"MIT"
] | 1 | 2020-06-08T19:40:03.000Z | 2020-06-08T19:40:03.000Z | models/__init__.py | laiguokun/fairseq | 6c01c91aac81eb2e3173add4463dfa45c404ffa5 | [
"MIT"
] | null | null | null | models/__init__.py | laiguokun/fairseq | 6c01c91aac81eb2e3173add4463dfa45c404ffa5 | [
"MIT"
] | null | null | null | from . import joint
from . import my_joint
from . import my_transformer | 23.666667 | 28 | 0.802817 | 11 | 71 | 5 | 0.454545 | 0.545455 | 0.545455 | 0.618182 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0.15493 | 71 | 3 | 28 | 23.666667 | 0.916667 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | true | 0 | 1 | 0 | 1 | 0 | 1 | 0 | 0 | null | 1 | 1 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 1 | 0 | 1 | 0 | 0 | 8 |
e91b6aaa6e43fcb689c98e9471aecea41b3c8d7b | 224 | py | Python | spacy/training/converters/__init__.py | snosrap/spaCy | 3f68bbcfec44ef55d101e6db742d353b72652129 | [
"MIT"
] | 22,040 | 2016-10-03T11:58:15.000Z | 2022-03-31T21:08:19.000Z | spacy/training/converters/__init__.py | snosrap/spaCy | 3f68bbcfec44ef55d101e6db742d353b72652129 | [
"MIT"
] | 6,927 | 2016-10-03T13:11:11.000Z | 2022-03-31T17:01:25.000Z | spacy/training/converters/__init__.py | snosrap/spaCy | 3f68bbcfec44ef55d101e6db742d353b72652129 | [
"MIT"
] | 4,403 | 2016-10-04T03:36:33.000Z | 2022-03-31T14:12:34.000Z | from .iob_to_docs import iob_to_docs # noqa: F401
from .conll_ner_to_docs import conll_ner_to_docs # noqa: F401
from .json_to_docs import json_to_docs # noqa: F401
from .conllu_to_docs import conllu_to_docs # noqa: F401
| 44.8 | 62 | 0.803571 | 42 | 224 | 3.857143 | 0.261905 | 0.296296 | 0.296296 | 0.345679 | 0.333333 | 0 | 0 | 0 | 0 | 0 | 0 | 0.0625 | 0.142857 | 224 | 4 | 63 | 56 | 0.78125 | 0.191964 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | true | 0 | 1 | 0 | 1 | 0 | 0 | 0 | 0 | null | 1 | 1 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 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 | 7 |
3a64c3078fccd9b86d529f1cf57913f707c32b29 | 15,146 | py | Python | src/services/migrations/0001_initial.py | Nikhilgupta18/practice-react_django | 4226345a10c528308d13629907952e841621badc | [
"MIT"
] | null | null | null | src/services/migrations/0001_initial.py | Nikhilgupta18/practice-react_django | 4226345a10c528308d13629907952e841621badc | [
"MIT"
] | 11 | 2020-09-07T15:48:40.000Z | 2022-03-08T23:06:16.000Z | src/services/migrations/0001_initial.py | Nikhilgupta18/practice-react_django | 4226345a10c528308d13629907952e841621badc | [
"MIT"
] | null | null | null | # Generated by Django 2.1.5 on 2019-10-22 15:58
from django.conf import settings
from django.db import migrations, models
import django.db.models.deletion
import services.models
class Migration(migrations.Migration):
initial = True
dependencies = [
migrations.swappable_dependency(settings.AUTH_USER_MODEL),
]
operations = [
migrations.CreateModel(
name='CompleteApplication',
fields=[
('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
('service', models.TextField(blank=True, default=None, null=True)),
('price_inr', models.IntegerField(blank=True, default=None, null=True)),
('price_usd', models.IntegerField(blank=True, default=None, null=True)),
('link_inr', models.SlugField(blank=True, default=None, null=True)),
('link_usd', models.SlugField(blank=True, default=None, null=True)),
],
),
migrations.CreateModel(
name='CreateAdmissionPlan',
fields=[
('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
('service', models.TextField(blank=True, default=None, null=True)),
('price_inr', models.IntegerField(blank=True, default=None, null=True)),
('price_usd', models.IntegerField(blank=True, default=None, null=True)),
('link_inr', models.SlugField(blank=True, default=None, null=True)),
('link_usd', models.SlugField(blank=True, default=None, null=True)),
],
),
migrations.CreateModel(
name='FreeConsultation',
fields=[
('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
('number', models.BigIntegerField(blank=True, default=None, null=True)),
('service', models.TextField(blank=True, default=None, null=True)),
('date', models.DateField(blank=True, default=None, null=True)),
('user', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to=settings.AUTH_USER_MODEL)),
],
),
migrations.CreateModel(
name='GreConsultation',
fields=[
('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
('service', models.TextField(blank=True, default=None, null=True)),
('price_inr', models.IntegerField(blank=True, default=None, null=True)),
('price_usd', models.IntegerField(blank=True, default=None, null=True)),
('link_inr', models.SlugField(blank=True, default=None, null=True)),
('link_usd', models.SlugField(blank=True, default=None, null=True)),
],
),
migrations.CreateModel(
name='HistoryDraft',
fields=[
('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
('service', models.TextField(blank=True, default=None, null=True)),
('price_inr', models.IntegerField(blank=True, default=None, null=True)),
('price_usd', models.IntegerField(blank=True, default=None, null=True)),
('link_inr', models.SlugField(blank=True, default=None, null=True)),
('link_usd', models.SlugField(blank=True, default=None, null=True)),
],
),
migrations.CreateModel(
name='KaplanAccounts',
fields=[
('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
('email_id', models.TextField(blank=True, default=None, null=True)),
('password', models.TextField(blank=True, default=None, null=True)),
('sold', models.BooleanField(default=False)),
('timestamp', models.DateTimeField(auto_now_add=True, null=True)),
('sold_to', models.ForeignKey(blank=True, null=True, on_delete=django.db.models.deletion.CASCADE, to=settings.AUTH_USER_MODEL)),
],
),
migrations.CreateModel(
name='LORPrice',
fields=[
('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
('customizations', models.IntegerField(blank=True, default=None, null=True)),
('price_usd', models.IntegerField(blank=True, default=None, null=True)),
('price_inr', models.IntegerField(blank=True, default=None, null=True)),
('link_inr', models.SlugField(blank=True, default=None, null=True)),
('link_usd', models.SlugField(blank=True, default=None, null=True)),
],
),
migrations.CreateModel(
name='MaterialUser',
fields=[
('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
('material_name', models.TextField(blank=True, default=None, null=True)),
('timestamp', models.DateTimeField(auto_now_add=True, null=True)),
('pending', models.BooleanField(blank=True, default=False, null=True)),
],
),
migrations.CreateModel(
name='PaidMaterial',
fields=[
('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
('name', models.TextField(blank=True, default=None, null=True)),
('details', models.TextField(blank=True, default=None, null=True)),
('price_inr', models.IntegerField(blank=True, default=None, null=True)),
('price_usd', models.IntegerField(blank=True, default=None, null=True)),
('purchase_times', models.IntegerField(blank=True, default=None, null=True)),
('limited', models.BooleanField(default=False)),
('is_available', models.BooleanField(blank=True, default=True, null=True)),
('thumbnail', models.ImageField(blank=True, default=None, null=True, upload_to='paid_material/')),
('price_about_to_increase', models.BooleanField(default=False)),
('slug', models.SlugField(default=None, null=True)),
],
),
migrations.CreateModel(
name='Payment',
fields=[
('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
('payment_id', models.TextField(blank=True, default=None, null=True)),
('service_name', models.TextField(blank=True, null=True, verbose_name=services.models.Service)),
('status', models.TextField(blank=True, default=None, null=True)),
('currency', models.TextField(default='INR')),
('amount', models.FloatField(default=0.0)),
('timestamp', models.DateTimeField(auto_now_add=True)),
('user', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to=settings.AUTH_USER_MODEL)),
],
),
migrations.CreateModel(
name='PrincetonAccounts',
fields=[
('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
('email_id', models.TextField(blank=True, default=None, null=True)),
('password', models.TextField(blank=True, default=None, null=True)),
('sold', models.BooleanField(default=False)),
('timestamp', models.DateTimeField(auto_now_add=True, null=True)),
('sold_to', models.TextField(blank=True, default=None, null=True)),
],
),
migrations.CreateModel(
name='PrincetonGMATAccounts',
fields=[
('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
('email_id', models.TextField(blank=True, default=None, null=True)),
('password', models.TextField(blank=True, default=None, null=True)),
('sold', models.BooleanField(default=False)),
('timestamp', models.DateTimeField(auto_now_add=True, null=True)),
('sold_to', models.ForeignKey(blank=True, null=True, on_delete=django.db.models.deletion.CASCADE, to=settings.AUTH_USER_MODEL)),
],
),
migrations.CreateModel(
name='Resume',
fields=[
('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
('service', models.TextField(blank=True, default=None, null=True)),
('price_inr', models.IntegerField(blank=True, default=None, null=True)),
('price_usd', models.IntegerField(blank=True, default=None, null=True)),
('link_inr', models.SlugField(blank=True, default=None, null=True)),
('link_usd', models.SlugField(blank=True, default=None, null=True)),
],
),
migrations.CreateModel(
name='Service',
fields=[
('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
('heading', models.TextField(blank=True, default=None, null=True)),
('intro', models.TextField(blank=True, default=None, null=True)),
('details', models.TextField(blank=True, default=None, null=True)),
('spl_details', models.TextField(blank=True, default=None, null=True)),
('link', models.SlugField(blank=True, default=None, null=True)),
('faicon', models.TextField(blank=True, default=None, null=True)),
('yt_link', models.TextField(blank=True, default=None, null=True)),
('is_available', models.BooleanField(blank=True, default=True, null=True)),
],
),
migrations.CreateModel(
name='ServiceUser',
fields=[
('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
('service_name', models.TextField(blank=True, default=None, null=True)),
('customizations', models.TextField(blank=True, default=None, null=True)),
('timestamp', models.DateTimeField(auto_now_add=True, null=True)),
('pending', models.BooleanField(blank=True, default=True, null=True)),
('payment_pending', models.TextField(blank=True, default=None, null=True)),
('total_amount', models.TextField(blank=True, default=None, null=True)),
('payment', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to='services.Payment')),
('user', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to=settings.AUTH_USER_MODEL)),
],
),
migrations.CreateModel(
name='SopPrice',
fields=[
('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
('customizations', models.IntegerField(blank=True, default=None, null=True)),
('price_usd', models.IntegerField(blank=True, default=None, null=True)),
('price_inr', models.IntegerField(blank=True, default=None, null=True)),
('link_inr', models.SlugField(blank=True, default=None, null=True)),
('link_usd', models.SlugField(blank=True, default=None, null=True)),
],
),
migrations.CreateModel(
name='Statement',
fields=[
('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
('type', models.TextField(choices=[('Credit', 'Credit'), ('Debit', 'Debit')], default=1)),
('detail', models.TextField()),
('amount', models.FloatField()),
('timestamp', models.DateTimeField(auto_now_add=True, null=True)),
],
),
migrations.CreateModel(
name='Testimonial',
fields=[
('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
('path', models.ImageField(blank=True, default=None, null=True, upload_to='testimonials/')),
('rating', models.IntegerField(blank=True, default=None, null=True)),
('headline', models.CharField(blank=True, default=None, max_length=100, null=True)),
('details', models.TextField(blank=True, default=None, null=True)),
('timestamp', models.DateTimeField(auto_now_add=True)),
('anonymous', models.BooleanField(default=False)),
('service', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to='services.Service')),
('user', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to=settings.AUTH_USER_MODEL)),
],
),
migrations.CreateModel(
name='ToeflConsultation',
fields=[
('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
('service', models.TextField(blank=True, default=None, null=True)),
('price_inr', models.IntegerField(blank=True, default=None, null=True)),
('price_usd', models.IntegerField(blank=True, default=None, null=True)),
('link_inr', models.SlugField(blank=True, default=None, null=True)),
('link_usd', models.SlugField(blank=True, default=None, null=True)),
],
),
migrations.CreateModel(
name='UnivShortlising',
fields=[
('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
('service', models.TextField(blank=True, default=None, null=True)),
('price_inr', models.IntegerField(blank=True, default=None, null=True)),
('price_usd', models.IntegerField(blank=True, default=None, null=True)),
('link_inr', models.SlugField(blank=True, default=None, null=True)),
('link_usd', models.SlugField(blank=True, default=None, null=True)),
],
),
migrations.AddField(
model_name='materialuser',
name='payment',
field=models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to='services.Payment'),
),
migrations.AddField(
model_name='materialuser',
name='user',
field=models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to=settings.AUTH_USER_MODEL),
),
]
| 58.030651 | 144 | 0.590123 | 1,551 | 15,146 | 5.654417 | 0.086396 | 0.084835 | 0.151425 | 0.18016 | 0.866591 | 0.862828 | 0.842531 | 0.828734 | 0.781528 | 0.746978 | 0 | 0.001877 | 0.261125 | 15,146 | 260 | 145 | 58.253846 | 0.781789 | 0.002971 | 0 | 0.719368 | 1 | 0 | 0.091595 | 0.002914 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | false | 0.011858 | 0.01581 | 0 | 0.031621 | 0 | 0 | 0 | 0 | null | 0 | 0 | 1 | 1 | 1 | 1 | 1 | 1 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 1 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 9 |
3a758cfd8522043cf8c508bb66d867fa5b6e411c | 4,971 | py | Python | ic3_labels/labels/utils/detector.py | IceCubeOpenSource/ic3-labels | 049565e1dd423115020484fca5b891afdd1f97bc | [
"MIT"
] | 1 | 2021-04-21T09:06:12.000Z | 2021-04-21T09:06:12.000Z | ic3_labels/labels/utils/detector.py | icecube/ic3-labels | 049565e1dd423115020484fca5b891afdd1f97bc | [
"MIT"
] | null | null | null | ic3_labels/labels/utils/detector.py | icecube/ic3-labels | 049565e1dd423115020484fca5b891afdd1f97bc | [
"MIT"
] | 2 | 2019-06-10T13:37:17.000Z | 2019-10-21T06:16:35.000Z | """ Convex Hulls for IceCube Detector
"""
from scipy.spatial import ConvexHull
icecube_hull = ConvexHull([
[-570.90002441, -125.13999939, -500], # string 31
[-256.14001465, -521.08001709, -500], # string 1
[ 361. , -422.82998657, -500], # string 6
[ 576.36999512, 170.91999817, -500], # string 50
[ 338.44000244, 463.72000122, -500], # string 74
[ 101.04000092, 412.79000854, -500], # string 72
[ 22.11000061, 509.5 , -500], # string 78
[-347.88000488, 451.51998901, -500], # string 75
[-570.90002441, -125.13999939, -500], # string 31
[-256.14001465, -521.08001709, 500], # string 1
[ 361. , -422.82998657, 500], # string 6
[ 576.36999512, 170.91999817, 500], # string 50
[ 338.44000244, 463.72000122, 500], # string 74
[ 101.04000092, 412.79000854, 500], # string 72
[ 22.11000061, 509.5 , 500], # string 78
[-347.88000488, 451.51998901, 500], # string 75
[-570.90002441, -125.13999939, 500], # string 31
])
# Assuming dust layer to be at -150m to -50m
icecube_hull_upper = ConvexHull([
[-570.90002441, -125.13999939, -50], # string 31
[-256.14001465, -521.08001709, -50], # string 1
[ 361. , -422.82998657, -50], # string 6
[ 576.36999512, 170.91999817, -50], # string 50
[ 338.44000244, 463.72000122, -50], # string 74
[ 101.04000092, 412.79000854, -50], # string 72
[ 22.11000061, 509.5 , -50], # string 78
[-347.88000488, 451.51998901, -50], # string 75
[-570.90002441, -125.13999939, -50], # string 31
[-256.14001465, -521.08001709, 500], # string 1
[ 361. , -422.82998657, 500], # string 6
[ 576.36999512, 170.91999817, 500], # string 50
[ 338.44000244, 463.72000122, 500], # string 74
[ 101.04000092, 412.79000854, 500], # string 72
[ 22.11000061, 509.5 , 500], # string 78
[-347.88000488, 451.51998901, 500], # string 75
[-570.90002441, -125.13999939, 500], # string 31
])
icecube_hull_lower = ConvexHull([
[-570.90002441, -125.13999939, -500], # string 31
[-256.14001465, -521.08001709, -500], # string 1
[ 361. , -422.82998657, -500], # string 6
[ 576.36999512, 170.91999817, -500], # string 50
[ 338.44000244, 463.72000122, -500], # string 74
[ 101.04000092, 412.79000854, -500], # string 72
[ 22.11000061, 509.5 , -500], # string 78
[-347.88000488, 451.51998901, -500], # string 75
[-570.90002441, -125.13999939, -500], # string 31
[-256.14001465, -521.08001709, -150], # string 1
[ 361. , -422.82998657, -150], # string 6
[ 576.36999512, 170.91999817, -150], # string 50
[ 338.44000244, 463.72000122, -150], # string 74
[ 101.04000092, 412.79000854, -150], # string 72
[ 22.11000061, 509.5 , -150], # string 78
[-347.88000488, 451.51998901, -150], # string 75
[-570.90002441, -125.13999939, -150], # string 31
])
# This is is convex hull around IceCube minus 1 outer layer and 3 in z
icecube_veto_hull_m1 = ConvexHull([
[-447.74, -113.13, -450], # string 32, DOM 57 (approx z)
[-211.35, -404.48, -450], # string 8, DOM 57 (approx z)
[ 282.18, -325.74, -450], # string 12, DOM 57 (approx z)
[ 472.05, 127.9 , -450], # string 49, DOM 57 (approx z)
[ 303.41, 335.64, -450], # string 66, DOM 57 (approx z)
[ -21.97, 393.24, -450], # string 71, DOM 57 (approx z)
[-268.9 , 354.24, -450], # string 69, DOM 57 (approx z)
[-447.74, -113.13, -450], # string 32, DOM 57 (approx z)
[-447.74, -113.13, 450], # string 32, DOM 4 (approx z)
[-211.35, -404.48, 450], # string 8, DOM 4 (approx z)
[ 282.18, -325.74, 450], # string 12, DOM 4 (approx z)
[ 472.05, 127.9 , 450], # string 49, DOM 4 (approx z)
[ 303.41, 335.64, 450], # string 66, DOM 4 (approx z)
[ -21.97, 393.24, 450], # string 71, DOM 4 (approx z)
[-268.9 , 354.24, 450], # string 69, DOM 4 (approx z)
[-447.74, -113.13, 450], # string 32, DOM 4 (approx z)
])
# This is is convex hull around IceCube minus 2 outer layers and 6 in z
icecube_veto_hull_m2 = ConvexHull([
[-324.39, -93.43, -400], # string 33, DOM 54 (approx z)
[-166.4 , -287.79, -400], # string 16, DOM 54 (approx z)
[ 210.47, -209.77, -400], # string 19, DOM 54 (approx z)
[ 330.03, 127.2 , -400], # string 48, DOM 54 (approx z)
[ 174.47, 315.54, -400], # string 65, DOM 54 (approx z)
[-189.98, 257.42, -400], # string 62, DOM 54 (approx z)
[-324.39, -93.43, -400], # string 33, DOM 54 (approx z)
[-324.39, -93.43, 400], # string 33, DOM 7 (approx z)
[-166.4 , -287.79, 400], # string 16, DOM 7 (approx z)
[ 210.47, -209.77, 400], # string 19, DOM 7 (approx z)
[ 330.03, 127.2 , 400], # string 48, DOM 7 (approx z)
[ 174.47, 315.54, 400], # string 65, DOM 7 (approx z)
[-189.98, 257.42, 400], # string 62, DOM 7 (approx z)
[-324.39, -93.43, 400], # string 33, DOM 7 (approx z)
])
| 47.798077 | 71 | 0.576343 | 751 | 4,971 | 3.800266 | 0.186418 | 0.107218 | 0.044149 | 0.069376 | 0.906797 | 0.875964 | 0.76384 | 0.76384 | 0.738612 | 0.738612 | 0 | 0.464684 | 0.242406 | 4,971 | 103 | 72 | 48.262136 | 0.293149 | 0.315228 | 0 | 0.532609 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | false | 0 | 0.01087 | 0 | 0.01087 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 1 | 1 | 1 | 1 | 1 | 1 | 0 | 1 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 8 |
3adb07d8890b6787b890d41ab43d33438d53dac1 | 44 | py | Python | tests/expectations/python-expr/np-to-pil-la.py | nipeone/histolab | 78854423df04c95c7168d03a95ae8665e3e957d8 | [
"Apache-2.0"
] | 149 | 2020-06-23T17:56:04.000Z | 2022-03-26T05:51:08.000Z | tests/expectations/python-expr/np-to-pil-la.py | nipeone/histolab | 78854423df04c95c7168d03a95ae8665e3e957d8 | [
"Apache-2.0"
] | 245 | 2020-06-22T22:56:06.000Z | 2022-03-28T03:18:11.000Z | tests/expectations/python-expr/np-to-pil-la.py | MPBA/histolab | 1dffe88aa04022567c70bbb78f96a860d73a599b | [
"Apache-2.0"
] | 31 | 2020-06-23T17:56:36.000Z | 2022-02-07T07:41:26.000Z | [[[27, 7], [66, 84]], [[77, 63], [98, 77]]]
| 22 | 43 | 0.340909 | 8 | 44 | 1.875 | 0.875 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0.416667 | 0.181818 | 44 | 1 | 44 | 44 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | true | 0 | 0 | 0 | 0 | 0 | 1 | 1 | 1 | 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 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 7 |
3ade06fe05db61fa1cf93cbcbd3c6388dea92c88 | 42 | py | Python | hello-fortran-dependency/tests/test.py | Nicholaswogan/skbuild-f2py-examples | e47d0a9ce483e54b678e31789dbfcc90ff4a8e74 | [
"MIT"
] | 4 | 2021-07-28T02:16:52.000Z | 2021-12-23T00:20:21.000Z | hello-fortran-dependency/tests/test.py | Nicholaswogan/skbuild-f2py-examples | e47d0a9ce483e54b678e31789dbfcc90ff4a8e74 | [
"MIT"
] | 1 | 2021-09-14T21:17:49.000Z | 2021-09-14T23:17:47.000Z | hello-fortran-dependency/tests/test.py | Nicholaswogan/skbuild-f2py-examples | e47d0a9ce483e54b678e31789dbfcc90ff4a8e74 | [
"MIT"
] | null | null | null | from hello import hola_mod
hola_mod.hola() | 21 | 26 | 0.833333 | 8 | 42 | 4.125 | 0.625 | 0.424242 | 0.666667 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0.095238 | 42 | 2 | 27 | 21 | 0.868421 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | true | 0 | 0.5 | 0 | 0.5 | 0 | 1 | 1 | 0 | null | 1 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 1 | 0 | 0 | 0 | 0 | 7 |
3aea0f6f72fc42fa17033c668a18b45616f318ab | 4,076 | py | Python | tests/parsing/test_expression.py | mvdnes/destructify | eb37ee3465da429685a8301ec00b4a63cd375561 | [
"MIT"
] | 7 | 2018-06-04T13:47:59.000Z | 2021-01-13T19:40:32.000Z | tests/parsing/test_expression.py | mvdnes/destructify | eb37ee3465da429685a8301ec00b4a63cd375561 | [
"MIT"
] | 1 | 2021-02-08T10:35:14.000Z | 2021-02-08T10:35:14.000Z | tests/parsing/test_expression.py | mvdnes/destructify | eb37ee3465da429685a8301ec00b4a63cd375561 | [
"MIT"
] | 2 | 2020-11-30T22:00:16.000Z | 2021-07-10T09:45:49.000Z | import unittest
from destructify import this, Structure, IntegerField, FixedLengthField
from tests import DestructifyTestCase
class AttributeAccess:
one = 1
two = 2
three = 3
list = [1, 2]
class ThisTest(unittest.TestCase):
obj = AttributeAccess()
def test_simple_access(self):
self.assertEqual(1, this.one(self.obj))
self.assertEqual(2, this.two(self.obj))
def test_comparison_both(self):
self.assertTrue((this.one < this.two)(self.obj))
self.assertTrue((this.one <= this.two)(self.obj))
self.assertTrue((this.one == this.one)(self.obj))
self.assertTrue((this.one != this.two)(self.obj))
self.assertTrue((this.two > this.one)(self.obj))
self.assertTrue((this.two >= this.one)(self.obj))
self.assertFalse((this.one > this.two)(self.obj))
self.assertFalse((this.one >= this.two)(self.obj))
self.assertFalse((this.one == this.two)(self.obj))
self.assertFalse((this.one != this.one)(self.obj))
self.assertFalse((this.two < this.one)(self.obj))
self.assertFalse((this.two <= this.one)(self.obj))
def test_comparison_one(self):
self.assertTrue((this.one < 2)(self.obj))
self.assertTrue((this.one <= 2)(self.obj))
self.assertTrue((this.one == 1)(self.obj))
self.assertTrue((this.one != 2)(self.obj))
self.assertTrue((this.two > 1)(self.obj))
self.assertTrue((this.two >= 1)(self.obj))
self.assertTrue((1 < this.two)(self.obj))
self.assertTrue((1 <= this.two)(self.obj))
self.assertTrue((1 == this.one)(self.obj))
self.assertTrue((1 != this.two)(self.obj))
self.assertTrue((2 > this.one)(self.obj))
self.assertTrue((1 >= this.one)(self.obj))
def test_math_both(self):
self.assertEqual(3, (this.one + this.two)(self.obj))
self.assertEqual(-1, (this.one - this.two)(self.obj))
self.assertEqual(2, (this.one * this.two)(self.obj))
self.assertEqual(1 / 2, (this.one / this.two)(self.obj))
# TODO: matmul
self.assertEqual(0, (this.one // this.two)(self.obj))
self.assertEqual(1, (this.three % this.two)(self.obj))
self.assertEqual((1, 1), divmod(this.three, this.two)(self.obj))
self.assertEqual(9, (this.three ** this.two)(self.obj))
self.assertEqual(9, (this.three ** this.two)(self.obj))
self.assertEqual(4, (this.two << this.one)(self.obj))
self.assertEqual(1, (this.two >> this.one)(self.obj))
self.assertEqual(1, (this.three & this.one)(self.obj))
self.assertEqual(2, (this.three ^ this.one)(self.obj))
self.assertEqual(3, (this.two | this.one)(self.obj))
def test_math_one(self):
self.assertEqual(3, (1 + this.two)(self.obj))
self.assertEqual(-1, (1 - this.two)(self.obj))
self.assertEqual(2, (1 * this.two)(self.obj))
self.assertEqual(1 / 2, (1 / this.two)(self.obj))
# TODO: matmul
self.assertEqual(0, (1 // this.two)(self.obj))
self.assertEqual(1, (3 % this.two)(self.obj))
self.assertEqual((1, 1), divmod(3, this.two)(self.obj))
self.assertEqual(9, (3 ** this.two)(self.obj))
self.assertEqual(9, (3 ** this.two)(self.obj))
self.assertEqual(4, (2 << this.one)(self.obj))
self.assertEqual(1, (2 >> this.one)(self.obj))
self.assertEqual(1, (3 & this.one)(self.obj))
self.assertEqual(2, (3 ^ this.one)(self.obj))
self.assertEqual(3, (2 | this.one)(self.obj))
def test_unary(self):
self.assertEqual(-1, (-this.one)(self.obj))
self.assertEqual(2, (+this.two)(self.obj))
self.assertEqual(1, (abs(this.one))(self.obj))
self.assertEqual(-2, (~this.one)(self.obj))
class ThisStructureTest(DestructifyTestCase):
def test(self):
class TestStruct(Structure):
length = IntegerField(1)
content = FixedLengthField(this.length)
self.assertStructureStreamEqual(b"\x03ASD", TestStruct(length=3, content=b"ASD"))
| 41.171717 | 89 | 0.609176 | 556 | 4,076 | 4.446043 | 0.08813 | 0.164239 | 0.222492 | 0.164239 | 0.809466 | 0.792071 | 0.782362 | 0.728155 | 0.586165 | 0.493123 | 0 | 0.022629 | 0.208538 | 4,076 | 98 | 90 | 41.591837 | 0.743645 | 0.006133 | 0 | 0.05 | 0 | 0 | 0.00247 | 0 | 0 | 0 | 0 | 0.010204 | 0.7375 | 1 | 0.0875 | false | 0 | 0.0375 | 0 | 0.2375 | 0 | 0 | 0 | 0 | null | 0 | 1 | 1 | 1 | 1 | 1 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | 0 | 0 | 1 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 8 |
c91acc928071f532bd0231d8df4f89b56c597bd9 | 3,253 | py | Python | hall-of-fame/round-01/04_StackOut-K1m/unitz.py | hansol000808/cau-osp2020-game | 6912d3e96e5d2625a98e8d5e95ee8b2fe1178584 | [
"Apache-2.0"
] | 17 | 2020-12-08T14:33:01.000Z | 2020-12-17T15:50:59.000Z | hall-of-fame/round-01/04_StackOut-K1m/unitz.py | linad27/cau-osp2020-game | a0ff61dfaafff41efe44c1f2f79968a4632eca32 | [
"Apache-2.0"
] | 2 | 2020-11-26T12:21:53.000Z | 2020-12-02T07:07:24.000Z | hall-of-fame/round-01/04_StackOut-K1m/unitz.py | linad27/cau-osp2020-game | a0ff61dfaafff41efe44c1f2f79968a4632eca32 | [
"Apache-2.0"
] | 79 | 2020-11-26T00:43:18.000Z | 2020-12-18T14:18:37.000Z | from loa.unit import Unit
class Soldier(Unit):
HP = 21 # Hit Points (health points)
ATT = 0 # Attack
ARM = 6 # Armor
EVS = 10 # Evasion
def __init__(self, team, name, pos):
cls = __class__
super().__init__(team,
name,
pos,
hp=cls.HP,
att=cls.ATT,
arm=cls.ARM,
evs=cls.EVS)
class Elite(Unit):
HP = 21 # Hit Points (health points)
ATT = 0 # Attack
ARM = 7 # Armor
EVS = 10 # Evasion
def __init__(self, team, name, pos):
cls = __class__
super().__init__(team,
name,
pos,
hp=cls.HP,
att=cls.ATT,
arm=cls.ARM,
evs=cls.EVS)
class Giant(Unit):
HP = 21 # Hit Points (health points)
ATT = 90 # Attack
ARM = 80 # Armor
EVS = 10 # Evasion
def __init__(self, team, name, pos):
cls = __class__
super().__init__(team,
name,
pos,
hp=cls.HP,
att=cls.ATT,
arm=cls.ARM,
evs=cls.EVS)
class Sacrifice(Unit):
HP = 0 # Hit Points (health points)
ATT = 0 # Attack
ARM = 1 # Armor
EVS = 1 # Evasion
def __init__(self, team, name, pos):
cls = __class__
super().__init__(team,
name,
pos,
hp=cls.HP,
att=cls.ATT,
arm=cls.ARM,
evs=cls.EVS)
class T_Soldier(Unit):
HP = 18 # Hit Points (health points)
ATT = 0 # Attack
ARM = 6 # Armor
EVS = 10 # Evasion
def __init__(self, team, name, pos):
cls = __class__
super().__init__(team,
name,
pos,
hp=cls.HP,
att=cls.ATT,
arm=cls.ARM,
evs=cls.EVS)
class T_Elite(Unit):
HP = 19 # Hit Points (health points)
ATT = 0 # Attack
ARM = 6 # Armor
EVS = 10 # Evasion
def __init__(self, team, name, pos):
cls = __class__
super().__init__(team,
name,
pos,
hp=cls.HP,
att=cls.ATT,
arm=cls.ARM,
evs=cls.EVS)
class T_Sacrifice(Unit):
HP = 0 # Hit Points (health points)
ATT = 0 # Attack
ARM = 1 # Armor
EVS = 2 # Evasion
def __init__(self, team, name, pos):
cls = __class__
super().__init__(team,
name,
pos,
hp=cls.HP,
att=cls.ATT,
arm=cls.ARM,
evs=cls.EVS) | 26.884298 | 45 | 0.368583 | 309 | 3,253 | 3.598706 | 0.126214 | 0.100719 | 0.138489 | 0.132194 | 0.921763 | 0.921763 | 0.921763 | 0.921763 | 0.892986 | 0.892986 | 0 | 0.027155 | 0.547187 | 3,253 | 121 | 46 | 26.884298 | 0.727766 | 0.111589 | 0 | 0.848485 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0.070707 | false | 0 | 0.010101 | 0 | 0.434343 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 1 | 1 | 1 | 1 | 1 | 1 | 0 | 0 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 8 |
c9641350c5ddaad39fb02d73a5b2d5ac58a293a0 | 23,543 | py | Python | tests/test_request_bodies/test_multipart.py | adriangb/xpresso | 43fcc360f7b19c00e0b78480f96390bcb4d28053 | [
"MIT"
] | 75 | 2022-01-18T02:17:57.000Z | 2022-03-24T02:30:04.000Z | tests/test_request_bodies/test_multipart.py | adriangb/xpresso | 43fcc360f7b19c00e0b78480f96390bcb4d28053 | [
"MIT"
] | 73 | 2022-01-18T03:01:27.000Z | 2022-03-27T16:41:38.000Z | tests/test_request_bodies/test_multipart.py | adriangb/xpresso | 43fcc360f7b19c00e0b78480f96390bcb4d28053 | [
"MIT"
] | 3 | 2022-01-18T22:47:06.000Z | 2022-01-25T02:03:53.000Z | import typing
from io import BytesIO
import pytest
from pydantic import BaseModel
from starlette.responses import Response
from starlette.testclient import TestClient
from xpresso import App, Form, FormFile, FromFormFile, FromMultipart, Path, UploadFile
from xpresso.typing import Annotated
Files = typing.List[
typing.Tuple[
str,
typing.Union[
typing.Tuple[
typing.Optional[str], typing.Union[bytes, typing.BinaryIO], str
],
typing.Tuple[typing.Optional[str], typing.Union[bytes, typing.BinaryIO]],
],
]
]
Data = typing.List[typing.Tuple[str, str]]
class TruthyEmptyList(typing.List[typing.Any]):
"""Used to force multipart requests"""
def __bool__(self) -> bool:
return True
def test_uploadfile_field() -> None:
file_payload = b"abc"
class FormDataModel(BaseModel):
file: FromFormFile[UploadFile]
async def test(body: FromMultipart[FormDataModel]) -> Response:
assert (await body.file.read()) == file_payload
return Response()
app = App([Path("/", post=test)])
client = TestClient(app)
files: Files = [
(
"file",
(
"file.txt",
BytesIO(file_payload),
),
),
]
data: Data = []
resp = client.post("/", files=files, data=data)
assert resp.status_code == 200, resp.text
expected_openapi: typing.Dict[str, typing.Any] = {
"openapi": "3.0.3",
"info": {"title": "API", "version": "0.1.0"},
"paths": {
"/": {
"post": {
"responses": {
"200": {
"description": "OK",
"content": {"application/json": {}},
},
"422": {
"description": "Validation Error",
"content": {
"application/json": {
"schema": {
"$ref": "#/components/schemas/HTTPValidationError"
}
}
},
},
},
"requestBody": {
"content": {
"multipart/form-data": {
"schema": {
"required": ["file"],
"type": "object",
"properties": {
"file": {"type": "string", "format": "binary"}
},
},
"encoding": {"file": {}},
}
},
"required": True,
},
}
}
},
"components": {
"schemas": {
"ValidationError": {
"title": "ValidationError",
"required": ["loc", "msg", "type"],
"type": "object",
"properties": {
"loc": {
"title": "Location",
"type": "array",
"items": {
"oneOf": [{"type": "string"}, {"type": "integer"}]
},
},
"msg": {"title": "Message", "type": "string"},
"type": {"title": "Error Type", "type": "string"},
},
},
"HTTPValidationError": {
"title": "HTTPValidationError",
"type": "object",
"properties": {
"detail": {
"title": "Detail",
"type": "array",
"items": {"$ref": "#/components/schemas/ValidationError"},
}
},
},
}
},
}
resp = client.get("/openapi.json")
assert resp.status_code == 200, resp.text
assert resp.json() == expected_openapi
def test_bytes_field() -> None:
file_payload = b"abc"
class FormDataModel(BaseModel):
file: FromFormFile[bytes]
async def test(body: FromMultipart[FormDataModel]) -> Response:
assert body.file == file_payload
return Response()
app = App([Path("/", post=test)])
client = TestClient(app)
files: Files = [
(
"file",
(
"file.txt",
BytesIO(file_payload),
),
),
]
data: Data = []
resp = client.post("/", files=files, data=data)
assert resp.status_code == 200, resp.text
expected_openapi: typing.Dict[str, typing.Any] = {
"openapi": "3.0.3",
"info": {"title": "API", "version": "0.1.0"},
"paths": {
"/": {
"post": {
"responses": {
"200": {
"description": "OK",
"content": {"application/json": {}},
},
"422": {
"description": "Validation Error",
"content": {
"application/json": {
"schema": {
"$ref": "#/components/schemas/HTTPValidationError"
}
}
},
},
},
"requestBody": {
"content": {
"multipart/form-data": {
"schema": {
"required": ["file"],
"type": "object",
"properties": {
"file": {"type": "string", "format": "binary"}
},
},
"encoding": {"file": {}},
}
},
"required": True,
},
}
}
},
"components": {
"schemas": {
"ValidationError": {
"title": "ValidationError",
"required": ["loc", "msg", "type"],
"type": "object",
"properties": {
"loc": {
"title": "Location",
"type": "array",
"items": {
"oneOf": [{"type": "string"}, {"type": "integer"}]
},
},
"msg": {"title": "Message", "type": "string"},
"type": {"title": "Error Type", "type": "string"},
},
},
"HTTPValidationError": {
"title": "HTTPValidationError",
"type": "object",
"properties": {
"detail": {
"title": "Detail",
"type": "array",
"items": {"$ref": "#/components/schemas/ValidationError"},
}
},
},
}
},
}
resp = client.get("/openapi.json")
assert resp.status_code == 200, resp.text
assert resp.json() == expected_openapi
def test_scalar_alias() -> None:
file_payload = b"abc"
class FormDataModel(BaseModel):
file: Annotated[bytes, FormFile(alias="realFieldName")]
async def test(body: FromMultipart[FormDataModel]) -> Response:
assert body.file == file_payload
return Response()
app = App([Path("/", post=test)])
client = TestClient(app)
files: Files = [
(
"realFieldName",
(
"file.txt",
BytesIO(file_payload),
),
),
]
data: Data = []
resp = client.post("/", files=files, data=data)
assert resp.status_code == 200, resp.text
expected_openapi: typing.Dict[str, typing.Any] = {
"openapi": "3.0.3",
"info": {"title": "API", "version": "0.1.0"},
"paths": {
"/": {
"post": {
"responses": {
"200": {
"description": "OK",
"content": {"application/json": {}},
},
"422": {
"description": "Validation Error",
"content": {
"application/json": {
"schema": {
"$ref": "#/components/schemas/HTTPValidationError"
}
}
},
},
},
"requestBody": {
"content": {
"multipart/form-data": {
"schema": {
"required": ["realFieldName"],
"type": "object",
"properties": {
"realFieldName": {
"type": "string",
"format": "binary",
}
},
},
"encoding": {"realFieldName": {}},
}
},
"required": True,
},
}
}
},
"components": {
"schemas": {
"ValidationError": {
"title": "ValidationError",
"required": ["loc", "msg", "type"],
"type": "object",
"properties": {
"loc": {
"title": "Location",
"type": "array",
"items": {
"oneOf": [{"type": "string"}, {"type": "integer"}]
},
},
"msg": {"title": "Message", "type": "string"},
"type": {"title": "Error Type", "type": "string"},
},
},
"HTTPValidationError": {
"title": "HTTPValidationError",
"type": "object",
"properties": {
"detail": {
"title": "Detail",
"type": "array",
"items": {"$ref": "#/components/schemas/ValidationError"},
}
},
},
}
},
}
resp = client.get("/openapi.json")
assert resp.status_code == 200, resp.text
assert resp.json() == expected_openapi
def test_array() -> None:
file_payload = b"abc"
class FormDataModel(BaseModel):
file: FromFormFile[typing.List[bytes]]
async def test(body: FromMultipart[FormDataModel]) -> Response:
assert body.file == [file_payload, file_payload]
return Response()
app = App([Path("/", post=test)])
client = TestClient(app)
files: Files = [
(
"file",
(
"file1.txt",
file_payload,
),
),
(
"file",
(
"file2.txt",
file_payload,
),
),
]
data: Data = []
resp = client.post("/", files=files, data=data)
assert resp.status_code == 200, resp.text
expected_openapi: typing.Dict[str, typing.Any] = {
"openapi": "3.0.3",
"info": {"title": "API", "version": "0.1.0"},
"paths": {
"/": {
"post": {
"responses": {
"200": {
"description": "OK",
"content": {"application/json": {}},
},
"422": {
"description": "Validation Error",
"content": {
"application/json": {
"schema": {
"$ref": "#/components/schemas/HTTPValidationError"
}
}
},
},
},
"requestBody": {
"content": {
"multipart/form-data": {
"schema": {
"required": ["file"],
"type": "object",
"properties": {
"file": {
"type": "array",
"items": {
"type": "string",
"format": "binary",
},
}
},
},
"encoding": {"file": {}},
}
},
"required": True,
},
}
}
},
"components": {
"schemas": {
"ValidationError": {
"title": "ValidationError",
"required": ["loc", "msg", "type"],
"type": "object",
"properties": {
"loc": {
"title": "Location",
"type": "array",
"items": {
"oneOf": [{"type": "string"}, {"type": "integer"}]
},
},
"msg": {"title": "Message", "type": "string"},
"type": {"title": "Error Type", "type": "string"},
},
},
"HTTPValidationError": {
"title": "HTTPValidationError",
"type": "object",
"properties": {
"detail": {
"title": "Detail",
"type": "array",
"items": {"$ref": "#/components/schemas/ValidationError"},
}
},
},
}
},
}
resp = client.get("/openapi.json")
assert resp.status_code == 200, resp.text
assert resp.json() == expected_openapi
def test_array_alias() -> None:
file_payload = b"abc"
class FormDataModel(BaseModel):
file: Annotated[typing.List[bytes], FormFile(alias="realFieldName")]
async def test(body: FromMultipart[FormDataModel]) -> Response:
assert body.file == [file_payload, file_payload]
return Response()
app = App([Path("/", post=test)])
client = TestClient(app)
files: Files = [
(
"realFieldName",
(
"file1.txt",
file_payload,
),
),
(
"realFieldName",
(
"file2.txt",
file_payload,
),
),
]
data: Data = []
resp = client.post("/", files=files, data=data)
assert resp.status_code == 200, resp.text
expected_openapi: typing.Dict[str, typing.Any] = {
"openapi": "3.0.3",
"info": {"title": "API", "version": "0.1.0"},
"paths": {
"/": {
"post": {
"responses": {
"200": {
"description": "OK",
"content": {"application/json": {}},
},
"422": {
"description": "Validation Error",
"content": {
"application/json": {
"schema": {
"$ref": "#/components/schemas/HTTPValidationError"
}
}
},
},
},
"requestBody": {
"content": {
"multipart/form-data": {
"schema": {
"required": ["realFieldName"],
"type": "object",
"properties": {
"realFieldName": {
"type": "array",
"items": {
"type": "string",
"format": "binary",
},
}
},
},
"encoding": {"realFieldName": {}},
}
},
"required": True,
},
}
}
},
"components": {
"schemas": {
"ValidationError": {
"title": "ValidationError",
"required": ["loc", "msg", "type"],
"type": "object",
"properties": {
"loc": {
"title": "Location",
"type": "array",
"items": {
"oneOf": [{"type": "string"}, {"type": "integer"}]
},
},
"msg": {"title": "Message", "type": "string"},
"type": {"title": "Error Type", "type": "string"},
},
},
"HTTPValidationError": {
"title": "HTTPValidationError",
"type": "object",
"properties": {
"detail": {
"title": "Detail",
"type": "array",
"items": {"$ref": "#/components/schemas/ValidationError"},
}
},
},
}
},
}
resp = client.get("/openapi.json")
assert resp.status_code == 200, resp.text
assert resp.json() == expected_openapi
def test_string_instead_of_file() -> None:
class FormDataModel(BaseModel):
file: FromFormFile[bytes]
async def test(body: FromMultipart[FormDataModel]) -> Response:
...
app = App([Path("/", post=test)])
client = TestClient(app)
files: Files = TruthyEmptyList()
data: Data = [("file", "notafile")]
resp = client.post("/", files=files, data=data)
assert resp.status_code == 422, resp.text
assert resp.json() == {
"detail": [
{
"loc": ["body", "file"],
"msg": "Expected a file, got a string",
"type": "type_error",
}
]
}
def test_missing_file():
class FormDataModel(BaseModel):
file: FromFormFile[bytes]
async def test(body: FromMultipart[FormDataModel]) -> Response:
...
app = App([Path("/", post=test)])
client = TestClient(app)
files: Files = TruthyEmptyList()
data: Data = [("otherfield", "placeholder")]
resp = client.post("/", files=files, data=data)
assert resp.status_code == 422, resp.text
assert resp.json() == {
"detail": [
{
"loc": ["body", "file"],
"msg": "field required",
"type": "value_error.missing",
}
]
}
@pytest.mark.parametrize(
"files,expected_response",
[
(TruthyEmptyList(), None),
(
[
(
"file",
(
"file.txt",
b"foo bar",
),
)
],
"foo bar",
),
],
)
def test_file_not_required(
files: Files,
expected_response: typing.Any,
):
class FormDataModel(BaseModel):
file: FromFormFile[typing.Optional[bytes]] = None
async def test(body: FromMultipart[FormDataModel]) -> typing.Optional[bytes]:
return body.file
app = App([Path("/", post=test)])
client = TestClient(app)
data: Data = [("otherfield", "placeholder to ensure a valid multipart body")]
resp = client.post("/", files=files, data=data)
assert resp.status_code == 200, resp.text
assert resp.json() == expected_response
def test_form_include_in_schema() -> None:
class FormDataModel(BaseModel):
file: FromFormFile[bytes]
async def test(
body: Annotated[FormDataModel, Form(include_in_schema=False)]
) -> Response:
...
app = App([Path("/", post=test)])
client = TestClient(app)
expected_openapi: typing.Dict[str, typing.Any] = {
"openapi": "3.0.3",
"info": {"title": "API", "version": "0.1.0"},
"paths": {
"/": {
"post": {
"responses": {
"200": {
"description": "OK",
"content": {"application/json": {}},
}
}
}
}
},
}
resp = client.get("/openapi.json")
assert resp.status_code == 200, resp.text
assert resp.json() == expected_openapi
def test_file_field_unknown_type() -> None:
class FormDataModel(BaseModel):
file: FromFormFile[str]
async def test(
body: Annotated[FormDataModel, Form(include_in_schema=False)]
) -> Response:
...
app = App([Path("/", post=test)])
with pytest.raises(TypeError, match="Unknown file type str"):
with TestClient(app):
pass
| 32.881285 | 90 | 0.340568 | 1,385 | 23,543 | 5.72852 | 0.099639 | 0.028989 | 0.037812 | 0.035291 | 0.873456 | 0.867406 | 0.849256 | 0.849256 | 0.835014 | 0.832619 | 0 | 0.01036 | 0.528522 | 23,543 | 715 | 91 | 32.927273 | 0.704414 | 0.001359 | 0 | 0.653188 | 0 | 0 | 0.168688 | 0.017145 | 0 | 0 | 0 | 0 | 0.043546 | 1 | 0.017107 | false | 0.001555 | 0.012442 | 0.001555 | 0.073095 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 1 | 1 | 1 | 1 | 1 | 1 | 0 | 0 | 1 | 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 | 7 |
a350651cfa1ae9e72c4ca878479bc0076a6f68ba | 2,130 | py | Python | tests/app_test.py | lusi1990/betterlifepsi | 8e7f8562967ab1816d8c25db3251c550a357f39c | [
"MIT"
] | 33 | 2018-10-19T03:41:56.000Z | 2022-01-23T16:26:02.000Z | tests/app_test.py | lusi1990/betterlifepsi | 8e7f8562967ab1816d8c25db3251c550a357f39c | [
"MIT"
] | 318 | 2018-09-23T15:16:54.000Z | 2022-03-31T22:58:55.000Z | tests/app_test.py | lusi1990/betterlifepsi | 8e7f8562967ab1816d8c25db3251c550a357f39c | [
"MIT"
] | 19 | 2018-10-22T18:04:18.000Z | 2021-12-06T19:49:05.000Z | # coding=utf-8
import unittest
from tests.base_test_case import BaseTestCase
class TestApplicationStartupAndLogin(BaseTestCase):
def test_empty_db(self):
rv = self.test_client.get('/login')
assert 302, rv.status_code
self.assertAlmostEquals('utf-8', rv.charset)
self.assertIn(b'<input id="email_or_login" name="email_or_login" type="text" value="">', rv.data)
self.assertIn(b'<input id="password" name="password" type="password" value="">', rv.data)
self.assertIn(b'<input id="submit" name="submit" type="submit"', rv.data)
def test_login_seed_user(self):
rv = self.test_client.post('/login', data=dict(email_or_login='support@betterlife.io', password='password'), follow_redirects=True)
self.assertEqual(200, rv.status_code)
self.assertIn(b'Log out', rv.data)
self.assertIn(b'Home', rv.data)
def test_login_user_not_exist(self):
rv = self.test_client.post('/login', data=dict(email_or_login='support1@betterlife.io', password='password'), follow_redirects=True)
self.assertEqual(200, rv.status_code)
self.assertIn(b'Specified user does not exist', rv.data)
self.assertIn(b'<input id="email_or_login" name="email_or_login" type="text" value="support1@betterlife.io">', rv.data)
self.assertIn(b'<input id="password" name="password" type="password" value="">', rv.data)
self.assertIn(b'<input id="submit" name="submit" type="submit"', rv.data)
def test_login_user_wrong_password(self):
rv = self.test_client.post('/login', data=dict(email_or_login='support@betterlife.io', password='password1'), follow_redirects=True)
self.assertEqual(200, rv.status_code)
self.assertIn(b'Invalid password', rv.data)
self.assertIn(b'<input id="email_or_login" name="email_or_login" type="text" value="support@betterlife.io">', rv.data)
self.assertIn(b'<input id="password" name="password" type="password" value="">', rv.data)
self.assertIn(b'<input id="submit" name="submit" type="submit"', rv.data)
if __name__ == '__main__':
unittest.main()
| 50.714286 | 140 | 0.688732 | 299 | 2,130 | 4.732441 | 0.217391 | 0.110247 | 0.119435 | 0.114488 | 0.773145 | 0.745583 | 0.727208 | 0.727208 | 0.727208 | 0.727208 | 0 | 0.009418 | 0.152582 | 2,130 | 41 | 141 | 51.95122 | 0.774515 | 0.005634 | 0 | 0.290323 | 0 | 0.064516 | 0.358696 | 0.088847 | 0 | 0 | 0 | 0 | 0.580645 | 1 | 0.129032 | false | 0.258065 | 0.064516 | 0 | 0.225806 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 1 | 1 | 1 | 1 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 1 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | 0 | 0 | 7 |
6e7d1dc278da03c224f1750879982ac68d226322 | 124 | py | Python | Prescient/views/__init__.py | RamonWill/Data-App | e4b28704940546156f9521c88eced73f1443ce7e | [
"MIT"
] | 28 | 2020-10-07T04:40:42.000Z | 2022-03-17T10:34:18.000Z | Prescient/views/__init__.py | RamonWill/Data-App | e4b28704940546156f9521c88eced73f1443ce7e | [
"MIT"
] | 2 | 2021-01-16T18:48:56.000Z | 2022-03-06T23:02:01.000Z | Prescient/views/__init__.py | RamonWill/Data-App | e4b28704940546156f9521c88eced73f1443ce7e | [
"MIT"
] | 16 | 2020-09-28T17:30:39.000Z | 2022-03-20T00:09:27.000Z | import Prescient.views.auth
import Prescient.views.dashboard
import Prescient.views.watchlist
import Prescient.views.charts
| 24.8 | 32 | 0.870968 | 16 | 124 | 6.75 | 0.4375 | 0.555556 | 0.740741 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0.064516 | 124 | 4 | 33 | 31 | 0.931034 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | true | 0 | 1 | 0 | 1 | 0 | 1 | 0 | 0 | null | 1 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 1 | 0 | 1 | 0 | 0 | 7 |
6e814d7b4b6ef6b676b85372a6b66bf65ea9685c | 36,575 | py | Python | pyreach/impl/requester_test.py | google-research/pyreach | f91753ce7a26e77e122eb02a9fdd5a1ce3ce0159 | [
"Apache-2.0"
] | 13 | 2021-09-01T01:10:22.000Z | 2022-03-05T10:01:52.000Z | pyreach/impl/requester_test.py | google-research/pyreach | f91753ce7a26e77e122eb02a9fdd5a1ce3ce0159 | [
"Apache-2.0"
] | null | null | null | pyreach/impl/requester_test.py | google-research/pyreach | f91753ce7a26e77e122eb02a9fdd5a1ce3ce0159 | [
"Apache-2.0"
] | 6 | 2021-09-20T21:17:53.000Z | 2022-03-14T18:42:48.000Z | # Copyright 2021 Google LLC
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
from typing import Optional
import unittest
from pyreach.common.python import types_gen
from pyreach.impl import requester
from pyreach.impl import thread_util
class _MockRequester(requester.Requester[str]):
def get_message_supplement(self, msg: types_gen.DeviceData) -> Optional[str]:
if (msg.device_type == "robot" and msg.device_name == "test" and
msg.data_type == "key-value" and msg.key == "robot_constraints.json"):
return msg.value
return None
def send_key_value(self, tag: str, value: str) -> None:
self.enqueue_device_data(
types_gen.DeviceData(
tag=tag,
device_type="robot",
device_name="test",
data_type="key-value",
key="robot_constraints.json",
value=value))
def send_wrong_key(self, tag: str) -> None:
self.enqueue_device_data(
types_gen.DeviceData(
tag=tag,
device_type="robot",
device_name="test",
data_type="key-value",
key="kill",
value="{}"))
class TestPyreachRequester(unittest.TestCase):
"""Test the Request and Requester classes."""
def test_request_untagged_no_timeout(self) -> None:
request: "requester.DeviceRequest[str]" = requester.DeviceRequest(
"color-camera", "left", "color", None, None)
self.assertEqual(request.device_type, "color-camera")
self.assertEqual(request.device_name, "left")
self.assertIsNone(request.tag)
terminate, send = request.on_poll()
self.assertFalse(terminate)
self.assertIsNone(send)
terminate, send = request.on_message(
types_gen.DeviceData(
device_type="color-camera", device_name="right", data_type="color"),
"test-1")
self.assertFalse(terminate)
self.assertIsNone(send)
request._resend_time = 0.0 # Force resend for test
terminate, send = request.on_message(
types_gen.DeviceData(
device_type="color-camera", device_name="right", data_type="color"),
"test-2")
self.assertFalse(terminate)
self.assertIsNotNone(send)
if send is not None:
self.assertEqual(send.device_type, "color-camera")
self.assertEqual(send.device_name, "left")
self.assertEqual(send.data_type, "frame-request")
self.assertEqual(send.tag, "")
pass_data = types_gen.DeviceData(
device_type="color-camera", device_name="left", data_type="color")
terminate, send = request.on_message(pass_data, "test-3")
self.assertTrue(terminate)
self.assertIsNone(send)
messages = thread_util.extract_all_from_queue(request.queue)
self.assertEqual(len(messages), 1)
self.assertEqual(messages[0][0], pass_data)
self.assertEqual(messages[0][1], "test-3")
request.close()
def test_request_untagged_without_timeout(self) -> None:
request: "requester.DeviceRequest[str]" = requester.DeviceRequest(
"color-camera", "left", "color", None, 100.0)
self.assertEqual(request.device_type, "color-camera")
self.assertEqual(request.device_name, "left")
self.assertIsNone(request.tag)
terminate, send = request.on_poll()
self.assertFalse(terminate)
self.assertIsNone(send)
terminate, send = request.on_message(
types_gen.DeviceData(
device_type="color-camera", device_name="right", data_type="color"),
"test-1")
self.assertFalse(terminate)
self.assertIsNone(send)
request._resend_time = 0.0 # Force resend for test
terminate, send = request.on_message(
types_gen.DeviceData(
device_type="color-camera", device_name="right", data_type="color"),
"test-2")
self.assertFalse(terminate)
self.assertNotEqual(send, None)
if send is not None:
self.assertEqual(send.device_type, "color-camera")
self.assertEqual(send.device_name, "left")
self.assertEqual(send.data_type, "frame-request")
self.assertEqual(send.tag, "")
pass_data = types_gen.DeviceData(
device_type="color-camera", device_name="left", data_type="color")
terminate, send = request.on_message(pass_data, "test-3")
self.assertTrue(terminate)
self.assertIsNone(send)
messages = thread_util.extract_all_from_queue(request.queue)
self.assertEqual(len(messages), 1)
self.assertEqual(messages[0][0], pass_data)
self.assertEqual(messages[0][1], "test-3")
request.close()
def test_request_untagged_with_timeout(self) -> None:
request: "requester.DeviceRequest[str]" = requester.DeviceRequest(
"color-camera", "left", "color", None, 0.0)
self.assertEqual(request.device_type, "color-camera")
self.assertEqual(request.device_name, "left")
self.assertIsNone(request.tag)
terminate, send = request.on_poll()
self.assertTrue(terminate)
self.assertIsNone(send)
messages = thread_util.extract_all_from_queue(request.queue)
self.assertEqual(len(messages), 0)
request.close()
def test_request_untagged_with_timeout_message(self) -> None:
request: "requester.DeviceRequest[str]" = requester.DeviceRequest(
"color-camera", "left", "color", None, 0.0)
self.assertEqual(request.device_type, "color-camera")
self.assertEqual(request.device_name, "left")
self.assertIsNone(request.tag)
pass_data = types_gen.DeviceData(
device_type="color-camera", device_name="left", data_type="color")
terminate, send = request.on_message(pass_data, "test-1")
self.assertTrue(terminate)
self.assertIsNone(send)
messages = thread_util.extract_all_from_queue(request.queue)
self.assertEqual(len(messages), 1)
self.assertEqual(messages[0][0], pass_data)
self.assertEqual(messages[0][1], "test-1")
request.close()
def test_request_untagged_with_timeout_wrong_message(self) -> None:
request: "requester.DeviceRequest[str]" = requester.DeviceRequest(
"color-camera", "left", "color", None, 0.0)
self.assertEqual(request.device_type, "color-camera")
self.assertEqual(request.device_name, "left")
self.assertIsNone(request.tag)
pass_data = types_gen.DeviceData(
device_type="color-camera", device_name="right", data_type="color")
terminate, send = request.on_message(pass_data, "test-1")
self.assertTrue(terminate)
self.assertIsNone(send)
messages = thread_util.extract_all_from_queue(request.queue)
self.assertEqual(len(messages), 0)
request.close()
def test_request_tagged_no_timeout(self) -> None:
request: "requester.DeviceRequest[str]" = requester.DeviceRequest(
"color-camera", "left", "color", "test-tag", None)
self.assertEqual(request.device_type, "color-camera")
self.assertEqual(request.device_name, "left")
self.assertEqual(request.tag, "test-tag")
terminate, send = request.on_poll()
self.assertFalse(terminate)
self.assertIsNone(send)
terminate, send = request.on_message(
types_gen.DeviceData(
device_type="color-camera",
device_name="left",
data_type="color",
tag="ignore"), "test-1")
self.assertFalse(terminate)
self.assertIsNone(send)
pass_data_0 = types_gen.DeviceData(
device_type="color-camera",
device_name="cmd-status",
data_type="color",
tag="test-tag",
status="executing")
terminate, send = request.on_message(pass_data_0, None)
self.assertFalse(terminate)
self.assertIsNone(send)
pass_data_1 = types_gen.DeviceData(
device_type="color-camera",
device_name="left",
data_type="color",
tag="test-tag")
self.assertIsNone(send)
terminate, send = request.on_message(pass_data_1, "test-2")
self.assertFalse(terminate)
self.assertIsNone(send)
pass_data_2 = types_gen.DeviceData(
device_type="color-camera",
device_name="left",
data_type="cmd-status",
tag="test-tag",
status="executing")
terminate, send = request.on_message(pass_data_2, None)
self.assertFalse(terminate)
self.assertIsNone(send)
pass_data_3 = types_gen.DeviceData(
device_type="color-camera",
device_name="left",
data_type="cmd-status",
tag="test-tag",
status="done")
terminate, send = request.on_message(pass_data_3, None)
self.assertTrue(terminate)
self.assertIsNone(send)
messages = thread_util.extract_all_from_queue(request.queue)
self.assertEqual(len(messages), 4)
self.assertEqual(messages[0][0], pass_data_0)
self.assertIsNone(messages[0][1])
self.assertEqual(messages[1][0], pass_data_1)
self.assertEqual(messages[1][1], "test-2")
self.assertEqual(messages[2][0], pass_data_2)
self.assertIsNone(messages[2][1])
self.assertEqual(messages[3][0], pass_data_3)
self.assertIsNone(messages[3][1])
request.close()
def test_request_tagged_no_timeout_swap(self) -> None:
request: "requester.DeviceRequest[str]" = requester.DeviceRequest(
"color-camera", "left", "color", "test-tag", None)
self.assertEqual(request.device_type, "color-camera")
self.assertEqual(request.device_name, "left")
self.assertEqual(request.tag, "test-tag")
terminate, send = request.on_poll()
self.assertFalse(terminate)
self.assertIsNone(send)
terminate, send = request.on_message(
types_gen.DeviceData(
device_type="color-camera",
device_name="left",
data_type="color",
tag="ignore"), "test-1")
self.assertFalse(terminate)
self.assertIsNone(send)
pass_data_0 = types_gen.DeviceData(
device_type="color-camera",
device_name="cmd-status",
data_type="color",
tag="test-tag",
status="executing")
terminate, send = request.on_message(pass_data_0, None)
self.assertFalse(terminate)
self.assertIsNone(send)
pass_data_1 = types_gen.DeviceData(
device_type="color-camera",
device_name="left",
data_type="cmd-status",
tag="test-tag",
status="done")
terminate, send = request.on_message(pass_data_1, None)
self.assertTrue(terminate)
self.assertIsNone(send)
messages = thread_util.extract_all_from_queue(request.queue)
self.assertEqual(len(messages), 2)
self.assertEqual(messages[0][0], pass_data_0)
self.assertIsNone(messages[0][1])
self.assertEqual(messages[1][0], pass_data_1)
self.assertIsNone(messages[1][1])
request.close()
def test_request_tagged_no_timeout_expect_messages(self) -> None:
request: "requester.DeviceRequest[str]" = requester.DeviceRequest(
"color-camera", "left", "color", "test-tag", None, expect_messages=1)
self.assertEqual(request.device_type, "color-camera")
self.assertEqual(request.device_name, "left")
self.assertEqual(request.tag, "test-tag")
terminate, send = request.on_poll()
self.assertFalse(terminate)
self.assertIsNone(send)
terminate, send = request.on_message(
types_gen.DeviceData(
device_type="color-camera",
device_name="left",
data_type="color",
tag="ignore"), "test-0")
self.assertFalse(terminate)
self.assertIsNone(send)
pass_data_0 = types_gen.DeviceData(
device_type="color-camera",
device_name="left",
data_type="color",
tag="test-tag")
terminate, send = request.on_message(pass_data_0, "test-1")
self.assertFalse(terminate)
self.assertIsNone(send)
pass_data_1 = types_gen.DeviceData(
device_type="color-camera",
device_name="left",
data_type="cmd-status",
tag="test-tag",
status="done")
terminate, send = request.on_message(pass_data_1, None)
self.assertTrue(terminate)
self.assertIsNone(send)
messages = thread_util.extract_all_from_queue(request.queue)
self.assertEqual(len(messages), 2)
self.assertEqual(messages[0][0], pass_data_0)
self.assertEqual(messages[0][1], "test-1")
self.assertEqual(messages[1][0], pass_data_1)
self.assertIsNone(messages[1][1])
request.close()
def test_request_tagged_no_timeout_expect_messages_swap(self) -> None:
request: "requester.DeviceRequest[str]" = requester.DeviceRequest(
"color-camera", "left", "color", "test-tag", None, expect_messages=1)
self.assertEqual(request.device_type, "color-camera")
self.assertEqual(request.device_name, "left")
self.assertEqual(request.tag, "test-tag")
terminate, send = request.on_poll()
self.assertFalse(terminate)
self.assertIsNone(send)
terminate, send = request.on_message(
types_gen.DeviceData(
device_type="color-camera",
device_name="left",
data_type="color",
tag="ignore"), "test-0")
self.assertFalse(terminate)
self.assertIsNone(send)
pass_data_0 = types_gen.DeviceData(
device_type="color-camera",
device_name="left",
data_type="cmd-status",
tag="test-tag",
status="done")
terminate, send = request.on_message(pass_data_0, None)
self.assertFalse(terminate)
self.assertIsNone(send)
pass_data_1 = types_gen.DeviceData(
device_type="color-camera",
device_name="left",
data_type="color",
tag="test-tag")
terminate, send = request.on_message(pass_data_1, "test-1")
self.assertTrue(terminate)
self.assertIsNone(send)
messages = thread_util.extract_all_from_queue(request.queue)
self.assertEqual(len(messages), 2)
self.assertEqual(messages[0][0], pass_data_1)
self.assertEqual(messages[0][1], "test-1")
self.assertEqual(messages[1][0], pass_data_0)
self.assertIsNone(messages[1][1])
request.close()
def test_request_tagged_no_timeout_expect_messages_error(self) -> None:
request: "requester.DeviceRequest[str]" = requester.DeviceRequest(
"color-camera", "left", "color", "test-tag", None, expect_messages=1)
self.assertEqual(request.device_type, "color-camera")
self.assertEqual(request.device_name, "left")
self.assertEqual(request.tag, "test-tag")
terminate, send = request.on_poll()
self.assertFalse(terminate)
self.assertIsNone(send)
terminate, send = request.on_message(
types_gen.DeviceData(
device_type="color-camera",
device_name="left",
data_type="color",
tag="ignore"), "test-0")
self.assertFalse(terminate)
self.assertIsNone(send)
pass_data_0 = types_gen.DeviceData(
device_type="color-camera",
device_name="left",
data_type="cmd-status",
tag="test-tag",
status="done",
error="died")
terminate, send = request.on_message(pass_data_0, None)
self.assertTrue(terminate)
self.assertIsNone(send)
messages = thread_util.extract_all_from_queue(request.queue)
self.assertEqual(len(messages), 1)
self.assertEqual(messages[0][0], pass_data_0)
self.assertIsNone(messages[0][1])
request.close()
def test_request_tagged_no_timeout_expect_messages_skip_status(self) -> None:
request: "requester.DeviceRequest[str]" = requester.DeviceRequest(
"color-camera",
"left",
"color",
"test-tag",
None,
expect_messages=1,
expect_cmd_status=False)
self.assertEqual(request.device_type, "color-camera")
self.assertEqual(request.device_name, "left")
self.assertEqual(request.tag, "test-tag")
terminate, send = request.on_poll()
self.assertFalse(terminate)
self.assertIsNone(send)
terminate, send = request.on_message(
types_gen.DeviceData(
device_type="color-camera",
device_name="left",
data_type="color",
tag="ignore"), "test-0")
self.assertFalse(terminate)
self.assertIsNone(send)
pass_data_0 = types_gen.DeviceData(
device_type="color-camera",
device_name="left",
data_type="color",
tag="test-tag")
terminate, send = request.on_message(pass_data_0, "test-1")
self.assertTrue(terminate)
self.assertIsNone(send)
messages = thread_util.extract_all_from_queue(request.queue)
self.assertEqual(len(messages), 1)
self.assertEqual(messages[0][0], pass_data_0)
self.assertEqual(messages[0][1], "test-1")
request.close()
def test_request_tagged_no_timeout_expect_messages_skip_status_error(
self) -> None:
request: "requester.DeviceRequest[str]" = requester.DeviceRequest(
"color-camera",
"left",
"color",
"test-tag",
None,
expect_messages=1,
expect_cmd_status=False)
self.assertEqual(request.device_type, "color-camera")
self.assertEqual(request.device_name, "left")
self.assertEqual(request.tag, "test-tag")
terminate, send = request.on_poll()
self.assertFalse(terminate)
self.assertIsNone(send)
terminate, send = request.on_message(
types_gen.DeviceData(
device_type="color-camera",
device_name="left",
data_type="color",
tag="ignore"), "test-0")
self.assertFalse(terminate)
self.assertIsNone(send)
pass_data_0 = types_gen.DeviceData(
device_type="color-camera",
device_name="left",
data_type="cmd-status",
tag="test-tag",
status="done",
error="died")
terminate, send = request.on_message(pass_data_0, None)
self.assertTrue(terminate)
self.assertIsNone(send)
messages = thread_util.extract_all_from_queue(request.queue)
self.assertEqual(len(messages), 1)
self.assertEqual(messages[0][0], pass_data_0)
self.assertIsNone(messages[0][1])
request.close()
def test_request_tagged_without_timeout(self) -> None:
request: "requester.DeviceRequest[str]" = requester.DeviceRequest(
"color-camera", "left", "color", "test-tag", 100.0)
self.assertEqual(request.device_type, "color-camera")
self.assertEqual(request.device_name, "left")
self.assertEqual(request.tag, "test-tag")
terminate, send = request.on_poll()
self.assertFalse(terminate)
self.assertIsNone(send)
terminate, send = request.on_message(
types_gen.DeviceData(
device_type="color-camera",
device_name="left",
data_type="color",
tag="ignore"), "test-1")
self.assertFalse(terminate)
self.assertIsNone(send)
pass_data_0 = types_gen.DeviceData(
device_type="color-camera",
device_name="cmd-status",
data_type="color",
tag="test-tag",
status="executing")
terminate, send = request.on_message(pass_data_0, None)
self.assertFalse(terminate)
self.assertIsNone(send)
pass_data_1 = types_gen.DeviceData(
device_type="color-camera",
device_name="left",
data_type="color",
tag="test-tag")
self.assertIsNone(send)
terminate, send = request.on_message(pass_data_1, "test-2")
self.assertFalse(terminate)
self.assertIsNone(send)
pass_data_2 = types_gen.DeviceData(
device_type="color-camera",
device_name="left",
data_type="cmd-status",
tag="test-tag",
status="executing")
terminate, send = request.on_message(pass_data_2, None)
self.assertFalse(terminate)
self.assertIsNone(send)
pass_data_3 = types_gen.DeviceData(
device_type="color-camera",
device_name="left",
data_type="cmd-status",
tag="test-tag",
status="done")
terminate, send = request.on_message(pass_data_3, None)
self.assertTrue(terminate)
self.assertIsNone(send)
messages = thread_util.extract_all_from_queue(request.queue)
self.assertEqual(len(messages), 4)
self.assertEqual(messages[0][0], pass_data_0)
self.assertIsNone(messages[0][1])
self.assertEqual(messages[1][0], pass_data_1)
self.assertEqual(messages[1][1], "test-2")
self.assertEqual(messages[2][0], pass_data_2)
self.assertIsNone(messages[2][1])
self.assertEqual(messages[3][0], pass_data_3)
self.assertIsNone(messages[3][1])
request.close()
def test_request_tagged_without_timeout_swap(self) -> None:
request: "requester.DeviceRequest[str]" = requester.DeviceRequest(
"color-camera", "left", "color", "test-tag", 100.0)
self.assertEqual(request.device_type, "color-camera")
self.assertEqual(request.device_name, "left")
self.assertEqual(request.tag, "test-tag")
terminate, send = request.on_poll()
self.assertFalse(terminate)
self.assertIsNone(send)
terminate, send = request.on_message(
types_gen.DeviceData(
device_type="color-camera",
device_name="left",
data_type="color",
tag="ignore"), "test-1")
self.assertFalse(terminate)
self.assertIsNone(send)
pass_data_0 = types_gen.DeviceData(
device_type="color-camera",
device_name="cmd-status",
data_type="color",
tag="test-tag",
status="executing")
terminate, send = request.on_message(pass_data_0, None)
self.assertFalse(terminate)
self.assertIsNone(send)
pass_data_1 = types_gen.DeviceData(
device_type="color-camera",
device_name="left",
data_type="cmd-status",
tag="test-tag",
status="done")
terminate, send = request.on_message(pass_data_1, None)
self.assertTrue(terminate)
self.assertIsNone(send)
messages = thread_util.extract_all_from_queue(request.queue)
self.assertEqual(len(messages), 2)
self.assertEqual(messages[0][0], pass_data_0)
self.assertIsNone(messages[0][1])
self.assertEqual(messages[1][0], pass_data_1)
self.assertIsNone(messages[1][1])
request.close()
def test_request_tagged_without_timeout_expect_messages(self) -> None:
request: "requester.DeviceRequest[str]" = requester.DeviceRequest(
"color-camera", "left", "color", "test-tag", 100.0, expect_messages=1)
self.assertEqual(request.device_type, "color-camera")
self.assertEqual(request.device_name, "left")
self.assertEqual(request.tag, "test-tag")
terminate, send = request.on_poll()
self.assertFalse(terminate)
self.assertIsNone(send)
terminate, send = request.on_message(
types_gen.DeviceData(
device_type="color-camera",
device_name="left",
data_type="color",
tag="ignore"), "test-0")
self.assertFalse(terminate)
self.assertIsNone(send)
pass_data_0 = types_gen.DeviceData(
device_type="color-camera",
device_name="left",
data_type="color",
tag="test-tag")
terminate, send = request.on_message(pass_data_0, "test-1")
self.assertFalse(terminate)
self.assertIsNone(send)
pass_data_1 = types_gen.DeviceData(
device_type="color-camera",
device_name="left",
data_type="cmd-status",
tag="test-tag",
status="done")
terminate, send = request.on_message(pass_data_1, None)
self.assertTrue(terminate)
self.assertIsNone(send)
messages = thread_util.extract_all_from_queue(request.queue)
self.assertEqual(len(messages), 2)
self.assertEqual(messages[0][0], pass_data_0)
self.assertEqual(messages[0][1], "test-1")
self.assertEqual(messages[1][0], pass_data_1)
self.assertIsNone(messages[1][1])
request.close()
def test_request_tagged_without_timeout_expect_messages_swap(self) -> None:
request: "requester.DeviceRequest[str]" = requester.DeviceRequest(
"color-camera", "left", "color", "test-tag", 100.0, expect_messages=1)
self.assertEqual(request.device_type, "color-camera")
self.assertEqual(request.device_name, "left")
self.assertEqual(request.tag, "test-tag")
terminate, send = request.on_poll()
self.assertFalse(terminate)
self.assertIsNone(send)
terminate, send = request.on_message(
types_gen.DeviceData(
device_type="color-camera",
device_name="left",
data_type="color",
tag="ignore"), "test-0")
self.assertFalse(terminate)
self.assertIsNone(send)
pass_data_0 = types_gen.DeviceData(
device_type="color-camera",
device_name="left",
data_type="cmd-status",
tag="test-tag",
status="done")
terminate, send = request.on_message(pass_data_0, None)
self.assertFalse(terminate)
self.assertIsNone(send)
pass_data_1 = types_gen.DeviceData(
device_type="color-camera",
device_name="left",
data_type="color",
tag="test-tag")
terminate, send = request.on_message(pass_data_1, "test-1")
self.assertTrue(terminate)
self.assertIsNone(send)
messages = thread_util.extract_all_from_queue(request.queue)
self.assertEqual(len(messages), 2)
self.assertEqual(messages[0][0], pass_data_1)
self.assertEqual(messages[0][1], "test-1")
self.assertEqual(messages[1][0], pass_data_0)
self.assertIsNone(messages[1][1])
request.close()
def test_request_tagged_without_timeout_expect_messages_error(self) -> None:
request: "requester.DeviceRequest[str]" = requester.DeviceRequest(
"color-camera", "left", "color", "test-tag", 100.0, expect_messages=1)
self.assertEqual(request.device_type, "color-camera")
self.assertEqual(request.device_name, "left")
self.assertEqual(request.tag, "test-tag")
terminate, send = request.on_poll()
self.assertFalse(terminate)
self.assertIsNone(send)
terminate, send = request.on_message(
types_gen.DeviceData(
device_type="color-camera",
device_name="left",
data_type="color",
tag="ignore"), "test-0")
self.assertFalse(terminate)
self.assertIsNone(send)
pass_data_0 = types_gen.DeviceData(
device_type="color-camera",
device_name="left",
data_type="cmd-status",
tag="test-tag",
status="done",
error="died")
terminate, send = request.on_message(pass_data_0, None)
self.assertTrue(terminate)
self.assertIsNone(send)
messages = thread_util.extract_all_from_queue(request.queue)
self.assertEqual(len(messages), 1)
self.assertEqual(messages[0][0], pass_data_0)
self.assertIsNone(messages[0][1])
request.close()
def test_request_tagged_without_timeout_expect_messages_skip_status(
self) -> None:
request: "requester.DeviceRequest[str]" = requester.DeviceRequest(
"color-camera",
"left",
"color",
"test-tag",
100.0,
expect_messages=1,
expect_cmd_status=False)
self.assertEqual(request.device_type, "color-camera")
self.assertEqual(request.device_name, "left")
self.assertEqual(request.tag, "test-tag")
terminate, send = request.on_poll()
self.assertFalse(terminate)
self.assertIsNone(send)
terminate, send = request.on_message(
types_gen.DeviceData(
device_type="color-camera",
device_name="left",
data_type="color",
tag="ignore"), "test-0")
self.assertFalse(terminate)
self.assertIsNone(send)
pass_data_0 = types_gen.DeviceData(
device_type="color-camera",
device_name="left",
data_type="color",
tag="test-tag")
terminate, send = request.on_message(pass_data_0, "test-1")
self.assertTrue(terminate)
self.assertIsNone(send)
messages = thread_util.extract_all_from_queue(request.queue)
self.assertEqual(len(messages), 1)
self.assertEqual(messages[0][0], pass_data_0)
self.assertEqual(messages[0][1], "test-1")
request.close()
def test_request_tagged_without_timeout_expect_messages_skip_status_error(
self) -> None:
request: "requester.DeviceRequest[str]" = requester.DeviceRequest(
"color-camera",
"left",
"color",
"test-tag",
100.0,
expect_messages=1,
expect_cmd_status=False)
self.assertEqual(request.device_type, "color-camera")
self.assertEqual(request.device_name, "left")
self.assertEqual(request.tag, "test-tag")
terminate, send = request.on_poll()
self.assertFalse(terminate)
self.assertIsNone(send)
terminate, send = request.on_message(
types_gen.DeviceData(
device_type="color-camera",
device_name="left",
data_type="color",
tag="ignore"), "test-0")
self.assertFalse(terminate)
self.assertIsNone(send)
pass_data_0 = types_gen.DeviceData(
device_type="color-camera",
device_name="left",
data_type="cmd-status",
tag="test-tag",
status="done",
error="died")
terminate, send = request.on_message(pass_data_0, None)
self.assertTrue(terminate)
self.assertIsNone(send)
messages = thread_util.extract_all_from_queue(request.queue)
self.assertEqual(len(messages), 1)
self.assertEqual(messages[0][0], pass_data_0)
self.assertIsNone(messages[0][1])
request.close()
def test_request_tagged_with_timeout(self) -> None:
request: "requester.DeviceRequest[str]" = requester.DeviceRequest(
"color-camera", "left", "color", "test-tag", 0)
self.assertEqual(request.device_type, "color-camera")
self.assertEqual(request.device_name, "left")
self.assertEqual(request.tag, "test-tag")
pass_data_0 = types_gen.DeviceData(
device_type="color-camera",
device_name="cmd-status",
data_type="color",
tag="test-tag",
status="executing")
terminate, send = request.on_message(pass_data_0, None)
self.assertTrue(terminate)
self.assertIsNone(send)
messages = thread_util.extract_all_from_queue(request.queue)
self.assertEqual(len(messages), 1)
self.assertEqual(messages[0][0], pass_data_0)
self.assertIsNone(messages[0][1])
request.close()
def test_request_tagged_with_timeout_swap(self) -> None:
request: "requester.DeviceRequest[str]" = requester.DeviceRequest(
"color-camera", "left", "color", "test-tag", 0)
self.assertEqual(request.device_type, "color-camera")
self.assertEqual(request.device_name, "left")
self.assertEqual(request.tag, "test-tag")
pass_data_0 = types_gen.DeviceData(
device_type="color-camera",
device_name="cmd-status",
data_type="color",
tag="test-tag",
status="executing")
terminate, send = request.on_message(pass_data_0, None)
self.assertTrue(terminate)
self.assertIsNone(send)
messages = thread_util.extract_all_from_queue(request.queue)
self.assertEqual(len(messages), 1)
self.assertEqual(messages[0][0], pass_data_0)
self.assertIsNone(messages[0][1])
request.close()
def test_request_tagged_with_timeout_expect_messages(self) -> None:
request: "requester.DeviceRequest[str]" = requester.DeviceRequest(
"color-camera", "left", "color", "test-tag", 0, expect_messages=1)
self.assertEqual(request.device_type, "color-camera")
self.assertEqual(request.device_name, "left")
self.assertEqual(request.tag, "test-tag")
pass_data_0 = types_gen.DeviceData(
device_type="color-camera",
device_name="left",
data_type="color",
tag="test-tag")
terminate, send = request.on_message(pass_data_0, "test-1")
self.assertTrue(terminate)
self.assertIsNone(send)
messages = thread_util.extract_all_from_queue(request.queue)
self.assertEqual(len(messages), 1)
self.assertEqual(messages[0][0], pass_data_0)
self.assertEqual(messages[0][1], "test-1")
request.close()
def test_request_tagged_with_timeout_expect_messages_swap(self) -> None:
request: "requester.DeviceRequest[str]" = requester.DeviceRequest(
"color-camera", "left", "color", "test-tag", 0, expect_messages=1)
self.assertEqual(request.device_type, "color-camera")
self.assertEqual(request.device_name, "left")
self.assertEqual(request.tag, "test-tag")
pass_data_0 = types_gen.DeviceData(
device_type="color-camera",
device_name="left",
data_type="cmd-status",
tag="test-tag",
status="done")
terminate, send = request.on_message(pass_data_0, None)
self.assertTrue(terminate)
self.assertIsNone(send)
messages = thread_util.extract_all_from_queue(request.queue)
self.assertEqual(len(messages), 0)
request.close()
def test_request_tagged_with_timeout_expect_messages_error(self) -> None:
request: "requester.DeviceRequest[str]" = requester.DeviceRequest(
"color-camera", "left", "color", "test-tag", 0, expect_messages=1)
self.assertEqual(request.device_type, "color-camera")
self.assertEqual(request.device_name, "left")
self.assertEqual(request.tag, "test-tag")
pass_data_0 = types_gen.DeviceData(
device_type="color-camera",
device_name="left",
data_type="cmd-status",
tag="test-tag",
status="done",
error="died")
terminate, send = request.on_message(pass_data_0, None)
self.assertTrue(terminate)
self.assertIsNone(send)
messages = thread_util.extract_all_from_queue(request.queue)
self.assertEqual(len(messages), 1)
self.assertEqual(messages[0][0], pass_data_0)
self.assertIsNone(messages[0][1])
request.close()
def test_request_tagged_with_timeout_expect_messages_skip_status(
self) -> None:
request: "requester.DeviceRequest[str]" = requester.DeviceRequest(
"color-camera",
"left",
"color",
"test-tag",
0,
expect_messages=1,
expect_cmd_status=False)
self.assertEqual(request.device_type, "color-camera")
self.assertEqual(request.device_name, "left")
self.assertEqual(request.tag, "test-tag")
pass_data_0 = types_gen.DeviceData(
device_type="color-camera",
device_name="left",
data_type="color",
tag="test-tag")
terminate, send = request.on_message(pass_data_0, "test-1")
self.assertTrue(terminate)
self.assertIsNone(send)
messages = thread_util.extract_all_from_queue(request.queue)
self.assertEqual(len(messages), 1)
self.assertEqual(messages[0][0], pass_data_0)
self.assertEqual(messages[0][1], "test-1")
request.close()
def test_request_tagged_with_timeout_expect_messages_skip_status_error(
self) -> None:
request: "requester.DeviceRequest[str]" = requester.DeviceRequest(
"color-camera",
"left",
"color",
"test-tag",
0,
expect_messages=1,
expect_cmd_status=False)
self.assertEqual(request.device_type, "color-camera")
self.assertEqual(request.device_name, "left")
self.assertEqual(request.tag, "test-tag")
pass_data_0 = types_gen.DeviceData(
device_type="color-camera",
device_name="left",
data_type="cmd-status",
tag="test-tag",
status="done",
error="died")
terminate, send = request.on_message(pass_data_0, None)
self.assertTrue(terminate)
self.assertIsNone(send)
messages = thread_util.extract_all_from_queue(request.queue)
self.assertEqual(len(messages), 1)
self.assertEqual(messages[0][0], pass_data_0)
self.assertIsNone(messages[0][1])
request.close()
def test_requester(self) -> None:
callback_capturer: "thread_util.CallbackCapturer[str]" = (
thread_util.CallbackCapturer())
device = _MockRequester()
device.add_update_callback(callback_capturer.callback_false,
callback_capturer.finished_callback)
device.start()
self.assertIsNone(device.get_cached())
device.send_key_value("", "{}")
device.send_wrong_key("")
device.close()
self.assertEqual(device.get_cached(), "{}")
states = callback_capturer.wait()
self.assertEqual(len(states), 0)
if __name__ == "__main__":
unittest.main()
| 38.059313 | 80 | 0.674012 | 4,451 | 36,575 | 5.334981 | 0.036621 | 0.099175 | 0.05243 | 0.073402 | 0.940916 | 0.940916 | 0.940916 | 0.940916 | 0.939316 | 0.938937 | 0 | 0.012969 | 0.194696 | 36,575 | 960 | 81 | 38.098958 | 0.793237 | 0.017307 | 0 | 0.928177 | 0 | 0 | 0.11937 | 0.02241 | 0 | 0 | 0 | 0 | 0.365746 | 1 | 0.033149 | false | 0.120442 | 0.005525 | 0 | 0.043094 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 1 | 1 | 1 | 1 | 1 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | 0 | 0 | 8 |
42c8ce83f166b7de751c5abdc7d512a316f79e0e | 134 | py | Python | tests/conftest.py | anirbanroydas/elaster | 08b5873d7a61d01905d059e08cc9ba533358e684 | [
"MIT"
] | 1 | 2017-05-18T19:46:16.000Z | 2017-05-18T19:46:16.000Z | tests/conftest.py | anirbanroydas/elaster | 08b5873d7a61d01905d059e08cc9ba533358e684 | [
"MIT"
] | null | null | null | tests/conftest.py | anirbanroydas/elaster | 08b5873d7a61d01905d059e08cc9ba533358e684 | [
"MIT"
] | null | null | null | import pytest
from elaster.server import main as elaster_app
@pytest.fixture(scope='session')
def app():
return elaster_app
| 16.75 | 46 | 0.746269 | 19 | 134 | 5.157895 | 0.684211 | 0.204082 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0.171642 | 134 | 8 | 47 | 16.75 | 0.882883 | 0 | 0 | 0 | 0 | 0 | 0.051852 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0.2 | true | 0 | 0.4 | 0.2 | 0.8 | 0 | 1 | 0 | 0 | null | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 1 | 1 | 1 | 0 | 0 | 7 |
6e22f451f7e60d094c762d3e67cf31a716cbcfc5 | 84,676 | py | Python | whoahqa/tests/test_base.py | onaio/who-adolescent-hqa | 108a7e60b025d0723247f5f02eab2c4d41f5a02a | [
"Apache-2.0"
] | null | null | null | whoahqa/tests/test_base.py | onaio/who-adolescent-hqa | 108a7e60b025d0723247f5f02eab2c4d41f5a02a | [
"Apache-2.0"
] | 2 | 2018-01-09T08:58:11.000Z | 2019-01-18T09:20:14.000Z | whoahqa/tests/test_base.py | onaio/who-adolescent-hqa | 108a7e60b025d0723247f5f02eab2c4d41f5a02a | [
"Apache-2.0"
] | null | null | null | import os
import unittest
import transaction
import datetime
from pyramid.registry import Registry
from pyramid import testing
from pyramid.paster import (
get_appsettings
)
from pyramid.security import IAuthenticationPolicy
from sqlalchemy import engine_from_config
from webtest import TestApp
from whoahqa import main
from whoahqa.constants import groups
from whoahqa.utils import enketo
from whoahqa.security import pwd_context
from whoahqa.models import (
DBSession,
Base,
User,
UserSettings,
UserProfile,
Group,
Submission,
OnaUser,
Clinic,
Municipality,
ReportingPeriod,
State
)
SETTINGS_FILE = 'test.ini'
settings = get_appsettings(SETTINGS_FILE)
engine = engine_from_config(settings, 'sqlalchemy.')
class TestBase(unittest.TestCase):
submissions = [
# clinic.id = 1 submissions
'{"characteristic_nine/ch9_invalid": "0", "subscriber_id": "no subscriberid property in enketo", "_tags": [], "characteristic_eight/ch8_score": "0", "characteristic_six/ch6_score": "1", "characteristic_thirteen/ch13_score": "2", "_xform_id_string": "adolescent_client_V3", "characteristic_thirteen/ch13_q1/ch13_q1e": "0", "characteristic_thirteen/ch13_q1/ch13_q1d": "1", "characteristic_fourteen/ch14_invalid": "1", "characteristic_thirteen/ch13_q1/ch13_q1a": "1", "characteristic_thirteen/ch13_q1/ch13_q1c": "0", "characteristic_thirteen/ch13_q1/ch13_q1b": "0", "characteristic_three/ch3_invalid": "0", "facility_info/facility_cnes": "1A2B", "characteristic_ten/ch10_score": "4", "characteristic_fourteen/ch14_q2": "0", "start_time": "2015-03-13T14:25:49.000+03:00", "characteristic_three/ch3_q1": "pessoal_da_administracao", "characteristic_fourteen/ch14_q6": "0", "characteristic_seventeen/ch17_score": "NaN", "facility_info/state": "distrito_federal", "characteristic_seven/ch7_invalid": "0", "characteristic_twelve/ch12_invalid": "0", "resp_demographics/resp_sex": "male", "terminate_int9": "0", "terminate_int8": "0", "terminate_int7": "0", "_submission_time": "2015-03-13T12:06:57", "terminate_int5": "0", "terminate_int4": "0", "terminate_int3": "0", "terminate_int2": "0", "_geolocation": [null, null], "characteristic_eleven/ch11_q1": "1", "characteristic_eleven/ch11_q2": "00", "characteristic_eleven/ch11_q3": "1", "characteristic_sixteen/ch16_invalid": "0", "characteristic_nine/ch9_q2/ch9_q2b": "0", "characteristic_nine/ch9_q2/ch9_q2c": "1", "characteristic_nine/ch9_q2/ch9_q2a": "0", "total_invalid8": "2", "total_invalid9": "2", "facility_info/municipality": "brasilia", "total_invalid2": "0", "meta/instanceID": "uuid:42006843-79da-472e-ae83-eadb021119e5", "total_invalid4": "0", "total_invalid5": "1", "total_invalid6": "1", "total_invalid7": "1", "characteristic_five/ch5_q1": "1", "characteristic_nineteen/ch19_score": "1", "characteristic_six/ch6_q2": "Fliers", "characteristic_six/ch6_q1": "1", "characteristic_one/ch1_invalid": "0", "characteristic_twenty/ch20_q1": "1", "facility_info/HS_char": "one two three five six seven eight nine ten eleven twelve thirteen fourteen fifteen sixteen nineteen twenty", "end_time": "2015-03-13T15:06:56.000+03:00", "phone_number": "no phonenumber property in enketo", "characteristic_seven/ch7_score": "2", "characteristic_one/ch1_score": "1", "facility_info/reporting_period": "1may_31jul_2015", "meta/deprecatedID": "uuid:88aad751-1917-4f28-9462-430475705dc3", "_uuid": "42006843-79da-472e-ae83-eadb021119e5", "characteristic_eleven/ch11_score": "2", "characteristic_two/ch2_q1": "1", "_version": "201503121224", "characteristic_five/ch5_score": "1", "terminate_int6": "0", "resp_demographics/resp_in_school": "no", "_notes": [], "resp_demographics/resp_age": 18, "terminate_int": "0", "characteristic_fifteen/ch15_score": "0", "_bamboo_dataset_id": "", "characteristic_three/ch3_score": "1", "characteristic_fifteen/ch15_invalid": "0", "characteristic_five/ch5_invalid": "0", "terminate_int10": "0", "characteristic_ten/ch10_q2": "1", "characteristic_ten/ch10_q3": "1", "characteristic_ten/ch10_q1": "1", "characteristic_ten/ch10_q4": "1", "characteristic_nineteen/ch19_invalid": "0", "characteristic_twelve/ch12_score": "0", "_status": "submitted_via_web", "characteristic_nine/ch9_q1/ch9_q1c": "0", "characteristic_seven/ch7_q3": "1", "characteristic_seven/ch7_q2": "1", "characteristic_seven/ch7_q1": "0", "characteristic_twelve/ch12_q1": "0", "characteristic_twelve/ch12_q3": "0", "characteristic_twelve/ch12_q2": "0", "resp_demographics/resp_marital_status": "boyfriend_girlfriend", "characteristic_fifteen/ch15_q2": "0", "characteristic_fifteen/ch15_q1": "0", "characteristic_eight/ch8_invalid": "0", "characteristic_one/ch1_q2": "0", "characteristic_one/ch1_q1": "1", "characteristic_nineteen/ch19_q1": "1", "characteristic_nineteen/ch19_q2": "0", "characteristic_twenty/ch20_score": "1", "total_invalid": "0", "characteristic_six/ch6_invalid": "0", "characteristic_ten/ch10_invalid": "0", "characteristic_eight/ch8_q1": "0", "characteristic_sixteen/ch16_score": "1", "total_invalid3": "0", "characteristic_twenty/ch20_invalid": "0", "sim_serial": "no simserial property in enketo", "_duration": 2467.0, "characteristic_nine/ch9_score": "2", "total_invalid10": "2", "characteristic_fourteen/ch14_q1": "1", "characteristic_seventeen/ch17_invalid": "1", "characteristic_two/ch2_score": "1", "characteristic_two/ch2_invalid": "0", "characteristic_thirteen/ch13_invalid": "0", "characteristic_nine/ch9_q1/ch9_q1a": "1", "characteristic_nine/ch9_q1/ch9_q1b": "0", "formhub/uuid": "89f76ed6137d4d1f8986e6c1f2d30603", "characteristic_fourteen/ch14_score": "NaN", "_attachments": [], "characteristic_eleven/ch11_invalid": "0", "_submitted_by": null, "characteristic_sixteen/ch16_q1": "0", "device_id": "localhost:cOUuftC4kZnkSPZs", "characteristic_sixteen/ch16_q2": "1", "_id": 309, "facility_info/interviewer_name": "Geoffrey Muchai"}', # noqa
'{"characteristic_nine/ch9_invalid":"0","subscriber_id":"no subscriberid property in enketo","_tags":[],"characteristic_eight/ch8_score":"1","characteristic_six/ch6_score":"1","characteristic_thirteen/ch13_score":"5","_xform_id_string":"adolescent_client_V3","characteristic_thirteen/ch13_q1/ch13_q1e":"1","characteristic_thirteen/ch13_q1/ch13_q1d":"1","characteristic_fourteen/ch14_invalid":"0","characteristic_thirteen/ch13_q1/ch13_q1a":"1","characteristic_thirteen/ch13_q1/ch13_q1c":"1","characteristic_thirteen/ch13_q1/ch13_q1b":"1","characteristic_three/ch3_invalid":"0","facility_info/facility_cnes":"1A2B","characteristic_ten/ch10_score":"0","characteristic_fourteen/ch14_q2":"1","characteristic_fourteen/ch14_q3":"1","start_time":"2015-03-13T15:08:58.000+03:00","characteristic_three/ch3_q1":"recepcionista","characteristic_seventeen/ch17_invalid":"1","chara cteristic_fourteen/ch14_q4":"1","characteristic_fourteen/ch14_q5":"1","characteristic_seventeen/ch17_score":"NaN","facility_info/state":"distrito_federal","characteristic_seven/ch7_invalid":"0","characteristic_twelve/ch12_invalid":"0","resp_demographics/resp_sex":"male","terminate_int9":"0","terminate_int8":"0","terminate_int7":"0","_submission_time":"2015-03-13T12:30:12","terminate_int5":"0","terminate_int4":"0","terminate_int3":"0","terminate_int2":"0","_geolocation":[null,null],"characteristic_eleven/ch11_q1":"1","characteristic_eleven/ch11_q2":"1","characteristic_eleven/ch11_q3":"1","characteristic_sixteen/ch16_invalid":"0","characteristic_nine/ch9_q2/ch9_q2b":"1","characteristic_nine/ch9_q2/ch9_q2c":"1","characteristic_nine/ch9_q2/ch9_q2a":"1","total_invalid8":"1","total_invalid9":"1","facility_info/municipality":"brasilia","total_invalid2":"0","meta/instanceID":"uuid:0736cff4-a0e7-4510-bb34-8d124776ea76","total_invalid4":"0","total_invalid5":"0","total_invalid6":"0","total_invalid7":"0","characteristic_five/ch5_q1":"1","characteristic_nineteen/ch19_score":"2","characteristic_six/ch6_q2":"TV","characteristic_six/ch6_q1":"1", "meta/deprecatedID": "uuid:88aad751-1917-4f28-9462-430475705dc3", "characteristic_one/ch1_invalid":"0","facility_info/reporting_period":"1may_31jul_2015","facility_info/HS_char":"one two three five six seven eight nine ten eleven twelve thirteen fourteen fifteen sixteen nineteen twenty","end_time":"2015-03-13T15:30:12.000+03:00","phone_number":"no phonenumber property in enketo","characteristic_seven/ch7_score":"2","characteristic_one/ch1_score":"1","characteristic_twenty/ch20_q1":"1","_uuid":"0736cff4-a0e7-4510-bb34-8d124776ea76","characteristic_eleven/ch11_score":"3","characteristic_two/ch2_q1":"1","_version":"201503121224","characteristic_five/ch5_score":"1","terminate_int6":"0","resp_demographics/resp_in_school":"no","_notes":[],"resp_demographics/resp_age":16,"terminate_int":"0","characteristic_fifteen/ch15_score":"2","_bamboo_dataset_id":"","characteristic_three/ch3_score":"1","characteristic_fifteen/ch15_invalid":"0","characteristic_five/ch5_invalid":"0","terminate_int10":"0","characteristic_ten/ch10_q2":"0","characteristic_ten/ch10_q3":"0","characteristic_ten/ch10_q1":"0","characteristic_ten/ch10_q4":"0","characteristic_nineteen/ch19_invalid":"0","characteristic_twelve/ch12_score":"3","_status":"submitted_via_web","characteristic_nine/ch9_q1/ch9_q1c":"1","characteristic_seven/ch7_q3":"1","characteristic_seven/ch7_q2":"0","characteristic_seven/ch7_q1":"1","characteristic_twelve/ch12_q1":"1","characteristic_twelve/ch12_q3":"1","characteristic_twelve/ch12_q2":"1","resp_demographics/resp_marital_status":"single","characteristic_fifteen/ch15_q2":"1","characteristic_fifteen/ch15_q1":"1","characteristic_eight/ch8_invalid":"0","characteristic_one/ch1_q2":"0","characteristic_one/ch1_q1":"1","characteristic_nineteen/ch19_q1":"1","characteristic_nineteen/ch19_q2":"1","characteristic_twenty/ch20_score":"1","total_invalid":"0","characteristic_six/ch6_invalid":"0","characteristic_ten/ch10_invalid":"0","characteristic_eight/ch8_q1":"1","characteristic_sixteen/ch16_score":"2","total_invalid3":"0","characteristic_twenty/ch20_invalid":"0","sim_serial":"no simserial property in enketo","_duration":1274,"characteristic_nine/ch9_score":"6","total_invalid10":"1","characteristic_fourteen/ch14_q1":"1","characteristic_fourteen/ch14_q6":"1","characteristic_two/ch2_score":"1","characteristic_two/ch2_invalid":"0","characteristic_thirteen/ch13_invalid":"0","characteristic_nine/ch9_q1/ch9_q1a":"1","characteristic_nine/ch9_q1/ch9_q1b":"1","formhub/uuid":"89f76ed6137d4d1f8986e6c1f2d30603","characteristic_fourteen/ch14_score":"6","_attachments":[],"characteristic_eleven/ch11_invalid":"0","_submitted_by":null,"characteristic_sixteen/ch16_q1":"1","device_id":"localhost:cOUuftC4kZnkSPZs","characteristic_sixteen/ch16_q2":"1","_id":310,"facility_info/interviewer_name":"Geof"}', # noqa
'{"characteristic_nine/ch9_invalid":"0","subscriber_id":"no subscriberid property in enketo","_tags":[],"characteristic_eight/ch8_score":"0","characteristic_six/ch6_score":"0","characteristic_thirteen/ch13_score":"0","_xform_id_string":"adolescent_client_V3","characteristic_thirteen/ch13_q1/ch13_q1e":"0","characteristic_thirteen/ch13_q1/ch13_q1d":"0","characteristic_fourteen/ch14_invalid":"0","characteristic_thirteen/ch13_q1/ch13_q1a":"0","characteristic_thirteen/ch13_q1/ch13_q1c":"0","characteristic_thirteen/ch13_q1/ch13_q1b":"0","characteristic_three/ch3_invalid":"0","facility_info/facility_cnes":"1A2B", "characteristic_ten/ch10_score":"4","characteristic_fourteen/ch14_q2":"0","characteristic_fourteen/ch14_q3":"0","start_time":"2015-03-13T15:32:14.000+03:00","characteristic_three/ch3_q1":"pessoal_da_administracao","characteristic_seventeen/ch17_invalid":"1","characteristic_fourteen/ch14_q4":"0","characteristic_fourteen/ch14_q5":"0","characteristic_seventeen/ch17_score":"NaN","facility_info/state":"distrito_federal","characteristic_seven/ch7_invalid":"0","characteristic_twelve/ch12_invalid":"0","resp_demographics/resp_sex":"female","terminate_int9":"0","terminate_int8":"0","terminate_int7":"0","terminate_int6":"0","terminate_int5":"0","terminate_int4":"0","terminate_int3":"0","terminate_int2":"0","_geolocation":[null,null],"characteristic_eleven/ch11_q1":"0","characteristic_eleven/ch11_q2":"0","characteristic_eleven/ch11_q3":"0","characteristic_sixteen/ch16_invalid":"0","characteristic_nine/ch9_q2/ch9_q2b":"0","characteristic_nine/ch9_q2/ch9_q2c":"0","characteristic_nine/ch9_q2/ch9_q2a":"0","total_invalid8":"1","total_invalid9":"1","facility_info/municipality":"brasilia","total_invalid2":"0","meta/instanceID":"uuid:7f028d33-3ab0-4518-8f54-0e70abbd8adf","total_invalid4":"0","total_invalid5":"0","total_invalid6":"0","total_invalid7":"0","characteristic_five/ch5_q1":"0","characteristic_nineteen/ch19_score":"0","characteristic_six/ch6_q2":"bla bla bla","characteristic_six/ch6_q1":"0","characteristic_one/ch1_invalid":"0","facility_info/reporting_period":"1may_31jul_2015","facility_info/HS_char":"one two three five six seven eight nine ten eleven twelve thirteen fourteen fifteen sixteen nineteen twenty","end_time":"2015-03-13T15:40:29.000+03:00","phone_number":"no phonenumber property in enketo","characteristic_seven/ch7_score":"1", "meta/deprecatedID": "uuid:88aad751-1917-4f28-9462-430475705dc3", "characteristic_one/ch1_score":"2","characteristic_twenty/ch20_q1":"0","_uuid":"7f028d33-3ab0-4518-8f54-0e70abbd8adf","characteristic_eleven/ch11_score":"0","characteristic_two/ch2_q1":"0","_version":"201503121224","characteristic_five/ch5_score":"0","resp_demographics/resp_in_school":"yes","_notes":[],"resp_demographics/resp_age":16,"terminate_int":"0","characteristic_fifteen/ch15_score":"0","_bamboo_dataset_id":"","characteristic_three/ch3_score":"1","characteristic_fifteen/ch15_invalid":"0","characteristic_five/ch5_invalid":"0","terminate_int10":"0","characteristic_ten/ch10_q2":"1","characteristic_ten/ch10_q3":"1","characteristic_ten/ch10_q1":"1","characteristic_ten/ch10_q4":"1","characteristic_nineteen/ch19_invalid":"0","characteristic_twelve/ch12_score":"0","_status":"submitted_via_web","characteristic_nine/ch9_q1/ch9_q1c":"0","characteristic_seven/ch7_q3":"0","characteristic_seven/ch7_q2":"1","characteristic_seven/ch7_q1":"0","characteristic_twelve/ch12_q1":"0","characteristic_twelve/ch12_q3":"0","characteristic_twelve/ch12_q2":"0","resp_demographics/resp_marital_status":"live_together","characteristic_fifteen/ch15_q2":"0","characteristic_fifteen/ch15_q1":"0","characteristic_eight/ch8_invalid":"0","characteristic_one/ch1_q2":"1","characteristic_one/ch1_q1":"1","characteristic_nineteen/ch19_q1":"0","characteristic_nineteen/ch19_q2":"0","characteristic_twenty/ch20_score":"0","total_invalid":"0","characteristic_six/ch6_invalid":"0","characteristic_ten/ch10_invalid":"0","characteristic_eight/ch8_q1":"0","characteristic_sixteen/ch16_score":"0","total_invalid3":"0","characteristic_twenty/ch20_invalid":"0","sim_serial":"no simserial property in enketo","_duration":495,"characteristic_nine/ch9_score":"0","total_invalid10":"1","characteristic_fourteen/ch14_q1":"0","characteristic_fourteen/ch14_q6":"0","characteristic_two/ch2_score":"0","characteristic_two/ch2_invalid":"0","resp_demographics/resp_in_school_yes":"ensino_superior","characteristic_thirteen/ch13_invalid":"0","characteristic_nine/ch9_q1/ch9_q1a":"0","characteristic_nine/ch9_q1/ch9_q1b":"0","formhub/uuid":"89f76ed6137d4d1f8986e6c1f2d30603","_submission_time":"2015-03-13T12:40:29","characteristic_fourteen/ch14_score":"0","_attachments":[],"characteristic_eleven/ch11_invalid":"0","_submitted_by":null,"characteristic_sixteen/ch16_q1":"0","device_id":"localhost:cOUuftC4kZnkSPZs","characteristic_sixteen/ch16_q2":"0","_id":311,"facility_info/interviewer_name":"Anita"}', # noqa
# clinic.id = 2 submissions '{"facility_info/facility_cnes": "1A2B", "facility_info/municipality": "Brasilia", "facility_info/state": "Acre", "_notes": [], "_bamboo_dataset_id": "", "_tags": [], "respondent_dem/respondent_sex": "male", "_xform_id_string": "health_care_provider_interview", "respondent_dem/study_yes_Esp": "Yes", "characteristic_one/ch1_q1_yes": "A lot of patients", "respondent_dem/res_age": "17", "facility_info/facility_geopoint": "-1.2988326 36.7906152 0.0 31.12", "meta/instanceID": "uuid:af18e938-8cb7-4a99-aa6d-35b05ae942d2", "_geolocation": ["-1.2988326", "36.7906152"], "_status": "submitted_via_web", "facility_info/HS_char": "one three", "respondent_dem/study": "yes", "characteristic_three/ch3_q1": "1", "respondent_dem/marital_status": "married", "characteristic_three/ch3_q2": "0", "characteristic_three/ch3_q3": "0", "_uuid": "ac18e938-8cb7-4a99-aa6d-35b05ae942d3", "characteristic_three/ch3_q4": "1", "facility_info/interviewer": "Hask", "respondent_dem/highest_study": "College", "formhub/uuid": "873bba82422444eda5c4d05d39f73616", "characteristic_one/ch1_q1": "1", "_submission_time": "2014-02-06T08:56:02", "_attachments": [], "facility_info/reporting_period": "2014-02-06", "facility_info/interview_date": "2014-02-06", "_id": 24651}', # noqa
'{"characteristic_nine/ch9_invalid": "0", "subscriber_id": "no subscriberid property in enketo", "_tags": [], "characteristic_eight/ch8_score": "0", "characteristic_six/ch6_score": "1", "characteristic_thirteen/ch13_score": "2", "_xform_id_string": "adolescent_client_V3", "characteristic_thirteen/ch13_q1/ch13_q1e": "0", "characteristic_thirteen/ch13_q1/ch13_q1d": "1", "characteristic_fourteen/ch14_invalid": "1", "characteristic_thirteen/ch13_q1/ch13_q1a": "1", "characteristic_thirteen/ch13_q1/ch13_q1c": "0", "characteristic_thirteen/ch13_q1/ch13_q1b": "0", "characteristic_three/ch3_invalid": "0", "facility_info/facility_cnes": "3E4G", "characteristic_ten/ch10_score": "4", "characteristic_fourteen/ch14_q2": "0", "start_time": "2015-03-13T14:25:49.000+03:00", "characteristic_three/ch3_q1": "pessoal_da_administracao", "characteristic_fourteen/ch14_q6": "0", "characteristic_seventeen/ch17_score": "NaN", "facility_info/state": "distrito_federal", "characteristic_seven/ch7_invalid": "0", "characteristic_twelve/ch12_invalid": "0", "resp_demographics/resp_sex": "male", "terminate_int9": "0", "terminate_int8": "0", "terminate_int7": "0", "_submission_time": "2015-03-13T12:06:57", "terminate_int5": "0", "terminate_int4": "0", "terminate_int3": "0", "terminate_int2": "0", "_geolocation": [null, null], "characteristic_eleven/ch11_q1": "1", "characteristic_eleven/ch11_q2": "00", "characteristic_eleven/ch11_q3": "1", "characteristic_sixteen/ch16_invalid": "0", "characteristic_nine/ch9_q2/ch9_q2b": "0", "characteristic_nine/ch9_q2/ch9_q2c": "1", "characteristic_nine/ch9_q2/ch9_q2a": "0", "total_invalid8": "2", "total_invalid9": "2", "facility_info/municipality": "brasilia", "total_invalid2": "0", "meta/instanceID": "uuid:42006843-79da-472e-ae83-eadb021119e5", "total_invalid4": "0", "total_invalid5": "1", "total_invalid6": "1", "total_invalid7": "1", "characteristic_five/ch5_q1": "1", "characteristic_nineteen/ch19_score": "1", "characteristic_six/ch6_q2": "Fliers", "characteristic_six/ch6_q1": "1", "characteristic_one/ch1_invalid": "0", "characteristic_twenty/ch20_q1": "1", "facility_info/HS_char": "one two three five six seven eight nine ten eleven twelve thirteen fourteen fifteen sixteen nineteen twenty", "end_time": "2015-03-13T15:06:56.000+03:00", "phone_number": "no phonenumber property in enketo", "characteristic_seven/ch7_score": "2", "characteristic_one/ch1_score": "1", "facility_info/reporting_period": "1may_31jul_2015", "_uuid": "42006843-79da-472e-ae83-eadb021119e5", "characteristic_eleven/ch11_score": "2", "characteristic_two/ch2_q1": "1", "_version": "201503121224", "characteristic_five/ch5_score": "1", "terminate_int6": "0", "resp_demographics/resp_in_school": "no", "_notes": [], "resp_demographics/resp_age": 18, "terminate_int": "0", "characteristic_fifteen/ch15_score": "0", "_bamboo_dataset_id": "", "characteristic_three/ch3_score": "1", "characteristic_fifteen/ch15_invalid": "0", "characteristic_five/ch5_invalid": "0", "terminate_int10": "0", "characteristic_ten/ch10_q2": "1", "characteristic_ten/ch10_q3": "1", "characteristic_ten/ch10_q1": "1", "characteristic_ten/ch10_q4": "1", "characteristic_nineteen/ch19_invalid": "0", "characteristic_twelve/ch12_score": "0", "_status": "submitted_via_web", "characteristic_nine/ch9_q1/ch9_q1c": "0", "characteristic_seven/ch7_q3": "1", "characteristic_seven/ch7_q2": "1", "characteristic_seven/ch7_q1": "0", "characteristic_twelve/ch12_q1": "0", "characteristic_twelve/ch12_q3": "0", "characteristic_twelve/ch12_q2": "0", "resp_demographics/resp_marital_status": "boyfriend_girlfriend", "characteristic_fifteen/ch15_q2": "0", "characteristic_fifteen/ch15_q1": "0", "characteristic_eight/ch8_invalid": "0", "meta/deprecatedID": "uuid:88aad751-1917-4f28-9462-430475705dc3", "characteristic_one/ch1_q2": "0", "characteristic_one/ch1_q1": "1", "characteristic_nineteen/ch19_q1": "1", "characteristic_nineteen/ch19_q2": "0", "characteristic_twenty/ch20_score": "1", "total_invalid": "0", "characteristic_six/ch6_invalid": "0", "characteristic_ten/ch10_invalid": "0", "characteristic_eight/ch8_q1": "0", "characteristic_sixteen/ch16_score": "1", "total_invalid3": "0", "characteristic_twenty/ch20_invalid": "0", "sim_serial": "no simserial property in enketo", "_duration": 2467.0, "characteristic_nine/ch9_score": "2", "total_invalid10": "2", "characteristic_fourteen/ch14_q1": "1", "characteristic_seventeen/ch17_invalid": "1", "characteristic_two/ch2_score": "1", "characteristic_two/ch2_invalid": "0", "characteristic_thirteen/ch13_invalid": "0", "characteristic_nine/ch9_q1/ch9_q1a": "1", "characteristic_nine/ch9_q1/ch9_q1b": "0", "formhub/uuid": "89f76ed6137d4d1f8986e6c1f2d30603", "characteristic_fourteen/ch14_score": "NaN", "_attachments": [], "characteristic_eleven/ch11_invalid": "0", "_submitted_by": null, "characteristic_sixteen/ch16_q1": "0", "device_id": "localhost:cOUuftC4kZnkSPZs", "characteristic_sixteen/ch16_q2": "1", "_id": 309, "facility_info/interviewer_name": "Geoffrey Muchai"}', # noqa
'{"characteristic_nine/ch9_invalid":"0","subscriber_id":"no subscriberid property in enketo","_tags":[],"characteristic_eight/ch8_score":"1","characteristic_six/ch6_score":"1","characteristic_thirteen/ch13_score":"5","_xform_id_string":"adolescent_client_V3","characteristic_thirteen/ch13_q1/ch13_q1e":"1","characteristic_thirteen/ch13_q1/ch13_q1d":"1","characteristic_fourteen/ch14_invalid":"0","characteristic_thirteen/ch13_q1/ch13_q1a":"1","characteristic_thirteen/ch13_q1/ch13_q1c":"1","characteristic_thirteen/ch13_q1/ch13_q1b":"1","characteristic_three/ch3_invalid":"0","facility_info/facility_cnes":"3E4G", "characteristic_ten/ch10_score":"0","characteristic_fourteen/ch14_q2":"1","characteristic_fourteen/ch14_q3":"1","start_time":"2015-03-13T15:08:58.000+03:00","characteristic_three/ch3_q1":"recepcionista","characteristic_seventeen/ch17_invalid":"1","characteristic_fourteen/ch14_q4":"1","characteristic_fourteen/ch14_q5":"1","characteristic_seventeen/ch17_score":"NaN","facility_info/state":"distrito_federal","characteristic_seven/ch7_invalid":"0","characteristic_twelve/ch12_invalid":"0","resp_demographics/resp_sex":"male","terminate_int9":"0","terminate_int8":"0","terminate_int7":"0","_submission_time":"2015-03-13T12:30:12","terminate_int5":"0","terminate_int4":"0","terminate_int3":"0","terminate_int2":"0","_geolocation":[null,null],"characteristic_eleven/ch11_q1":"1","characteristic_eleven/ch11_q2":"1","characteristic_eleven/ch11_q3":"1","characteristic_sixteen/ch16_invalid":"0","characteristic_nine/ch9_q2/ch9_q2b":"1","characteristic_nine/ch9_q2/ch9_q2c":"1","characteristic_nine/ch9_q2/ch9_q2a":"1","total_invalid8":"1","total_invalid9":"1","facility_info/municipality":"brasilia","total_invalid2":"0","meta/instanceID":"uuid:0736cff4-a0e7-4510-bb34-8d124776ea76","total_invalid4":"0","total_invalid5":"0","total_invalid6":"0","total_invalid7":"0","characteristic_five/ch5_q1":"1","characteristic_nineteen/ch19_score":"2","characteristic_six/ch6_q2":"TV","characteristic_six/ch6_q1":"1","characteristic_one/ch1_invalid":"0","facility_info/reporting_period":"1may_31jul_2015","facility_info/HS_char":"one two three five six seven eight nine ten eleven twelve thirteen fourteen fifteen sixteen nineteen twenty","end_time":"2015-03-13T15:30:12.000+03:00","phone_number":"no phonenumber property in enketo","characteristic_seven/ch7_score":"2","characteristic_one/ch1_score":"1","characteristic_twenty/ch20_q1":"1", "meta/deprecatedID": "uuid:88aad751-1917-4f28-9462-430475705dc3", "_uuid":"0736cff4-a0e7-4510-bb34-8d124776ea76","characteristic_eleven/ch11_score":"3","characteristic_two/ch2_q1":"1","_version":"201503121224","characteristic_five/ch5_score":"1","terminate_int6":"0","resp_demographics/resp_in_school":"no","_notes":[],"resp_demographics/resp_age":16,"terminate_int":"0","characteristic_fifteen/ch15_score":"2","_bamboo_dataset_id":"","characteristic_three/ch3_score":"1","characteristic_fifteen/ch15_invalid":"0","characteristic_five/ch5_invalid":"0","terminate_int10":"0","characteristic_ten/ch10_q2":"0","characteristic_ten/ch10_q3":"0","characteristic_ten/ch10_q1":"0","characteristic_ten/ch10_q4":"0","characteristic_nineteen/ch19_invalid":"0","characteristic_twelve/ch12_score":"3","_status":"submitted_via_web","characteristic_nine/ch9_q1/ch9_q1c":"1","characteristic_seven/ch7_q3":"1","characteristic_seven/ch7_q2":"0","characteristic_seven/ch7_q1":"1","characteristic_twelve/ch12_q1":"1","characteristic_twelve/ch12_q3":"1","characteristic_twelve/ch12_q2":"1","resp_demographics/resp_marital_status":"single","characteristic_fifteen/ch15_q2":"1","characteristic_fifteen/ch15_q1":"1","characteristic_eight/ch8_invalid":"0","characteristic_one/ch1_q2":"0","characteristic_one/ch1_q1":"1","characteristic_nineteen/ch19_q1":"1","characteristic_nineteen/ch19_q2":"1","characteristic_twenty/ch20_score":"1","total_invalid":"0","characteristic_six/ch6_invalid":"0","characteristic_ten/ch10_invalid":"0","characteristic_eight/ch8_q1":"1","characteristic_sixteen/ch16_score":"2","total_invalid3":"0","characteristic_twenty/ch20_invalid":"0","sim_serial":"no simserial property in enketo","_duration":1274,"characteristic_nine/ch9_score":"6","total_invalid10":"1","characteristic_fourteen/ch14_q1":"1","characteristic_fourteen/ch14_q6":"1","characteristic_two/ch2_score":"1","characteristic_two/ch2_invalid":"0","characteristic_thirteen/ch13_invalid":"0","characteristic_nine/ch9_q1/ch9_q1a":"1","characteristic_nine/ch9_q1/ch9_q1b":"1","formhub/uuid":"89f76ed6137d4d1f8986e6c1f2d30603","characteristic_fourteen/ch14_score":"6","_attachments":[],"characteristic_eleven/ch11_invalid":"0","_submitted_by":null,"characteristic_sixteen/ch16_q1":"1","device_id":"localhost:cOUuftC4kZnkSPZs","characteristic_sixteen/ch16_q2":"1","_id":310,"facility_info/interviewer_name":"Geof"}', # noqa
# non existent clinic id
'{"characteristic_nine/ch9_invalid":"0","subscriber_id":"no subscriberid property in enketo","_tags":[],"characteristic_eight/ch8_score":"1","characteristic_six/ch6_score":"1","characteristic_thirteen/ch13_score":"5","_xform_id_string":"adolescent_client_V3","characteristic_thirteen/ch13_q1/ch13_q1e":"1","characteristic_thirteen/ch13_q1/ch13_q1d":"1","characteristic_fourteen/ch14_invalid":"0","characteristic_thirteen/ch13_q1/ch13_q1a":"1","characteristic_thirteen/ch13_q1/ch13_q1c":"1","characteristic_thirteen/ch13_q1/ch13_q1b":"1","characteristic_three/ch3_invalid":"0","facility_info/facility_cnes":"no-such-clinic","characteristic_ten/ch10_score":"0","characteristic_fourteen/ch14_q2":"1","characteristic_fourteen/ch14_q3":"1","start_time":"2015-03-13T15:08:58.000+03:00","characteristic_three/ch3_q1":"recepcionista","characteristic_seventeen/ch17_invalid":"1","characteristic_fourteen/ch14_q4":"1","characteristic_fourteen/ch14_q5":"1","characteristic_seventeen/ch17_score":"NaN","facility_info/state":"distrito_federal","characteristic_seven/ch7_invalid":"0","characteristic_twelve/ch12_invalid":"0","resp_demographics/resp_sex":"male","terminate_int9":"0","terminate_int8":"0","terminate_int7":"0","_submission_time":"2015-03-13T12:30:12","terminate_int5":"0","terminate_int4":"0","terminate_int3":"0","terminate_int2":"0","_geolocation":[null,null],"characteristic_eleven/ch11_q1":"1","characteristic_eleven/ch11_q2":"1","characteristic_eleven/ch11_q3":"1","characteristic_sixteen/ch16_invalid":"0","characteristic_nine/ch9_q2/ch9_q2b":"1","characteristic_nine/ch9_q2/ch9_q2c":"1","characteristic_nine/ch9_q2/ch9_q2a":"1","total_invalid8":"1","total_invalid9":"1","facility_info/municipality":"brasilia","total_invalid2":"0","meta/instanceID":"uuid:0736cff4-a0e7-4510-bb34-8d124776ea76","total_invalid4":"0","total_invalid5":"0","total_invalid6":"0","total_invalid7":"0","characteristic_five/ch5_q1":"1","characteristic_nineteen/ch19_score":"2","characteristic_six/ch6_q2":"TV","characteristic_six/ch6_q1":"1","characteristic_one/ch1_invalid":"0","facility_info/reporting_period":"1may_31jul_2015","facility_info/HS_char":"one two three five six seven eight nine ten eleven twelve thirteen fourteen fifteen sixteen nineteen twenty","end_time":"2015-03-13T15:30:12.000+03:00","phone_number":"no phonenumber property in enketo","characteristic_seven/ch7_score":"2","characteristic_one/ch1_score":"1","characteristic_twenty/ch20_q1":"1","_uuid":"0736cff4-a0e7-4510-bb34-8d124776ea76","characteristic_eleven/ch11_score":"3","characteristic_two/ch2_q1":"1","_version":"201503121224", "meta/deprecatedID": "uuid:88aad751-1917-4f28-9462-430475705dc3", "characteristic_five/ch5_score":"1","terminate_int6":"0","resp_demographics/resp_in_school":"no","_notes":[],"resp_demographics/resp_age":16,"terminate_int":"0","characteristic_fifteen/ch15_score":"2","_bamboo_dataset_id":"","characteristic_three/ch3_score":"1","characteristic_fifteen/ch15_invalid":"0","characteristic_five/ch5_invalid":"0","terminate_int10":"0","characteristic_ten/ch10_q2":"0","characteristic_ten/ch10_q3":"0","characteristic_ten/ch10_q1":"0","characteristic_ten/ch10_q4":"0","characteristic_nineteen/ch19_invalid":"0","characteristic_twelve/ch12_score":"3","_status":"submitted_via_web","characteristic_nine/ch9_q1/ch9_q1c":"1","characteristic_seven/ch7_q3":"1","characteristic_seven/ch7_q2":"0","characteristic_seven/ch7_q1":"1","characteristic_twelve/ch12_q1":"1","characteristic_twelve/ch12_q3":"1","characteristic_twelve/ch12_q2":"1","resp_demographics/resp_marital_status":"single","characteristic_fifteen/ch15_q2":"1","characteristic_fifteen/ch15_q1":"1","characteristic_eight/ch8_invalid":"0","characteristic_one/ch1_q2":"0","characteristic_one/ch1_q1":"1","characteristic_nineteen/ch19_q1":"1","characteristic_nineteen/ch19_q2":"1","characteristic_twenty/ch20_score":"1","total_invalid":"0","characteristic_six/ch6_invalid":"0","characteristic_ten/ch10_invalid":"0","characteristic_eight/ch8_q1":"1","characteristic_sixteen/ch16_score":"2","total_invalid3":"0","characteristic_twenty/ch20_invalid":"0","sim_serial":"no simserial property in enketo","_duration":1274,"characteristic_nine/ch9_score":"6","total_invalid10":"1","characteristic_fourteen/ch14_q1":"1","characteristic_fourteen/ch14_q6":"1","characteristic_two/ch2_score":"1","characteristic_two/ch2_invalid":"0","characteristic_thirteen/ch13_invalid":"0","characteristic_nine/ch9_q1/ch9_q1a":"1","characteristic_nine/ch9_q1/ch9_q1b":"1","formhub/uuid":"89f76ed6137d4d1f8986e6c1f2d30603","characteristic_fourteen/ch14_score":"6","_attachments":[],"characteristic_eleven/ch11_invalid":"0","_submitted_by":null,"characteristic_sixteen/ch16_q1":"1","device_id":"localhost:cOUuftC4kZnkSPZs","characteristic_sixteen/ch16_q2":"1","_id":310,"facility_info/interviewer_name":"Geof"}', # noqa
]
clinic_registrations = [
'{"facility_info/facility_cnes": "1A2B", "facility_info/municipality": "Brasilia", "facility_info/state": "Acre", "_notes": [], "_id": 27761, "user_id": "2", "_submission_time": "2014-02-20T09:24:40", "_uuid": "a3814ab2-6fcc-472b-9a7c-450d92b4fb10", "_bamboo_dataset_id": "", "_tags": [], "_attachments": [], "_geolocation": [null, null], "_xform_id_string": "clinic_registration", "_status": "submitted_via_web", "meta/instanceID": "uuid:a3814ab2-6fcc-472b-9a7c-450d92b4fb10", "facility_info/facility_name": "New Kakamega Clinic", "formhub/uuid": "4796cf1b830840b0a326cc16eda45083"}', # noqa
# bad user id
'{"facility_info/facility_cnes": "3E4G", "facility_info/municipality": "Brasilia", "facility_info/state": "Acre", "_notes": [], "_id": 27761, "user_id": "-1", "_submission_time": "2014-02-20T09:24:40", "_uuid": "a3814ab2-6fcc-472b-9a7c-450d92b4fb10", "_bamboo_dataset_id": "", "_tags": [], "_attachments": [], "_geolocation": [null, null], "_xform_id_string": "clinic_registration", "_status": "submitted_via_web", "meta/instanceID": "uuid:a3814ab2-6fcc-472b-9a7c-450d92b4fb10", "facility_info/facility_name": "New Kakamega Clinic", "formhub/uuid": "4796cf1b830840b0a326cc16eda45083"}' # noqa
]
brazil_submissions = [
# clinic.id = 1
'{"facility_info/facility_cnes": "1A2B", "facility_info/municipality": "Brasilia", "facility_info/state": "Acre", "_notes": [], "_bamboo_dataset_id": "", "_tags": [], "respondent_dem/respondent_sex": "male", "_xform_id_string": "health_care_provider_interview", "respondent_dem/study_yes_Esp": "Yes", "characteristic_one/ch1_q1_yes": "A lot of patients", "respondent_dem/res_age": "17", "facility_info/facility_geopoint": "-1.2988326 36.7906152 0.0 31.12", "meta/instanceID": "uuid:af18e938-8cb7-4a99-aa6d-35b05ae942d2", "_geolocation": ["-1.2988326", "36.7906152"], "_status": "submitted_via_web", "facility_info/HS_char": "one three", "respondent_dem/study": "yes", "characteristic_three/ch3_q1": "999", "respondent_dem/marital_status": "married", "characteristic_three/ch3_q2": "0", "characteristic_three/ch3_q3": "0", "_uuid": "ac18e938-8cb7-4a99-aa6d-35b05ae942d3", "characteristic_three/ch3_q4": "1", "facility_info/interviewer": "Hask", "respondent_dem/highest_study": "College", "formhub/uuid": "873bba82422444eda5c4d05d39f73616", "characteristic_one/ch1_q1": "1", "_submission_time": "2014-02-06T08:56:02", "_attachments": [], "facility_info/reporting_period": "2014-02-06", "facility_info/interview_date": "2014-02-06", "_id": 24651}', # noqa
'{"facility_info/facility_cnes": "1A2B", "facility_info/municipality": "Brasilia", "facility_info/state": "Acre", "_notes": [], "_bamboo_dataset_id": "", "_tags": [], "respondent_dem/respondent_sex": "female", "_xform_id_string": "adolescent_client_V3", "respondent_dem/study_yes_Esp": "Yes", "characteristic_one/ch1_q1_yes": "A lot of patients", "respondent_dem/res_age": "17", "facility_info/facility_geopoint": "-1.2988326 36.7906152 0.0 31.12", "meta/instanceID": "uuid:af18e938-8cb7-4a99-aa6d-35b05ae942d2", "_geolocation": ["-1.2988326", "36.7906152"], "_status": "submitted_via_web", "facility_info/HS_char": "one three", "respondent_dem/study": "yes", "characteristic_three/ch3_q1": "1", "respondent_dem/marital_status": "married", "characteristic_three/ch3_q2": "999", "characteristic_three/ch3_q3": "0", "_uuid": "af18e938-8cb7-4a99-aa6d-35b05ae942d2", "characteristic_three/ch3_q4": "0", "facility_info/interviewer": "Kwhba", "respondent_dem/highest_study": "High school", "formhub/uuid": "753bba82422444eda5c4d05d39f73667", "characteristic_one/ch1_q2": "1", "characteristic_one/ch1_q1": "0", "_submission_time": "2014-02-06T08:56:02", "_attachments": [], "facility_info/reporting_period": "2014-02-06", "facility_info/interview_date": "2014-02-06", "_id": 24651}', # noqa
'{"facility_info/facility_cnes": "1A2B", "facility_info/municipality": "Brasilia", "facility_info/state": "Acre", "_notes": [], "_bamboo_dataset_id": "", "_tags": [], "respondent_dem/respondent_sex": "female", "_xform_id_string": "adolescent_client_V3", "respondent_dem/study_yes_Esp": "Yes", "characteristic_one/ch1_q1_yes": "A lot of patients", "respondent_dem/res_age": "17", "facility_info/facility_geopoint": "-1.2988326 36.7906152 0.0 31.12", "meta/instanceID": "uuid:af18e938-8cb7-4a99-aa6d-35b05ae942d2", "_geolocation": ["-1.2988326", "36.7906152"], "_status": "submitted_via_web", "facility_info/HS_char": "one three", "respondent_dem/study": "yes", "characteristic_three/ch3_q1": "1", "respondent_dem/marital_status": "married", "characteristic_three/ch3_q2": "0", "characteristic_three/ch3_q3": "0", "_uuid": "bd18e938-8cb7-4a99-aa6d-35b05ae942f1", "characteristic_three/ch3_q4": "1", "facility_info/interviewer": "Hwwk", "respondent_dem/highest_study": "Primary school", "formhub/uuid": "933bba82422444eda5c4d05d39f73684", "characteristic_one/ch1_q2": "1", "characteristic_one/ch1_q1": "1", "_submission_time": "2014-02-06T08:56:02", "_attachments": [], "facility_info/reporting_period": "2014-02-06", "facility_info/interview_date": "2014-02-06", "_id": 24651}', # noqa
]
adolescent_client_submissions_v2 = [
'{"characteristic_nine/ch9_invalid": "0", "subscriber_id": "no subscriberid property in enketo", "_tags": [], "characteristic_eight/ch8_score": "0", "characteristic_six/ch6_score": "1", "characteristic_thirteen/ch13_score": "2", "_xform_id_string": "adolescent_client_V3", "characteristic_thirteen/ch13_q1/ch13_q1e": "0", "characteristic_thirteen/ch13_q1/ch13_q1d": "1", "characteristic_fourteen/ch14_invalid": "1", "characteristic_thirteen/ch13_q1/ch13_q1a": "1", "characteristic_thirteen/ch13_q1/ch13_q1c": "0", "characteristic_thirteen/ch13_q1/ch13_q1b": "0", "characteristic_three/ch3_invalid": "0", "facility_info/facility_cnes": "0010731", "characteristic_ten/ch10_score": "4", "characteristic_fourteen/ch14_q2": "0", "start_time": "2015-03-13T14:25:49.000+03:00", "characteristic_three/ch3_q1": "pessoal_da_administracao", "characteristic_fourteen/ch14_q6": "0", "characteristic_seventeen/ch17_score": "NaN", "facility_info/state": "distrito_federal", "characteristic_seven/ch7_invalid": "0", "characteristic_twelve/ch12_invalid": "0", "resp_demographics/resp_sex": "male", "terminate_int9": "0", "terminate_int8": "0", "terminate_int7": "0", "_submission_time": "2015-03-13T12:06:57", "terminate_int5": "0", "terminate_int4": "0", "terminate_int3": "0", "terminate_int2": "0", "_geolocation": [null, null], "characteristic_eleven/ch11_q1": "1", "characteristic_eleven/ch11_q2": "00", "characteristic_eleven/ch11_q3": "1", "characteristic_sixteen/ch16_invalid": "0", "characteristic_nine/ch9_q2/ch9_q2b": "0", "characteristic_nine/ch9_q2/ch9_q2c": "1", "characteristic_nine/ch9_q2/ch9_q2a": "0", "total_invalid8": "2", "total_invalid9": "2", "facility_info/municipality": "brasilia", "total_invalid2": "0", "meta/instanceID": "uuid:42006843-79da-472e-ae83-eadb021119e5", "total_invalid4": "0", "total_invalid5": "1", "total_invalid6": "1", "total_invalid7": "1", "characteristic_five/ch5_q1": "1", "characteristic_nineteen/ch19_score": "1", "characteristic_six/ch6_q2": "Fliers", "characteristic_six/ch6_q1": "1", "characteristic_one/ch1_invalid": "0", "characteristic_twenty/ch20_q1": "1", "facility_info/HS_char": "one two three five six seven eight nine ten eleven twelve thirteen fourteen fifteen sixteen nineteen twenty", "end_time": "2015-03-13T15:06:56.000+03:00", "phone_number": "no phonenumber property in enketo", "characteristic_seven/ch7_score": "2", "characteristic_one/ch1_score": "1", "facility_info/reporting_period": "1may_31jul_2015", "_uuid": "42006843-79da-472e-ae83-eadb021119e5", "characteristic_eleven/ch11_score": "2", "characteristic_two/ch2_q1": "1", "_version": "201503121224", "characteristic_five/ch5_score": "1", "terminate_int6": "0", "resp_demographics/resp_in_school": "no", "_notes": [], "resp_demographics/resp_age": 18, "terminate_int": "0", "characteristic_fifteen/ch15_score": "0", "_bamboo_dataset_id": "", "characteristic_three/ch3_score": "1", "characteristic_fifteen/ch15_invalid": "0", "characteristic_five/ch5_invalid": "0", "terminate_int10": "0", "characteristic_ten/ch10_q2": "1", "characteristic_ten/ch10_q3": "1", "characteristic_ten/ch10_q1": "1", "characteristic_ten/ch10_q4": "1", "characteristic_nineteen/ch19_invalid": "0", "characteristic_twelve/ch12_score": "0", "_status": "submitted_via_web", "characteristic_nine/ch9_q1/ch9_q1c": "0", "characteristic_seven/ch7_q3": "1", "characteristic_seven/ch7_q2": "1", "characteristic_seven/ch7_q1": "0", "characteristic_twelve/ch12_q1": "0", "characteristic_twelve/ch12_q3": "0", "characteristic_twelve/ch12_q2": "0", "resp_demographics/resp_marital_status": "boyfriend_girlfriend", "characteristic_fifteen/ch15_q2": "0", "characteristic_fifteen/ch15_q1": "0", "characteristic_eight/ch8_invalid": "0", "characteristic_one/ch1_q2": "0", "characteristic_one/ch1_q1": "1", "characteristic_nineteen/ch19_q1": "1", "characteristic_nineteen/ch19_q2": "0", "characteristic_twenty/ch20_score": "1", "total_invalid": "0", "characteristic_six/ch6_invalid": "0", "characteristic_ten/ch10_invalid": "0", "characteristic_eight/ch8_q1": "0", "characteristic_sixteen/ch16_score": "1", "total_invalid3": "0", "characteristic_twenty/ch20_invalid": "0", "sim_serial": "no simserial property in enketo", "_duration": 2467.0, "characteristic_nine/ch9_score": "2", "total_invalid10": "2", "characteristic_fourteen/ch14_q1": "1", "characteristic_seventeen/ch17_invalid": "1", "characteristic_two/ch2_score": "1", "characteristic_two/ch2_invalid": "0", "characteristic_thirteen/ch13_invalid": "0", "characteristic_nine/ch9_q1/ch9_q1a": "1", "characteristic_nine/ch9_q1/ch9_q1b": "0", "formhub/uuid": "89f76ed6137d4d1f8986e6c1f2d30603", "characteristic_fourteen/ch14_score": "NaN", "_attachments": [], "characteristic_eleven/ch11_invalid": "0", "_submitted_by": null, "characteristic_sixteen/ch16_q1": "0", "device_id": "localhost:cOUuftC4kZnkSPZs", "characteristic_sixteen/ch16_q2": "1", "_id": 309, "facility_info/interviewer_name": "Geoffrey Muchai"}', # noqa
'{"characteristic_nine/ch9_invalid":"0","subscriber_id":"no subscriberid property in enketo","_tags":[],"characteristic_eight/ch8_score":"1","characteristic_six/ch6_score":"1","characteristic_thirteen/ch13_score":"5","_xform_id_string":"adolescent_client_V3","characteristic_thirteen/ch13_q1/ch13_q1e":"1","characteristic_thirteen/ch13_q1/ch13_q1d":"1","characteristic_fourteen/ch14_invalid":"0","characteristic_thirteen/ch13_q1/ch13_q1a":"1","characteristic_thirteen/ch13_q1/ch13_q1c":"1","characteristic_thirteen/ch13_q1/ch13_q1b":"1","characteristic_three/ch3_invalid":"0","facility_info/facility_cnes":"0010731","characteristic_ten/ch10_score":"0","characteristic_fourteen/ch14_q2":"1","characteristic_fourteen/ch14_q3":"1","start_time":"2015-03-13T15:08:58.000+03:00","characteristic_three/ch3_q1":"recepcionista","characteristic_seventeen/ch17_invalid":"1","characteristic_fourteen/ch14_q4":"1","characteristic_fourteen/ch14_q5":"1","characteristic_seventeen/ch17_score":"NaN","facility_info/state":"distrito_federal","characteristic_seven/ch7_invalid":"0","characteristic_twelve/ch12_invalid":"0","resp_demographics/resp_sex":"male","terminate_int9":"0","terminate_int8":"0","terminate_int7":"0","_submission_time":"2015-03-13T12:30:12","terminate_int5":"0","terminate_int4":"0","terminate_int3":"0","terminate_int2":"0","_geolocation":[null,null],"characteristic_eleven/ch11_q1":"1","characteristic_eleven/ch11_q2":"1","characteristic_eleven/ch11_q3":"1","characteristic_sixteen/ch16_invalid":"0","characteristic_nine/ch9_q2/ch9_q2b":"1","characteristic_nine/ch9_q2/ch9_q2c":"1","characteristic_nine/ch9_q2/ch9_q2a":"1","total_invalid8":"1","total_invalid9":"1","facility_info/municipality":"brasilia","total_invalid2":"0","meta/instanceID":"uuid:0736cff4-a0e7-4510-bb34-8d124776ea76","total_invalid4":"0","total_invalid5":"0","total_invalid6":"0","total_invalid7":"0","characteristic_five/ch5_q1":"1","characteristic_nineteen/ch19_score":"2","characteristic_six/ch6_q2":"TV","characteristic_six/ch6_q1":"1","characteristic_one/ch1_invalid":"0","facility_info/reporting_period":"1may_31jul_2015","facility_info/HS_char":"one two three five six seven eight nine ten eleven twelve thirteen fourteen fifteen sixteen nineteen twenty","end_time":"2015-03-13T15:30:12.000+03:00","phone_number":"no phonenumber property in enketo","characteristic_seven/ch7_score":"2","characteristic_one/ch1_score":"1","characteristic_twenty/ch20_q1":"1","_uuid":"0736cff4-a0e7-4510-bb34-8d124776ea76","characteristic_eleven/ch11_score":"3","characteristic_two/ch2_q1":"1","_version":"201503121224","characteristic_five/ch5_score":"1","terminate_int6":"0","resp_demographics/resp_in_school":"no","_notes":[],"resp_demographics/resp_age":16,"terminate_int":"0","characteristic_fifteen/ch15_score":"2","_bamboo_dataset_id":"","characteristic_three/ch3_score":"1","characteristic_fifteen/ch15_invalid":"0","characteristic_five/ch5_invalid":"0","terminate_int10":"0","characteristic_ten/ch10_q2":"0","characteristic_ten/ch10_q3":"0","characteristic_ten/ch10_q1":"0","characteristic_ten/ch10_q4":"0","characteristic_nineteen/ch19_invalid":"0","characteristic_twelve/ch12_score":"3","_status":"submitted_via_web","characteristic_nine/ch9_q1/ch9_q1c":"1","characteristic_seven/ch7_q3":"1","characteristic_seven/ch7_q2":"0","characteristic_seven/ch7_q1":"1","characteristic_twelve/ch12_q1":"1","characteristic_twelve/ch12_q3":"1","characteristic_twelve/ch12_q2":"1","resp_demographics/resp_marital_status":"single","characteristic_fifteen/ch15_q2":"1","characteristic_fifteen/ch15_q1":"1","characteristic_eight/ch8_invalid":"0","characteristic_one/ch1_q2":"0","characteristic_one/ch1_q1":"1","characteristic_nineteen/ch19_q1":"1","characteristic_nineteen/ch19_q2":"1","characteristic_twenty/ch20_score":"1","total_invalid":"0","characteristic_six/ch6_invalid":"0","characteristic_ten/ch10_invalid":"0","characteristic_eight/ch8_q1":"1","characteristic_sixteen/ch16_score":"2","total_invalid3":"0","characteristic_twenty/ch20_invalid":"0","sim_serial":"no simserial property in enketo","_duration":1274,"characteristic_nine/ch9_score":"6","total_invalid10":"1","characteristic_fourteen/ch14_q1":"1","characteristic_fourteen/ch14_q6":"1","characteristic_two/ch2_score":"1","characteristic_two/ch2_invalid":"0","characteristic_thirteen/ch13_invalid":"0","characteristic_nine/ch9_q1/ch9_q1a":"1","characteristic_nine/ch9_q1/ch9_q1b":"1","formhub/uuid":"89f76ed6137d4d1f8986e6c1f2d30603","characteristic_fourteen/ch14_score":"6","_attachments":[],"characteristic_eleven/ch11_invalid":"0","_submitted_by":null,"characteristic_sixteen/ch16_q1":"1","device_id":"localhost:cOUuftC4kZnkSPZs","characteristic_sixteen/ch16_q2":"1","_id":310,"facility_info/interviewer_name":"Geof"}', # noqa
'{"characteristic_nine/ch9_invalid":"0","subscriber_id":"no subscriberid property in enketo","_tags":[],"characteristic_eight/ch8_score":"0","characteristic_six/ch6_score":"0","characteristic_thirteen/ch13_score":"0","_xform_id_string":"adolescent_client_V3","characteristic_thirteen/ch13_q1/ch13_q1e":"0","characteristic_thirteen/ch13_q1/ch13_q1d":"0","characteristic_fourteen/ch14_invalid":"0","characteristic_thirteen/ch13_q1/ch13_q1a":"0","characteristic_thirteen/ch13_q1/ch13_q1c":"0","characteristic_thirteen/ch13_q1/ch13_q1b":"0","characteristic_three/ch3_invalid":"0","facility_info/facility_cnes":"0010731","characteristic_ten/ch10_score":"4","characteristic_fourteen/ch14_q2":"0","characteristic_fourteen/ch14_q3":"0","start_time":"2015-03-13T15:32:14.000+03:00","characteristic_three/ch3_q1":"pessoal_da_administracao","characteristic_seventeen/ch17_invalid":"1","characteristic_fourteen/ch14_q4":"0","characteristic_fourteen/ch14_q5":"0","characteristic_seventeen/ch17_score":"NaN","facility_info/state":"distrito_federal","characteristic_seven/ch7_invalid":"0","characteristic_twelve/ch12_invalid":"0","resp_demographics/resp_sex":"female","terminate_int9":"0","terminate_int8":"0","terminate_int7":"0","terminate_int6":"0","terminate_int5":"0","terminate_int4":"0","terminate_int3":"0","terminate_int2":"0","_geolocation":[null,null],"characteristic_eleven/ch11_q1":"0","characteristic_eleven/ch11_q2":"0","characteristic_eleven/ch11_q3":"0","characteristic_sixteen/ch16_invalid":"0","characteristic_nine/ch9_q2/ch9_q2b":"0","characteristic_nine/ch9_q2/ch9_q2c":"0","characteristic_nine/ch9_q2/ch9_q2a":"0","total_invalid8":"1","total_invalid9":"1","facility_info/municipality":"brasilia","total_invalid2":"0","meta/instanceID":"uuid:7f028d33-3ab0-4518-8f54-0e70abbd8adf","total_invalid4":"0","total_invalid5":"0","total_invalid6":"0","total_invalid7":"0","characteristic_five/ch5_q1":"0","characteristic_nineteen/ch19_score":"0","characteristic_six/ch6_q2":"bla bla bla","characteristic_six/ch6_q1":"0","characteristic_one/ch1_invalid":"0","facility_info/reporting_period":"1may_31jul_2015","facility_info/HS_char":"one two three five six seven eight nine ten eleven twelve thirteen fourteen fifteen sixteen nineteen twenty","end_time":"2015-03-13T15:40:29.000+03:00","phone_number":"no phonenumber property in enketo","characteristic_seven/ch7_score":"1","characteristic_one/ch1_score":"2","characteristic_twenty/ch20_q1":"0","_uuid":"7f028d33-3ab0-4518-8f54-0e70abbd8adf","characteristic_eleven/ch11_score":"0","characteristic_two/ch2_q1":"0","_version":"201503121224","characteristic_five/ch5_score":"0","resp_demographics/resp_in_school":"yes","_notes":[],"resp_demographics/resp_age":16,"terminate_int":"0","characteristic_fifteen/ch15_score":"0","_bamboo_dataset_id":"","characteristic_three/ch3_score":"1","characteristic_fifteen/ch15_invalid":"0","characteristic_five/ch5_invalid":"0","terminate_int10":"0","characteristic_ten/ch10_q2":"1","characteristic_ten/ch10_q3":"1","characteristic_ten/ch10_q1":"1","characteristic_ten/ch10_q4":"1","characteristic_nineteen/ch19_invalid":"0","characteristic_twelve/ch12_score":"0","_status":"submitted_via_web","characteristic_nine/ch9_q1/ch9_q1c":"0","characteristic_seven/ch7_q3":"0","characteristic_seven/ch7_q2":"1","characteristic_seven/ch7_q1":"0","characteristic_twelve/ch12_q1":"0","characteristic_twelve/ch12_q3":"0","characteristic_twelve/ch12_q2":"0","resp_demographics/resp_marital_status":"live_together","characteristic_fifteen/ch15_q2":"0","characteristic_fifteen/ch15_q1":"0","characteristic_eight/ch8_invalid":"0","characteristic_one/ch1_q2":"1","characteristic_one/ch1_q1":"1","characteristic_nineteen/ch19_q1":"0","characteristic_nineteen/ch19_q2":"0","characteristic_twenty/ch20_score":"0","total_invalid":"0","characteristic_six/ch6_invalid":"0","characteristic_ten/ch10_invalid":"0","characteristic_eight/ch8_q1":"0","characteristic_sixteen/ch16_score":"0","total_invalid3":"0","characteristic_twenty/ch20_invalid":"0","sim_serial":"no simserial property in enketo","_duration":495,"characteristic_nine/ch9_score":"0","total_invalid10":"1","characteristic_fourteen/ch14_q1":"0","characteristic_fourteen/ch14_q6":"0","characteristic_two/ch2_score":"0","characteristic_two/ch2_invalid":"0","resp_demographics/resp_in_school_yes":"ensino_superior","characteristic_thirteen/ch13_invalid":"0","characteristic_nine/ch9_q1/ch9_q1a":"0","characteristic_nine/ch9_q1/ch9_q1b":"0","formhub/uuid":"89f76ed6137d4d1f8986e6c1f2d30603","_submission_time":"2015-03-13T12:40:29","characteristic_fourteen/ch14_score":"0","_attachments":[],"characteristic_eleven/ch11_invalid":"0","_submitted_by":null,"characteristic_sixteen/ch16_q1":"0","device_id":"localhost:cOUuftC4kZnkSPZs","characteristic_sixteen/ch16_q2":"0","_id":311,"facility_info/interviewer_name":"Anita"}', # noqa
'{"characteristic_nine/ch9_invalid":"0","subscriber_id":"no subscriberid property in enketo","_tags":[],"characteristic_eight/ch8_score":"00","characteristic_six/ch6_score":"00","characteristic_thirteen/ch13_score":"0","_xform_id_string":"adolescent_client_V3","characteristic_thirteen/ch13_q1/ch13_q1e":"00","characteristic_thirteen/ch13_q1/ch13_q1d":"0","characteristic_fourteen/ch14_invalid":"0","characteristic_thirteen/ch13_q1/ch13_q1a":"00","characteristic_thirteen/ch13_q1/ch13_q1c":"00","characteristic_thirteen/ch13_q1/ch13_q1b":"00","characteristic_three/ch3_invalid":"0","facility_info/facility_cnes":"0010731","characteristic_ten/ch10_score":"NaN","characteristic_fourteen/ch14_q2":"00","characteristic_fourteen/ch14_q3":"00","start_time":"2015-03-16T15:36:16.000+03:00","characteristic_three/ch3_q1":"pessoal_da_administracao","characteristic_seventeen/ch17_invalid":"1","characteristic_fourteen/ch14_q4":"00","characteristic_fourteen/ch14_q5":"00","characteristic_seventeen/ch17_score":"NaN","facility_info/state":"distrito_federal","characteristic_seven/ch7_invalid":"0","characteristic_twelve/ch12_invalid":"0","resp_demographics/resp_sex":"male","terminate_int9":"0","terminate_int8":"0","terminate_int7":"0","_submission_time":"2015-03-16T13:23:47","terminate_int5":"0","terminate_int4":"0","terminate_int3":"0","terminate_int2":"0","_geolocation":[null,null],"characteristic_eleven/ch11_q1":"00","characteristic_eleven/ch11_q2":"00","characteristic_eleven/ch11_q3":"00","characteristic_sixteen/ch16_invalid":"0","characteristic_nine/ch9_q2/ch9_q2b":"00","characteristic_nine/ch9_q2/ch9_q2c":"00","characteristic_nine/ch9_q2/ch9_q2a":"00","total_invalid8":"2","total_invalid9":"2","facility_info/municipality":"brasilia","total_invalid2":"1","meta/instanceID":"uuid:f1f1256d-a12d-4cca-9bd3-f3e32ced5f5f","total_invalid4":"1","total_invalid5":"1","total_invalid6":"1","total_invalid7":"1","characteristic_five/ch5_q1":"00","characteristic_nineteen/ch19_score":"0","characteristic_six/ch6_q2":"DUNNO","characteristic_six/ch6_q1":"00","characteristic_one/ch1_invalid":"0","facility_info/reporting_period":"1aug_31oct_2015","facility_info/HS_char":"one two three five six seven eight nine ten eleven twelve thirteen fourteen fifteen sixteen nineteen twenty","end_time":"2015-03-16T16:23:46.000+03:00","phone_number":"no phonenumber property in enketo","characteristic_seven/ch7_score":"0","characteristic_one/ch1_score":"0","characteristic_twenty/ch20_q1":"00","_uuid":"f1f1256d-a12d-4cca-9bd3-f3e32ced5f5f","characteristic_eleven/ch11_score":"0","characteristic_two/ch2_q1":"00","_version":"201503121224","characteristic_five/ch5_score":"00","terminate_int6":"0","resp_demographics/resp_in_school":"no","_notes":[],"resp_demographics/resp_age":17,"terminate_int":"0","characteristic_fifteen/ch15_score":"0","_bamboo_dataset_id":"","characteristic_three/ch3_score":"1","characteristic_fifteen/ch15_invalid":"0","characteristic_five/ch5_invalid":"0","terminate_int10":"0","characteristic_ten/ch10_q2":"00","characteristic_ten/ch10_q3":"na","characteristic_ten/ch10_q1":"00","characteristic_ten/ch10_q4":"00","characteristic_nineteen/ch19_invalid":"0","characteristic_twelve/ch12_score":"0","_status":"submitted_via_web","characteristic_nine/ch9_q1/ch9_q1c":"00","characteristic_seven/ch7_q3":"00","characteristic_seven/ch7_q2":"00","characteristic_seven/ch7_q1":"00","characteristic_twelve/ch12_q1":"00","characteristic_twelve/ch12_q3":"00","characteristic_twelve/ch12_q2":"00","resp_demographics/resp_marital_status":"single","characteristic_fifteen/ch15_q2":"00","characteristic_fifteen/ch15_q1":"00","characteristic_eight/ch8_invalid":"0","characteristic_one/ch1_q2":"00","characteristic_one/ch1_q1":"00","characteristic_nineteen/ch19_q1":"00","characteristic_nineteen/ch19_q2":"00","characteristic_twenty/ch20_score":"00","total_invalid":"1","characteristic_six/ch6_invalid":"0","characteristic_ten/ch10_invalid":"1","characteristic_eight/ch8_q1":"00","characteristic_sixteen/ch16_score":"0","total_invalid3":"1","characteristic_twenty/ch20_invalid":"0","sim_serial":"no simserial property in enketo","_duration":2850,"characteristic_nine/ch9_score":"0","total_invalid10":"2","characteristic_fourteen/ch14_q1":"00","characteristic_fourteen/ch14_q6":"00","characteristic_two/ch2_score":"00","characteristic_two/ch2_invalid":"0","characteristic_thirteen/ch13_invalid":"0","characteristic_nine/ch9_q1/ch9_q1a":"00","characteristic_nine/ch9_q1/ch9_q1b":"00","formhub/uuid":"89f76ed6137d4d1f8986e6c1f2d30603","characteristic_fourteen/ch14_score":"0","_attachments":[],"characteristic_eleven/ch11_invalid":"0","_submitted_by":null,"characteristic_sixteen/ch16_q1":"00","device_id":"localhost:cOUuftC4kZnkSPZs","characteristic_sixteen/ch16_q2":"00","_id":312,"facility_info/interviewer_name":"Okal"}' # noqa
]
adolescent_client_submissions_v3 = [
'{"characteristic_nine/ch9_invalid": "0", "subscriber_id": "639029670254615", "characteristic_thirteen/ch13_q1e": "00", "_tags": [], "characteristic_eight/ch8_score": "00", "characteristic_six/ch6_score": "1", "characteristic_thirteen/ch13_score": "2", "_xform_id_string": "adolescent_client_V3", "characteristic_fourteen/ch14_invalid": "0", "characteristic_three/ch3_invalid": "0", "facility_info/facility_cnes": "6890", "characteristic_ten/ch10_score": "2", "characteristic_nine/ch9_q2a": "0", "characteristic_nine/ch9_q2b": "00", "characteristic_nine/ch9_q2c": "0", "characteristic_fourteen/ch14_q2": "1", "characteristic_fourteen/ch14_q3": "1", "start_time": "2017-06-02T14:56:43.954+03", "characteristic_fourteen/ch14_q1": "0", "characteristic_fourteen/ch14_q6": "1", "characteristic_fourteen/ch14_q4": "0", "characteristic_fourteen/ch14_q5": "1", "characteristic_seventeen/ch17_score": "4", "facility_info/state": "Bahia", "characteristic_seven/ch7_invalid": "1", "characteristic_twelve/ch12_invalid": "0", "resp_demographics/resp_sex": "1", "terminate_int9": "0", "terminate_int8": "0", "terminate_int7": "0", "terminate_int6": "0", "terminate_int5": "0", "terminate_int4": "0", "terminate_int3": "0", "terminate_int2": "0", "_geolocation": [null, null], "characteristic_eleven/ch11_q1": "1", "characteristic_eleven/ch11_q2": "1", "characteristic_eleven/ch11_q3": "0", "characteristic_sixteen/ch16_invalid": "1", "characteristic_three/ch3_q1d": "1", "characteristic_three/ch3_q1a": "1", "characteristic_three/ch3_q1b": "0", "characteristic_three/ch3_q1c": "0", "total_invalid8": "2", "total_invalid9": "2", "characteristic_thirteen/ch13_q1a": "1", "characteristic_thirteen/ch13_q1b": "1", "characteristic_thirteen/ch13_q1c": "0", "total_invalid2": "1", "total_invalid3": "1", "total_invalid4": "1", "total_invalid5": "1", "_duration": 124.0, "total_invalid7": "2", "characteristic_five/ch5_q1": "1", "characteristic_nineteen/ch19_score": "1", "characteristic_six/ch6_q1": "1", "characteristic_one/ch1_invalid": "0", "_edited": false, "facility_info/HS_char": "one two three five six seven eight nine ten eleven twelve thirteen fourteen fifteen sixteen seventeen nineteen twenty", "end_time": "2017-06-02T14:58:47.963+03", "characteristic_one/ch1_score": "0", "characteristic_twenty/ch20_q1": "1", "_uuid": "ecb5bf19-22d8-4c06-a61b-85f5cab1e204", "characteristic_eleven/ch11_score": "2", "characteristic_two/ch2_q1": "0", "_version": "201706021154", "characteristic_nine/ch9_q1a": "0", "characteristic_nine/ch9_q1c": "0", "characteristic_nine/ch9_q1b": "1", "resp_demographics/resp_in_school": "1", "_notes": [], "resp_demographics/resp_age": 14, "characteristic_two/ch2_invalid": "0", "characteristic_fifteen/ch15_score": "1", "_bamboo_dataset_id": "", "characteristic_three/ch3_score": "2", "characteristic_fifteen/ch15_invalid": "0", "characteristic_five/ch5_invalid": "0", "terminate_int11": "0", "terminate_int10": "0", "characteristic_thirteen/ch13_invalid": "0", "characteristic_ten/ch10_q2": "1", "characteristic_ten/ch10_q3": "1", "resp_demographics/resp_marital_status": "2", "characteristic_ten/ch10_q1": "00", "characteristic_ten/ch10_q4": "0", "characteristic_nineteen/ch19_invalid": "0", "characteristic_twelve/ch12_score": "2", "_status": "submitted_via_web", "formhub/uuid": "6873e43e8709420a84a44efdaab35682", "characteristic_seven/ch7_q3": "nr", "characteristic_seven/ch7_q2": "nr", "characteristic_seven/ch7_q1": "na", "characteristic_twelve/ch12_q1": "1", "characteristic_seventeen/ch17_q2": "0", "characteristic_twelve/ch12_q3": "0", "characteristic_twelve/ch12_q2": "1", "characteristic_seventeen/ch17_q6": "1", "characteristic_seventeen/ch17_q5": "1", "characteristic_seventeen/ch17_q4": "1", "_submission_time": "2017-06-02T11:58:56", "_submitted_by": "kipsigei", "characteristic_fifteen/ch15_q2": "00", "characteristic_fifteen/ch15_q1": "1", "characteristic_eight/ch8_invalid": "0", "characteristic_thirteen/ch13_q1d": "00", "characteristic_one/ch1_q2": "0", "characteristic_one/ch1_q1": "0", "characteristic_nineteen/ch19_q1": "0", "characteristic_nineteen/ch19_q2": "1", "characteristic_twenty/ch20_score": "1", "total_invalid": "1", "characteristic_seventeen/ch17_q3": "1", "characteristic_six/ch6_invalid": "0", "characteristic_seventeen/ch17_q1": "0", "characteristic_ten/ch10_invalid": "0", "characteristic_eight/ch8_q1": "00", "facility_info/reporting_period": "2017", "meta/instanceID": "uuid:ecb5bf19-22d8-4c06-a61b-85f5cab1e204", "characteristic_twenty/ch20_invalid": "0", "characteristic_eleven/ch11_invalid": "0", "sim_serial": "89254029671002546150", "characteristic_five/ch5_score": "1", "total_invalid6": "1", "characteristic_nine/ch9_score": "1", "total_invalid10": "2", "total_invalid11": "1", "facility_info/municipality": "Salvador", "characteristic_seventeen/ch17_invalid": "0", "characteristic_two/ch2_score": "0", "terminate_int": "0", "facility_info/facility_name": "USF de Barreiras", "device_id": "861102034048530", "resp_demographics/resp_race": "1", "characteristic_fourteen/ch14_score": "4", "_attachments": [], "characteristic_sixteen/ch16_q5": "00", "characteristic_sixteen/ch16_q4": "0", "characteristic_sixteen/ch16_q6": "nr", "characteristic_sixteen/ch16_q1": "1", "characteristic_sixteen/ch16_q3": "0", "characteristic_sixteen/ch16_q2": "0", "_id": 16358146, "facility_info/interviewer_name": "Kip"}', # noqa
'{"characteristic_nine/ch9_invalid": "1", "subscriber_id": "639029670254615", "characteristic_thirteen/ch13_q1e": "1", "_tags": [], "characteristic_eight/ch8_score": "0", "characteristic_six/ch6_score": "1", "characteristic_thirteen/ch13_score": "3", "_xform_id_string": "adolescent_client_V3", "characteristic_fourteen/ch14_invalid": "0", "characteristic_three/ch3_invalid": "0", "facility_info/facility_cnes": "6890", "characteristic_five/ch5_invalid": "0", "characteristic_nine/ch9_q2a": "1", "characteristic_nine/ch9_q2b": "0", "characteristic_nine/ch9_q2c": "nr", "characteristic_fourteen/ch14_q2": "1", "characteristic_fourteen/ch14_q3": "0", "start_time": "2017-06-02T15:58:23.858+03", "characteristic_fourteen/ch14_q1": "0", "characteristic_fourteen/ch14_q6": "00", "characteristic_fourteen/ch14_q4": "1", "characteristic_fourteen/ch14_q5": "0", "characteristic_seventeen/ch17_score": "3", "facility_info/state": "Sao Paulo", "characteristic_seven/ch7_invalid": "0", "characteristic_twelve/ch12_invalid": "0", "resp_demographics/resp_sex": "1", "terminate_int9": "0", "terminate_int8": "0", "terminate_int7": "0", "terminate_int6": "0", "terminate_int5": "0", "terminate_int4": "0", "terminate_int3": "0", "terminate_int2": "0", "_geolocation": [null, null], "characteristic_eleven/ch11_q1": "1", "characteristic_eleven/ch11_q2": "0", "characteristic_eleven/ch11_q3": "1", "characteristic_sixteen/ch16_invalid": "0", "characteristic_three/ch3_q1d": "0", "characteristic_three/ch3_q1a": "1", "characteristic_three/ch3_q1b": "0", "characteristic_three/ch3_q1c": "00", "total_invalid8": "2", "total_invalid9": "3", "characteristic_thirteen/ch13_q1a": "1", "characteristic_thirteen/ch13_q1b": "0", "characteristic_thirteen/ch13_q1c": "00", "total_invalid2": "2", "total_invalid3": "2", "total_invalid4": "2", "total_invalid5": "2", "_duration": 181.0, "total_invalid7": "2", "characteristic_five/ch5_q1": "1", "characteristic_six/ch6_q1": "1", "characteristic_one/ch1_invalid": "0", "_edited": false, "facility_info/HS_char": "one two three five six seven eight nine ten eleven twelve thirteen fourteen fifteen sixteen seventeen nineteen twenty", "end_time": "2017-06-02T16:01:24.448+03", "characteristic_seven/ch7_score": "2", "characteristic_one/ch1_score": "1", "characteristic_twenty/ch20_q1": "0", "_uuid": "51e4e1d6-fe37-4bb0-a25e-ee34ebd38d29", "characteristic_eleven/ch11_score": "2", "characteristic_two/ch2_q1": "1", "_version": "201706021154", "characteristic_nine/ch9_q1a": "00", "characteristic_nine/ch9_q1c": "1", "characteristic_nine/ch9_q1b": "1", "resp_demographics/resp_in_school": "1", "_notes": [], "resp_demographics/resp_age": 16, "characteristic_two/ch2_invalid": "0", "characteristic_fifteen/ch15_score": "1", "_bamboo_dataset_id": "", "characteristic_three/ch3_score": "1", "characteristic_fifteen/ch15_invalid": "0", "terminate_int11": "0", "terminate_int10": "0", "characteristic_thirteen/ch13_invalid": "0", "characteristic_ten/ch10_q2": "nr", "characteristic_ten/ch10_q3": "0", "resp_demographics/resp_marital_status": "5", "characteristic_ten/ch10_q1": "0", "characteristic_ten/ch10_q4": "1", "characteristic_nineteen/ch19_invalid": "1", "characteristic_twelve/ch12_score": "1", "_status": "submitted_via_web", "formhub/uuid": "6873e43e8709420a84a44efdaab35682", "characteristic_seven/ch7_q3": "00", "characteristic_seven/ch7_q2": "1", "characteristic_seven/ch7_q1": "1", "characteristic_twelve/ch12_q1": "00", "characteristic_seventeen/ch17_q2": "1", "characteristic_twelve/ch12_q3": "0", "characteristic_twelve/ch12_q2": "1", "characteristic_seventeen/ch17_q6": "00", "characteristic_seventeen/ch17_q5": "0", "characteristic_seventeen/ch17_q4": "1", "_submission_time": "2017-06-02T13:01:44", "_submitted_by": "kipsigei", "characteristic_fifteen/ch15_q2": "1", "characteristic_fifteen/ch15_q1": "0", "characteristic_eight/ch8_invalid": "0", "characteristic_thirteen/ch13_q1d": "1", "characteristic_one/ch1_q2": "1", "characteristic_one/ch1_q1": "0", "characteristic_nineteen/ch19_q1": "nr", "characteristic_nineteen/ch19_q2": "na", "characteristic_twenty/ch20_score": "0", "total_invalid": "2", "characteristic_seventeen/ch17_q3": "1", "characteristic_six/ch6_invalid": "0", "characteristic_seventeen/ch17_q1": "00", "characteristic_ten/ch10_invalid": "1", "characteristic_eight/ch8_q1": "0", "facility_info/reporting_period": "2017", "characteristic_sixteen/ch16_score": "3", "meta/instanceID": "uuid:51e4e1d6-fe37-4bb0-a25e-ee34ebd38d29", "characteristic_twenty/ch20_invalid": "0", "characteristic_eleven/ch11_invalid": "0", "sim_serial": "89254029671002546150", "characteristic_five/ch5_score": "1", "total_invalid6": "2", "total_invalid10": "3", "total_invalid11": "1", "facility_info/municipality": "Sao Paulo", "characteristic_seventeen/ch17_invalid": "0", "characteristic_two/ch2_score": "1", "terminate_int": "0", "facility_info/facility_name": "UBS Fazenda da Juta I", "device_id": "861102034048530", "resp_demographics/resp_race": "3", "characteristic_fourteen/ch14_score": "2", "_attachments": [], "characteristic_sixteen/ch16_q5": "1", "characteristic_sixteen/ch16_q4": "0", "characteristic_sixteen/ch16_q6": "0", "characteristic_sixteen/ch16_q1": "1", "characteristic_sixteen/ch16_q3": "1", "characteristic_sixteen/ch16_q2": "00", "_id": 16360234, "facility_info/interviewer_name": "Roy"}', # noqa
'{"characteristic_nine/ch9_invalid": "1", "subscriber_id": "639029670254615", "characteristic_thirteen/ch13_q1e": "1", "_tags": [], "characteristic_six/ch6_score": "00", "characteristic_thirteen/ch13_score": "4", "_xform_id_string": "adolescent_client_V3", "characteristic_fourteen/ch14_invalid": "0", "characteristic_three/ch3_invalid": "0", "facility_info/facility_cnes": "6890", "characteristic_five/ch5_invalid": "0", "characteristic_nine/ch9_q2a": "0", "characteristic_nine/ch9_q2b": "0", "characteristic_nine/ch9_q2c": "1", "characteristic_fourteen/ch14_q2": "0", "characteristic_fourteen/ch14_q3": "00", "start_time": "2017-06-02T15:55:42.070+03", "characteristic_fourteen/ch14_q1": "1", "characteristic_fourteen/ch14_q6": "1", "characteristic_fourteen/ch14_q4": "0", "characteristic_fourteen/ch14_q5": "1", "characteristic_seventeen/ch17_score": "4", "facility_info/state": "Parana", "characteristic_seven/ch7_invalid": "1", "characteristic_twelve/ch12_invalid": "0", "resp_demographics/resp_sex": "0", "terminate_int9": "0", "terminate_int8": "0", "terminate_int7": "0", "terminate_int6": "0", "terminate_int5": "0", "terminate_int4": "0", "terminate_int3": "0", "terminate_int2": "0", "_geolocation": [null, null], "characteristic_eleven/ch11_q1": "0", "characteristic_eleven/ch11_q2": "1", "characteristic_eleven/ch11_q3": "0", "characteristic_sixteen/ch16_invalid": "0", "characteristic_three/ch3_q1d": "0", "characteristic_three/ch3_q1a": "1", "characteristic_three/ch3_q1b": "00", "characteristic_three/ch3_q1c": "1", "total_invalid8": "5", "total_invalid9": "6", "characteristic_thirteen/ch13_q1a": "1", "characteristic_thirteen/ch13_q1b": "1", "characteristic_thirteen/ch13_q1c": "0", "total_invalid2": "4", "total_invalid3": "4", "total_invalid4": "4", "total_invalid5": "4", "_duration": 156.0, "total_invalid7": "5", "characteristic_five/ch5_q1": "1", "characteristic_six/ch6_q1": "00", "characteristic_one/ch1_invalid": "0", "_edited": false, "facility_info/HS_char": "one two three five six seven eight nine ten eleven twelve thirteen fourteen fifteen sixteen seventeen nineteen twenty", "end_time": "2017-06-02T15:58:18.233+03", "characteristic_one/ch1_score": "1", "characteristic_twenty/ch20_q1": "1", "_uuid": "cd525b30-5db2-46ea-9bfc-b60f352387a8", "characteristic_eleven/ch11_score": "1", "characteristic_two/ch2_q1": "1", "_version": "201706021154", "characteristic_nine/ch9_q1a": "1", "characteristic_nine/ch9_q1c": "nr", "characteristic_nine/ch9_q1b": "0", "resp_demographics/resp_in_school": "0", "_notes": [], "resp_demographics/resp_age": 15, "characteristic_two/ch2_invalid": "0", "_bamboo_dataset_id": "", "characteristic_three/ch3_score": "2", "characteristic_fifteen/ch15_invalid": "1", "terminate_int11": "0", "terminate_int10": "0", "characteristic_thirteen/ch13_invalid": "0", "characteristic_ten/ch10_q2": "na", "characteristic_ten/ch10_q3": "0", "resp_demographics/resp_marital_status": "1", "characteristic_ten/ch10_q1": "nr", "characteristic_ten/ch10_q4": "0", "characteristic_nineteen/ch19_invalid": "1", "characteristic_twelve/ch12_score": "2", "_status": "submitted_via_web", "formhub/uuid": "6873e43e8709420a84a44efdaab35682", "characteristic_seven/ch7_q3": "1", "characteristic_seven/ch7_q2": "0", "characteristic_seven/ch7_q1": "nr", "characteristic_twelve/ch12_q1": "1", "characteristic_seventeen/ch17_q2": "1", "characteristic_twelve/ch12_q3": "0", "characteristic_twelve/ch12_q2": "1", "characteristic_seventeen/ch17_q6": "1", "characteristic_seventeen/ch17_q5": "0", "characteristic_seventeen/ch17_q4": "1", "_submission_time": "2017-06-02T13:01:42", "_submitted_by": "kipsigei", "characteristic_fifteen/ch15_q2": "nr", "characteristic_fifteen/ch15_q1": "0", "characteristic_eight/ch8_invalid": "1", "characteristic_thirteen/ch13_q1d": "1", "characteristic_one/ch1_q2": "1", "characteristic_one/ch1_q1": "0", "characteristic_nineteen/ch19_q1": "nr", "characteristic_nineteen/ch19_q2": "1", "characteristic_twenty/ch20_score": "1", "total_invalid": "4", "characteristic_seventeen/ch17_q3": "0", "characteristic_six/ch6_invalid": "0", "characteristic_seventeen/ch17_q1": "1", "characteristic_ten/ch10_invalid": "1", "characteristic_eight/ch8_q1": "nr", "facility_info/reporting_period": "2017", "characteristic_sixteen/ch16_score": "3", "meta/instanceID": "uuid:cd525b30-5db2-46ea-9bfc-b60f352387a8", "characteristic_twenty/ch20_invalid": "0", "characteristic_eleven/ch11_invalid": "0", "sim_serial": "89254029671002546150", "characteristic_five/ch5_score": "1", "total_invalid6": "5", "total_invalid10": "6", "total_invalid11": "3", "facility_info/municipality": "Curitiba", "characteristic_seventeen/ch17_invalid": "0", "characteristic_two/ch2_score": "1", "terminate_int": "0", "facility_info/facility_name": "UMS Sao Braz", "device_id": "861102034048530", "resp_demographics/resp_race": "0", "characteristic_fourteen/ch14_score": "3", "_attachments": [], "characteristic_sixteen/ch16_q5": "00", "characteristic_sixteen/ch16_q4": "00", "characteristic_sixteen/ch16_q6": "1", "characteristic_sixteen/ch16_q1": "0", "characteristic_sixteen/ch16_q3": "1", "characteristic_sixteen/ch16_q2": "1", "_id": 16360233, "facility_info/interviewer_name": "Njagi"}', # noqa
'{"characteristic_nine/ch9_invalid": "0", "subscriber_id": "639029670254615", "characteristic_thirteen/ch13_q1e": "1", "_tags": [], "characteristic_eight/ch8_score": "1", "characteristic_thirteen/ch13_score": "3", "_xform_id_string": "adolescent_client_V3", "characteristic_fourteen/ch14_invalid": "1", "characteristic_three/ch3_invalid": "0", "facility_info/facility_cnes": "6890", "characteristic_ten/ch10_score": "1", "characteristic_nine/ch9_q2a": "0", "characteristic_nine/ch9_q2b": "1", "characteristic_nine/ch9_q2c": "0", "characteristic_fourteen/ch14_q2": "1", "characteristic_fourteen/ch14_q3": "nr", "start_time": "2017-06-02T15:52:37.942+03", "characteristic_fourteen/ch14_q1": "00", "characteristic_fourteen/ch14_q6": "00", "characteristic_fourteen/ch14_q4": "1", "characteristic_fourteen/ch14_q5": "na", "facility_info/state": "Distrito Federal", "characteristic_seven/ch7_invalid": "0", "characteristic_twelve/ch12_invalid": "0", "resp_demographics/resp_sex": "0", "terminate_int9": "0", "terminate_int8": "0", "terminate_int7": "0", "terminate_int6": "0", "terminate_int5": "0", "terminate_int4": "0", "terminate_int3": "0", "terminate_int2": "0", "_geolocation": [null, null], "characteristic_eleven/ch11_q1": "1", "characteristic_eleven/ch11_q2": "0", "characteristic_eleven/ch11_q3": "1", "characteristic_sixteen/ch16_invalid": "1", "characteristic_three/ch3_q1d": "1", "characteristic_three/ch3_q1a": "1", "characteristic_three/ch3_q1b": "1", "characteristic_three/ch3_q1c": "0", "total_invalid8": "5", "total_invalid9": "5", "characteristic_thirteen/ch13_q1a": "1", "characteristic_thirteen/ch13_q1b": "1", "characteristic_thirteen/ch13_q1c": "00", "total_invalid2": "1", "total_invalid3": "1", "total_invalid4": "1", "total_invalid5": "2", "_duration": 177.0, "total_invalid7": "4", "characteristic_five/ch5_q1": "0", "characteristic_nineteen/ch19_score": "1", "characteristic_six/ch6_q1": "nr", "characteristic_one/ch1_invalid": "0", "_edited": false, "facility_info/HS_char": "one two three five six seven eight nine ten eleven twelve thirteen fourteen fifteen sixteen seventeen nineteen twenty", "end_time": "2017-06-02T15:55:34.655+03", "characteristic_seven/ch7_score": "1", "characteristic_one/ch1_score": "1", "characteristic_twenty/ch20_q1": "1", "_uuid": "0500aed9-82b9-4aaf-86e3-d0f7a8590224", "characteristic_eleven/ch11_score": "2", "characteristic_two/ch2_q1": "0", "_version": "201706021154", "characteristic_nine/ch9_q1a": "0", "characteristic_nine/ch9_q1c": "1", "characteristic_nine/ch9_q1b": "1", "resp_demographics/resp_in_school": "1", "_notes": [], "resp_demographics/resp_age": 18, "characteristic_two/ch2_invalid": "0", "_bamboo_dataset_id": "", "characteristic_three/ch3_score": "3", "characteristic_fifteen/ch15_invalid": "1", "characteristic_five/ch5_invalid": "0", "terminate_int11": "0", "terminate_int10": "0", "characteristic_thirteen/ch13_invalid": "0", "characteristic_ten/ch10_q2": "0", "characteristic_ten/ch10_q3": "1", "resp_demographics/resp_marital_status": "0", "characteristic_ten/ch10_q1": "00", "characteristic_ten/ch10_q4": "0", "characteristic_nineteen/ch19_invalid": "0", "characteristic_twelve/ch12_score": "2", "_status": "submitted_via_web", "formhub/uuid": "6873e43e8709420a84a44efdaab35682", "characteristic_seven/ch7_q3": "0", "characteristic_seven/ch7_q2": "0", "characteristic_seven/ch7_q1": "1", "characteristic_twelve/ch12_q1": "1", "characteristic_seventeen/ch17_q2": "1", "characteristic_twelve/ch12_q3": "0", "characteristic_twelve/ch12_q2": "1", "characteristic_seventeen/ch17_q6": "0", "characteristic_seventeen/ch17_q5": "1", "characteristic_seventeen/ch17_q4": "1", "_submission_time": "2017-06-02T13:01:41", "_submitted_by": "kipsigei", "characteristic_fifteen/ch15_q2": "na", "characteristic_fifteen/ch15_q1": "00", "characteristic_eight/ch8_invalid": "0", "characteristic_thirteen/ch13_q1d": "0", "characteristic_one/ch1_q2": "1", "characteristic_one/ch1_q1": "0", "characteristic_nineteen/ch19_q1": "1", "characteristic_nineteen/ch19_q2": "0", "characteristic_twenty/ch20_score": "1", "total_invalid": "1", "characteristic_seventeen/ch17_q3": "0", "characteristic_six/ch6_invalid": "1", "characteristic_seventeen/ch17_q1": "nr", "characteristic_ten/ch10_invalid": "0", "characteristic_eight/ch8_q1": "1", "facility_info/reporting_period": "2016", "meta/instanceID": "uuid:0500aed9-82b9-4aaf-86e3-d0f7a8590224", "characteristic_twenty/ch20_invalid": "0", "characteristic_eleven/ch11_invalid": "0", "sim_serial": "89254029671002546150", "characteristic_five/ch5_score": "0", "total_invalid6": "3", "characteristic_nine/ch9_score": "3", "total_invalid10": "5", "total_invalid11": "1", "facility_info/municipality": "Distrito Federal", "characteristic_seventeen/ch17_invalid": "1", "characteristic_two/ch2_score": "0", "terminate_int": "0", "facility_info/facility_name": "Unidade Basica de Saude N.01 - Itapoa", "device_id": "861102034048530", "resp_demographics/resp_race": "3", "_attachments": [], "characteristic_sixteen/ch16_q5": "1", "characteristic_sixteen/ch16_q4": "nr", "characteristic_sixteen/ch16_q6": "1", "characteristic_sixteen/ch16_q1": "1", "characteristic_sixteen/ch16_q3": "1", "characteristic_sixteen/ch16_q2": "1", "_id": 16360232, "facility_info/interviewer_name": "Geoff"}', # noqa
]
def setUp(self):
registry = Registry()
registry.settings = settings
self.config = testing.setUp(registry=registry)
# setup db
# DBSession.configure(bind=engine)
Base.metadata.bind = engine
# TODO: run migrations instead of create_all to test migrations
Base.metadata.drop_all()
Base.metadata.create_all()
def tearDown(self):
DBSession.remove()
testing.tearDown()
def _create_user(self, username, group='user'):
user_group = Group(name=group)
user = User()
user.group = user_group
ona_user = OnaUser(username=username,
user=user,
refresh_token="1239khyackas")
with transaction.manager:
DBSession.add(ona_user)
def _create_dash_user(self, username, password, email, group='user'):
user_group = Group(name=group)
user = User()
user.group = user_group
dash_user = UserProfile(user=user,
username=username,
password=password,
email=email)
with transaction.manager:
DBSession.add(dash_user)
def _create_municipality(self, name="Test Municipality"):
municipality = Municipality(name=name)
with transaction.manager:
DBSession.add(municipality)
def _create_state(self, name="Test State"):
state = State(name=name)
with transaction.manager:
DBSession.add(state)
def setup_test_data(self):
su_group = Group(name=groups.SUPER_USER)
clinic_managers_group = Group(name=groups.CLINIC_MANAGER)
municipality_manager_group = Group(name=groups.MUNICIPALITY_MANAGER)
municipality = Municipality(name="Test Municipality")
su = User()
user_setting = UserSettings(user=su)
su_ona_user = OnaUser(
user=su, username='super', refresh_token="a123f4")
su.group = su_group
manager_a = User(location=municipality)
manager_a_ona_user = OnaUser(
user=manager_a, username='manager_a', refresh_token="b345d6")
manager_a.group = municipality_manager_group
manager_b = User(location=municipality)
manager_b_ona_user = OnaUser(
user=manager_b, username='manager_b', refresh_token="c563e9")
manager_b.group = clinic_managers_group
none_role = User(location=municipality)
none_role_ona_user = OnaUser(
user=none_role, username='none_role', refresh_token="d789f0")
none_role.group = None
# add a couple of clinics
clinic1 = Clinic(id=1,
name="Clinic A",
code="1A2B",
municipality=municipality)
# assign a su to clinic1
manager_a.clinics.append(clinic1)
clinic2 = Clinic(id=2,
name="Clinic B",
code="3E4G",
municipality=municipality)
clinic3 = Clinic(id=3,
name="Health Centre 09",
code="0010731",
municipality=municipality)
clinic4 = Clinic(id=4,
name="Clinic X",
code="6890",
municipality=municipality)
reporting_period_v2_1 = ReportingPeriod(
title='Default Period',
form_xpath='1jan_31mar_2015',
start_date=datetime.datetime(2015, 1, 1),
end_date=datetime.datetime(2015, 3, 31))
reporting_period_v2_2 = ReportingPeriod(
title='Period 1',
form_xpath='1may_31jul_2015',
start_date=datetime.datetime(2015, 5, 1),
end_date=datetime.datetime(2015, 7, 31))
reporting_period_v3 = ReportingPeriod(
title='Period 2017',
form_xpath='2017',
start_date=datetime.datetime(2017, 1, 1),
end_date=datetime.datetime(2017, 12, 31))
with transaction.manager:
DBSession.add_all(
[user_setting, su_ona_user, manager_a_ona_user,
manager_b_ona_user, none_role_ona_user,
municipality, clinic1, clinic2,
clinic3, clinic4, reporting_period_v2_1,
reporting_period_v2_2, reporting_period_v3])
def create_submissions(self):
# make submissions
for i in range(5):
Submission.create_from_json(self.submissions[i])
transaction.commit()
def create_brazil_submissions(self):
# make submissions
for i in range(3):
Submission.create_from_json(self.brazil_submissions[i])
transaction.commit()
def create_adolescent_client_submissions_v2(self):
# make submissions
for i in range(len(self.adolescent_client_submissions_v2)):
Submission.create_from_json(
self.adolescent_client_submissions_v2[i])
transaction.commit()
def create_adolescent_client_submissions_v3(self):
for i in range(len(self.adolescent_client_submissions_v3)):
Submission.create_from_json(
self.adolescent_client_submissions_v3[i])
transaction.commit()
class IntegrationTestBase(TestBase):
def setUp(self):
super(IntegrationTestBase, self).setUp()
pwd_context.load_path('test.ini')
# configure enketo
enketo.configure(settings['enketo_url'], settings['enketo_api_token'])
self.config.include('whoahqa')
class FunctionalTestBase(IntegrationTestBase):
def _login_user(self, ona_username):
user = OnaUser.get(OnaUser.username == ona_username).user
policy = self.testapp.app.registry.queryUtility(IAuthenticationPolicy)
headers = policy.remember(self.request, user.id)
cookie_parts = dict(headers)['Set-Cookie'].split('; ')
cookie = filter(
lambda i: i.split('=')[0] == 'auth_tkt', cookie_parts)[0]
return {'Cookie': cookie}
def _login_dashboard_user(self, user):
policy = self.testapp.app.registry.queryUtility(IAuthenticationPolicy)
headers = policy.remember(self.request, user.id)
cookie_parts = dict(headers)['Set-Cookie'].split('; ')
cookie = filter(
lambda i: i.split('=')[0] == 'auth_tkt', cookie_parts)[0]
return {'Cookie': cookie}
def setUp(self):
super(FunctionalTestBase, self).setUp()
current_dir = os.getcwd()
app = main(
{
'__file__': os.path.join(current_dir, SETTINGS_FILE),
'here': current_dir
},
**settings)
self.testapp = TestApp(app, extra_environ={
'HTTP_HOST': 'example.com'
})
self.request = testing.DummyRequest()
# used by cookie auth as the domain
self.request.environ = {
'SERVER_NAME': 'example.com',
}
| 301.338078 | 5,382 | 0.756566 | 10,952 | 84,676 | 5.489682 | 0.050219 | 0.0978 | 0.050496 | 0.023286 | 0.916006 | 0.905211 | 0.89104 | 0.875089 | 0.86664 | 0.829034 | 0 | 0.100719 | 0.063725 | 84,676 | 280 | 5,383 | 302.414286 | 0.657644 | 0.020147 | 0 | 0.165899 | 0 | 0.087558 | 0.906709 | 0.719572 | 0 | 0 | 0 | 0.003571 | 0 | 1 | 0.069124 | false | 0.009217 | 0.069124 | 0 | 0.184332 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 1 | 1 | 1 | 1 | 1 | 1 | 0 | 0 | 0 | 0 | 0 | 1 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 1 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 10 |
285d1004e73fa9294379706a3ee69fd6a8b1f16a | 168 | py | Python | streaming/transparency/api/__init__.py | rcfontana/faust-transparency | e0a7773c5589ecded5e0567f469a62ecba748536 | [
"MIT"
] | 12 | 2019-04-21T18:01:45.000Z | 2020-11-05T03:17:35.000Z | streaming/transparency/api/__init__.py | d3vzer0/faust-enricher | 17b8b59f26f60c36fda31e507dc6d897c22e80e9 | [
"MIT"
] | 7 | 2019-04-22T19:53:36.000Z | 2022-02-17T23:45:34.000Z | streaming/transparency/api/__init__.py | d3vzer0/faust-enricher | 17b8b59f26f60c36fda31e507dc6d897c22e80e9 | [
"MIT"
] | 3 | 2019-04-22T20:25:52.000Z | 2019-12-19T21:19:16.000Z | from streaming.transparency.api.sources import Sources
from streaming.transparency.api.records import Records
from streaming.transparency.api.merkle import MerkleTree
| 33.6 | 56 | 0.869048 | 21 | 168 | 6.952381 | 0.428571 | 0.267123 | 0.513699 | 0.575342 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0.077381 | 168 | 4 | 57 | 42 | 0.941935 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | true | 0 | 1 | 0 | 1 | 0 | 1 | 0 | 0 | null | 1 | 1 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 1 | 0 | 1 | 0 | 0 | 8 |
289d94d4c2f8190ae42a24730bbdaec98e64babf | 140 | py | Python | anuvaad-etl/anuvaad-extractor/sentence/etl-tokeniser/routes/__init__.py | ManavTriesStuff/anuvaad | 6993e3ac78818c171c173ccf8acf962ff57856a4 | [
"MIT"
] | 15 | 2021-01-08T08:42:30.000Z | 2022-03-12T17:52:15.000Z | anuvaad-etl/anuvaad-extractor/sentence/etl-tokeniser/routes/__init__.py | ManavTriesStuff/anuvaad | 6993e3ac78818c171c173ccf8acf962ff57856a4 | [
"MIT"
] | 16 | 2021-01-21T01:38:51.000Z | 2022-01-20T08:59:52.000Z | anuvaad-etl/anuvaad-extractor/sentence/etl-tokeniser/routes/__init__.py | ManavTriesStuff/anuvaad | 6993e3ac78818c171c173ccf8acf962ff57856a4 | [
"MIT"
] | 25 | 2020-08-26T11:25:38.000Z | 2022-03-29T04:40:21.000Z | from .para_sen_routes import TOK_BLUEPRINT
from .para_sen_routes import TOK_BLUEPRINT_wf
from .para_sen_routes import TOK_BLOCK_BLUEPRINT_wf | 46.666667 | 51 | 0.9 | 24 | 140 | 4.75 | 0.375 | 0.210526 | 0.289474 | 0.447368 | 0.842105 | 0.842105 | 0.614035 | 0 | 0 | 0 | 0 | 0 | 0.078571 | 140 | 3 | 51 | 46.666667 | 0.883721 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | true | 0 | 1 | 0 | 1 | 0 | 1 | 0 | 0 | null | 1 | 1 | 1 | 1 | 1 | 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 | 10 |
955112a3f23e6c41f8f3a42384d6f0d832c0a98a | 2,277 | py | Python | sys_web/migrations/0004_avaliardois_avaliartres_avaliarum.py | jamesperes/fred_sys | 30e4b0cdc5d2fbe76c40a6ae4f26650e28590e4f | [
"Apache-2.0"
] | null | null | null | sys_web/migrations/0004_avaliardois_avaliartres_avaliarum.py | jamesperes/fred_sys | 30e4b0cdc5d2fbe76c40a6ae4f26650e28590e4f | [
"Apache-2.0"
] | null | null | null | sys_web/migrations/0004_avaliardois_avaliartres_avaliarum.py | jamesperes/fred_sys | 30e4b0cdc5d2fbe76c40a6ae4f26650e28590e4f | [
"Apache-2.0"
] | 1 | 2018-10-15T21:52:33.000Z | 2018-10-15T21:52:33.000Z | # Generated by Django 2.0.7 on 2018-08-15 05:31
from django.db import migrations, models
class Migration(migrations.Migration):
dependencies = [
('sys_web', '0003_criterios'),
]
operations = [
migrations.CreateModel(
name='Avaliardois',
fields=[
('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
('c1a1a2', models.IntegerField()),
('c1a1a3', models.IntegerField()),
('c1a2a3', models.IntegerField()),
('c2a1a2', models.IntegerField()),
('c2a1a3', models.IntegerField()),
('c2a2a3', models.IntegerField()),
('c3a1a2', models.IntegerField()),
('c3a1a3', models.IntegerField()),
('c3a2a3', models.IntegerField()),
],
),
migrations.CreateModel(
name='Avaliartres',
fields=[
('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
('c1a1a2', models.IntegerField()),
('c1a1a3', models.IntegerField()),
('c1a2a3', models.IntegerField()),
('c2a1a2', models.IntegerField()),
('c2a1a3', models.IntegerField()),
('c2a2a3', models.IntegerField()),
('c3a1a2', models.IntegerField()),
('c3a1a3', models.IntegerField()),
('c3a2a3', models.IntegerField()),
],
),
migrations.CreateModel(
name='Avaliarum',
fields=[
('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
('c1a1a2', models.IntegerField()),
('c1a1a3', models.IntegerField()),
('c1a2a3', models.IntegerField()),
('c2a1a2', models.IntegerField()),
('c2a1a3', models.IntegerField()),
('c2a2a3', models.IntegerField()),
('c3a1a2', models.IntegerField()),
('c3a1a3', models.IntegerField()),
('c3a2a3', models.IntegerField()),
],
),
]
| 38.59322 | 114 | 0.502415 | 166 | 2,277 | 6.825301 | 0.307229 | 0.42895 | 0.066196 | 0.0609 | 0.825243 | 0.825243 | 0.825243 | 0.825243 | 0.825243 | 0.825243 | 0 | 0.066534 | 0.339921 | 2,277 | 58 | 115 | 39.258621 | 0.687292 | 0.019763 | 0 | 0.807692 | 1 | 0 | 0.101345 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | false | 0 | 0.019231 | 0 | 0.076923 | 0 | 0 | 0 | 0 | null | 1 | 0 | 0 | 1 | 1 | 1 | 1 | 1 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 1 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 9 |
95ccd56cc6c4be176c9bfbf2b3a931ef7fd38ef5 | 118 | py | Python | dpd/wikipedia/__init__.py | davidbailey/dpd | 29bce937e34afa2161788a5c4a911e590a388229 | [
"MIT"
] | 6 | 2020-08-13T22:21:25.000Z | 2021-09-15T19:12:51.000Z | dpd/wikipedia/__init__.py | davidbailey/dpd | 29bce937e34afa2161788a5c4a911e590a388229 | [
"MIT"
] | 3 | 2018-01-25T09:11:01.000Z | 2020-12-22T17:31:24.000Z | dpd/wikipedia/__init__.py | davidbailey/dpd | 29bce937e34afa2161788a5c4a911e590a388229 | [
"MIT"
] | null | null | null | from .get_wikipedia_table import get_wikipedia_table
from .get_wikipedia_coordinates import get_wikipedia_coordinates
| 39.333333 | 64 | 0.915254 | 16 | 118 | 6.25 | 0.375 | 0.48 | 0.32 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0.067797 | 118 | 2 | 65 | 59 | 0.909091 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | true | 0 | 1 | 0 | 1 | 0 | 1 | 0 | 0 | null | 1 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 1 | 0 | 1 | 0 | 0 | 7 |
25032c7ba479144d32f75cc208bf0be2c4be7427 | 9,073 | py | Python | tests/test_train.py | jay-johnson/antinex-core | 6d179f84300a642867997b55b1f7c5a1b4f8cfa0 | [
"Apache-2.0"
] | 18 | 2018-03-11T09:44:21.000Z | 2020-12-16T02:02:57.000Z | tests/test_train.py | jay-johnson/antinex-core | 6d179f84300a642867997b55b1f7c5a1b4f8cfa0 | [
"Apache-2.0"
] | null | null | null | tests/test_train.py | jay-johnson/antinex-core | 6d179f84300a642867997b55b1f7c5a1b4f8cfa0 | [
"Apache-2.0"
] | 2 | 2019-01-21T13:15:06.000Z | 2020-06-03T21:15:54.000Z | import mock
from tests.base_test import BaseTestCase
from tests.mock_make_predictions import mock_make_predictions_success
from tests.mock_make_predictions import mock_make_predictions_error
from tests.mock_make_predictions import mock_make_predictions_fail
from tests.mock_message import MockMessage
from spylunking.log.setup_logging import test_logger
from antinex_core.antinex_processor import AntiNexProcessor
log = test_logger(name='test-train')
class TestTrain(BaseTestCase):
@mock.patch(
"antinex_utils.make_predictions.make_predictions",
new=mock_make_predictions_success)
def test_train_antinex_simple(self):
exchange = "webapp.train.requests"
routing_key = "webapp.train.requests"
queue = "webapp.train.requests"
max_models = 1
prc = AntiNexProcessor(
max_models=max_models)
body = self.build_train_antinex_request()
self.assertEqual(
body["ml_type"],
"classification")
message = MockMessage(
exchange=exchange,
routing_key=routing_key,
queue=queue)
self.assertEqual(
message.state,
"NOTRUN")
self.assertEqual(
message.get_exchange(),
exchange)
self.assertEqual(
message.get_routing_key(),
routing_key)
self.assertEqual(
message.get_queue(),
queue)
self.assertEqual(
len(prc.models),
0)
prc.handle_messages(
body=body,
message=message)
self.assertEqual(
message.state,
"ACK")
self.assertEqual(
len(prc.models),
max_models)
# end of test_train_antinex_simple
@mock.patch(
"antinex_utils.make_predictions.make_predictions",
new=mock_make_predictions_error)
def test_train_antinex_simple_error(self):
exchange = "webapp.train.requests"
routing_key = "webapp.train.requests"
queue = "webapp.train.requests"
max_models = 1
prc = AntiNexProcessor(
max_models=max_models)
body = self.build_train_antinex_request()
self.assertEqual(
body["ml_type"],
"classification")
message = MockMessage(
exchange=exchange,
routing_key=routing_key,
queue=queue)
self.assertEqual(
message.state,
"NOTRUN")
self.assertEqual(
message.get_exchange(),
exchange)
self.assertEqual(
message.get_routing_key(),
routing_key)
self.assertEqual(
message.get_queue(),
queue)
self.assertEqual(
len(prc.models),
0)
prc.handle_messages(
body=body,
message=message)
self.assertEqual(
message.state,
"ACK")
self.assertEqual(
len(prc.models),
0)
# end of test_train_antinex_simple_error
@mock.patch(
"antinex_utils.make_predictions.make_predictions",
new=mock_make_predictions_fail)
def test_train_antinex_simple_fail(self):
exchange = "webapp.train.requests"
routing_key = "webapp.train.requests"
queue = "webapp.train.requests"
max_models = 1
prc = AntiNexProcessor(
max_models=max_models)
body = self.build_train_antinex_request()
self.assertEqual(
body["ml_type"],
"classification")
message = MockMessage(
exchange=exchange,
routing_key=routing_key,
queue=queue)
self.assertEqual(
message.state,
"NOTRUN")
self.assertEqual(
message.get_exchange(),
exchange)
self.assertEqual(
message.get_routing_key(),
routing_key)
self.assertEqual(
message.get_queue(),
queue)
self.assertEqual(
len(prc.models),
0)
prc.handle_messages(
body=body,
message=message)
self.assertEqual(
message.state,
"ACK")
self.assertEqual(
len(prc.models),
0)
# end of test_train_antinex_simple_fail
@mock.patch(
"antinex_utils.make_predictions.make_predictions",
new=mock_make_predictions_success)
def test_train_antinex_simple_model_cleanup(self):
exchange = "webapp.train.requests"
routing_key = "webapp.train.requests"
queue = "webapp.train.requests"
max_models = 1
prc = AntiNexProcessor(
max_models=max_models)
body = self.build_train_antinex_request()
self.assertEqual(
body["ml_type"],
"classification")
message = MockMessage(
exchange=exchange,
routing_key=routing_key,
queue=queue)
self.assertEqual(
message.state,
"NOTRUN")
self.assertEqual(
message.get_exchange(),
exchange)
self.assertEqual(
message.get_routing_key(),
routing_key)
self.assertEqual(
message.get_queue(),
queue)
self.assertEqual(
len(prc.models),
0)
prc.handle_messages(
body=body,
message=message)
self.assertEqual(
message.state,
"ACK")
self.assertEqual(
len(prc.models),
max_models)
# now try to train a new one and test the cleanup
body["label"] = "should-remove-the-first"
self.assertEqual(
len(prc.models),
1)
prc.handle_messages(
body=body,
message=message)
self.assertEqual(
message.state,
"ACK")
self.assertEqual(
len(prc.models),
max_models)
for midx, model_name in enumerate(prc.models):
self.assertEqual(
model_name,
body["label"])
# end of test_train_antinex_simple_model_cleanup
def test_train_antinex_simple_success(self):
exchange = "webapp.train.requests"
routing_key = "webapp.train.requests"
queue = "webapp.train.requests"
max_models = 1
prc = AntiNexProcessor(
max_models=max_models)
body = self.build_train_antinex_request()
self.assertEqual(
body["ml_type"],
"classification")
message = MockMessage(
exchange=exchange,
routing_key=routing_key,
queue=queue)
self.assertEqual(
message.state,
"NOTRUN")
self.assertEqual(
message.get_exchange(),
exchange)
self.assertEqual(
message.get_routing_key(),
routing_key)
self.assertEqual(
message.get_queue(),
queue)
self.assertEqual(
len(prc.models),
0)
prc.handle_messages(
body=body,
message=message)
self.assertEqual(
message.state,
"ACK")
self.assertEqual(
len(prc.models),
max_models)
# end of test_train_antinex_simple_success
def test_train_antinex_simple_success_retrain(self):
exchange = "webapp.train.requests"
routing_key = "webapp.train.requests"
queue = "webapp.train.requests"
max_models = 1
prc = AntiNexProcessor(
max_models=max_models)
body = self.build_train_antinex_request()
self.assertEqual(
body["ml_type"],
"classification")
message = MockMessage(
exchange=exchange,
routing_key=routing_key,
queue=queue)
self.assertEqual(
message.state,
"NOTRUN")
self.assertEqual(
message.get_exchange(),
exchange)
self.assertEqual(
message.get_routing_key(),
routing_key)
self.assertEqual(
message.get_queue(),
queue)
self.assertEqual(
len(prc.models),
0)
prc.handle_messages(
body=body,
message=message)
self.assertEqual(
message.state,
"ACK")
self.assertEqual(
len(prc.models),
max_models)
self.assertEqual(
len(prc.models),
1)
prc.handle_messages(
body=body,
message=message)
self.assertEqual(
message.state,
"ACK")
self.assertEqual(
len(prc.models),
max_models)
# end of test_train_antinex_simple_success_retrain
# end of TestTrain
| 26.922849 | 69 | 0.555164 | 852 | 9,073 | 5.674883 | 0.091549 | 0.170631 | 0.145605 | 0.093071 | 0.916029 | 0.901965 | 0.875284 | 0.875284 | 0.875284 | 0.842399 | 0 | 0.002768 | 0.362945 | 9,073 | 336 | 70 | 27.002976 | 0.833737 | 0.034278 | 0 | 0.922807 | 0 | 0 | 0.090826 | 0.067291 | 0 | 0 | 0 | 0 | 0.192982 | 1 | 0.021053 | false | 0 | 0.02807 | 0 | 0.052632 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 1 | 1 | 1 | 1 | 1 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 7 |
2556a32ef565fa49a431635dfee06d3fb4be7798 | 6,472 | py | Python | physicsScripts/electroMagneticField/electroMagneticField.py | aknh9189/code | 03478b86f0db233040a8341e9067cbb134bc0af9 | [
"MIT"
] | null | null | null | physicsScripts/electroMagneticField/electroMagneticField.py | aknh9189/code | 03478b86f0db233040a8341e9067cbb134bc0af9 | [
"MIT"
] | null | null | null | physicsScripts/electroMagneticField/electroMagneticField.py | aknh9189/code | 03478b86f0db233040a8341e9067cbb134bc0af9 | [
"MIT"
] | null | null | null |
# coding: utf-8
# In[17]:
import numpy as np
from matplotlib import pyplot as plt
get_ipython().magic(u'matplotlib inline')
resolution = 100 #resolution of 1m by 1m grid
field=np.zeros((resolution,resolution)) #create fields arrays
fieldx=np.zeros((resolution,resolution))
fieldy=np.zeros((resolution,resolution))
def distanceFrom(point1,point2): #fuction to find relationship between two points
distance = np.sqrt((point1[0]-point2[0])**2 + (point1[1]-point2[1])**2)
#print distance
if point1[1]-point2[1] == 0 and point1[0]-point2[0] == 0: #if the points arent on top of eachother (error handeling)
return 0,0 #return zeros
elif point1[0]-point2[0] == 0: #if on y axis relative to center point
if point1[1]-point2[1] > 0: #if above center point
return point1[1]-point2[1], 90
elif point1[1]-point2[1] < 0: #below center point
return abs(point1[1]-point2[1]), 270
elif point1[1]-point2[1] == 0: #if on the x axis
if point1[0]-point2[0] > 0: #if left of center point
return point1[0]-point2[0], 180
elif point1[0]-point2[0] < 0: #below center point
return abs(point1[0]-point2[0]),0
else:
angle = np.arctan(float(abs(point1[1]-point2[1]))/abs(point1[0]-point2[0])) #find reference angle
#print "({0},{1})".format(point1[0]-point2[0],point1[1]-point2[1]) #y
if point1[0]-point2[0] == 0: #flush if on point
quad = 0
elif point1[0]-point2[0] < 0: #quadrants 1 and 4
if point1[1]-point2[1] == 0:#on y axis
quad = 0
elif point1[1]-point2[1] > 0: #qaudrants 1 and 2 so becomes 1
quad = 1
angle = angle #angle is reference angle
elif point1[1]-point2[1] < 0: #quadrants 3 and 4
quad = 4
#print angle
angle = (2.0*np.pi) - angle #ajust for q4
#print angle
elif point1[0]-point2[0] > 0: #quadrants 2 and 3
if point1[1]-point2[1] == 0:#on y axis
quad = 0
elif point1[1]-point2[1] > 0: #qaudrants 1 and 2 so becomes 2
quad = 2
angle = np.pi-angle #ajust for quadrant 2
elif point1[1]-point2[1] < 0: #quadrants 3 and 4
quad = 3
angle = np.pi+angle #ajust for q3
#distance = distance * (1/resolution) #convert to meters
#print distance
# plt.figure()
# plt.xlim(0,10)
# plt.ylim(0,10)
# plt.gca().invert_yaxis()
# plt.plot(point2[0],point2[1],'or')
# plt.plot(point1[0],point1[1],'og')
# plt.show()
return distance,np.rad2deg(angle)#, quad
def addCharge(magnitude=5, location=(0,0)):
k=9.11e9
field[location[1]][location[0]] = magnitude
for x in range(0,len(field)):
for y in range(0,len(field)): #find y vector values
dist, angle = distanceFrom(location,(x,y))
if dist != 0:
eFieldConst = (k*magnitude/((dist*1.0/resolution)**2))
else:
eFieldConst = 0
fieldx[y,x] = fieldx[y,x] + np.cos(np.deg2rad(angle)) * eFieldConst
fieldy[y,x] = fieldy[y,x] + np.sin(np.deg2rad(angle)) *eFieldConst
field[y,x] = field[y,x] + eFieldConst
#print "T.P=({0},{1}) | Angle={2} | Dist={3} | X comp={4} | Y comp={5} |".format(x,y,angle,dist,fieldx[x,y],fieldy[x,y])
#distanceFrom((0,0),(999,0))
addCharge(0.0000001,(25,50))
addCharge(-0.0000002,(50,50))
addCharge(0.0000003,(75,50))
fieldx[24,40]= 0
#addCharge(3,(2,2))
#addCharge(2,(2,1))
#print field
#plt.imshow(field, interpolation='nearest')
plt.gca().invert_yaxis()
a = plt.quiver(fieldx,fieldy)
#plt.imshow(field)
#plt.show()
# In[ ]:
# In[ ]:
# In[1]:
# In[ ]:
####### IGNORE FOR PROGRAM - JUST TESTING FOR FINAL ######### (IN IPYTHON NOTEBOOK)
def distanceFrom(point1,point2):
distance = np.sqrt((point1[0]-point2[0])**2 + (point1[1]-point2[1])**2)
#print distance
if point1[1]-point2[1] == 0 and point1[0]-point2[0] == 0: #if the points arent on top of eachother (error handeling)
return 0,0 #return zeros
elif point1[0]-point2[0] == 0: #if on y axis relative to center point
if point1[1]-point2[1] > 0: #if above center point
return point1[1]-point2[1], 90
elif point1[1]-point2[1] < 0: #below center point
return abs(point1[1]-point2[1]), 270
elif point1[1]-point2[1] == 0: #if on the x axis
if point1[0]-point2[0] > 0: #if left of center point
return point1[0]-point2[0], 180
elif point1[0]-point2[0] < 0: #below center point
return abs(point1[0]-point2[0]),0
else:
angle = np.arctan(float(abs(point1[1]-point2[1]))/abs(point1[0]-point2[0])) #find reference angle
#print "({0},{1})".format(point1[0]-point2[0],point1[1]-point2[1]) #y
if point1[0]-point2[0] == 0: #flush if on point
quad = 0
elif point1[0]-point2[0] < 0: #quadrants 1 and 4
if point1[1]-point2[1] == 0:#on y axis
quad = 0
elif point1[1]-point2[1] > 0: #qaudrants 1 and 2 so becomes 1
quad = 1
angle = angle #angle is reference angle
elif point1[1]-point2[1] < 0: #quadrants 3 and 4
quad = 4
#print angle
angle = (2.0*np.pi) - angle #ajust for q4
#print angle
elif point1[0]-point2[0] > 0: #quadrants 2 and 3
if point1[1]-point2[1] == 0:#on y axis
quad = 0
elif point1[1]-point2[1] > 0: #qaudrants 1 and 2 so becomes 2
quad = 2
angle = np.pi-angle #ajust for quadrant 2
elif point1[1]-point2[1] < 0: #quadrants 3 and 4
quad = 3
angle = np.pi+angle #ajust for q3
#distance = distance * (1/resolution) #convert to meters
#print distance
plt.figure()
plt.xlim(0,10)
plt.ylim(0,10)
plt.gca().invert_yaxis()
plt.plot(point2[0],point2[1],'or')
plt.plot(point1[0],point1[1],'og')
plt.show()
return distance,np.rad2deg(angle)#, quad
print distanceFrom((2,5),(9,0))
# In[ ]:
# In[ ]:
# In[ ]:
# In[1]:
# In[ ]:
# In[ ]:
# In[2]:
# In[ ]:
| 30.242991 | 132 | 0.547126 | 957 | 6,472 | 3.695925 | 0.15256 | 0.063331 | 0.110263 | 0.118745 | 0.71473 | 0.700594 | 0.700594 | 0.700594 | 0.700594 | 0.700594 | 0 | 0.101188 | 0.29759 | 6,472 | 213 | 133 | 30.384977 | 0.676859 | 0.31165 | 0 | 0.712963 | 0 | 0 | 0.00484 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | null | 0 | 0.018519 | null | null | 0.009259 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 1 | 1 | 1 | 1 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 7 |
255c7b773a0190114ac3b8a09434291a0e12e7d1 | 6,930 | py | Python | zounds/basic/test_merge.py | FelixAbrahamsson/zounds | 197c358acf3bea4252cfc2561da70cbe799e2c75 | [
"MIT"
] | 20 | 2016-06-04T05:44:28.000Z | 2021-05-26T02:26:08.000Z | zounds/basic/test_merge.py | FelixAbrahamsson/zounds | 197c358acf3bea4252cfc2561da70cbe799e2c75 | [
"MIT"
] | 53 | 2016-08-07T15:11:38.000Z | 2019-05-21T15:56:40.000Z | zounds/basic/test_merge.py | FelixAbrahamsson/zounds | 197c358acf3bea4252cfc2561da70cbe799e2c75 | [
"MIT"
] | 7 | 2016-08-14T15:50:33.000Z | 2020-12-22T13:34:23.000Z | import unittest2
import numpy as np
from featureflow import BaseModel, Node, PersistenceSettings
from .basic import Merge
from zounds.timeseries import Milliseconds, TimeDimension
from zounds.persistence import ArrayWithUnitsFeature
from zounds.core import ArrayWithUnits, IdentityDimension
class MergeTester(Node):
def __init__(
self,
total_frames=100,
increments_of=30,
features=10,
needs=None):
super(MergeTester, self).__init__(needs=needs)
self.features = features
self.increments_of = increments_of
self.total_frames = total_frames
def _process(self, data):
for i in range(0, self.total_frames, self.increments_of):
size = min(self.increments_of, self.total_frames - i)
td = TimeDimension(frequency=Milliseconds(500))
yield ArrayWithUnits(
np.zeros((size, self.features)), [td, IdentityDimension()])
class MergeTests(unittest2.TestCase):
def test_raises_if_single_source(self):
class Document(BaseModel, PersistenceSettings):
source = ArrayWithUnitsFeature(
MergeTester,
store=True)
merged = ArrayWithUnitsFeature(
Merge,
needs=source,
store=True)
self.assertRaises(ValueError, lambda: Document.process(source=''))
def test_raises_if_single_element_iterable(self):
class Document(BaseModel, PersistenceSettings):
source = ArrayWithUnitsFeature(
MergeTester,
store=True)
merged = ArrayWithUnitsFeature(
Merge,
needs=[source],
store=True)
self.assertRaises(ValueError, lambda: Document.process(source=''))
def test_can_combine_two_sources_at_same_rate(self):
class Document(BaseModel, PersistenceSettings):
source1 = ArrayWithUnitsFeature(
MergeTester,
total_frames=200,
store=True)
source2 = ArrayWithUnitsFeature(
MergeTester,
total_frames=200,
store=True)
merged = ArrayWithUnitsFeature(
Merge,
needs=[source1, source2],
store=True)
_id = Document.process(source1='', source2='')
doc = Document(_id)
self.assertEqual((200, 20), doc.merged.shape)
def test_can_combine_three_sources_at_same_rate(self):
class Document(BaseModel, PersistenceSettings):
source1 = ArrayWithUnitsFeature(
MergeTester,
total_frames=200,
store=True)
source2 = ArrayWithUnitsFeature(
MergeTester,
total_frames=200,
store=True)
source3 = ArrayWithUnitsFeature(
MergeTester,
total_frames=200,
store=True)
merged = ArrayWithUnitsFeature(
Merge,
needs=(source1, source2, source3),
store=True)
_id = Document.process(source1='', source2='', source3='')
doc = Document(_id)
self.assertEqual((200, 30), doc.merged.shape)
def test_can_combine_two_sources_at_different_rates(self):
class Document(BaseModel, PersistenceSettings):
source1 = ArrayWithUnitsFeature(
MergeTester,
total_frames=200,
increments_of=30,
store=True)
source2 = ArrayWithUnitsFeature(
MergeTester,
total_frames=200,
increments_of=40,
store=True)
merged = ArrayWithUnitsFeature(
Merge,
needs=(source1, source2),
store=True)
_id = Document.process(source1='', source2='')
doc = Document(_id)
self.assertEqual((200, 20), doc.merged.shape)
def test_can_combine_three_sources_at_different_rates(self):
class Document(BaseModel, PersistenceSettings):
source1 = ArrayWithUnitsFeature(
MergeTester,
total_frames=200,
increments_of=12,
store=True)
source2 = ArrayWithUnitsFeature(
MergeTester,
total_frames=200,
increments_of=17,
store=True)
source3 = ArrayWithUnitsFeature(
MergeTester,
total_frames=200,
increments_of=32,
store=True)
merged = ArrayWithUnitsFeature(
Merge,
needs=(source1, source2, source3),
store=True)
_id = Document.process(source1='', source2='', source3='')
doc = Document(_id)
self.assertEqual((200, 30), doc.merged.shape)
def test_shortest_of_two_sources(self):
class Document(BaseModel, PersistenceSettings):
source1 = ArrayWithUnitsFeature(
MergeTester,
total_frames=190,
increments_of=30,
store=True)
source2 = ArrayWithUnitsFeature(
MergeTester,
total_frames=200,
increments_of=40,
store=True)
merged = ArrayWithUnitsFeature(
Merge,
needs=[source1, source2],
store=True)
_id = Document.process(source1='', source2='')
doc = Document(_id)
self.assertEqual((190, 20), doc.merged.shape)
def test_shortest_of_three_sources(self):
class Document(BaseModel, PersistenceSettings):
source1 = ArrayWithUnitsFeature(
MergeTester,
total_frames=200,
increments_of=12,
store=True)
source2 = ArrayWithUnitsFeature(
MergeTester,
total_frames=185,
increments_of=17,
store=True)
source3 = ArrayWithUnitsFeature(
MergeTester,
total_frames=50,
increments_of=32,
store=True)
merged = ArrayWithUnitsFeature(
Merge,
needs=[source1, source2, source3],
store=True)
_id = Document.process(source1='', source2='', source3='')
doc = Document(_id)
self.assertEqual((50, 30), doc.merged.shape)
| 36.473684 | 79 | 0.527706 | 543 | 6,930 | 6.548803 | 0.173112 | 0.063273 | 0.156074 | 0.181384 | 0.81018 | 0.785152 | 0.784589 | 0.765748 | 0.762936 | 0.762936 | 0 | 0.03615 | 0.397258 | 6,930 | 189 | 80 | 36.666667 | 0.815178 | 0 | 0 | 0.757396 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0.047337 | 1 | 0.059172 | false | 0 | 0.04142 | 0 | 0.159763 | 0 | 0 | 0 | 0 | null | 0 | 0 | 1 | 1 | 1 | 1 | 1 | 1 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 8 |
c291e1adfd0789528c830dc10c9a61ab8d77b0bf | 4,303 | py | Python | verifyml/model_tests/FEAT/tests/test_DataShift.py | cylynx/verifyml | d3b4b3465493b802aba87edff81015f0db97805b | [
"Apache-2.0"
] | 13 | 2021-10-30T03:32:53.000Z | 2022-03-31T00:51:09.000Z | verifyml/model_tests/FEAT/tests/test_DataShift.py | cylynx/verifyml | d3b4b3465493b802aba87edff81015f0db97805b | [
"Apache-2.0"
] | 28 | 2021-10-21T06:19:23.000Z | 2022-02-07T08:18:44.000Z | verifyml/model_tests/FEAT/tests/test_DataShift.py | cylynx/verifyml | d3b4b3465493b802aba87edff81015f0db97805b | [
"Apache-2.0"
] | 1 | 2022-02-07T04:10:15.000Z | 2022-02-07T04:10:15.000Z | # Test cases for the DataShift FEAT test
from ..DataShift import DataShift
import inspect
import pandas as pd
# Sample test case datas
x_train_data = pd.DataFrame(
{"gender": ["M", "M", "M", "M", "M", "M", "F", "F", "F", "F"]}
)
x_test_data = pd.DataFrame(
{"gender": ["M", "M", "M", "M", "M", "F", "F", "F", "F", "F"]}
)
def test_plot_defaults():
"""Test that the default arguments of the plot() method are as expected."""
sig = inspect.signature(DataShift.plot)
assert sig.parameters["alpha"].default == 0.05
assert sig.parameters["save_plots"].default == True
def test_save_plots_true():
"""Test that the plot is saved to the test object when .plot(save_plots=True)."""
# init test object
data_test = DataShift(protected_attr=["gender"], method="ratio", threshold=1.5)
# run test
data_test.run(x_train=x_train_data, x_test=x_test_data)
# plot it
data_test.plot(save_plots=True)
# test object should be a dict of length 1
assert len(data_test.plots) == 1
# test object should have the specified key, and the value should be a string
assert isinstance(
data_test.plots["Probability Distribution of protected attributes"], str
)
def test_save_plots_false():
"""Test that the plot is not saved to the test object when .plot(save_plots=False)."""
# init test object
data_test = DataShift(protected_attr=["gender"], method="ratio", threshold=1.5)
# run test
data_test.run(x_train=x_train_data, x_test=x_test_data)
# plot it
data_test.plot(save_plots=False)
# nothing should be saved
assert len(data_test.plots) == 0
def test_run_ratio():
"""Test that calling .run() updates the test object's .result and .passed attributes."""
# init test object
data_test = DataShift(protected_attr=["gender"], method="ratio", threshold=1.23)
# run test
data_test.run(x_train=x_train_data, x_test=x_test_data)
assert data_test.result.loc["gender_F"]["training_distribution"] == 0.4
assert data_test.result.loc["gender_F"]["eval_distribution"] == 0.5
assert data_test.result.loc["gender_F"]["ratio"] == 1.25
assert data_test.result.loc["gender_F"]["passed"] == False
assert data_test.result.loc["gender_M"]["training_distribution"] == 0.6
assert data_test.result.loc["gender_M"]["eval_distribution"] == 0.5
assert data_test.result.loc["gender_M"]["ratio"] == 1.2
assert data_test.result.loc["gender_M"]["passed"] == True
assert data_test.passed == False
def test_run_difference():
"""Test that calling .run() updates the test object's .result and .passed attributes."""
# init test object
data_test = DataShift(protected_attr=["gender"], method="diff", threshold=0.1)
# run test
data_test.run(x_train=x_train_data, x_test=x_test_data)
assert data_test.result.loc["gender_F"]["training_distribution"] == 0.4
assert data_test.result.loc["gender_F"]["eval_distribution"] == 0.5
assert data_test.result.loc["gender_F"]["difference"] == 0.1
assert data_test.result.loc["gender_F"]["passed"] == True
assert data_test.result.loc["gender_M"]["training_distribution"] == 0.6
assert data_test.result.loc["gender_M"]["eval_distribution"] == 0.5
assert data_test.result.loc["gender_M"]["difference"] == 0.1
assert data_test.result.loc["gender_M"]["passed"] == True
assert data_test.passed == True
def test_run_chi2():
"""Test that calling .run() updates the test object's .result and .passed attributes."""
# init test object
data_test = DataShift(protected_attr=["gender"], method="chi2", threshold=1.1)
# run test
data_test.run(x_train=x_train_data, x_test=x_test_data)
assert data_test.result.loc["gender_F"]["training_distribution"] == 0.4
assert data_test.result.loc["gender_F"]["eval_distribution"] == 0.5
assert data_test.result.loc["gender_F"]["p-value"] == 1
assert data_test.result.loc["gender_F"]["passed"] == False
assert data_test.result.loc["gender_M"]["training_distribution"] == 0.6
assert data_test.result.loc["gender_M"]["eval_distribution"] == 0.5
assert data_test.result.loc["gender_M"]["p-value"] == 1
assert data_test.result.loc["gender_M"]["passed"] == False
assert data_test.passed == False
| 35.270492 | 92 | 0.684406 | 652 | 4,303 | 4.308282 | 0.142638 | 0.119616 | 0.134567 | 0.170879 | 0.768601 | 0.726949 | 0.726949 | 0.726949 | 0.726949 | 0.639729 | 0 | 0.014996 | 0.163142 | 4,303 | 121 | 93 | 35.561983 | 0.765065 | 0.191727 | 0 | 0.403226 | 0 | 0 | 0.188866 | 0.036724 | 0 | 0 | 0 | 0 | 0.516129 | 1 | 0.096774 | false | 0.145161 | 0.048387 | 0 | 0.145161 | 0 | 0 | 0 | 0 | null | 0 | 0 | 1 | 0 | 1 | 1 | 1 | 1 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 1 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | 0 | 0 | 8 |
665f126530811e92701eed207cba5811bcf2a78b | 13,904 | py | Python | tools/dictionaries.py | hn617/paINDICATOR | 67f1dbca5151ed166ef4fda213c4798fdc07b3c0 | [
"MIT"
] | 1 | 2021-09-29T16:39:41.000Z | 2021-09-29T16:39:41.000Z | tools/dictionaries.py | hn617/paINDICATOR | 67f1dbca5151ed166ef4fda213c4798fdc07b3c0 | [
"MIT"
] | null | null | null | tools/dictionaries.py | hn617/paINDICATOR | 67f1dbca5151ed166ef4fda213c4798fdc07b3c0 | [
"MIT"
] | null | null | null | appointment_status_types = ['manually completed', 'completed', 'cancelled',
'open', 'cancelled - patient no-show', 'in progress (manually set)',
'in progress', 'pt. compltfinish',
'pt. compltactive'
]
valid_status = ['manually completed', 'completed']
valid_ct_types = ['ct sim (tasked)', 'ct sim (add-on tasked)',
'ct sim 4d-ct (tasked)',
'initial simulation',
'ct sim + fu at itt (tasked)', 'ct sim',
'ct sim + call md (tasked)',
''
]
valid_cosult_types = ['consult new out palliative', 'consult return out palliative',
'consult new in palliative', 'consult return in palliative',
'consult return out', 'consult new out', 'consult new in',
'con pall ni offsite lakeshore',
'con no offsite lakeshore',
'con pall no offsite lakeshore',
'con pall ro offsite lakeshore',
'con pall ni offsite lakeshore',
'con no offsite mni',
'con ro offsite mni',
'con pall ro offsite mni',
'con pall ri offsite mni',
'con pall no offsite mni',
'consult n-o',
'con pall no offsite valleyfield',
]
ivalid_appointment_types = [
'.brc-implant prep.',
'.brc-intracav. rx',
'.brc-ns interst.+ ebrt', '.brc-ns intracav.+ ebrt', '.bxc implant ent', '.bxc implant eye plaque',
'.bxc implant gyn', '.bxc implant other', '.bxc implant prostate', '.bxc incav.cerv anes+ebrt',
'.bxc incav.cerv ns anes+ebrt', '.bxc incav.nasophar ns alone', '.bxc incav.oesophag alone',
'.bxc incav.vault ns+ebrt', '.bxc inst.ent ns alone', '.bxc inst.ent prep+sim', '.bxc inst.ent rx',
'.bxc inst.prostate ns+ebrt', '.bxc ns eye plaque', '.ebc-cancelled', '.ebc-daily rx',
'.ebc-daily rx (electron boost)', '.ebc-last rx', '.ebc-mod plan', '.ebc-new start',
'.ebc-new start (+site)', '.ebc-new start (electron boost)', '.ebc-new start (plan ii)',
'.ebc-new start (plan iii)', '.ebc-new start (srs/fsrt/sbrt)', '.ebc-on hold', '.ebc-one rx',
'.ebc-one rx (srs/fsrt/sbrt)', '.ebm-dibh teaching', '.ebm-iso shift', '.ebm-plan on machine',
'.ebm-plan on machine (ado not use)', '.ebm-plan on machine (anot to use)',
'.ebm-plan on machine (clinical with md)', '.ebm-plan on machine (virtual)',
'.ebm-pt booked', '.ebm-waiting distribution', '.ebm-waiting md contouring', '.ebp-cancelled',
'.ebp-daily rx', '.ebp-last rx', '.ebp-mod plan', '.ebp-new start', '.ebp-new start (+site)',
'.ebp-new start (plan ii)', '.ebp-new start (srs/fsrt/sbrt)', '.ebp-on hold', '.ebp-one rx',
'.ebp-one rx (srs/fsrt/sbrt)', '.reminder', '6 breast follow ups', 'blood test',
'brachy', 'brachy (reminder)',
'brachytherapy coverage', 'brainlab mask',
'ca-pain fu', 'cancelled', 'cancelled (120min)', 'cancelled (15min)',
'cancelled (30min)', 'centre de la prostate rive sud',
'chemotherapy', 'closed', 'con ni offsite lakeshore', 'con ni offsite mni',
'con ni offsite mtl childrens', 'con no offsite ent clinic rvh', 'con no offsite gyn cl rvh',
'con no offsite lakeshore', 'con no offsite mni', 'con no offsite mtl childrens',
'con no offsite odc cl rvh', 'con no offsite priv chateauguay', 'con no offsite sarc cl mgh',
'con no offsite valleyfield', 'con no offsite video valleyfield', 'con no offsite vmbc',
'con pall ni offsite lakeshore', 'con pall no offsite gyn cl rvh',
'con pall no offsite lakeshore', 'con pall no offsite mni',
'con pall no offsite valleyfield', 'con pall no offsite vmbc',
'con pall ri offsite lakeshore', 'con pall ri offsite mni',
'con pall ro offsite lakeshore', 'con pall ro offsite mni',
'con pall ro offsite odc cl rvh', 'con pall ro offsite valleyfield',
'con ri offsite lakeshore', 'con ri offsite mni', 'con ro offsite ent clinic rvh',
'con ro offsite gyn cl rvh', 'con ro offsite lakeshore', 'con ro offsite mni',
'con ro offsite odc cl rvh', 'con ro offsite valleyfield', 'con ro offsite vmbc',
'covid-19 screening',
'cut out planning', 'daily rx', 'daily rx (30min)',
'daily rx (45min)', 'dressing', 'drr marking', 'ebm-dibh-teaching', 'electron boost', 'electron plan',
'electron plan (30min)', 'electron plan (45min)', 'f-u', 'f-u cancelled', 'f-u md clin', 'f-u md prot',
'f-u prot', 'f-up x 6', 'follow up', 'follow up in less/30days',
'follow up in more/30days', 'follow up in offsite more/30days', 'follow up in offsite pall less/30days',
'follow up in pall less/30days', 'follow up in prot more/30days',
'follow up out less/30days', 'follow up out more/30days', 'follow up out offsite less/30days',
'follow up out offsite more/30 days', 'follow up out offsite pall less/30days',
'follow up out offsite pall more/30days', 'follow up out pall more/30days',
'follow up out private clinic more/30 days', 'follow up out prot more/30days',
'follow up telemed less/30 days', 'follow up telemed more/30 days', 'gyn anesthesia',
'hold for rapid access', 'hydration', 'impl. prostate', 'imrt qa', 'in rx',
'in-rx/plan/ctsim', 'initial simulation', 'injection', 'intra treat in',
'intra treat note', 'intra treat out', 'intra treat telemed',
'intra-treatment visit', 'intra-treatment visits only', 'iso shift',
'jgh rad-onc', 'last rx', 'last rx (15min)', 'lgh no', 'mets', 'mets (15min)',
'mets (30min)', 'mets (brainlab)', 'mgh breast cl no', 'mgh ent clinic no', 'mni',
'mri sim', 'mri sim (brachy)', 'mri sim (pt not called)', 'mri sim (spine)',
'mri sim (tasked)', 'mri sim + iv', 'mri sim + iv (pt not called)',
'mri sim + iv (spine)', 'mri sim + iv (tasked)', 'new start', 'new start (15min)',
'new start (brachy)', 'new start (brainlab)', 'new start (electron boost)',
'new start (photon)', 'new start (plan ii)', 'new start (plan ii-15min)',
'new start prostate+cath.rem', 'nursing consult', 'nursing note', 'nutrition first consult',
'nutrition follow up', 'on call', 'on hold', 'on hold (15min)',
'one rx (15min)', 'other nursing', 'patient information',
'patient on break', 'patient unwell', 'pcdh consult', 'pcdh fu',
'physics measurement', 'physics qa', 'pmr palliative',
'prostate (plan ii)', 'pso consult out', 'pso fu out', 'ready for contour',
'ready for imrt qa', 'reminder', 'rvh gyn clinic', 'rvh odc no',
'rvh odc ro', 'sarc/ortho', 'tests to be booked', 'to be booked',
'transfusion', 'ultrasound cw', 'valleyfield', 'verif film', 'vmbc no'
]
appointment_types = [
'.brc-implant prep.',
'.brc-intracav. rx',
'.brc-ns interst.+ ebrt', '.brc-ns intracav.+ ebrt', '.bxc implant ent', '.bxc implant eye plaque',
'.bxc implant gyn', '.bxc implant other', '.bxc implant prostate', '.bxc incav.cerv anes+ebrt',
'.bxc incav.cerv ns anes+ebrt', '.bxc incav.nasophar ns alone', '.bxc incav.oesophag alone',
'.bxc incav.vault ns+ebrt', '.bxc inst.ent ns alone', '.bxc inst.ent prep+sim', '.bxc inst.ent rx',
'.bxc inst.prostate ns+ebrt', '.bxc ns eye plaque', '.ebc-cancelled', '.ebc-daily rx',
'.ebc-daily rx (electron boost)', '.ebc-last rx', '.ebc-mod plan', '.ebc-new start',
'.ebc-new start (+site)', '.ebc-new start (electron boost)', '.ebc-new start (plan ii)',
'.ebc-new start (plan iii)', '.ebc-new start (srs/fsrt/sbrt)', '.ebc-on hold', '.ebc-one rx',
'.ebc-one rx (srs/fsrt/sbrt)', '.ebm-dibh teaching', '.ebm-iso shift', '.ebm-plan on machine',
'.ebm-plan on machine (ado not use)', '.ebm-plan on machine (anot to use)',
'.ebm-plan on machine (clinical with md)', '.ebm-plan on machine (virtual)',
'.ebm-pt booked', '.ebm-waiting distribution', '.ebm-waiting md contouring', '.ebp-cancelled',
'.ebp-daily rx', '.ebp-last rx', '.ebp-mod plan', '.ebp-new start', '.ebp-new start (+site)',
'.ebp-new start (plan ii)', '.ebp-new start (srs/fsrt/sbrt)', '.ebp-on hold', '.ebp-one rx',
'.ebp-one rx (srs/fsrt/sbrt)', '.reminder', '6 breast follow ups', 'blood test',
'book ct sim',
'brachy', 'brachy (reminder)',
'brachytherapy coverage', 'brainlab mask', 'ca-pain consult',
'ca-pain fu', 'cancelled', 'cancelled (120min)', 'cancelled (15min)',
'cancelled (30min)', 'centre de la prostate rive sud',
'chemotherapy', 'closed', 'con ni offsite lakeshore', 'con ni offsite mni',
'con ni offsite mtl childrens', 'con no offsite ent clinic rvh', 'con no offsite gyn cl rvh',
'con no offsite lakeshore', 'con no offsite mni', 'con no offsite mtl childrens',
'con no offsite odc cl rvh', 'con no offsite priv chateauguay', 'con no offsite sarc cl mgh',
'con no offsite valleyfield', 'con no offsite video valleyfield', 'con no offsite vmbc',
'con pall ni offsite lakeshore', 'con pall no offsite gyn cl rvh',
'con pall no offsite lakeshore', 'con pall no offsite mni',
'con pall no offsite valleyfield', 'con pall no offsite vmbc',
'con pall ri offsite lakeshore', 'con pall ri offsite mni',
'con pall ro offsite lakeshore', 'con pall ro offsite mni',
'con pall ro offsite odc cl rvh', 'con pall ro offsite valleyfield',
'con ri offsite lakeshore', 'con ri offsite mni', 'con ro offsite ent clinic rvh',
'con ro offsite gyn cl rvh', 'con ro offsite lakeshore', 'con ro offsite mni',
'con ro offsite odc cl rvh', 'con ro offsite valleyfield', 'con ro offsite vmbc',
'consult',
'consult n-o',
'consult flex',
'consult new in',
'consult new in palliative',
'consult new out',
'consult new out palliative',
'consult new telemed',
'consult pall n-i',
'consult pall n-o',
'consult pall r-i',
'consult pall r-o',
'consult r-o',
'consult return in',
'consult return in palliative',
'consult return out',
'consult return out palliative',
'consult return telemed',
'consult ro offsite private chateauguay',
'covid-19 screening',
'ct sim',
'ct sim (add-on tasked)',
'ct sim (brachy)',
'ct sim (brain ck)',
'ct sim (left message)',
'ct sim (novalis)',
'ct sim (other)',
'ct sim (pt not called)',
'ct sim (reminder)',
'ct sim (rescan tasked)',
'ct sim (rescan)',
'ct sim (tasked)',
'ct sim + call md',
'ct sim + call md (left message)',
'ct sim + call md (pt not called)',
'ct sim + call md (tasked)',
'ct sim + fu at itt',
'ct sim + fu at itt (left message)',
'ct sim + fu at itt (tasked)',
'ct sim + iv', 'ct sim + iv (brain ck)',
'ct sim + iv (pt not called)',
'ct sim + iv (tasked)',
'ct sim + reconsult at simulator',
'ct sim + reconsult at simulator (tasked)',
'ct sim 4d-ct', 'ct sim 4d-ct (left message)',
'ct sim 4d-ct (pt not called)',
'ct sim 4d-ct (tasked)',
'ct sim 4d-ct + iv (tasked)',
'ct sim dibh (tasked)',
'cut out planning', 'daily rx', 'daily rx (30min)',
'daily rx (45min)', 'dressing', 'drr marking', 'ebm-dibh-teaching', 'electron boost', 'electron plan',
'electron plan (30min)', 'electron plan (45min)', 'f-u', 'f-u cancelled', 'f-u md clin', 'f-u md prot',
'f-u prot', 'f-up x 6', 'first consult', 'follow up', 'follow up in less/30days',
'follow up in more/30days', 'follow up in offsite more/30days', 'follow up in offsite pall less/30days',
'follow up in pall less/30days', 'follow up in prot more/30days',
'follow up out less/30days', 'follow up out more/30days', 'follow up out offsite less/30days',
'follow up out offsite more/30 days', 'follow up out offsite pall less/30days',
'follow up out offsite pall more/30days', 'follow up out pall more/30days',
'follow up out private clinic more/30 days', 'follow up out prot more/30days',
'follow up telemed less/30 days', 'follow up telemed more/30 days', 'gyn anesthesia',
'hold for rapid access', 'hydration', 'impl. prostate', 'imrt qa', 'in rx',
'in-rx/plan/ctsim', 'initial simulation', 'injection', 'intra treat in',
'intra treat note', 'intra treat out', 'intra treat telemed',
'intra-treatment visit', 'intra-treatment visits only', 'iso shift',
'jgh rad-onc', 'last rx', 'last rx (15min)', 'lgh no', 'mets', 'mets (15min)',
'mets (30min)', 'mets (brainlab)', 'mgh breast cl no', 'mgh ent clinic no', 'mni',
'mri sim', 'mri sim (brachy)', 'mri sim (pt not called)', 'mri sim (spine)',
'mri sim (tasked)', 'mri sim + iv', 'mri sim + iv (pt not called)',
'mri sim + iv (spine)', 'mri sim + iv (tasked)', 'new start', 'new start (15min)',
'new start (brachy)', 'new start (brainlab)', 'new start (electron boost)',
'new start (photon)', 'new start (plan ii)', 'new start (plan ii-15min)',
'new start prostate+cath.rem', 'nursing consult', 'nursing note', 'nutrition first consult',
'nutrition follow up', 'on call', 'on hold', 'on hold (15min)',
'one rx (15min)', 'other nursing', 'patient information',
'patient on break', 'patient unwell', 'pcdh consult', 'pcdh fu',
'physics measurement', 'physics qa', 'pmr palliative',
'prostate (plan ii)', 'pso consult out', 'pso fu out', 'ready for contour',
'ready for imrt qa', 'reminder', 'rvh gyn clinic', 'rvh odc no',
'rvh odc ro', 'sarc/ortho', 'tests to be booked', 'to be booked',
'transfusion', 'ultrasound cw', 'valleyfield', 'verif film', 'vmbc no'
]
| 62.071429 | 111 | 0.602345 | 1,955 | 13,904 | 4.278772 | 0.115601 | 0.022714 | 0.043515 | 0.030126 | 0.915959 | 0.862044 | 0.860968 | 0.841363 | 0.815541 | 0.802152 | 0 | 0.013231 | 0.238996 | 13,904 | 224 | 112 | 62.071429 | 0.777337 | 0 | 0 | 0.638889 | 0 | 0 | 0.726142 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | false | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 1 | 1 | 1 | 1 | 1 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 7 |
dd905eb9ff7b99f6e1665e9c5309c1222eb905eb | 36 | py | Python | primeirosProgramas/testeCores.py | LucasHenrique-dev/Exercicios-Python | b1f6ca56ea8e197a89a044245419dc6079bdb9c7 | [
"MIT"
] | 1 | 2020-04-09T23:18:03.000Z | 2020-04-09T23:18:03.000Z | primeirosProgramas/testeCores.py | LucasHenrique-dev/Exercicios-Python | b1f6ca56ea8e197a89a044245419dc6079bdb9c7 | [
"MIT"
] | null | null | null | primeirosProgramas/testeCores.py | LucasHenrique-dev/Exercicios-Python | b1f6ca56ea8e197a89a044245419dc6079bdb9c7 | [
"MIT"
] | null | null | null | print('\033[7;30mOlá Mundo!\033[m')
| 18 | 35 | 0.666667 | 7 | 36 | 3.428571 | 0.857143 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0.264706 | 0.055556 | 36 | 1 | 36 | 36 | 0.441176 | 0 | 0 | 0 | 0 | 0 | 0.722222 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | true | 0 | 0 | 0 | 0 | 1 | 1 | 1 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 1 | 0 | 0 | 1 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | 0 | 1 | 0 | 8 |
06ec3b106a771f8e6bda9ac08a194c797a63cbe3 | 149,884 | py | Python | smbf/mbf.py | Alpha-Demon404/RE-14 | b5b46a9f0eee218f2a642b615c77135c33c6f4ad | [
"MIT"
] | 39 | 2020-02-26T09:44:36.000Z | 2022-03-23T00:18:25.000Z | smbf/mbf.py | B4BY-DG/reverse-enginnering | b5b46a9f0eee218f2a642b615c77135c33c6f4ad | [
"MIT"
] | 15 | 2020-05-14T10:07:26.000Z | 2022-01-06T02:55:32.000Z | smbf/mbf.py | B4BY-DG/reverse-enginnering | b5b46a9f0eee218f2a642b615c77135c33c6f4ad | [
"MIT"
] | 41 | 2020-03-16T22:36:38.000Z | 2022-03-17T14:47:19.000Z | # Filenames : mbf-obf.py
# Python bytecode : 3.8
# Time succses decompiled Fri Sep 25 22:37:59 2020
# Selector <module> in line 1 file mbf-obf.py
# Timestamp in code : 2020-09-25 13:05:12
#exec(__import__('marshal').loads(
open('1.pyc','wb').write(b'U\r\r\n\x00\x00\x00\x00\x98\x88m_nH\x02\x00' + b'\xe3\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x05\x00\x00\x00@\x00\x00\x00s\x1c\x00\x00\x00e\x00d\x00\xa0\x01d\x01d\x02\x84\x00d\x03D\x00\x83\x01\xa1\x01\x83\x01\x01\x00d\x04S\x00)\x05\xda\x00c\x01\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x02\x00\x00\x00\x03\x00\x00\x00c\x00\x00\x00s\x16\x00\x00\x00|\x00]\x0e}\x01t\x00|\x01\x83\x01V\x00\x01\x00q\x02d\x00S\x00)\x01N)\x01\xda\x03chr)\x02\xda\x02.0\xda\x01_\xa9\x00r\x05\x00\x00\x00\xfa\x08<EzzKun>\xda\t<genexpr>\x01\x00\x00\x00s\x04\x00\x00\x00\x04\x00\x02\x00r\x07\x00\x00\x00(\xc3#\x00\x00\xe9#\x00\x00\x00\xe9!\x00\x00\x00\xe9/\x00\x00\x00\xe9u\x00\x00\x00\xe9s\x00\x00\x00\xe9r\x00\x00\x00r\n\x00\x00\x00\xe9b\x00\x00\x00\xe9i\x00\x00\x00\xe9n\x00\x00\x00r\n\x00\x00\x00\xe9e\x00\x00\x00r\x10\x00\x00\x00\xe9v\x00\x00\x00\xe9 \x00\x00\x00\xe9p\x00\x00\x00\xe9y\x00\x00\x00\xe9t\x00\x00\x00\xe9h\x00\x00\x00\xe9o\x00\x00\x00r\x10\x00\x00\x00\xe93\x00\x00\x00\xe9\n\x00\x00\x00r\x08\x00\x00\x00r\x13\x00\x00\x00\xe9A\x00\x00\x00r\x0b\x00\x00\x00r\x16\x00\x00\x00r\x17\x00\x00\x00r\x18\x00\x00\x00r\r\x00\x00\x00r\x13\x00\x00\x00\xe9:\x00\x00\x00r\x13\x00\x00\x00\xe9z\x00\x00\x00r\x11\x00\x00\x00r\x16\x00\x00\x00r\x16\x00\x00\x00\xe9a\x00\x00\x00\xe9m\x00\x00\x00r\x0b\x00\x00\x00r\x0c\x00\x00\x00r\x1a\x00\x00\x00r\x08\x00\x00\x00r\x13\x00\x00\x00\xe9G\x00\x00\x00r\x0f\x00\x00\x00r\x16\x00\x00\x00r\x17\x00\x00\x00r\x0b\x00\x00\x00r\x0e\x00\x00\x00r\x13\x00\x00\x00r\x1c\x00\x00\x00r\x13\x00\x00\x00\xe9Z\x00\x00\x00r\x11\x00\x00\x00r\x16\x00\x00\x00r\x16\x00\x00\x00r\x1e\x00\x00\x00r\x1f\x00\x00\x00r\x0b\x00\x00\x00r\x0c\x00\x00\x00r\x1a\x00\x00\x00r\x08\x00\x00\x00r\x13\x00\x00\x00\xe9F\x00\x00\x00r\x1e\x00\x00\x00\xe9c\x00\x00\x00r\x11\x00\x00\x00r\x0e\x00\x00\x00r\x18\x00\x00\x00r\x18\x00\x00\x00\xe9k\x00\x00\x00r\x13\x00\x00\x00r\x1c\x00\x00\x00r\x13\x00\x00\x00\xe9f\x00\x00\x00r\x0e\x00\x00\x00\xe9.\x00\x00\x00r\x1f\x00\x00\x00r\x11\x00\x00\x00r\n\x00\x00\x00r\x1d\x00\x00\x00r\x11\x00\x00\x00r\x16\x00\x00\x00r\x16\x00\x00\x00r\x0f\x00\x00\x00\xe9d\x00\x00\x00r&\x00\x00\x00\xe91\x00\x00\x00r\x1a\x00\x00\x00r\x08\x00\x00\x00r\x13\x00\x00\x00\xe9T\x00\x00\x00r\x11\x00\x00\x00\xe9l\x00\x00\x00r\x11\x00\x00\x00\xe9g\x00\x00\x00r\r\x00\x00\x00r\x1e\x00\x00\x00r\x1f\x00\x00\x00r\x13\x00\x00\x00r\x1c\x00\x00\x00r\x13\x00\x00\x00r\x16\x00\x00\x00r&\x00\x00\x00r\x1f\x00\x00\x00r\x11\x00\x00\x00r\n\x00\x00\x00r\x1d\x00\x00\x00r\x11\x00\x00\x00r\x16\x00\x00\x00r\x16\x00\x00\x00r\x1e\x00\x00\x00r\x1f\x00\x00\x00r\x0b\x00\x00\x00r\x0c\x00\x00\x00r\x1a\x00\x00\x00r\x08\x00\x00\x00r\x13\x00\x00\x00r\r\x00\x00\x00r\x11\x00\x00\x00r#\x00\x00\x00r\x18\x00\x00\x00r\'\x00\x00\x00r\x11\x00\x00\x00\xe9?\x00\x00\x00\xe9,\x00\x00\x00r\x13\x00\x00\x00r\x0f\x00\x00\x00r\x10\x00\x00\x00r#\x00\x00\x00r*\x00\x00\x00r\x0b\x00\x00\x00r\'\x00\x00\x00r\x11\x00\x00\x00r\x13\x00\x00\x00r\x16\x00\x00\x00r\x17\x00\x00\x00r\x11\x00\x00\x00r\x13\x00\x00\x00r\x0c\x00\x00\x00r\x18\x00\x00\x00r\x0b\x00\x00\x00r\r\x00\x00\x00r#\x00\x00\x00r\x11\x00\x00\x00r\t\x00\x00\x00r\t\x00\x00\x00r\x1a\x00\x00\x00r\x0f\x00\x00\x00r\x1f\x00\x00\x00r\x14\x00\x00\x00r\x18\x00\x00\x00r\r\x00\x00\x00r\x16\x00\x00\x00r\x13\x00\x00\x00r\r\x00\x00\x00r\x11\x00\x00\x00r\x1a\x00\x00\x00r\x0f\x00\x00\x00r\x1f\x00\x00\x00r\x14\x00\x00\x00r\x18\x00\x00\x00r\r\x00\x00\x00r\x16\x00\x00\x00r\x13\x00\x00\x00r\x18\x00\x00\x00r\x0c\x00\x00\x00r\x1a\x00\x00\x00r\x0f\x00\x00\x00r\x1f\x00\x00\x00r\x14\x00\x00\x00r\x18\x00\x00\x00r\r\x00\x00\x00r\x16\x00\x00\x00r\x13\x00\x00\x00r\x0c\x00\x00\x00r\x15\x00\x00\x00r\x0c\x00\x00\x00r\x1a\x00\x00\x00r\x0f\x00\x00\x00r\x1f\x00\x00\x00r\x14\x00\x00\x00r\x18\x00\x00\x00r\r\x00\x00\x00r\x16\x00\x00\x00r\x13\x00\x00\x00r\x0c\x00\x00\x00r\x17\x00\x00\x00r\x0b\x00\x00\x00r\x16\x00\x00\x00r\x0f\x00\x00\x00r*\x00\x00\x00r\x1a\x00\x00\x00r\x0f\x00\x00\x00r\x1f\x00\x00\x00r\x14\x00\x00\x00r\x18\x00\x00\x00r\r\x00\x00\x00r\x16\x00\x00\x00r\x13\x00\x00\x00r\r\x00\x00\x00r\x11\x00\x00\x00\xe9q\x00\x00\x00r\x0b\x00\x00\x00r\x11\x00\x00\x00r\x0c\x00\x00\x00r\x16\x00\x00\x00r\x0c\x00\x00\x00r\x1a\x00\x00\x00r%\x00\x00\x00r\r\x00\x00\x00r\x18\x00\x00\x00r\x1f\x00\x00\x00r\x13\x00\x00\x00r*\x00\x00\x00r\x0f\x00\x00\x00r\x0e\x00\x00\x00r\x13\x00\x00\x00r\x0f\x00\x00\x00r\x1f\x00\x00\x00r\x14\x00\x00\x00r\x18\x00\x00\x00r\r\x00\x00\x00r\x16\x00\x00\x00r\x13\x00\x00\x00\xe9M\x00\x00\x00r\x1e\x00\x00\x00r\x0f\x00\x00\x00r\x10\x00\x00\x00r\x1a\x00\x00\x00r%\x00\x00\x00r\r\x00\x00\x00r\x18\x00\x00\x00r\x1f\x00\x00\x00r\x13\x00\x00\x00r+\x00\x00\x00r\x11\x00\x00\x00r\x16\x00\x00\x00r\x14\x00\x00\x00r\x1e\x00\x00\x00r\x0c\x00\x00\x00r\x0c\x00\x00\x00r\x13\x00\x00\x00r\x0f\x00\x00\x00r\x1f\x00\x00\x00r\x14\x00\x00\x00r\x18\x00\x00\x00r\r\x00\x00\x00r\x16\x00\x00\x00r\x13\x00\x00\x00r+\x00\x00\x00r\x11\x00\x00\x00r\x16\x00\x00\x00r\x14\x00\x00\x00r\x1e\x00\x00\x00r\x0c\x00\x00\x00r\x0c\x00\x00\x00r\x1a\x00\x00\x00r%\x00\x00\x00r\r\x00\x00\x00r\x18\x00\x00\x00r\x1f\x00\x00\x00r\x13\x00\x00\x00r\x0b\x00\x00\x00r\x0c\x00\x00\x00r\r\x00\x00\x00r\x13\x00\x00\x00r\x0f\x00\x00\x00r\x1f\x00\x00\x00r\x14\x00\x00\x00r\x18\x00\x00\x00r\r\x00\x00\x00r\x16\x00\x00\x00r\x13\x00\x00\x00r*\x00\x00\x00r\x18\x00\x00\x00r+\x00\x00\x00r\x0f\x00\x00\x00r\x10\x00\x00\x00r-\x00\x00\x00r\x13\x00\x00\x00r\x0e\x00\x00\x00r\x1e\x00\x00\x00r\x10\x00\x00\x00r\x10\x00\x00\x00r\x11\x00\x00\x00r\r\x00\x00\x00r-\x00\x00\x00r\x13\x00\x00\x00r\x0c\x00\x00\x00r\x16\x00\x00\x00r\x1e\x00\x00\x00r\r\x00\x00\x00r\x16\x00\x00\x00r\x1a\x00\x00\x00r%\x00\x00\x00r\r\x00\x00\x00r\x18\x00\x00\x00r\x1f\x00\x00\x00r\x13\x00\x00\x00r*\x00\x00\x00r\x0f\x00\x00\x00r\x0e\x00\x00\x00r&\x00\x00\x00r\x14\x00\x00\x00r\x1e\x00\x00\x00r\r\x00\x00\x00r\x0c\x00\x00\x00r\x0f\x00\x00\x00r\x10\x00\x00\x00r+\x00\x00\x00r\x13\x00\x00\x00r\x0f\x00\x00\x00r\x1f\x00\x00\x00r\x14\x00\x00\x00r\x18\x00\x00\x00r\r\x00\x00\x00r\x16\x00\x00\x00r\x13\x00\x00\x00r\x0b\x00\x00\x00r\r\x00\x00\x00r*\x00\x00\x00\xe9_\x00\x00\x00r%\x00\x00\x00r\x0f\x00\x00\x00r\x10\x00\x00\x00r\'\x00\x00\x00r-\x00\x00\x00r\x13\x00\x00\x00r\x14\x00\x00\x00r\x1e\x00\x00\x00r\r\x00\x00\x00r\x0c\x00\x00\x00r\x11\x00\x00\x00r\r\x00\x00\x00r\x1a\x00\x00\x00\xe9D\x00\x00\x00r\x1b\x00\x00\x00r)\x00\x00\x00r\x1b\x00\x00\x00r\x13\x00\x00\x00\xe9=\x00\x00\x00r\x13\x00\x00\x00\xe9N\x00\x00\x00r\x18\x00\x00\x00r\x10\x00\x00\x00r\x11\x00\x00\x00r\x1a\x00\x00\x00r\x1a\x00\x00\x00r\'\x00\x00\x00r\x11\x00\x00\x00r%\x00\x00\x00r\x13\x00\x00\x00r\x1f\x00\x00\x00r\x11\x00\x00\x00r\x10\x00\x00\x00r\x0b\x00\x00\x00\xe9(\x00\x00\x00\xe9)\x00\x00\x00r\x1c\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x18\x00\x00\x00r\x0c\x00\x00\x00r&\x00\x00\x00r\x0c\x00\x00\x00r\x15\x00\x00\x00r\x0c\x00\x00\x00r\x16\x00\x00\x00r\x11\x00\x00\x00r\x1f\x00\x00\x00r4\x00\x00\x00\xe9"\x00\x00\x00r#\x00\x00\x00r*\x00\x00\x00r\x11\x00\x00\x00r\x1e\x00\x00\x00r\r\x00\x00\x00r6\x00\x00\x00r5\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x0e\x00\x00\x00r\x1e\x00\x00\x00r\x10\x00\x00\x00r\x10\x00\x00\x00r\x11\x00\x00\x00r\r\x00\x00\x00r&\x00\x00\x00r\x0e\x00\x00\x00r\x1e\x00\x00\x00r\x10\x00\x00\x00r\x10\x00\x00\x00r\x11\x00\x00\x00r\r\x00\x00\x00r4\x00\x00\x00r5\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x14\x00\x00\x00r\r\x00\x00\x00r\x0f\x00\x00\x00r\x10\x00\x00\x00r\x16\x00\x00\x00r4\x00\x00\x00r6\x00\x00\x00\xe9\\\x00\x00\x00r\x10\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\t\x00\x00\x00r\x13\x00\x00\x00\xe9L\x00\x00\x00r\x18\x00\x00\x00r+\x00\x00\x00r\x0f\x00\x00\x00r\x10\x00\x00\x00r\x13\x00\x00\x00r\x1e\x00\x00\x00r\x0c\x00\x00\x00r\x13\x00\x00\x00r\x1c\x00\x00\x00r\x13\x00\x00\x00r6\x00\x00\x00r\x13\x00\x00\x00\xe9+\x00\x00\x00r\x13\x00\x00\x00r1\x00\x00\x00r\x1b\x00\x00\x00r)\x00\x00\x00r\x1b\x00\x00\x00r5\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x14\x00\x00\x00r\r\x00\x00\x00r\x0f\x00\x00\x00r\x10\x00\x00\x00r\x16\x00\x00\x00r4\x00\x00\x00r6\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\t\x00\x00\x00r\x13\x00\x00\x00\xe9E\x00\x00\x00\xe9x\x00\x00\x00r\x14\x00\x00\x00r\x0f\x00\x00\x00r\r\x00\x00\x00r\x11\x00\x00\x00r\'\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x1c\x00\x00\x00r\x13\x00\x00\x00\xe9%\x00\x00\x00r\x0c\x00\x00\x00r6\x00\x00\x00r<\x00\x00\x00r\x13\x00\x00\x00r\x0b\x00\x00\x00r\x0c\x00\x00\x00r\x11\x00\x00\x00r\r\x00\x00\x00r0\x00\x00\x00r*\x00\x00\x00r\x18\x00\x00\x00r+\x00\x00\x00r+\x00\x00\x00r\x11\x00\x00\x00r\'\x00\x00\x00\xe9[\x00\x00\x00r6\x00\x00\x00r\x11\x00\x00\x00r;\x00\x00\x00r\x14\x00\x00\x00r\x0f\x00\x00\x00r\r\x00\x00\x00r\x11\x00\x00\x00r\'\x00\x00\x00r6\x00\x00\x00\xe9]\x00\x00\x00r5\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x0e\x00\x00\x00r\x1e\x00\x00\x00r\x10\x00\x00\x00r\x10\x00\x00\x00r\x11\x00\x00\x00r\r\x00\x00\x00r&\x00\x00\x00r\x1f\x00\x00\x00r\x11\x00\x00\x00r\x10\x00\x00\x00r\x0b\x00\x00\x00r4\x00\x00\x00r5\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x14\x00\x00\x00r\r\x00\x00\x00r\x0f\x00\x00\x00r\x10\x00\x00\x00r\x16\x00\x00\x00r4\x00\x00\x00r5\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x1d\x00\x00\x00r\x11\x00\x00\x00r\x16\x00\x00\x00r\x13\x00\x00\x00r2\x00\x00\x00r\x13\x00\x00\x00r\x0f\x00\x00\x00r\x10\x00\x00\x00r\x14\x00\x00\x00r\x0b\x00\x00\x00r\x16\x00\x00\x00r4\x00\x00\x00r6\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00\xe9{\x00\x00\x00r\x13\x00\x00\x00r,\x00\x00\x00r\x13\x00\x00\x00\xe9}\x00\x00\x00r\x13\x00\x00\x00r \x00\x00\x00r\x11\x00\x00\x00r\x16\x00\x00\x00r\x13\x00\x00\x00r\x0b\x00\x00\x00r\x0c\x00\x00\x00r\x11\x00\x00\x00r\r\x00\x00\x00r\x13\x00\x00\x00r\x1c\x00\x00\x00r\x13\x00\x00\x00r6\x00\x00\x00r5\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x0f\x00\x00\x00r%\x00\x00\x00r\x13\x00\x00\x00r\x1d\x00\x00\x00r\x11\x00\x00\x00r\x16\x00\x00\x00r\x13\x00\x00\x00r2\x00\x00\x00r2\x00\x00\x00r\x13\x00\x00\x00r6\x00\x00\x00r6\x00\x00\x00r\x1c\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x1f\x00\x00\x00r\x11\x00\x00\x00r\x10\x00\x00\x00r\x0b\x00\x00\x00r4\x00\x00\x00r5\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x11\x00\x00\x00r*\x00\x00\x00r\x0f\x00\x00\x00r%\x00\x00\x00r\x13\x00\x00\x00r\x1d\x00\x00\x00r\x11\x00\x00\x00r\x16\x00\x00\x00r\x13\x00\x00\x00r2\x00\x00\x00r2\x00\x00\x00r\x13\x00\x00\x00r6\x00\x00\x00r(\x00\x00\x00r6\x00\x00\x00r\x1c\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x0b\x00\x00\x00r\x0c\x00\x00\x00r\x11\x00\x00\x00r\r\x00\x00\x00r\x0c\x00\x00\x00r\x13\x00\x00\x00r2\x00\x00\x00r\x13\x00\x00\x00r\r\x00\x00\x00r\x0b\x00\x00\x00r\x10\x00\x00\x00r&\x00\x00\x00r%\x00\x00\x00r\r\x00\x00\x00r\x0f\x00\x00\x00r\x11\x00\x00\x00r\x10\x00\x00\x00r\'\x00\x00\x00r*\x00\x00\x00r\x0f\x00\x00\x00r\x0c\x00\x00\x00r\x16\x00\x00\x00r4\x00\x00\x00r\x0b\x00\x00\x00r\r\x00\x00\x00r*\x00\x00\x00r0\x00\x00\x00r%\x00\x00\x00r\x0f\x00\x00\x00r\x10\x00\x00\x00r\'\x00\x00\x00r4\x00\x00\x00r\r\x00\x00\x00r\x0b\x00\x00\x00r\x10\x00\x00\x00r&\x00\x00\x00r\x14\x00\x00\x00r\x1e\x00\x00\x00r\r\x00\x00\x00r\x0c\x00\x00\x00r\x11\x00\x00\x00r\r\x00\x00\x00r&\x00\x00\x00r+\x00\x00\x00r\x11\x00\x00\x00r\x16\x00\x00\x00r4\x00\x00\x00r6\x00\x00\x00r\n\x00\x00\x00r\x14\x00\x00\x00r\r\x00\x00\x00r\x18\x00\x00\x00r%\x00\x00\x00r\x0f\x00\x00\x00r*\x00\x00\x00r\x11\x00\x00\x00r&\x00\x00\x00r\x14\x00\x00\x00r\x17\x00\x00\x00r\x14\x00\x00\x00r6\x00\x00\x00r5\x00\x00\x00r-\x00\x00\x00r\x13\x00\x00\x00\xe9\'\x00\x00\x00r%\x00\x00\x00r\r\x00\x00\x00r\x0f\x00\x00\x00r\x11\x00\x00\x00r\x10\x00\x00\x00r\'\x00\x00\x00r\x0c\x00\x00\x00r,\x00\x00\x00r*\x00\x00\x00r\x0c\x00\x00\x00r\x16\x00\x00\x00rA\x00\x00\x00r5\x00\x00\x00r5\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x14\x00\x00\x00r\r\x00\x00\x00r\x0f\x00\x00\x00r\x10\x00\x00\x00r\x16\x00\x00\x00r4\x00\x00\x00r5\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x0c\x00\x00\x00r\x16\x00\x00\x00r\x1e\x00\x00\x00r\r\x00\x00\x00r\x16\x00\x00\x00r&\x00\x00\x00r\x0c\x00\x00\x00r\x18\x00\x00\x00r\r\x00\x00\x00r\x16\x00\x00\x00r\x0f\x00\x00\x00r\x10\x00\x00\x00r+\x00\x00\x00r4\x00\x00\x00r\x0b\x00\x00\x00r\x0c\x00\x00\x00r\x11\x00\x00\x00r\r\x00\x00\x00r\x0c\x00\x00\x00r5\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x11\x00\x00\x00r*\x00\x00\x00r\x0f\x00\x00\x00r%\x00\x00\x00r\x13\x00\x00\x00r\x1d\x00\x00\x00r\x11\x00\x00\x00r\x16\x00\x00\x00r\x13\x00\x00\x00r2\x00\x00\x00r2\x00\x00\x00r\x13\x00\x00\x00r6\x00\x00\x00\xe92\x00\x00\x00r6\x00\x00\x00r\x1c\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x0b\x00\x00\x00r\r\x00\x00\x00r*\x00\x00\x00r\x13\x00\x00\x00r2\x00\x00\x00r\x13\x00\x00\x00r\x0f\x00\x00\x00r\x10\x00\x00\x00r\x14\x00\x00\x00r\x0b\x00\x00\x00r\x16\x00\x00\x00r4\x00\x00\x00r6\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r?\x00\x00\x00r\x13\x00\x00\x00r,\x00\x00\x00r\x13\x00\x00\x00r@\x00\x00\x00r\x13\x00\x00\x00r\x0b\x00\x00\x00r\r\x00\x00\x00r*\x00\x00\x00r\x13\x00\x00\x00r\x14\x00\x00\x00r\x18\x00\x00\x00r\x0c\x00\x00\x00r\x16\x00\x00\x00r\x13\x00\x00\x00r\x1c\x00\x00\x00r\x13\x00\x00\x00r6\x00\x00\x00r5\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x0f\x00\x00\x00r%\x00\x00\x00r\x13\x00\x00\x00r6\x00\x00\x00r\x17\x00\x00\x00r\x16\x00\x00\x00r\x16\x00\x00\x00r\x14\x00\x00\x00r\x0c\x00\x00\x00r\x1c\x00\x00\x00r\n\x00\x00\x00r\n\x00\x00\x00\xe9w\x00\x00\x00rC\x00\x00\x00rC\x00\x00\x00r&\x00\x00\x00r%\x00\x00\x00r\x1e\x00\x00\x00r#\x00\x00\x00r\x11\x00\x00\x00r\x0e\x00\x00\x00r\x18\x00\x00\x00r\x18\x00\x00\x00r$\x00\x00\x00r&\x00\x00\x00r#\x00\x00\x00r\x18\x00\x00\x00r\x1f\x00\x00\x00r6\x00\x00\x00r\x13\x00\x00\x00r\x0f\x00\x00\x00r\x10\x00\x00\x00r\x13\x00\x00\x00r\x0b\x00\x00\x00r\r\x00\x00\x00r*\x00\x00\x00r\x1c\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x0b\x00\x00\x00r\r\x00\x00\x00r*\x00\x00\x00r\x13\x00\x00\x00r2\x00\x00\x00r\x13\x00\x00\x00r\x0b\x00\x00\x00r\r\x00\x00\x00r*\x00\x00\x00r&\x00\x00\x00r\r\x00\x00\x00r\x11\x00\x00\x00r\x14\x00\x00\x00r*\x00\x00\x00r\x1e\x00\x00\x00r#\x00\x00\x00r\x11\x00\x00\x00r4\x00\x00\x00r6\x00\x00\x00r\x17\x00\x00\x00r\x16\x00\x00\x00r\x16\x00\x00\x00r\x14\x00\x00\x00r\x0c\x00\x00\x00r\x1c\x00\x00\x00r\n\x00\x00\x00r\n\x00\x00\x00rC\x00\x00\x00rC\x00\x00\x00rC\x00\x00\x00r&\x00\x00\x00r%\x00\x00\x00r\x1e\x00\x00\x00r#\x00\x00\x00r\x11\x00\x00\x00r\x0e\x00\x00\x00r\x18\x00\x00\x00r\x18\x00\x00\x00r$\x00\x00\x00r&\x00\x00\x00r#\x00\x00\x00r\x18\x00\x00\x00r\x1f\x00\x00\x00r6\x00\x00\x00r-\x00\x00\x00r\x13\x00\x00\x00r6\x00\x00\x00r6\x00\x00\x00r5\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x11\x00\x00\x00r*\x00\x00\x00r\x0f\x00\x00\x00r%\x00\x00\x00r\x13\x00\x00\x00r6\x00\x00\x00r\x17\x00\x00\x00r\x16\x00\x00\x00r\x16\x00\x00\x00r\x14\x00\x00\x00r\x0c\x00\x00\x00r\x1c\x00\x00\x00r\n\x00\x00\x00r\n\x00\x00\x00r\x1f\x00\x00\x00r&\x00\x00\x00r%\x00\x00\x00r\x1e\x00\x00\x00r#\x00\x00\x00r\x11\x00\x00\x00r\x0e\x00\x00\x00r\x18\x00\x00\x00r\x18\x00\x00\x00r$\x00\x00\x00r&\x00\x00\x00r#\x00\x00\x00r\x18\x00\x00\x00r\x1f\x00\x00\x00r6\x00\x00\x00r\x13\x00\x00\x00r\x0f\x00\x00\x00r\x10\x00\x00\x00r\x13\x00\x00\x00r\x0b\x00\x00\x00r\r\x00\x00\x00r*\x00\x00\x00r\x1c\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x0b\x00\x00\x00r\r\x00\x00\x00r*\x00\x00\x00r\x13\x00\x00\x00r2\x00\x00\x00r\x13\x00\x00\x00r\x0b\x00\x00\x00r\r\x00\x00\x00r*\x00\x00\x00r&\x00\x00\x00r\r\x00\x00\x00r\x11\x00\x00\x00r\x14\x00\x00\x00r*\x00\x00\x00r\x1e\x00\x00\x00r#\x00\x00\x00r\x11\x00\x00\x00r4\x00\x00\x00r6\x00\x00\x00r\x17\x00\x00\x00r\x16\x00\x00\x00r\x16\x00\x00\x00r\x14\x00\x00\x00r\x0c\x00\x00\x00r\x1c\x00\x00\x00r\n\x00\x00\x00r\n\x00\x00\x00r\x1f\x00\x00\x00r&\x00\x00\x00r%\x00\x00\x00r\x1e\x00\x00\x00r#\x00\x00\x00r\x11\x00\x00\x00r\x0e\x00\x00\x00r\x18\x00\x00\x00r\x18\x00\x00\x00r$\x00\x00\x00r&\x00\x00\x00r#\x00\x00\x00r\x18\x00\x00\x00r\x1f\x00\x00\x00r6\x00\x00\x00r-\x00\x00\x00r\x13\x00\x00\x00r6\x00\x00\x00r6\x00\x00\x00r5\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x11\x00\x00\x00r*\x00\x00\x00r\x0f\x00\x00\x00r%\x00\x00\x00r\x13\x00\x00\x00r6\x00\x00\x00r\x17\x00\x00\x00r\x16\x00\x00\x00r\x16\x00\x00\x00r\x14\x00\x00\x00r\x0c\x00\x00\x00r\x1c\x00\x00\x00r\n\x00\x00\x00r\n\x00\x00\x00r\x1f\x00\x00\x00r\x0e\x00\x00\x00r\x1e\x00\x00\x00r\x0c\x00\x00\x00r\x0f\x00\x00\x00r#\x00\x00\x00r&\x00\x00\x00r%\x00\x00\x00r\x1e\x00\x00\x00r#\x00\x00\x00r\x11\x00\x00\x00r\x0e\x00\x00\x00r\x18\x00\x00\x00r\x18\x00\x00\x00r$\x00\x00\x00r&\x00\x00\x00r#\x00\x00\x00r\x18\x00\x00\x00r\x1f\x00\x00\x00r6\x00\x00\x00r\x13\x00\x00\x00r\x0f\x00\x00\x00r\x10\x00\x00\x00r\x13\x00\x00\x00r\x0b\x00\x00\x00r\r\x00\x00\x00r*\x00\x00\x00r\x1c\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x0b\x00\x00\x00r\r\x00\x00\x00r*\x00\x00\x00r\x13\x00\x00\x00r2\x00\x00\x00r\x13\x00\x00\x00r\x0b\x00\x00\x00r\r\x00\x00\x00r*\x00\x00\x00r&\x00\x00\x00r\r\x00\x00\x00r\x11\x00\x00\x00r\x14\x00\x00\x00r*\x00\x00\x00r\x1e\x00\x00\x00r#\x00\x00\x00r\x11\x00\x00\x00r4\x00\x00\x00r6\x00\x00\x00r\x17\x00\x00\x00r\x16\x00\x00\x00r\x16\x00\x00\x00r\x14\x00\x00\x00r\x0c\x00\x00\x00r\x1c\x00\x00\x00r\n\x00\x00\x00r\n\x00\x00\x00r\x1f\x00\x00\x00r\x0e\x00\x00\x00r\x1e\x00\x00\x00r\x0c\x00\x00\x00r\x0f\x00\x00\x00r#\x00\x00\x00r&\x00\x00\x00r%\x00\x00\x00r\x1e\x00\x00\x00r#\x00\x00\x00r\x11\x00\x00\x00r\x0e\x00\x00\x00r\x18\x00\x00\x00r\x18\x00\x00\x00r$\x00\x00\x00r&\x00\x00\x00r#\x00\x00\x00r\x18\x00\x00\x00r\x1f\x00\x00\x00r6\x00\x00\x00r-\x00\x00\x00r\x13\x00\x00\x00r6\x00\x00\x00r6\x00\x00\x00r5\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x11\x00\x00\x00r*\x00\x00\x00r\x0c\x00\x00\x00r\x11\x00\x00\x00r\x1c\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x11\x00\x00\x00r;\x00\x00\x00r\x0f\x00\x00\x00r\x16\x00\x00\x00r4\x00\x00\x00r6\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r?\x00\x00\x00r\x13\x00\x00\x00r\t\x00\x00\x00r\x13\x00\x00\x00r@\x00\x00\x00r\x13\x00\x00\x00\xe9U\x00\x00\x00r\r\x00\x00\x00r*\x00\x00\x00r\x13\x00\x00\x00r\x0f\x00\x00\x00r\x10\x00\x00\x00r\x12\x00\x00\x00r\x1e\x00\x00\x00r*\x00\x00\x00r\x0f\x00\x00\x00r\'\x00\x00\x00r6\x00\x00\x00r5\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x0f\x00\x00\x00r%\x00\x00\x00r\x13\x00\x00\x00rA\x00\x00\x00r\n\x00\x00\x00r\x12\x00\x00\x00r\x0f\x00\x00\x00r\'\x00\x00\x00r\x11\x00\x00\x00r\x18\x00\x00\x00r\x0c\x00\x00\x00r\n\x00\x00\x00rA\x00\x00\x00r\x13\x00\x00\x00r\x0f\x00\x00\x00r\x10\x00\x00\x00r\x13\x00\x00\x00r\x0b\x00\x00\x00r\r\x00\x00\x00r*\x00\x00\x00r\x1c\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x0b\x00\x00\x00r\r\x00\x00\x00r*\x00\x00\x00r\x13\x00\x00\x00r2\x00\x00\x00r\x13\x00\x00\x00r\x0b\x00\x00\x00r\r\x00\x00\x00r*\x00\x00\x00r0\x00\x00\x00r%\x00\x00\x00r\x0f\x00\x00\x00r\x10\x00\x00\x00r\'\x00\x00\x00r4\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\r\x00\x00\x00r\x0b\x00\x00\x00r\x10\x00\x00\x00r&\x00\x00\x00r\x14\x00\x00\x00r\x1e\x00\x00\x00r\r\x00\x00\x00r\x0c\x00\x00\x00r\x11\x00\x00\x00r\r\x00\x00\x00r&\x00\x00\x00r+\x00\x00\x00r\x11\x00\x00\x00r\x16\x00\x00\x00r4\x00\x00\x00rA\x00\x00\x00r\n\x00\x00\x00rC\x00\x00\x00r\x1e\x00\x00\x00r\x16\x00\x00\x00r#\x00\x00\x00r\x17\x00\x00\x00r\n\x00\x00\x00r,\x00\x00\x00r\x12\x00\x00\x00r2\x00\x00\x00rA\x00\x00\x00r\x13\x00\x00\x00r9\x00\x00\x00r\x13\x00\x00\x00r\x0c\x00\x00\x00r\x16\x00\x00\x00r\r\x00\x00\x00r4\x00\x00\x00r\r\x00\x00\x00r\x11\x00\x00\x00r&\x00\x00\x00r%\x00\x00\x00r\x0f\x00\x00\x00r\x10\x00\x00\x00r\'\x00\x00\x00r\x1e\x00\x00\x00r*\x00\x00\x00r*\x00\x00\x00r4\x00\x00\x00rA\x00\x00\x00r4\x00\x00\x00r7\x00\x00\x00r\'\x00\x00\x00r9\x00\x00\x00r5\x00\x00\x00rA\x00\x00\x00r-\x00\x00\x00r\x13\x00\x00\x00r\x0b\x00\x00\x00r\r\x00\x00\x00r*\x00\x00\x00r&\x00\x00\x00r\x0c\x00\x00\x00r\x14\x00\x00\x00r*\x00\x00\x00r\x0f\x00\x00\x00r\x16\x00\x00\x00r4\x00\x00\x00rA\x00\x00\x00r\x12\x00\x00\x00r\x0f\x00\x00\x00r\'\x00\x00\x00r\x11\x00\x00\x00r\x18\x00\x00\x00r\x0c\x00\x00\x00r\n\x00\x00\x00rA\x00\x00\x00r5\x00\x00\x00r=\x00\x00\x00r(\x00\x00\x00r>\x00\x00\x00r5\x00\x00\x00r=\x00\x00\x00\xe90\x00\x00\x00r>\x00\x00\x00r5\x00\x00\x00r\x13\x00\x00\x00r9\x00\x00\x00r\x13\x00\x00\x00rA\x00\x00\x00\xe9&\x00\x00\x00r0\x00\x00\x00r\r\x00\x00\x00r\'\x00\x00\x00r\r\x00\x00\x00rA\x00\x00\x00r5\x00\x00\x00r-\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00rA\x00\x00\x00r\x08\x00\x00\x00r%\x00\x00\x00r\x18\x00\x00\x00r\x18\x00\x00\x00r\x16\x00\x00\x00r\x11\x00\x00\x00r\r\x00\x00\x00r0\x00\x00\x00r\x1e\x00\x00\x00r#\x00\x00\x00r\x16\x00\x00\x00r\x0f\x00\x00\x00r\x18\x00\x00\x00r\x10\x00\x00\x00r0\x00\x00\x00r*\x00\x00\x00r\x0f\x00\x00\x00r\x0c\x00\x00\x00r\x16\x00\x00\x00rA\x00\x00\x00r5\x00\x00\x00r=\x00\x00\x00rE\x00\x00\x00r>\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r*\x00\x00\x00r\x0f\x00\x00\x00r$\x00\x00\x00r\x11\x00\x00\x00r\x13\x00\x00\x00r2\x00\x00\x00r\x13\x00\x00\x00r\r\x00\x00\x00r\x0b\x00\x00\x00r\x10\x00\x00\x00r&\x00\x00\x00r\x14\x00\x00\x00r\x1e\x00\x00\x00r\r\x00\x00\x00r\x0c\x00\x00\x00r\x11\x00\x00\x00r\r\x00\x00\x00r&\x00\x00\x00r+\x00\x00\x00r\x11\x00\x00\x00r\x16\x00\x00\x00r4\x00\x00\x00r\x0b\x00\x00\x00r\r\x00\x00\x00r*\x00\x00\x00r5\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x16\x00\x00\x00r\r\x00\x00\x00r\x15\x00\x00\x00r\x1c\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x0b\x00\x00\x00r\r\x00\x00\x00r*\x00\x00\x00r\x13\x00\x00\x00r2\x00\x00\x00r\x13\x00\x00\x00r\x0b\x00\x00\x00r\r\x00\x00\x00r*\x00\x00\x00r0\x00\x00\x00r%\x00\x00\x00r\x0f\x00\x00\x00r\x10\x00\x00\x00r\'\x00\x00\x00r4\x00\x00\x00r*\x00\x00\x00r\x0f\x00\x00\x00r$\x00\x00\x00r\x11\x00\x00\x00r-\x00\x00\x00r\x13\x00\x00\x00rA\x00\x00\x00r\x0e\x00\x00\x00r\r\x00\x00\x00r\x18\x00\x00\x00rC\x00\x00\x00r\x0c\x00\x00\x00r\x11\x00\x00\x00r\r\x00\x00\x00rA\x00\x00\x00r5\x00\x00\x00r=\x00\x00\x00rE\x00\x00\x00r>\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x11\x00\x00\x00r;\x00\x00\x00r#\x00\x00\x00r\x11\x00\x00\x00r\x14\x00\x00\x00r\x16\x00\x00\x00r\x13\x00\x00\x00\xe9I\x00\x00\x00r\x10\x00\x00\x00r\'\x00\x00\x00r\x11\x00\x00\x00r;\x00\x00\x00r:\x00\x00\x00r\r\x00\x00\x00r\r\x00\x00\x00r\x18\x00\x00\x00r\r\x00\x00\x00r\x1c\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x11\x00\x00\x00r;\x00\x00\x00r\x0f\x00\x00\x00r\x16\x00\x00\x00r4\x00\x00\x00r6\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r?\x00\x00\x00r\x13\x00\x00\x00r\t\x00\x00\x00r\x13\x00\x00\x00r@\x00\x00\x00r\x13\x00\x00\x00r\x0f\x00\x00\x00r\x10\x00\x00\x00r\x12\x00\x00\x00r\x1e\x00\x00\x00r*\x00\x00\x00r\x0f\x00\x00\x00r\'\x00\x00\x00r\x13\x00\x00\x00r\x0b\x00\x00\x00r\r\x00\x00\x00r*\x00\x00\x00r6\x00\x00\x00r5\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x0b\x00\x00\x00r\x0c\x00\x00\x00r\x11\x00\x00\x00r\r\x00\x00\x00r\x0c\x00\x00\x00r\x13\x00\x00\x00r2\x00\x00\x00r\x13\x00\x00\x00r\r\x00\x00\x00r\x0b\x00\x00\x00r\x10\x00\x00\x00r&\x00\x00\x00r*\x00\x00\x00r\x0f\x00\x00\x00r$\x00\x00\x00r\x11\x00\x00\x00r\x0c\x00\x00\x00r4\x00\x00\x00r\x0b\x00\x00\x00r\r\x00\x00\x00r*\x00\x00\x00r5\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x14\x00\x00\x00r\r\x00\x00\x00r\x0f\x00\x00\x00r\x10\x00\x00\x00r\x16\x00\x00\x00r4\x00\x00\x00r5\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x0f\x00\x00\x00r%\x00\x00\x00r\x13\x00\x00\x00r*\x00\x00\x00r\x11\x00\x00\x00r\x10\x00\x00\x00r4\x00\x00\x00r\x0b\x00\x00\x00r\x0c\x00\x00\x00r\x11\x00\x00\x00r\r\x00\x00\x00r\x0c\x00\x00\x00r5\x00\x00\x00r\x13\x00\x00\x00r\t\x00\x00\x00r2\x00\x00\x00r\x13\x00\x00\x00rE\x00\x00\x00r\x1c\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x0c\x00\x00\x00r\x16\x00\x00\x00r\x1e\x00\x00\x00r\r\x00\x00\x00r\x16\x00\x00\x00r&\x00\x00\x00r\x0c\x00\x00\x00r\x18\x00\x00\x00r\r\x00\x00\x00r\x16\x00\x00\x00r\x0f\x00\x00\x00r\x10\x00\x00\x00r+\x00\x00\x00r4\x00\x00\x00r\x0b\x00\x00\x00r\x0c\x00\x00\x00r\x11\x00\x00\x00r\r\x00\x00\x00r\x0c\x00\x00\x00r5\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x11\x00\x00\x00r*\x00\x00\x00r\x0c\x00\x00\x00r\x11\x00\x00\x00r\x1c\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r+\x00\x00\x00r\x11\x00\x00\x00r\x16\x00\x00\x00r\x14\x00\x00\x00r\x1e\x00\x00\x00r\x0c\x00\x00\x00r\x0c\x00\x00\x00r4\x00\x00\x00rA\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r?\x00\x00\x00r\x13\x00\x00\x00r\t\x00\x00\x00r\x13\x00\x00\x00r@\x00\x00\x00r\x13\x00\x00\x00\xe9C\x00\x00\x00r\x1e\x00\x00\x00r\x10\x00\x00\x00r7\x00\x00\x00rA\x00\x00\x00r\x16\x00\x00\x00r\x13\x00\x00\x00r\'\x00\x00\x00r\x0b\x00\x00\x00r\x1f\x00\x00\x00r\x14\x00\x00\x00r\x13\x00\x00\x00r\x0b\x00\x00\x00r\x0c\x00\x00\x00r\x11\x00\x00\x00r\r\x00\x00\x00r\x0c\x00\x00\x00r\x13\x00\x00\x00r%\x00\x00\x00r\r\x00\x00\x00r\x18\x00\x00\x00r\x1f\x00\x00\x00r\x13\x00\x00\x00r*\x00\x00\x00r\x0f\x00\x00\x00r\x10\x00\x00\x00r$\x00\x00\x00r&\x00\x00\x00r\x13\x00\x00\x00r:\x00\x00\x00r\x10\x00\x00\x00r\x16\x00\x00\x00r\x11\x00\x00\x00r\r\x00\x00\x00r&\x00\x00\x00r&\x00\x00\x00r&\x00\x00\x00rA\x00\x00\x00r5\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x1f\x00\x00\x00r\x1e\x00\x00\x00r\x0f\x00\x00\x00r\x10\x00\x00\x00r4\x00\x00\x00r5\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x11\x00\x00\x00r*\x00\x00\x00r\x0f\x00\x00\x00r%\x00\x00\x00r\x13\x00\x00\x00r\x1d\x00\x00\x00r\x11\x00\x00\x00r\x16\x00\x00\x00r\x13\x00\x00\x00r2\x00\x00\x00r2\x00\x00\x00r\x13\x00\x00\x00r6\x00\x00\x00r\x19\x00\x00\x00r6\x00\x00\x00r\x1c\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x0b\x00\x00\x00r\x0c\x00\x00\x00r\x11\x00\x00\x00r\r\x00\x00\x00r\x10\x00\x00\x00r\x1e\x00\x00\x00r\x1f\x00\x00\x00r\x11\x00\x00\x00r\x13\x00\x00\x00r2\x00\x00\x00r\x13\x00\x00\x00r\r\x00\x00\x00r\x0b\x00\x00\x00r\x10\x00\x00\x00r&\x00\x00\x00r\x0e\x00\x00\x00r\x15\x00\x00\x00r\x0c\x00\x00\x00r\x11\x00\x00\x00r\x1e\x00\x00\x00r\r\x00\x00\x00r#\x00\x00\x00r\x17\x00\x00\x00r4\x00\x00\x00r6\x00\x00\x00r\n\x00\x00\x00r\x0c\x00\x00\x00r\x11\x00\x00\x00r\x1e\x00\x00\x00r\r\x00\x00\x00r#\x00\x00\x00r\x17\x00\x00\x00r\n\x00\x00\x00r\x14\x00\x00\x00r\x11\x00\x00\x00r\x18\x00\x00\x00r\x14\x00\x00\x00r*\x00\x00\x00r\x11\x00\x00\x00r\n\x00\x00\x00r,\x00\x00\x00r.\x00\x00\x00r2\x00\x00\x00r6\x00\x00\x00r\x13\x00\x00\x00r9\x00\x00\x00r\x13\x00\x00\x00r\x0f\x00\x00\x00r\x10\x00\x00\x00r\x14\x00\x00\x00r\x0b\x00\x00\x00r\x16\x00\x00\x00r4\x00\x00\x00r6\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r?\x00\x00\x00r\x13\x00\x00\x00r,\x00\x00\x00r\x13\x00\x00\x00r@\x00\x00\x00r\x13\x00\x00\x00\xe9Q\x00\x00\x00r\x0b\x00\x00\x00r\x11\x00\x00\x00r\r\x00\x00\x00r\x15\x00\x00\x00r\x13\x00\x00\x00r\x1c\x00\x00\x00r\x13\x00\x00\x00r6\x00\x00\x00r5\x00\x00\x00r5\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x0f\x00\x00\x00r%\x00\x00\x00r\x13\x00\x00\x00r*\x00\x00\x00r\x11\x00\x00\x00r\x10\x00\x00\x00r4\x00\x00\x00r\x0b\x00\x00\x00r\x0c\x00\x00\x00r\x11\x00\x00\x00r\r\x00\x00\x00r\x10\x00\x00\x00r\x1e\x00\x00\x00r\x1f\x00\x00\x00r\x11\x00\x00\x00r5\x00\x00\x00r\x13\x00\x00\x00r2\x00\x00\x00r2\x00\x00\x00r\x13\x00\x00\x00rE\x00\x00\x00r\x1c\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r+\x00\x00\x00r\x11\x00\x00\x00r\x16\x00\x00\x00r\x14\x00\x00\x00r\x1e\x00\x00\x00r\x0c\x00\x00\x00r\x0c\x00\x00\x00r4\x00\x00\x00r6\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r?\x00\x00\x00r\x13\x00\x00\x00r\t\x00\x00\x00r\x13\x00\x00\x00r@\x00\x00\x00r\x13\x00\x00\x00rH\x00\x00\x00r\x1e\x00\x00\x00r\x10\x00\x00\x00rA\x00\x00\x00r\x16\x00\x00\x00r\x13\x00\x00\x00r\'\x00\x00\x00r\x0b\x00\x00\x00r\x1f\x00\x00\x00r\x14\x00\x00\x00r&\x00\x00\x00r\x13\x00\x00\x00\xe9P\x00\x00\x00r*\x00\x00\x00r\x11\x00\x00\x00r\x1e\x00\x00\x00r\x0c\x00\x00\x00r\x11\x00\x00\x00r\x13\x00\x00\x00r#\x00\x00\x00r\x17\x00\x00\x00r\x11\x00\x00\x00r#\x00\x00\x00r$\x00\x00\x00r\x13\x00\x00\x00r\x15\x00\x00\x00r\x18\x00\x00\x00r\x0b\x00\x00\x00r\r\x00\x00\x00r\x13\x00\x00\x00r\x1e\x00\x00\x00r#\x00\x00\x00r#\x00\x00\x00r\x18\x00\x00\x00r\x0b\x00\x00\x00r\x10\x00\x00\x00r\x16\x00\x00\x00r&\x00\x00\x00r\x13\x00\x00\x00r:\x00\x00\x00r\x10\x00\x00\x00r\x16\x00\x00\x00r\x11\x00\x00\x00r\r\x00\x00\x00r&\x00\x00\x00r&\x00\x00\x00r&\x00\x00\x00r6\x00\x00\x00r5\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x1f\x00\x00\x00r\x11\x00\x00\x00r\x10\x00\x00\x00r\x0b\x00\x00\x00r4\x00\x00\x00r5\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x0c\x00\x00\x00r\x16\x00\x00\x00r\x1e\x00\x00\x00r\r\x00\x00\x00r\x16\x00\x00\x00r&\x00\x00\x00r\x0c\x00\x00\x00r\x18\x00\x00\x00r\r\x00\x00\x00r\x16\x00\x00\x00r\x0f\x00\x00\x00r\x10\x00\x00\x00r+\x00\x00\x00r4\x00\x00\x00r\x0b\x00\x00\x00r\x0c\x00\x00\x00r\x11\x00\x00\x00r\r\x00\x00\x00r\x10\x00\x00\x00r\x1e\x00\x00\x00r\x1f\x00\x00\x00r\x11\x00\x00\x00r5\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x11\x00\x00\x00r*\x00\x00\x00r\x0f\x00\x00\x00r%\x00\x00\x00r\x13\x00\x00\x00r\x1d\x00\x00\x00r\x11\x00\x00\x00r\x16\x00\x00\x00r\x13\x00\x00\x00r2\x00\x00\x00r2\x00\x00\x00r\x13\x00\x00\x00r6\x00\x00\x00\xe94\x00\x00\x00r6\x00\x00\x00r\x1c\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x14\x00\x00\x00r\r\x00\x00\x00r\x0f\x00\x00\x00r\x10\x00\x00\x00r\x16\x00\x00\x00r4\x00\x00\x00r5\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r#\x00\x00\x00r\x0b\x00\x00\x00r\r\x00\x00\x00r\r\x00\x00\x00r\x11\x00\x00\x00r\x10\x00\x00\x00r\x16\x00\x00\x00r\x13\x00\x00\x00r2\x00\x00\x00r\x13\x00\x00\x00r=\x00\x00\x00r>\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x1e\x00\x00\x00r\x0c\x00\x00\x00r\x0b\x00\x00\x00r\x13\x00\x00\x00r2\x00\x00\x00r\x13\x00\x00\x00rE\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\r\x00\x00\x00r\x1e\x00\x00\x00rC\x00\x00\x00r\x13\x00\x00\x00r2\x00\x00\x00r\x13\x00\x00\x00r\r\x00\x00\x00r\x0b\x00\x00\x00r\x10\x00\x00\x00r&\x00\x00\x00r\x14\x00\x00\x00r\x1e\x00\x00\x00r\r\x00\x00\x00r\x0c\x00\x00\x00r\x11\x00\x00\x00r\r\x00\x00\x00r&\x00\x00\x00r+\x00\x00\x00r\x11\x00\x00\x00r\x16\x00\x00\x00r4\x00\x00\x00r6\x00\x00\x00r\n\x00\x00\x00r+\x00\x00\x00r\r\x00\x00\x00r\x18\x00\x00\x00r\x0b\x00\x00\x00r\x14\x00\x00\x00r\x0c\x00\x00\x00r\n\x00\x00\x00r,\x00\x00\x00r\x0c\x00\x00\x00r\x11\x00\x00\x00r\x11\x00\x00\x00r\x1f\x00\x00\x00r\x18\x00\x00\x00r\r\x00\x00\x00r\x11\x00\x00\x00r6\x00\x00\x00r5\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r%\x00\x00\x00r\x18\x00\x00\x00r\r\x00\x00\x00r\x13\x00\x00\x00r+\x00\x00\x00r\r\x00\x00\x00r\x18\x00\x00\x00r\x0b\x00\x00\x00r\x14\x00\x00\x00r\x13\x00\x00\x00r\x0f\x00\x00\x00r\x10\x00\x00\x00r\x13\x00\x00\x00r\x0b\x00\x00\x00r\r\x00\x00\x00r*\x00\x00\x00r0\x00\x00\x00r%\x00\x00\x00r\x0f\x00\x00\x00r\x10\x00\x00\x00r\'\x00\x00\x00r4\x00\x00\x00r\r\x00\x00\x00r\x1e\x00\x00\x00rC\x00\x00\x00r-\x00\x00\x00r\x13\x00\x00\x00r6\x00\x00\x00r+\x00\x00\x00r\r\x00\x00\x00r\x18\x00\x00\x00r\x0b\x00\x00\x00r\x14\x00\x00\x00r\x0c\x00\x00\x00r6\x00\x00\x00r-\x00\x00\x00r\x13\x00\x00\x00r\x16\x00\x00\x00r\x11\x00\x00\x00r;\x00\x00\x00r\x16\x00\x00\x00r2\x00\x00\x00r)\x00\x00\x00r\r\x00\x00\x00r\x0b\x00\x00\x00r\x11\x00\x00\x00r5\x00\x00\x00r\x1c\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x0f\x00\x00\x00r%\x00\x00\x00r\x13\x00\x00\x00r6\x00\x00\x00r#\x00\x00\x00r\x1e\x00\x00\x00r\x16\x00\x00\x00r\x11\x00\x00\x00r+\x00\x00\x00r\x18\x00\x00\x00r\r\x00\x00\x00r\x15\x00\x00\x00r6\x00\x00\x00r\x13\x00\x00\x00r\x0f\x00\x00\x00r\x10\x00\x00\x00r\x13\x00\x00\x00r\x0c\x00\x00\x00r\x16\x00\x00\x00r\r\x00\x00\x00r4\x00\x00\x00r+\x00\x00\x00r\r\x00\x00\x00r\x18\x00\x00\x00r\x0b\x00\x00\x00r\x14\x00\x00\x00r=\x00\x00\x00r6\x00\x00\x00r\x0b\x00\x00\x00r\r\x00\x00\x00r*\x00\x00\x00r6\x00\x00\x00r>\x00\x00\x00r5\x00\x00\x00r\x13\x00\x00\x00r\x18\x00\x00\x00r\r\x00\x00\x00r\x13\x00\x00\x00r6\x00\x00\x00r#\x00\x00\x00r\r\x00\x00\x00r\x11\x00\x00\x00r\x1e\x00\x00\x00r\x16\x00\x00\x00r\x11\x00\x00\x00r6\x00\x00\x00r\x13\x00\x00\x00r\x0f\x00\x00\x00r\x10\x00\x00\x00r\x13\x00\x00\x00r\x0c\x00\x00\x00r\x16\x00\x00\x00r\r\x00\x00\x00r4\x00\x00\x00r+\x00\x00\x00r\r\x00\x00\x00r\x18\x00\x00\x00r\x0b\x00\x00\x00r\x14\x00\x00\x00r=\x00\x00\x00r6\x00\x00\x00r\x0b\x00\x00\x00r\r\x00\x00\x00r*\x00\x00\x00r6\x00\x00\x00r>\x00\x00\x00r5\x00\x00\x00r\x1c\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r#\x00\x00\x00r\x18\x00\x00\x00r\x10\x00\x00\x00r\x16\x00\x00\x00r\x0f\x00\x00\x00r\x10\x00\x00\x00r\x0b\x00\x00\x00r\x11\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x11\x00\x00\x00r*\x00\x00\x00r\x0c\x00\x00\x00r\x11\x00\x00\x00r\x1c\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r#\x00\x00\x00r\x0b\x00\x00\x00r\r\x00\x00\x00r\r\x00\x00\x00r\x11\x00\x00\x00r\x10\x00\x00\x00r\x16\x00\x00\x00r&\x00\x00\x00r\x1e\x00\x00\x00r\x14\x00\x00\x00r\x14\x00\x00\x00r\x11\x00\x00\x00r\x10\x00\x00\x00r\'\x00\x00\x00r4\x00\x00\x00r+\x00\x00\x00r\r\x00\x00\x00r\x18\x00\x00\x00r\x0b\x00\x00\x00r\x14\x00\x00\x00r=\x00\x00\x00r6\x00\x00\x00r\x0b\x00\x00\x00r\r\x00\x00\x00r*\x00\x00\x00r6\x00\x00\x00r>\x00\x00\x00r&\x00\x00\x00r\r\x00\x00\x00r\x11\x00\x00\x00r\x14\x00\x00\x00r*\x00\x00\x00r\x1e\x00\x00\x00r#\x00\x00\x00r\x11\x00\x00\x00r4\x00\x00\x00r6\x00\x00\x00r,\x00\x00\x00r\r\x00\x00\x00r\x11\x00\x00\x00r%\x00\x00\x00r\x0f\x00\x00\x00r\'\x00\x00\x00r2\x00\x00\x00rB\x00\x00\x00\xe97\x00\x00\x00r6\x00\x00\x00r-\x00\x00\x00r\x13\x00\x00\x00r6\x00\x00\x00r6\x00\x00\x00r5\x00\x00\x00r5\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x1e\x00\x00\x00r\x0c\x00\x00\x00r\x0b\x00\x00\x00r\x13\x00\x00\x00r9\x00\x00\x00r2\x00\x00\x00r\x13\x00\x00\x00r(\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x14\x00\x00\x00r\r\x00\x00\x00r\x0f\x00\x00\x00r\x10\x00\x00\x00r\x16\x00\x00\x00r4\x00\x00\x00r%\x00\x00\x00rA\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r=\x00\x00\x00r?\x00\x00\x00r\x0c\x00\x00\x00r\x16\x00\x00\x00r\r\x00\x00\x00r4\x00\x00\x00r\x1e\x00\x00\x00r\x0c\x00\x00\x00r\x0b\x00\x00\x00r5\x00\x00\x00r@\x00\x00\x00r>\x00\x00\x00r\x13\x00\x00\x00r?\x00\x00\x00r+\x00\x00\x00r\r\x00\x00\x00r\x18\x00\x00\x00r\x0b\x00\x00\x00r\x14\x00\x00\x00r=\x00\x00\x00r6\x00\x00\x00r\x16\x00\x00\x00r\x11\x00\x00\x00r;\x00\x00\x00r\x16\x00\x00\x00r6\x00\x00\x00r>\x00\x00\x00r@\x00\x00\x00rA\x00\x00\x00r5\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r+\x00\x00\x00r\r\x00\x00\x00r\x0b\x00\x00\x00r\x0e\x00\x00\x00r\x13\x00\x00\x00r2\x00\x00\x00r\x13\x00\x00\x00r\x0f\x00\x00\x00r\x10\x00\x00\x00r\x14\x00\x00\x00r\x0b\x00\x00\x00r\x16\x00\x00\x00r4\x00\x00\x00r6\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r?\x00\x00\x00r\x13\x00\x00\x00r,\x00\x00\x00r\x13\x00\x00\x00r@\x00\x00\x00r\x13\x00\x00\x00\xe9S\x00\x00\x00r\x11\x00\x00\x00r*\x00\x00\x00r\x11\x00\x00\x00r#\x00\x00\x00r\x16\x00\x00\x00r\x13\x00\x00\x00r\x1c\x00\x00\x00r\x13\x00\x00\x00r6\x00\x00\x00r5\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r#\x00\x00\x00r\x17\x00\x00\x00r\x18\x00\x00\x00r\x0f\x00\x00\x00r#\x00\x00\x00r\x11\x00\x00\x00r\x13\x00\x00\x00r2\x00\x00\x00r\x13\x00\x00\x00r6\x00\x00\x00r6\x00\x00\x00r&\x00\x00\x00\xe9j\x00\x00\x00r\x18\x00\x00\x00r\x0f\x00\x00\x00r\x10\x00\x00\x00r4\x00\x00\x00r\r\x00\x00\x00r\x11\x00\x00\x00r&\x00\x00\x00r%\x00\x00\x00r\x0f\x00\x00\x00r\x10\x00\x00\x00r\'\x00\x00\x00r\x1e\x00\x00\x00r*\x00\x00\x00r*\x00\x00\x00r4\x00\x00\x00r6\x00\x00\x00r7\x00\x00\x00r\'\x00\x00\x00\xe9*\x00\x00\x00r6\x00\x00\x00r-\x00\x00\x00r\x13\x00\x00\x00r#\x00\x00\x00r\x0b\x00\x00\x00r\r\x00\x00\x00r\r\x00\x00\x00r\x11\x00\x00\x00r\x10\x00\x00\x00r\x16\x00\x00\x00r=\x00\x00\x00r\x0f\x00\x00\x00r\x10\x00\x00\x00r\x16\x00\x00\x00r4\x00\x00\x00r+\x00\x00\x00r\r\x00\x00\x00r\x0b\x00\x00\x00r\x0e\x00\x00\x00r5\x00\x00\x00r\x13\x00\x00\x00\xe9-\x00\x00\x00r\x13\x00\x00\x00r(\x00\x00\x00r>\x00\x00\x00r5\x00\x00\x00r5\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x0b\x00\x00\x00r\x0c\x00\x00\x00r\x11\x00\x00\x00r\r\x00\x00\x00r\x0c\x00\x00\x00r\x13\x00\x00\x00r2\x00\x00\x00r\x13\x00\x00\x00r\r\x00\x00\x00r\x0b\x00\x00\x00r\x10\x00\x00\x00r&\x00\x00\x00r%\x00\x00\x00r\r\x00\x00\x00r\x18\x00\x00\x00r\x1f\x00\x00\x00r \x00\x00\x00r\r\x00\x00\x00r\x0b\x00\x00\x00r\x0e\x00\x00\x00r4\x00\x00\x00r6\x00\x00\x00r\n\x00\x00\x00r\x0e\x00\x00\x00r\r\x00\x00\x00r\x18\x00\x00\x00rC\x00\x00\x00r\x0c\x00\x00\x00r\x11\x00\x00\x00r\n\x00\x00\x00r+\x00\x00\x00r\r\x00\x00\x00r\x18\x00\x00\x00r\x0b\x00\x00\x00r\x14\x00\x00\x00r\n\x00\x00\x00r\x1f\x00\x00\x00r\x11\x00\x00\x00r\x1f\x00\x00\x00r\x0e\x00\x00\x00r\x11\x00\x00\x00r\r\x00\x00\x00r\x0c\x00\x00\x00r\n\x00\x00\x00r,\x00\x00\x00r\x0f\x00\x00\x00r\'\x00\x00\x00r2\x00\x00\x00r6\x00\x00\x00r\x13\x00\x00\x00r9\x00\x00\x00r\x13\x00\x00\x00r#\x00\x00\x00r\x17\x00\x00\x00r\x18\x00\x00\x00r\x0f\x00\x00\x00r#\x00\x00\x00r\x11\x00\x00\x00r5\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x14\x00\x00\x00r\r\x00\x00\x00r\x0f\x00\x00\x00r\x10\x00\x00\x00r\x16\x00\x00\x00r4\x00\x00\x00r5\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x0f\x00\x00\x00r%\x00\x00\x00r\x13\x00\x00\x00r*\x00\x00\x00r\x11\x00\x00\x00r\x10\x00\x00\x00r4\x00\x00\x00r\x0b\x00\x00\x00r\x0c\x00\x00\x00r\x11\x00\x00\x00r\r\x00\x00\x00r\x0c\x00\x00\x00r5\x00\x00\x00r\x13\x00\x00\x00r2\x00\x00\x00r2\x00\x00\x00r\x13\x00\x00\x00rE\x00\x00\x00r\x1c\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x11\x00\x00\x00r;\x00\x00\x00r\x0f\x00\x00\x00r\x16\x00\x00\x00r4\x00\x00\x00r6\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r?\x00\x00\x00r\x13\x00\x00\x00r\t\x00\x00\x00r\x13\x00\x00\x00r@\x00\x00\x00r\x13\x00\x00\x00\xe9W\x00\x00\x00r\r\x00\x00\x00r\x18\x00\x00\x00r\x10\x00\x00\x00r+\x00\x00\x00r\x13\x00\x00\x00rG\x00\x00\x00r\'\x00\x00\x00r6\x00\x00\x00r5\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x0c\x00\x00\x00r\x16\x00\x00\x00r\x1e\x00\x00\x00r\r\x00\x00\x00r\x16\x00\x00\x00r&\x00\x00\x00r\x0c\x00\x00\x00r\x18\x00\x00\x00r\r\x00\x00\x00r\x16\x00\x00\x00r\x0f\x00\x00\x00r\x10\x00\x00\x00r+\x00\x00\x00r4\x00\x00\x00r\x0b\x00\x00\x00r\x0c\x00\x00\x00r\x11\x00\x00\x00r\r\x00\x00\x00r\x0c\x00\x00\x00r5\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x11\x00\x00\x00r*\x00\x00\x00r\x0f\x00\x00\x00r%\x00\x00\x00r\x13\x00\x00\x00r\x1d\x00\x00\x00r\x11\x00\x00\x00r\x16\x00\x00\x00r\x13\x00\x00\x00r2\x00\x00\x00r2\x00\x00\x00r\x13\x00\x00\x00r6\x00\x00\x00\xe95\x00\x00\x00r6\x00\x00\x00r\x1c\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x1d\x00\x00\x00r\x11\x00\x00\x00r\x16\x00\x00\x00r\x13\x00\x00\x00r2\x00\x00\x00r\x13\x00\x00\x00r\x0f\x00\x00\x00r\x10\x00\x00\x00r\x14\x00\x00\x00r\x0b\x00\x00\x00r\x16\x00\x00\x00r4\x00\x00\x00r6\x00\x00\x00r\x13\x00\x00\x00r?\x00\x00\x00r\x13\x00\x00\x00r,\x00\x00\x00r\x13\x00\x00\x00r@\x00\x00\x00r\x13\x00\x00\x00r:\x00\x00\x00r\x10\x00\x00\x00r\x16\x00\x00\x00r\x11\x00\x00\x00r\r\x00\x00\x00r\x13\x00\x00\x00r\x0b\x00\x00\x00r\x0c\x00\x00\x00r\x11\x00\x00\x00r\r\x00\x00\x00r\x10\x00\x00\x00r\x1e\x00\x00\x00r\x1f\x00\x00\x00r\x11\x00\x00\x00r\n\x00\x00\x00rG\x00\x00\x00r\'\x00\x00\x00r\x13\x00\x00\x00r\x1c\x00\x00\x00r\x13\x00\x00\x00r6\x00\x00\x00r5\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x0f\x00\x00\x00r%\x00\x00\x00r\x13\x00\x00\x00r\x1d\x00\x00\x00r\x11\x00\x00\x00r\x16\x00\x00\x00r&\x00\x00\x00r\x0f\x00\x00\x00r\x0c\x00\x00\x00r\'\x00\x00\x00r\x0f\x00\x00\x00r+\x00\x00\x00r\x0f\x00\x00\x00r\x16\x00\x00\x00r4\x00\x00\x00r5\x00\x00\x00r\x1c\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x0b\x00\x00\x00r\x0c\x00\x00\x00r\x11\x00\x00\x00r\r\x00\x00\x00r\x13\x00\x00\x00r2\x00\x00\x00r\x13\x00\x00\x00r6\x00\x00\x00r\n\x00\x00\x00r\x14\x00\x00\x00r\r\x00\x00\x00r\x18\x00\x00\x00r%\x00\x00\x00r\x0f\x00\x00\x00r*\x00\x00\x00r\x11\x00\x00\x00r&\x00\x00\x00r\x14\x00\x00\x00r\x17\x00\x00\x00r\x14\x00\x00\x00r,\x00\x00\x00r\x0f\x00\x00\x00r\'\x00\x00\x00r2\x00\x00\x00r6\x00\x00\x00r\x13\x00\x00\x00r9\x00\x00\x00r\x13\x00\x00\x00r\x1d\x00\x00\x00r\x11\x00\x00\x00r\x16\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x16\x00\x00\x00r\x0f\x00\x00\x00r\x14\x00\x00\x00r\x11\x00\x00\x00r\x13\x00\x00\x00r2\x00\x00\x00r\x13\x00\x00\x00r6\x00\x00\x00r%\x00\x00\x00r\r\x00\x00\x00r\x0f\x00\x00\x00r\x11\x00\x00\x00r\x10\x00\x00\x00r\'\x00\x00\x00r\x0c\x00\x00\x00rF\x00\x00\x00r6\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x11\x00\x00\x00r*\x00\x00\x00r\x0c\x00\x00\x00r\x11\x00\x00\x00r\x1c\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x0b\x00\x00\x00r\x0c\x00\x00\x00r\x11\x00\x00\x00r\r\x00\x00\x00r\x13\x00\x00\x00r2\x00\x00\x00r\x13\x00\x00\x00r6\x00\x00\x00r\n\x00\x00\x00r6\x00\x00\x00r\x13\x00\x00\x00r9\x00\x00\x00r\x13\x00\x00\x00r\x1d\x00\x00\x00r\x11\x00\x00\x00r\x16\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x16\x00\x00\x00r\x0f\x00\x00\x00r\x14\x00\x00\x00r\x11\x00\x00\x00r\x13\x00\x00\x00r2\x00\x00\x00r\x13\x00\x00\x00r6\x00\x00\x00r%\x00\x00\x00r\r\x00\x00\x00r\x0f\x00\x00\x00r\x11\x00\x00\x00r\x10\x00\x00\x00r\'\x00\x00\x00r\x0c\x00\x00\x00r,\x00\x00\x00r6\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x16\x00\x00\x00r\r\x00\x00\x00r\x15\x00\x00\x00r\x1c\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x0b\x00\x00\x00r\x0c\x00\x00\x00r\x11\x00\x00\x00r\r\x00\x00\x00r\x13\x00\x00\x00r2\x00\x00\x00r\x13\x00\x00\x00r\r\x00\x00\x00r\x0b\x00\x00\x00r\x10\x00\x00\x00r&\x00\x00\x00r\x14\x00\x00\x00r\x1e\x00\x00\x00r\r\x00\x00\x00r\x0c\x00\x00\x00r\x11\x00\x00\x00r\r\x00\x00\x00r&\x00\x00\x00r+\x00\x00\x00r\x11\x00\x00\x00r\x16\x00\x00\x00r4\x00\x00\x00r\x0b\x00\x00\x00r\x0c\x00\x00\x00r\x11\x00\x00\x00r\r\x00\x00\x00r5\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x0f\x00\x00\x00r%\x00\x00\x00r\x13\x00\x00\x00r6\x00\x00\x00r\x14\x00\x00\x00r\x17\x00\x00\x00r\x14\x00\x00\x00r,\x00\x00\x00r\r\x00\x00\x00r\x1e\x00\x00\x00r\x10\x00\x00\x00r\'\x00\x00\x00r6\x00\x00\x00r\x13\x00\x00\x00r\x0f\x00\x00\x00r\x10\x00\x00\x00r\x13\x00\x00\x00r\x0c\x00\x00\x00r\x16\x00\x00\x00r\r\x00\x00\x00r4\x00\x00\x00r\x0b\x00\x00\x00r\x0c\x00\x00\x00r\x11\x00\x00\x00r\r\x00\x00\x00r5\x00\x00\x00r\x1c\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x11\x00\x00\x00r;\x00\x00\x00r\x0f\x00\x00\x00r\x16\x00\x00\x00r4\x00\x00\x00r6\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r?\x00\x00\x00r\x13\x00\x00\x00r\t\x00\x00\x00r\x13\x00\x00\x00r@\x00\x00\x00r\x13\x00\x00\x00rD\x00\x00\x00r\x0c\x00\x00\x00r\x11\x00\x00\x00r\r\x00\x00\x00r\x13\x00\x00\x00r\x10\x00\x00\x00r\x18\x00\x00\x00r\x16\x00\x00\x00r\x13\x00\x00\x00r%\x00\x00\x00r\x18\x00\x00\x00r\x0b\x00\x00\x00r\x10\x00\x00\x00r\'\x00\x00\x00r6\x00\x00\x00r5\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x0b\x00\x00\x00r\x0c\x00\x00\x00r\x11\x00\x00\x00r\r\x00\x00\x00r\x13\x00\x00\x00r2\x00\x00\x00r\x13\x00\x00\x00r\x0b\x00\x00\x00r\r\x00\x00\x00r*\x00\x00\x00r0\x00\x00\x00r%\x00\x00\x00r\x0f\x00\x00\x00r\x10\x00\x00\x00r\'\x00\x00\x00r4\x00\x00\x00r\x0b\x00\x00\x00r\x0c\x00\x00\x00r\x11\x00\x00\x00r\r\x00\x00\x00r-\x00\x00\x00r\x13\x00\x00\x00r\x16\x00\x00\x00r\x0f\x00\x00\x00r\x14\x00\x00\x00r\x11\x00\x00\x00r5\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x0b\x00\x00\x00r\x0c\x00\x00\x00r\x11\x00\x00\x00r\r\x00\x00\x00r\x10\x00\x00\x00r\x1e\x00\x00\x00r\x1f\x00\x00\x00r\x11\x00\x00\x00r\x13\x00\x00\x00r2\x00\x00\x00r\x13\x00\x00\x00r\r\x00\x00\x00r\x0b\x00\x00\x00r\x10\x00\x00\x00r&\x00\x00\x00r%\x00\x00\x00r\r\x00\x00\x00r\x0f\x00\x00\x00r\x11\x00\x00\x00r\x10\x00\x00\x00r\'\x00\x00\x00r*\x00\x00\x00r\x0f\x00\x00\x00r\x0c\x00\x00\x00r\x16\x00\x00\x00r4\x00\x00\x00r\x0b\x00\x00\x00r\x0c\x00\x00\x00r\x11\x00\x00\x00r\r\x00\x00\x00r=\x00\x00\x00r(\x00\x00\x00r>\x00\x00\x00r\x13\x00\x00\x00r\x0f\x00\x00\x00r%\x00\x00\x00r\x13\x00\x00\x00r\x16\x00\x00\x00r\x15\x00\x00\x00r\x14\x00\x00\x00r\x11\x00\x00\x00r4\x00\x00\x00r\x0b\x00\x00\x00r\x0c\x00\x00\x00r\x11\x00\x00\x00r\r\x00\x00\x00r5\x00\x00\x00r\x13\x00\x00\x00r2\x00\x00\x00r2\x00\x00\x00r\x13\x00\x00\x00r*\x00\x00\x00r\x0f\x00\x00\x00r\x0c\x00\x00\x00r\x16\x00\x00\x00r\x13\x00\x00\x00r\x11\x00\x00\x00r*\x00\x00\x00r\x0c\x00\x00\x00r\x11\x00\x00\x00r\x13\x00\x00\x00r\x0b\x00\x00\x00r\x0c\x00\x00\x00r\x11\x00\x00\x00r\r\x00\x00\x00r5\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x0f\x00\x00\x00r%\x00\x00\x00r\x13\x00\x00\x00r*\x00\x00\x00r\x11\x00\x00\x00r\x10\x00\x00\x00r4\x00\x00\x00r\x0b\x00\x00\x00r\x0c\x00\x00\x00r\x11\x00\x00\x00r\r\x00\x00\x00r5\x00\x00\x00r\x13\x00\x00\x00r2\x00\x00\x00r2\x00\x00\x00r\x13\x00\x00\x00rE\x00\x00\x00r\x1c\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r+\x00\x00\x00r\x11\x00\x00\x00r\x16\x00\x00\x00r\x14\x00\x00\x00r\x1e\x00\x00\x00r\x0c\x00\x00\x00r\x0c\x00\x00\x00r4\x00\x00\x00r6\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r?\x00\x00\x00r\x13\x00\x00\x00r\t\x00\x00\x00r\x13\x00\x00\x00r@\x00\x00\x00r\x13\x00\x00\x00rH\x00\x00\x00r\x1e\x00\x00\x00r\x10\x00\x00\x00rA\x00\x00\x00r\x16\x00\x00\x00r\x13\x00\x00\x00r\'\x00\x00\x00r\x0b\x00\x00\x00r\x1f\x00\x00\x00r\x14\x00\x00\x00r\x13\x00\x00\x00r\x0b\x00\x00\x00r\x0c\x00\x00\x00r\x11\x00\x00\x00r\r\x00\x00\x00r\x10\x00\x00\x00r\x1e\x00\x00\x00r\x1f\x00\x00\x00r\x11\x00\x00\x00r&\x00\x00\x00r\x13\x00\x00\x00r\x1f\x00\x00\x00r\x1e\x00\x00\x00r\x15\x00\x00\x00r\x0e\x00\x00\x00r\x11\x00\x00\x00r\x13\x00\x00\x00r%\x00\x00\x00r\r\x00\x00\x00r\x0f\x00\x00\x00r\x11\x00\x00\x00r\x10\x00\x00\x00r\'\x00\x00\x00r\x0c\x00\x00\x00r\x13\x00\x00\x00r\x17\x00\x00\x00r\x1e\x00\x00\x00r\x0c\x00\x00\x00r\x13\x00\x00\x00r\x14\x00\x00\x00r\r\x00\x00\x00r\x0f\x00\x00\x00r\x12\x00\x00\x00r\x1e\x00\x00\x00r\x16\x00\x00\x00r\x11\x00\x00\x00r&\x00\x00\x00r\x13\x00\x00\x00r:\x00\x00\x00r\x10\x00\x00\x00r\x16\x00\x00\x00r\x11\x00\x00\x00r\r\x00\x00\x00r&\x00\x00\x00r&\x00\x00\x00r&\x00\x00\x00r6\x00\x00\x00r5\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x14\x00\x00\x00r\r\x00\x00\x00r\x0f\x00\x00\x00r\x10\x00\x00\x00r\x16\x00\x00\x00r4\x00\x00\x00r5\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x0c\x00\x00\x00r\x16\x00\x00\x00r\x1e\x00\x00\x00r\r\x00\x00\x00r\x16\x00\x00\x00r&\x00\x00\x00r\x0c\x00\x00\x00r\x18\x00\x00\x00r\r\x00\x00\x00r\x16\x00\x00\x00r\x0f\x00\x00\x00r\x10\x00\x00\x00r+\x00\x00\x00r4\x00\x00\x00r\x0b\x00\x00\x00r\x0c\x00\x00\x00r\x11\x00\x00\x00r\r\x00\x00\x00r\x10\x00\x00\x00r\x1e\x00\x00\x00r\x1f\x00\x00\x00r\x11\x00\x00\x00r5\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x11\x00\x00\x00r;\x00\x00\x00r#\x00\x00\x00r\x11\x00\x00\x00r\x14\x00\x00\x00r\x16\x00\x00\x00r\x13\x00\x00\x00r)\x00\x00\x00r\x15\x00\x00\x00r\x14\x00\x00\x00r\x11\x00\x00\x00r:\x00\x00\x00r\r\x00\x00\x00r\r\x00\x00\x00r\x18\x00\x00\x00r\r\x00\x00\x00r\x1c\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x11\x00\x00\x00r;\x00\x00\x00r\x0f\x00\x00\x00r\x16\x00\x00\x00r4\x00\x00\x00r6\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r?\x00\x00\x00r\x13\x00\x00\x00r\t\x00\x00\x00r\x13\x00\x00\x00r@\x00\x00\x00r\x13\x00\x00\x00rD\x00\x00\x00r\x0c\x00\x00\x00r\x11\x00\x00\x00r\r\x00\x00\x00r\x13\x00\x00\x00r\x10\x00\x00\x00r\x18\x00\x00\x00r\x16\x00\x00\x00r\x13\x00\x00\x00r%\x00\x00\x00r\x18\x00\x00\x00r\x0b\x00\x00\x00r\x10\x00\x00\x00r\'\x00\x00\x00r\x13\x00\x00\x00r6\x00\x00\x00r5\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x11\x00\x00\x00r;\x00\x00\x00r#\x00\x00\x00r\x11\x00\x00\x00r\x14\x00\x00\x00r\x16\x00\x00\x00r\x13\x00\x00\x00rG\x00\x00\x00r\x10\x00\x00\x00r\'\x00\x00\x00r\x11\x00\x00\x00r;\x00\x00\x00r:\x00\x00\x00r\r\x00\x00\x00r\r\x00\x00\x00r\x18\x00\x00\x00r\r\x00\x00\x00r\x1c\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r+\x00\x00\x00r\x11\x00\x00\x00r\x16\x00\x00\x00r\x14\x00\x00\x00r\x1e\x00\x00\x00r\x0c\x00\x00\x00r\x0c\x00\x00\x00r4\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r6\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r?\x00\x00\x00r\x13\x00\x00\x00r\t\x00\x00\x00r\x13\x00\x00\x00r@\x00\x00\x00r\x13\x00\x00\x00rH\x00\x00\x00r\x1e\x00\x00\x00r\x10\x00\x00\x00rA\x00\x00\x00r\x16\x00\x00\x00r\x13\x00\x00\x00r\'\x00\x00\x00r\x0b\x00\x00\x00r\x1f\x00\x00\x00r\x14\x00\x00\x00r\x13\x00\x00\x00r\x0b\x00\x00\x00r\x0c\x00\x00\x00r\x11\x00\x00\x00r\r\x00\x00\x00r\x10\x00\x00\x00r\x1e\x00\x00\x00r\x1f\x00\x00\x00r\x11\x00\x00\x00r&\x00\x00\x00r7\x00\x00\x00r\x10\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r?\x00\x00\x00r\x13\x00\x00\x00r\t\x00\x00\x00r\x13\x00\x00\x00r@\x00\x00\x00r\x13\x00\x00\x00r\x15\x00\x00\x00r\x18\x00\x00\x00r\x0b\x00\x00\x00r\r\x00\x00\x00r\x13\x00\x00\x00r\x1e\x00\x00\x00r#\x00\x00\x00r#\x00\x00\x00r\x18\x00\x00\x00r\x0b\x00\x00\x00r\x10\x00\x00\x00r\x16\x00\x00\x00r\x13\x00\x00\x00r\x18\x00\x00\x00r\x10\x00\x00\x00r*\x00\x00\x00r\x15\x00\x00\x00r\x13\x00\x00\x00r\x16\x00\x00\x00r\x1e\x00\x00\x00r$\x00\x00\x00r\x11\x00\x00\x00r\x0c\x00\x00\x00r\x13\x00\x00\x00r\x0b\x00\x00\x00r\x0c\x00\x00\x00r\x11\x00\x00\x00r\r\x00\x00\x00r\x10\x00\x00\x00r\x1e\x00\x00\x00r\x1f\x00\x00\x00r\x11\x00\x00\x00r\x13\x00\x00\x00r%\x00\x00\x00r\r\x00\x00\x00r\x18\x00\x00\x00r\x1f\x00\x00\x00r\x13\x00\x00\x00r\x15\x00\x00\x00r\x18\x00\x00\x00r\x0b\x00\x00\x00r\r\x00\x00\x00r\x13\x00\x00\x00r%\x00\x00\x00r\r\x00\x00\x00r\x0f\x00\x00\x00r\x11\x00\x00\x00r\x10\x00\x00\x00r\'\x00\x00\x00r*\x00\x00\x00r\x0f\x00\x00\x00r\x0c\x00\x00\x00r\x16\x00\x00\x00r\x13\x00\x00\x00r\x18\x00\x00\x00r\x10\x00\x00\x00r*\x00\x00\x00r\x15\x00\x00\x00r&\x00\x00\x00r\x13\x00\x00\x00r:\x00\x00\x00r\x10\x00\x00\x00r\x16\x00\x00\x00r\x11\x00\x00\x00r\r\x00\x00\x00r&\x00\x00\x00r&\x00\x00\x00r&\x00\x00\x00r6\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r5\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x1f\x00\x00\x00r\x11\x00\x00\x00r\x10\x00\x00\x00r\x0b\x00\x00\x00r4\x00\x00\x00r5\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x11\x00\x00\x00r*\x00\x00\x00r\x0f\x00\x00\x00r%\x00\x00\x00r\x13\x00\x00\x00r\x1d\x00\x00\x00r\x11\x00\x00\x00r\x16\x00\x00\x00r\x13\x00\x00\x00r2\x00\x00\x00r2\x00\x00\x00r\x13\x00\x00\x00r6\x00\x00\x00\xe96\x00\x00\x00r6\x00\x00\x00r\x1c\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r.\x00\x00\x00r\x0b\x00\x00\x00r\x11\x00\x00\x00r\r\x00\x00\x00r\x15\x00\x00\x00r\x13\x00\x00\x00r2\x00\x00\x00r\x13\x00\x00\x00r\x0f\x00\x00\x00r\x10\x00\x00\x00r\x14\x00\x00\x00r\x0b\x00\x00\x00r\x16\x00\x00\x00r4\x00\x00\x00r6\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r?\x00\x00\x00r\x13\x00\x00\x00r,\x00\x00\x00r\x13\x00\x00\x00r@\x00\x00\x00r\x13\x00\x00\x00\xe9H\x00\x00\x00r\x1e\x00\x00\x00r\x0c\x00\x00\x00r\x17\x00\x00\x00r\x16\x00\x00\x00r\x1e\x00\x00\x00r+\x00\x00\x00r\x13\x00\x00\x00r\x1c\x00\x00\x00r\x13\x00\x00\x00r6\x00\x00\x00r5\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x0b\x00\x00\x00r\x0c\x00\x00\x00r\x11\x00\x00\x00r\r\x00\x00\x00r\x10\x00\x00\x00r\x1e\x00\x00\x00r\x1f\x00\x00\x00r\x11\x00\x00\x00r\x13\x00\x00\x00r2\x00\x00\x00r\x13\x00\x00\x00r\r\x00\x00\x00r\x0b\x00\x00\x00r\x10\x00\x00\x00r&\x00\x00\x00r\x17\x00\x00\x00r\x1e\x00\x00\x00r\x0c\x00\x00\x00r\x17\x00\x00\x00r\x16\x00\x00\x00r\x1e\x00\x00\x00r+\x00\x00\x00r4\x00\x00\x00r6\x00\x00\x00r\n\x00\x00\x00r\x17\x00\x00\x00r\x1e\x00\x00\x00r\x0c\x00\x00\x00r\x17\x00\x00\x00r\x16\x00\x00\x00r\x1e\x00\x00\x00r+\x00\x00\x00r\n\x00\x00\x00r6\x00\x00\x00r\x13\x00\x00\x00r9\x00\x00\x00r\x13\x00\x00\x00r.\x00\x00\x00r\x0b\x00\x00\x00r\x11\x00\x00\x00r\r\x00\x00\x00r\x15\x00\x00\x00r5\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x14\x00\x00\x00r\r\x00\x00\x00r\x0f\x00\x00\x00r\x10\x00\x00\x00r\x16\x00\x00\x00r4\x00\x00\x00r5\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x0f\x00\x00\x00r%\x00\x00\x00r\x13\x00\x00\x00r*\x00\x00\x00r\x11\x00\x00\x00r\x10\x00\x00\x00r4\x00\x00\x00r\x0b\x00\x00\x00r\x0c\x00\x00\x00r\x11\x00\x00\x00r\r\x00\x00\x00r\x10\x00\x00\x00r\x1e\x00\x00\x00r\x1f\x00\x00\x00r\x11\x00\x00\x00r5\x00\x00\x00r\x13\x00\x00\x00r2\x00\x00\x00r2\x00\x00\x00r\x13\x00\x00\x00rE\x00\x00\x00r\x1c\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r+\x00\x00\x00r\x11\x00\x00\x00r\x16\x00\x00\x00r\x14\x00\x00\x00r\x1e\x00\x00\x00r\x0c\x00\x00\x00r\x0c\x00\x00\x00r4\x00\x00\x00r6\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r?\x00\x00\x00r\x13\x00\x00\x00r\t\x00\x00\x00r\x13\x00\x00\x00r@\x00\x00\x00r\x13\x00\x00\x00r3\x00\x00\x00r\x18\x00\x00\x00r\x13\x00\x00\x00r\r\x00\x00\x00r\x11\x00\x00\x00r\x0c\x00\x00\x00r\x0b\x00\x00\x00r*\x00\x00\x00r\x16\x00\x00\x00r\x0c\x00\x00\x00r&\x00\x00\x00r\x13\x00\x00\x00r:\x00\x00\x00r\x10\x00\x00\x00r\x16\x00\x00\x00r\x11\x00\x00\x00r\r\x00\x00\x00r&\x00\x00\x00r&\x00\x00\x00r&\x00\x00\x00r6\x00\x00\x00r5\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x1f\x00\x00\x00r\x11\x00\x00\x00r\x10\x00\x00\x00r\x0b\x00\x00\x00r4\x00\x00\x00r5\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x0c\x00\x00\x00r\x16\x00\x00\x00r\x1e\x00\x00\x00r\r\x00\x00\x00r\x16\x00\x00\x00r&\x00\x00\x00r\x0c\x00\x00\x00r\x18\x00\x00\x00r\r\x00\x00\x00r\x16\x00\x00\x00r\x0f\x00\x00\x00r\x10\x00\x00\x00r+\x00\x00\x00r4\x00\x00\x00r\x0b\x00\x00\x00r\x0c\x00\x00\x00r\x11\x00\x00\x00r\r\x00\x00\x00r\x10\x00\x00\x00r\x1e\x00\x00\x00r\x1f\x00\x00\x00r\x11\x00\x00\x00r5\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x11\x00\x00\x00r*\x00\x00\x00r\x0f\x00\x00\x00r%\x00\x00\x00r\x13\x00\x00\x00r\x1d\x00\x00\x00r\x11\x00\x00\x00r\x16\x00\x00\x00r\x13\x00\x00\x00r2\x00\x00\x00r2\x00\x00\x00r\x13\x00\x00\x00r6\x00\x00\x00rL\x00\x00\x00r6\x00\x00\x00r\x1c\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r#\x00\x00\x00r\x17\x00\x00\x00r\x11\x00\x00\x00r#\x00\x00\x00r$\x00\x00\x00r\x13\x00\x00\x00r2\x00\x00\x00r\x13\x00\x00\x00r\x18\x00\x00\x00r\x14\x00\x00\x00r\x11\x00\x00\x00r\x10\x00\x00\x00r4\x00\x00\x00r6\x00\x00\x00r\r\x00\x00\x00r\x11\x00\x00\x00r\x0c\x00\x00\x00r\x0b\x00\x00\x00r*\x00\x00\x00r\x16\x00\x00\x00r\x0c\x00\x00\x00rP\x00\x00\x00r#\x00\x00\x00r\x17\x00\x00\x00r\x11\x00\x00\x00r#\x00\x00\x00r$\x00\x00\x00r6\x00\x00\x00r5\x00\x00\x00r&\x00\x00\x00r\r\x00\x00\x00r\x11\x00\x00\x00r\x1e\x00\x00\x00r\'\x00\x00\x00r4\x00\x00\x00r5\x00\x00\x00r\x13\x00\x00\x00r\x0f\x00\x00\x00r%\x00\x00\x00r\x13\x00\x00\x00r\x18\x00\x00\x00r\x0c\x00\x00\x00r&\x00\x00\x00r\x14\x00\x00\x00r\x1e\x00\x00\x00r\x16\x00\x00\x00r\x17\x00\x00\x00r&\x00\x00\x00r\x11\x00\x00\x00r;\x00\x00\x00r\x0f\x00\x00\x00r\x0c\x00\x00\x00r\x16\x00\x00\x00r\x0c\x00\x00\x00r4\x00\x00\x00r6\x00\x00\x00r\r\x00\x00\x00r\x11\x00\x00\x00r\x0c\x00\x00\x00r\x0b\x00\x00\x00r*\x00\x00\x00r\x16\x00\x00\x00r\x0c\x00\x00\x00rP\x00\x00\x00r#\x00\x00\x00r\x17\x00\x00\x00r\x11\x00\x00\x00r#\x00\x00\x00r$\x00\x00\x00r6\x00\x00\x00r5\x00\x00\x00r\x13\x00\x00\x00r\x11\x00\x00\x00r*\x00\x00\x00r\x0c\x00\x00\x00r\x11\x00\x00\x00r\x13\x00\x00\x00r=\x00\x00\x00r>\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r*\x00\x00\x00r\x0f\x00\x00\x00r%\x00\x00\x00r\x11\x00\x00\x00r\x13\x00\x00\x00r2\x00\x00\x00r\x13\x00\x00\x00r\x18\x00\x00\x00r\x14\x00\x00\x00r\x11\x00\x00\x00r\x10\x00\x00\x00r4\x00\x00\x00r6\x00\x00\x00r\r\x00\x00\x00r\x11\x00\x00\x00r\x0c\x00\x00\x00r\x0b\x00\x00\x00r*\x00\x00\x00r\x16\x00\x00\x00r\x0c\x00\x00\x00rP\x00\x00\x00r*\x00\x00\x00r\x0f\x00\x00\x00r%\x00\x00\x00r\x11\x00\x00\x00r6\x00\x00\x00r5\x00\x00\x00r&\x00\x00\x00r\r\x00\x00\x00r\x11\x00\x00\x00r\x1e\x00\x00\x00r\'\x00\x00\x00r4\x00\x00\x00r5\x00\x00\x00r\x13\x00\x00\x00r\x0f\x00\x00\x00r%\x00\x00\x00r\x13\x00\x00\x00r\x18\x00\x00\x00r\x0c\x00\x00\x00r&\x00\x00\x00r\x14\x00\x00\x00r\x1e\x00\x00\x00r\x16\x00\x00\x00r\x17\x00\x00\x00r&\x00\x00\x00r\x11\x00\x00\x00r;\x00\x00\x00r\x0f\x00\x00\x00r\x0c\x00\x00\x00r\x16\x00\x00\x00r\x0c\x00\x00\x00r4\x00\x00\x00r6\x00\x00\x00r\r\x00\x00\x00r\x11\x00\x00\x00r\x0c\x00\x00\x00r\x0b\x00\x00\x00r*\x00\x00\x00r\x16\x00\x00\x00r\x0c\x00\x00\x00rP\x00\x00\x00r*\x00\x00\x00r\x0f\x00\x00\x00r%\x00\x00\x00r\x11\x00\x00\x00r6\x00\x00\x00r5\x00\x00\x00r\x13\x00\x00\x00r\x11\x00\x00\x00r*\x00\x00\x00r\x0c\x00\x00\x00r\x11\x00\x00\x00r\x13\x00\x00\x00r=\x00\x00\x00r>\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r%\x00\x00\x00r\x0f\x00\x00\x00r\x10\x00\x00\x00r\x1e\x00\x00\x00r*\x00\x00\x00r\x13\x00\x00\x00r2\x00\x00\x00r\x13\x00\x00\x00r#\x00\x00\x00r\x17\x00\x00\x00r\x11\x00\x00\x00r#\x00\x00\x00r$\x00\x00\x00r\x13\x00\x00\x00r9\x00\x00\x00r\x13\x00\x00\x00r*\x00\x00\x00r\x0f\x00\x00\x00r%\x00\x00\x00r\x11\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x14\x00\x00\x00r\r\x00\x00\x00r\x0f\x00\x00\x00r\x10\x00\x00\x00r\x16\x00\x00\x00r4\x00\x00\x00r6\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r?\x00\x00\x00r\x13\x00\x00\x00r\t\x00\x00\x00r\x13\x00\x00\x00r@\x00\x00\x00r\x13\x00\x00\x00r<\x00\x00\x00r\x0c\x00\x00\x00r\x13\x00\x00\x00r\x1e\x00\x00\x00r#\x00\x00\x00r#\x00\x00\x00r\x18\x00\x00\x00r\x0b\x00\x00\x00r\x10\x00\x00\x00r\x16\x00\x00\x00r\x0c\x00\x00\x00r\x13\x00\x00\x00r\x16\x00\x00\x00r\x18\x00\x00\x00r\x13\x00\x00\x00r#\x00\x00\x00r\x17\x00\x00\x00r\x11\x00\x00\x00r#\x00\x00\x00r$\x00\x00\x00r6\x00\x00\x00r\x13\x00\x00\x00r<\x00\x00\x00r\x13\x00\x00\x00r\x0c\x00\x00\x00r\x16\x00\x00\x00r\r\x00\x00\x00r4\x00\x00\x00r*\x00\x00\x00r\x11\x00\x00\x00r\x10\x00\x00\x00r4\x00\x00\x00r%\x00\x00\x00r\x0f\x00\x00\x00r\x10\x00\x00\x00r\x1e\x00\x00\x00r*\x00\x00\x00r5\x00\x00\x00r5\x00\x00\x00r5\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x0c\x00\x00\x00r\x16\x00\x00\x00r\x1e\x00\x00\x00r\r\x00\x00\x00r\x16\x00\x00\x00r&\x00\x00\x00r#\x00\x00\x00r\x17\x00\x00\x00r\x11\x00\x00\x00r#\x00\x00\x00r$\x00\x00\x00r\x11\x00\x00\x00r\r\x00\x00\x00r4\x00\x00\x00r%\x00\x00\x00r\x0f\x00\x00\x00r\x10\x00\x00\x00r\x1e\x00\x00\x00r*\x00\x00\x00r5\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x11\x00\x00\x00r*\x00\x00\x00r\x0c\x00\x00\x00r\x11\x00\x00\x00r\x1c\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r+\x00\x00\x00r\x11\x00\x00\x00r\x16\x00\x00\x00r\x14\x00\x00\x00r\x1e\x00\x00\x00r\x0c\x00\x00\x00r\x0c\x00\x00\x00r4\x00\x00\x00r6\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r?\x00\x00\x00r\x13\x00\x00\x00r\t\x00\x00\x00r\x13\x00\x00\x00r@\x00\x00\x00r\x13\x00\x00\x00rQ\x00\x00\x00r\r\x00\x00\x00r\x18\x00\x00\x00r\x10\x00\x00\x00r+\x00\x00\x00r\x13\x00\x00\x00r#\x00\x00\x00r\x17\x00\x00\x00r\x18\x00\x00\x00r\x0f\x00\x00\x00r#\x00\x00\x00r\x11\x00\x00\x00r&\x00\x00\x00r\x13\x00\x00\x00r:\x00\x00\x00r\x10\x00\x00\x00r\x16\x00\x00\x00r\x11\x00\x00\x00r\r\x00\x00\x00r&\x00\x00\x00r&\x00\x00\x00r&\x00\x00\x00r6\x00\x00\x00r5\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x1f\x00\x00\x00r\x11\x00\x00\x00r\x10\x00\x00\x00r\x0b\x00\x00\x00r4\x00\x00\x00r5\x00\x00\x00r\x1a\x00\x00\x00r\x1a\x00\x00\x00r\x1a\x00\x00\x00r\'\x00\x00\x00r\x11\x00\x00\x00r%\x00\x00\x00r\x13\x00\x00\x00r#\x00\x00\x00r\x11\x00\x00\x00r$\x00\x00\x00r4\x00\x00\x00r5\x00\x00\x00r\x1c\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r+\x00\x00\x00r*\x00\x00\x00r\x18\x00\x00\x00r\x0e\x00\x00\x00r\x1e\x00\x00\x00r*\x00\x00\x00r\x13\x00\x00\x00r1\x00\x00\x00r\x1b\x00\x00\x00r)\x00\x00\x00r\x1b\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x18\x00\x00\x00r\x0c\x00\x00\x00r&\x00\x00\x00r\x0c\x00\x00\x00r\x15\x00\x00\x00r\x0c\x00\x00\x00r\x16\x00\x00\x00r\x11\x00\x00\x00r\x1f\x00\x00\x00r4\x00\x00\x00r6\x00\x00\x00r#\x00\x00\x00r*\x00\x00\x00r\x11\x00\x00\x00r\x1e\x00\x00\x00r\r\x00\x00\x00r6\x00\x00\x00r5\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x0e\x00\x00\x00r\x1e\x00\x00\x00r\x10\x00\x00\x00r\x10\x00\x00\x00r\x11\x00\x00\x00r\r\x00\x00\x00r&\x00\x00\x00r\x0e\x00\x00\x00r\x1e\x00\x00\x00r\x10\x00\x00\x00r\x10\x00\x00\x00r\x11\x00\x00\x00r\r\x00\x00\x00r4\x00\x00\x00r5\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x14\x00\x00\x00r\r\x00\x00\x00r\x0f\x00\x00\x00r\x10\x00\x00\x00r\x16\x00\x00\x00r4\x00\x00\x00r6\x00\x00\x00r7\x00\x00\x00r\x10\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\t\x00\x00\x00r\x13\x00\x00\x00r:\x00\x00\x00r;\x00\x00\x00r\x14\x00\x00\x00r\x0f\x00\x00\x00r\r\x00\x00\x00r\x11\x00\x00\x00r\'\x00\x00\x00r\x1c\x00\x00\x00r\x13\x00\x00\x00r<\x00\x00\x00r\x0c\x00\x00\x00r6\x00\x00\x00r<\x00\x00\x00r\x13\x00\x00\x00r\x0b\x00\x00\x00r\x0c\x00\x00\x00r\x11\x00\x00\x00r\r\x00\x00\x00r0\x00\x00\x00r*\x00\x00\x00r\x18\x00\x00\x00r+\x00\x00\x00r+\x00\x00\x00r\x11\x00\x00\x00r\'\x00\x00\x00r=\x00\x00\x00r6\x00\x00\x00r\x11\x00\x00\x00r;\x00\x00\x00r\x14\x00\x00\x00r\x0f\x00\x00\x00r\r\x00\x00\x00r\x11\x00\x00\x00r\'\x00\x00\x00r6\x00\x00\x00r>\x00\x00\x00r5\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x14\x00\x00\x00r\r\x00\x00\x00r\x0f\x00\x00\x00r\x10\x00\x00\x00r\x16\x00\x00\x00r4\x00\x00\x00r6\x00\x00\x00r7\x00\x00\x00r\x10\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00\xe9>\x00\x00\x00r\x13\x00\x00\x00rT\x00\x00\x00r\x18\x00\x00\x00rC\x00\x00\x00r\x13\x00\x00\x00r\x16\x00\x00\x00r\x18\x00\x00\x00r\x13\x00\x00\x00r+\x00\x00\x00r\x11\x00\x00\x00r\x16\x00\x00\x00r\x13\x00\x00\x00r#\x00\x00\x00r\x18\x00\x00\x00r\x18\x00\x00\x00r$\x00\x00\x00r\x0f\x00\x00\x00r\x11\x00\x00\x00r\x13\x00\x00\x00r\x1c\x00\x00\x00r\x13\x00\x00\x00r\x17\x00\x00\x00r\x16\x00\x00\x00r\x16\x00\x00\x00r\x14\x00\x00\x00r\x0c\x00\x00\x00r\x1c\x00\x00\x00r\n\x00\x00\x00r\n\x00\x00\x00r\x15\x00\x00\x00r\x18\x00\x00\x00r\x0b\x00\x00\x00r\x16\x00\x00\x00r\x0b\x00\x00\x00r&\x00\x00\x00r\x0e\x00\x00\x00r\x11\x00\x00\x00r\n\x00\x00\x00rK\x00\x00\x00r$\x00\x00\x00r\x17\x00\x00\x00r\x14\x00\x00\x00rQ\x00\x00\x00r\x1f\x00\x00\x00r\x0c\x00\x00\x00r.\x00\x00\x00rN\x00\x00\x00rN\x00\x00\x00r/\x00\x00\x00r6\x00\x00\x00r5\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r#\x00\x00\x00r\x18\x00\x00\x00r\x18\x00\x00\x00r$\x00\x00\x00r\x0f\x00\x00\x00r\x11\x00\x00\x00r\x13\x00\x00\x00r2\x00\x00\x00r\x13\x00\x00\x00r\x0f\x00\x00\x00r\x10\x00\x00\x00r\x14\x00\x00\x00r\x0b\x00\x00\x00r\x16\x00\x00\x00r4\x00\x00\x00r6\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00rU\x00\x00\x00r\x13\x00\x00\x00r:\x00\x00\x00r\x10\x00\x00\x00r\x16\x00\x00\x00r\x11\x00\x00\x00r\r\x00\x00\x00r\x13\x00\x00\x00r\x15\x00\x00\x00r\x18\x00\x00\x00r\x0b\x00\x00\x00r\r\x00\x00\x00r\x13\x00\x00\x00r#\x00\x00\x00r\x18\x00\x00\x00r\x18\x00\x00\x00r$\x00\x00\x00r\x0f\x00\x00\x00r\x11\x00\x00\x00r\x13\x00\x00\x00r\x1c\x00\x00\x00r\x13\x00\x00\x00r6\x00\x00\x00r5\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\'\x00\x00\x00r\x1e\x00\x00\x00r\x16\x00\x00\x00r\x1e\x00\x00\x00r\x13\x00\x00\x00r2\x00\x00\x00r\x13\x00\x00\x00r*\x00\x00\x00r\x18\x00\x00\x00r+\x00\x00\x00r\x0f\x00\x00\x00r\x10\x00\x00\x00r&\x00\x00\x00r\x12\x00\x00\x00r\x1e\x00\x00\x00r*\x00\x00\x00r4\x00\x00\x00r#\x00\x00\x00r\x18\x00\x00\x00r\x18\x00\x00\x00r$\x00\x00\x00r\x0f\x00\x00\x00r\x11\x00\x00\x00r5\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x0f\x00\x00\x00r%\x00\x00\x00r\x13\x00\x00\x00r\'\x00\x00\x00r\x1e\x00\x00\x00r\x16\x00\x00\x00r\x1e\x00\x00\x00r\x1c\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00rC\x00\x00\x00r\x0f\x00\x00\x00r\x16\x00\x00\x00r\x17\x00\x00\x00r\x13\x00\x00\x00r\x18\x00\x00\x00r\x14\x00\x00\x00r\x11\x00\x00\x00r\x10\x00\x00\x00r4\x00\x00\x00r6\x00\x00\x00r\x0b\x00\x00\x00r\x0c\x00\x00\x00r\r\x00\x00\x00r\n\x00\x00\x00r#\x00\x00\x00r\x18\x00\x00\x00r\x18\x00\x00\x00r$\x00\x00\x00r\x0f\x00\x00\x00r\x11\x00\x00\x00r\x0c\x00\x00\x00r6\x00\x00\x00r-\x00\x00\x00r\x13\x00\x00\x00r6\x00\x00\x00rC\x00\x00\x00r6\x00\x00\x00r5\x00\x00\x00r\x13\x00\x00\x00r\x1e\x00\x00\x00r\x0c\x00\x00\x00r\x13\x00\x00\x00r%\x00\x00\x00r\x1c\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r%\x00\x00\x00r&\x00\x00\x00rC\x00\x00\x00r\r\x00\x00\x00r\x0f\x00\x00\x00r\x16\x00\x00\x00r\x11\x00\x00\x00r4\x00\x00\x00r#\x00\x00\x00r\x18\x00\x00\x00r\x18\x00\x00\x00r$\x00\x00\x00r\x0f\x00\x00\x00r\x11\x00\x00\x00r5\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r1\x00\x00\x00r\x1b\x00\x00\x00r)\x00\x00\x00r\x1b\x00\x00\x00r\x13\x00\x00\x00r2\x00\x00\x00r\x13\x00\x00\x00r\'\x00\x00\x00r\x1e\x00\x00\x00r\x16\x00\x00\x00r\x1e\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\r\x00\x00\x00r\x11\x00\x00\x00r\x16\x00\x00\x00r\x0b\x00\x00\x00r\r\x00\x00\x00r\x10\x00\x00\x00r\x13\x00\x00\x00r#\x00\x00\x00r\x18\x00\x00\x00r\x18\x00\x00\x00r$\x00\x00\x00r\x0f\x00\x00\x00r\x11\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x11\x00\x00\x00r*\x00\x00\x00r\x0c\x00\x00\x00r\x11\x00\x00\x00r\x1c\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r+\x00\x00\x00r\x11\x00\x00\x00r\x16\x00\x00\x00r\x14\x00\x00\x00r\x1e\x00\x00\x00r\x0c\x00\x00\x00r\x0c\x00\x00\x00r4\x00\x00\x00r6\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r?\x00\x00\x00r\x13\x00\x00\x00r\t\x00\x00\x00r\x13\x00\x00\x00r@\x00\x00\x00r\x13\x00\x00\x00r#\x00\x00\x00r\x18\x00\x00\x00r\x18\x00\x00\x00r$\x00\x00\x00r\x0f\x00\x00\x00r\x11\x00\x00\x00r\x13\x00\x00\x00rC\x00\x00\x00r\r\x00\x00\x00r\x18\x00\x00\x00r\x10\x00\x00\x00r+\x00\x00\x00r6\x00\x00\x00r5\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r#\x00\x00\x00r\x11\x00\x00\x00r$\x00\x00\x00r4\x00\x00\x00r5\x00\x00\x00r\x1a\x00\x00\x00r\x1a\x00\x00\x00r\x1a\x00\x00\x00r\'\x00\x00\x00r\x11\x00\x00\x00r%\x00\x00\x00r\x13\x00\x00\x00r\x1f\x00\x00\x00r\x1e\x00\x00\x00r\x0f\x00\x00\x00r\x10\x00\x00\x00r4\x00\x00\x00r5\x00\x00\x00r\x1c\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x16\x00\x00\x00r\r\x00\x00\x00r\x15\x00\x00\x00r\x1c\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r+\x00\x00\x00r*\x00\x00\x00r\x18\x00\x00\x00r\x0e\x00\x00\x00r\x1e\x00\x00\x00r*\x00\x00\x00r\x13\x00\x00\x00r1\x00\x00\x00r\x1b\x00\x00\x00r)\x00\x00\x00r\x1b\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r#\x00\x00\x00r\x18\x00\x00\x00r\x18\x00\x00\x00r$\x00\x00\x00r\x0f\x00\x00\x00r\x11\x00\x00\x00r\x0c\x00\x00\x00r\x13\x00\x00\x00r2\x00\x00\x00r\x13\x00\x00\x00r\x18\x00\x00\x00r\x14\x00\x00\x00r\x11\x00\x00\x00r\x10\x00\x00\x00r4\x00\x00\x00r6\x00\x00\x00r\x0b\x00\x00\x00r\x0c\x00\x00\x00r\r\x00\x00\x00r\n\x00\x00\x00r#\x00\x00\x00r\x18\x00\x00\x00r\x18\x00\x00\x00r$\x00\x00\x00r\x0f\x00\x00\x00r\x11\x00\x00\x00r\x0c\x00\x00\x00r6\x00\x00\x00r5\x00\x00\x00r&\x00\x00\x00r\r\x00\x00\x00r\x11\x00\x00\x00r\x1e\x00\x00\x00r\'\x00\x00\x00r4\x00\x00\x00r5\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\'\x00\x00\x00r\x1e\x00\x00\x00r\x16\x00\x00\x00r\x1e\x00\x00\x00r\x13\x00\x00\x00r2\x00\x00\x00r\x13\x00\x00\x00r*\x00\x00\x00r\x18\x00\x00\x00r+\x00\x00\x00r\x0f\x00\x00\x00r\x10\x00\x00\x00r&\x00\x00\x00r\x12\x00\x00\x00r\x1e\x00\x00\x00r*\x00\x00\x00r4\x00\x00\x00r#\x00\x00\x00r\x18\x00\x00\x00r\x18\x00\x00\x00r$\x00\x00\x00r\x0f\x00\x00\x00r\x11\x00\x00\x00r\x0c\x00\x00\x00r5\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x0f\x00\x00\x00r%\x00\x00\x00r\x13\x00\x00\x00r\'\x00\x00\x00r\x1e\x00\x00\x00r\x16\x00\x00\x00r\x1e\x00\x00\x00r\x1c\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r1\x00\x00\x00r\x1b\x00\x00\x00r)\x00\x00\x00r\x1b\x00\x00\x00r\x13\x00\x00\x00r2\x00\x00\x00r\x13\x00\x00\x00r\'\x00\x00\x00r\x1e\x00\x00\x00r\x16\x00\x00\x00r\x1e\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\r\x00\x00\x00r\x11\x00\x00\x00r\x16\x00\x00\x00r\x0b\x00\x00\x00r\r\x00\x00\x00r\x10\x00\x00\x00r\x13\x00\x00\x00r#\x00\x00\x00r\x18\x00\x00\x00r\x18\x00\x00\x00r$\x00\x00\x00r\x0f\x00\x00\x00r\x11\x00\x00\x00r\x0c\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x11\x00\x00\x00r*\x00\x00\x00r\x0c\x00\x00\x00r\x11\x00\x00\x00r\x1c\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x18\x00\x00\x00r\x0c\x00\x00\x00r&\x00\x00\x00r\r\x00\x00\x00r\x11\x00\x00\x00r\x1f\x00\x00\x00r\x18\x00\x00\x00r\x12\x00\x00\x00r\x11\x00\x00\x00r4\x00\x00\x00r6\x00\x00\x00r\x0b\x00\x00\x00r\x0c\x00\x00\x00r\r\x00\x00\x00r\n\x00\x00\x00r#\x00\x00\x00r\x18\x00\x00\x00r\x18\x00\x00\x00r$\x00\x00\x00r\x0f\x00\x00\x00r\x11\x00\x00\x00r\x0c\x00\x00\x00r6\x00\x00\x00r5\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x11\x00\x00\x00r;\x00\x00\x00r\x0f\x00\x00\x00r\x16\x00\x00\x00r4\x00\x00\x00r6\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r?\x00\x00\x00r\x13\x00\x00\x00r\t\x00\x00\x00r\x13\x00\x00\x00r@\x00\x00\x00r\x13\x00\x00\x00r\x0c\x00\x00\x00r\x11\x00\x00\x00r\x0c\x00\x00\x00r\x0c\x00\x00\x00r\x0f\x00\x00\x00r\x18\x00\x00\x00r\x10\x00\x00\x00r\x13\x00\x00\x00r\'\x00\x00\x00r\x0f\x00\x00\x00r\x11\x00\x00\x00r6\x00\x00\x00r5\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x11\x00\x00\x00r;\x00\x00\x00r#\x00\x00\x00r\x11\x00\x00\x00r\x14\x00\x00\x00r\x16\x00\x00\x00r\x13\x00\x00\x00r"\x00\x00\x00r\x0f\x00\x00\x00r*\x00\x00\x00r\x11\x00\x00\x00r3\x00\x00\x00r\x18\x00\x00\x00r\x16\x00\x00\x00r"\x00\x00\x00r\x18\x00\x00\x00r\x0b\x00\x00\x00r\x10\x00\x00\x00r\'\x00\x00\x00r:\x00\x00\x00r\r\x00\x00\x00r\r\x00\x00\x00r\x18\x00\x00\x00r\r\x00\x00\x00r\x1c\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\r\x00\x00\x00r\x11\x00\x00\x00r\x16\x00\x00\x00r\x0b\x00\x00\x00r\r\x00\x00\x00r\x10\x00\x00\x00r\x13\x00\x00\x00r#\x00\x00\x00r\x11\x00\x00\x00r$\x00\x00\x00r4\x00\x00\x00r5\x00\x00\x00r\x1a\x00\x00\x00r\x1a\x00\x00\x00r\x08\x00\x00\x00r\x16\x00\x00\x00r\r\x00\x00\x00r\x15\x00\x00\x00r\x1c\x00\x00\x00r\x1a\x00\x00\x00r\x08\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x14\x00\x00\x00r\x1e\x00\x00\x00r\x16\x00\x00\x00r\x17\x00\x00\x00r\x13\x00\x00\x00r2\x00\x00\x00r\x13\x00\x00\x00r\x0c\x00\x00\x00r\x15\x00\x00\x00r\x0c\x00\x00\x00r&\x00\x00\x00r\x14\x00\x00\x00r\r\x00\x00\x00r\x11\x00\x00\x00r%\x00\x00\x00r\x0f\x00\x00\x00r;\x00\x00\x00r\x13\x00\x00\x00r9\x00\x00\x00r\x13\x00\x00\x00rA\x00\x00\x00r\n\x00\x00\x00r*\x00\x00\x00r\x0f\x00\x00\x00r\x0e\x00\x00\x00r\n\x00\x00\x00r\x14\x00\x00\x00r\x15\x00\x00\x00r\x16\x00\x00\x00r\x17\x00\x00\x00r\x18\x00\x00\x00r\x10\x00\x00\x00r\x19\x00\x00\x00r&\x00\x00\x00\xe98\x00\x00\x00r\n\x00\x00\x00r\'\x00\x00\x00r\x0f\x00\x00\x00r\x0c\x00\x00\x00r&\x00\x00\x00r\x14\x00\x00\x00r\x15\x00\x00\x00rA\x00\x00\x00r\x1a\x00\x00\x00r\x08\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x18\x00\x00\x00r\x0c\x00\x00\x00r&\x00\x00\x00r\x0c\x00\x00\x00r\x15\x00\x00\x00r\x0c\x00\x00\x00r\x16\x00\x00\x00r\x11\x00\x00\x00r\x1f\x00\x00\x00r4\x00\x00\x00r%\x00\x00\x00rA\x00\x00\x00r\r\x00\x00\x00r\x1f\x00\x00\x00r\x13\x00\x00\x00r?\x00\x00\x00r\x14\x00\x00\x00r\x1e\x00\x00\x00r\x16\x00\x00\x00r\x17\x00\x00\x00r@\x00\x00\x00rA\x00\x00\x00r5\x00\x00\x00r\x1a\x00\x00\x00r\x08\x00\x00\x00r\x11\x00\x00\x00r;\x00\x00\x00r#\x00\x00\x00r\x11\x00\x00\x00r\x14\x00\x00\x00r\x16\x00\x00\x00r\x13\x00\x00\x00r:\x00\x00\x00r;\x00\x00\x00r#\x00\x00\x00r\x11\x00\x00\x00r\x14\x00\x00\x00r\x16\x00\x00\x00r\x0f\x00\x00\x00r\x18\x00\x00\x00r\x10\x00\x00\x00r\x1c\x00\x00\x00r\x1a\x00\x00\x00r\x08\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x14\x00\x00\x00r\x1e\x00\x00\x00r\x0c\x00\x00\x00r\x0c\x00\x00\x00r\x1a\x00\x00\x00r\x1a\x00\x00\x00r\x0f\x00\x00\x00r%\x00\x00\x00r\x13\x00\x00\x00r6\x00\x00\x00r0\x00\x00\x00r0\x00\x00\x00r\x1f\x00\x00\x00r\x1e\x00\x00\x00r\x0f\x00\x00\x00r\x10\x00\x00\x00r0\x00\x00\x00r0\x00\x00\x00r6\x00\x00\x00r\x13\x00\x00\x00r2\x00\x00\x00r2\x00\x00\x00r\x13\x00\x00\x00r0\x00\x00\x00r0\x00\x00\x00r\x10\x00\x00\x00r\x1e\x00\x00\x00r\x1f\x00\x00\x00r\x11\x00\x00\x00r0\x00\x00\x00r0\x00\x00\x00r\x1c\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x16\x00\x00\x00r\r\x00\x00\x00r\x15\x00\x00\x00r\x1c\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x0f\x00\x00\x00r\x1f\x00\x00\x00r\x14\x00\x00\x00r\x18\x00\x00\x00r\r\x00\x00\x00r\x16\x00\x00\x00r\x13\x00\x00\x00r\r\x00\x00\x00r\x1e\x00\x00\x00r\x10\x00\x00\x00r\'\x00\x00\x00r\x18\x00\x00\x00r\x1f\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x0f\x00\x00\x00r\x1f\x00\x00\x00r\x14\x00\x00\x00r\x18\x00\x00\x00r\r\x00\x00\x00r\x16\x00\x00\x00r\x13\x00\x00\x00r\x0c\x00\x00\x00r\x0b\x00\x00\x00r\x0e\x00\x00\x00r\x14\x00\x00\x00r\r\x00\x00\x00r\x18\x00\x00\x00r#\x00\x00\x00r\x11\x00\x00\x00r\x0c\x00\x00\x00r\x0c\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r%\x00\x00\x00r\r\x00\x00\x00r\x18\x00\x00\x00r\x1f\x00\x00\x00r\x13\x00\x00\x00r+\x00\x00\x00r\x11\x00\x00\x00r\x16\x00\x00\x00r\x14\x00\x00\x00r\x1e\x00\x00\x00r\x0c\x00\x00\x00r\x0c\x00\x00\x00r\x13\x00\x00\x00r\x0f\x00\x00\x00r\x1f\x00\x00\x00r\x14\x00\x00\x00r\x18\x00\x00\x00r\r\x00\x00\x00r\x16\x00\x00\x00r\x13\x00\x00\x00r+\x00\x00\x00r\x11\x00\x00\x00r\x16\x00\x00\x00r\x14\x00\x00\x00r\x1e\x00\x00\x00r\x0c\x00\x00\x00r\x0c\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x18\x00\x00\x00r\x0c\x00\x00\x00r&\x00\x00\x00r\x0c\x00\x00\x00r\x15\x00\x00\x00r\x0c\x00\x00\x00r\x16\x00\x00\x00r\x11\x00\x00\x00r\x1f\x00\x00\x00r4\x00\x00\x00r6\x00\x00\x00r#\x00\x00\x00r*\x00\x00\x00r\x11\x00\x00\x00r\x1e\x00\x00\x00r\r\x00\x00\x00r6\x00\x00\x00r5\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x0e\x00\x00\x00r\x1e\x00\x00\x00r\x10\x00\x00\x00r\x10\x00\x00\x00r\x11\x00\x00\x00r\r\x00\x00\x00r&\x00\x00\x00r\x0e\x00\x00\x00r\x1e\x00\x00\x00r\x10\x00\x00\x00r\x10\x00\x00\x00r\x11\x00\x00\x00r\r\x00\x00\x00r4\x00\x00\x00r5\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x16\x00\x00\x00r\r\x00\x00\x00r\x15\x00\x00\x00r\x1c\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x0c\x00\x00\x00r\x17\x00\x00\x00r\x0b\x00\x00\x00r\x16\x00\x00\x00r\x0f\x00\x00\x00r*\x00\x00\x00r&\x00\x00\x00r\r\x00\x00\x00r\x1f\x00\x00\x00r\x16\x00\x00\x00r\r\x00\x00\x00r\x11\x00\x00\x00r\x11\x00\x00\x00r4\x00\x00\x00r6\x00\x00\x00r\x0b\x00\x00\x00r\x0c\x00\x00\x00r\r\x00\x00\x00r\n\x00\x00\x00r0\x00\x00\x00r0\x00\x00\x00r\x14\x00\x00\x00r\x15\x00\x00\x00r#\x00\x00\x00r\x1e\x00\x00\x00r#\x00\x00\x00r\x17\x00\x00\x00r\x11\x00\x00\x00r0\x00\x00\x00r0\x00\x00\x00r6\x00\x00\x00r5\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x0c\x00\x00\x00r\x17\x00\x00\x00r\x0b\x00\x00\x00r\x16\x00\x00\x00r\x0f\x00\x00\x00r*\x00\x00\x00r&\x00\x00\x00r\r\x00\x00\x00r\x1f\x00\x00\x00r\x16\x00\x00\x00r\r\x00\x00\x00r\x11\x00\x00\x00r\x11\x00\x00\x00r4\x00\x00\x00r6\x00\x00\x00r*\x00\x00\x00r\x0f\x00\x00\x00r\x0e\x00\x00\x00r\n\x00\x00\x00r0\x00\x00\x00r0\x00\x00\x00r\x14\x00\x00\x00r\x15\x00\x00\x00r#\x00\x00\x00r\x1e\x00\x00\x00r#\x00\x00\x00r\x17\x00\x00\x00r\x11\x00\x00\x00r0\x00\x00\x00r0\x00\x00\x00r6\x00\x00\x00r5\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x0c\x00\x00\x00r\x17\x00\x00\x00r\x0b\x00\x00\x00r\x16\x00\x00\x00r\x0f\x00\x00\x00r*\x00\x00\x00r&\x00\x00\x00r\r\x00\x00\x00r\x1f\x00\x00\x00r\x16\x00\x00\x00r\r\x00\x00\x00r\x11\x00\x00\x00r\x11\x00\x00\x00r4\x00\x00\x00r6\x00\x00\x00r&\x00\x00\x00r\n\x00\x00\x00r0\x00\x00\x00r0\x00\x00\x00r\x14\x00\x00\x00r\x15\x00\x00\x00r#\x00\x00\x00r\x1e\x00\x00\x00r#\x00\x00\x00r\x17\x00\x00\x00r\x11\x00\x00\x00r0\x00\x00\x00r0\x00\x00\x00r6\x00\x00\x00r5\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x11\x00\x00\x00r;\x00\x00\x00r#\x00\x00\x00r\x11\x00\x00\x00r\x14\x00\x00\x00r\x16\x00\x00\x00r\x13\x00\x00\x00r"\x00\x00\x00r\x0f\x00\x00\x00r*\x00\x00\x00r\x11\x00\x00\x00r3\x00\x00\x00r\x18\x00\x00\x00r\x16\x00\x00\x00r"\x00\x00\x00r\x18\x00\x00\x00r\x0b\x00\x00\x00r\x10\x00\x00\x00r\'\x00\x00\x00r:\x00\x00\x00r\r\x00\x00\x00r\r\x00\x00\x00r\x18\x00\x00\x00r\r\x00\x00\x00r\x1c\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x14\x00\x00\x00r\x1e\x00\x00\x00r\x0c\x00\x00\x00r\x0c\x00\x00\x00r\x1a\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\'\x00\x00\x00r\x11\x00\x00\x00r%\x00\x00\x00r\x13\x00\x00\x00r\x11\x00\x00\x00r#\x00\x00\x00r\x17\x00\x00\x00r\x18\x00\x00\x00r4\x00\x00\x00r#\x00\x00\x00r\x18\x00\x00\x00r\x1f\x00\x00\x00r\x1f\x00\x00\x00r\x1e\x00\x00\x00r\x10\x00\x00\x00r\'\x00\x00\x00r-\x00\x00\x00r\x13\x00\x00\x00r\x1e\x00\x00\x00r\r\x00\x00\x00r+\x00\x00\x00r-\x00\x00\x00r\x13\x00\x00\x00r\x1e\x00\x00\x00r\r\x00\x00\x00r+\x00\x00\x00r\x0c\x00\x00\x00r5\x00\x00\x00r\x1c\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\r\x00\x00\x00r\x11\x00\x00\x00r\x16\x00\x00\x00r\x0b\x00\x00\x00r\r\x00\x00\x00r\x10\x00\x00\x00r\x13\x00\x00\x00r4\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x0c\x00\x00\x00r\x0b\x00\x00\x00r\x0e\x00\x00\x00r\x14\x00\x00\x00r\r\x00\x00\x00r\x18\x00\x00\x00r#\x00\x00\x00r\x11\x00\x00\x00r\x0c\x00\x00\x00r\x0c\x00\x00\x00r&\x00\x00\x00rJ\x00\x00\x00r\x18\x00\x00\x00r\x14\x00\x00\x00r\x11\x00\x00\x00r\x10\x00\x00\x00r4\x00\x00\x00r=\x00\x00\x00r#\x00\x00\x00r\x18\x00\x00\x00r\x1f\x00\x00\x00r\x1f\x00\x00\x00r\x1e\x00\x00\x00r\x10\x00\x00\x00r\'\x00\x00\x00r-\x00\x00\x00r\x13\x00\x00\x00r\x1e\x00\x00\x00r\r\x00\x00\x00r+\x00\x00\x00r-\x00\x00\x00r\x13\x00\x00\x00r\x1e\x00\x00\x00r\r\x00\x00\x00r+\x00\x00\x00r\x0c\x00\x00\x00r>\x00\x00\x00r-\x00\x00\x00r\x13\x00\x00\x00r\x0c\x00\x00\x00r\x16\x00\x00\x00r\'\x00\x00\x00r\x18\x00\x00\x00r\x0b\x00\x00\x00r\x16\x00\x00\x00r2\x00\x00\x00r\x0c\x00\x00\x00r\x0b\x00\x00\x00r\x0e\x00\x00\x00r\x14\x00\x00\x00r\r\x00\x00\x00r\x18\x00\x00\x00r#\x00\x00\x00r\x11\x00\x00\x00r\x0c\x00\x00\x00r\x0c\x00\x00\x00r&\x00\x00\x00rJ\x00\x00\x00rG\x00\x00\x00rJ\x00\x00\x00r:\x00\x00\x00r5\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r&\x00\x00\x00r\x0c\x00\x00\x00r\x16\x00\x00\x00r\'\x00\x00\x00r\x18\x00\x00\x00r\x0b\x00\x00\x00r\x16\x00\x00\x00r&\x00\x00\x00r\r\x00\x00\x00r\x11\x00\x00\x00r\x1e\x00\x00\x00r\'\x00\x00\x00r4\x00\x00\x00r5\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r&\x00\x00\x00r\'\x00\x00\x00r\x11\x00\x00\x00r#\x00\x00\x00r\x18\x00\x00\x00r\'\x00\x00\x00r\x11\x00\x00\x00r4\x00\x00\x00r5\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r&\x00\x00\x00r\x0c\x00\x00\x00r\x16\x00\x00\x00r\r\x00\x00\x00r\x0f\x00\x00\x00r\x14\x00\x00\x00r4\x00\x00\x00r5\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r5\x00\x00\x00r\x1a\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x16\x00\x00\x00r\r\x00\x00\x00r\x15\x00\x00\x00r\x1c\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x0b\x00\x00\x00r\x0f\x00\x00\x00r\'\x00\x00\x00r\x13\x00\x00\x00r2\x00\x00\x00r\x13\x00\x00\x00r\x0c\x00\x00\x00r\x16\x00\x00\x00r\r\x00\x00\x00r4\x00\x00\x00r\x18\x00\x00\x00r\x0c\x00\x00\x00r&\x00\x00\x00r+\x00\x00\x00r\x11\x00\x00\x00r\x16\x00\x00\x00r\x11\x00\x00\x00r\x0b\x00\x00\x00r\x0f\x00\x00\x00r\'\x00\x00\x00r4\x00\x00\x00r5\x00\x00\x00r5\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x0b\x00\x00\x00r\x0c\x00\x00\x00r\x11\x00\x00\x00r\r\x00\x00\x00r\x13\x00\x00\x00r2\x00\x00\x00r\x13\x00\x00\x00r\r\x00\x00\x00r\x11\x00\x00\x00r.\x00\x00\x00r\x0b\x00\x00\x00r\x11\x00\x00\x00r\x0c\x00\x00\x00r\x16\x00\x00\x00r\x0c\x00\x00\x00r&\x00\x00\x00r+\x00\x00\x00r\x11\x00\x00\x00r\x16\x00\x00\x00r4\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r6\x00\x00\x00r\x17\x00\x00\x00r\x16\x00\x00\x00r\x16\x00\x00\x00r\x14\x00\x00\x00r\x0c\x00\x00\x00r\x1c\x00\x00\x00r\n\x00\x00\x00r\n\x00\x00\x00r\x1e\x00\x00\x00r\x0c\x00\x00\x00r\x1f\x00\x00\x00r\x0f\x00\x00\x00r\x10\x00\x00\x00r&\x00\x00\x00r\x14\x00\x00\x00r\x15\x00\x00\x00r\x16\x00\x00\x00r\x17\x00\x00\x00r\x18\x00\x00\x00r\x10\x00\x00\x00r\x1e\x00\x00\x00r\x10\x00\x00\x00r\x15\x00\x00\x00rC\x00\x00\x00r\x17\x00\x00\x00r\x11\x00\x00\x00r\r\x00\x00\x00r\x11\x00\x00\x00r&\x00\x00\x00r#\x00\x00\x00r\x18\x00\x00\x00r\x1f\x00\x00\x00r\n\x00\x00\x00r\x1f\x00\x00\x00r\x11\x00\x00\x00r\x1f\x00\x00\x00r\x0e\x00\x00\x00r\x11\x00\x00\x00r\r\x00\x00\x00r\n\x00\x00\x00r6\x00\x00\x00r\x13\x00\x00\x00r9\x00\x00\x00r\x13\x00\x00\x00r\x0b\x00\x00\x00r\x0f\x00\x00\x00r\'\x00\x00\x00r5\x00\x00\x00r&\x00\x00\x00rN\x00\x00\x00r\x0c\x00\x00\x00r\x18\x00\x00\x00r\x10\x00\x00\x00r4\x00\x00\x00r5\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x14\x00\x00\x00r\r\x00\x00\x00r\x0f\x00\x00\x00r\x10\x00\x00\x00r\x16\x00\x00\x00r4\x00\x00\x00r6\x00\x00\x00r7\x00\x00\x00r\x10\x00\x00\x00r6\x00\x00\x00r5\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x0f\x00\x00\x00r%\x00\x00\x00r\x13\x00\x00\x00r6\x00\x00\x00r\'\x00\x00\x00r\x11\x00\x00\x00r\x12\x00\x00\x00r\x0f\x00\x00\x00r#\x00\x00\x00r\x11\x00\x00\x00r\x13\x00\x00\x00r\x0f\x00\x00\x00r\'\x00\x00\x00r\x13\x00\x00\x00r\x10\x00\x00\x00r\x18\x00\x00\x00r\x16\x00\x00\x00r\x13\x00\x00\x00r%\x00\x00\x00r\x18\x00\x00\x00r\x0b\x00\x00\x00r\x10\x00\x00\x00r\'\x00\x00\x00r6\x00\x00\x00r\x13\x00\x00\x00r\x0f\x00\x00\x00r\x10\x00\x00\x00r\x13\x00\x00\x00r\x0c\x00\x00\x00r\x16\x00\x00\x00r\r\x00\x00\x00r4\x00\x00\x00r\x0b\x00\x00\x00r\x0c\x00\x00\x00r\x11\x00\x00\x00r\r\x00\x00\x00r5\x00\x00\x00r\x13\x00\x00\x00r\x18\x00\x00\x00r\r\x00\x00\x00r\x13\x00\x00\x00r6\x00\x00\x00r\x10\x00\x00\x00r\x18\x00\x00\x00r\x13\x00\x00\x00r\x0b\x00\x00\x00r\x0c\x00\x00\x00r\x11\x00\x00\x00r\r\x00\x00\x00r\x0c\x00\x00\x00r6\x00\x00\x00r\x13\x00\x00\x00r\x0f\x00\x00\x00r\x10\x00\x00\x00r\x13\x00\x00\x00r\x0c\x00\x00\x00r\x16\x00\x00\x00r\r\x00\x00\x00r4\x00\x00\x00r\x0b\x00\x00\x00r\x0c\x00\x00\x00r\x11\x00\x00\x00r\r\x00\x00\x00r5\x00\x00\x00r\x1c\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x14\x00\x00\x00r\x1e\x00\x00\x00r\x16\x00\x00\x00r\x17\x00\x00\x00r\x13\x00\x00\x00r2\x00\x00\x00r\x13\x00\x00\x00r\x0c\x00\x00\x00r\x15\x00\x00\x00r\x0c\x00\x00\x00r&\x00\x00\x00r\x14\x00\x00\x00r\r\x00\x00\x00r\x11\x00\x00\x00r%\x00\x00\x00r\x0f\x00\x00\x00r;\x00\x00\x00r\x13\x00\x00\x00r9\x00\x00\x00r\x13\x00\x00\x00rA\x00\x00\x00r\n\x00\x00\x00r\x0e\x00\x00\x00r\x0f\x00\x00\x00r\x10\x00\x00\x00r\n\x00\x00\x00r&\x00\x00\x00r\x1d\x00\x00\x00r\x11\x00\x00\x00r\x16\x00\x00\x00rA\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x0f\x00\x00\x00r%\x00\x00\x00r\x13\x00\x00\x00r\x18\x00\x00\x00r\x0c\x00\x00\x00r&\x00\x00\x00r\x14\x00\x00\x00r\x1e\x00\x00\x00r\x16\x00\x00\x00r\x17\x00\x00\x00r&\x00\x00\x00r\x11\x00\x00\x00r;\x00\x00\x00r\x0f\x00\x00\x00r\x0c\x00\x00\x00r\x16\x00\x00\x00r\x0c\x00\x00\x00r4\x00\x00\x00r\x14\x00\x00\x00r\x1e\x00\x00\x00r\x16\x00\x00\x00r\x17\x00\x00\x00r5\x00\x00\x00r\x1c\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r%\x00\x00\x00r\x0f\x00\x00\x00r\x10\x00\x00\x00r\x1e\x00\x00\x00r*\x00\x00\x00r\x0f\x00\x00\x00r\'\x00\x00\x00r\x13\x00\x00\x00r2\x00\x00\x00r\x13\x00\x00\x00r\x18\x00\x00\x00r\x14\x00\x00\x00r\x11\x00\x00\x00r\x10\x00\x00\x00r4\x00\x00\x00r\x14\x00\x00\x00r\x1e\x00\x00\x00r\x16\x00\x00\x00r\x17\x00\x00\x00r5\x00\x00\x00r&\x00\x00\x00r\r\x00\x00\x00r\x11\x00\x00\x00r\x1e\x00\x00\x00r\'\x00\x00\x00r4\x00\x00\x00r5\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x14\x00\x00\x00r\r\x00\x00\x00r\x0f\x00\x00\x00r\x10\x00\x00\x00r\x16\x00\x00\x00r4\x00\x00\x00rA\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r?\x00\x00\x00r\x13\x00\x00\x00r\t\x00\x00\x00r\x13\x00\x00\x00r@\x00\x00\x00r\x13\x00\x00\x00\xe9Y\x00\x00\x00r\x18\x00\x00\x00r\x0b\x00\x00\x00r\r\x00\x00\x00r\x13\x00\x00\x00r\x0f\x00\x00\x00r\'\x00\x00\x00r\x1c\x00\x00\x00r\x13\x00\x00\x00r<\x00\x00\x00r\x0c\x00\x00\x00rA\x00\x00\x00r<\x00\x00\x00r%\x00\x00\x00r\x0f\x00\x00\x00r\x10\x00\x00\x00r\x1e\x00\x00\x00r*\x00\x00\x00r\x0f\x00\x00\x00r\'\x00\x00\x00r5\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x14\x00\x00\x00r\r\x00\x00\x00r\x0f\x00\x00\x00r\x10\x00\x00\x00r\x16\x00\x00\x00r4\x00\x00\x00r6\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r?\x00\x00\x00r\x13\x00\x00\x00r\t\x00\x00\x00r\x13\x00\x00\x00r@\x00\x00\x00r\x13\x00\x00\x00r3\x00\x00\x00r\x18\x00\x00\x00r\x16\x00\x00\x00r\x13\x00\x00\x00r#\x00\x00\x00r\x18\x00\x00\x00r\x1f\x00\x00\x00r%\x00\x00\x00r\x0f\x00\x00\x00r\r\x00\x00\x00r\x1f\x00\x00\x00r\x11\x00\x00\x00r\'\x00\x00\x00r\x13\x00\x00\x00r\x15\x00\x00\x00r\x11\x00\x00\x00r\x16\x00\x00\x00r&\x00\x00\x00r\x13\x00\x00\x00rJ\x00\x00\x00r\r\x00\x00\x00r\x11\x00\x00\x00r\x0c\x00\x00\x00r\x0c\x00\x00\x00r\x13\x00\x00\x00r\x11\x00\x00\x00r\x10\x00\x00\x00r\x16\x00\x00\x00r\x11\x00\x00\x00r\r\x00\x00\x00r\x13\x00\x00\x00r\x16\x00\x00\x00r\x18\x00\x00\x00r\x13\x00\x00\x00r#\x00\x00\x00r\x18\x00\x00\x00r\x10\x00\x00\x00r%\x00\x00\x00r\x0f\x00\x00\x00r\r\x00\x00\x00r\x1f\x00\x00\x00r6\x00\x00\x00r5\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x11\x00\x00\x00r*\x00\x00\x00r\x0c\x00\x00\x00r\x11\x00\x00\x00r\x1c\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x14\x00\x00\x00r\r\x00\x00\x00r\x0f\x00\x00\x00r\x10\x00\x00\x00r\x16\x00\x00\x00r4\x00\x00\x00r6\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r=\x00\x00\x00r\x13\x00\x00\x00rG\x00\x00\x00r3\x00\x00\x00r"\x00\x00\x00\xe9O\x00\x00\x00r\x13\x00\x00\x00r>\x00\x00\x00r\x13\x00\x00\x00rW\x00\x00\x00r\x18\x00\x00\x00r\x0b\x00\x00\x00r\r\x00\x00\x00r\x13\x00\x00\x00r\'\x00\x00\x00r\x11\x00\x00\x00r\x12\x00\x00\x00r\x0f\x00\x00\x00r#\x00\x00\x00r\x11\x00\x00\x00r\'\x00\x00\x00r\x13\x00\x00\x00r\x0f\x00\x00\x00r\x0c\x00\x00\x00r\x13\x00\x00\x00r\x10\x00\x00\x00r\x18\x00\x00\x00r\x16\x00\x00\x00r\x13\x00\x00\x00r\r\x00\x00\x00r\x11\x00\x00\x00r+\x00\x00\x00r\x0f\x00\x00\x00r\x0c\x00\x00\x00r\x16\x00\x00\x00r\x11\x00\x00\x00r\r\x00\x00\x00r\x11\x00\x00\x00r\'\x00\x00\x00r\x13\x00\x00\x00r\x15\x00\x00\x00r\x11\x00\x00\x00r\x16\x00\x00\x00r6\x00\x00\x00r5\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x14\x00\x00\x00r\r\x00\x00\x00r\x0f\x00\x00\x00r\x10\x00\x00\x00r\x16\x00\x00\x00r4\x00\x00\x00r6\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00rJ\x00\x00\x00r*\x00\x00\x00r\x11\x00\x00\x00r\x1e\x00\x00\x00r\x0c\x00\x00\x00r\x11\x00\x00\x00r\x13\x00\x00\x00r\r\x00\x00\x00r\x11\x00\x00\x00r+\x00\x00\x00r\x0f\x00\x00\x00r\x0c\x00\x00\x00r\x16\x00\x00\x00r\x11\x00\x00\x00r\r\x00\x00\x00r\x13\x00\x00\x00r%\x00\x00\x00r\x0f\x00\x00\x00r\r\x00\x00\x00r\x0c\x00\x00\x00r\x16\x00\x00\x00r\t\x00\x00\x00r7\x00\x00\x00r\x10\x00\x00\x00r6\x00\x00\x00r5\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x14\x00\x00\x00r\r\x00\x00\x00r\x0f\x00\x00\x00r\x10\x00\x00\x00r\x16\x00\x00\x00r4\x00\x00\x00r6\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r(\x00\x00\x00r5\x00\x00\x00r&\x00\x00\x00r\x13\x00\x00\x00r)\x00\x00\x00r\r\x00\x00\x00r\x0f\x00\x00\x00r\x1e\x00\x00\x00r*\x00\x00\x00r\x13\x00\x00\x00r\x18\x00\x00\x00r\x10\x00\x00\x00r\x11\x00\x00\x00r\x13\x00\x00\x00r\'\x00\x00\x00r\x1e\x00\x00\x00r\x15\x00\x00\x00r6\x00\x00\x00r5\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x14\x00\x00\x00r\r\x00\x00\x00r\x0f\x00\x00\x00r\x10\x00\x00\x00r\x16\x00\x00\x00r4\x00\x00\x00r6\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00rB\x00\x00\x00r5\x00\x00\x00r&\x00\x00\x00r\x13\x00\x00\x00\xe9B\x00\x00\x00r\x0b\x00\x00\x00r\x15\x00\x00\x00r\x13\x00\x00\x00r\x19\x00\x00\x00rE\x00\x00\x00r$\x00\x00\x00r\n\x00\x00\x00r\x19\x00\x00\x00\xe9$\x00\x00\x00r\x13\x00\x00\x00r(\x00\x00\x00r\x13\x00\x00\x00r/\x00\x00\x00r\x18\x00\x00\x00r\x10\x00\x00\x00r\x16\x00\x00\x00r\x17\x00\x00\x00r6\x00\x00\x00r5\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x14\x00\x00\x00r\r\x00\x00\x00r\x0f\x00\x00\x00r\x10\x00\x00\x00r\x16\x00\x00\x00r4\x00\x00\x00r6\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x19\x00\x00\x00r5\x00\x00\x00r&\x00\x00\x00r\x13\x00\x00\x00rY\x00\x00\x00r\x0b\x00\x00\x00r\x15\x00\x00\x00r\x13\x00\x00\x00rR\x00\x00\x00rE\x00\x00\x00r$\x00\x00\x00r\n\x00\x00\x00rR\x00\x00\x00rZ\x00\x00\x00r\x13\x00\x00\x00rB\x00\x00\x00r\x13\x00\x00\x00r/\x00\x00\x00r\x18\x00\x00\x00r\x10\x00\x00\x00r\x16\x00\x00\x00r\x17\x00\x00\x00r6\x00\x00\x00r5\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x14\x00\x00\x00r\r\x00\x00\x00r\x0f\x00\x00\x00r\x10\x00\x00\x00r\x16\x00\x00\x00r4\x00\x00\x00r6\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00rK\x00\x00\x00r5\x00\x00\x00r&\x00\x00\x00r\x13\x00\x00\x00rY\x00\x00\x00r\x0b\x00\x00\x00r\x15\x00\x00\x00r\x13\x00\x00\x00r(\x00\x00\x00rE\x00\x00\x00rE\x00\x00\x00r$\x00\x00\x00r\n\x00\x00\x00r(\x00\x00\x00rE\x00\x00\x00rZ\x00\x00\x00r\x13\x00\x00\x00rR\x00\x00\x00r\x13\x00\x00\x00r/\x00\x00\x00r\x18\x00\x00\x00r\x10\x00\x00\x00r\x16\x00\x00\x00r\x17\x00\x00\x00r7\x00\x00\x00r\x10\x00\x00\x00r6\x00\x00\x00r5\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r#\x00\x00\x00r\x17\x00\x00\x00r\x18\x00\x00\x00r\x0f\x00\x00\x00r#\x00\x00\x00r\x11\x00\x00\x00r\x13\x00\x00\x00r2\x00\x00\x00r\x13\x00\x00\x00r\x0f\x00\x00\x00r\x10\x00\x00\x00r\x14\x00\x00\x00r\x0b\x00\x00\x00r\x16\x00\x00\x00r4\x00\x00\x00r6\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r?\x00\x00\x00r\x13\x00\x00\x00r\t\x00\x00\x00r\x13\x00\x00\x00r@\x00\x00\x00r\x13\x00\x00\x00rM\x00\x00\x00r\x11\x00\x00\x00r*\x00\x00\x00r\x11\x00\x00\x00r#\x00\x00\x00r\x16\x00\x00\x00r\x13\x00\x00\x00r#\x00\x00\x00r\x17\x00\x00\x00r\x18\x00\x00\x00r\x0f\x00\x00\x00r#\x00\x00\x00r\x11\x00\x00\x00r\x1c\x00\x00\x00r\x13\x00\x00\x00r6\x00\x00\x00r5\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x0f\x00\x00\x00r%\x00\x00\x00r\x13\x00\x00\x00r#\x00\x00\x00r\x17\x00\x00\x00r\x18\x00\x00\x00r\x0f\x00\x00\x00r#\x00\x00\x00r\x11\x00\x00\x00r\x13\x00\x00\x00r2\x00\x00\x00r2\x00\x00\x00r\x13\x00\x00\x00r6\x00\x00\x00r(\x00\x00\x00r6\x00\x00\x00r\x1c\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r$\x00\x00\x00r\x18\x00\x00\x00r\'\x00\x00\x00r\x11\x00\x00\x00r\x13\x00\x00\x00r2\x00\x00\x00r\x13\x00\x00\x00r=\x00\x00\x00r6\x00\x00\x00r)\x00\x00\x00\xe9R\x00\x00\x00r6\x00\x00\x00r-\x00\x00\x00r\x13\x00\x00\x00r6\x00\x00\x00r\x1b\x00\x00\x00r8\x00\x00\x00r6\x00\x00\x00r>\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x1f\x00\x00\x00r\x1e\x00\x00\x00r\x0c\x00\x00\x00r\x1e\x00\x00\x00r\x13\x00\x00\x00r2\x00\x00\x00r\x13\x00\x00\x00r6\x00\x00\x00r\x16\x00\x00\x00r\r\x00\x00\x00r\x0f\x00\x00\x00r\x1e\x00\x00\x00r*\x00\x00\x00r6\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x11\x00\x00\x00r*\x00\x00\x00r\x0f\x00\x00\x00r%\x00\x00\x00r\x13\x00\x00\x00r#\x00\x00\x00r\x17\x00\x00\x00r\x18\x00\x00\x00r\x0f\x00\x00\x00r#\x00\x00\x00r\x11\x00\x00\x00r\x13\x00\x00\x00r2\x00\x00\x00r2\x00\x00\x00r\x13\x00\x00\x00r6\x00\x00\x00rB\x00\x00\x00r6\x00\x00\x00r\x1c\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r$\x00\x00\x00r\x18\x00\x00\x00r\'\x00\x00\x00r\x11\x00\x00\x00r\x13\x00\x00\x00r2\x00\x00\x00r\x13\x00\x00\x00r=\x00\x00\x00r6\x00\x00\x00rX\x00\x00\x00r\x10\x00\x00\x00r6\x00\x00\x00r-\x00\x00\x00r\x13\x00\x00\x00r6\x00\x00\x00rX\x00\x00\x00r\x10\x00\x00\x00r6\x00\x00\x00r>\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x1f\x00\x00\x00r\x1e\x00\x00\x00r\x0c\x00\x00\x00r\x1e\x00\x00\x00r\x13\x00\x00\x00r2\x00\x00\x00r\x13\x00\x00\x00r6\x00\x00\x00r\'\x00\x00\x00r\x1e\x00\x00\x00r\x15\x00\x00\x00r\x0c\x00\x00\x00r\x0c\x00\x00\x00r6\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x11\x00\x00\x00r*\x00\x00\x00r\x0f\x00\x00\x00r%\x00\x00\x00r\x13\x00\x00\x00r#\x00\x00\x00r\x17\x00\x00\x00r\x18\x00\x00\x00r\x0f\x00\x00\x00r#\x00\x00\x00r\x11\x00\x00\x00r\x13\x00\x00\x00r2\x00\x00\x00r2\x00\x00\x00r\x13\x00\x00\x00r6\x00\x00\x00r\x19\x00\x00\x00r6\x00\x00\x00r\x1c\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r$\x00\x00\x00r\x18\x00\x00\x00r\'\x00\x00\x00r\x11\x00\x00\x00r\x13\x00\x00\x00r2\x00\x00\x00r\x13\x00\x00\x00r=\x00\x00\x00r6\x00\x00\x00r/\x00\x00\x00r\x18\x00\x00\x00r6\x00\x00\x00r-\x00\x00\x00r\x13\x00\x00\x00r6\x00\x00\x00r)\x00\x00\x00rC\x00\x00\x00r6\x00\x00\x00r>\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x1f\x00\x00\x00r\x1e\x00\x00\x00r\x0c\x00\x00\x00r\x1e\x00\x00\x00r\x13\x00\x00\x00r2\x00\x00\x00r\x13\x00\x00\x00r6\x00\x00\x00r\x1f\x00\x00\x00r\x18\x00\x00\x00r\x10\x00\x00\x00r\x16\x00\x00\x00r\x17\x00\x00\x00r6\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x11\x00\x00\x00r*\x00\x00\x00r\x0f\x00\x00\x00r%\x00\x00\x00r\x13\x00\x00\x00r#\x00\x00\x00r\x17\x00\x00\x00r\x18\x00\x00\x00r\x0f\x00\x00\x00r#\x00\x00\x00r\x11\x00\x00\x00r\x13\x00\x00\x00r2\x00\x00\x00r2\x00\x00\x00r\x13\x00\x00\x00r6\x00\x00\x00rK\x00\x00\x00r6\x00\x00\x00r\x1c\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r$\x00\x00\x00r\x18\x00\x00\x00r\'\x00\x00\x00r\x11\x00\x00\x00r\x13\x00\x00\x00r2\x00\x00\x00r\x13\x00\x00\x00r=\x00\x00\x00r6\x00\x00\x00rW\x00\x00\x00r\x11\x00\x00\x00r6\x00\x00\x00r-\x00\x00\x00r\x13\x00\x00\x00r6\x00\x00\x00rX\x00\x00\x00rW\x00\x00\x00r6\x00\x00\x00r>\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x1f\x00\x00\x00r\x1e\x00\x00\x00r\x0c\x00\x00\x00r\x1e\x00\x00\x00r\x13\x00\x00\x00r2\x00\x00\x00r\x13\x00\x00\x00r6\x00\x00\x00r\x15\x00\x00\x00r\x11\x00\x00\x00r\x1e\x00\x00\x00r\r\x00\x00\x00r\x0c\x00\x00\x00r6\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x10\x00\x00\x00r\x1e\x00\x00\x00r\x1f\x00\x00\x00r\x11\x00\x00\x00r\x13\x00\x00\x00r2\x00\x00\x00r\x13\x00\x00\x00r\x0f\x00\x00\x00r\x10\x00\x00\x00r\x14\x00\x00\x00r\x0b\x00\x00\x00r\x16\x00\x00\x00r4\x00\x00\x00r6\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r?\x00\x00\x00r\x13\x00\x00\x00r\t\x00\x00\x00r\x13\x00\x00\x00r@\x00\x00\x00r\x13\x00\x00\x00rW\x00\x00\x00r\x18\x00\x00\x00r\x0b\x00\x00\x00r\r\x00\x00\x00r\x13\x00\x00\x00r\x10\x00\x00\x00r\x1e\x00\x00\x00r\x1f\x00\x00\x00r\x11\x00\x00\x00r\x1c\x00\x00\x00r\x13\x00\x00\x00r6\x00\x00\x00r5\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r%\x00\x00\x00r\x0f\x00\x00\x00r\x10\x00\x00\x00r\x1e\x00\x00\x00r*\x00\x00\x00r\x0f\x00\x00\x00r\'\x00\x00\x00r\x13\x00\x00\x00r2\x00\x00\x00r\x13\x00\x00\x00r4\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r$\x00\x00\x00r\x18\x00\x00\x00r\'\x00\x00\x00r\x11\x00\x00\x00r=\x00\x00\x00rE\x00\x00\x00r>\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r9\x00\x00\x00r\x13\x00\x00\x00r\r\x00\x00\x00r\x1e\x00\x00\x00r\x10\x00\x00\x00r\'\x00\x00\x00r\x18\x00\x00\x00r\x1f\x00\x00\x00r&\x00\x00\x00r#\x00\x00\x00r\x17\x00\x00\x00r\x18\x00\x00\x00r\x0f\x00\x00\x00r#\x00\x00\x00r\x11\x00\x00\x00r4\x00\x00\x00r*\x00\x00\x00r\x0f\x00\x00\x00r\x0c\x00\x00\x00r\x16\x00\x00\x00r4\x00\x00\x00r6\x00\x00\x00r\x1b\x00\x00\x00r\x0e\x00\x00\x00r\x1b\x00\x00\x00r1\x00\x00\x00rT\x00\x00\x00rW\x00\x00\x00r\x10\x00\x00\x00r"\x00\x00\x00rM\x00\x00\x00r\x1e\x00\x00\x00r\x11\x00\x00\x00r.\x00\x00\x00rQ\x00\x00\x00r6\x00\x00\x00r5\x00\x00\x00r\x13\x00\x00\x00r9\x00\x00\x00r\x13\x00\x00\x00r*\x00\x00\x00r\x0f\x00\x00\x00r\x0c\x00\x00\x00r\x16\x00\x00\x00r4\x00\x00\x00r6\x00\x00\x00rC\x00\x00\x00r;\x00\x00\x00rN\x00\x00\x00r$\x00\x00\x00r\x1f\x00\x00\x00r\x17\x00\x00\x00r\'\x00\x00\x00r\x11\x00\x00\x00r\x0f\x00\x00\x00r\x11\x00\x00\x00r6\x00\x00\x00r5\x00\x00\x00r5\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r9\x00\x00\x00r\x13\x00\x00\x00r$\x00\x00\x00r\x18\x00\x00\x00r\'\x00\x00\x00r\x11\x00\x00\x00r=\x00\x00\x00rE\x00\x00\x00r>\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r9\x00\x00\x00r\x13\x00\x00\x00r\x0b\x00\x00\x00r\x0f\x00\x00\x00r\'\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r9\x00\x00\x00r\x13\x00\x00\x00r$\x00\x00\x00r\x18\x00\x00\x00r\'\x00\x00\x00r\x11\x00\x00\x00r=\x00\x00\x00r(\x00\x00\x00r>\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r9\x00\x00\x00r\x13\x00\x00\x00r\x1f\x00\x00\x00r\x1e\x00\x00\x00r\x0c\x00\x00\x00r\x1e\x00\x00\x00r&\x00\x00\x00r\x0b\x00\x00\x00r\x14\x00\x00\x00r\x14\x00\x00\x00r\x11\x00\x00\x00r\r\x00\x00\x00r4\x00\x00\x00r5\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r5\x00\x00\x00r=\x00\x00\x00r\x1c\x00\x00\x00r\x1c\x00\x00\x00rP\x00\x00\x00r(\x00\x00\x00r>\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\r\x00\x00\x00r\x11\x00\x00\x00r.\x00\x00\x00r\x0b\x00\x00\x00r\x11\x00\x00\x00r\x0c\x00\x00\x00r\x16\x00\x00\x00r\x0c\x00\x00\x00r&\x00\x00\x00r+\x00\x00\x00r\x11\x00\x00\x00r\x16\x00\x00\x00r4\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r6\x00\x00\x00r\x17\x00\x00\x00r\x16\x00\x00\x00r\x16\x00\x00\x00r\x14\x00\x00\x00r\x0c\x00\x00\x00r\x1c\x00\x00\x00r\n\x00\x00\x00r\n\x00\x00\x00r\x1e\x00\x00\x00r\x0c\x00\x00\x00r\x1f\x00\x00\x00r\x0f\x00\x00\x00r\x10\x00\x00\x00r&\x00\x00\x00r\x14\x00\x00\x00r\x15\x00\x00\x00r\x16\x00\x00\x00r\x17\x00\x00\x00r\x18\x00\x00\x00r\x10\x00\x00\x00r\x1e\x00\x00\x00r\x10\x00\x00\x00r\x15\x00\x00\x00rC\x00\x00\x00r\x17\x00\x00\x00r\x11\x00\x00\x00r\r\x00\x00\x00r\x11\x00\x00\x00r&\x00\x00\x00r#\x00\x00\x00r\x18\x00\x00\x00r\x1f\x00\x00\x00r\n\x00\x00\x00r\x0c\x00\x00\x00r\x0f\x00\x00\x00r+\x00\x00\x00r\x10\x00\x00\x00r\x0f\x00\x00\x00r\x10\x00\x00\x00r,\x00\x00\x00r\r\x00\x00\x00r\x1e\x00\x00\x00rC\x00\x00\x00r2\x00\x00\x00r6\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r9\x00\x00\x00r\x13\x00\x00\x00r%\x00\x00\x00r\x0f\x00\x00\x00r\x10\x00\x00\x00r\x1e\x00\x00\x00r*\x00\x00\x00r\x0f\x00\x00\x00r\'\x00\x00\x00r5\x00\x00\x00r&\x00\x00\x00r\x16\x00\x00\x00r\x11\x00\x00\x00r;\x00\x00\x00r\x16\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x14\x00\x00\x00r\r\x00\x00\x00r\x0f\x00\x00\x00r\x10\x00\x00\x00r\x16\x00\x00\x00r4\x00\x00\x00r6\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r?\x00\x00\x00r\x13\x00\x00\x00r\t\x00\x00\x00r\x13\x00\x00\x00r@\x00\x00\x00r\x13\x00\x00\x00rW\x00\x00\x00r\x18\x00\x00\x00r\x0b\x00\x00\x00r\r\x00\x00\x00r\x13\x00\x00\x00rG\x00\x00\x00r1\x00\x00\x00r\x13\x00\x00\x00r\x1c\x00\x00\x00r\x13\x00\x00\x00r6\x00\x00\x00r\x13\x00\x00\x00r9\x00\x00\x00r\x13\x00\x00\x00r%\x00\x00\x00r\x0f\x00\x00\x00r\x10\x00\x00\x00r\x1e\x00\x00\x00r*\x00\x00\x00r\x0f\x00\x00\x00r\'\x00\x00\x00r5\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00rC\x00\x00\x00r\x0f\x00\x00\x00r\x16\x00\x00\x00r\x17\x00\x00\x00r\x13\x00\x00\x00r\x18\x00\x00\x00r\x14\x00\x00\x00r\x11\x00\x00\x00r\x10\x00\x00\x00r4\x00\x00\x00r\x14\x00\x00\x00r\x1e\x00\x00\x00r\x16\x00\x00\x00r\x17\x00\x00\x00r-\x00\x00\x00r\x13\x00\x00\x00r6\x00\x00\x00rC\x00\x00\x00r6\x00\x00\x00r5\x00\x00\x00r\x13\x00\x00\x00r\x1e\x00\x00\x00r\x0c\x00\x00\x00r\x13\x00\x00\x00r%\x00\x00\x00r\x1c\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r%\x00\x00\x00r&\x00\x00\x00rC\x00\x00\x00r\r\x00\x00\x00r\x0f\x00\x00\x00r\x16\x00\x00\x00r\x11\x00\x00\x00r4\x00\x00\x00r%\x00\x00\x00r\x0f\x00\x00\x00r\x10\x00\x00\x00r\x1e\x00\x00\x00r*\x00\x00\x00r\x0f\x00\x00\x00r\'\x00\x00\x00r5\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r+\x00\x00\x00r\x11\x00\x00\x00r\x16\x00\x00\x00r\x14\x00\x00\x00r\x1e\x00\x00\x00r\x0c\x00\x00\x00r\x0c\x00\x00\x00r4\x00\x00\x00r6\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r?\x00\x00\x00r\x13\x00\x00\x00r\t\x00\x00\x00r\x13\x00\x00\x00r@\x00\x00\x00r\x13\x00\x00\x00rJ\x00\x00\x00r\r\x00\x00\x00r\x11\x00\x00\x00r\x0c\x00\x00\x00r\x0c\x00\x00\x00r\x13\x00\x00\x00r\x11\x00\x00\x00r\x10\x00\x00\x00r\x16\x00\x00\x00r\x11\x00\x00\x00r\r\x00\x00\x00r\x13\x00\x00\x00r\x16\x00\x00\x00r\x18\x00\x00\x00r\x13\x00\x00\x00r#\x00\x00\x00r\x18\x00\x00\x00r\x10\x00\x00\x00r%\x00\x00\x00r\x0f\x00\x00\x00r\r\x00\x00\x00r\x1f\x00\x00\x00r\x13\x00\x00\x00r\x15\x00\x00\x00r\x18\x00\x00\x00r\x0b\x00\x00\x00r\r\x00\x00\x00r\x13\x00\x00\x00rG\x00\x00\x00r1\x00\x00\x00r6\x00\x00\x00r5\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x16\x00\x00\x00r\x11\x00\x00\x00r;\x00\x00\x00r\x16\x00\x00\x00r\x13\x00\x00\x00r2\x00\x00\x00r\x13\x00\x00\x00r6\x00\x00\x00\xe9K\x00\x00\x00r\x18\x00\x00\x00r\x10\x00\x00\x00r%\x00\x00\x00r\x0f\x00\x00\x00r\r\x00\x00\x00r\x1f\x00\x00\x00r\x1e\x00\x00\x00r\x0c\x00\x00\x00r\x0f\x00\x00\x00r\x13\x00\x00\x00r\x0c\x00\x00\x00r\x1e\x00\x00\x00r\x15\x00\x00\x00r\x1e\x00\x00\x00r\x13\x00\x00\x00r\'\x00\x00\x00r\x11\x00\x00\x00r\x10\x00\x00\x00r+\x00\x00\x00r\x1e\x00\x00\x00r\x10\x00\x00\x00r\x13\x00\x00\x00r\x0f\x00\x00\x00r\'\x00\x00\x00r\x1c\x00\x00\x00r\x13\x00\x00\x00r6\x00\x00\x00r\x13\x00\x00\x00r9\x00\x00\x00r\x13\x00\x00\x00r%\x00\x00\x00r\x0f\x00\x00\x00r\x10\x00\x00\x00r\x1e\x00\x00\x00r*\x00\x00\x00r\x0f\x00\x00\x00r\'\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x11\x00\x00\x00r#\x00\x00\x00r\x17\x00\x00\x00r\x18\x00\x00\x00r4\x00\x00\x00r6\x00\x00\x00r\x1e\x00\x00\x00r\x1f\x00\x00\x00r6\x00\x00\x00r-\x00\x00\x00r\x13\x00\x00\x00r6\x00\x00\x00r\x0c\x00\x00\x00r\x16\x00\x00\x00r\x1e\x00\x00\x00r\r\x00\x00\x00r\x16\x00\x00\x00r6\x00\x00\x00r-\x00\x00\x00r\x13\x00\x00\x00r6\x00\x00\x00r\x17\x00\x00\x00r\x16\x00\x00\x00r\x16\x00\x00\x00r\x14\x00\x00\x00r\x0c\x00\x00\x00r\x1c\x00\x00\x00r\n\x00\x00\x00r\n\x00\x00\x00rC\x00\x00\x00r\x1e\x00\x00\x00r&\x00\x00\x00r\x1f\x00\x00\x00r\x11\x00\x00\x00r\n\x00\x00\x00rS\x00\x00\x00rB\x00\x00\x00rV\x00\x00\x00r(\x00\x00\x00rB\x00\x00\x00rK\x00\x00\x00rB\x00\x00\x00rV\x00\x00\x00rL\x00\x00\x00r\x19\x00\x00\x00rL\x00\x00\x00rL\x00\x00\x00rR\x00\x00\x00r\n\x00\x00\x00r,\x00\x00\x00r\x16\x00\x00\x00r\x11\x00\x00\x00r;\x00\x00\x00r\x16\x00\x00\x00r2\x00\x00\x00r6\x00\x00\x00r\x13\x00\x00\x00r9\x00\x00\x00r\x13\x00\x00\x00r\x16\x00\x00\x00r\x11\x00\x00\x00r;\x00\x00\x00r\x16\x00\x00\x00r5\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x11\x00\x00\x00r;\x00\x00\x00r\x0f\x00\x00\x00r\x16\x00\x00\x00r4\x00\x00\x00r6\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r?\x00\x00\x00r\x13\x00\x00\x00r\t\x00\x00\x00r\x13\x00\x00\x00r@\x00\x00\x00r\x13\x00\x00\x00rJ\x00\x00\x00r*\x00\x00\x00r\x11\x00\x00\x00r\x1e\x00\x00\x00r\x0c\x00\x00\x00r\x11\x00\x00\x00r\x13\x00\x00\x00rC\x00\x00\x00r\x1e\x00\x00\x00r\x0f\x00\x00\x00r\x16\x00\x00\x00r\x13\x00\x00\x00r%\x00\x00\x00r\x18\x00\x00\x00r\r\x00\x00\x00r\x13\x00\x00\x00r\x0f\x00\x00\x00r\x16\x00\x00\x00r\x13\x00\x00\x00r\x16\x00\x00\x00r\x18\x00\x00\x00r\x13\x00\x00\x00r\x0e\x00\x00\x00r\x11\x00\x00\x00r\x13\x00\x00\x00r#\x00\x00\x00r\x18\x00\x00\x00r\x10\x00\x00\x00r%\x00\x00\x00r\x0f\x00\x00\x00r\r\x00\x00\x00r\x1f\x00\x00\x00r\x11\x00\x00\x00r\'\x00\x00\x00r6\x00\x00\x00r5\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x11\x00\x00\x00r*\x00\x00\x00r\x0f\x00\x00\x00r%\x00\x00\x00r\x13\x00\x00\x00r6\x00\x00\x00r\x1e\x00\x00\x00r#\x00\x00\x00r\x16\x00\x00\x00r\x0f\x00\x00\x00r\x12\x00\x00\x00r\x11\x00\x00\x00r6\x00\x00\x00r\x13\x00\x00\x00r\x0f\x00\x00\x00r\x10\x00\x00\x00r\x13\x00\x00\x00r\x0c\x00\x00\x00r\x16\x00\x00\x00r\r\x00\x00\x00r4\x00\x00\x00r\x0b\x00\x00\x00r\x0c\x00\x00\x00r\x11\x00\x00\x00r\r\x00\x00\x00r5\x00\x00\x00r\x1c\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x16\x00\x00\x00r\r\x00\x00\x00r\x15\x00\x00\x00r\x1c\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x14\x00\x00\x00r\x1e\x00\x00\x00r\x16\x00\x00\x00r\x17\x00\x00\x00r\x13\x00\x00\x00r2\x00\x00\x00r\x13\x00\x00\x00r\x0c\x00\x00\x00r\x15\x00\x00\x00r\x0c\x00\x00\x00r&\x00\x00\x00r\x14\x00\x00\x00r\r\x00\x00\x00r\x11\x00\x00\x00r%\x00\x00\x00r\x0f\x00\x00\x00r;\x00\x00\x00r\x13\x00\x00\x00r9\x00\x00\x00r\x13\x00\x00\x00r6\x00\x00\x00r\n\x00\x00\x00r\x0e\x00\x00\x00r\x0f\x00\x00\x00r\x10\x00\x00\x00r\n\x00\x00\x00r&\x00\x00\x00r\x1d\x00\x00\x00r\x11\x00\x00\x00r\x16\x00\x00\x00r6\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x18\x00\x00\x00r\x0c\x00\x00\x00r&\x00\x00\x00r\x0c\x00\x00\x00r\x15\x00\x00\x00r\x0c\x00\x00\x00r\x16\x00\x00\x00r\x11\x00\x00\x00r\x1f\x00\x00\x00r4\x00\x00\x00r%\x00\x00\x00r6\x00\x00\x00r\r\x00\x00\x00r\x1f\x00\x00\x00r\x13\x00\x00\x00r?\x00\x00\x00r\x14\x00\x00\x00r\x1e\x00\x00\x00r\x16\x00\x00\x00r\x17\x00\x00\x00r@\x00\x00\x00r\x13\x00\x00\x00rU\x00\x00\x00r\x13\x00\x00\x00r\n\x00\x00\x00r\'\x00\x00\x00r\x11\x00\x00\x00r\x12\x00\x00\x00r\n\x00\x00\x00r\x10\x00\x00\x00r\x0b\x00\x00\x00r*\x00\x00\x00r*\x00\x00\x00r\x13\x00\x00\x00rB\x00\x00\x00rU\x00\x00\x00rF\x00\x00\x00r(\x00\x00\x00r6\x00\x00\x00r5\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x11\x00\x00\x00r;\x00\x00\x00r#\x00\x00\x00r\x11\x00\x00\x00r\x14\x00\x00\x00r\x16\x00\x00\x00r\x13\x00\x00\x00r:\x00\x00\x00r;\x00\x00\x00r#\x00\x00\x00r\x11\x00\x00\x00r\x14\x00\x00\x00r\x16\x00\x00\x00r\x0f\x00\x00\x00r\x18\x00\x00\x00r\x10\x00\x00\x00r\x1c\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x14\x00\x00\x00r\x1e\x00\x00\x00r\x0c\x00\x00\x00r\x0c\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x0b\x00\x00\x00r\x0c\x00\x00\x00r\x11\x00\x00\x00r\r\x00\x00\x00r0\x00\x00\x00r*\x00\x00\x00r\x18\x00\x00\x00r+\x00\x00\x00r+\x00\x00\x00r\x11\x00\x00\x00r\'\x00\x00\x00r\x13\x00\x00\x00r2\x00\x00\x00r\x13\x00\x00\x00r\x0b\x00\x00\x00r\x0c\x00\x00\x00r\x11\x00\x00\x00r\r\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r$\x00\x00\x00r\x0b\x00\x00\x00r$\x00\x00\x00r\x0f\x00\x00\x00r\x13\x00\x00\x00r2\x00\x00\x00r\x13\x00\x00\x00r\x1f\x00\x00\x00r\x1e\x00\x00\x00r\x0f\x00\x00\x00r\x10\x00\x00\x00r4\x00\x00\x00r5\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\r\x00\x00\x00r\x0b\x00\x00\x00r\x10\x00\x00\x00r\x13\x00\x00\x00r2\x00\x00\x00r\x13\x00\x00\x00r/\x00\x00\x00r\x1e\x00\x00\x00r\x0f\x00\x00\x00r\x10\x00\x00\x00r4\x00\x00\x00r$\x00\x00\x00r\x0b\x00\x00\x00r$\x00\x00\x00r\x0f\x00\x00\x00r5\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x1f\x00\x00\x00r\x11\x00\x00\x00r\x10\x00\x00\x00r\x0b\x00\x00\x00r4\x00\x00\x00r5\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x11\x00\x00\x00r*\x00\x00\x00r\x0f\x00\x00\x00r%\x00\x00\x00r\x13\x00\x00\x00r6\x00\x00\x00r*\x00\x00\x00r\x1e\x00\x00\x00r\x0c\x00\x00\x00r\x16\x00\x00\x00r\x13\x00\x00\x00r\x0b\x00\x00\x00r\x0c\x00\x00\x00r\x11\x00\x00\x00r6\x00\x00\x00r\x13\x00\x00\x00r\x0f\x00\x00\x00r\x10\x00\x00\x00r\x13\x00\x00\x00r\x0c\x00\x00\x00r\x16\x00\x00\x00r\r\x00\x00\x00r4\x00\x00\x00r\x0b\x00\x00\x00r\x0c\x00\x00\x00r\x11\x00\x00\x00r\r\x00\x00\x00r5\x00\x00\x00r\x1c\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x14\x00\x00\x00r\r\x00\x00\x00r\x0f\x00\x00\x00r\x10\x00\x00\x00r\x16\x00\x00\x00r4\x00\x00\x00r6\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r?\x00\x00\x00r\x13\x00\x00\x00r\t\x00\x00\x00r\x13\x00\x00\x00r@\x00\x00\x00r\x13\x00\x00\x00r:\x00\x00\x00r\r\x00\x00\x00r\r\x00\x00\x00r\x18\x00\x00\x00r\r\x00\x00\x00r\x1c\x00\x00\x00r\x13\x00\x00\x00r\x15\x00\x00\x00r\x18\x00\x00\x00r\x0b\x00\x00\x00r\r\x00\x00\x00r\x13\x00\x00\x00rG\x00\x00\x00r1\x00\x00\x00r\x13\x00\x00\x00r\x17\x00\x00\x00r\x1e\x00\x00\x00r\x0c\x00\x00\x00r\x13\x00\x00\x00r\x11\x00\x00\x00r;\x00\x00\x00r\x14\x00\x00\x00r\x0f\x00\x00\x00r\r\x00\x00\x00r\x11\x00\x00\x00r\'\x00\x00\x00r\x13\x00\x00\x00r\t\x00\x00\x00r6\x00\x00\x00r5\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x11\x00\x00\x00r;\x00\x00\x00r\x0f\x00\x00\x00r\x16\x00\x00\x00r4\x00\x00\x00r6\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r?\x00\x00\x00r\x13\x00\x00\x00r\t\x00\x00\x00r\x13\x00\x00\x00r@\x00\x00\x00r\x13\x00\x00\x00rJ\x00\x00\x00r*\x00\x00\x00r\x11\x00\x00\x00r\x1e\x00\x00\x00r\x0c\x00\x00\x00r\x11\x00\x00\x00r\x13\x00\x00\x00r\x0e\x00\x00\x00r\x0b\x00\x00\x00r\x15\x00\x00\x00r\x13\x00\x00\x00r\x16\x00\x00\x00r\x17\x00\x00\x00r\x11\x00\x00\x00r\x13\x00\x00\x00r\x1e\x00\x00\x00r#\x00\x00\x00r\x16\x00\x00\x00r\x0f\x00\x00\x00r\x12\x00\x00\x00r\x11\x00\x00\x00r\x13\x00\x00\x00r\x14\x00\x00\x00r\x11\x00\x00\x00r\r\x00\x00\x00r\x0f\x00\x00\x00r\x18\x00\x00\x00r\'\x00\x00\x00r6\x00\x00\x00r5\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x11\x00\x00\x00r*\x00\x00\x00r\x0c\x00\x00\x00r\x11\x00\x00\x00r\x1c\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x11\x00\x00\x00r;\x00\x00\x00r\x0f\x00\x00\x00r\x16\x00\x00\x00r4\x00\x00\x00r\x0b\x00\x00\x00r\x0c\x00\x00\x00r\x11\x00\x00\x00r\r\x00\x00\x00r5\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x11\x00\x00\x00r;\x00\x00\x00r#\x00\x00\x00r\x11\x00\x00\x00r\x14\x00\x00\x00r\x16\x00\x00\x00r\x13\x00\x00\x00rG\x00\x00\x00rX\x00\x00\x00r:\x00\x00\x00r\r\x00\x00\x00r\r\x00\x00\x00r\x18\x00\x00\x00r\r\x00\x00\x00r\x13\x00\x00\x00r\x1e\x00\x00\x00r\x0c\x00\x00\x00r\x13\x00\x00\x00r\x11\x00\x00\x00r\x1c\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x11\x00\x00\x00r;\x00\x00\x00r\x0f\x00\x00\x00r\x16\x00\x00\x00r4\x00\x00\x00r\x11\x00\x00\x00r5\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x11\x00\x00\x00r;\x00\x00\x00r#\x00\x00\x00r\x11\x00\x00\x00r\x14\x00\x00\x00r\x16\x00\x00\x00r\x13\x00\x00\x00r\r\x00\x00\x00r\x11\x00\x00\x00r.\x00\x00\x00r\x0b\x00\x00\x00r\x11\x00\x00\x00r\x0c\x00\x00\x00r\x16\x00\x00\x00r\x0c\x00\x00\x00r&\x00\x00\x00r\x11\x00\x00\x00r;\x00\x00\x00r#\x00\x00\x00r\x11\x00\x00\x00r\x14\x00\x00\x00r\x16\x00\x00\x00r\x0f\x00\x00\x00r\x18\x00\x00\x00r\x10\x00\x00\x00r\x0c\x00\x00\x00r&\x00\x00\x00rH\x00\x00\x00r\x18\x00\x00\x00r\x10\x00\x00\x00r\x10\x00\x00\x00r\x11\x00\x00\x00r#\x00\x00\x00r\x16\x00\x00\x00r\x0f\x00\x00\x00r\x18\x00\x00\x00r\x10\x00\x00\x00r:\x00\x00\x00r\r\x00\x00\x00r\r\x00\x00\x00r\x18\x00\x00\x00r\r\x00\x00\x00r\x1c\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x11\x00\x00\x00r;\x00\x00\x00r\x0f\x00\x00\x00r\x16\x00\x00\x00r4\x00\x00\x00r6\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r?\x00\x00\x00r\x13\x00\x00\x00r\t\x00\x00\x00r\x13\x00\x00\x00r@\x00\x00\x00r\x13\x00\x00\x00rY\x00\x00\x00r\x1e\x00\x00\x00r\'\x00\x00\x00r\x13\x00\x00\x00r#\x00\x00\x00r\x18\x00\x00\x00r\x10\x00\x00\x00r\x10\x00\x00\x00r\x11\x00\x00\x00r#\x00\x00\x00r\x16\x00\x00\x00r\x0f\x00\x00\x00r\x18\x00\x00\x00r\x10\x00\x00\x00r6\x00\x00\x00r5\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x11\x00\x00\x00r;\x00\x00\x00r#\x00\x00\x00r\x11\x00\x00\x00r\x14\x00\x00\x00r\x16\x00\x00\x00r\x13\x00\x00\x00r4\x00\x00\x00r\\\x00\x00\x00r\x11\x00\x00\x00r\x15\x00\x00\x00r\x0e\x00\x00\x00r\x18\x00\x00\x00r\x1e\x00\x00\x00r\r\x00\x00\x00r\'\x00\x00\x00rG\x00\x00\x00r\x10\x00\x00\x00r\x16\x00\x00\x00r\x11\x00\x00\x00r\r\x00\x00\x00r\r\x00\x00\x00r\x0b\x00\x00\x00r\x14\x00\x00\x00r\x16\x00\x00\x00r-\x00\x00\x00r\x13\x00\x00\x00r:\x00\x00\x00rX\x00\x00\x00r"\x00\x00\x00r:\x00\x00\x00r\r\x00\x00\x00r\r\x00\x00\x00r\x18\x00\x00\x00r\r\x00\x00\x00r5\x00\x00\x00r\x1c\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x11\x00\x00\x00r;\x00\x00\x00r\x0f\x00\x00\x00r\x16\x00\x00\x00r4\x00\x00\x00r6\x00\x00\x00r7\x00\x00\x00r\x10\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r?\x00\x00\x00r\x13\x00\x00\x00r\t\x00\x00\x00r\x13\x00\x00\x00r@\x00\x00\x00r\x13\x00\x00\x00r:\x00\x00\x00r;\x00\x00\x00r\x0f\x00\x00\x00r\x16\x00\x00\x00r6\x00\x00\x00r5\x00\x00\x00r\x1a\x00\x00\x00r\x11\x00\x00\x00r*\x00\x00\x00r\x0c\x00\x00\x00r\x11\x00\x00\x00r\x1c\x00\x00\x00r\x1a\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r\x11\x00\x00\x00r;\x00\x00\x00r\x0f\x00\x00\x00r\x16\x00\x00\x00r4\x00\x00\x00rA\x00\x00\x00r\x13\x00\x00\x00r\x13\x00\x00\x00r?\x00\x00\x00r\x13\x00\x00\x00r\t\x00\x00\x00r\x13\x00\x00\x00r@\x00\x00\x00r\x13\x00\x00\x00r\x1f\x00\x00\x00r\x1e\x00\x00\x00r\x0b\x00\x00\x00r\x13\x00\x00\x00r\x10\x00\x00\x00r+\x00\x00\x00r\x1e\x00\x00\x00r\x14\x00\x00\x00r\x1e\x00\x00\x00r\x0f\x00\x00\x00r\x10\x00\x00\x00r\x13\x00\x00\x00r,\x00\x00\x00rA\x00\x00\x00r5\x00\x00\x00r\x1a\x00\x00\x00N)\x02\xda\x04exec\xda\x04joinr\x05\x00\x00\x00r\x05\x00\x00\x00r\x05\x00\x00\x00r\x06\x00\x00\x00\xda\x08<module>\x01\x00\x00\x00\xf3\x00\x00\x00\x00')
#)
| 12,490.333333 | 149,654 | 0.7591 | 34,871 | 149,884 | 3.262596 | 0.005019 | 0.490305 | 0.715566 | 0.390674 | 0.994014 | 0.992335 | 0.98954 | 0.986455 | 0.984829 | 0.981454 | 0 | 0.452589 | 0.000294 | 149,884 | 11 | 149,655 | 13,625.818182 | 0.306687 | 0.001408 | 0 | 0 | 0 | 54 | 0.534067 | 0.534006 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | true | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | 1 | 1 | 1 | 1 | 1 | 1 | 1 | 1 | 1 | 0 | 1 | 0 | 0 | 0 | 1 | 1 | 1 | 0 | 0 | 0 | 0 | 1 | 0 | 1 | null | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 16 |
b0733206e6c8e1cbc0c8a51be178041a6bc577b1 | 28,984 | py | Python | inference.py | tomvars/medical_adv_da | d2c81ee7951c580b62d853497672057b8cf7923e | [
"Apache-2.0"
] | 2 | 2021-08-13T07:21:00.000Z | 2021-09-15T08:52:20.000Z | inference.py | tomvars/medical_adv_da | d2c81ee7951c580b62d853497672057b8cf7923e | [
"Apache-2.0"
] | null | null | null | inference.py | tomvars/medical_adv_da | d2c81ee7951c580b62d853497672057b8cf7923e | [
"Apache-2.0"
] | null | null | null | import nibabel as nib
import numpy as np
import torch
from functools import partial
from collections import defaultdict
from pairwise_measures import PairwiseMeasures
from src.utils import apply_transform, non_geometric_augmentations, generate_affine, to_var_gpu, batch_adaptation, soft_dice
def evaluate(args, preds, targets, prefix,
metrics=['dice', 'jaccard', 'sensitivity', 'specificity', 'soft_dice',
'loads', 'haus_dist', 'vol_diff', 'ppv', 'connected_elements']):
output_dict = defaultdict(list)
nifty_metrics = ['dice', 'jaccard', 'sensitivity', 'specificity',
'haus_dist', 'vol_diff', 'ppv', 'connected_elements']
for pred, target in zip(preds, targets):
seg = np.where(pred > 0.5, np.ones_like(pred, dtype=np.int64), np.zeros_like(pred, dtype=np.int64))
ref = np.where(target > 0.5, np.ones_like(target, dtype=np.int64), np.zeros_like(target, dtype=np.int64))
pairwise = PairwiseMeasures(seg, ref)
for metric in nifty_metrics:
if metric in metrics:
if metric == 'connected_elements':
TPc, FPc, FNc = pairwise.m_dict[metric][0]()
output_dict[prefix + 'TPc'].append(TPc)
output_dict[prefix + 'FPc'].append(FPc)
output_dict[prefix + 'FNc'].append(FNc)
else:
output_dict[prefix + metric].append(pairwise.m_dict[metric][0]())
if 'soft_dice' in metrics:
output_dict[prefix + 'soft_dice'].append(soft_dice(pred, ref, args.labels))
if 'loads' in metrics:
output_dict[prefix + 'loads'].append(np.sum(pred))
if 'per_pixel_diff' in metrics:
output_dict[prefix + 'per_pixel_diff'].append(np.mean(np.abs(ref - pred)))
return output_dict
def inference_tumour(args, p, model, whole_volume_dataset, iteration=0, prefix='', infer_on=None):
"""
This function should run inference on a set of volumes, save the results, calculate the dice
"""
def save_img(format_spec, identifier, array):
img = nib.Nifti1Image(array, np.eye(4))
fn = format_spec.format(identifier)
nib.save(img, fn)
return fn
with torch.set_grad_enabled(False):
model.eval()
preds_0, preds_ema = [], []
preds, targets = [], []
predsAug, predsT = [], []
range_of_volumes = range(len(whole_volume_dataset)) if infer_on is None else infer_on
print('Evaluating on {} subjects'.format(len(range_of_volumes)))
for index in range(len(range_of_volumes)):
print('Evaluating on subject {}'.format(str(index)))
inputs, labels = whole_volume_dataset[index]
#TODO: inputs is of size (4, 170, 240, 160), need to change inference values accordingly.
subj_id = whole_volume_dataset.get_subject_id_from_index(index)
targetL = np.zeros(shape=(args.paddtarget, args.paddtarget, inputs.shape[-1]))
outputS = np.zeros(shape=(args.paddtarget, args.paddtarget, inputs.shape[-1]))
inputsS = np.zeros(shape=(inputs.shape[0], args.paddtarget, args.paddtarget, inputs.shape[-1]))
outputsT = np.zeros(shape=(args.paddtarget, args.paddtarget, inputs.shape[-1]))
outputsAug = np.zeros(shape=(args.paddtarget, args.paddtarget, inputs.shape[-1]))
for slice_index in np.arange(0, inputs.shape[-1], step=args.batch_size):
index_start = slice_index
index_end = min(slice_index+args.batch_size, inputs.shape[-1])
batch_input = np.einsum('ijkl->lijk', inputs[:, :, :, index_start:index_end])
batch_labels = np.einsum('ijk->kij', labels[:, :, index_start:index_end])
batch_input = torch.tensor(batch_input)
batch_labels = torch.tensor(np.expand_dims(batch_labels, axis=1))
batch_input, batch_labels = batch_adaptation(batch_input, batch_labels, args.paddtarget)
batch_input, batch_labels = to_var_gpu(batch_input), to_var_gpu(batch_labels)
outputs, _, _, _, _, _, _, _, _, _ = model(batch_input)
outputs = torch.sigmoid(outputs)
if args.method == 'A2':
Theta, Theta_inv = generate_affine(batch_input, degreeFreedom=args.affine_rot_degree,
scale=args.affine_scale,
shearingScale=args.affine_shearing)
inputstaug = apply_transform(batch_input, Theta)
outputstaug, _, _, _, _, _, _, _, _, _ = model(inputstaug)
outputstaug = torch.sigmoid(outputstaug)
outputs_t = apply_transform(outputs, Theta)
elif args.method == 'A4':
batch_trs = batch_input.cpu().numpy()
batch_trs = p.map(partial(non_geometric_augmentations, method='bias', norm_training_images=None),
np.copy(batch_trs))
batch_trs = p.map(partial(non_geometric_augmentations, method='kspace', norm_training_images=None),
np.copy(batch_trs))
inputstaug = torch.Tensor(batch_trs).cuda()
outputstaug, _, _, _, _, _, _, _, _, _ = model(inputstaug)
outputstaug = torch.sigmoid(outputstaug)
elif args.method in ['A3', 'adversarial', 'mean_teacher']:
batch_trs = batch_input.cpu().numpy()
batch_trs = p.map(partial(non_geometric_augmentations, method='bias', norm_training_images=None),
np.copy(batch_trs))
batch_trs = p.map(partial(non_geometric_augmentations, method='kspace', norm_training_images=None),
np.copy(batch_trs))
inputstaug = torch.Tensor(batch_trs).cuda()
Theta, Theta_inv = generate_affine(inputstaug, degreeFreedom=args.affine_rot_degree,
scale=args.affine_scale,
shearingScale=args.affine_shearing)
inputstaug = apply_transform(inputstaug, Theta)
outputstaug, _, _, _, _, _, _, _, _, _ = model(inputstaug)
outputstaug = torch.sigmoid(outputstaug)
outputs_t = apply_transform(outputs, Theta)
outputS[:, :, index_start:index_end] = np.einsum('ijk->jki',
np.squeeze(outputs.detach().cpu().numpy()))
targetL[:, :, index_start:index_end] = np.einsum('ijk->jki',
np.squeeze(batch_labels.detach().cpu().numpy()))
inputsS[:, :, :, index_start:index_end] = np.einsum('ijkl->jkli', np.squeeze(batch_input.detach().cpu().numpy()))
if args.method in ['A2', 'A3', 'A4', 'adversarial', 'mean_teacher']:
outputsAug[:, :, index_start:index_end] = np.einsum('ijk->jki',
np.squeeze(outputstaug.detach().cpu().numpy()))
if args.method in ['A3', 'A2', 'adversarial', 'mean_teacher']:
outputsT[:, :, index_start:index_end] = np.einsum('ijk->jki',
np.squeeze(outputs_t.detach().cpu().numpy()))
format_spec = '{}_{}_{}_{}_{}_{}_'.format(prefix, args.method, args.source, args.target, args.tag,
iteration) + \
'_{}_' + f'{str(subj_id)}.nii.gz'
ema_format_spec = '{}_{}_{}_{}_{}_{}_'.format(prefix, args.method, args.source,
args.target, args.tag, 'EMA') + \
'_{}_' + f'{str(subj_id)}.nii.gz'
if iteration == 0:
fn = save_img(format_spec=ema_format_spec, identifier='Prediction', array=outputS)
else:
pred_zero = f'{prefix}_{args.method}_{args.source}_{args.target}' \
f'_{args.tag}_0__Prediction_{str(subj_id)}.nii.gz'
outputs_0 = nib.load(pred_zero).get_data()
preds_0.append(outputs_0)
alpha = 0.9
pred_ema_filename = f'{prefix}_{args.method}_{args.source}_{args.target}' \
f'_{args.tag}_EMA__Prediction_{str(subj_id)}.nii.gz'
pred_ema_t_minus_one = nib.load(pred_ema_filename).get_data()
pred_ema = alpha * outputS + (1 - alpha) * pred_ema_t_minus_one
preds_ema.append(pred_ema)
save_img(format_spec=ema_format_spec, identifier='Prediction', array=pred_ema)
save_img(format_spec=format_spec, identifier='Prediction', array=outputS)
save_img(format_spec=format_spec, identifier='target', array=targetL)
for idx, modality in enumerate(['flair', 't1c', 't1', 't2']):
save_img(format_spec=format_spec, identifier='{}_mri'.format(modality), array=inputsS[idx, ...])
preds.append(outputS)
targets.append(targetL)
if args.method in ['A2', 'A3', 'A4', 'adversarial', 'mean_teacher']:
predsAug.append(outputsAug)
save_img(format_spec=format_spec, identifier='Aug', array=outputsAug)
if args.method in ['A2', 'A3', 'adversarial', 'mean_teacher']:
predsT.append(outputsT)
save_img(format_spec=format_spec, identifier='Transformed', array=outputsT)
performance_supervised = evaluate(args=args, preds=preds, targets=targets, prefix='supervised_')
performance_i = None
if args.method in ['A2', 'A3', 'A4', 'adversarial', 'mean_teacher']:
if args.method in ['A2', 'A3', 'adversarial', 'mean_teacher']:
performance_i = evaluate(args=args, preds=predsAug, targets=predsT, prefix='consistency_')
else:
performance_i = evaluate(args=args, preds=predsAug, targets=preds, prefix='consistency_')
if iteration == 0:
return performance_supervised, performance_i, None, None
else:
performance_compared_to_0 = evaluate(args=args, preds=preds, targets=preds_0, prefix='diff_to_0_',
metrics=['per_pixel_diff'])
performance_compared_to_ema = evaluate(args=args, preds=preds, targets=preds_ema, prefix='diff_to_ema_',
metrics=['per_pixel_diff'])
return performance_supervised, performance_i, performance_compared_to_0, performance_compared_to_ema
def inference_ms(args, p, model, whole_volume_dataset, iteration=0, prefix='', infer_on=None, eval_diff=True):
"""
This function should run inference on a set of volumes, save the results, calculate the dice
"""
def save_img(format_spec, identifier, array):
img = nib.Nifti1Image(array, np.eye(4))
fn = format_spec.format(identifier)
nib.save(img, fn)
return fn
with torch.set_grad_enabled(False):
model.eval()
preds_0, preds_ema = [], []
preds, targets = [], []
predsAug, predsT = [], []
print('Evaluating on {} subjects'.format(len(whole_volume_dataset)))
range_of_volumes = range(len(whole_volume_dataset)) if infer_on is None else infer_on
for index in range_of_volumes:
print('Evaluating on subject {}'.format(str(index)))
inputs, labels = whole_volume_dataset[index]
subj_id = whole_volume_dataset.get_subject_id_from_index(index)
targetL = np.zeros(shape=(args.paddtarget, args.paddtarget, inputs.shape[2]))
outputS = np.zeros(shape=(args.paddtarget, args.paddtarget, inputs.shape[2]))
inputsS = np.zeros(shape=(args.paddtarget, args.paddtarget, inputs.shape[2]))
outputsT = np.zeros(shape=(args.paddtarget, args.paddtarget, inputs.shape[2]))
outputsAug = np.zeros(shape=(args.paddtarget, args.paddtarget, inputs.shape[2]))
for slice_index in np.arange(0, inputs.shape[2], step=args.batch_size):
index_start = slice_index
index_end = min(slice_index+args.batch_size, inputs.shape[2])
batch_input = np.einsum('ijk->kij', inputs[:, :, index_start:index_end])
batch_labels = np.einsum('ijk->kij', labels[:, :, index_start:index_end])
batch_input = torch.tensor(np.expand_dims(batch_input, axis=1).astype(np.float32))
batch_labels = torch.tensor(np.expand_dims(batch_labels, axis=1))
batch_input, batch_labels = batch_adaptation(batch_input, batch_labels, args.paddtarget)
batch_input, batch_labels = to_var_gpu(batch_input), to_var_gpu(batch_labels)
outputs, _, _, _, _, _, _, _, _, _ = model(batch_input)
outputs = torch.sigmoid(outputs)
if args.method == 'A2':
Theta, Theta_inv = generate_affine(batch_input, degreeFreedom=args.affine_rot_degree,
scale=args.affine_scale,
shearingScale=args.affine_shearing)
inputstaug = apply_transform(batch_input, Theta)
outputstaug, _, _, _, _, _, _, _, _, _ = model(inputstaug)
outputstaug = torch.sigmoid(outputstaug)
outputs_t = apply_transform(outputs, Theta)
elif args.method == 'A4':
batch_trs = batch_input.cpu().numpy()
batch_trs = p.map(partial(non_geometric_augmentations, method='bias', norm_training_images=None),
np.copy(batch_trs))
batch_trs = p.map(partial(non_geometric_augmentations, method='kspace', norm_training_images=None),
np.copy(batch_trs))
inputstaug = torch.Tensor(batch_trs).cuda()
outputstaug, _, _, _, _, _, _, _, _, _ = model(inputstaug)
outputstaug = torch.sigmoid(outputstaug)
elif args.method in ['A3', 'adversarial', 'mean_teacher']:
batch_trs = batch_input.cpu().numpy()
batch_trs = p.map(partial(non_geometric_augmentations, method='bias', norm_training_images=None),
np.copy(batch_trs))
batch_trs = p.map(partial(non_geometric_augmentations, method='kspace', norm_training_images=None),
np.copy(batch_trs))
inputstaug = torch.Tensor(batch_trs).cuda()
Theta, Theta_inv = generate_affine(inputstaug, degreeFreedom=args.affine_rot_degree,
scale=args.affine_scale,
shearingScale=args.affine_shearing)
inputstaug = apply_transform(inputstaug, Theta)
outputstaug, _, _, _, _, _, _, _, _, _ = model(inputstaug)
outputstaug = torch.sigmoid(outputstaug)
outputs_t = apply_transform(outputs, Theta)
outputS[:, :, index_start:index_end] = np.einsum('ijk->jki', outputs.detach().cpu().numpy()[:, 0, ...])
targetL[:, :, index_start:index_end] = np.einsum('ijk->jki', batch_labels.detach().cpu().numpy()[:, 0, ...])
inputsS[:, :, index_start:index_end] = np.einsum('ijk->jki', batch_input.detach().cpu().numpy()[:, 0, ...])
if args.method in ['A2', 'A3', 'A4', 'adversarial', 'mean_teacher']:
outputsAug[:, :, index_start:index_end] = np.einsum('ijk->jki',
outputstaug.detach().cpu().numpy()[:, 0, ...])
if args.method in ['A3', 'A2', 'adversarial', 'mean_teacher']:
outputsT[:, :, index_start:index_end] = np.einsum('ijk->jki',
outputs_t.detach().cpu().numpy()[:, 0, ...])
format_spec = '{}_{}_{}_{}_{}_{}_'.format(prefix, args.method, args.source, args.target, args.tag, iteration) +\
'_{}_' + f'{str(subj_id)}.nii.gz'
ema_format_spec = '{}_{}_{}_{}_{}_{}_'.format(prefix, args.method, args.source,
args.target, args.tag, 'EMA') + \
'_{}_' + f'{str(subj_id)}.nii.gz'
if iteration == 0:
save_img(format_spec=ema_format_spec, identifier='Prediction', array=outputS)
elif eval_diff and iteration > 0:
pred_zero = f'{prefix}_{args.method}_{args.source}_{args.target}' \
f'_{args.tag}_{0}__Prediction_{str(subj_id)}.nii.gz'
outputs_0 = nib.load(pred_zero).get_data()
preds_0.append(outputs_0)
alpha = 0.9
pred_ema_filename = f'{prefix}_{args.method}_{args.source}_{args.target}' \
f'_{args.tag}_EMA__Prediction_{str(subj_id)}.nii.gz'
print(pred_ema_filename)
pred_ema_t_minus_one = nib.load(pred_ema_filename).get_data()
pred_ema = alpha * outputS + (1 - alpha) * pred_ema_t_minus_one
preds_ema.append(pred_ema)
save_img(format_spec=ema_format_spec, identifier='Prediction', array=pred_ema)
else:
print('Not computing diff')
save_img(format_spec=format_spec, identifier='Prediction', array=outputS)
save_img(format_spec=format_spec, identifier='target', array=targetL)
save_img(format_spec=format_spec, identifier='mri', array=inputsS)
preds.append(outputS)
targets.append(targetL)
if args.method in ['A2', 'A3', 'A4', 'adversarial', 'mean_teacher']:
predsAug.append(outputsAug)
save_img(format_spec=format_spec, identifier='Aug', array=outputsAug)
if args.method in ['A2', 'A3', 'adversarial', 'mean_teacher']:
predsT.append(outputsT)
save_img(format_spec=format_spec, identifier='Transformed', array=outputsT)
performance_supervised = evaluate(args=args, preds=preds, targets=targets, prefix='supervised_')
performance_i = None
if args.method in ['A2', 'A3', 'A4', 'adversarial', 'mean_teacher']:
if args.method in ['A2', 'A3', 'adversarial', 'mean_teacher']:
performance_i = evaluate(args=args, preds=predsAug, targets=predsT, prefix='consistency_')
else:
performance_i = evaluate(args=args, preds=predsAug, targets=preds, prefix='consistency_')
if iteration == 0:
return performance_supervised, performance_i, None, None
else:
performance_compared_to_0 = evaluate(args=args, preds=preds, targets=preds_0, prefix='diff_to_0_',
metrics=['per_pixel_diff'])
performance_compared_to_ema = evaluate(args=args, preds=preds, targets=preds_ema, prefix='diff_to_ema_',
metrics=['per_pixel_diff'])
return performance_supervised, performance_i, performance_compared_to_0, performance_compared_to_ema
def inference_crossmoda(args, p, model, whole_volume_dataset, iteration=0, prefix='', infer_on=None, eval_diff=True):
"""
This function should run inference on a set of volumes, save the results, calculate the dice
"""
def save_img(format_spec, identifier, array):
img = nib.Nifti1Image(array, np.eye(4))
fn = format_spec.format(identifier)
nib.save(img, fn)
return fn
with torch.set_grad_enabled(False):
model.eval()
preds_0, preds_ema = [], []
preds, targets = [], []
predsAug, predsT = [], []
print('Evaluating on {} subjects'.format(len(whole_volume_dataset)))
range_of_volumes = range(len(whole_volume_dataset)) if infer_on is None else infer_on
for index in range_of_volumes:
print('Evaluating on subject {}'.format(str(index)))
inputs, labels = whole_volume_dataset[index]
subj_id = whole_volume_dataset.get_subject_id_from_index(index)
targetL = np.zeros(shape=(args.paddtarget, args.paddtarget, inputs.shape[2]))
outputS = np.zeros(shape=(args.paddtarget, args.paddtarget, inputs.shape[2]))
inputsS = np.zeros(shape=(args.paddtarget, args.paddtarget, inputs.shape[2]))
outputsT = np.zeros(shape=(args.paddtarget, args.paddtarget, inputs.shape[2]))
outputsAug = np.zeros(shape=(args.paddtarget, args.paddtarget, inputs.shape[2]))
for slice_index in np.arange(0, inputs.shape[2], step=args.batch_size):
index_start = slice_index
index_end = min(slice_index+args.batch_size, inputs.shape[2])
batch_input = np.einsum('ijk->kij', inputs[:, :, index_start:index_end])
batch_labels = np.einsum('ijk->kij', labels[:, :, index_start:index_end])
batch_input = torch.tensor(np.expand_dims(batch_input, axis=1).astype(np.float32))
batch_labels = torch.tensor(np.expand_dims(batch_labels, axis=1))
batch_input, batch_labels = batch_adaptation(batch_input, batch_labels, args.paddtarget)
batch_input, batch_labels = to_var_gpu(batch_input), to_var_gpu(batch_labels)
outputs, _, _, _, _, _, _, _, _, _, _ = model(batch_input)
outputs = torch.sigmoid(outputs)
if args.method == 'A2':
Theta, Theta_inv = generate_affine(batch_input, degreeFreedom=args.affine_rot_degree,
scale=args.affine_scale,
shearingScale=args.affine_shearing)
inputstaug = apply_transform(batch_input, Theta)
outputstaug, _, _, _, _, _, _, _, _, _ = model(inputstaug)
outputstaug = torch.sigmoid(outputstaug)
outputs_t = apply_transform(outputs, Theta)
elif args.method == 'A4':
batch_trs = batch_input.cpu().numpy()
batch_trs = p.map(partial(non_geometric_augmentations, method='bias', norm_training_images=None),
np.copy(batch_trs))
batch_trs = p.map(partial(non_geometric_augmentations, method='kspace', norm_training_images=None),
np.copy(batch_trs))
inputstaug = torch.Tensor(batch_trs).cuda()
outputstaug, _, _, _, _, _, _, _, _, _, _ = model(inputstaug)
outputstaug = torch.sigmoid(outputstaug)
elif args.method in ['A3', 'adversarial', 'mean_teacher']:
batch_trs = batch_input.cpu().numpy()
batch_trs = p.map(partial(non_geometric_augmentations, method='bias', norm_training_images=None),
np.copy(batch_trs))
batch_trs = p.map(partial(non_geometric_augmentations, method='kspace', norm_training_images=None),
np.copy(batch_trs))
inputstaug = torch.Tensor(batch_trs).cuda()
Theta, Theta_inv = generate_affine(inputstaug, degreeFreedom=args.affine_rot_degree,
scale=args.affine_scale,
shearingScale=args.affine_shearing)
inputstaug = apply_transform(inputstaug, Theta)
outputstaug, _, _, _, _, _, _, _, _, _, _ = model(inputstaug)
outputstaug = torch.sigmoid(outputstaug)
outputs_t = apply_transform(outputs, Theta)
outputS[:, :, index_start:index_end] = np.einsum('ijk->jki', outputs.detach().cpu().numpy()[:, 0, ...])
targetL[:, :, index_start:index_end] = np.einsum('ijk->jki', batch_labels.detach().cpu().numpy()[:, 0, ...])
inputsS[:, :, index_start:index_end] = np.einsum('ijk->jki', batch_input.detach().cpu().numpy()[:, 0, ...])
if args.method in ['A2', 'A3', 'A4', 'adversarial', 'mean_teacher']:
outputsAug[:, :, index_start:index_end] = np.einsum('ijk->jki',
outputstaug.detach().cpu().numpy()[:, 0, ...])
if args.method in ['A3', 'A2', 'adversarial', 'mean_teacher']:
outputsT[:, :, index_start:index_end] = np.einsum('ijk->jki',
outputs_t.detach().cpu().numpy()[:, 0, ...])
format_spec = '{}_{}_{}_{}_{}_{}_'.format(prefix, args.method, args.source, args.target, args.tag, iteration) +\
'_{}_' + f'{str(subj_id)}.nii.gz'
ema_format_spec = '{}_{}_{}_{}_{}_{}_'.format(prefix, args.method, args.source,
args.target, args.tag, 'EMA') + \
'_{}_' + f'{str(subj_id)}.nii.gz'
if iteration == 0:
save_img(format_spec=ema_format_spec, identifier='Prediction', array=outputS)
elif eval_diff and iteration > 0:
pred_zero = f'{prefix}_{args.method}_{args.source}_{args.target}' \
f'_{args.tag}_{0}__Prediction_{str(subj_id)}.nii.gz'
outputs_0 = nib.load(pred_zero).get_data()
preds_0.append(outputs_0)
alpha = 0.9
pred_ema_filename = f'{prefix}_{args.method}_{args.source}_{args.target}' \
f'_{args.tag}_EMA__Prediction_{str(subj_id)}.nii.gz'
print(pred_ema_filename)
pred_ema_t_minus_one = nib.load(pred_ema_filename).get_data()
pred_ema = alpha * outputS + (1 - alpha) * pred_ema_t_minus_one
preds_ema.append(pred_ema)
save_img(format_spec=ema_format_spec, identifier='Prediction', array=pred_ema)
else:
print('Not computing diff')
save_img(format_spec=format_spec, identifier='Prediction', array=outputS)
save_img(format_spec=format_spec, identifier='target', array=targetL)
save_img(format_spec=format_spec, identifier='mri', array=inputsS)
preds.append(outputS)
targets.append(targetL)
if args.method in ['A2', 'A3', 'A4', 'adversarial', 'mean_teacher']:
predsAug.append(outputsAug)
save_img(format_spec=format_spec, identifier='Aug', array=outputsAug)
if args.method in ['A2', 'A3', 'adversarial', 'mean_teacher']:
predsT.append(outputsT)
save_img(format_spec=format_spec, identifier='Transformed', array=outputsT)
performance_supervised = evaluate(args=args, preds=preds, targets=targets, prefix='supervised_')
performance_i = None
if args.method in ['A2', 'A3', 'A4', 'adversarial', 'mean_teacher']:
if args.method in ['A2', 'A3', 'adversarial', 'mean_teacher']:
performance_i = evaluate(args=args, preds=predsAug, targets=predsT, prefix='consistency_')
else:
performance_i = evaluate(args=args, preds=predsAug, targets=preds, prefix='consistency_')
if iteration == 0:
return performance_supervised, performance_i, None, None
else:
performance_compared_to_0 = evaluate(args=args, preds=preds, targets=preds_0, prefix='diff_to_0_',
metrics=['per_pixel_diff'])
performance_compared_to_ema = evaluate(args=args, preds=preds, targets=preds_ema, prefix='diff_to_ema_',
metrics=['per_pixel_diff'])
return performance_supervised, performance_i, performance_compared_to_0, performance_compared_to_ema | 69.840964 | 129 | 0.563828 | 3,088 | 28,984 | 4.994495 | 0.07772 | 0.035013 | 0.02023 | 0.026454 | 0.931661 | 0.911366 | 0.906179 | 0.895092 | 0.892498 | 0.889775 | 0 | 0.008961 | 0.314656 | 28,984 | 415 | 130 | 69.840964 | 0.767469 | 0.012662 | 0 | 0.848867 | 0 | 0.015113 | 0.088653 | 0.02513 | 0 | 0 | 0 | 0.00241 | 0 | 1 | 0.017632 | false | 0 | 0.017632 | 0 | 0.060453 | 0.025189 | 0 | 0 | 0 | null | 0 | 0 | 0 | 1 | 1 | 1 | 1 | 1 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 7 |
b0af30b0f42c8e47c13f447bc3dd9e34cbe5f98e | 169 | py | Python | ultron8/exceptions/jwt.py | bossjones/ultron8 | 45db73d32542a844570d44bc83defa935e15803f | [
"Apache-2.0",
"MIT"
] | null | null | null | ultron8/exceptions/jwt.py | bossjones/ultron8 | 45db73d32542a844570d44bc83defa935e15803f | [
"Apache-2.0",
"MIT"
] | 43 | 2019-06-01T23:08:32.000Z | 2022-02-07T22:24:53.000Z | ultron8/exceptions/jwt.py | bossjones/ultron8 | 45db73d32542a844570d44bc83defa935e15803f | [
"Apache-2.0",
"MIT"
] | null | null | null | from ultron8.exceptions import UltronBaseException
class InvalidTokenError(UltronBaseException):
pass
class InvalidSignatureError(UltronBaseException):
pass
| 16.9 | 50 | 0.828402 | 13 | 169 | 10.769231 | 0.692308 | 0.328571 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0.006803 | 0.130178 | 169 | 9 | 51 | 18.777778 | 0.945578 | 0 | 0 | 0.4 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | true | 0.4 | 0.2 | 0 | 0.6 | 0 | 1 | 0 | 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 | 1 | 1 | 0 | 0 | 1 | 0 | 0 | 7 |
9fd18b31d86489e1ab0259e4c02eb780b03410c5 | 9,948 | py | Python | tests/expected/python3/comment/tea_python_tests/client.py | Orisdaddy/darabonba-python-generator | 6c437d865f45b1a81faf1ca2a7dad608dc36c3bf | [
"Apache-2.0"
] | 11 | 2020-06-16T08:50:27.000Z | 2020-09-08T08:48:52.000Z | tests/expected/python3/comment/tea_python_tests/client.py | Orisdaddy/darabonba-python-generator | 6c437d865f45b1a81faf1ca2a7dad608dc36c3bf | [
"Apache-2.0"
] | 68 | 2020-06-18T08:51:38.000Z | 2021-01-19T09:01:10.000Z | tests/expected/python3/comment/tea_python_tests/client.py | Orisdaddy/darabonba-python-generator | 6c437d865f45b1a81faf1ca2a7dad608dc36c3bf | [
"Apache-2.0"
] | 11 | 2020-06-18T07:21:03.000Z | 2020-07-31T07:56:50.000Z | # -*- coding: utf-8 -*-
# top comment
# This file is auto-generated, don't edit it. Thanks.
import time
from Tea.request import TeaRequest
from Tea.core import TeaCore
from Tea.exceptions import UnretryableException
from typing import List, Dict, BinaryIO, Any
from tea_python_tests import models as main_models
class Client:
"""
top annotation
"""
# type's comment
_a: List[str] = None
_comple_list: List[List[str]] = None
_endpoint_map: Dict[str, str] = None
def __init__(self):
"""
Init Func
"""
# string declate comment
str = 'sss'
# new model instance comment
model_instance = main_models.Test1(
test='test',
# test declare back comment,
test_2='test2',
# test2 declare back comment
)
array = [
# array string comment
'string',
# array number comment
300
]
def test_api(self) -> None:
"""
testAPI
testAPI comment one
testAPI comment two
"""
_runtime = [
# empty runtime comment
# another runtime comment
]
_last_request = None
_last_exception = None
_now = time.time()
_retry_times = 0
while TeaCore.allow_retry(_runtime.get('retry'), _retry_times, _now):
if _retry_times > 0:
_backoff_time = TeaCore.get_backoff_time(_runtime.get('backoff'), _retry_times)
if _backoff_time > 0:
TeaCore.sleep(_backoff_time)
_retry_times = _retry_times + 1
try:
_request = TeaRequest()
# new model instance comment
model_instance = main_models.Test1(
# test declare front comment,
test='test',
# test2 declare front comment,
test_2='test2'
)
# number declare comment
num = 123
# static function call comment
self.static_func()
_last_request = _request
_response = TeaCore.do_action(_request, _runtime)
# static async function call
self.test_func('test', True, [
[
'str'
],
[
'str1'
]
])
# return comment
return
except Exception as e:
if TeaCore.is_retryable(e):
_last_exception = e
continue
raise e
raise UnretryableException(_last_request, _last_exception)
async def test_api_async(self) -> None:
"""
testAPI
testAPI comment one
testAPI comment two
"""
_runtime = [
# empty runtime comment
# another runtime comment
]
_last_request = None
_last_exception = None
_now = time.time()
_retry_times = 0
while TeaCore.allow_retry(_runtime.get('retry'), _retry_times, _now):
if _retry_times > 0:
_backoff_time = TeaCore.get_backoff_time(_runtime.get('backoff'), _retry_times)
if _backoff_time > 0:
TeaCore.sleep(_backoff_time)
_retry_times = _retry_times + 1
try:
_request = TeaRequest()
# new model instance comment
model_instance = main_models.Test1(
# test declare front comment,
test='test',
# test2 declare front comment,
test_2='test2'
)
# number declare comment
num = 123
# static function call comment
self.static_func()
_last_request = _request
_response = await TeaCore.async_do_action(_request, _runtime)
# static async function call
await self.test_func_async('test', True, [
[
'str'
],
[
'str1'
]
])
# return comment
return
except Exception as e:
if TeaCore.is_retryable(e):
_last_exception = e
continue
raise e
raise UnretryableException(_last_request, _last_exception)
def test_api2(self) -> None:
"""
testAPI2 comment
"""
_runtime = {
# runtime retry comment
'retry': True,
# runtime back comment one
# runtime back comment two
}
_last_request = None
_last_exception = None
_now = time.time()
_retry_times = 0
while TeaCore.allow_retry(_runtime.get('retry'), _retry_times, _now):
if _retry_times > 0:
_backoff_time = TeaCore.get_backoff_time(_runtime.get('backoff'), _retry_times)
if _backoff_time > 0:
TeaCore.sleep(_backoff_time)
_retry_times = _retry_times + 1
try:
_request = TeaRequest()
# new model instance comment
model_instance = main_models.Test3(
# empty model
)
# boolean declare comment
bool = True
if bool:
# empty if
pass
else:
# empty else
pass
# api function call comment
self.test_api()
_last_request = _request
_response = TeaCore.do_action(_request, _runtime)
# empty return comment
# back comment
except Exception as e:
if TeaCore.is_retryable(e):
_last_exception = e
continue
raise e
raise UnretryableException(_last_request, _last_exception)
async def test_api2_async(self) -> None:
"""
testAPI2 comment
"""
_runtime = {
# runtime retry comment
'retry': True,
# runtime back comment one
# runtime back comment two
}
_last_request = None
_last_exception = None
_now = time.time()
_retry_times = 0
while TeaCore.allow_retry(_runtime.get('retry'), _retry_times, _now):
if _retry_times > 0:
_backoff_time = TeaCore.get_backoff_time(_runtime.get('backoff'), _retry_times)
if _backoff_time > 0:
TeaCore.sleep(_backoff_time)
_retry_times = _retry_times + 1
try:
_request = TeaRequest()
# new model instance comment
model_instance = main_models.Test3(
# empty model
)
# boolean declare comment
bool = True
if bool:
# empty if
pass
else:
# empty else
pass
# api function call comment
await self.test_api_async()
_last_request = _request
_response = await TeaCore.async_do_action(_request, _runtime)
# empty return comment
# back comment
except Exception as e:
if TeaCore.is_retryable(e):
_last_exception = e
continue
raise e
raise UnretryableException(_last_request, _last_exception)
@staticmethod
def static_func() -> None:
a = [
# empty annotation comment
]
@staticmethod
def test_func(
str: str,
val: bool,
comple_list: List[List[str]],
) -> str:
"""
testFunc
@param str: description: string parameter
@param val: description: boolean parameter
@return: `test` for return
"""
# empty comment1
# empty comment2
s = 'test'
return s
@staticmethod
async def test_func_async(
str: str,
val: bool,
comple_list: List[List[str]],
) -> str:
"""
testFunc
@param str: description: string parameter
@param val: description: boolean parameter
@return: `test` for return
"""
# empty comment1
# empty comment2
s = 'test'
return s
@staticmethod
def test_func_params(
comple_list: List[List[str]],
map_test: Dict[str, str],
read: BinaryIO,
any_test: Any,
test_1: main_models.Test1,
) -> None:
"""
testFuncComment
@param comple_list: list parameter
@param map_test: dict parameter
@param read: readable parameter
@param any_test: any parameter
@param test_1: Model parameter
@return: void description for return
"""
pass
@staticmethod
async def test_func_params_async(
comple_list: List[List[str]],
map_test: Dict[str, str],
read: BinaryIO,
any_test: Any,
test_1: main_models.Test1,
) -> None:
"""
testFuncComment
@param comple_list: list parameter
@param map_test: dict parameter
@param read: readable parameter
@param any_test: any parameter
@param test_1: Model parameter
@return: void description for return
"""
pass
| 31.0875 | 95 | 0.492963 | 907 | 9,948 | 5.131202 | 0.13892 | 0.051569 | 0.024065 | 0.019338 | 0.8526 | 0.838633 | 0.838633 | 0.838633 | 0.828749 | 0.815428 | 0 | 0.010048 | 0.439787 | 9,948 | 319 | 96 | 31.184953 | 0.825049 | 0.164355 | 0 | 0.762626 | 1 | 0 | 0.016622 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0.030303 | false | 0.030303 | 0.030303 | 0 | 0.10101 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 1 | 1 | 1 | 1 | 1 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 1 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 8 |
b0321f15af2ef8524c75be1c402282742daf0eea | 8,645 | py | Python | src/_build/build.py | sl-lang/sll | 05205c32e9c263c2a41ed96147a8677b2cd54a2d | [
"MIT"
] | 14 | 2021-08-21T10:26:03.000Z | 2022-03-23T14:44:24.000Z | src/_build/build.py | sl-lang/sll | 05205c32e9c263c2a41ed96147a8677b2cd54a2d | [
"MIT"
] | 247 | 2021-08-19T08:35:24.000Z | 2022-03-28T09:56:29.000Z | src/_build/build.py | sl-lang/sll | 05205c32e9c263c2a41ed96147a8677b2cd54a2d | [
"MIT"
] | 1 | 2021-10-10T00:30:41.000Z | 2021-10-10T00:30:41.000Z | import os
import subprocess
import sys
import util
def build_sll(fl,v,r):
nm=f"sll-{v[0]}.{v[1]}.{v[2]}"
cd=os.getcwd()
os.chdir("build")
if (os.name=="nt"):
e_fl=(["/D",f"__SHA__=\"{os.getenv('GITHUB_SHA')[:7]}\"","/D",f"__FULL_SHA__=\"{os.getenv('GITHUB_SHA')}\""] if os.getenv("GITHUB_SHA") else [])+(["/D","USE_STACK_ALLOCATOR=1"] if len(os.getenv("USE_STACK_ALLOCATOR",""))!=0 else [])
if (r):
util.log(" Compiling Files (Release Mode)...")
if (subprocess.run(["cl","/c","/permissive-","/Zc:preprocessor","/std:c11","/Wv:18","/GS","/utf-8","/W3","/Zc:wchar_t","/Gm-","/sdl","/Zc:inline","/fp:precise","/D","NDEBUG","/D","_WINDOWS","/D","WINDLL","/D","USERDLL","/D","__SLL_COMPILATION__","/D","WIN32_LEAN_AND_MEAN","/D","_CRT_SECURE_NO_WARNINGS","/errorReport:none","/WX","/Zc:forScope","/Gd","/Oi","/EHsc","/nologo","/diagnostics:column","/GL","/Gy","/Zi","/O2","/MD","/I","../src/sll/include","/Foobjects\\","/D",f"__TIME_RAW__={util.BUILD_TIME}"]+e_fl+["../"+e for e in fl]).returncode!=0):
os.chdir(cd)
sys.exit(1)
util.log(" Linking Files (Release Mode)...")
if (subprocess.run(["link",f"/OUT:{nm}.dll","/DLL","/DYNAMICBASE","/MACHINE:X64","/SUBSYSTEM:WINDOWS","/ERRORREPORT:none","/NOLOGO","/TLBID:1","/WX","/LTCG","/OPT:NOREF","/INCREMENTAL:NO","/RELEASE","bcrypt.lib"]+["objects/"+e for e in os.listdir("objects")]).returncode!=0):
os.chdir(cd)
sys.exit(1)
else:
util.log(" Compiling Files...")
if (subprocess.run(["cl","/c","/permissive-","/Zc:preprocessor","/std:c11","/Wv:18","/GS","/utf-8","/W3","/Zc:wchar_t","/Gm-","/sdl","/Zc:inline","/fp:precise","/D","_DEBUG","/D","_WINDOWS","/D","WINDLL","/D","USERDLL","/D","__SLL_COMPILATION__","/D","WIN32_LEAN_AND_MEAN","/D","DEBUG_BUILD","/D","_CRT_SECURE_NO_WARNINGS","/errorReport:none","/WX","/Zc:forScope","/Gd","/Oi","/EHsc","/nologo","/diagnostics:column","/Zi","/Od","/RTC1","/MDd","/I","../src/sll/include","/Foobjects\\","/D",f"__TIME_RAW__={util.BUILD_TIME}"]+e_fl+["../"+e for e in fl]).returncode!=0):
os.chdir(cd)
sys.exit(1)
util.log(" Linking Files...")
if (subprocess.run(["link",f"/OUT:{nm}.dll","/DLL","/DYNAMICBASE","/MACHINE:X64","/SUBSYSTEM:WINDOWS","/ERRORREPORT:none","/NOLOGO","/TLBID:1","/WX","/DEBUG","/INCREMENTAL:NO","/RELEASE","bcrypt.lib"]+["objects/"+e for e in os.listdir("objects")]).returncode!=0):
os.chdir(cd)
sys.exit(1)
else:
e_fl=(["-D",f"__SHA__=\"{os.getenv('GITHUB_SHA')[:7]}\"","-D",f"__FULL_SHA__=\"{os.getenv('GITHUB_SHA')}\""] if os.getenv("GITHUB_SHA") else [])+(["-D","USE_STACK_ALLOCATOR=1"] if len(os.getenv("USE_STACK_ALLOCATOR",""))!=0 else [])
if (r):
util.log(" Compiling Files (Release Mode)...")
os.chdir("objects")
if (subprocess.run(["gcc","-fdiagnostics-color=always","-fPIC","-c","-fvisibility=hidden","-D","__SLL_COMPILATION__","-D","_GNU_SOURCE","-Wall","-O3","-Werror","-I","../../src/sll/include","-D",f"__TIME_RAW__={util.BUILD_TIME}"]+e_fl+["../../"+e for e in fl]+["-lm"]).returncode!=0):
os.chdir(cd)
sys.exit(1)
os.chdir("..")
util.log(" Linking Files (Release Mode)...")
if (subprocess.run(["gcc","-fdiagnostics-color=always","-shared","-fPIC","-fvisibility=hidden","-Wall","-O3","-Werror","-o",nm+".so"]+["objects/"+e for e in os.listdir("objects")]+["-lm","-ldl"]).returncode!=0):
os.chdir(cd)
sys.exit(1)
else:
util.log(" Compiling Files...")
os.chdir("objects")
if (subprocess.run(["gcc","-fdiagnostics-color=always","-fPIC","-c","-fvisibility=hidden","-D","__SLL_COMPILATION__","-D","DEBUG_BUILD","-D","_GNU_SOURCE","-Wall","-g","-O0","-Werror","-I","../../src/sll/include","-D",f"__TIME_RAW__={util.BUILD_TIME}"]+e_fl+["../../"+e for e in fl]+["-lm"]).returncode!=0):
os.chdir(cd)
sys.exit(1)
os.chdir("..")
util.log(" Linking Files...")
if (subprocess.run(["gcc","-fdiagnostics-color=always","-shared","-fPIC","-fvisibility=hidden","-Wall","-Werror","-g","-O0","-o",nm+".so"]+["objects/"+e for e in os.listdir("objects")]+["-lm","-ldl"]).returncode!=0):
os.chdir(cd)
sys.exit(1)
os.chdir(cd)
def build_sll_cli():
cd=os.getcwd()
os.chdir("build")
if (os.name=="nt"):
util.log(" Compiling Files (Release Mode)...")
if (subprocess.run(["cl","/c","/permissive-","/Zc:preprocessor","/std:c11","/Wv:18","/GS","/utf-8","/W3","/Zc:wchar_t","/Gm-","/sdl","/Zc:inline","/fp:precise","/D","NDEBUG","/D","_WINDOWS","/D","_CRT_SECURE_NO_WARNINGS","/D","WIN32_LEAN_AND_MEAN","/errorReport:none","/WX","/Zc:forScope","/Gd","/Oi","/EHsc","/nologo","/diagnostics:column","/GL","/Gy","/Zi","/O2","/MD","/I",".","/Fomain.obj","../src/cli/main_windows.c"]).returncode!=0):
os.chdir(cd)
sys.exit(1)
util.log(" Linking Files (Release Mode)...")
if (subprocess.run(["link","main.obj","/OUT:sll.exe","/DYNAMICBASE","/MACHINE:X64","/SUBSYSTEM:WINDOWS","/ERRORREPORT:none","/NOLOGO","/TLBID:1","/WX","/LTCG","/OPT:REF","/INCREMENTAL:NO","/RELEASE"]).returncode!=0):
os.chdir(cd)
sys.exit(1)
else:
util.log(" Compiling & Linking Files...")
if (subprocess.run(["gcc","-fdiagnostics-color=always","-Wall","-lm","-Werror","-O3","../src/cli/main_posix.c","-o","sll","-I",".","-ldl"]).returncode!=0):
os.chdir(cd)
sys.exit(1)
os.chdir(cd)
def build_sll_extension(fl,v,r):
b_nm=f"sll-{v[0]}.{v[1]}.{v[2]}"
nm=f"sll-ext-debug-{v[0]}.{v[1]}.{v[2]}"
cd=os.getcwd()
os.chdir("build")
if (os.name=="nt"):
if (r):
util.log(" Compiling Library Files (Release Mode)...")
if (subprocess.run(["cl","/c","/permissive-","/Zc:preprocessor","/std:c11","/Wv:18","/GS","/utf-8","/W3","/Zc:wchar_t","/Gm-","/sdl","/Zc:inline","/fp:precise","/D","NDEBUG","/D","_WINDOWS","/D","WINDLL","/D","USERDLL","/D","WIN32_LEAN_AND_MEAN","/D","_CRT_SECURE_NO_WARNINGS","/errorReport:none","/WX","/Zc:forScope","/Gd","/Oi","/EHsc","/nologo","/diagnostics:column","/GL","/Gy","/Zi","/O2","/MD","/I","../src/ext/debug/include","/I",".","/Foobjects_ext\\"]+["../"+e for e in fl]).returncode!=0):
os.chdir(cd)
sys.exit(1)
util.log(" Linking Library Files (Release Mode)...")
if (subprocess.run(["link",f"/OUT:{nm}.dll","/DLL","/DYNAMICBASE","/MACHINE:X64","/SUBSYSTEM:WINDOWS","/ERRORREPORT:none","/NOLOGO","/TLBID:1","/WX","/LTCG","/OPT:NOREF","/INCREMENTAL:NO","/RELEASE",b_nm+".lib"]+["objects_ext/"+e for e in os.listdir("objects_ext")]).returncode!=0):
os.chdir(cd)
sys.exit(1)
else:
util.log(" Compiling Library Files...")
if (subprocess.run(["cl","/c","/permissive-","/Zc:preprocessor","/std:c11","/Wv:18","/GS","/utf-8","/W3","/Zc:wchar_t","/Gm-","/sdl","/Zc:inline","/fp:precise","/D","_DEBUG","/D","_WINDOWS","/D","WINDLL","/D","USERDLL","/D","WIN32_LEAN_AND_MEAN","/D","_CRT_SECURE_NO_WARNINGS","/errorReport:none","/WX","/Zc:forScope","/Gd","/Oi","/EHsc","/nologo","/diagnostics:column","/Zi","/Od","/RTC1","/MDd","/I","../src/ext/debug/include","/I",".","/Foobjects_ext\\"]+["../"+e for e in fl]).returncode!=0):
os.chdir(cd)
sys.exit(1)
util.log(" Linking Library Files...")
if (subprocess.run(["link",f"/OUT:{nm}.dll","/DLL","/DYNAMICBASE","/MACHINE:X64","/SUBSYSTEM:WINDOWS","/ERRORREPORT:none","/NOLOGO","/TLBID:1","/WX","/DEBUG","/INCREMENTAL:NO","/RELEASE",b_nm+".lib"]+["objects_ext/"+e for e in os.listdir("objects_ext")]).returncode!=0):
os.chdir(cd)
sys.exit(1)
else:
if (r):
util.log(" Compiling Library Files (Release Mode)...")
os.chdir("objects_ext")
if (subprocess.run(["gcc","-fdiagnostics-color=always","-fPIC","-c","-fvisibility=hidden","-Wall","-O3","-Werror","-I","../../src/ext/debug/include","-I","../"]+["../../"+e for e in fl]+["-lm"]).returncode!=0):
os.chdir(cd)
sys.exit(1)
os.chdir("..")
util.log(" Linking Library Files (Release Mode)...")
if (subprocess.run(["gcc","-fdiagnostics-color=always","-shared","-fPIC","-fvisibility=hidden","-Wall","-O3","-Werror","-o",nm+".so"]+["objects_ext/"+e for e in os.listdir("objects_ext")]+["-lm"]).returncode!=0):
os.chdir(cd)
sys.exit(1)
else:
util.log(" Compiling Library Files...")
os.chdir("objects_ext")
if (subprocess.run(["gcc","-fdiagnostics-color=always","-fPIC","-c","-fvisibility=hidden","-Wall","-g","-O0","-Werror","-I","../../src/ext/debug/include","-I","../"]+["../../"+e for e in fl]+["-lm"]).returncode!=0):
os.chdir(cd)
sys.exit(1)
os.chdir("..")
util.log(" Linking Library Files...")
if (subprocess.run(["gcc","-fdiagnostics-color=always","-shared","-fPIC","-fvisibility=hidden","-Wall","-g","-O0","-o",nm+".so"]+["objects_ext/"+e for e in os.listdir("objects_ext")]+["-lm"]).returncode!=0):
os.chdir(cd)
sys.exit(1)
os.chdir(cd)
| 67.015504 | 570 | 0.595836 | 1,272 | 8,645 | 3.926101 | 0.117138 | 0.046256 | 0.039648 | 0.068482 | 0.952944 | 0.944133 | 0.940929 | 0.940929 | 0.940929 | 0.913096 | 0 | 0.015248 | 0.074494 | 8,645 | 128 | 571 | 67.539063 | 0.608924 | 0 | 0 | 0.731092 | 0 | 0 | 0.508271 | 0.090804 | 0 | 0 | 0 | 0 | 0 | 1 | 0.02521 | false | 0 | 0.033613 | 0 | 0.058824 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 1 | 1 | 1 | 1 | 1 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 7 |
b05bee28896a7e85c98477a6a889cf9d82fd0ecb | 146 | py | Python | modules/modules/glitch.py | Kerdek/gie | ebcd1aec6dc34de46145e4013afd6d5dad194a9f | [
"BSD-3-Clause-Clear"
] | 57 | 2019-06-21T21:15:03.000Z | 2022-03-30T18:17:56.000Z | modules/modules/glitch.py | Kerdek/gie | ebcd1aec6dc34de46145e4013afd6d5dad194a9f | [
"BSD-3-Clause-Clear"
] | 2 | 2020-08-04T05:45:03.000Z | 2021-02-26T10:21:16.000Z | modules/modules/glitch.py | Kerdek/gie | ebcd1aec6dc34de46145e4013afd6d5dad194a9f | [
"BSD-3-Clause-Clear"
] | 8 | 2019-11-24T07:57:46.000Z | 2021-05-05T07:58:29.000Z | import modules.internals
def jpeg_artifacts(source: Image, radius: int)->Image:
return modules.images_internal.jpeg_artifacts(source, radius) | 36.5 | 65 | 0.808219 | 19 | 146 | 6.052632 | 0.684211 | 0.226087 | 0.330435 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0.09589 | 146 | 4 | 65 | 36.5 | 0.871212 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0.333333 | false | 0 | 0.333333 | 0.333333 | 1 | 0 | 1 | 0 | 0 | null | 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 | 1 | 0 | 0 | 1 | 1 | 1 | 0 | 0 | 8 |
c678e606f3a6e67913dcca339a94d850e3a76549 | 45 | py | Python | ast-transformations-core/src/test/resources/org/jetbrains/research/ml/ast/gumtree/tree/data/function/in_0.py | JetBrains-Research/ast-transformations | 0ab408af3275b520cc87a473f418c4b4dfcb0284 | [
"MIT"
] | 8 | 2021-01-19T21:15:54.000Z | 2022-02-23T19:16:25.000Z | ast-transformations-core/src/test/resources/org/jetbrains/research/ml/ast/gumtree/tree/data/function/in_0.py | JetBrains-Research/ast-transformations | 0ab408af3275b520cc87a473f418c4b4dfcb0284 | [
"MIT"
] | 4 | 2020-11-17T14:28:25.000Z | 2022-02-24T07:54:28.000Z | ast-transformations-core/src/test/resources/org/jetbrains/research/ml/ast/gumtree/tree/data/function/in_0.py | nbirillo/ast-transformations | 717706765a2da29087a0de768fc851698886dd65 | [
"MIT"
] | 1 | 2022-02-23T19:16:30.000Z | 2022-02-23T19:16:30.000Z | def f(a, b=1, c=2, *d, e, f=3, **g):
pass | 22.5 | 36 | 0.4 | 13 | 45 | 1.384615 | 0.923077 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0.090909 | 0.266667 | 45 | 2 | 37 | 22.5 | 0.454545 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0.5 | false | 0.5 | 0 | 0 | 0.5 | 0 | 1 | 1 | 1 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 1 | 0 | 0 | 0 | 0 | 0 | 7 |
05baa79bbc828aa33773ded3ca428a78b71247c3 | 410 | py | Python | esercizi/espressione.py | gdv/python-alfabetizzazione | d87561222de8a230db11d8529c49cf1702aec326 | [
"MIT"
] | null | null | null | esercizi/espressione.py | gdv/python-alfabetizzazione | d87561222de8a230db11d8529c49cf1702aec326 | [
"MIT"
] | null | null | null | esercizi/espressione.py | gdv/python-alfabetizzazione | d87561222de8a230db11d8529c49cf1702aec326 | [
"MIT"
] | 1 | 2019-03-26T11:14:33.000Z | 2019-03-26T11:14:33.000Z | a = input("inserire il valore di a ")
b = input("inserire il valore di b ")
y = input("inserire il valore di y ")
print "a + b * (4 * y + 7.0) = ", a + b * (4 * y + 7.0)
print "a + ( b * 4 * y + 7.0) = ", a + (b * 4 * y + 7.0)
print "(a + b) * 4 * y + 7.0 = ", (a + b) * 4 * y + 7.0
print "a + ( (b * 4) * (y + 7.0) ) = ", a + ((b * 4) * (y + 7.0))
print "(a + b * 4 * y + 7.0) = ", (a + b * 4 * y + 7.0)
| 41 | 66 | 0.390244 | 86 | 410 | 1.860465 | 0.139535 | 0.1375 | 0.1875 | 0.25 | 0.9625 | 0.53125 | 0.53125 | 0.53125 | 0.53125 | 0.53125 | 0 | 0.10989 | 0.334146 | 410 | 9 | 67 | 45.555556 | 0.47619 | 0 | 0 | 0 | 0 | 0 | 0.495122 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | null | 0 | 0 | null | null | 0.625 | 0 | 0 | 1 | null | 0 | 1 | 1 | 1 | 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 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 8 |
af26e74ca6d6827e2c46f0dcaf63775adca9c96b | 4,218 | py | Python | tests/test_codeepneat.py | githealthy18/Tensorflow-Neuroevolution | 15f6e906e8000c64f5c9a60907f53fe835f0b28c | [
"Apache-2.0"
] | 121 | 2019-06-27T17:30:52.000Z | 2022-03-24T07:32:42.000Z | tests/test_codeepneat.py | githealthy18/Tensorflow-Neuroevolution | 15f6e906e8000c64f5c9a60907f53fe835f0b28c | [
"Apache-2.0"
] | 10 | 2021-01-03T19:52:13.000Z | 2022-02-10T00:15:26.000Z | tests/test_codeepneat.py | githealthy18/Tensorflow-Neuroevolution | 15f6e906e8000c64f5c9a60907f53fe835f0b28c | [
"Apache-2.0"
] | 31 | 2019-07-31T10:45:53.000Z | 2022-03-21T08:31:09.000Z | import os
import tempfile
# Deactivate GPUs as pytest seems very error-prone in combination with Tensorflow
os.environ['CUDA_VISIBLE_DEVICES'] = '-1'
import tfne
def sanity_check_algorithm_state(ne_algorithm):
"""
Very basic sanity check as the purpose of the pytest checks is the run of the evolutionary loops. If there are some
bugs in the evolutionary process the complex logic will fail. Therefore there is not much purpose in doing extensive
asserts after the evolutionary process succeded.
"""
best_genome = ne_algorithm.get_best_genome()
assert 100 >= best_genome.get_fitness() > 0
def test_codeepneat_1():
# Create test config
config = tfne.parse_configuration(os.path.dirname(__file__) + '/test_codeepneat_1_config.cfg')
environment = tfne.environments.XOREnvironment(weight_training=True, config=config)
ne_algorithm = tfne.algorithms.CoDeepNEAT(config)
# Start test
engine = tfne.EvolutionEngine(ne_algorithm=ne_algorithm,
environment=environment,
backup_dir_path=tempfile.gettempdir(),
max_generations=10,
max_fitness=None)
engine.train()
# Sanity check state of the algorithm
sanity_check_algorithm_state(ne_algorithm)
def test_codeepneat_2():
# Create test config
config = tfne.parse_configuration(os.path.dirname(__file__) + '/test_codeepneat_2_config.cfg')
environment = tfne.environments.XOREnvironment(weight_training=True, config=config)
ne_algorithm = tfne.algorithms.CoDeepNEAT(config)
# Start test
engine = tfne.EvolutionEngine(ne_algorithm=ne_algorithm,
environment=environment,
backup_dir_path=tempfile.gettempdir(),
max_generations=6,
max_fitness=None)
engine.train()
# Sanity check state of the algorithm
sanity_check_algorithm_state(ne_algorithm)
def test_codeepneat_3():
# Create test config
config = tfne.parse_configuration(os.path.dirname(__file__) + '/test_codeepneat_3_config.cfg')
environment = tfne.environments.XOREnvironment(weight_training=True, config=config)
ne_algorithm = tfne.algorithms.CoDeepNEAT(config)
# Start test
engine = tfne.EvolutionEngine(ne_algorithm=ne_algorithm,
environment=environment,
backup_dir_path=tempfile.gettempdir(),
max_generations=6,
max_fitness=None)
engine.train()
# Sanity check state of the algorithm
sanity_check_algorithm_state(ne_algorithm)
def test_codeepneat_4():
# Create test config
config = tfne.parse_configuration(os.path.dirname(__file__) + '/test_codeepneat_4_config.cfg')
environment = tfne.environments.MNISTEnvironment(weight_training=True, config=config)
ne_algorithm = tfne.algorithms.CoDeepNEAT(config)
# Start test
engine = tfne.EvolutionEngine(ne_algorithm=ne_algorithm,
environment=environment,
backup_dir_path=tempfile.gettempdir(),
max_generations=2,
max_fitness=None)
engine.train()
# Sanity check state of the algorithm
sanity_check_algorithm_state(ne_algorithm)
def test_codeepneat_5():
# Create test config
config = tfne.parse_configuration(os.path.dirname(__file__) + '/test_codeepneat_4_config.cfg')
environment = tfne.environments.CIFAR10Environment(weight_training=True, config=config)
ne_algorithm = tfne.algorithms.CoDeepNEAT(config)
# Start test
engine = tfne.EvolutionEngine(ne_algorithm=ne_algorithm,
environment=environment,
backup_dir_path=tempfile.gettempdir(),
max_generations=2,
max_fitness=None)
engine.train()
# Sanity check state of the algorithm
sanity_check_algorithm_state(ne_algorithm)
| 39.055556 | 120 | 0.650071 | 447 | 4,218 | 5.861298 | 0.214765 | 0.092366 | 0.045802 | 0.057252 | 0.81374 | 0.81374 | 0.8 | 0.8 | 0.8 | 0.8 | 0 | 0.007566 | 0.279279 | 4,218 | 107 | 121 | 39.420561 | 0.854276 | 0.164059 | 0 | 0.709677 | 0 | 0 | 0.047892 | 0.041583 | 0 | 0 | 0 | 0 | 0.016129 | 1 | 0.096774 | false | 0 | 0.048387 | 0 | 0.145161 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 1 | 1 | 1 | 1 | 1 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 7 |
af445296e9a70809834d6c984fa118cdbb7a0f98 | 12,939 | py | Python | oc_config_validate/oc_config_validate/testcases/subif_ip.py | JoseIgnacioTamayo/gnxi | 1ebe7b7e58d33844e5bcbca0710153760c03e9f7 | [
"Apache-2.0"
] | 1 | 2019-08-06T09:25:43.000Z | 2019-08-06T09:25:43.000Z | oc_config_validate/oc_config_validate/testcases/subif_ip.py | JoseIgnacioTamayo/gnxi | 1ebe7b7e58d33844e5bcbca0710153760c03e9f7 | [
"Apache-2.0"
] | null | null | null | oc_config_validate/oc_config_validate/testcases/subif_ip.py | JoseIgnacioTamayo/gnxi | 1ebe7b7e58d33844e5bcbca0710153760c03e9f7 | [
"Apache-2.0"
] | null | null | null | """Test cases for subinterfaces with IPv4 addresses."""
import json
from pyangbind.lib import pybindJSON
from retry import retry
from oc_config_validate import schema, testbase
from oc_config_validate.models.interfaces import \
openconfig_interfaces as oc_interfaces
class SetSubifDhcp(testbase.TestCase):
"""Tests configuring DHCP on a subinterface.
1. A gNMI Set message is sent to configure the subinterface.
1. A gNMI Get message on the /config container validates it.
All arguments are read from the Test YAML description.
Args:
interface: Name of the physical interface.
index: Index of the subinterface, defaults to 0.
dhcp: True to enable DHCP, defaults to False.
"""
interface = ""
index = 0
dhcp = False
def test0100(self):
self.assertArgs(["interface"])
iface = oc_interfaces().interfaces.interface.add(self.interface)
subif = iface.subinterfaces.subinterface.add(self.index)
if self.index:
subif.vlan.config.vlan_id = self.index
subif.ipv4.config.dhcp_client = self.dhcp
xpath = "/interfaces/interface[name=%s]" % self.interface
_json_value = json.loads(pybindJSON.dumps(iface, mode='ietf'))
schema.fixSubifIndex(_json_value)
self.assertTrue(self.gNMISetUpdate(xpath, _json_value),
"gNMI Set did not succeed.")
@retry(exceptions=AssertionError, tries=5, delay=15)
def test0200(self):
xpath = ("/interfaces/interface[name=%s]/subinterfaces/"
"subinterface[index=%d]/ipv4/config/dhcp-client") % (
self.interface, self.index)
resp_val = self.gNMIGet(xpath)
self.assertIsNotNone(resp_val, "No gNMI GET response")
self.assertIsNotNone(
resp_val.bool_val,
"The gNMI Get response is not a boolean: %s" % resp_val)
self.assertEqual(resp_val.bool_val, self.dhcp,
"Dhcp client config = %s, wanted %s" % (
resp_val.bool_val, self.dhcp))
@retry(exceptions=AssertionError, tries=5, delay=15)
def test0300(self):
xpath = ("/interfaces/interface[name=%s]/subinterfaces/"
"subinterface[index=%d]/ipv4/state/dhcp-client") % (
self.interface, self.index)
resp_val = self.gNMIGet(xpath)
self.assertIsNotNone(resp_val, "No gNMI GET response")
self.assertIsNotNone(
resp_val.bool_val,
"The gNMI Get response is not a boolean: %s" % resp_val)
self.assertEqual(resp_val.bool_val, self.dhcp,
"Dhcp client state = %s, wanted %s" % (
resp_val.bool_val, self.dhcp))
class CheckSubifDhcpState(testbase.TestCase):
"""Checks the DHCP state on a subinterface.
1. A gNMI Get message on the /state container.
All arguments are read from the Test YAML description.
Args:
interface: Name of the physical interface.
index: Index of the subinterface, defaults to 0.
dhcp: True to enable DHCP, defaults to False.
"""
interface = ""
index = 0
dhcp = False
@retry(exceptions=AssertionError, tries=5, delay=15)
def test0100(self):
""""""
xpath = ("/interfaces/interface[name=%s]/subinterfaces/"
"subinterface[index=%d]/ipv4/state/dhcp-client") % (
self.interface, self.index)
resp_val = self.gNMIGet(xpath)
self.assertIsNotNone(resp_val, "No gNMI GET response")
self.assertIsNotNone(
resp_val.bool_val,
"The gNMI Get response is not a boolean: %s" % resp_val)
self.assertEqual(resp_val.bool_val, self.dhcp,
"Dhcp client state = %s, wanted %s" % (
resp_val.bool_val, self.dhcp))
class CheckSubifDhcpConfig(testbase.TestCase):
"""Checks the DHCP config on a subinterface.
1. A gNMI Get message on the /config container.
All arguments are read from the Test YAML description.
Args:
interface: Name of the physical interface.
index: Index of the subinterface, defaults to 0.
dhcp: True to enable DHCP, defaults to False.
"""
interface = ""
index = 0
dhcp = False
@retry(exceptions=AssertionError, tries=5, delay=15)
def test0100(self):
""""""
xpath = ("/interfaces/interface[name=%s]/subinterfaces/"
"subinterface[index=%d]/ipv4/config/dhcp-client") % (
self.interface, self.index)
resp_val = self.gNMIGet(xpath)
self.assertIsNotNone(resp_val, "No gNMI GET response")
self.assertIsNotNone(
resp_val.bool_val,
"The gNMI Get response is not a boolean: %s" % resp_val)
self.assertEqual(resp_val.bool_val, self.dhcp,
"Dhcp client config = %s, wanted %s" % (
resp_val.bool_val, self.dhcp))
class AddSubifIp(testbase.TestCase):
"""Tests configuring an IP on a subinterface.
1. A gNMI Set message is sent to configure the subinterface.
1. A gNMI Get message on the /config container validates it.
All arguments are read from the Test YAML description.
Args:
interface: Name of the physical interface.
index: Index of the subinterface, defaults to 0.
address: IPv4 address to add.
prefix_length: Prefix lenght of the IPv4 address to add.
"""
interface = ""
index = 0
address = ""
prefix_length = 32
iface = None
def setUp(self):
self.iface = oc_interfaces().interfaces.interface.add(self.interface)
subif = self.iface.subinterfaces.subinterface.add(self.index)
if self.index:
subif.vlan.config.vlan_id = self.index
self.addr = subif.ipv4.addresses.address.add(self.address)
self.addr.config.ip = self.address
self.addr.config.prefix_length = self.prefix_length
def test0100(self):
self.assertArgs(["interface", "address", "prefix_length"])
xpath = "/interfaces/interface[name=%s]" % self.interface
_json_value = json.loads(pybindJSON.dumps(self.iface, mode='ietf'))
schema.fixSubifIndex(_json_value)
self.assertTrue(self.gNMISetUpdate(xpath, _json_value),
"gNMI Set did not succeed.")
@retry(exceptions=AssertionError, tries=5, delay=15)
def test0200(self):
xpath = ("/interfaces/interface[name=%s]/subinterfaces/"
"subinterface[index=%d]/ipv4/addresses"
"/address[ip=%s]/config") % (
self.interface, self.index, self.address)
resp_val = self.gNMIGetJson(xpath)
self.assertJsonModel(
resp_val, self.addr.config,
'gNMI Get on the /config container does not match model')
want = json.loads(
schema.removeOpenConfigPrefix(
pybindJSON.dumps(self.addr.config, mode='ietf')))
self.assertJsonCmp(resp_val, want)
@retry(exceptions=AssertionError, tries=5, delay=15)
def test0300(self):
xpath = ("/interfaces/interface[name=%s]/subinterfaces/"
"subinterface[index=%d]/ipv4/addresses"
"/address[ip=%s]/state") % (
self.interface, self.index, self.address)
resp_val = self.gNMIGetJson(xpath)
self.addr.state._set_ip(self.address)
self.addr.state._set_prefix_length(self.prefix_length)
self.assertJsonModel(
resp_val, self.addr.state,
'gNMI Get on the /state container does not match model')
want = json.loads(
schema.removeOpenConfigPrefix(
pybindJSON.dumps(self.addr.state, mode='ietf')))
self.assertJsonCmp(resp_val, want)
class RemoveSubifIp(testbase.TestCase):
"""Tests removing an IP on a subinterface.
1. gNMI Get message on the /config container, to check it is configured.
1. gNMI Set message to delete the ip.
1. gNMI Get message on the /config container to check it is not there.
1. gNMI Get message on the /state container to check it is not there.
All arguments are read from the Test YAML description.
Args:
interface: Name of the physical interface.
index: Index of the subinterface, defaults to 0.
address: IPv4 address to remove.
prefix_length: Prefix lenght of the IPv4 address to remove.
"""
interface = ""
index = 0
address = ""
prefix_length = 32
xpath = ""
def test0100(self):
self.assertArgs(["interface", "address", "prefix_length"])
self.xpath = ("/interfaces/interface[name=%s]/subinterfaces/"
"subinterface[index=%d]/ipv4/addresses"
"/address[ip=%s]") % (
self.interface, self.index, self.address)
if not self.gNMIGet(self.xpath + "/config"):
self.log("IP %s not configured at %s.%s",
self.address, self.interface, self.index)
return
self.assertTrue(self.gNMISetDelete(self.xpath),
"gNMI Delete did not succeed.")
@retry(exceptions=AssertionError, tries=5, delay=15)
def test0200(self):
resp = self.gNMIGet(self.xpath + "/config")
self.assertIsNone(
resp,
"IP %s still configured at %s.%s" % (self.address,
self.interface, self.index))
@retry(exceptions=AssertionError, tries=5, delay=15)
def test0300(self):
resp = self.gNMIGet(self.xpath + "/state")
self.assertIsNone(
resp,
"IP %s still at %s.%s" % (self.address,
self.interface, self.index))
class CheckSubifIpState(testbase.TestCase):
"""Checks the state on an ip address configured on a subinterface.
1. A gNMI Get message on the /state container.
All arguments are read from the Test YAML description.
Args:
interface: Name of the physical interface.
index: Index of the subinterface, defaults to 0.
address: IPv4 address.
prefix_length: Prefix lenght of the IPv4 address.
"""
interface = ""
index = 0
address = ""
prefix_length = 32
@retry(exceptions=AssertionError, tries=5, delay=15)
def test0100(self):
""""""
xpath = ("/interfaces/interface[name=%s]/subinterfaces/"
"subinterface[index=%d]/ipv4/addresses/"
"address[ip=%s]/state") % (
self.interface, self.index, self.address)
resp_val = self.gNMIGetJson(xpath)
iface = oc_interfaces().interfaces.interface.add(self.interface)
subif = iface.subinterfaces.subinterface.add(self.index)
if self.index:
subif.vlan.config.vlan_id = self.index
addr = subif.ipv4.addresses.address.add(self.address)
addr.state._set_ip(self.address)
addr.state._set_prefix_length(self.prefix_length)
self.assertJsonModel(
resp_val, addr.state,
'gNMI Get on the /state container does not match model')
want = json.loads(
schema.removeOpenConfigPrefix(
pybindJSON.dumps(addr.state, mode='ietf')))
self.assertJsonCmp(resp_val, want)
class CheckSubifIpConfig(testbase.TestCase):
"""Checks the config on an ip address on a subinterface.
1. A gNMI Get message on the /config container.
All arguments are read from the Test YAML description.
Args:
interface: Name of the physical interface.
index: Index of the subinterface, defaults to 0.
address: IPv4 address.
prefix_length: Prefix lenght of the IPv4 address.
"""
interface = ""
index = 0
address = ""
prefix_length = 32
@retry(exceptions=AssertionError, tries=5, delay=15)
def test0100(self):
""""""
xpath = ("/interfaces/interface[name=%s]/subinterfaces/"
"subinterface[index=%d]/ipv4/addresses/"
"address[ip=%s]/config") % (
self.interface, self.index, self.address)
resp_val = self.gNMIGetJson(xpath)
iface = oc_interfaces().interfaces.interface.add(self.interface)
subif = iface.subinterfaces.subinterface.add(self.index)
if self.index:
subif.vlan.config.vlan_id = self.index
addr = subif.ipv4.addresses.address.add(self.address)
addr.config.ip = self.address
addr.config.prefix_length = self.prefix_length
self.assertJsonModel(
resp_val, addr.config,
'gNMI Get on the /config container does not match model')
want = json.loads(
schema.removeOpenConfigPrefix(
pybindJSON.dumps(addr.config, mode='ietf')))
self.assertJsonCmp(resp_val, want)
| 37.723032 | 77 | 0.619213 | 1,523 | 12,939 | 5.194353 | 0.093894 | 0.031854 | 0.019467 | 0.033371 | 0.908229 | 0.891038 | 0.851725 | 0.828972 | 0.823537 | 0.776008 | 0 | 0.014753 | 0.277069 | 12,939 | 342 | 78 | 37.833333 | 0.830981 | 0.209985 | 0 | 0.746544 | 0 | 0 | 0.181287 | 0.090542 | 0 | 0 | 0 | 0 | 0.175115 | 1 | 0.064516 | false | 0 | 0.023041 | 0 | 0.248848 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 1 | 1 | 1 | 1 | 1 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 7 |
af7d53a2104574027f3448e3406a3868464a17f6 | 113 | py | Python | invest_viewshed.py | phargogh/invest-natcap.invest-3 | ee96055a4fa034d9a95fa8ccc6259ab03264e6c1 | [
"BSD-3-Clause"
] | null | null | null | invest_viewshed.py | phargogh/invest-natcap.invest-3 | ee96055a4fa034d9a95fa8ccc6259ab03264e6c1 | [
"BSD-3-Clause"
] | null | null | null | invest_viewshed.py | phargogh/invest-natcap.invest-3 | ee96055a4fa034d9a95fa8ccc6259ab03264e6c1 | [
"BSD-3-Clause"
] | null | null | null | import invest_natcap.iui.modelui
if __name__ == '__main__':
invest_natcap.iui.modelui.main('viewshed.json')
| 22.6 | 51 | 0.761062 | 15 | 113 | 5.066667 | 0.666667 | 0.315789 | 0.394737 | 0.578947 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0.106195 | 113 | 4 | 52 | 28.25 | 0.752475 | 0 | 0 | 0 | 0 | 0 | 0.185841 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | true | 0 | 0.333333 | 0 | 0.333333 | 0 | 1 | 0 | 0 | null | 1 | 1 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 1 | 0 | 0 | 0 | 0 | 7 |
bb9f436bad540646716f5b02ad02fcbebb59f553 | 203 | py | Python | columnchecker/__init__.py | Zamot40/Columnchecker | 055a1e960f5fed31dd80fb9e99a73b89483f66a8 | [
"MIT"
] | null | null | null | columnchecker/__init__.py | Zamot40/Columnchecker | 055a1e960f5fed31dd80fb9e99a73b89483f66a8 | [
"MIT"
] | null | null | null | columnchecker/__init__.py | Zamot40/Columnchecker | 055a1e960f5fed31dd80fb9e99a73b89483f66a8 | [
"MIT"
] | null | null | null | # -*- coding: utf-8 -*-
"""
Created on Sun May 30 16:40:51 2021
@author: CoolT
"""
from columnchecker import columnchecker
#from columnchecker import datecheck
#from columnchecker import oddrows | 22.555556 | 40 | 0.719212 | 26 | 203 | 5.615385 | 0.730769 | 0.349315 | 0.472603 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0.077844 | 0.17734 | 203 | 9 | 41 | 22.555556 | 0.796407 | 0.699507 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | true | 0 | 1 | 0 | 1 | 0 | 1 | 0 | 0 | null | 1 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 1 | 0 | 1 | 0 | 0 | 7 |
bbd532e9baaded733e029afcbe386f7c82eeabb6 | 7,162 | py | Python | ape/FourierBasis.py | yenchunlin024/APE | bc9c08af01291b6f5821efffe85452554be22694 | [
"MIT"
] | 3 | 2020-04-13T02:26:34.000Z | 2022-01-04T12:02:08.000Z | ape/FourierBasis.py | yenchunlin024/APE | bc9c08af01291b6f5821efffe85452554be22694 | [
"MIT"
] | 1 | 2021-08-06T11:05:51.000Z | 2021-08-06T11:05:51.000Z | ape/FourierBasis.py | yenchunlin024/APE | bc9c08af01291b6f5821efffe85452554be22694 | [
"MIT"
] | 1 | 2021-08-03T08:28:25.000Z | 2021-08-03T08:28:25.000Z | # -*- coding: utf-8 -*-
import numpy as np
from math import sqrt
from math import pi, sin, cos
def IndefIntxPhimPhin(m,n,x,L,x_power):
if m == 0 or n == 0:
if m == n: #const*const
y = pow(x,x_power+1)/(x_power+1)
y /= (2*L)
else:
if n == 0:
n = m
m = 0
if n%2 == 1: #const*cos
n = (n+1)/2
k = n*pi/L
if x_power == 0:
y = sin(k*x)/k
elif x_power == 1:
y = (k*x*sin(k*x)+cos(k*x))/pow(k,2)
elif x_power == 2:
y = ((pow(k,2)*pow(x,2)-2)*sin(k*x)+2*k*x*cos(k*x))/pow(k,3)
elif x_power == 3:
y = (k*x*(pow(k,2)*pow(x,2)-6)*sin(k*x)+3*(pow(k,2)*pow(x,2)-2)*cos(k*x))/pow(k,4)
y /= L*sqrt(2)
else: #const*sin
n = n/2
k = n*pi/L
if x_power == 0:
y = -cos(k*x)/k
elif x_power == 1:
y = (-k*x*cos(k*x)+sin(k*x))/pow(k,2)
elif x_power == 2:
y = ((2-pow(k,2)*pow(x,2))*cos(k*x)+2*k*x*sin(k*x))/pow(k,3)
elif x_power == 3:
y = (-k*x*(pow(k,2)*pow(x,2)-6)*cos(k*x)+3*(pow(k,2)*pow(x,2)-2)*sin(k*x))/pow(k,4)
y /= L*sqrt(2)
elif m%2 == 1 and n%2 == 1: #cos*cos
m = (m+1)/2
n = (n+1)/2
k1 = m*pi/L
k2 = n*pi/L
if m == n:
if x_power == 0:
y = (2*k1*x+sin(2*k1*x))/(4*k1)
elif x_power == 1:
y = (2*k1*x*(k1*x+sin(2*k1*x))+cos(2*k1*x))/(8*pow(k1,2))
elif x_power == 2:
y = (4*pow(k1,3)*pow(x,3)+(6*pow(k1,2)*pow(x,2)-3)*sin(2*k1*x)+6*k1*x*cos(2*k1*x))/(24*pow(k1,3))
elif x_power == 3:
y = (2*pow(k1,4)*pow(x,4)+2*k1*x*(2*pow(k1,2)*pow(x,2)-3)*sin(2*k1*x)+(6*pow(k1,2)*pow(x,2)-3)*cos(2*k1*x))/(16*pow(k1,4))
else:
if x_power == 0:
y = (k1*sin(k1*x)*cos(k2*x)-k2*cos(k1*x)*sin(k2*x))/(pow(k1,2)-pow(k2,2))
elif x_power == 1:
y = 0.5*(x*sin(x*(k1-k2))/(k1-k2)+x*sin(x*(k1+k2))/(k1+k2)\
+cos(x*(k1-k2))/pow(k1-k2,2)+cos(x*(k1+k2))/pow(k1+k2,2))
elif x_power == 2:
y = 0.5*((pow(k1,2)*pow(x,2)-2*k1*k2*pow(x,2)+pow(k2,2)*pow(x,2)-2)*sin(x*(k1-k2))/pow(k1-k2,3)\
+ (pow(k1,2)*pow(x,2)+2*k1*k2*pow(x,2)+pow(k2,2)*pow(x,2)-2)*sin(x*(k1+k2))/pow(k1+k2,3)\
+ 2*x*cos(x*(k1-k2))/pow(k1-k2,2) + 2*x*cos(x*(k1+k2))/pow(k1+k2,2))
elif x_power == 3:
y = 0.5*(x*(pow(k1,2)*pow(x,2)-2*k1*k2*pow(x,2)+pow(k2,2)*pow(x,2)-6)*sin(x*(k1-k2))/pow(k1-k2,3)\
+ x*(pow(k1,2)*pow(x,2)+2*k1*k2*pow(x,2)+pow(k2,2)*pow(x,2)-6)*sin(x*(k1+k2))/pow(k1+k2,3)\
+ 3*(pow(k1,2)*pow(x,2)-2*k1*k2*pow(x,2)+pow(k2,2)*pow(x,2)-2)*cos(x*(k1-k2))/pow(k1-k2,4)\
+ 3*(pow(k1,2)*pow(x,2)+2*k1*k2*pow(x,2)+pow(k2,2)*pow(x,2)-2)*cos(x*(k1+k2))/pow(k1+k2,4))
y /= L
elif m%2 == 0 and n%2 == 0: #sin*sin
m = m/2
n = n/2
k1 = m*pi/L
k2 = n*pi/L
if m == n:
if x_power == 0:
y = (2*k1*x-sin(2*k1*x))/(4*k1)
elif x_power == 1:
y = -(2*k1*x*(-k1*x+sin(2*k1*x))+cos(2*k1*x))/(8*pow(k1,2))
elif x_power == 2:
y = (4*pow(k1,3)*pow(x,3)+(-6*pow(k1,2)*pow(x,2)+3)*sin(2*k1*x)-6*k1*x*cos(2*k1*x))/(24*pow(k1,3));
elif x_power == 3:
y = (2*pow(k1,4)*pow(x,4)+2*k1*x*(-2*pow(k1,2)*pow(x,2)+3)*sin(2*k1*x)+(-6*pow(k1,2)*pow(x,2)+3)*cos(2*k1*x))/(16*pow(k1,4))
else:
if x_power == 0:
y = (k2*sin(k1*x)*cos(k2*x)-k1*cos(k1*x)*sin(k2*x))/(pow(k1,2)-pow(k2,2))
elif x_power == 1:
y = 0.5*(x*sin(x*(k1-k2))/(k1-k2)-x*sin(x*(k1+k2))/(k1+k2)\
+cos(x*(k1-k2))/pow(k1-k2,2)-cos(x*(k1+k2))/pow(k1+k2,2))
elif x_power == 2:
y = 0.5*((pow(k1,2)*pow(x,2)-2*k1*k2*pow(x,2)+pow(k2,2)*pow(x,2)-2)*sin(x*(k1-k2))/pow(k1-k2,3)\
- (pow(k1,2)*pow(x,2)+2*k1*k2*pow(x,2)+pow(k2,2)*pow(x,2)-2)*sin(x*(k1+k2))/pow(k1+k2,3)\
+ 2*x*cos(x*(k1-k2))/pow(k1-k2,2) - 2*x*cos(x*(k1+k2))/pow(k1+k2,2))
elif x_power == 3:
y = 0.5*(x*(pow(k1,2)*pow(x,2)-2*k1*k2*pow(x,2)+pow(k2,2)*pow(x,2)-6)*sin(x*(k1-k2))/pow(k1-k2,3)\
- x*(pow(k1,2)*pow(x,2)+2*k1*k2*pow(x,2)+pow(k2,2)*pow(x,2)-6)*sin(x*(k1+k2))/pow(k1+k2,3)\
+ 3*(pow(k1,2)*pow(x,2)-2*k1*k2*pow(x,2)+pow(k2,2)*pow(x,2)-2)*cos(x*(k1-k2))/pow(k1-k2,4)\
- 3*(pow(k1,2)*pow(x,2)+2*k1*k2*pow(x,2)+pow(k2,2)*pow(x,2)-2)*cos(x*(k1+k2))/pow(k1+k2,4))
y /= L
else: #cos*sin
if m%2 == 0:
temp = m
m = n
n = temp
m = (m+1)/2
n = n/2
k1 = m*pi/L
k2 = n*pi/L
if m == n:
if x_power == 0:
y = -pow(cos(k1*x),2)/(2*k1)
elif x_power == 1:
y = (sin(2*k1*x)-2*k1*x*cos(2*k1*x))/(8*pow(k1,2))
elif x_power == 2:
y = ((1-2*pow(k1,2)*pow(x,2))*cos(2*k1*x)+2*k1*x*sin(2*k1*x))/(8*pow(k1,3))
elif x_power == 3:
y = ((6*k1*x-4*pow(k1,3)*pow(x,3))*cos(2*k1*x)+3*(2*pow(k1,2)*pow(x,2)-1)*sin(2*k1*x))/(16*pow(k1,4))
else:
if x_power == 0:
y = (k1*sin(k1*x)*sin(k2*x)+k2*cos(k1*x)*cos(k2*x))/(pow(k1,2)-pow(k2,2))
elif x_power == 1:
y = 0.5*(x*cos(x*(k1-k2))/(k1-k2)-x*cos(x*(k1+k2))/(k1+k2)\
-sin(x*(k1-k2))/pow(k1-k2,2)+sin(x*(k1+k2))/pow(k1+k2,2))
elif x_power == 2:
y = 0.5*((pow(k1,2)*pow(x,2)-2*k1*k2*pow(x,2)+pow(k2,2)*pow(x,2)-2)*cos(x*(k1-k2))/pow(k1-k2,3)\
- (pow(k1,2)*pow(x,2)+2*k1*k2*pow(x,2)+pow(k2,2)*pow(x,2)-2)*cos(x*(k1+k2))/pow(k1+k2,3)\
- 2*x*sin(x*(k1-k2))/pow(k1-k2,2) + 2*x*sin(x*(k1+k2))/pow(k1+k2,2))
elif x_power == 3:
y = 0.5*(x*(pow(k1,2)*pow(x,2)-2*k1*k2*pow(x,2)+pow(k2,2)*pow(x,2)-6)*cos(x*(k1-k2))/pow(k1-k2,3)\
- x*(pow(k1,2)*pow(x,2)+2*k1*k2*pow(x,2)+pow(k2,2)*pow(x,2)-6)*cos(x*(k1+k2))/pow(k1+k2,3)\
- 3*(pow(k1,2)*pow(x,2)-2*k1*k2*pow(x,2)+pow(k2,2)*pow(x,2)-2)*sin(x*(k1-k2))/pow(k1-k2,4)\
+ 3*(pow(k1,2)*pow(x,2)+2*k1*k2*pow(x,2)+pow(k2,2)*pow(x,2)-2)*sin(x*(k1+k2))/pow(k1+k2,4))
y /= L
return y
def IntxPhimPhin(m,n,x1,x2,L,x_power):
return (IndefIntxPhimPhin(m,n,x2,L,x_power) - IndefIntxPhimPhin(m,n,x1,L,x_power))
def IntXPhimPhin(m,n,x1,x2,L,a):
y = 0
if (a[0]!=0): y += a[0]*IntxPhimPhin(m,n,x1,x2,L,0)
if (a[1]!=0): y += a[1]*IntxPhimPhin(m,n,x1,x2,L,1)
if (a[2]!=0): y += a[2]*IntxPhimPhin(m,n,x1,x2,L,2)
if (a[3]!=0): y += a[3]*IntxPhimPhin(m,n,x1,x2,L,3)
return y
# Fourier series | 48.721088 | 140 | 0.413153 | 1,550 | 7,162 | 1.884516 | 0.030968 | 0.123245 | 0.116398 | 0.102705 | 0.859979 | 0.84697 | 0.792879 | 0.74632 | 0.73468 | 0.725094 | 0 | 0.14642 | 0.305781 | 7,162 | 147 | 141 | 48.721088 | 0.44107 | 0.012008 | 0 | 0.5 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0.021429 | false | 0 | 0.021429 | 0.007143 | 0.064286 | 0 | 0 | 0 | 1 | null | 0 | 0 | 0 | 1 | 1 | 1 | 1 | 1 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 8 |
a5249880ee6a81ead2187519da71459454155f33 | 186 | py | Python | invoke/parser/__init__.py | daobook/invoke | 577faf1c016a69392583046613bfb42356855e8f | [
"BSD-2-Clause"
] | null | null | null | invoke/parser/__init__.py | daobook/invoke | 577faf1c016a69392583046613bfb42356855e8f | [
"BSD-2-Clause"
] | null | null | null | invoke/parser/__init__.py | daobook/invoke | 577faf1c016a69392583046613bfb42356855e8f | [
"BSD-2-Clause"
] | null | null | null | # flake8: noqa
from .parser import *
from .context import ParserContext
from .context import ParserContext as Context, to_flag, translate_underscores
from .argument import Argument
| 31 | 78 | 0.801075 | 23 | 186 | 6.391304 | 0.565217 | 0.14966 | 0.231293 | 0.408163 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0.006329 | 0.150538 | 186 | 5 | 79 | 37.2 | 0.924051 | 0.064516 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | true | 0 | 1 | 0 | 1 | 0 | 1 | 0 | 0 | null | 0 | 1 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 1 | 0 | 1 | 0 | 0 | 7 |
a525a8868f2120c7fcbb6b3f91498622601e6441 | 192 | py | Python | torchero/utils/data/__init__.py | juancruzsosa/torchero | d1440b7a9c3ab2c1d3abbb282abb9ee1ea240797 | [
"MIT"
] | 10 | 2020-07-06T13:35:26.000Z | 2021-08-10T09:46:53.000Z | torchero/utils/data/__init__.py | juancruzsosa/torchero | d1440b7a9c3ab2c1d3abbb282abb9ee1ea240797 | [
"MIT"
] | 6 | 2020-07-07T20:52:16.000Z | 2020-07-14T04:05:02.000Z | torchero/utils/data/__init__.py | juancruzsosa/torchero | d1440b7a9c3ab2c1d3abbb282abb9ee1ea240797 | [
"MIT"
] | 1 | 2021-06-28T17:56:11.000Z | 2021-06-28T17:56:11.000Z | from torchero.utils.data.cross_fold_validation import (CrossFoldValidation,
train_test_split)
from torchero.utils.data.datasets import *
| 48 | 75 | 0.614583 | 18 | 192 | 6.333333 | 0.722222 | 0.210526 | 0.298246 | 0.368421 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0.333333 | 192 | 3 | 76 | 64 | 0.890625 | 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 | 1 | 1 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 1 | 0 | 1 | 0 | 0 | 8 |
a5978c2f5205bb6223cbf1b5b5945763619c6470 | 234 | py | Python | bot/interface.py | boweihan/NLPPlayground | 17ad1bc989a6d98fcc11cede0ab728abd5d7df42 | [
"MIT"
] | null | null | null | bot/interface.py | boweihan/NLPPlayground | 17ad1bc989a6d98fcc11cede0ab728abd5d7df42 | [
"MIT"
] | 16 | 2021-01-06T08:10:37.000Z | 2022-03-27T06:27:48.000Z | bot/interface.py | boweihan/NLPPlayground | 17ad1bc989a6d98fcc11cede0ab728abd5d7df42 | [
"MIT"
] | null | null | null | from abc import ABC, abstractmethod
class TokenOperationInterface(ABC):
@abstractmethod
def process(self, tokens):
pass
class TextOperationInterface(ABC):
@abstractmethod
def process(self, text):
pass | 21.272727 | 35 | 0.705128 | 23 | 234 | 7.173913 | 0.565217 | 0.309091 | 0.242424 | 0.327273 | 0.375758 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0.222222 | 234 | 11 | 36 | 21.272727 | 0.906593 | 0 | 0 | 0.444444 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0.222222 | false | 0.222222 | 0.111111 | 0 | 0.555556 | 0 | 1 | 0 | 0 | null | 1 | 1 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 1 | 0 | 0 | 1 | 0 | 0 | 7 |
3c1ce04cc4a969cadfcc6147d4ac527bed02d6e1 | 139 | py | Python | djikiwww/ga_processor.py | emesik/djiki-website | b6c5e8e4010a98dda25398684907d432a81ff0cb | [
"Apache-2.0"
] | null | null | null | djikiwww/ga_processor.py | emesik/djiki-website | b6c5e8e4010a98dda25398684907d432a81ff0cb | [
"Apache-2.0"
] | null | null | null | djikiwww/ga_processor.py | emesik/djiki-website | b6c5e8e4010a98dda25398684907d432a81ff0cb | [
"Apache-2.0"
] | null | null | null | from django.conf import settings
def google_analytics(ctx):
return {'GOOGLE_ANALYTICS_ID': getattr(settings, 'GOOGLE_ANALYTICS_ID', '')}
| 27.8 | 77 | 0.784173 | 18 | 139 | 5.777778 | 0.666667 | 0.432692 | 0.326923 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0.093525 | 139 | 4 | 78 | 34.75 | 0.825397 | 0 | 0 | 0 | 0 | 0 | 0.273381 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0.333333 | false | 0 | 0.333333 | 0.333333 | 1 | 0 | 1 | 0 | 0 | null | 1 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 1 | 1 | 1 | 0 | 0 | 8 |
3c2193a9fff2f60dcb85bcc90e3281f05327e6f9 | 83,894 | py | Python | ultracart/api/checkout_api.py | UltraCart/rest_api_v2_sdk_python | d734ea13fabc7a57872ff68bac06861edb8fd882 | [
"Apache-2.0"
] | 1 | 2018-03-15T16:56:23.000Z | 2018-03-15T16:56:23.000Z | ultracart/api/checkout_api.py | UltraCart/rest_api_v2_sdk_python | d734ea13fabc7a57872ff68bac06861edb8fd882 | [
"Apache-2.0"
] | null | null | null | ultracart/api/checkout_api.py | UltraCart/rest_api_v2_sdk_python | d734ea13fabc7a57872ff68bac06861edb8fd882 | [
"Apache-2.0"
] | null | null | null | # coding: utf-8
"""
UltraCart Rest API V2
UltraCart REST API Version 2 # noqa: E501
OpenAPI spec version: 2.0.0
Contact: support@ultracart.com
Generated by: https://github.com/swagger-api/swagger-codegen.git
"""
from __future__ import absolute_import
import re # noqa: F401
# python 2 and python 3 compatibility library
import six
from ultracart.api_client import ApiClient
from ultracart.configuration import Configuration
class CheckoutApi(object):
"""NOTE: This class is auto generated by the swagger code generator program.
Do not edit the class manually.
Ref: https://github.com/swagger-api/swagger-codegen
"""
def __init__(self, api_client=None):
if api_client is None:
api_client = ApiClient()
self.api_client = api_client
@classmethod
def fromApiKey(cls, apiKey, verify_ssl = True, debug = False):
config = Configuration()
config.api_key['x-ultracart-simple-key'] = apiKey
config.debug = debug
config.verify_ssl = verify_ssl
api_client = ApiClient(configuration=config, header_name='X-UltraCart-Api-Version', header_value='2017-03-01')
return CheckoutApi(api_client)
def city_state(self, cart, **kwargs): # noqa: E501
"""City/State for Zip # noqa: E501
Look up the city and state for the shipping zip code. Useful for building an auto complete for parts of the shipping address # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
>>> thread = api.city_state(cart, async_req=True)
>>> result = thread.get()
:param async_req bool
:param Cart cart: Cart (required)
:return: CityStateZip
If the method is called asynchronously,
returns the request thread.
"""
kwargs['_return_http_data_only'] = True
if kwargs.get('async_req'):
return self.city_state_with_http_info(cart, **kwargs) # noqa: E501
else:
(data) = self.city_state_with_http_info(cart, **kwargs) # noqa: E501
return data
def city_state_with_http_info(self, cart, **kwargs): # noqa: E501
"""City/State for Zip # noqa: E501
Look up the city and state for the shipping zip code. Useful for building an auto complete for parts of the shipping address # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
>>> thread = api.city_state_with_http_info(cart, async_req=True)
>>> result = thread.get()
:param async_req bool
:param Cart cart: Cart (required)
:return: CityStateZip
If the method is called asynchronously,
returns the request thread.
"""
all_params = ['cart'] # noqa: E501
all_params.append('async_req')
all_params.append('_return_http_data_only')
all_params.append('_preload_content')
all_params.append('_request_timeout')
params = locals()
for key, val in six.iteritems(params['kwargs']):
if key not in all_params:
raise TypeError(
"Got an unexpected keyword argument '%s'"
" to method city_state" % key
)
params[key] = val
del params['kwargs']
# verify the required parameter 'cart' is set
if ('cart' not in params or
params['cart'] is None):
raise ValueError("Missing the required parameter `cart` when calling `city_state`") # noqa: E501
collection_formats = {}
path_params = {}
query_params = []
header_params = {}
form_params = []
local_var_files = {}
body_params = None
if 'cart' in params:
body_params = params['cart']
# HTTP header `Accept`
header_params['Accept'] = self.api_client.select_header_accept(
['application/json']) # noqa: E501
# HTTP header `Content-Type`
header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501
['application/json']) # noqa: E501
# Authentication setting
auth_settings = ['ultraCartBrowserApiKey', 'ultraCartOauth', 'ultraCartSimpleApiKey'] # noqa: E501
return self.api_client.call_api(
'/checkout/city_state', 'POST',
path_params,
query_params,
header_params,
body=body_params,
post_params=form_params,
files=local_var_files,
response_type='CityStateZip', # noqa: E501
auth_settings=auth_settings,
async_req=params.get('async_req'),
_return_http_data_only=params.get('_return_http_data_only'),
_preload_content=params.get('_preload_content', True),
_request_timeout=params.get('_request_timeout'),
collection_formats=collection_formats)
def finalize_order(self, finalize_request, **kwargs): # noqa: E501
"""Finalize Order # noqa: E501
Finalize the cart into an order. This method can not be called with browser key authentication. It is ONLY meant for server side code to call. # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
>>> thread = api.finalize_order(finalize_request, async_req=True)
>>> result = thread.get()
:param async_req bool
:param CartFinalizeOrderRequest finalize_request: Finalize request (required)
:return: CartFinalizeOrderResponse
If the method is called asynchronously,
returns the request thread.
"""
kwargs['_return_http_data_only'] = True
if kwargs.get('async_req'):
return self.finalize_order_with_http_info(finalize_request, **kwargs) # noqa: E501
else:
(data) = self.finalize_order_with_http_info(finalize_request, **kwargs) # noqa: E501
return data
def finalize_order_with_http_info(self, finalize_request, **kwargs): # noqa: E501
"""Finalize Order # noqa: E501
Finalize the cart into an order. This method can not be called with browser key authentication. It is ONLY meant for server side code to call. # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
>>> thread = api.finalize_order_with_http_info(finalize_request, async_req=True)
>>> result = thread.get()
:param async_req bool
:param CartFinalizeOrderRequest finalize_request: Finalize request (required)
:return: CartFinalizeOrderResponse
If the method is called asynchronously,
returns the request thread.
"""
all_params = ['finalize_request'] # noqa: E501
all_params.append('async_req')
all_params.append('_return_http_data_only')
all_params.append('_preload_content')
all_params.append('_request_timeout')
params = locals()
for key, val in six.iteritems(params['kwargs']):
if key not in all_params:
raise TypeError(
"Got an unexpected keyword argument '%s'"
" to method finalize_order" % key
)
params[key] = val
del params['kwargs']
# verify the required parameter 'finalize_request' is set
if ('finalize_request' not in params or
params['finalize_request'] is None):
raise ValueError("Missing the required parameter `finalize_request` when calling `finalize_order`") # noqa: E501
collection_formats = {}
path_params = {}
query_params = []
header_params = {}
form_params = []
local_var_files = {}
body_params = None
if 'finalize_request' in params:
body_params = params['finalize_request']
# HTTP header `Accept`
header_params['Accept'] = self.api_client.select_header_accept(
['application/json']) # noqa: E501
# HTTP header `Content-Type`
header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501
['application/json']) # noqa: E501
# Authentication setting
auth_settings = ['ultraCartOauth', 'ultraCartSimpleApiKey'] # noqa: E501
return self.api_client.call_api(
'/checkout/cart/finalizeOrder', 'POST',
path_params,
query_params,
header_params,
body=body_params,
post_params=form_params,
files=local_var_files,
response_type='CartFinalizeOrderResponse', # noqa: E501
auth_settings=auth_settings,
async_req=params.get('async_req'),
_return_http_data_only=params.get('_return_http_data_only'),
_preload_content=params.get('_preload_content', True),
_request_timeout=params.get('_request_timeout'),
collection_formats=collection_formats)
def get_affirm_checkout(self, cart_id, **kwargs): # noqa: E501
"""Get affirm checkout (by cart id) # noqa: E501
Get a Affirm checkout object for the specified cart_id parameter. # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
>>> thread = api.get_affirm_checkout(cart_id, async_req=True)
>>> result = thread.get()
:param async_req bool
:param str cart_id: Cart ID to retrieve (required)
:return: CartAffirmCheckoutResponse
If the method is called asynchronously,
returns the request thread.
"""
kwargs['_return_http_data_only'] = True
if kwargs.get('async_req'):
return self.get_affirm_checkout_with_http_info(cart_id, **kwargs) # noqa: E501
else:
(data) = self.get_affirm_checkout_with_http_info(cart_id, **kwargs) # noqa: E501
return data
def get_affirm_checkout_with_http_info(self, cart_id, **kwargs): # noqa: E501
"""Get affirm checkout (by cart id) # noqa: E501
Get a Affirm checkout object for the specified cart_id parameter. # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
>>> thread = api.get_affirm_checkout_with_http_info(cart_id, async_req=True)
>>> result = thread.get()
:param async_req bool
:param str cart_id: Cart ID to retrieve (required)
:return: CartAffirmCheckoutResponse
If the method is called asynchronously,
returns the request thread.
"""
all_params = ['cart_id'] # noqa: E501
all_params.append('async_req')
all_params.append('_return_http_data_only')
all_params.append('_preload_content')
all_params.append('_request_timeout')
params = locals()
for key, val in six.iteritems(params['kwargs']):
if key not in all_params:
raise TypeError(
"Got an unexpected keyword argument '%s'"
" to method get_affirm_checkout" % key
)
params[key] = val
del params['kwargs']
# verify the required parameter 'cart_id' is set
if ('cart_id' not in params or
params['cart_id'] is None):
raise ValueError("Missing the required parameter `cart_id` when calling `get_affirm_checkout`") # noqa: E501
collection_formats = {}
path_params = {}
if 'cart_id' in params:
path_params['cart_id'] = params['cart_id'] # noqa: E501
query_params = []
header_params = {}
form_params = []
local_var_files = {}
body_params = None
# HTTP header `Accept`
header_params['Accept'] = self.api_client.select_header_accept(
['application/json']) # noqa: E501
# HTTP header `Content-Type`
header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501
['application/json']) # noqa: E501
# Authentication setting
auth_settings = ['ultraCartBrowserApiKey', 'ultraCartOauth', 'ultraCartSimpleApiKey'] # noqa: E501
return self.api_client.call_api(
'/checkout/cart/{cart_id}/affirmCheckout', 'GET',
path_params,
query_params,
header_params,
body=body_params,
post_params=form_params,
files=local_var_files,
response_type='CartAffirmCheckoutResponse', # noqa: E501
auth_settings=auth_settings,
async_req=params.get('async_req'),
_return_http_data_only=params.get('_return_http_data_only'),
_preload_content=params.get('_preload_content', True),
_request_timeout=params.get('_request_timeout'),
collection_formats=collection_formats)
def get_allowed_countries(self, **kwargs): # noqa: E501
"""Allowed countries # noqa: E501
Lookup the allowed countries for this merchant id # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
>>> thread = api.get_allowed_countries(async_req=True)
>>> result = thread.get()
:param async_req bool
:return: CheckoutAllowedCountriesResponse
If the method is called asynchronously,
returns the request thread.
"""
kwargs['_return_http_data_only'] = True
if kwargs.get('async_req'):
return self.get_allowed_countries_with_http_info(**kwargs) # noqa: E501
else:
(data) = self.get_allowed_countries_with_http_info(**kwargs) # noqa: E501
return data
def get_allowed_countries_with_http_info(self, **kwargs): # noqa: E501
"""Allowed countries # noqa: E501
Lookup the allowed countries for this merchant id # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
>>> thread = api.get_allowed_countries_with_http_info(async_req=True)
>>> result = thread.get()
:param async_req bool
:return: CheckoutAllowedCountriesResponse
If the method is called asynchronously,
returns the request thread.
"""
all_params = [] # noqa: E501
all_params.append('async_req')
all_params.append('_return_http_data_only')
all_params.append('_preload_content')
all_params.append('_request_timeout')
params = locals()
for key, val in six.iteritems(params['kwargs']):
if key not in all_params:
raise TypeError(
"Got an unexpected keyword argument '%s'"
" to method get_allowed_countries" % key
)
params[key] = val
del params['kwargs']
collection_formats = {}
path_params = {}
query_params = []
header_params = {}
form_params = []
local_var_files = {}
body_params = None
# HTTP header `Accept`
header_params['Accept'] = self.api_client.select_header_accept(
['application/json']) # noqa: E501
# HTTP header `Content-Type`
header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501
['application/json']) # noqa: E501
# Authentication setting
auth_settings = ['ultraCartBrowserApiKey', 'ultraCartOauth', 'ultraCartSimpleApiKey'] # noqa: E501
return self.api_client.call_api(
'/checkout/allowedCountries', 'POST',
path_params,
query_params,
header_params,
body=body_params,
post_params=form_params,
files=local_var_files,
response_type='CheckoutAllowedCountriesResponse', # noqa: E501
auth_settings=auth_settings,
async_req=params.get('async_req'),
_return_http_data_only=params.get('_return_http_data_only'),
_preload_content=params.get('_preload_content', True),
_request_timeout=params.get('_request_timeout'),
collection_formats=collection_formats)
def get_cart(self, **kwargs): # noqa: E501
"""Get cart # noqa: E501
If the cookie is set on the browser making the request then it will return their active cart. Otherwise it will create a new cart. # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
>>> thread = api.get_cart(async_req=True)
>>> result = thread.get()
:param async_req bool
:param str expand: The object expansion to perform on the result. See documentation for examples
:return: CartResponse
If the method is called asynchronously,
returns the request thread.
"""
kwargs['_return_http_data_only'] = True
if kwargs.get('async_req'):
return self.get_cart_with_http_info(**kwargs) # noqa: E501
else:
(data) = self.get_cart_with_http_info(**kwargs) # noqa: E501
return data
def get_cart_with_http_info(self, **kwargs): # noqa: E501
"""Get cart # noqa: E501
If the cookie is set on the browser making the request then it will return their active cart. Otherwise it will create a new cart. # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
>>> thread = api.get_cart_with_http_info(async_req=True)
>>> result = thread.get()
:param async_req bool
:param str expand: The object expansion to perform on the result. See documentation for examples
:return: CartResponse
If the method is called asynchronously,
returns the request thread.
"""
all_params = ['expand'] # noqa: E501
all_params.append('async_req')
all_params.append('_return_http_data_only')
all_params.append('_preload_content')
all_params.append('_request_timeout')
params = locals()
for key, val in six.iteritems(params['kwargs']):
if key not in all_params:
raise TypeError(
"Got an unexpected keyword argument '%s'"
" to method get_cart" % key
)
params[key] = val
del params['kwargs']
collection_formats = {}
path_params = {}
query_params = []
if 'expand' in params:
query_params.append(('_expand', params['expand'])) # noqa: E501
header_params = {}
form_params = []
local_var_files = {}
body_params = None
# HTTP header `Accept`
header_params['Accept'] = self.api_client.select_header_accept(
['application/json']) # noqa: E501
# HTTP header `Content-Type`
header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501
['application/json']) # noqa: E501
# Authentication setting
auth_settings = ['ultraCartBrowserApiKey', 'ultraCartOauth', 'ultraCartSimpleApiKey'] # noqa: E501
return self.api_client.call_api(
'/checkout/cart', 'GET',
path_params,
query_params,
header_params,
body=body_params,
post_params=form_params,
files=local_var_files,
response_type='CartResponse', # noqa: E501
auth_settings=auth_settings,
async_req=params.get('async_req'),
_return_http_data_only=params.get('_return_http_data_only'),
_preload_content=params.get('_preload_content', True),
_request_timeout=params.get('_request_timeout'),
collection_formats=collection_formats)
def get_cart_by_cart_id(self, cart_id, **kwargs): # noqa: E501
"""Get cart (by cart id) # noqa: E501
Get a cart specified by the cart_id parameter. # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
>>> thread = api.get_cart_by_cart_id(cart_id, async_req=True)
>>> result = thread.get()
:param async_req bool
:param str cart_id: Cart ID to retrieve (required)
:param str expand: The object expansion to perform on the result. See documentation for examples
:return: CartResponse
If the method is called asynchronously,
returns the request thread.
"""
kwargs['_return_http_data_only'] = True
if kwargs.get('async_req'):
return self.get_cart_by_cart_id_with_http_info(cart_id, **kwargs) # noqa: E501
else:
(data) = self.get_cart_by_cart_id_with_http_info(cart_id, **kwargs) # noqa: E501
return data
def get_cart_by_cart_id_with_http_info(self, cart_id, **kwargs): # noqa: E501
"""Get cart (by cart id) # noqa: E501
Get a cart specified by the cart_id parameter. # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
>>> thread = api.get_cart_by_cart_id_with_http_info(cart_id, async_req=True)
>>> result = thread.get()
:param async_req bool
:param str cart_id: Cart ID to retrieve (required)
:param str expand: The object expansion to perform on the result. See documentation for examples
:return: CartResponse
If the method is called asynchronously,
returns the request thread.
"""
all_params = ['cart_id', 'expand'] # noqa: E501
all_params.append('async_req')
all_params.append('_return_http_data_only')
all_params.append('_preload_content')
all_params.append('_request_timeout')
params = locals()
for key, val in six.iteritems(params['kwargs']):
if key not in all_params:
raise TypeError(
"Got an unexpected keyword argument '%s'"
" to method get_cart_by_cart_id" % key
)
params[key] = val
del params['kwargs']
# verify the required parameter 'cart_id' is set
if ('cart_id' not in params or
params['cart_id'] is None):
raise ValueError("Missing the required parameter `cart_id` when calling `get_cart_by_cart_id`") # noqa: E501
collection_formats = {}
path_params = {}
if 'cart_id' in params:
path_params['cart_id'] = params['cart_id'] # noqa: E501
query_params = []
if 'expand' in params:
query_params.append(('_expand', params['expand'])) # noqa: E501
header_params = {}
form_params = []
local_var_files = {}
body_params = None
# HTTP header `Accept`
header_params['Accept'] = self.api_client.select_header_accept(
['application/json']) # noqa: E501
# HTTP header `Content-Type`
header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501
['application/json']) # noqa: E501
# Authentication setting
auth_settings = ['ultraCartBrowserApiKey', 'ultraCartOauth', 'ultraCartSimpleApiKey'] # noqa: E501
return self.api_client.call_api(
'/checkout/cart/{cart_id}', 'GET',
path_params,
query_params,
header_params,
body=body_params,
post_params=form_params,
files=local_var_files,
response_type='CartResponse', # noqa: E501
auth_settings=auth_settings,
async_req=params.get('async_req'),
_return_http_data_only=params.get('_return_http_data_only'),
_preload_content=params.get('_preload_content', True),
_request_timeout=params.get('_request_timeout'),
collection_formats=collection_formats)
def get_cart_by_return_code(self, return_code, **kwargs): # noqa: E501
"""Get cart (by return code) # noqa: E501
Get a cart specified by the return code parameter. # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
>>> thread = api.get_cart_by_return_code(return_code, async_req=True)
>>> result = thread.get()
:param async_req bool
:param str return_code: Return code to lookup cart ID by (required)
:param str expand: The object expansion to perform on the result. See documentation for examples
:return: CartResponse
If the method is called asynchronously,
returns the request thread.
"""
kwargs['_return_http_data_only'] = True
if kwargs.get('async_req'):
return self.get_cart_by_return_code_with_http_info(return_code, **kwargs) # noqa: E501
else:
(data) = self.get_cart_by_return_code_with_http_info(return_code, **kwargs) # noqa: E501
return data
def get_cart_by_return_code_with_http_info(self, return_code, **kwargs): # noqa: E501
"""Get cart (by return code) # noqa: E501
Get a cart specified by the return code parameter. # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
>>> thread = api.get_cart_by_return_code_with_http_info(return_code, async_req=True)
>>> result = thread.get()
:param async_req bool
:param str return_code: Return code to lookup cart ID by (required)
:param str expand: The object expansion to perform on the result. See documentation for examples
:return: CartResponse
If the method is called asynchronously,
returns the request thread.
"""
all_params = ['return_code', 'expand'] # noqa: E501
all_params.append('async_req')
all_params.append('_return_http_data_only')
all_params.append('_preload_content')
all_params.append('_request_timeout')
params = locals()
for key, val in six.iteritems(params['kwargs']):
if key not in all_params:
raise TypeError(
"Got an unexpected keyword argument '%s'"
" to method get_cart_by_return_code" % key
)
params[key] = val
del params['kwargs']
# verify the required parameter 'return_code' is set
if ('return_code' not in params or
params['return_code'] is None):
raise ValueError("Missing the required parameter `return_code` when calling `get_cart_by_return_code`") # noqa: E501
collection_formats = {}
path_params = {}
if 'return_code' in params:
path_params['return_code'] = params['return_code'] # noqa: E501
query_params = []
if 'expand' in params:
query_params.append(('_expand', params['expand'])) # noqa: E501
header_params = {}
form_params = []
local_var_files = {}
body_params = None
# HTTP header `Accept`
header_params['Accept'] = self.api_client.select_header_accept(
['application/json']) # noqa: E501
# HTTP header `Content-Type`
header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501
['application/json']) # noqa: E501
# Authentication setting
auth_settings = ['ultraCartBrowserApiKey', 'ultraCartOauth', 'ultraCartSimpleApiKey'] # noqa: E501
return self.api_client.call_api(
'/checkout/return/{return_code}', 'GET',
path_params,
query_params,
header_params,
body=body_params,
post_params=form_params,
files=local_var_files,
response_type='CartResponse', # noqa: E501
auth_settings=auth_settings,
async_req=params.get('async_req'),
_return_http_data_only=params.get('_return_http_data_only'),
_preload_content=params.get('_preload_content', True),
_request_timeout=params.get('_request_timeout'),
collection_formats=collection_formats)
def get_cart_by_return_token(self, **kwargs): # noqa: E501
"""Get cart (by return token) # noqa: E501
Get a cart specified by the encrypted return token parameter. # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
>>> thread = api.get_cart_by_return_token(async_req=True)
>>> result = thread.get()
:param async_req bool
:param str return_token: Return token provided by StoreFront Communications
:param str expand: The object expansion to perform on the result. See documentation for examples
:return: CartResponse
If the method is called asynchronously,
returns the request thread.
"""
kwargs['_return_http_data_only'] = True
if kwargs.get('async_req'):
return self.get_cart_by_return_token_with_http_info(**kwargs) # noqa: E501
else:
(data) = self.get_cart_by_return_token_with_http_info(**kwargs) # noqa: E501
return data
def get_cart_by_return_token_with_http_info(self, **kwargs): # noqa: E501
"""Get cart (by return token) # noqa: E501
Get a cart specified by the encrypted return token parameter. # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
>>> thread = api.get_cart_by_return_token_with_http_info(async_req=True)
>>> result = thread.get()
:param async_req bool
:param str return_token: Return token provided by StoreFront Communications
:param str expand: The object expansion to perform on the result. See documentation for examples
:return: CartResponse
If the method is called asynchronously,
returns the request thread.
"""
all_params = ['return_token', 'expand'] # noqa: E501
all_params.append('async_req')
all_params.append('_return_http_data_only')
all_params.append('_preload_content')
all_params.append('_request_timeout')
params = locals()
for key, val in six.iteritems(params['kwargs']):
if key not in all_params:
raise TypeError(
"Got an unexpected keyword argument '%s'"
" to method get_cart_by_return_token" % key
)
params[key] = val
del params['kwargs']
collection_formats = {}
path_params = {}
query_params = []
if 'return_token' in params:
query_params.append(('return_token', params['return_token'])) # noqa: E501
if 'expand' in params:
query_params.append(('_expand', params['expand'])) # noqa: E501
header_params = {}
form_params = []
local_var_files = {}
body_params = None
# HTTP header `Accept`
header_params['Accept'] = self.api_client.select_header_accept(
['application/json']) # noqa: E501
# HTTP header `Content-Type`
header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501
['application/json']) # noqa: E501
# Authentication setting
auth_settings = ['ultraCartBrowserApiKey', 'ultraCartOauth', 'ultraCartSimpleApiKey'] # noqa: E501
return self.api_client.call_api(
'/checkout/return_token', 'GET',
path_params,
query_params,
header_params,
body=body_params,
post_params=form_params,
files=local_var_files,
response_type='CartResponse', # noqa: E501
auth_settings=auth_settings,
async_req=params.get('async_req'),
_return_http_data_only=params.get('_return_http_data_only'),
_preload_content=params.get('_preload_content', True),
_request_timeout=params.get('_request_timeout'),
collection_formats=collection_formats)
def get_state_provinces_for_country(self, country_code, **kwargs): # noqa: E501
"""Get state/province list for a country code # noqa: E501
Lookup a state/province list for a given country code # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
>>> thread = api.get_state_provinces_for_country(country_code, async_req=True)
>>> result = thread.get()
:param async_req bool
:param str country_code: Two letter ISO country code (required)
:return: CheckoutStateProvinceResponse
If the method is called asynchronously,
returns the request thread.
"""
kwargs['_return_http_data_only'] = True
if kwargs.get('async_req'):
return self.get_state_provinces_for_country_with_http_info(country_code, **kwargs) # noqa: E501
else:
(data) = self.get_state_provinces_for_country_with_http_info(country_code, **kwargs) # noqa: E501
return data
def get_state_provinces_for_country_with_http_info(self, country_code, **kwargs): # noqa: E501
"""Get state/province list for a country code # noqa: E501
Lookup a state/province list for a given country code # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
>>> thread = api.get_state_provinces_for_country_with_http_info(country_code, async_req=True)
>>> result = thread.get()
:param async_req bool
:param str country_code: Two letter ISO country code (required)
:return: CheckoutStateProvinceResponse
If the method is called asynchronously,
returns the request thread.
"""
all_params = ['country_code'] # noqa: E501
all_params.append('async_req')
all_params.append('_return_http_data_only')
all_params.append('_preload_content')
all_params.append('_request_timeout')
params = locals()
for key, val in six.iteritems(params['kwargs']):
if key not in all_params:
raise TypeError(
"Got an unexpected keyword argument '%s'"
" to method get_state_provinces_for_country" % key
)
params[key] = val
del params['kwargs']
# verify the required parameter 'country_code' is set
if ('country_code' not in params or
params['country_code'] is None):
raise ValueError("Missing the required parameter `country_code` when calling `get_state_provinces_for_country`") # noqa: E501
collection_formats = {}
path_params = {}
if 'country_code' in params:
path_params['country_code'] = params['country_code'] # noqa: E501
query_params = []
header_params = {}
form_params = []
local_var_files = {}
body_params = None
# HTTP header `Accept`
header_params['Accept'] = self.api_client.select_header_accept(
['application/json']) # noqa: E501
# HTTP header `Content-Type`
header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501
['application/json']) # noqa: E501
# Authentication setting
auth_settings = ['ultraCartBrowserApiKey', 'ultraCartOauth', 'ultraCartSimpleApiKey'] # noqa: E501
return self.api_client.call_api(
'/checkout/stateProvincesForCountry/{country_code}', 'POST',
path_params,
query_params,
header_params,
body=body_params,
post_params=form_params,
files=local_var_files,
response_type='CheckoutStateProvinceResponse', # noqa: E501
auth_settings=auth_settings,
async_req=params.get('async_req'),
_return_http_data_only=params.get('_return_http_data_only'),
_preload_content=params.get('_preload_content', True),
_request_timeout=params.get('_request_timeout'),
collection_formats=collection_formats)
def handoff_cart(self, handoff_request, **kwargs): # noqa: E501
"""Handoff cart # noqa: E501
Handoff the browser to UltraCart for view cart on StoreFront, transfer to PayPal, transfer to Affirm, transfer to Sezzle or finalization of the order (including upsell processing). # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
>>> thread = api.handoff_cart(handoff_request, async_req=True)
>>> result = thread.get()
:param async_req bool
:param CheckoutHandoffRequest handoff_request: Handoff request (required)
:param str expand: The object expansion to perform on the result. See documentation for examples
:return: CheckoutHandoffResponse
If the method is called asynchronously,
returns the request thread.
"""
kwargs['_return_http_data_only'] = True
if kwargs.get('async_req'):
return self.handoff_cart_with_http_info(handoff_request, **kwargs) # noqa: E501
else:
(data) = self.handoff_cart_with_http_info(handoff_request, **kwargs) # noqa: E501
return data
def handoff_cart_with_http_info(self, handoff_request, **kwargs): # noqa: E501
"""Handoff cart # noqa: E501
Handoff the browser to UltraCart for view cart on StoreFront, transfer to PayPal, transfer to Affirm, transfer to Sezzle or finalization of the order (including upsell processing). # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
>>> thread = api.handoff_cart_with_http_info(handoff_request, async_req=True)
>>> result = thread.get()
:param async_req bool
:param CheckoutHandoffRequest handoff_request: Handoff request (required)
:param str expand: The object expansion to perform on the result. See documentation for examples
:return: CheckoutHandoffResponse
If the method is called asynchronously,
returns the request thread.
"""
all_params = ['handoff_request', 'expand'] # noqa: E501
all_params.append('async_req')
all_params.append('_return_http_data_only')
all_params.append('_preload_content')
all_params.append('_request_timeout')
params = locals()
for key, val in six.iteritems(params['kwargs']):
if key not in all_params:
raise TypeError(
"Got an unexpected keyword argument '%s'"
" to method handoff_cart" % key
)
params[key] = val
del params['kwargs']
# verify the required parameter 'handoff_request' is set
if ('handoff_request' not in params or
params['handoff_request'] is None):
raise ValueError("Missing the required parameter `handoff_request` when calling `handoff_cart`") # noqa: E501
collection_formats = {}
path_params = {}
query_params = []
if 'expand' in params:
query_params.append(('_expand', params['expand'])) # noqa: E501
header_params = {}
form_params = []
local_var_files = {}
body_params = None
if 'handoff_request' in params:
body_params = params['handoff_request']
# HTTP header `Accept`
header_params['Accept'] = self.api_client.select_header_accept(
['application/json']) # noqa: E501
# HTTP header `Content-Type`
header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501
['application/json']) # noqa: E501
# Authentication setting
auth_settings = ['ultraCartBrowserApiKey', 'ultraCartOauth', 'ultraCartSimpleApiKey'] # noqa: E501
return self.api_client.call_api(
'/checkout/cart/handoff', 'POST',
path_params,
query_params,
header_params,
body=body_params,
post_params=form_params,
files=local_var_files,
response_type='CheckoutHandoffResponse', # noqa: E501
auth_settings=auth_settings,
async_req=params.get('async_req'),
_return_http_data_only=params.get('_return_http_data_only'),
_preload_content=params.get('_preload_content', True),
_request_timeout=params.get('_request_timeout'),
collection_formats=collection_formats)
def login(self, login_request, **kwargs): # noqa: E501
"""Profile login # noqa: E501
Login in to the customer profile specified by cart.billing.email and password # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
>>> thread = api.login(login_request, async_req=True)
>>> result = thread.get()
:param async_req bool
:param CartProfileLoginRequest login_request: Login request (required)
:param str expand: The object expansion to perform on the result. See documentation for examples
:return: CartProfileLoginResponse
If the method is called asynchronously,
returns the request thread.
"""
kwargs['_return_http_data_only'] = True
if kwargs.get('async_req'):
return self.login_with_http_info(login_request, **kwargs) # noqa: E501
else:
(data) = self.login_with_http_info(login_request, **kwargs) # noqa: E501
return data
def login_with_http_info(self, login_request, **kwargs): # noqa: E501
"""Profile login # noqa: E501
Login in to the customer profile specified by cart.billing.email and password # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
>>> thread = api.login_with_http_info(login_request, async_req=True)
>>> result = thread.get()
:param async_req bool
:param CartProfileLoginRequest login_request: Login request (required)
:param str expand: The object expansion to perform on the result. See documentation for examples
:return: CartProfileLoginResponse
If the method is called asynchronously,
returns the request thread.
"""
all_params = ['login_request', 'expand'] # noqa: E501
all_params.append('async_req')
all_params.append('_return_http_data_only')
all_params.append('_preload_content')
all_params.append('_request_timeout')
params = locals()
for key, val in six.iteritems(params['kwargs']):
if key not in all_params:
raise TypeError(
"Got an unexpected keyword argument '%s'"
" to method login" % key
)
params[key] = val
del params['kwargs']
# verify the required parameter 'login_request' is set
if ('login_request' not in params or
params['login_request'] is None):
raise ValueError("Missing the required parameter `login_request` when calling `login`") # noqa: E501
collection_formats = {}
path_params = {}
query_params = []
if 'expand' in params:
query_params.append(('_expand', params['expand'])) # noqa: E501
header_params = {}
form_params = []
local_var_files = {}
body_params = None
if 'login_request' in params:
body_params = params['login_request']
# HTTP header `Accept`
header_params['Accept'] = self.api_client.select_header_accept(
['application/json']) # noqa: E501
# HTTP header `Content-Type`
header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501
['application/json']) # noqa: E501
# Authentication setting
auth_settings = ['ultraCartBrowserApiKey', 'ultraCartOauth', 'ultraCartSimpleApiKey'] # noqa: E501
return self.api_client.call_api(
'/checkout/cart/profile/login', 'POST',
path_params,
query_params,
header_params,
body=body_params,
post_params=form_params,
files=local_var_files,
response_type='CartProfileLoginResponse', # noqa: E501
auth_settings=auth_settings,
async_req=params.get('async_req'),
_return_http_data_only=params.get('_return_http_data_only'),
_preload_content=params.get('_preload_content', True),
_request_timeout=params.get('_request_timeout'),
collection_formats=collection_formats)
def logout(self, cart, **kwargs): # noqa: E501
"""Profile logout # noqa: E501
Log the cart out of the current profile. No error will occur if they are not logged in. # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
>>> thread = api.logout(cart, async_req=True)
>>> result = thread.get()
:param async_req bool
:param Cart cart: Cart (required)
:param str expand: The object expansion to perform on the result. See documentation for examples
:return: CartResponse
If the method is called asynchronously,
returns the request thread.
"""
kwargs['_return_http_data_only'] = True
if kwargs.get('async_req'):
return self.logout_with_http_info(cart, **kwargs) # noqa: E501
else:
(data) = self.logout_with_http_info(cart, **kwargs) # noqa: E501
return data
def logout_with_http_info(self, cart, **kwargs): # noqa: E501
"""Profile logout # noqa: E501
Log the cart out of the current profile. No error will occur if they are not logged in. # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
>>> thread = api.logout_with_http_info(cart, async_req=True)
>>> result = thread.get()
:param async_req bool
:param Cart cart: Cart (required)
:param str expand: The object expansion to perform on the result. See documentation for examples
:return: CartResponse
If the method is called asynchronously,
returns the request thread.
"""
all_params = ['cart', 'expand'] # noqa: E501
all_params.append('async_req')
all_params.append('_return_http_data_only')
all_params.append('_preload_content')
all_params.append('_request_timeout')
params = locals()
for key, val in six.iteritems(params['kwargs']):
if key not in all_params:
raise TypeError(
"Got an unexpected keyword argument '%s'"
" to method logout" % key
)
params[key] = val
del params['kwargs']
# verify the required parameter 'cart' is set
if ('cart' not in params or
params['cart'] is None):
raise ValueError("Missing the required parameter `cart` when calling `logout`") # noqa: E501
collection_formats = {}
path_params = {}
query_params = []
if 'expand' in params:
query_params.append(('_expand', params['expand'])) # noqa: E501
header_params = {}
form_params = []
local_var_files = {}
body_params = None
if 'cart' in params:
body_params = params['cart']
# HTTP header `Accept`
header_params['Accept'] = self.api_client.select_header_accept(
['application/json']) # noqa: E501
# HTTP header `Content-Type`
header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501
['application/json']) # noqa: E501
# Authentication setting
auth_settings = ['ultraCartBrowserApiKey', 'ultraCartOauth', 'ultraCartSimpleApiKey'] # noqa: E501
return self.api_client.call_api(
'/checkout/cart/profile/logout', 'POST',
path_params,
query_params,
header_params,
body=body_params,
post_params=form_params,
files=local_var_files,
response_type='CartResponse', # noqa: E501
auth_settings=auth_settings,
async_req=params.get('async_req'),
_return_http_data_only=params.get('_return_http_data_only'),
_preload_content=params.get('_preload_content', True),
_request_timeout=params.get('_request_timeout'),
collection_formats=collection_formats)
def register(self, register_request, **kwargs): # noqa: E501
"""Profile registration # noqa: E501
Register a new customer profile. Requires the cart.billing object to be populated along with the password. # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
>>> thread = api.register(register_request, async_req=True)
>>> result = thread.get()
:param async_req bool
:param CartProfileRegisterRequest register_request: Register request (required)
:param str expand: The object expansion to perform on the result. See documentation for examples
:return: CartProfileRegisterResponse
If the method is called asynchronously,
returns the request thread.
"""
kwargs['_return_http_data_only'] = True
if kwargs.get('async_req'):
return self.register_with_http_info(register_request, **kwargs) # noqa: E501
else:
(data) = self.register_with_http_info(register_request, **kwargs) # noqa: E501
return data
def register_with_http_info(self, register_request, **kwargs): # noqa: E501
"""Profile registration # noqa: E501
Register a new customer profile. Requires the cart.billing object to be populated along with the password. # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
>>> thread = api.register_with_http_info(register_request, async_req=True)
>>> result = thread.get()
:param async_req bool
:param CartProfileRegisterRequest register_request: Register request (required)
:param str expand: The object expansion to perform on the result. See documentation for examples
:return: CartProfileRegisterResponse
If the method is called asynchronously,
returns the request thread.
"""
all_params = ['register_request', 'expand'] # noqa: E501
all_params.append('async_req')
all_params.append('_return_http_data_only')
all_params.append('_preload_content')
all_params.append('_request_timeout')
params = locals()
for key, val in six.iteritems(params['kwargs']):
if key not in all_params:
raise TypeError(
"Got an unexpected keyword argument '%s'"
" to method register" % key
)
params[key] = val
del params['kwargs']
# verify the required parameter 'register_request' is set
if ('register_request' not in params or
params['register_request'] is None):
raise ValueError("Missing the required parameter `register_request` when calling `register`") # noqa: E501
collection_formats = {}
path_params = {}
query_params = []
if 'expand' in params:
query_params.append(('_expand', params['expand'])) # noqa: E501
header_params = {}
form_params = []
local_var_files = {}
body_params = None
if 'register_request' in params:
body_params = params['register_request']
# HTTP header `Accept`
header_params['Accept'] = self.api_client.select_header_accept(
['application/json']) # noqa: E501
# HTTP header `Content-Type`
header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501
['application/json']) # noqa: E501
# Authentication setting
auth_settings = ['ultraCartBrowserApiKey', 'ultraCartOauth', 'ultraCartSimpleApiKey'] # noqa: E501
return self.api_client.call_api(
'/checkout/cart/profile/register', 'POST',
path_params,
query_params,
header_params,
body=body_params,
post_params=form_params,
files=local_var_files,
response_type='CartProfileRegisterResponse', # noqa: E501
auth_settings=auth_settings,
async_req=params.get('async_req'),
_return_http_data_only=params.get('_return_http_data_only'),
_preload_content=params.get('_preload_content', True),
_request_timeout=params.get('_request_timeout'),
collection_formats=collection_formats)
def register_affiliate_click(self, register_affiliate_click_request, **kwargs): # noqa: E501
"""Register affiliate click # noqa: E501
Register an affiliate click. Used by custom checkouts that are completely API based and do not perform checkout handoff. # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
>>> thread = api.register_affiliate_click(register_affiliate_click_request, async_req=True)
>>> result = thread.get()
:param async_req bool
:param RegisterAffiliateClickRequest register_affiliate_click_request: Register affiliate click request (required)
:param str expand: The object expansion to perform on the result. See documentation for examples
:return: RegisterAffiliateClickResponse
If the method is called asynchronously,
returns the request thread.
"""
kwargs['_return_http_data_only'] = True
if kwargs.get('async_req'):
return self.register_affiliate_click_with_http_info(register_affiliate_click_request, **kwargs) # noqa: E501
else:
(data) = self.register_affiliate_click_with_http_info(register_affiliate_click_request, **kwargs) # noqa: E501
return data
def register_affiliate_click_with_http_info(self, register_affiliate_click_request, **kwargs): # noqa: E501
"""Register affiliate click # noqa: E501
Register an affiliate click. Used by custom checkouts that are completely API based and do not perform checkout handoff. # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
>>> thread = api.register_affiliate_click_with_http_info(register_affiliate_click_request, async_req=True)
>>> result = thread.get()
:param async_req bool
:param RegisterAffiliateClickRequest register_affiliate_click_request: Register affiliate click request (required)
:param str expand: The object expansion to perform on the result. See documentation for examples
:return: RegisterAffiliateClickResponse
If the method is called asynchronously,
returns the request thread.
"""
all_params = ['register_affiliate_click_request', 'expand'] # noqa: E501
all_params.append('async_req')
all_params.append('_return_http_data_only')
all_params.append('_preload_content')
all_params.append('_request_timeout')
params = locals()
for key, val in six.iteritems(params['kwargs']):
if key not in all_params:
raise TypeError(
"Got an unexpected keyword argument '%s'"
" to method register_affiliate_click" % key
)
params[key] = val
del params['kwargs']
# verify the required parameter 'register_affiliate_click_request' is set
if ('register_affiliate_click_request' not in params or
params['register_affiliate_click_request'] is None):
raise ValueError("Missing the required parameter `register_affiliate_click_request` when calling `register_affiliate_click`") # noqa: E501
collection_formats = {}
path_params = {}
query_params = []
if 'expand' in params:
query_params.append(('_expand', params['expand'])) # noqa: E501
header_params = {}
form_params = []
local_var_files = {}
body_params = None
if 'register_affiliate_click_request' in params:
body_params = params['register_affiliate_click_request']
# HTTP header `Accept`
header_params['Accept'] = self.api_client.select_header_accept(
['application/json']) # noqa: E501
# HTTP header `Content-Type`
header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501
['application/json']) # noqa: E501
# Authentication setting
auth_settings = ['ultraCartBrowserApiKey', 'ultraCartOauth', 'ultraCartSimpleApiKey'] # noqa: E501
return self.api_client.call_api(
'/checkout/affiliateClick/register', 'POST',
path_params,
query_params,
header_params,
body=body_params,
post_params=form_params,
files=local_var_files,
response_type='RegisterAffiliateClickResponse', # noqa: E501
auth_settings=auth_settings,
async_req=params.get('async_req'),
_return_http_data_only=params.get('_return_http_data_only'),
_preload_content=params.get('_preload_content', True),
_request_timeout=params.get('_request_timeout'),
collection_formats=collection_formats)
def related_items_for_cart(self, cart, **kwargs): # noqa: E501
"""Related items # noqa: E501
Retrieve all the related items for the cart contents. Expansion is limited to content, content.assignments, content.attributes, content.multimedia, content.multimedia.thumbnails, options, pricing, and pricing.tiers. # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
>>> thread = api.related_items_for_cart(cart, async_req=True)
>>> result = thread.get()
:param async_req bool
:param Cart cart: Cart (required)
:param str expand: The object expansion to perform on the result. See item resource documentation for examples
:return: ItemsResponse
If the method is called asynchronously,
returns the request thread.
"""
kwargs['_return_http_data_only'] = True
if kwargs.get('async_req'):
return self.related_items_for_cart_with_http_info(cart, **kwargs) # noqa: E501
else:
(data) = self.related_items_for_cart_with_http_info(cart, **kwargs) # noqa: E501
return data
def related_items_for_cart_with_http_info(self, cart, **kwargs): # noqa: E501
"""Related items # noqa: E501
Retrieve all the related items for the cart contents. Expansion is limited to content, content.assignments, content.attributes, content.multimedia, content.multimedia.thumbnails, options, pricing, and pricing.tiers. # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
>>> thread = api.related_items_for_cart_with_http_info(cart, async_req=True)
>>> result = thread.get()
:param async_req bool
:param Cart cart: Cart (required)
:param str expand: The object expansion to perform on the result. See item resource documentation for examples
:return: ItemsResponse
If the method is called asynchronously,
returns the request thread.
"""
all_params = ['cart', 'expand'] # noqa: E501
all_params.append('async_req')
all_params.append('_return_http_data_only')
all_params.append('_preload_content')
all_params.append('_request_timeout')
params = locals()
for key, val in six.iteritems(params['kwargs']):
if key not in all_params:
raise TypeError(
"Got an unexpected keyword argument '%s'"
" to method related_items_for_cart" % key
)
params[key] = val
del params['kwargs']
# verify the required parameter 'cart' is set
if ('cart' not in params or
params['cart'] is None):
raise ValueError("Missing the required parameter `cart` when calling `related_items_for_cart`") # noqa: E501
collection_formats = {}
path_params = {}
query_params = []
if 'expand' in params:
query_params.append(('_expand', params['expand'])) # noqa: E501
header_params = {}
form_params = []
local_var_files = {}
body_params = None
if 'cart' in params:
body_params = params['cart']
# HTTP header `Accept`
header_params['Accept'] = self.api_client.select_header_accept(
['application/json']) # noqa: E501
# HTTP header `Content-Type`
header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501
['application/json']) # noqa: E501
# Authentication setting
auth_settings = ['ultraCartBrowserApiKey', 'ultraCartOauth', 'ultraCartSimpleApiKey'] # noqa: E501
return self.api_client.call_api(
'/checkout/related_items', 'POST',
path_params,
query_params,
header_params,
body=body_params,
post_params=form_params,
files=local_var_files,
response_type='ItemsResponse', # noqa: E501
auth_settings=auth_settings,
async_req=params.get('async_req'),
_return_http_data_only=params.get('_return_http_data_only'),
_preload_content=params.get('_preload_content', True),
_request_timeout=params.get('_request_timeout'),
collection_formats=collection_formats)
def related_items_for_item(self, item_id, cart, **kwargs): # noqa: E501
"""Related items (specific item) # noqa: E501
Retrieve all the related items for the cart contents. Expansion is limited to content, content.assignments, content.attributes, content.multimedia, content.multimedia.thumbnails, options, pricing, and pricing.tiers. # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
>>> thread = api.related_items_for_item(item_id, cart, async_req=True)
>>> result = thread.get()
:param async_req bool
:param str item_id: Item ID to retrieve related items for (required)
:param Cart cart: Cart (required)
:param str expand: The object expansion to perform on the result. See item resource documentation for examples
:return: ItemsResponse
If the method is called asynchronously,
returns the request thread.
"""
kwargs['_return_http_data_only'] = True
if kwargs.get('async_req'):
return self.related_items_for_item_with_http_info(item_id, cart, **kwargs) # noqa: E501
else:
(data) = self.related_items_for_item_with_http_info(item_id, cart, **kwargs) # noqa: E501
return data
def related_items_for_item_with_http_info(self, item_id, cart, **kwargs): # noqa: E501
"""Related items (specific item) # noqa: E501
Retrieve all the related items for the cart contents. Expansion is limited to content, content.assignments, content.attributes, content.multimedia, content.multimedia.thumbnails, options, pricing, and pricing.tiers. # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
>>> thread = api.related_items_for_item_with_http_info(item_id, cart, async_req=True)
>>> result = thread.get()
:param async_req bool
:param str item_id: Item ID to retrieve related items for (required)
:param Cart cart: Cart (required)
:param str expand: The object expansion to perform on the result. See item resource documentation for examples
:return: ItemsResponse
If the method is called asynchronously,
returns the request thread.
"""
all_params = ['item_id', 'cart', 'expand'] # noqa: E501
all_params.append('async_req')
all_params.append('_return_http_data_only')
all_params.append('_preload_content')
all_params.append('_request_timeout')
params = locals()
for key, val in six.iteritems(params['kwargs']):
if key not in all_params:
raise TypeError(
"Got an unexpected keyword argument '%s'"
" to method related_items_for_item" % key
)
params[key] = val
del params['kwargs']
# verify the required parameter 'item_id' is set
if ('item_id' not in params or
params['item_id'] is None):
raise ValueError("Missing the required parameter `item_id` when calling `related_items_for_item`") # noqa: E501
# verify the required parameter 'cart' is set
if ('cart' not in params or
params['cart'] is None):
raise ValueError("Missing the required parameter `cart` when calling `related_items_for_item`") # noqa: E501
collection_formats = {}
path_params = {}
if 'item_id' in params:
path_params['item_id'] = params['item_id'] # noqa: E501
query_params = []
if 'expand' in params:
query_params.append(('_expand', params['expand'])) # noqa: E501
header_params = {}
form_params = []
local_var_files = {}
body_params = None
if 'cart' in params:
body_params = params['cart']
# HTTP header `Accept`
header_params['Accept'] = self.api_client.select_header_accept(
['application/json']) # noqa: E501
# HTTP header `Content-Type`
header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501
['application/json']) # noqa: E501
# Authentication setting
auth_settings = ['ultraCartBrowserApiKey', 'ultraCartOauth', 'ultraCartSimpleApiKey'] # noqa: E501
return self.api_client.call_api(
'/checkout/relatedItems/{item_id}', 'POST',
path_params,
query_params,
header_params,
body=body_params,
post_params=form_params,
files=local_var_files,
response_type='ItemsResponse', # noqa: E501
auth_settings=auth_settings,
async_req=params.get('async_req'),
_return_http_data_only=params.get('_return_http_data_only'),
_preload_content=params.get('_preload_content', True),
_request_timeout=params.get('_request_timeout'),
collection_formats=collection_formats)
def setup_browser_key(self, browser_key_request, **kwargs): # noqa: E501
"""Setup Browser Application # noqa: E501
Setup a browser key authenticated application with checkout permissions. This REST call must be made with an authentication scheme that is not browser key. The new application will be linked to the application that makes this call. If this application is disabled / deleted, then so will the application setup by this call. The purpose of this call is to allow an OAuth application, such as the Wordpress plugin, to setup the proper browser based authentication for the REST checkout API to use. # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
>>> thread = api.setup_browser_key(browser_key_request, async_req=True)
>>> result = thread.get()
:param async_req bool
:param CheckoutSetupBrowserKeyRequest browser_key_request: Setup browser key request (required)
:return: CheckoutSetupBrowserKeyResponse
If the method is called asynchronously,
returns the request thread.
"""
kwargs['_return_http_data_only'] = True
if kwargs.get('async_req'):
return self.setup_browser_key_with_http_info(browser_key_request, **kwargs) # noqa: E501
else:
(data) = self.setup_browser_key_with_http_info(browser_key_request, **kwargs) # noqa: E501
return data
def setup_browser_key_with_http_info(self, browser_key_request, **kwargs): # noqa: E501
"""Setup Browser Application # noqa: E501
Setup a browser key authenticated application with checkout permissions. This REST call must be made with an authentication scheme that is not browser key. The new application will be linked to the application that makes this call. If this application is disabled / deleted, then so will the application setup by this call. The purpose of this call is to allow an OAuth application, such as the Wordpress plugin, to setup the proper browser based authentication for the REST checkout API to use. # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
>>> thread = api.setup_browser_key_with_http_info(browser_key_request, async_req=True)
>>> result = thread.get()
:param async_req bool
:param CheckoutSetupBrowserKeyRequest browser_key_request: Setup browser key request (required)
:return: CheckoutSetupBrowserKeyResponse
If the method is called asynchronously,
returns the request thread.
"""
all_params = ['browser_key_request'] # noqa: E501
all_params.append('async_req')
all_params.append('_return_http_data_only')
all_params.append('_preload_content')
all_params.append('_request_timeout')
params = locals()
for key, val in six.iteritems(params['kwargs']):
if key not in all_params:
raise TypeError(
"Got an unexpected keyword argument '%s'"
" to method setup_browser_key" % key
)
params[key] = val
del params['kwargs']
# verify the required parameter 'browser_key_request' is set
if ('browser_key_request' not in params or
params['browser_key_request'] is None):
raise ValueError("Missing the required parameter `browser_key_request` when calling `setup_browser_key`") # noqa: E501
collection_formats = {}
path_params = {}
query_params = []
header_params = {}
form_params = []
local_var_files = {}
body_params = None
if 'browser_key_request' in params:
body_params = params['browser_key_request']
# HTTP header `Accept`
header_params['Accept'] = self.api_client.select_header_accept(
['application/json']) # noqa: E501
# HTTP header `Content-Type`
header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501
['application/json']) # noqa: E501
# Authentication setting
auth_settings = ['ultraCartOauth', 'ultraCartSimpleApiKey'] # noqa: E501
return self.api_client.call_api(
'/checkout/browser_key', 'PUT',
path_params,
query_params,
header_params,
body=body_params,
post_params=form_params,
files=local_var_files,
response_type='CheckoutSetupBrowserKeyResponse', # noqa: E501
auth_settings=auth_settings,
async_req=params.get('async_req'),
_return_http_data_only=params.get('_return_http_data_only'),
_preload_content=params.get('_preload_content', True),
_request_timeout=params.get('_request_timeout'),
collection_formats=collection_formats)
def update_cart(self, cart, **kwargs): # noqa: E501
"""Update cart # noqa: E501
Update the cart. # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
>>> thread = api.update_cart(cart, async_req=True)
>>> result = thread.get()
:param async_req bool
:param Cart cart: Cart (required)
:param str expand: The object expansion to perform on the result. See documentation for examples
:return: CartResponse
If the method is called asynchronously,
returns the request thread.
"""
kwargs['_return_http_data_only'] = True
if kwargs.get('async_req'):
return self.update_cart_with_http_info(cart, **kwargs) # noqa: E501
else:
(data) = self.update_cart_with_http_info(cart, **kwargs) # noqa: E501
return data
def update_cart_with_http_info(self, cart, **kwargs): # noqa: E501
"""Update cart # noqa: E501
Update the cart. # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
>>> thread = api.update_cart_with_http_info(cart, async_req=True)
>>> result = thread.get()
:param async_req bool
:param Cart cart: Cart (required)
:param str expand: The object expansion to perform on the result. See documentation for examples
:return: CartResponse
If the method is called asynchronously,
returns the request thread.
"""
all_params = ['cart', 'expand'] # noqa: E501
all_params.append('async_req')
all_params.append('_return_http_data_only')
all_params.append('_preload_content')
all_params.append('_request_timeout')
params = locals()
for key, val in six.iteritems(params['kwargs']):
if key not in all_params:
raise TypeError(
"Got an unexpected keyword argument '%s'"
" to method update_cart" % key
)
params[key] = val
del params['kwargs']
# verify the required parameter 'cart' is set
if ('cart' not in params or
params['cart'] is None):
raise ValueError("Missing the required parameter `cart` when calling `update_cart`") # noqa: E501
collection_formats = {}
path_params = {}
query_params = []
if 'expand' in params:
query_params.append(('_expand', params['expand'])) # noqa: E501
header_params = {}
form_params = []
local_var_files = {}
body_params = None
if 'cart' in params:
body_params = params['cart']
# HTTP header `Accept`
header_params['Accept'] = self.api_client.select_header_accept(
['application/json']) # noqa: E501
# HTTP header `Content-Type`
header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501
['application/json']) # noqa: E501
# Authentication setting
auth_settings = ['ultraCartBrowserApiKey', 'ultraCartOauth', 'ultraCartSimpleApiKey'] # noqa: E501
return self.api_client.call_api(
'/checkout/cart', 'PUT',
path_params,
query_params,
header_params,
body=body_params,
post_params=form_params,
files=local_var_files,
response_type='CartResponse', # noqa: E501
auth_settings=auth_settings,
async_req=params.get('async_req'),
_return_http_data_only=params.get('_return_http_data_only'),
_preload_content=params.get('_preload_content', True),
_request_timeout=params.get('_request_timeout'),
collection_formats=collection_formats)
def validate_cart(self, validation_request, **kwargs): # noqa: E501
"""Validate # noqa: E501
Validate the cart for errors. Specific checks can be passed and multiple validations can occur throughout your checkout flow. # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
>>> thread = api.validate_cart(validation_request, async_req=True)
>>> result = thread.get()
:param async_req bool
:param CartValidationRequest validation_request: Validation request (required)
:param str expand: The object expansion to perform on the result. See documentation for examples
:return: CartValidationResponse
If the method is called asynchronously,
returns the request thread.
"""
kwargs['_return_http_data_only'] = True
if kwargs.get('async_req'):
return self.validate_cart_with_http_info(validation_request, **kwargs) # noqa: E501
else:
(data) = self.validate_cart_with_http_info(validation_request, **kwargs) # noqa: E501
return data
def validate_cart_with_http_info(self, validation_request, **kwargs): # noqa: E501
"""Validate # noqa: E501
Validate the cart for errors. Specific checks can be passed and multiple validations can occur throughout your checkout flow. # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
>>> thread = api.validate_cart_with_http_info(validation_request, async_req=True)
>>> result = thread.get()
:param async_req bool
:param CartValidationRequest validation_request: Validation request (required)
:param str expand: The object expansion to perform on the result. See documentation for examples
:return: CartValidationResponse
If the method is called asynchronously,
returns the request thread.
"""
all_params = ['validation_request', 'expand'] # noqa: E501
all_params.append('async_req')
all_params.append('_return_http_data_only')
all_params.append('_preload_content')
all_params.append('_request_timeout')
params = locals()
for key, val in six.iteritems(params['kwargs']):
if key not in all_params:
raise TypeError(
"Got an unexpected keyword argument '%s'"
" to method validate_cart" % key
)
params[key] = val
del params['kwargs']
# verify the required parameter 'validation_request' is set
if ('validation_request' not in params or
params['validation_request'] is None):
raise ValueError("Missing the required parameter `validation_request` when calling `validate_cart`") # noqa: E501
collection_formats = {}
path_params = {}
query_params = []
if 'expand' in params:
query_params.append(('_expand', params['expand'])) # noqa: E501
header_params = {}
form_params = []
local_var_files = {}
body_params = None
if 'validation_request' in params:
body_params = params['validation_request']
# HTTP header `Accept`
header_params['Accept'] = self.api_client.select_header_accept(
['application/json']) # noqa: E501
# HTTP header `Content-Type`
header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501
['application/json']) # noqa: E501
# Authentication setting
auth_settings = ['ultraCartBrowserApiKey', 'ultraCartOauth', 'ultraCartSimpleApiKey'] # noqa: E501
return self.api_client.call_api(
'/checkout/cart/validate', 'POST',
path_params,
query_params,
header_params,
body=body_params,
post_params=form_params,
files=local_var_files,
response_type='CartValidationResponse', # noqa: E501
auth_settings=auth_settings,
async_req=params.get('async_req'),
_return_http_data_only=params.get('_return_http_data_only'),
_preload_content=params.get('_preload_content', True),
_request_timeout=params.get('_request_timeout'),
collection_formats=collection_formats)
| 42.629065 | 522 | 0.627828 | 9,615 | 83,894 | 5.23973 | 0.034425 | 0.048114 | 0.021119 | 0.027154 | 0.958833 | 0.946784 | 0.936066 | 0.924811 | 0.920464 | 0.910242 | 0 | 0.01551 | 0.286814 | 83,894 | 1,967 | 523 | 42.650737 | 0.826514 | 0.360789 | 0 | 0.776836 | 1 | 0 | 0.205114 | 0.068284 | 0 | 0 | 0 | 0 | 0 | 1 | 0.037665 | false | 0 | 0.004708 | 0 | 0.097928 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 1 | 1 | 1 | 1 | 1 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 1 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 8 |
3cb22845b4886805d8281e53324e508d40e9aa79 | 3,666 | py | Python | tests/test_mismatched_brackets.py | delfick/nose-of-yeti | b9fbb32c131074bc61eb5d1da67f0931d9803637 | [
"MIT"
] | 12 | 2015-02-20T11:21:58.000Z | 2022-01-20T08:33:32.000Z | tests/test_mismatched_brackets.py | delfick/nose-of-yeti | b9fbb32c131074bc61eb5d1da67f0931d9803637 | [
"MIT"
] | 8 | 2015-12-05T01:26:19.000Z | 2021-06-07T01:22:59.000Z | tests/test_mismatched_brackets.py | delfick/nose-of-yeti | b9fbb32c131074bc61eb5d1da67f0931d9803637 | [
"MIT"
] | 4 | 2015-05-26T19:49:48.000Z | 2016-05-25T20:33:59.000Z | import pytest
import re
class TestMismatchedBrackets:
def test_it_knows_about_mismatched_square_from_parenthesis(self):
original = """
def wat(self:
pass
things = "]"
def things]self:
pass
"""
expected = re.escape(
"Trying to close the wrong type of bracket. Found ']' (line 6, column 10) instead of closing a '(' (line 1, column 7)"
)
with pytest.raises(SyntaxError, match=expected):
pytest.helpers.assert_conversion(original, "")
def test_it_knows_about_mismatched_square_from_curly(self):
original = """
def wat{self:
pass
def things]self:
pass
"""
expected = re.escape(
"Trying to close the wrong type of bracket. Found ']' (line 4, column 10) instead of closing a '{' (line 1, column 7)"
)
with pytest.raises(SyntaxError, match=expected):
pytest.helpers.assert_conversion(original, "")
def test_it_knows_about_mismatched_parenthesis_from_square(self):
original = """
def wat[self:
pass
def things)self:
pass
"""
expected = re.escape(
"Trying to close the wrong type of bracket. Found ')' (line 4, column 10) instead of closing a '[' (line 1, column 7)"
)
with pytest.raises(SyntaxError, match=expected):
pytest.helpers.assert_conversion(original, "")
def test_it_knows_about_hanging_square(self):
original = """
def wat(self):
pass
def things]self:
pass
"""
expected = re.escape("Found a hanging ']' on line 4, column 10")
with pytest.raises(SyntaxError, match=expected):
pytest.helpers.assert_conversion(original, "")
def test_it_knows_about_hanging_parenthesis(self):
original = """
def wat(self)):
pass
"""
expected = re.escape("Found a hanging ')' on line 1, column 13")
with pytest.raises(SyntaxError, match=expected):
pytest.helpers.assert_conversion(original, "")
def test_it_knows_about_hanging_curly(self):
original = """
class Wat:
def __init__(self):
self.d = {1: 2}}
"""
expected = re.escape("Found a hanging '}' on line 3, column 23")
with pytest.raises(SyntaxError, match=expected):
pytest.helpers.assert_conversion(original, "")
def test_it_knows_about_unclosed_parenthesis(self):
original = """
def thing(self):
pass
def wat(self:
pass
"""
expected = re.escape("Found an open '(' (line 4, column 7) that wasn't closed")
with pytest.raises(SyntaxError, match=expected):
pytest.helpers.assert_conversion(original, "")
def test_it_knows_about_unclosed_square(self):
original = """
def thing(self):
pass
things = [1, 2
"""
expected = re.escape("Found an open '[' (line 4, column 9) that wasn't closed")
with pytest.raises(SyntaxError, match=expected):
pytest.helpers.assert_conversion(original, "")
def test_it_knows_about_unclosed_curly(self):
original = """
def thing(self):
pass
things = [1, 2]
stuff = {1: 2
"""
expected = re.escape("Found an open '{' (line 6, column 8) that wasn't closed")
with pytest.raises(SyntaxError, match=expected):
pytest.helpers.assert_conversion(original, "")
| 27.358209 | 130 | 0.572559 | 410 | 3,666 | 4.963415 | 0.163415 | 0.086486 | 0.039803 | 0.061916 | 0.912039 | 0.912039 | 0.897297 | 0.867813 | 0.816708 | 0.727764 | 0 | 0.015267 | 0.321058 | 3,666 | 133 | 131 | 27.56391 | 0.80233 | 0 | 0 | 0.625 | 0 | 0.03125 | 0.389525 | 0 | 0 | 0 | 0 | 0 | 0.09375 | 1 | 0.09375 | false | 0.135417 | 0.020833 | 0 | 0.125 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 1 | 1 | 1 | 1 | 1 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | 0 | 0 | 7 |
3cde7507df9785759d3dabce97c6ea65ec02b279 | 6,131 | py | Python | loldib/getratings/models/NA/na_zed/na_zed_top.py | koliupy/loldib | c9ab94deb07213cdc42b5a7c26467cdafaf81b7f | [
"Apache-2.0"
] | null | null | null | loldib/getratings/models/NA/na_zed/na_zed_top.py | koliupy/loldib | c9ab94deb07213cdc42b5a7c26467cdafaf81b7f | [
"Apache-2.0"
] | null | null | null | loldib/getratings/models/NA/na_zed/na_zed_top.py | koliupy/loldib | c9ab94deb07213cdc42b5a7c26467cdafaf81b7f | [
"Apache-2.0"
] | null | null | null | from getratings.models.ratings import Ratings
class NA_Zed_Top_Aatrox(Ratings):
pass
class NA_Zed_Top_Ahri(Ratings):
pass
class NA_Zed_Top_Akali(Ratings):
pass
class NA_Zed_Top_Alistar(Ratings):
pass
class NA_Zed_Top_Amumu(Ratings):
pass
class NA_Zed_Top_Anivia(Ratings):
pass
class NA_Zed_Top_Annie(Ratings):
pass
class NA_Zed_Top_Ashe(Ratings):
pass
class NA_Zed_Top_AurelionSol(Ratings):
pass
class NA_Zed_Top_Azir(Ratings):
pass
class NA_Zed_Top_Bard(Ratings):
pass
class NA_Zed_Top_Blitzcrank(Ratings):
pass
class NA_Zed_Top_Brand(Ratings):
pass
class NA_Zed_Top_Braum(Ratings):
pass
class NA_Zed_Top_Caitlyn(Ratings):
pass
class NA_Zed_Top_Camille(Ratings):
pass
class NA_Zed_Top_Cassiopeia(Ratings):
pass
class NA_Zed_Top_Chogath(Ratings):
pass
class NA_Zed_Top_Corki(Ratings):
pass
class NA_Zed_Top_Darius(Ratings):
pass
class NA_Zed_Top_Diana(Ratings):
pass
class NA_Zed_Top_Draven(Ratings):
pass
class NA_Zed_Top_DrMundo(Ratings):
pass
class NA_Zed_Top_Ekko(Ratings):
pass
class NA_Zed_Top_Elise(Ratings):
pass
class NA_Zed_Top_Evelynn(Ratings):
pass
class NA_Zed_Top_Ezreal(Ratings):
pass
class NA_Zed_Top_Fiddlesticks(Ratings):
pass
class NA_Zed_Top_Fiora(Ratings):
pass
class NA_Zed_Top_Fizz(Ratings):
pass
class NA_Zed_Top_Galio(Ratings):
pass
class NA_Zed_Top_Gangplank(Ratings):
pass
class NA_Zed_Top_Garen(Ratings):
pass
class NA_Zed_Top_Gnar(Ratings):
pass
class NA_Zed_Top_Gragas(Ratings):
pass
class NA_Zed_Top_Graves(Ratings):
pass
class NA_Zed_Top_Hecarim(Ratings):
pass
class NA_Zed_Top_Heimerdinger(Ratings):
pass
class NA_Zed_Top_Illaoi(Ratings):
pass
class NA_Zed_Top_Irelia(Ratings):
pass
class NA_Zed_Top_Ivern(Ratings):
pass
class NA_Zed_Top_Janna(Ratings):
pass
class NA_Zed_Top_JarvanIV(Ratings):
pass
class NA_Zed_Top_Jax(Ratings):
pass
class NA_Zed_Top_Jayce(Ratings):
pass
class NA_Zed_Top_Jhin(Ratings):
pass
class NA_Zed_Top_Jinx(Ratings):
pass
class NA_Zed_Top_Kalista(Ratings):
pass
class NA_Zed_Top_Karma(Ratings):
pass
class NA_Zed_Top_Karthus(Ratings):
pass
class NA_Zed_Top_Kassadin(Ratings):
pass
class NA_Zed_Top_Katarina(Ratings):
pass
class NA_Zed_Top_Kayle(Ratings):
pass
class NA_Zed_Top_Kayn(Ratings):
pass
class NA_Zed_Top_Kennen(Ratings):
pass
class NA_Zed_Top_Khazix(Ratings):
pass
class NA_Zed_Top_Kindred(Ratings):
pass
class NA_Zed_Top_Kled(Ratings):
pass
class NA_Zed_Top_KogMaw(Ratings):
pass
class NA_Zed_Top_Leblanc(Ratings):
pass
class NA_Zed_Top_LeeSin(Ratings):
pass
class NA_Zed_Top_Leona(Ratings):
pass
class NA_Zed_Top_Lissandra(Ratings):
pass
class NA_Zed_Top_Lucian(Ratings):
pass
class NA_Zed_Top_Lulu(Ratings):
pass
class NA_Zed_Top_Lux(Ratings):
pass
class NA_Zed_Top_Malphite(Ratings):
pass
class NA_Zed_Top_Malzahar(Ratings):
pass
class NA_Zed_Top_Maokai(Ratings):
pass
class NA_Zed_Top_MasterYi(Ratings):
pass
class NA_Zed_Top_MissFortune(Ratings):
pass
class NA_Zed_Top_MonkeyKing(Ratings):
pass
class NA_Zed_Top_Mordekaiser(Ratings):
pass
class NA_Zed_Top_Morgana(Ratings):
pass
class NA_Zed_Top_Nami(Ratings):
pass
class NA_Zed_Top_Nasus(Ratings):
pass
class NA_Zed_Top_Nautilus(Ratings):
pass
class NA_Zed_Top_Nidalee(Ratings):
pass
class NA_Zed_Top_Nocturne(Ratings):
pass
class NA_Zed_Top_Nunu(Ratings):
pass
class NA_Zed_Top_Olaf(Ratings):
pass
class NA_Zed_Top_Orianna(Ratings):
pass
class NA_Zed_Top_Ornn(Ratings):
pass
class NA_Zed_Top_Pantheon(Ratings):
pass
class NA_Zed_Top_Poppy(Ratings):
pass
class NA_Zed_Top_Quinn(Ratings):
pass
class NA_Zed_Top_Rakan(Ratings):
pass
class NA_Zed_Top_Rammus(Ratings):
pass
class NA_Zed_Top_RekSai(Ratings):
pass
class NA_Zed_Top_Renekton(Ratings):
pass
class NA_Zed_Top_Rengar(Ratings):
pass
class NA_Zed_Top_Riven(Ratings):
pass
class NA_Zed_Top_Rumble(Ratings):
pass
class NA_Zed_Top_Ryze(Ratings):
pass
class NA_Zed_Top_Sejuani(Ratings):
pass
class NA_Zed_Top_Shaco(Ratings):
pass
class NA_Zed_Top_Shen(Ratings):
pass
class NA_Zed_Top_Shyvana(Ratings):
pass
class NA_Zed_Top_Singed(Ratings):
pass
class NA_Zed_Top_Sion(Ratings):
pass
class NA_Zed_Top_Sivir(Ratings):
pass
class NA_Zed_Top_Skarner(Ratings):
pass
class NA_Zed_Top_Sona(Ratings):
pass
class NA_Zed_Top_Soraka(Ratings):
pass
class NA_Zed_Top_Swain(Ratings):
pass
class NA_Zed_Top_Syndra(Ratings):
pass
class NA_Zed_Top_TahmKench(Ratings):
pass
class NA_Zed_Top_Taliyah(Ratings):
pass
class NA_Zed_Top_Talon(Ratings):
pass
class NA_Zed_Top_Taric(Ratings):
pass
class NA_Zed_Top_Teemo(Ratings):
pass
class NA_Zed_Top_Thresh(Ratings):
pass
class NA_Zed_Top_Tristana(Ratings):
pass
class NA_Zed_Top_Trundle(Ratings):
pass
class NA_Zed_Top_Tryndamere(Ratings):
pass
class NA_Zed_Top_TwistedFate(Ratings):
pass
class NA_Zed_Top_Twitch(Ratings):
pass
class NA_Zed_Top_Udyr(Ratings):
pass
class NA_Zed_Top_Urgot(Ratings):
pass
class NA_Zed_Top_Varus(Ratings):
pass
class NA_Zed_Top_Vayne(Ratings):
pass
class NA_Zed_Top_Veigar(Ratings):
pass
class NA_Zed_Top_Velkoz(Ratings):
pass
class NA_Zed_Top_Vi(Ratings):
pass
class NA_Zed_Top_Viktor(Ratings):
pass
class NA_Zed_Top_Vladimir(Ratings):
pass
class NA_Zed_Top_Volibear(Ratings):
pass
class NA_Zed_Top_Warwick(Ratings):
pass
class NA_Zed_Top_Xayah(Ratings):
pass
class NA_Zed_Top_Xerath(Ratings):
pass
class NA_Zed_Top_XinZhao(Ratings):
pass
class NA_Zed_Top_Yasuo(Ratings):
pass
class NA_Zed_Top_Yorick(Ratings):
pass
class NA_Zed_Top_Zac(Ratings):
pass
class NA_Zed_Top_Zed(Ratings):
pass
class NA_Zed_Top_Ziggs(Ratings):
pass
class NA_Zed_Top_Zilean(Ratings):
pass
class NA_Zed_Top_Zyra(Ratings):
pass
| 14.702638 | 46 | 0.750938 | 972 | 6,131 | 4.3107 | 0.151235 | 0.230549 | 0.329356 | 0.428162 | 0.784726 | 0.784726 | 0 | 0 | 0 | 0 | 0 | 0 | 0.18121 | 6,131 | 416 | 47 | 14.737981 | 0.834661 | 0 | 0 | 0.498195 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | true | 0.498195 | 0.00361 | 0 | 0.501805 | 0 | 0 | 0 | 0 | null | 1 | 1 | 1 | 0 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 1 | 0 | 0 | 1 | 0 | 0 | 7 |
a71a829720a4813cb86534e06a7583bf17ce13b1 | 197 | py | Python | carrierx/resources/core/__init__.py | EugeneSqr/carrierx-python | 3bdd9728165e73584116ae63af03e2f7bcd7ca9f | [
"MIT"
] | null | null | null | carrierx/resources/core/__init__.py | EugeneSqr/carrierx-python | 3bdd9728165e73584116ae63af03e2f7bcd7ca9f | [
"MIT"
] | null | null | null | carrierx/resources/core/__init__.py | EugeneSqr/carrierx-python | 3bdd9728165e73584116ae63af03e2f7bcd7ca9f | [
"MIT"
] | 1 | 2020-03-26T15:13:10.000Z | 2020-03-26T15:13:10.000Z | from carrierx.resources.core import sms
from carrierx.resources.core import storage
from carrierx.resources.core import shortener
from carrierx.resources.core.endpoints import Endpoint, Endpoints
| 32.833333 | 65 | 0.857868 | 26 | 197 | 6.5 | 0.384615 | 0.284024 | 0.497041 | 0.591716 | 0.550296 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0.091371 | 197 | 5 | 66 | 39.4 | 0.944134 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | true | 0 | 1 | 0 | 1 | 0 | 1 | 0 | 0 | null | 1 | 1 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 1 | 0 | 1 | 0 | 0 | 8 |
a7386ca0712076dda7b0de6f9f59f6648fa1e98f | 122 | py | Python | hachinai_scraping/__init__.py | kibehiro/hachinaiScraping | 4df80bc9a451ab07d8e8bd8d8741299e3c1fddca | [
"MIT"
] | null | null | null | hachinai_scraping/__init__.py | kibehiro/hachinaiScraping | 4df80bc9a451ab07d8e8bd8d8741299e3c1fddca | [
"MIT"
] | null | null | null | hachinai_scraping/__init__.py | kibehiro/hachinaiScraping | 4df80bc9a451ab07d8e8bd8d8741299e3c1fddca | [
"MIT"
] | null | null | null | from hachinai_scraping.get_pages import *
from hachinai_scraping.init_db import *
from hachinai_scraping.make_db import *
| 30.5 | 41 | 0.852459 | 18 | 122 | 5.444444 | 0.5 | 0.367347 | 0.612245 | 0.530612 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0.098361 | 122 | 3 | 42 | 40.666667 | 0.890909 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | true | 0 | 1 | 0 | 1 | 0 | 1 | 0 | 0 | null | 1 | 1 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 1 | 0 | 1 | 0 | 0 | 8 |
597ee7e4ad9274fcea2d4e70c47b01f196b22d36 | 1,722 | py | Python | TP1/EJ2 Y 3/ejercicio_2.py | luisemacsel/IA2 | b99e19df3cd689d1c6cb42cd83cd71d6302e89eb | [
"MIT"
] | null | null | null | TP1/EJ2 Y 3/ejercicio_2.py | luisemacsel/IA2 | b99e19df3cd689d1c6cb42cd83cd71d6302e89eb | [
"MIT"
] | null | null | null | TP1/EJ2 Y 3/ejercicio_2.py | luisemacsel/IA2 | b99e19df3cd689d1c6cb42cd83cd71d6302e89eb | [
"MIT"
] | null | null | null | from Aestrella import *
from calculoDistancia import *
import numba
@numba.jit
def main():
print("Ejercicio 2")
map = np.array([[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0],
[ 0, 1, 2, 0, 25, 26, 0, 49, 50, 0],
[ 0, 3, 4, 0, 27, 28, 0, 51, 52, 0],
[ 0, 5, 6, 0, 29, 30, 0, 53, 54, 0],
[ 0, 7, 8, 0, 31, 32, 0, 55, 56, 0],
[ 0, 0, 0, 0, 0, 0, 0, 0 , 0 , 0],
[ 0, 9, 10, 0, 33, 34, 0, 57, 58, 0],
[ 0, 11, 12, 0, 35, 36, 0, 59, 60, 0],
[ 0, 13, 14, 0, 37, 38, 0, 61, 62, 0],
[ 0, 15, 16, 0, 39, 40, 0, 63, 64, 0],
[ 0, 0, 0, 0, 0, 0, 0, 0 , 0 , 0],
[ 0, 17, 18, 0, 41, 42, 0, 65, 66, 0],
[ 0, 19, 20, 0, 43, 44, 0, 67, 68, 0],
[ 0, 21, 22, 0, 45, 46, 0, 69, 70, 0],
[ 0, 23, 24, 0, 47, 48, 0, 71, 72, 0],
[ 0, 0, 0, 0, 0, 0, 0, 0, 0 , 0],
[ 0, 73, 74, 0, 81, 82, 0, 89, 90, 0],
[ 0, 75, 76, 0, 83, 84, 0, 91, 92, 0],
[ 0, 77, 78, 0, 85, 86, 0, 93, 94, 0],
[ 0, 79, 80, 0, 87, 88, 0, 95, 96, 0],
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0],
[ 0, 97, 98, 0, 0, 0, 0, 0, 0, 0],
[ 0, 99, 100, 0, 0, 0, 0, 0, 0, 0],
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0]])
CalculoCosto(map)
print('fin de ejecucion')
if __name__ == "__main__":
main()
| 46.540541 | 62 | 0.281069 | 268 | 1,722 | 1.776119 | 0.447761 | 0.37395 | 0.441176 | 0.529412 | 0.176471 | 0.176471 | 0.176471 | 0.176471 | 0.159664 | 0.159664 | 0 | 0.41573 | 0.534843 | 1,722 | 36 | 63 | 47.833333 | 0.178527 | 0 | 0 | 0.117647 | 0 | 0 | 0.020759 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0.029412 | false | 0 | 0.088235 | 0 | 0.117647 | 0.058824 | 0 | 0 | 1 | null | 1 | 1 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 1 | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 7 |
59b26d92ba20edc8ffa46a9377ef60300280d84a | 928 | py | Python | advertise/models/collections.py | sadagatasgarov1/sahibinden | 76b16c64551d37b055f80b82808736f107afb92c | [
"MIT"
] | 2 | 2020-08-13T19:50:43.000Z | 2021-01-16T17:15:43.000Z | advertise/models/collections.py | sadagatasgarov1/sahibinden | 76b16c64551d37b055f80b82808736f107afb92c | [
"MIT"
] | 5 | 2021-04-08T21:50:04.000Z | 2022-02-10T12:34:46.000Z | advertise/models/collections.py | ozanteoman/sahibinden | 76b16c64551d37b055f80b82808736f107afb92c | [
"MIT"
] | 3 | 2020-09-26T13:17:06.000Z | 2022-01-26T20:02:56.000Z | from django.db import models
class Frontal(models.Model):
name = models.CharField(max_length=25)
def __str__(self):
return self.name
class InteriorFeature(models.Model):
name = models.CharField(max_length=25)
def __str__(self):
return self.name
class ExteriorFeature(models.Model):
name = models.CharField(max_length=25)
def __str__(self):
return self.name
class Locality(models.Model):
name = models.CharField(max_length=25)
def __str__(self):
return self.name
class Transportation(models.Model):
name = models.CharField(max_length=25)
def __str__(self):
return self.name
class Landscape(models.Model):
name = models.CharField(max_length=25)
def __str__(self):
return self.name
class SuitableForDisabled(models.Model):
name = models.CharField(max_length=25)
def __str__(self):
return self.name
| 18.196078 | 42 | 0.685345 | 117 | 928 | 5.136752 | 0.196581 | 0.12812 | 0.174709 | 0.244592 | 0.806988 | 0.806988 | 0.806988 | 0.806988 | 0.806988 | 0.806988 | 0 | 0.019231 | 0.215517 | 928 | 50 | 43 | 18.56 | 0.806319 | 0 | 0 | 0.724138 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0.241379 | false | 0 | 0.034483 | 0.241379 | 1 | 0 | 0 | 0 | 0 | null | 0 | 0 | 1 | 1 | 1 | 1 | 1 | 1 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | 1 | 1 | 0 | 0 | 11 |
59d3add449cc3a690a5c5bffa8fd5ce8de055f23 | 116 | py | Python | backend/apps/users/admin.py | jorgejimenez98/backend-evaluacion-desempenno | 08975303952608809375c5e2185bf20a84cc0f4e | [
"MIT"
] | 13 | 2021-04-22T04:08:19.000Z | 2022-03-09T13:39:40.000Z | backend/apps/users/admin.py | jorgejimenez98/backend-evaluacion-desempenno | 08975303952608809375c5e2185bf20a84cc0f4e | [
"MIT"
] | 29 | 2017-04-25T14:05:08.000Z | 2021-06-21T14:41:53.000Z | backend/apps/users/admin.py | jorgejimenez98/backend-evaluacion-desempenno | 08975303952608809375c5e2185bf20a84cc0f4e | [
"MIT"
] | 9 | 2021-04-25T20:20:01.000Z | 2022-02-15T00:53:18.000Z | from django.contrib import admin
from django.contrib.auth.models import Permission
admin.site.register(Permission)
| 23.2 | 49 | 0.844828 | 16 | 116 | 6.125 | 0.625 | 0.204082 | 0.346939 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0.086207 | 116 | 4 | 50 | 29 | 0.924528 | 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 | 1 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 1 | 0 | 1 | 0 | 0 | 7 |
ab68e82b022e3bf3e5a0c6c20ce974d26528e634 | 3,719 | py | Python | searcher/models.py | lawrie-sm/holyrood-search | 70f7d7cfd06ca1516fed4e057309c41d009a8d53 | [
"MIT"
] | null | null | null | searcher/models.py | lawrie-sm/holyrood-search | 70f7d7cfd06ca1516fed4e057309c41d009a8d53 | [
"MIT"
] | null | null | null | searcher/models.py | lawrie-sm/holyrood-search | 70f7d7cfd06ca1516fed4e057309c41d009a8d53 | [
"MIT"
] | null | null | null | from django.db import models
from django.utils import timezone
from django.contrib.postgres.search import SearchVectorField, SearchVector
from django.contrib.postgres.indexes import GinIndex
class Person(models.Model):
internal_id = models.CharField(max_length=128, blank=True, null=True)
name = models.CharField(max_length=256, blank=True, null=True)
is_msp = models.BooleanField(default=True)
has_been_scraped = models.BooleanField(default=False)
def __str__(self):
return (self.name)
class Contribution(models.Model):
internal_id = models.CharField(max_length=1024, blank=True, null=True)
session = models.IntegerField(blank=True, null=True)
meeting_type = models.CharField(max_length=1024, blank=True, null=True)
heading_type = models.CharField(max_length=1024, blank=True, null=True)
heading = models.CharField(max_length=1024, blank=True, null=True)
subheading_type = models.CharField(max_length=1024, blank=True, null=True)
subheading = models.CharField(max_length=1024, blank=True, null=True)
party = models.CharField(max_length=1024, blank=True, null=True)
text = models.TextField(blank=True, null=True)
date = models.DateField(auto_now=False, auto_now_add=False, default=timezone.now)
member = models.ForeignKey(Person, blank=True, null=True)
member_office = models.CharField(max_length=1024, blank=True, null=True)
has_been_scraped = models.BooleanField(default=False)
search_vector = SearchVectorField(null=True)
class Meta(object):
indexes = [GinIndex(fields=['search_vector'])]
def __str__(self):
return (self.heading)
class Motion(models.Model):
internal_id = models.CharField(max_length=256, blank=True, null=True)
sp_ref = models.CharField(max_length=128, blank=True, null=True)
sub_type = models.CharField(max_length=128, blank=True, null=True)
member = models.ForeignKey(Person, blank=True, null=True)
party = models.CharField(max_length=256, blank=True, null=True)
date = models.DateField(auto_now=False, auto_now_add=False, default=timezone.now)
title = models.CharField(max_length=256, blank=True, null=True)
text = models.TextField(blank=True, null=True)
is_potential_mb = models.BooleanField(default=False)
has_cross_party_support = models.BooleanField(default=False)
has_been_scraped = models.BooleanField(default=False)
search_vector = SearchVectorField(null=True)
class Meta(object):
indexes = [GinIndex(fields=['search_vector'])]
def __str__(self):
return (self.title)
# TODO: Investigate why titles aren't working for questions
class Question(models.Model):
internal_id = models.CharField(max_length=256, blank=True, null=True)
sp_ref = models.CharField(max_length=128, blank=True, null=True)
sub_type = models.CharField(max_length=128, blank=True, null=True)
member = models.ForeignKey(Person, blank=True, null=True)
party = models.CharField(max_length=256, blank=True, null=True)
date = models.DateField(auto_now=False, auto_now_add=False, default=timezone.now)
answer_date = models.DateField(auto_now=False, auto_now_add=False, default=timezone.now, blank=True, null=True)
text = models.TextField(blank=True, null=True)
answer_text = models.TextField(blank=True, null=True)
answered_by = models.CharField(max_length=256, blank=True, null=True)
has_been_scraped = models.BooleanField(default=False)
search_vector = SearchVectorField(null=True)
class Meta(object):
indexes = [GinIndex(fields=['search_vector'])]
def __str__(self):
return (self.sp_ref) | 48.934211 | 116 | 0.728422 | 493 | 3,719 | 5.324544 | 0.172414 | 0.097524 | 0.143619 | 0.18781 | 0.836952 | 0.801524 | 0.801524 | 0.78781 | 0.736381 | 0.624762 | 0 | 0.021725 | 0.158376 | 3,719 | 76 | 117 | 48.934211 | 0.816933 | 0.015327 | 0 | 0.53125 | 0 | 0 | 0.010876 | 0 | 0 | 0 | 0 | 0.013158 | 0 | 1 | 0.0625 | false | 0 | 0.0625 | 0.0625 | 0.953125 | 0 | 0 | 0 | 0 | null | 0 | 0 | 1 | 1 | 1 | 1 | 1 | 1 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | 0 | 0 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 9 |
ab6fc8d95bef63b6e794a118840a3fabca3a8756 | 198 | py | Python | pythonProject1/Lesson 1 (Task 3).py | Sana-Amir/Python-Lesson-Assignments | 719c9c40a1eed0b5abcd5e56f97d1c9cb9b89ec0 | [
"MIT"
] | null | null | null | pythonProject1/Lesson 1 (Task 3).py | Sana-Amir/Python-Lesson-Assignments | 719c9c40a1eed0b5abcd5e56f97d1c9cb9b89ec0 | [
"MIT"
] | null | null | null | pythonProject1/Lesson 1 (Task 3).py | Sana-Amir/Python-Lesson-Assignments | 719c9c40a1eed0b5abcd5e56f97d1c9cb9b89ec0 | [
"MIT"
] | null | null | null | print("#########")
print("#\t\t#")
print("#\t\t#")
print("#\t\t#")
print("#########")
print("\n")
print("#\t\t#")
print("#\t\t#")
print("#########")
print("#\t\t#")
print("#\t\t#")
| 13.2 | 19 | 0.353535 | 26 | 198 | 2.692308 | 0.115385 | 0.6 | 0.7 | 1.028571 | 0.985714 | 0.985714 | 0.985714 | 0.685714 | 0 | 0 | 0 | 0 | 0.141414 | 198 | 14 | 20 | 14.142857 | 0.411765 | 0 | 0 | 0.909091 | 0 | 0 | 0.392265 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | true | 0 | 0 | 0 | 0 | 1 | 1 | 0 | 0 | null | 1 | 1 | 1 | 1 | 1 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 1 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | 0 | 1 | 0 | 11 |
ab8388fb55d2c48ef306ae96176da9a058f9757e | 127 | py | Python | example_project/tests/test_app.py | DeanWay/coverage-threshold | f242495331b6dbb1319cc6aac9e449b450c7c874 | [
"MIT"
] | 6 | 2021-01-25T18:37:02.000Z | 2022-01-06T15:13:11.000Z | example_project/tests/test_app.py | DeanWay/coverage-threshold | f242495331b6dbb1319cc6aac9e449b450c7c874 | [
"MIT"
] | null | null | null | example_project/tests/test_app.py | DeanWay/coverage-threshold | f242495331b6dbb1319cc6aac9e449b450c7c874 | [
"MIT"
] | null | null | null | from src.app import is_big_number
def test_is_big_number() -> None:
assert is_big_number(9001) == "That's a big number!"
| 21.166667 | 56 | 0.724409 | 23 | 127 | 3.695652 | 0.652174 | 0.423529 | 0.388235 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0.037736 | 0.165354 | 127 | 5 | 57 | 25.4 | 0.764151 | 0 | 0 | 0 | 0 | 0 | 0.15748 | 0 | 0 | 0 | 0 | 0 | 0.333333 | 1 | 0.333333 | true | 0 | 0.333333 | 0 | 0.666667 | 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 | 1 | 1 | 0 | 1 | 0 | 1 | 0 | 0 | 8 |
e6376ed2b3e6c4beb3a1624130bcf73491261331 | 122 | py | Python | main.py | nhatsmrt/torch-styletransfer | dabf3f8a375da318f74c8ccae75e0cf7298582da | [
"CC-BY-4.0"
] | 3 | 2021-07-27T08:06:39.000Z | 2021-12-20T03:06:18.000Z | main.py | nhatsmrt/torch-styletransfer | dabf3f8a375da318f74c8ccae75e0cf7298582da | [
"CC-BY-4.0"
] | null | null | null | main.py | nhatsmrt/torch-styletransfer | dabf3f8a375da318f74c8ccae75e0cf7298582da | [
"CC-BY-4.0"
] | null | null | null | from src.test import run_test, run_test_multiple
from fire import Fire
if __name__ == '__main__': Fire(run_test_multiple) | 30.5 | 50 | 0.811475 | 20 | 122 | 4.3 | 0.5 | 0.244186 | 0.348837 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0.114754 | 122 | 4 | 50 | 30.5 | 0.796296 | 0 | 0 | 0 | 0 | 0 | 0.065041 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | true | 0 | 0.666667 | 0 | 0.666667 | 0 | 1 | 0 | 0 | null | 1 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 1 | 0 | 1 | 0 | 0 | 7 |
e63c77013dbdc6b6e1f94c253bec60bc27a49d60 | 38,707 | py | Python | tests/functional/regressions/test_issue105.py | matt-koevort/tartiflette | 5777866b133d846ce4f8aa03f735fa81832896cd | [
"MIT"
] | 530 | 2019-06-04T11:45:36.000Z | 2022-03-31T09:29:56.000Z | tests/functional/regressions/test_issue105.py | matt-koevort/tartiflette | 5777866b133d846ce4f8aa03f735fa81832896cd | [
"MIT"
] | 242 | 2019-06-04T11:53:08.000Z | 2022-03-28T07:06:27.000Z | tests/functional/regressions/test_issue105.py | matt-koevort/tartiflette | 5777866b133d846ce4f8aa03f735fa81832896cd | [
"MIT"
] | 36 | 2019-06-21T06:40:27.000Z | 2021-11-04T13:11:16.000Z | import pytest
async def _query_human_resolver(*_args, **__kwargs):
return {"name": "Hooman"}
@pytest.mark.asyncio
@pytest.mark.ttftt_engine(resolvers={"Query.human": _query_human_resolver})
@pytest.mark.parametrize(
"query,expected",
[
(
"""
query {
human(id: 1) {
name
}
}
""",
{"data": {"human": {"name": "Hooman"}}},
),
(
"""
query {
human(id: 1) {
name
unknownField
}
dog {
name
}
}
""",
{
"data": None,
"errors": [
{
"message": "Field unknownField doesn't exist on Human",
"path": ["human", "unknownField"],
"locations": [{"line": 5, "column": 17}],
"extensions": {
"rule": "5.3.1",
"spec": "June 2018",
"details": "https://graphql.github.io/graphql-spec/June2018/#sec-Field-Selections-on-Objects-Interfaces-and-Unions-Types",
"tag": "field-selections-on-objects-interfaces-and-unions-types",
},
}
],
},
),
(
"""
query {
human(undefinedArgument: 1, id: 1) {
unknownField
name
}
dog {
name
}
}
""",
{
"data": None,
"errors": [
{
"message": "Field unknownField doesn't exist on Human",
"path": ["human", "unknownField"],
"locations": [{"line": 4, "column": 17}],
"extensions": {
"rule": "5.3.1",
"spec": "June 2018",
"details": "https://graphql.github.io/graphql-spec/June2018/#sec-Field-Selections-on-Objects-Interfaces-and-Unions-Types",
"tag": "field-selections-on-objects-interfaces-and-unions-types",
},
},
{
"message": "Provided Argument < undefinedArgument > doesn't exist on field < Query.human >.",
"path": ["human"],
"locations": [{"line": 3, "column": 21}],
"extensions": {
"rule": "5.4.1",
"spec": "June 2018",
"details": "https://graphql.github.io/graphql-spec/June2018/#sec-Argument-Names",
"tag": "argument-names",
},
},
],
},
),
(
"""
query {
human(undefinedArgument: 1, id: 1) {
unknownField
name
}
unknownField {
name
}
}
""",
{
"data": None,
"errors": [
{
"message": "Field unknownField doesn't exist on Human",
"path": ["human", "unknownField"],
"locations": [{"line": 4, "column": 17}],
"extensions": {
"rule": "5.3.1",
"spec": "June 2018",
"details": "https://graphql.github.io/graphql-spec/June2018/#sec-Field-Selections-on-Objects-Interfaces-and-Unions-Types",
"tag": "field-selections-on-objects-interfaces-and-unions-types",
},
},
{
"message": "Provided Argument < undefinedArgument > doesn't exist on field < Query.human >.",
"path": ["human"],
"locations": [{"line": 3, "column": 21}],
"extensions": {
"rule": "5.4.1",
"spec": "June 2018",
"details": "https://graphql.github.io/graphql-spec/June2018/#sec-Argument-Names",
"tag": "argument-names",
},
},
{
"message": "Field name doesn't exist on Root",
"path": ["unknownField", "name"],
"locations": [{"line": 8, "column": 17}],
"extensions": {
"rule": "5.3.1",
"spec": "June 2018",
"details": "https://graphql.github.io/graphql-spec/June2018/#sec-Field-Selections-on-Objects-Interfaces-and-Unions-Types",
"tag": "field-selections-on-objects-interfaces-and-unions-types",
},
},
{
"message": "Field unknownField doesn't exist on Query",
"path": ["unknownField"],
"locations": [{"line": 7, "column": 15}],
"extensions": {
"rule": "5.3.1",
"spec": "June 2018",
"details": "https://graphql.github.io/graphql-spec/June2018/#sec-Field-Selections-on-Objects-Interfaces-and-Unions-Types",
"tag": "field-selections-on-objects-interfaces-and-unions-types",
},
},
],
},
),
(
"""
query {
dog {
doesKnowCommand(command: SIT)
}
}
""",
{
"data": None,
"errors": [
{
"message": "Provided Argument < command > doesn't exist on field < Dog.doesKnowCommand >.",
"path": ["dog", "doesKnowCommand"],
"locations": [{"line": 4, "column": 33}],
"extensions": {
"rule": "5.4.1",
"spec": "June 2018",
"details": "https://graphql.github.io/graphql-spec/June2018/#sec-Argument-Names",
"tag": "argument-names",
},
},
{
"message": "Missing mandatory argument < dogCommand > in field < Dog.doesKnowCommand >.",
"path": ["dog", "doesKnowCommand"],
"locations": [{"line": 4, "column": 17}],
"extensions": {
"rule": "5.4.2.1",
"spec": "June 2018",
"details": "https://graphql.github.io/graphql-spec/June2018/#sec-Required-Arguments",
"tag": "required-arguments",
},
},
],
},
),
(
"""
fragment DogFields on Dog {
... on Dog {
doesKnowCommand(command: SIT)
}
}
query {
dog {
...DogFields
}
}
""",
{
"data": None,
"errors": [
{
"message": "Provided Argument < command > doesn't exist on field < Dog.doesKnowCommand >.",
"path": ["doesKnowCommand"],
"locations": [{"line": 4, "column": 33}],
"extensions": {
"rule": "5.4.1",
"spec": "June 2018",
"details": "https://graphql.github.io/graphql-spec/June2018/#sec-Argument-Names",
"tag": "argument-names",
},
},
{
"message": "Missing mandatory argument < dogCommand > in field < Dog.doesKnowCommand >.",
"path": ["doesKnowCommand"],
"locations": [{"line": 4, "column": 17}],
"extensions": {
"rule": "5.4.2.1",
"spec": "June 2018",
"details": "https://graphql.github.io/graphql-spec/June2018/#sec-Required-Arguments",
"tag": "required-arguments",
},
},
],
},
),
(
"""
query {
unknownField1
dog {
doesKnowCommand(command: SIT) {
unknownField2
}
unknownField3
}
unknownField4
}
""",
{
"data": None,
"errors": [
{
"message": "Field unknownField1 doesn't exist on Query",
"path": ["unknownField1"],
"locations": [{"line": 3, "column": 15}],
"extensions": {
"rule": "5.3.1",
"spec": "June 2018",
"details": "https://graphql.github.io/graphql-spec/June2018/#sec-Field-Selections-on-Objects-Interfaces-and-Unions-Types",
"tag": "field-selections-on-objects-interfaces-and-unions-types",
},
},
{
"message": "Field unknownField2 doesn't exist on Boolean",
"path": ["dog", "doesKnowCommand", "unknownField2"],
"locations": [{"line": 6, "column": 19}],
"extensions": {
"rule": "5.3.1",
"spec": "June 2018",
"details": "https://graphql.github.io/graphql-spec/June2018/#sec-Field-Selections-on-Objects-Interfaces-and-Unions-Types",
"tag": "field-selections-on-objects-interfaces-and-unions-types",
},
},
{
"message": "Field doesKnowCommand must not have a selection since type Boolean has no subfields.",
"path": ["dog", "doesKnowCommand"],
"locations": [{"line": 5, "column": 17}],
"extensions": {
"rule": "5.3.3",
"tag": "leaf-field-selections",
"details": "https://graphql.github.io/graphql-spec/June2018/#sec-Leaf-Field-Selections",
"spec": "June 2018",
},
},
{
"message": "Provided Argument < command > doesn't exist on field < Dog.doesKnowCommand >.",
"path": ["dog", "doesKnowCommand"],
"locations": [{"line": 5, "column": 33}],
"extensions": {
"rule": "5.4.1",
"spec": "June 2018",
"details": "https://graphql.github.io/graphql-spec/June2018/#sec-Argument-Names",
"tag": "argument-names",
},
},
{
"message": "Missing mandatory argument < dogCommand > in field < Dog.doesKnowCommand >.",
"path": ["dog", "doesKnowCommand"],
"locations": [{"line": 5, "column": 17}],
"extensions": {
"rule": "5.4.2.1",
"spec": "June 2018",
"details": "https://graphql.github.io/graphql-spec/June2018/#sec-Required-Arguments",
"tag": "required-arguments",
},
},
{
"message": "Field unknownField3 doesn't exist on Dog",
"path": ["dog", "unknownField3"],
"locations": [{"line": 8, "column": 17}],
"extensions": {
"rule": "5.3.1",
"spec": "June 2018",
"details": "https://graphql.github.io/graphql-spec/June2018/#sec-Field-Selections-on-Objects-Interfaces-and-Unions-Types",
"tag": "field-selections-on-objects-interfaces-and-unions-types",
},
},
{
"message": "Field unknownField4 doesn't exist on Query",
"path": ["unknownField4"],
"locations": [{"line": 10, "column": 15}],
"extensions": {
"rule": "5.3.1",
"spec": "June 2018",
"details": "https://graphql.github.io/graphql-spec/June2018/#sec-Field-Selections-on-Objects-Interfaces-and-Unions-Types",
"tag": "field-selections-on-objects-interfaces-and-unions-types",
},
},
],
},
),
(
"""
fragment QueryFields on Query {
unknownField1
}
fragment NestedDogFields on Dog {
... on Dog {
doesKnowCommand(command: SIT) {
unknownField2
}
}
}
fragment DogFields on Dog {
...NestedDogFields
unknownField3
}
query {
...QueryFields
dog {
...DogFields
unknownField4
}
unknownField5
}
""",
{
"data": None,
"errors": [
{
"message": "Field unknownField1 doesn't exist on Query",
"path": ["unknownField1"],
"locations": [{"line": 3, "column": 15}],
"extensions": {
"rule": "5.3.1",
"spec": "June 2018",
"details": "https://graphql.github.io/graphql-spec/June2018/#sec-Field-Selections-on-Objects-Interfaces-and-Unions-Types",
"tag": "field-selections-on-objects-interfaces-and-unions-types",
},
},
{
"message": "Field unknownField2 doesn't exist on Boolean",
"path": ["doesKnowCommand", "unknownField2"],
"locations": [{"line": 9, "column": 19}],
"extensions": {
"rule": "5.3.1",
"spec": "June 2018",
"details": "https://graphql.github.io/graphql-spec/June2018/#sec-Field-Selections-on-Objects-Interfaces-and-Unions-Types",
"tag": "field-selections-on-objects-interfaces-and-unions-types",
},
},
{
"message": "Field doesKnowCommand must not have a selection since type Boolean has no subfields.",
"path": ["doesKnowCommand"],
"locations": [{"line": 8, "column": 17}],
"extensions": {
"rule": "5.3.3",
"tag": "leaf-field-selections",
"details": "https://graphql.github.io/graphql-spec/June2018/#sec-Leaf-Field-Selections",
"spec": "June 2018",
},
},
{
"message": "Provided Argument < command > doesn't exist on field < Dog.doesKnowCommand >.",
"path": ["doesKnowCommand"],
"locations": [{"line": 8, "column": 33}],
"extensions": {
"rule": "5.4.1",
"spec": "June 2018",
"details": "https://graphql.github.io/graphql-spec/June2018/#sec-Argument-Names",
"tag": "argument-names",
},
},
{
"message": "Missing mandatory argument < dogCommand > in field < Dog.doesKnowCommand >.",
"path": ["doesKnowCommand"],
"locations": [{"line": 8, "column": 17}],
"extensions": {
"rule": "5.4.2.1",
"spec": "June 2018",
"details": "https://graphql.github.io/graphql-spec/June2018/#sec-Required-Arguments",
"tag": "required-arguments",
},
},
{
"message": "Field unknownField3 doesn't exist on Dog",
"path": ["unknownField3"],
"locations": [{"line": 16, "column": 15}],
"extensions": {
"rule": "5.3.1",
"spec": "June 2018",
"details": "https://graphql.github.io/graphql-spec/June2018/#sec-Field-Selections-on-Objects-Interfaces-and-Unions-Types",
"tag": "field-selections-on-objects-interfaces-and-unions-types",
},
},
{
"message": "Field unknownField4 doesn't exist on Dog",
"path": ["dog", "unknownField4"],
"locations": [{"line": 23, "column": 17}],
"extensions": {
"rule": "5.3.1",
"spec": "June 2018",
"details": "https://graphql.github.io/graphql-spec/June2018/#sec-Field-Selections-on-Objects-Interfaces-and-Unions-Types",
"tag": "field-selections-on-objects-interfaces-and-unions-types",
},
},
{
"message": "Field unknownField5 doesn't exist on Query",
"path": ["unknownField5"],
"locations": [{"line": 25, "column": 15}],
"extensions": {
"rule": "5.3.1",
"spec": "June 2018",
"details": "https://graphql.github.io/graphql-spec/June2018/#sec-Field-Selections-on-Objects-Interfaces-and-Unions-Types",
"tag": "field-selections-on-objects-interfaces-and-unions-types",
},
},
],
},
),
(
"""
fragment QueryFields on Query {
unknownField1
}
fragment NestedDogFields on Dog {
... on Dog {
doesKnowCommand(command: SIT) {
unknownField2 {
unknownField21
}
}
}
}
fragment DogFields on Dog {
unknownField3
...NestedDogFields
}
query {
...QueryFields
dog {
...DogFields
unknownField4
}
unknownField5
}
""",
{
"data": None,
"errors": [
{
"message": "Field unknownField1 doesn't exist on Query",
"path": ["unknownField1"],
"locations": [{"line": 3, "column": 15}],
"extensions": {
"rule": "5.3.1",
"spec": "June 2018",
"details": "https://graphql.github.io/graphql-spec/June2018/#sec-Field-Selections-on-Objects-Interfaces-and-Unions-Types",
"tag": "field-selections-on-objects-interfaces-and-unions-types",
},
},
{
"message": "Field unknownField21 doesn't exist on Root",
"path": [
"doesKnowCommand",
"unknownField2",
"unknownField21",
],
"locations": [{"line": 10, "column": 21}],
"extensions": {
"rule": "5.3.1",
"spec": "June 2018",
"details": "https://graphql.github.io/graphql-spec/June2018/#sec-Field-Selections-on-Objects-Interfaces-and-Unions-Types",
"tag": "field-selections-on-objects-interfaces-and-unions-types",
},
},
{
"message": "Field unknownField2 doesn't exist on Boolean",
"path": ["doesKnowCommand", "unknownField2"],
"locations": [{"line": 9, "column": 19}],
"extensions": {
"rule": "5.3.1",
"spec": "June 2018",
"details": "https://graphql.github.io/graphql-spec/June2018/#sec-Field-Selections-on-Objects-Interfaces-and-Unions-Types",
"tag": "field-selections-on-objects-interfaces-and-unions-types",
},
},
{
"message": "Field doesKnowCommand must not have a selection since type Boolean has no subfields.",
"path": ["doesKnowCommand"],
"locations": [{"line": 8, "column": 17}],
"extensions": {
"rule": "5.3.3",
"tag": "leaf-field-selections",
"details": "https://graphql.github.io/graphql-spec/June2018/#sec-Leaf-Field-Selections",
"spec": "June 2018",
},
},
{
"message": "Provided Argument < command > doesn't exist on field < Dog.doesKnowCommand >.",
"path": ["doesKnowCommand"],
"locations": [{"line": 8, "column": 33}],
"extensions": {
"rule": "5.4.1",
"spec": "June 2018",
"details": "https://graphql.github.io/graphql-spec/June2018/#sec-Argument-Names",
"tag": "argument-names",
},
},
{
"message": "Missing mandatory argument < dogCommand > in field < Dog.doesKnowCommand >.",
"path": ["doesKnowCommand"],
"locations": [{"line": 8, "column": 17}],
"extensions": {
"rule": "5.4.2.1",
"spec": "June 2018",
"details": "https://graphql.github.io/graphql-spec/June2018/#sec-Required-Arguments",
"tag": "required-arguments",
},
},
{
"message": "Field unknownField3 doesn't exist on Dog",
"path": ["unknownField3"],
"locations": [{"line": 17, "column": 15}],
"extensions": {
"rule": "5.3.1",
"spec": "June 2018",
"details": "https://graphql.github.io/graphql-spec/June2018/#sec-Field-Selections-on-Objects-Interfaces-and-Unions-Types",
"tag": "field-selections-on-objects-interfaces-and-unions-types",
},
},
{
"message": "Field unknownField4 doesn't exist on Dog",
"path": ["dog", "unknownField4"],
"locations": [{"line": 25, "column": 17}],
"extensions": {
"rule": "5.3.1",
"spec": "June 2018",
"details": "https://graphql.github.io/graphql-spec/June2018/#sec-Field-Selections-on-Objects-Interfaces-and-Unions-Types",
"tag": "field-selections-on-objects-interfaces-and-unions-types",
},
},
{
"message": "Field unknownField5 doesn't exist on Query",
"path": ["unknownField5"],
"locations": [{"line": 27, "column": 15}],
"extensions": {
"rule": "5.3.1",
"spec": "June 2018",
"details": "https://graphql.github.io/graphql-spec/June2018/#sec-Field-Selections-on-Objects-Interfaces-and-Unions-Types",
"tag": "field-selections-on-objects-interfaces-and-unions-types",
},
},
],
},
),
(
"""
fragment QueryFields on Query {
unknownField1
}
fragment NestedDogFields on Dog {
... on Dog {
doesKnowCommandDown: doesKnowCommand(dogCommand: DOWN)
doesKnowCommandSitError: doesKnowCommand(command: SIT) {
unknownField2 @deprecated(undefinedArgument: "undefined") {
unknownField21
}
}
doesKnowCommandHeel: doesKnowCommand(dogCommand: HEEL) @deprecated(undefinedArgument: "undefined")
doesKnowCommandSit: doesKnowCommand(dogCommand: SIT)
}
}
fragment DogFields on Dog {
unknownField3
...NestedDogFields
}
query {
...QueryFields
dog {
doesKnowCommandUndefinedArgument: doesKnowCommand(undefinedArgument: "undefined", dogCommand: SIT)
...DogFields
unknownField4
doesKnowCommandHeel: doesKnowCommand(dogCommand: HEEL) @deprecated(undefinedArgument: "undefined")
}
unknownField5
}
""",
{
"data": None,
"errors": [
{
"message": "Field unknownField1 doesn't exist on Query",
"path": ["unknownField1"],
"locations": [{"line": 3, "column": 15}],
"extensions": {
"rule": "5.3.1",
"spec": "June 2018",
"details": "https://graphql.github.io/graphql-spec/June2018/#sec-Field-Selections-on-Objects-Interfaces-and-Unions-Types",
"tag": "field-selections-on-objects-interfaces-and-unions-types",
},
},
{
"message": "Provided Argument < undefinedArgument > doesn't exist on directive < @deprecated >.",
"path": ["doesKnowCommand", "unknownField2"],
"locations": [{"line": 10, "column": 45}],
"extensions": {
"rule": "5.4.1",
"spec": "June 2018",
"details": "https://graphql.github.io/graphql-spec/June2018/#sec-Argument-Names",
"tag": "argument-names",
},
},
{
"message": "Field unknownField21 doesn't exist on Root",
"path": [
"doesKnowCommand",
"unknownField2",
"unknownField21",
],
"locations": [{"line": 11, "column": 21}],
"extensions": {
"rule": "5.3.1",
"spec": "June 2018",
"details": "https://graphql.github.io/graphql-spec/June2018/#sec-Field-Selections-on-Objects-Interfaces-and-Unions-Types",
"tag": "field-selections-on-objects-interfaces-and-unions-types",
},
},
{
"message": "Directive < @deprecated > is not used in a valid location.",
"path": ["doesKnowCommand", "unknownField2"],
"locations": [
{"line": 10, "column": 19},
{"line": 10, "column": 33},
],
"extensions": {
"rule": "5.7.2",
"spec": "June 2018",
"details": "https://graphql.github.io/graphql-spec/June2018/#sec-Directives-Are-In-Valid-Locations",
"tag": "directives-are-in-valid-locations",
},
},
{
"message": "Field unknownField2 doesn't exist on Boolean",
"path": ["doesKnowCommand", "unknownField2"],
"locations": [{"line": 10, "column": 19}],
"extensions": {
"rule": "5.3.1",
"spec": "June 2018",
"details": "https://graphql.github.io/graphql-spec/June2018/#sec-Field-Selections-on-Objects-Interfaces-and-Unions-Types",
"tag": "field-selections-on-objects-interfaces-and-unions-types",
},
},
{
"message": "Field doesKnowCommand must not have a selection since type Boolean has no subfields.",
"path": ["doesKnowCommand"],
"locations": [{"line": 9, "column": 17}],
"extensions": {
"rule": "5.3.3",
"spec": "June 2018",
"details": "https://graphql.github.io/graphql-spec/June2018/#sec-Leaf-Field-Selections",
"tag": "leaf-field-selections",
},
},
{
"message": "Provided Argument < command > doesn't exist on field < Dog.doesKnowCommand >.",
"path": ["doesKnowCommand"],
"locations": [{"line": 9, "column": 58}],
"extensions": {
"rule": "5.4.1",
"spec": "June 2018",
"details": "https://graphql.github.io/graphql-spec/June2018/#sec-Argument-Names",
"tag": "argument-names",
},
},
{
"message": "Missing mandatory argument < dogCommand > in field < Dog.doesKnowCommand >.",
"path": ["doesKnowCommand"],
"locations": [{"line": 9, "column": 17}],
"extensions": {
"rule": "5.4.2.1",
"spec": "June 2018",
"details": "https://graphql.github.io/graphql-spec/June2018/#sec-Required-Arguments",
"tag": "required-arguments",
},
},
{
"message": "Provided Argument < undefinedArgument > doesn't exist on directive < @deprecated >.",
"path": ["doesKnowCommand"],
"locations": [{"line": 14, "column": 84}],
"extensions": {
"rule": "5.4.1",
"spec": "June 2018",
"details": "https://graphql.github.io/graphql-spec/June2018/#sec-Argument-Names",
"tag": "argument-names",
},
},
{
"message": "Directive < @deprecated > is not used in a valid location.",
"path": ["doesKnowCommand"],
"locations": [
{"line": 14, "column": 17},
{"line": 14, "column": 72},
],
"extensions": {
"rule": "5.7.2",
"spec": "June 2018",
"details": "https://graphql.github.io/graphql-spec/June2018/#sec-Directives-Are-In-Valid-Locations",
"tag": "directives-are-in-valid-locations",
},
},
{
"message": "Field unknownField3 doesn't exist on Dog",
"path": ["unknownField3"],
"locations": [{"line": 20, "column": 15}],
"extensions": {
"rule": "5.3.1",
"spec": "June 2018",
"details": "https://graphql.github.io/graphql-spec/June2018/#sec-Field-Selections-on-Objects-Interfaces-and-Unions-Types",
"tag": "field-selections-on-objects-interfaces-and-unions-types",
},
},
{
"message": "Provided Argument < undefinedArgument > doesn't exist on field < Dog.doesKnowCommand >.",
"path": ["dog", "doesKnowCommand"],
"locations": [{"line": 27, "column": 67}],
"extensions": {
"rule": "5.4.1",
"spec": "June 2018",
"details": "https://graphql.github.io/graphql-spec/June2018/#sec-Argument-Names",
"tag": "argument-names",
},
},
{
"message": "Field unknownField4 doesn't exist on Dog",
"path": ["dog", "unknownField4"],
"locations": [{"line": 29, "column": 17}],
"extensions": {
"rule": "5.3.1",
"spec": "June 2018",
"details": "https://graphql.github.io/graphql-spec/June2018/#sec-Field-Selections-on-Objects-Interfaces-and-Unions-Types",
"tag": "field-selections-on-objects-interfaces-and-unions-types",
},
},
{
"message": "Provided Argument < undefinedArgument > doesn't exist on directive < @deprecated >.",
"path": ["dog", "doesKnowCommand"],
"locations": [{"line": 30, "column": 84}],
"extensions": {
"rule": "5.4.1",
"spec": "June 2018",
"details": "https://graphql.github.io/graphql-spec/June2018/#sec-Argument-Names",
"tag": "argument-names",
},
},
{
"message": "Directive < @deprecated > is not used in a valid location.",
"path": ["dog", "doesKnowCommand"],
"locations": [
{"line": 30, "column": 17},
{"line": 30, "column": 72},
],
"extensions": {
"rule": "5.7.2",
"spec": "June 2018",
"details": "https://graphql.github.io/graphql-spec/June2018/#sec-Directives-Are-In-Valid-Locations",
"tag": "directives-are-in-valid-locations",
},
},
{
"message": "Field unknownField5 doesn't exist on Query",
"path": ["unknownField5"],
"locations": [{"line": 32, "column": 15}],
"extensions": {
"rule": "5.3.1",
"spec": "June 2018",
"details": "https://graphql.github.io/graphql-spec/June2018/#sec-Field-Selections-on-Objects-Interfaces-and-Unions-Types",
"tag": "field-selections-on-objects-interfaces-and-unions-types",
},
},
],
},
),
],
)
async def test_issue105(engine, query, expected):
assert await engine.execute(query) == expected
| 47.088808 | 150 | 0.37138 | 2,587 | 38,707 | 5.552377 | 0.054503 | 0.062657 | 0.061543 | 0.086884 | 0.931287 | 0.925508 | 0.920287 | 0.896686 | 0.887845 | 0.879003 | 0 | 0.042959 | 0.498437 | 38,707 | 821 | 151 | 47.146163 | 0.69692 | 0 | 0 | 0.641141 | 0 | 0.04955 | 0.409087 | 0.046413 | 0 | 0 | 0 | 0 | 0.001502 | 1 | 0 | true | 0 | 0.001502 | 0 | 0.003003 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 1 | 1 | 1 | 1 | 1 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 7 |
051c3c8a157c53d22694edcc0b59ffc051348a9e | 3,011 | py | Python | src/web/modules/ejudge/migrations/0006_auto_20160329_2039.py | fossabot/SIStema | 1427dda2082688a9482c117d0e24ad380fdc26a6 | [
"MIT"
] | 5 | 2018-03-08T17:22:27.000Z | 2018-03-11T14:20:53.000Z | src/web/modules/ejudge/migrations/0006_auto_20160329_2039.py | fossabot/SIStema | 1427dda2082688a9482c117d0e24ad380fdc26a6 | [
"MIT"
] | 263 | 2018-03-08T18:05:12.000Z | 2022-03-11T23:26:20.000Z | src/web/modules/ejudge/migrations/0006_auto_20160329_2039.py | fossabot/SIStema | 1427dda2082688a9482c117d0e24ad380fdc26a6 | [
"MIT"
] | 6 | 2018-03-12T19:48:19.000Z | 2022-01-14T04:58:52.000Z | # -*- coding: utf-8 -*-
from __future__ import unicode_literals
from django.db import models, migrations
import djchoices.choices
class Migration(migrations.Migration):
dependencies = [
('ejudge', '0005_solutioncheckingresult_failed_test'),
]
operations = [
migrations.AlterField(
model_name='solutioncheckingresult',
name='max_possible_score',
field=models.PositiveIntegerField(default=0),
),
migrations.AlterField(
model_name='solutioncheckingresult',
name='result',
field=models.PositiveIntegerField(choices=[(0, 'OK'), (1, 'Compilation error'), (2, 'Run-time error'), (3, 'Time-limit exceeded'), (4, 'Presentation error'), (5, 'Wrong Answer'), (6, 'Check failed'), (12, 'Memory limit exceeded'), (13, 'Security violation'), (14, 'Coding style violation'), (15, 'Wall time-limit exceeded'), (18, 'Skipped'), (100, 'UNKNOWN')], validators=[djchoices.choices.ChoicesValidator({0: 'OK', 1: 'Compilation error', 2: 'Run-time error', 3: 'Time-limit exceeded', 4: 'Presentation error', 5: 'Wrong Answer', 6: 'Check failed', 12: 'Memory limit exceeded', 13: 'Security violation', 14: 'Coding style violation', 15: 'Wall time-limit exceeded', 18: 'Skipped', 100: 'UNKNOWN'})]),
),
migrations.AlterField(
model_name='solutioncheckingresult',
name='score',
field=models.PositiveIntegerField(default=0),
),
migrations.AlterField(
model_name='solutioncheckingresult',
name='time_elapsed',
field=models.FloatField(default=0),
),
migrations.AlterField(
model_name='testcheckingresult',
name='max_possible_score',
field=models.PositiveIntegerField(default=0),
),
migrations.AlterField(
model_name='testcheckingresult',
name='result',
field=models.PositiveIntegerField(choices=[(0, 'OK'), (1, 'Compilation error'), (2, 'Run-time error'), (3, 'Time-limit exceeded'), (4, 'Presentation error'), (5, 'Wrong Answer'), (6, 'Check failed'), (12, 'Memory limit exceeded'), (13, 'Security violation'), (14, 'Coding style violation'), (15, 'Wall time-limit exceeded'), (18, 'Skipped'), (100, 'UNKNOWN')], validators=[djchoices.choices.ChoicesValidator({0: 'OK', 1: 'Compilation error', 2: 'Run-time error', 3: 'Time-limit exceeded', 4: 'Presentation error', 5: 'Wrong Answer', 6: 'Check failed', 12: 'Memory limit exceeded', 13: 'Security violation', 14: 'Coding style violation', 15: 'Wall time-limit exceeded', 18: 'Skipped', 100: 'UNKNOWN'})]),
),
migrations.AlterField(
model_name='testcheckingresult',
name='score',
field=models.PositiveIntegerField(default=0),
),
migrations.AlterField(
model_name='testcheckingresult',
name='time_elapsed',
field=models.FloatField(default=0),
),
]
| 53.767857 | 715 | 0.623713 | 304 | 3,011 | 6.105263 | 0.226974 | 0.084052 | 0.107759 | 0.125 | 0.895474 | 0.895474 | 0.846444 | 0.846444 | 0.778017 | 0.778017 | 0 | 0.038823 | 0.221521 | 3,011 | 55 | 716 | 54.745455 | 0.752986 | 0.006974 | 0 | 0.816327 | 0 | 0 | 0.354418 | 0.042503 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | false | 0 | 0.061224 | 0 | 0.122449 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 1 | 1 | 1 | 1 | 1 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 7 |
052e86010d5f79328fad26481294a45d001428d0 | 4,249 | py | Python | api/barriers/migrations/0087_auto_20200901_1511.py | uktrade/market-access-api | 850a59880f8f62263784bcd9c6b3362e447dbc7a | [
"MIT"
] | null | null | null | api/barriers/migrations/0087_auto_20200901_1511.py | uktrade/market-access-api | 850a59880f8f62263784bcd9c6b3362e447dbc7a | [
"MIT"
] | 51 | 2018-05-31T12:16:31.000Z | 2022-03-08T09:36:48.000Z | api/barriers/migrations/0087_auto_20200901_1511.py | uktrade/market-access-api | 850a59880f8f62263784bcd9c6b3362e447dbc7a | [
"MIT"
] | 2 | 2019-12-24T09:47:42.000Z | 2021-02-09T09:36:51.000Z | # Generated by Django 3.1.1 on 2020-09-01 15:11
import django.contrib.postgres.fields
from django.db import migrations, models
class Migration(migrations.Migration):
dependencies = [
("barriers", "0086_auto_20200827_1445"),
]
operations = [
migrations.AlterField(
model_name="barrierinstance",
name="all_sectors",
field=models.BooleanField(
help_text="boolean to signify that all sectors are affected by this barrier",
null=True,
),
),
migrations.AlterField(
model_name="barrierinstance",
name="caused_by_trading_bloc",
field=models.BooleanField(null=True),
),
migrations.AlterField(
model_name="barrierinstance",
name="companies",
field=models.JSONField(
default=None, help_text="list of companies that are affected", null=True
),
),
migrations.AlterField(
model_name="barrierinstance",
name="is_summary_sensitive",
field=models.BooleanField(
help_text="Does the summary contain sensitive information", null=True
),
),
migrations.AlterField(
model_name="barrierinstance",
name="sectors_affected",
field=models.BooleanField(
help_text="boolean to signify one or more sectors are affected by this barrier",
null=True,
),
),
migrations.AlterField(
model_name="historicalbarrierinstance",
name="all_sectors",
field=models.BooleanField(
help_text="boolean to signify that all sectors are affected by this barrier",
null=True,
),
),
migrations.AlterField(
model_name="historicalbarrierinstance",
name="caused_by_trading_bloc",
field=models.BooleanField(null=True),
),
migrations.AlterField(
model_name="historicalbarrierinstance",
name="commodities_cache",
field=django.contrib.postgres.fields.ArrayField(
base_field=models.JSONField(), default=list, size=None
),
),
migrations.AlterField(
model_name="historicalbarrierinstance",
name="companies",
field=models.JSONField(
default=None, help_text="list of companies that are affected", null=True
),
),
migrations.AlterField(
model_name="historicalbarrierinstance",
name="is_summary_sensitive",
field=models.BooleanField(
help_text="Does the summary contain sensitive information", null=True
),
),
migrations.AlterField(
model_name="historicalbarrierinstance",
name="sectors_affected",
field=models.BooleanField(
help_text="boolean to signify one or more sectors are affected by this barrier",
null=True,
),
),
migrations.AlterField(
model_name="historicalpublicbarrier",
name="all_sectors",
field=models.BooleanField(null=True),
),
migrations.AlterField(
model_name="historicalpublicbarrier",
name="published_versions",
field=models.JSONField(default=dict),
),
migrations.AlterField(
model_name="historicalpublicbarrier",
name="trading_bloc",
field=models.CharField(choices=[], max_length=7, null=True),
),
migrations.AlterField(
model_name="publicbarrier",
name="all_sectors",
field=models.BooleanField(null=True),
),
migrations.AlterField(
model_name="publicbarrier",
name="published_versions",
field=models.JSONField(default=dict),
),
migrations.AlterField(
model_name="publicbarrier",
name="trading_bloc",
field=models.CharField(choices=[], max_length=7, null=True),
),
]
| 34.827869 | 96 | 0.568369 | 366 | 4,249 | 6.456284 | 0.226776 | 0.143885 | 0.179856 | 0.208633 | 0.879391 | 0.879391 | 0.822683 | 0.822683 | 0.721117 | 0.721117 | 0 | 0.011735 | 0.338197 | 4,249 | 121 | 97 | 35.115702 | 0.828592 | 0.010591 | 0 | 0.904348 | 1 | 0 | 0.248215 | 0.068063 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | false | 0 | 0.017391 | 0 | 0.043478 | 0 | 0 | 0 | 0 | null | 0 | 0 | 1 | 1 | 1 | 1 | 1 | 1 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 1 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 9 |
5580766e3c76b0d21f09d524882ad03f652f047e | 7,786 | py | Python | modules/ednet/w2py.py | frankyrumple/smc | 975945ddcff754dd95f2e1a8bd4bf6e43a0f91f6 | [
"MIT"
] | null | null | null | modules/ednet/w2py.py | frankyrumple/smc | 975945ddcff754dd95f2e1a8bd4bf6e43a0f91f6 | [
"MIT"
] | null | null | null | modules/ednet/w2py.py | frankyrumple/smc | 975945ddcff754dd95f2e1a8bd4bf6e43a0f91f6 | [
"MIT"
] | null | null | null | from gluon import *
from gluon import current
from .appsettings import AppSettings
###### Web2PyAPIClass
class W2Py:
def __init__(self):
pass
@staticmethod
def Test():
return "test"
@staticmethod
def SetStudentPassword(user_name, new_password, update_db=True):
db = current.db
ret = True
# Get the auth_user id
rows = db(db.auth_user.username==user_name).select()
for row in rows:
id = row['id']
# Set password in info table
if (update_db == True):
db(db.student_info.account_id==id).update(student_password=new_password)
# Set Web2py password
db(db.auth_user.id==id).update( password=db.auth_user.password.validate(new_password)[0] )
return ret
@staticmethod
def SetFacultyPassword(user_name, new_password, update_db=True):
db = current.db
ret = True
# Get the auth_user id
rows = db(db.auth_user.username==user_name).select()
for row in rows:
id = row['id']
# Set password in info table
if(update_db == True):
db(db.faculty_info.account_id==id).update(faculty_password=new_password)
# Set Web2py password
db(db.auth_user.id==id).update( password=db.auth_user.password.validate(new_password)[0] )
return ret
@staticmethod
def CreateW2PStudentUser(user_name, password, user_email, first_name, last_name, user_ad_quota, user_canvas_quota, row):
db = current.db # Grab the current db object
auth = current.auth # Grab the current auth object
# Load the user if it already exists
user = db(db.student_info.user_id==row.user_id).select().first()
if (user == None):
# User doesn't exist, create it
# Create the new user in web2py
uid = db.auth_user.insert(last_name=last_name,
first_name=first_name,
username=user_name,
password=db.auth_user.password.validate(password)[0],
email=user_email
)
# Put the user in the students group
auth.add_membership('Students', uid)
default_ad_quota = user_ad_quota
default_canvas_quota = user_canvas_quota
# Move the rest of the info in place
db.student_info.insert(
account_id=uid,
user_id= row.user_id,
student_name= row.student_name,
student_password= password,
import_classes= row.import_classes,
program = row.program,
additional_fields= row.additional_fields,
sheet_name= row.sheet_name,
student_guid= row.student_guid,
account_enabled= row.account_enabled,
account_added_on= row.account_updated_on,
account_updated_on= row.account_updated_on,
student_ad_quota = default_ad_quota,
student_canvas_quota = default_canvas_quota
)
pass
else:
# Student exists, update web2py info
db(db.auth_user.id==user.account_id).update(
last_name=last_name,
first_name=first_name,
username=user_name,
# Don't overwrite existing password, GetPasswordForStudent
# Should have returned the current password so this is ok.
password=db.auth_user.password.validate(password)[0],
email=user_email
)
# Update user info
user.update_record(
student_name=row.student_name,
student_password=password,
import_classes=row.import_classes,
program = row.program,
additional_fields=row.additional_fields,
sheet_name=row.sheet_name,
account_enabled=row.account_enabled,
account_updated_on=row.account_updated_on,
student_ad_quota=user_ad_quota,
student_canvas_quota=user_canvas_quota
)
# Make sure the user in the students group
auth.add_membership('Students', user.account_id)
pass
@staticmethod
def CreateW2PFacultyUser(user_name, password, user_email, first_name, last_name, user_ad_quota, user_canvas_quota, row):
db = current.db # Grab the current db object
auth = current.auth # Grab the current auth object
# Load the user if it already exists
user = db(db.faculty_info.user_id==row.user_id).select().first()
if (user == None):
# User doesn't exist, create it
# Create the new user in web2py
uid = db.auth_user.insert(last_name=last_name,
first_name=first_name,
username=user_name,
password=db.auth_user.password.validate(password)[0],
email=user_email
)
# Put the user in the faculty group
auth.add_membership('Faculty', uid)
default_ad_quota = user_ad_quota
default_canvas_quota = user_canvas_quota
# Move the rest of the info in place
db.faculty_info.insert(
account_id=uid,
user_id= row.user_id,
faculty_name= row.faculty_name,
faculty_password= password,
import_classes= row.import_classes,
program = row.program,
additional_fields= row.additional_fields,
sheet_name= row.sheet_name,
faculty_guid= row.faculty_guid,
account_enabled= row.account_enabled,
account_added_on= row.account_updated_on,
account_updated_on= row.account_updated_on,
faculty_ad_quota = default_ad_quota,
faculty_canvas_quota = default_canvas_quota
)
pass
else:
# User exists, update web2py info
db(db.auth_user.id==user.account_id).update(
last_name=last_name,
first_name=first_name,
username=user_name,
# Don't overwrite existing password, GetPasswordForStudent
# Should have returned the current password so this is ok.
password=db.auth_user.password.validate(password)[0],
email=user_email
)
# Update user info
user.update_record(
faculty_name=row.faculty_name,
faculty_password=password,
import_classes=row.import_classes,
program = row.program,
additional_fields=row.additional_fields,
sheet_name=row.sheet_name,
account_enabled=row.account_enabled,
account_updated_on=row.account_updated_on,
faculty_ad_quota=user_ad_quota,
faculty_canvas_quota=user_canvas_quota
)
# Make sure the user in the faculty group
auth.add_membership('Faculty', user.account_id)
pass
###### EndWeb2PyAPIClass
| 40.341969 | 124 | 0.549448 | 836 | 7,786 | 4.849282 | 0.12201 | 0.031574 | 0.034534 | 0.01776 | 0.900839 | 0.871238 | 0.871238 | 0.852985 | 0.852985 | 0.852985 | 0 | 0.003546 | 0.384279 | 7,786 | 192 | 125 | 40.552083 | 0.842094 | 0.130876 | 0 | 0.719424 | 0 | 0 | 0.005651 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0.043165 | false | 0.151079 | 0.05036 | 0.007194 | 0.122302 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 1 | 1 | 1 | 1 | 1 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | 0 | 0 | 8 |
e948031f3e273b4eaa1bb4c562f5f6daf0783ff0 | 10,258 | py | Python | Mainfunction.py | Letmehackyou011/TermuxCmd | 53ba10f99026b58d8cb9a0c91087d04dd609bae8 | [
"MIT"
] | null | null | null | Mainfunction.py | Letmehackyou011/TermuxCmd | 53ba10f99026b58d8cb9a0c91087d04dd609bae8 | [
"MIT"
] | null | null | null | Mainfunction.py | Letmehackyou011/TermuxCmd | 53ba10f99026b58d8cb9a0c91087d04dd609bae8 | [
"MIT"
] | null | null | null | #!/bin/py
pkg install toilet -y
pkg install python -y
print("github:https://github.com/Letmehackyou011")
YouTube:print("https://youtube.com/channel/UCIfCOyewE9Qv7RyqpuIiCwQ")
print("beginner is friendly")
print("Termux all command in second")
print('''
_______ _____ _
|__ __| / ____| | |
| | ___ _ __ _ __ ___ _ ___ _| | _ __ ___ __| |
| |/ _ \ '__| '_ ` _ \| | | \ \/ / | | '_ ` _ \ / _` |
| | __/ | | | | | | | |_| |> <| |____| | | | | | (_| |
|_|\___|_| |_| |_| |_|\__,_/_/\_\\_____|_| |_| |_|\__,_|
by Letmehackyou011
''')
print('''
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
- W | e | l | c | o | m | e | -
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
''')
def print_menu(): Termuxcmd
print "1. Enter the script"
print "2. Exit"
loop=True
While loop:
print_menu() TermuxCmd
choice = input("Enter your choice [1-2]: ")
if choice == 1:
print('''("Command") ("Usage")
cp -v used to prints informative massage
cp -r used to copy any directory
mv -u update-move when source is newer than destination
mv -v to move any directory
ls -n to display UID and GID directory
ls –version to check the version of ls
cd — show last working directory from where we moved
ls -l show file action like – modified, date and time, owner of file, permissions Etc.
ls help show display how to use “ls” command
cp -n no file overwrite
cd ~ move to users home directory from anywhere
mv [file1 name] [new file2 name] move or rename two file at a time
cd – move one directory back from current location
mv [file name] move any file and folder
ls list directory
ls -a list all files including hidden files
pwd it show your current working directory
mv -i interactive prompt before overwrit
wget [url] install tool , apt install wget
git clone [url] install any tools with git clone, apt install git
ls -al formatted listing with hidden files
mv -f force move by overwriting destination files without prompt
ls -i Display number of file or directory
cp copy any file
cd / change to root directory
cd change directory
cd .. change current directory to parent directory
curl -O [url] apt install curl
rm remove or delete files
rm [filename] remove any text files
rmdir [dir name] remove any directory
rm -rf force remove a directory or a folder
rm -r [name] delete a directory called name
apt remove [package name] uninstall / remove a package
touch [file name] create new file
mkdir [name] create a directory or folder
more [file name] output the contents of file
head [file name] output the first 10 line of file
tail -f [file name] output the contents of file as it grows
apt install zip install zip file tool
zip name.zip [file] compress file using this commands
unzip [zip file] to unzip file
ftp launch ftp client from terminal
-p use passive mode
bye terminate current ftp session, exit
ascii set file transfer to ascii protocols
bell bell sound after each command
status shows current status about ftp server
open host open a connection to remote host
remotehelp [cmdname] request help from ftp server
account [password] supply a password required by remote
uname -m used to find the architecture of your device
du display directory space usage
df display disk usages
cal show display calendar
w show display who is currently online
cat /proc/meminfo show memory related information
cat /proc/cpuinfo show cpu information
whoami show your login name
fingure username shows information about user
date show the current date and time
uptime show the system current uptime
man command show manual a command
free display memory and swap usage
kill send signal to process
kill- l list all of the signal that are possible to send with kill
lspci show PCI devices
lsusb show usb devices
apt search [qurey]
pkg search [qurey] find a package
locate [file] find all files with filename
locate [query] find all path names contains a pharse
whereis [command] find location binary /source/man file for a command
which [command] find of an executable
grep pattern [files] searching for pattern in files
grep -r pattern files searching for certain pattern in files
command | grep pattern search for pattern in the output of command
find / -atime40 to find all the files, which are accessed 40 days back
find / -cmin -60 find change files in last 1 hour
find / -type d -name mll find all directories whose name is mll in directory
find . -type f -perm 0777 -print find all tghe files, whose permission are 777
ifconfig shows all configuration a network interface like ip, mac
ifconfig eth0 used view the network setting on the interface eth0
ifconfig wlan0 view the network setting on wlan0
ping [host] to ping host ip and show results
arp check network card & show ip adress
host display specific server
netstat review network connection
nslookup find out DNS related query
tracerout ipadress display number of hops & respone time to get to a remote system and website
whois domain get whois information of domain
telnet [ip address [post] telnet connection
dig domain get DNS information of domain
scp copies file, over a source
uname -a used to display kernal information
whereis app shows possible location for an app
nano [file name] display and edit text files
apt show view package information
append [local-file] remote file append a local file to one on the remote
$ execute a macro''')
elif choice==2:print('''
print -v used to prints informative massage
cp -r used to copy any directory
mv -u update-move when source is newer than destination
mv -v to move any directory
ls -n to display UID and GID directory
ls –version to check the version of ls
cd — show last working directory from where we moved
ls -l show file action like – modified, date and time, owner of file, permissions Etc.
ls help show display how to use “ls” command
cp -n no file overwrite
cd ~ move to users home directory from anywhere
mv [file1 name] [new file2 name] move or rename two file at a time
cd – move one directory back from current location
mv [file name] move any file and folder
ls list directory
ls -a list all files including hidden files
pwd it show your current working directory
mv -i interactive prompt before overwrit
wget [url] install tool , apt install wget
git clone [url] install any tools with git clone, apt install git
ls -al formatted listing with hidden files
mv -f force move by overwriting destination files without prompt
ls -i Display number of file or directory
cp copy any file
cd / change to root directory
cd change directory
cd .. change current directory to parent directory
curl -O [url] apt install curl
rm remove or delete files
rm [filename] remove any text files
rmdir [dir name] remove any directory
rm -rf force remove a directory or a folder
rm -r [name] delete a directory called name
apt remove [package name] uninstall / remove a package
touch [file name] create new file
mkdir [name] create a directory or folder
more [file name] output the contents of file
head [file name] output the first 10 line of file
tail -f [file name] output the contents of file as it grows
apt install zip install zip file tool
zip name.zip [file] compress file using this commands
unzip [zip file] to unzip file
ftp launch ftp client from terminal
-p use passive mode
bye terminate current ftp session, exit
ascii set file transfer to ascii protocols
bell bell sound after each command
status shows current status about ftp server
open host open a connection to remote host
remotehelp [cmdname] request help from ftp server
account [password] supply a password required by remote
uname -m used to find the architecture of your device
du display directory space usage
df display disk usages
cal show display calendar
w show display who is currently online
cat /proc/meminfo show memory related information
cat /proc/cpuinfo show cpu information
whoami show your login name
fingure username shows information about user
date show the current date and time
uptime show the system current uptime
man command show manual a command
free display memory and swap usage
kill send signal to process
kill- l list all of the signal that are possible to send with kill
lspci show PCI devices
lsusb show usb devices
apt search [qurey]
pkg search [qurey] find a package
locate [file] find all files with filename
locate [query] find all path names contains a pharse
whereis [command] find location binary /source/man file for a command
which [command] find of an executable
grep pattern [files] searching for pattern in files
grep -r pattern files searching for certain pattern in files
command | grep pattern search for pattern in the output of command
find / -atime40 to find all the files, which are accessed 40 days back
find / -cmin -60 find change files in last 1 hour
find / -type d -name mll find all directories whose name is mll in directory
find . -type f -perm 0777 -print find all tghe files, whose permission are 777
ifconfig shows all configuration a network interface like ip, mac
ifconfig eth0 used view the network setting on the interface eth0
ifconfig wlan0 view the network setting on wlan0
ping [host] to ping host ip and show results
arp check network card & show ip adress
host display specific server
netstat review network connection
nslookup find out DNS related query
tracerout ipadress display number of hops & respone time to get to a remote system and website
whois domain get whois information of domain
telnet [ip address [post] telnet connection
dig domain get DNS information of domain
scp copies file, over a source
uname -a used to display kernal information
whereis app shows possible location for an app
nano [file name] display and edit text files
apt show view package information
append [local-file] remote file append a local file to one on the remote
$ execute a macro''')
loop=False
else:
raw_input("Wrong input press any key to enter...")
mv -f Readme.md storage/0/Android/com.termux
print("Sometime code was wrong find code wrong in termux press Ctrl+c to exit")
print("NOW OPEN COM.TERMUX FOLDER")
| 40.070313 | 94 | 0.744005 | 1,640 | 10,258 | 4.604268 | 0.215244 | 0.012714 | 0.011124 | 0.013508 | 0.92597 | 0.92597 | 0.92597 | 0.92597 | 0.92597 | 0.92597 | 0 | 0.007214 | 0.202769 | 10,258 | 255 | 95 | 40.227451 | 0.915138 | 0 | 0 | 0.864407 | 0 | 0.021186 | 0.955508 | 0.008293 | 0 | 0 | 0 | 0 | 0 | 0 | null | null | 0.016949 | 0 | null | null | 0.076271 | 0 | 0 | 0 | null | 0 | 0 | 0 | 1 | 1 | 1 | 1 | 1 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 1 | 0 | null | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 9 |
e968377b3aa397c83dc8a20fc97b2a757b7fd6ba | 76 | py | Python | unet/models/__init__.py | nunenuh/unet.pytorch | d14b4c2ccfd9c9bf41ac044bd3d0625637ca9422 | [
"Apache-2.0"
] | null | null | null | unet/models/__init__.py | nunenuh/unet.pytorch | d14b4c2ccfd9c9bf41ac044bd3d0625637ca9422 | [
"Apache-2.0"
] | null | null | null | unet/models/__init__.py | nunenuh/unet.pytorch | d14b4c2ccfd9c9bf41ac044bd3d0625637ca9422 | [
"Apache-2.0"
] | null | null | null | from .unet import *
from .tunnable_unet import *
from .resnet_unet import * | 25.333333 | 28 | 0.763158 | 11 | 76 | 5.090909 | 0.454545 | 0.535714 | 0.5 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0.157895 | 76 | 3 | 29 | 25.333333 | 0.875 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | true | 0 | 1 | 0 | 1 | 0 | 1 | 0 | 0 | null | 1 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 1 | 0 | 1 | 0 | 0 | 7 |
75b04a60c90d4520bb9810f0e13182de3b40a4d3 | 362 | py | Python | examples.py | cripplet/btc-cdn-decode | c87b75f5ed95a932ce44edee4bc1a98ee5ccaed6 | [
"MIT"
] | null | null | null | examples.py | cripplet/btc-cdn-decode | c87b75f5ed95a932ce44edee4bc1a98ee5ccaed6 | [
"MIT"
] | null | null | null | examples.py | cripplet/btc-cdn-decode | c87b75f5ed95a932ce44edee4bc1a98ee5ccaed6 | [
"MIT"
] | null | null | null | import BTCCDN_decode_lib as cdnde
if __name__ == '__main__':
# print cdnde.BTCCDNDownload('1AQmkM5K5RJ9vdGFtwXYQqdazCbB2pofbH').download()
print cdnde.BTCCDNDownload('1AQmkM5K5RJ9vdGFtwXYQqdazCbB2pofbH', txid=['9e7d5b6c5634994bc7d23801debc6d5905c2c14c2d6339170e3283149e12555c']).download()
# cdnde.BTCCDNDownload('1AQmkM5K5RJ9vdGFtwXYQqdazCbB2pofbH').save()
| 51.714286 | 151 | 0.842541 | 25 | 362 | 11.8 | 0.64 | 0.19322 | 0.538983 | 0.39322 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0.175439 | 0.055249 | 362 | 6 | 152 | 60.333333 | 0.687135 | 0.389503 | 0 | 0 | 0 | 0 | 0.486239 | 0.449541 | 0 | 0 | 0 | 0 | 0 | 0 | null | null | 0 | 0.333333 | null | null | 0.333333 | 1 | 0 | 1 | null | 0 | 1 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | null | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | 0 | 8 |
75b621a4bcb3812036c36f3e9251b0ed088a645e | 8,731 | py | Python | sabr.py | Baiwisher/ASP | 0b0549c2b4d41804fc14e255118c60a9a70be1ab | [
"MIT"
] | null | null | null | sabr.py | Baiwisher/ASP | 0b0549c2b4d41804fc14e255118c60a9a70be1ab | [
"MIT"
] | null | null | null | sabr.py | Baiwisher/ASP | 0b0549c2b4d41804fc14e255118c60a9a70be1ab | [
"MIT"
] | null | null | null | # -*- coding: utf-8 -*-
"""
Created on Tue Oct 10
@author: jaehyuk
"""
import numpy as np
import scipy.stats as ss
import scipy.optimize as sopt
import pyfeng as pf
'''
MC model class for Beta=1
'''
class ModelBsmMC:
beta = 1.0 # fixed (not used)
vov, rho = 0.0, 0.0
sigma, intr, divr = None, None, None
bsm_model = None
'''
You may define more members for MC: time step, etc
'''
def __init__(self, sigma, vov=0, rho=0.0, beta=1.0, intr=0, divr=0):
self.sigma = sigma
self.vov = vov
self.rho = rho
self.intr = intr
self.divr = divr
self.bsm_model = pf.Bsm(sigma, intr=intr, divr=divr)
def st_mc(self, spot, texp=None, sigma=None, N_intervals = 100):
t_delte = texp / N_intervals
sigma_sequence = []
sigma_sequence.append(self.sigma)
s_sequence_log = []
s_sequence_log.append(np.log(spot))
for i in range(0,N_intervals):
a = np.random.normal(size=2)
W_1 = a[0]
Z_1 = self.rho * a[0] + np.sqrt(1 - self.rho**2) * a[1]
sigma_sequence.append(sigma_sequence[i]*np.exp(self.vov * np.sqrt(t_delte) \
* Z_1 - 0.5 * self.vov ** 2 * t_delte))
s_sequence_log.append(s_sequence_log[i] + sigma_sequence[i] * np.sqrt(t_delte) \
* W_1 - 0.5 * sigma_sequence[i] ** 2 * t_delte)
sigma_sequence = np.array(sigma_sequence)
s_sequence = np.exp(np.array(s_sequence_log))
return s_sequence[len(s_sequence) - 1]
def price(self, strike, spot, texp=None, sigma=None, cp=1):
'''
Your MC routine goes here
Generate paths for vol and price first. Then get prices (vector) for all strikes
You may fix the random number seed
'''
sample_population = 100000
price_matrix = np.zeros([sample_population,len(strike)])
sigma = sigma if(sigma != None) else self.sigma
for i in range(0,sample_population):
st = np.array([self.st_mc(spot, texp, sigma)] \
* len(strike))
st_strike_delta = np.append([st - strike],[np.zeros(len(strike))], axis = 0)
st_strike = st_strike_delta.max(0)
price_matrix[i] = st_strike
# np.random.seed(12345)
return price_matrix.sum(0) * 1/sample_population
'''
MC model class for Beta=0
'''
class ModelNormalMC:
beta = 0.0 # fixed (not used)
vov, rho = 0.0, 0.0
sigma, intr, divr = None, None, None
normal_model = None
def __init__(self, sigma, vov=0, rho=0.0, beta=0.0, intr=0, divr=0):
self.sigma = sigma
self.vov = vov
self.rho = rho
self.intr = intr
self.divr = divr
self.normal_model = pf.Norm(sigma, intr=intr, divr=divr)
def st_mc(self, spot, texp=None, sigma=None, N_intervals = 100):
t_delte = texp / N_intervals
sigma_sequence = []
sigma_sequence.append(self.sigma)
s_sequence = []
s_sequence.append(spot)
for i in range(0,N_intervals):
a = np.random.normal(size=2)
W_1 = a[0]
Z_1 = self.rho * a[0] + np.sqrt(1 - self.rho**2) * a[1]
sigma_sequence.append(sigma_sequence[i]*np.exp(self.vov * np.sqrt(t_delte) \
* Z_1 - 0.5 * self.vov ** 2 * t_delte))
s_sequence.append(s_sequence[i] + sigma_sequence[i] * np.sqrt(t_delte) * W_1)
sigma_sequence = np.array(sigma_sequence)
s_sequence = np.array(s_sequence)
return s_sequence[len(s_sequence) - 1]
def price(self, strike, spot, texp=None, sigma=None, cp=1):
'''
Your MC routine goes here
Generate paths for vol and price first. Then get prices (vector) for all strikes
You may fix the random number seed
'''
sample_population = 100000
price_matrix = np.zeros([sample_population,len(strike)])
sigma = sigma if(sigma != None) else self.sigma
for i in range(0,sample_population):
st = np.array([self.st_mc(spot, texp, sigma)] \
* len(strike))
st_strike_delta = np.append([st - strike],[np.zeros(len(strike))], axis = 0)
st_strike = st_strike_delta.max(0)
price_matrix[i] = st_strike
# np.random.seed(12345)
return price_matrix.sum(0) * 1/sample_population
'''
Conditional MC model class for Beta=1
'''
class ModelBsmCondMC:
beta = 1.0 # fixed (not used)
vov, rho = 0.0, 0.0
sigma, intr, divr = None, None, None
bsm_model = None
'''
You may define more members for MC: time step, etc
'''
def __init__(self, sigma, vov=0, rho=0.0, beta=1.0, intr=0, divr=0):
self.sigma = sigma
self.vov = vov
self.rho = rho
self.intr = intr
self.divr = divr
self.bsm_model = pf.Bsm(sigma, intr=intr, divr=divr)
def bsm_vol(self, spot, texp, sigma):
''''
should be same as bsm_vol method in ModelBsmMC (just copy & paste)
'''
np.random.seed(123456)
a = np.random.normal(size=[2,100])
Z_1 = a[0]
X_1 = rho * a[0] + np.sqrt(1 - rho**2) * a[1]
t_delte = texp / N_intervals
sigma_sequence = []
sigma_sequence.append(self.sigma)
for i in range(0,N_intervals):
sigma_sequence.append(sigma_sequence[i]*np.exp(self.vov * np.sqrt(t_delte) \
* Z_1 - 0.5 * self.vov ** 2 * t_delte))
sigma_sequence = np.array(sigma_sequence)
return sigma_sequence
def price(self, strike, spot, texp=None, cp=1):
'''
Your MC routine goes here
Generate paths for vol only. Then compute integrated variance and BSM price.
Then get prices (vector) for all strikes
You may fix the random number seed
'''
np.random.seed(123456)
a = np.random.normal(size=[2,100])
Z_1 = a[0]
X_1 = rho * a[0] + np.sqrt(1 - rho**2) * a[1]
sigma_sequence = self.bsm_vol(spot, texp, 1)
I_T = (sigma_sequence ** 2).sum() / 100
sigma_T = 1 * np.exp(self.vov * Z_1[100] - 0.5 * self.vov ** 2 * texp)
s_0 = spot * exp(self.rho / self.vov * (sigma_T - 1) - 0.5 * \
self.rho ** 2 * 1 * texp * I_T)
sigma_BS = 1 * np.sqrt((1 - self.rho ** 2) * I_T)
m_bsm = pf.Bsm(sigma_BS)
price_continuous = m_bsm.price(strike, s_0, texp)
print("check")
return price_continuous
'''
Conditional MC model class for Beta=0
'''
class ModelNormalCondMC:
beta = 0.0 # fixed (not used)
vov, rho = 0.0, 0.0
sigma, intr, divr = None, None, None
normal_model = None
def __init__(self, sigma, vov=0, rho=0.0, beta=0.0, intr=0, divr=0):
self.sigma = sigma
self.vov = vov
self.rho = rho
self.intr = intr
self.divr = divr
self.normal_model = pf.Norm(sigma, intr=intr, divr=divr)
def norm_vol(self, strike, spot, texp=None):
''''
should be same as norm_vol method in ModelNormalMC (just copy & paste)
'''
np.random.seed(123456)
a = np.random.normal(size=[2,100])
Z_1 = a[0]
X_1 = rho * a[0] + np.sqrt(1 - rho**2) * a[1]
t_delte = texp / N_intervals
sigma_sequence = []
sigma_sequence.append(self.sigma)
for i in range(0,N_intervals):
sigma_sequence.append(sigma_sequence[i]*np.exp(self.vov * np.sqrt(t_delte) \
* Z_1 - 0.5 * self.vov ** 2 * t_delte))
sigma_sequence = np.array(sigma_sequence)
return sigma_sequence
def price(self, strike, spot, cp=1):
'''
Your MC routine goes here
Generate paths for vol only. Then compute integrated variance and normal price.
You may fix the random number seed
'''
np.random.seed(123456)
a = np.random.normal(size=[2,100])
Z_1 = a[0]
X_1 = rho * a[0] + np.sqrt(1 - rho**2) * a[1]
sigma_sequence = self.bsm_vol(spot, texp, 1)
I_T = (sigma_sequence ** 2).sum() / 100
sigma_T = 1 * np.exp(self.vov * Z_1[100] - 0.5 * self.vov ** 2 * texp)
s_0 = spot + self.rho / self.vov * (sigma_T - 1)
sigma_N = 1 * np.sqrt((1 - self.rho ** 2) * I_T)
m_norm = pf.Norm(sigma_N)
price_continuous = m_norm.price(strike, s_0, texp)
return price_continuous
| 34.509881 | 92 | 0.553888 | 1,277 | 8,731 | 3.642913 | 0.105717 | 0.092218 | 0.008598 | 0.029665 | 0.874678 | 0.86264 | 0.857911 | 0.826526 | 0.826526 | 0.806105 | 0 | 0.042956 | 0.322758 | 8,731 | 252 | 93 | 34.646825 | 0.743785 | 0.017066 | 0 | 0.807453 | 0 | 0 | 0.000687 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | null | 0 | 0.024845 | null | null | 0.006211 | 0 | 0 | 0 | null | 0 | 0 | 0 | 1 | 1 | 1 | 1 | 1 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 8 |
75d5786451fdffd0407068da3f68d6b6a0d0a915 | 1,679 | py | Python | Lean-Openwhisk-Evaluation/Results/ServerlessBench-Testcase5-Results/DataTransfer_latency.py | razkey23/Serverless-On-Edge | 6b0c09d992204f1f113fc48c3839b0bdf28ecca5 | [
"MIT"
] | 1 | 2022-01-04T04:56:44.000Z | 2022-01-04T04:56:44.000Z | Lean-Openwhisk-Evaluation/Results/ServerlessBench-Testcase5-Results/DataTransfer_latency.py | razkey23/Serverless-On-Edge | 6b0c09d992204f1f113fc48c3839b0bdf28ecca5 | [
"MIT"
] | null | null | null | Lean-Openwhisk-Evaluation/Results/ServerlessBench-Testcase5-Results/DataTransfer_latency.py | razkey23/Serverless-On-Edge | 6b0c09d992204f1f113fc48c3839b0bdf28ecca5 | [
"MIT"
] | null | null | null | import pandas as pd
import matplotlib.pyplot as plt
import numpy as np
files=[0,1024,5120,10240,15360,20480,25600,30720,35840,40960,46080,51200,100000,128000,208000,256000,400000,512000,650000,1000000]
x=["0","1","5","10","15","20","25.6","30","36","41","46","51","100","128","208","256","400","512","650","1000"]
y=[]
for f in files:
l=[]
with open("Result-"+str(f)+".csv", 'rb') as fil:
res=fil.read()
res=res.split('\n')
l=[int(i) for i in res[0:20]]
l = np.array(l)
l = l[(l>np.quantile(l,0.2)) & (l<np.quantile(l,0.85))].tolist()
print(l)
median=sum(l)/len(l)
y.append(median)
temp=[i for i in range(len(files))]
plt.figure(figsize=(9, 6))
plt.plot(temp,y)
plt.xlabel("Payload in KBytes")
plt.ylabel("Latency (ms)")
plt.xticks(temp,x)
plt.title('Payload-Latency')
plt.savefig('Payload_Latency_DataTransfer.png')
plt.clf()
# Plot the low latency Payloads
y=[]
files=[0,1024,5120,10240,15360,20480,25600,30720,35840,40960,46080,51200,100000]
x=["0","1","5","10","15","20","25.6","30","36","41","46","51","100"]
for f in files:
l=[]
with open("Result-"+str(f)+".csv", 'rb') as fil:
res=fil.read()
res=res.split('\n')
l=[int(i) for i in res[0:20]]
l = np.array(l)
l = l[(l>np.quantile(l,0.2)) & (l<np.quantile(l,0.85))].tolist()
print(l)
median=sum(l)/len(l)
y.append(median)
temp=[i for i in range(len(files))]
plt.figure(figsize=(9, 6))
plt.plot(temp,y)
plt.xlabel("Payload in KBytes")
plt.ylabel("Latency (ms)")
plt.xticks(temp,x)
plt.title('Payload-Latency')
plt.savefig('Payload_Latency_DataTransfer_partial.png')
plt.clf() | 30.527273 | 130 | 0.603931 | 295 | 1,679 | 3.420339 | 0.342373 | 0.017839 | 0.019822 | 0.02775 | 0.826561 | 0.826561 | 0.826561 | 0.826561 | 0.826561 | 0.826561 | 0 | 0.180085 | 0.156641 | 1,679 | 55 | 131 | 30.527273 | 0.532486 | 0.017272 | 0 | 0.816327 | 0 | 0 | 0.160097 | 0.043663 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | false | 0 | 0.061224 | 0 | 0.061224 | 0.040816 | 0 | 0 | 0 | null | 0 | 0 | 0 | 1 | 1 | 1 | 1 | 1 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 7 |
75fd9f7acd3e61843ff188e8e075d6a77ff801cf | 250 | py | Python | lilies/compiler/__init__.py | mrz1988/lilies | 9525770fabab7e142ebedc40ab5d0c8027aa90ba | [
"MIT"
] | null | null | null | lilies/compiler/__init__.py | mrz1988/lilies | 9525770fabab7e142ebedc40ab5d0c8027aa90ba | [
"MIT"
] | 51 | 2019-06-18T16:35:56.000Z | 2021-02-23T00:32:23.000Z | lilies/compiler/__init__.py | mrz1988/lilies | 9525770fabab7e142ebedc40ab5d0c8027aa90ba | [
"MIT"
] | null | null | null | from .state_manager import (
get_compiler,
teardown,
nocolor,
compile_all,
colorama,
CustomTerminal,
)
__all__ = [
"get_compiler",
"teardown",
"nocolor",
"compile_all",
"colorama",
"CustomTerminal",
]
| 13.888889 | 28 | 0.6 | 21 | 250 | 6.714286 | 0.571429 | 0.156028 | 0.269504 | 0.368794 | 0.822695 | 0.822695 | 0.822695 | 0.822695 | 0 | 0 | 0 | 0 | 0.28 | 250 | 17 | 29 | 14.705882 | 0.783333 | 0 | 0 | 0 | 0 | 0 | 0.24 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | false | 0 | 0.0625 | 0 | 0.0625 | 0 | 1 | 0 | 0 | null | 0 | 1 | 1 | 1 | 1 | 1 | 1 | 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 | 7 |
f98a40fa51e6eb0d44986040ad2a527897201436 | 140 | py | Python | torch/ao/quantization/fx/backend_config/fuse_handler.py | vuanvin/pytorch | 9267fd8d7395074001ad7cf2a8f28082dbff6b0b | [
"Intel"
] | 5 | 2018-04-24T13:41:12.000Z | 2019-07-09T07:32:09.000Z | torch/ao/quantization/fx/backend_config/fuse_handler.py | vuanvin/pytorch | 9267fd8d7395074001ad7cf2a8f28082dbff6b0b | [
"Intel"
] | 14 | 2021-10-14T06:58:50.000Z | 2021-12-17T11:51:07.000Z | torch/ao/quantization/fx/backend_config/fuse_handler.py | vuanvin/pytorch | 9267fd8d7395074001ad7cf2a8f28082dbff6b0b | [
"Intel"
] | 7 | 2020-08-31T22:49:59.000Z | 2020-09-15T14:29:07.000Z | from ..fusion_patterns import DefaultFuseHandler
# TODO: move DefaultFuseHandler
def get_fuse_handler_cls():
return DefaultFuseHandler
| 23.333333 | 48 | 0.828571 | 15 | 140 | 7.466667 | 0.866667 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0.121429 | 140 | 5 | 49 | 28 | 0.910569 | 0.207143 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0.2 | 0 | 1 | 0.333333 | true | 0 | 0.333333 | 0.333333 | 1 | 0 | 1 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | 0 | 0 | 1 | 0 | 0 | 1 | 1 | 0 | 1 | 1 | 0 | 0 | 0 | 7 |
f9cb3e4b939ec477645aec7547846868afbb1a4c | 4,912 | py | Python | IPL_Match_Simulation/Step3/Step3_4_Program6_Player_vs_Player_Calculate.py | KavyaThani/Cls_IPL_01FB15ECS326 | ba8642596d559a9d0af0bfff2bf2afcfdc937332 | [
"MIT"
] | null | null | null | IPL_Match_Simulation/Step3/Step3_4_Program6_Player_vs_Player_Calculate.py | KavyaThani/Cls_IPL_01FB15ECS326 | ba8642596d559a9d0af0bfff2bf2afcfdc937332 | [
"MIT"
] | null | null | null | IPL_Match_Simulation/Step3/Step3_4_Program6_Player_vs_Player_Calculate.py | KavyaThani/Cls_IPL_01FB15ECS326 | ba8642596d559a9d0af0bfff2bf2afcfdc937332 | [
"MIT"
] | null | null | null | f = open('player_vs_player_Probability3.txt', 'w')
inF = open('player_vs_player_Probability2.txt', 'r')
lines = inF.readlines()
#list4 format is [0's,1's,2's,3's,4's,6's,total_balls]
list4=[0,0,0,0,0,0,0]
counter=0
for i in range(len(lines)):
line1=lines[i]
if i+1 <= len(lines)-1:
line2=lines[i+1]
else :
break
list1=[]
list2=[]
list1=line1.split(',')
list2=line2.split(',')
list1[2]=float(list1[2])
list2[2]=float(list2[2])
#print(list4)
if list1[0]==list2[0]:
if list1[1]==list2[1]:
list4[0]=list4[0]+float(list2[2]) #0
list4[1]=list4[1]+float(list2[3]) #1
list4[2]=list4[2]+float(list2[4]) #2
list4[3]=list4[3]+float(list2[5]) #3
list4[4]=list4[4]+float(list2[6]) #4
list4[5]=list4[5]+float(list2[7]) #6
list4[6]=list4[6]+float(list2[8]) #balls
counter=counter+1
else :
list4[0]=list4[0]+float(list2[2]) #0
list4[1]=list4[1]+float(list2[3]) #1
list4[2]=list4[2]+float(list2[4]) #2
list4[3]=list4[3]+float(list2[5]) #3
list4[4]=list4[4]+float(list2[6]) #4
list4[5]=list4[5]+float(list2[7]) #6
list4[6]=list4[6]+float(list2[8]) #balls
counter=counter+1
#f.write(str(list1[0])+","+str(list1[1])+","+str(list4)+"\n")
list4[0]=float(list4[0])/counter
list4[1]=float(list4[1])/counter
list4[2]=float(list4[2])/counter
list4[3]=float(list4[3])/counter
list4[4]=float(list4[4])/counter
list4[5]=float(list4[5])/counter
list4[6]=int(list4[6])
f.write(str(list1[0])+","+str(list1[1])+","+str(list4[0])+","+str(list4[1])+","+str(list4[2])+","+str(list4[3])+","+str(list4[4])+","+str(list4[5])+","+str(list4[6])+"\n")
list4=[0,0,0,0,0,0,0]
counter=0
else :
list4[0]=list4[0]+float(list2[2]) #0
list4[1]=list4[1]+float(list2[3]) #1
list4[2]=list4[2]+float(list2[4]) #2
list4[3]=list4[3]+float(list2[5]) #3
list4[4]=list4[4]+float(list2[6]) #4
list4[5]=list4[5]+float(list2[7]) #6
list4[6]=list4[6]+float(list2[8]) #balls
counter=counter+1
#f.write(str(list1[0])+","+str(list1[1])+","+str(list4)+"\n")
list4[0]=float(list4[0])/counter
list4[1]=float(list4[1])/counter
list4[2]=float(list4[2])/counter
list4[3]=float(list4[3])/counter
list4[4]=float(list4[4])/counter
list4[5]=float(list4[5])/counter
list4[6]=int(list4[6])
f.write(str(list1[0])+","+str(list1[1])+","+str(list4[0])+","+str(list4[1])+","+str(list4[2])+","+str(list4[3])+","+str(list4[4])+","+str(list4[5])+","+str(list4[6])+"\n")
list4=[0,0,0,0,0,0,0]
counter=0
print(list4)
print(list2)
list3=[]
line3=lines[len(lines)-1]
list3=line3.split(',')
list3[2]=float(list3[2])
#print(list4)
if list3[0]==list2[0]:
if list3[1]==list2[1]:
list4[0]=list4[0]+float(list2[2]) #0
list4[1]=list4[1]+float(list2[3]) #1
list4[2]=list4[2]+float(list2[4]) #2
list4[3]=list4[3]+float(list2[5]) #3
list4[4]=list4[4]+float(list2[6]) #4
list4[5]=list4[5]+float(list2[7]) #6
list4[6]=list4[6]+float(list2[8]) #balls
counter=counter+1
else :
list4[0]=list4[0]+list2[2] #0
list4[1]=list4[1]+list2[3] #1
list4[2]=list4[2]+list2[4] #2
list4[3]=list4[3]+list2[5] #3
list4[4]=list4[4]+list2[6] #4
list4[5]=list4[5]+list2[7] #6
list4[6]=list4[6]+list2[8] #balls
counter=counter+1
#f.write(str(list1[0])+","+str(list1[1])+","+str(list4)+"\n")
list4[0]=float(list4[0])/counter
list4[1]=float(list4[1])/counter
list4[2]=float(list4[2])/counter
list4[3]=float(list4[3])/counter
list4[4]=float(list4[4])/counter
list4[5]=float(list4[5])/counter
list4[6]=int(list4[6])
f.write(str(list1[0])+","+str(list1[1])+","+str(list4[0])+","+str(list4[1])+","+str(list4[2])+","+str(list4[3])+","+str(list4[4])+","+str(list4[5])+","+str(list4[6])+"\n")
list4=[0,0,0,0,0,0,0]
counter=0
else :
list4[0]=list4[0]+float(list2[2]) #0
list4[1]=list4[1]+float(list2[3]) #1
list4[2]=list4[2]+float(list2[4]) #2
list4[3]=list4[3]+float(list2[5]) #3
list4[4]=list4[4]+float(list2[6]) #4
list4[5]=list4[5]+float(list2[7]) #6
list4[6]=list4[6]+float(list2[8]) #balls
counter=counter+1
#f.write(str(list1[0])+","+str(list1[1])+","+str(list4)+"\n")
list4[0]=float(list4[0])/counter
list4[1]=float(list4[1])/counter
list4[2]=float(list4[2])/counter
list4[3]=float(list4[3])/counter
list4[4]=float(list4[4])/counter
list4[5]=float(list4[5])/counter
list4[6]=int(list4[6])
f.write(str(list1[0])+","+str(list1[1])+","+str(list4[0])+","+str(list4[1])+","+str(list4[2])+","+str(list4[3])+","+str(list4[4])+","+str(list4[5])+","+str(list4[6])+"\n")
list4=[0,0,0,0,0,0,0]
counter=0
f.write(str(list1[0])+","+str(list1[1])+","+str(list4[0])+","+str(list4[1])+","+str(list4[2])+","+str(list4[3])+","+str(list4[4])+","+str(list4[5])+","+str(list4[6])+"\n")
f.close()
inF.close()
| 31.088608 | 174 | 0.579397 | 880 | 4,912 | 3.226136 | 0.056818 | 0.109898 | 0.026418 | 0.028179 | 0.854174 | 0.854174 | 0.854174 | 0.814019 | 0.814019 | 0.814019 | 0 | 0.1449 | 0.131718 | 4,912 | 157 | 175 | 31.286624 | 0.52075 | 0.077972 | 0 | 0.729508 | 0 | 0 | 0.027009 | 0.014732 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | false | 0 | 0 | 0 | 0 | 0.016393 | 0 | 0 | 0 | null | 0 | 0 | 0 | 1 | 1 | 1 | 1 | 1 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 7 |
ddd3a7789a544b91a56fe856e4bb2c7fda8e42b4 | 230,958 | py | Python | ruckus_vsz_snmp/RUCKUS-SCG-EVENT-MIB.py | molekuul/check_ruckus_vsz | 57b243a53794b8ab40b049cdd2ae0380d3476ac8 | [
"Apache-2.0"
] | 3 | 2016-09-06T10:23:23.000Z | 2021-04-27T14:37:40.000Z | ruckus_vsz_snmp/RUCKUS-SCG-EVENT-MIB.py | molekuul/check_ruckus_vsz | 57b243a53794b8ab40b049cdd2ae0380d3476ac8 | [
"Apache-2.0"
] | 4 | 2018-06-25T08:45:43.000Z | 2020-10-22T07:26:58.000Z | ruckus_vsz_snmp/RUCKUS-SCG-EVENT-MIB.py | molekuul/check_ruckus_vsz | 57b243a53794b8ab40b049cdd2ae0380d3476ac8 | [
"Apache-2.0"
] | null | null | null | # PySNMP SMI module. Autogenerated from smidump -f python RUCKUS-SCG-EVENT-MIB
# by libsmi2pysnmp-0.1.3
# Python version sys.version_info(major=2, minor=7, micro=11, releaselevel='final', serial=0)
# pylint:disable=C0302
mibBuilder = mibBuilder # pylint:disable=undefined-variable,used-before-assignment
# Imports
(Integer, ObjectIdentifier, OctetString, ) = mibBuilder.importSymbols("ASN1", "Integer", "ObjectIdentifier", "OctetString")
(NamedValues, ) = mibBuilder.importSymbols("ASN1-ENUMERATION", "NamedValues")
(ConstraintsIntersection, ConstraintsUnion, SingleValueConstraint, ValueRangeConstraint, ValueSizeConstraint, ) = mibBuilder.importSymbols("ASN1-REFINEMENT", "ConstraintsIntersection", "ConstraintsUnion", "SingleValueConstraint", "ValueRangeConstraint", "ValueSizeConstraint")
(ruckusEvents, ) = mibBuilder.importSymbols("RUCKUS-ROOT-MIB", "ruckusEvents")
(ModuleCompliance, ObjectGroup, ) = mibBuilder.importSymbols("SNMPv2-CONF", "ModuleCompliance", "ObjectGroup")
(Bits, Integer32, IpAddress, ModuleIdentity, MibIdentifier, NotificationType, MibScalar, MibTable, MibTableRow, MibTableColumn, TimeTicks, Unsigned32, enterprises, ) = mibBuilder.importSymbols("SNMPv2-SMI", "Bits", "Integer32", "IpAddress", "ModuleIdentity", "MibIdentifier", "NotificationType", "MibScalar", "MibTable", "MibTableRow", "MibTableColumn", "TimeTicks", "Unsigned32", "enterprises")
(DisplayString, MacAddress, ) = mibBuilder.importSymbols("SNMPv2-TC", "DisplayString", "MacAddress")
# Objects
ruckusSCGEventMIB = ModuleIdentity((1, 3, 6, 1, 4, 1, 25053, 2, 10)).setRevisions(("2015-08-18 10:00", ))
if mibBuilder.loadTexts:
ruckusSCGEventMIB.setOrganization("Ruckus Wireless, Inc.")
if mibBuilder.loadTexts:
ruckusSCGEventMIB.setContactInfo("Ruckus Wireless, Inc.\n\n350 West Java Dr.\nSunnyvale, CA 94089\nUSA\n\nT: +1 (650) 265-4200\nF: +1 (408) 738-2065\nEMail: info@ruckuswireless.com\nWeb: www.ruckuswireless.com")
if mibBuilder.loadTexts:
ruckusSCGEventMIB.setDescription("Ruckus SCG event objects, including trap OID and trap payload.")
ruckusSCGEventTraps = MibIdentifier((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1))
ruckusSCGEventObjects = MibIdentifier((1, 3, 6, 1, 4, 1, 25053, 2, 10, 2))
ruckusSCGEventDescription = MibScalar((1, 3, 6, 1, 4, 1, 25053, 2, 10, 2, 1), OctetString()).setMaxAccess("notifyonly")
if mibBuilder.loadTexts:
ruckusSCGEventDescription.setDescription("The event's description.")
ruckusSCGClusterName = MibScalar((1, 3, 6, 1, 4, 1, 25053, 2, 10, 2, 2), OctetString()).setMaxAccess("notifyonly")
if mibBuilder.loadTexts:
ruckusSCGClusterName.setDescription("The SCG's cluster name.")
ruckusSCGEventCode = MibScalar((1, 3, 6, 1, 4, 1, 25053, 2, 10, 2, 10), OctetString()).setMaxAccess("notifyonly")
if mibBuilder.loadTexts:
ruckusSCGEventCode.setDescription("The event's code.")
ruckusSCGProcessName = MibScalar((1, 3, 6, 1, 4, 1, 25053, 2, 10, 2, 11), OctetString()).setMaxAccess("notifyonly")
if mibBuilder.loadTexts:
ruckusSCGProcessName.setDescription("The process name.")
ruckusSCGEventCtrlIP = MibScalar((1, 3, 6, 1, 4, 1, 25053, 2, 10, 2, 12), OctetString()).setMaxAccess("notifyonly")
if mibBuilder.loadTexts:
ruckusSCGEventCtrlIP.setDescription("The SCG's node control IP address.")
ruckusSCGEventSeverity = MibScalar((1, 3, 6, 1, 4, 1, 25053, 2, 10, 2, 13), OctetString()).setMaxAccess("notifyonly")
if mibBuilder.loadTexts:
ruckusSCGEventSeverity.setDescription("The event's severity.")
ruckusSCGEventType = MibScalar((1, 3, 6, 1, 4, 1, 25053, 2, 10, 2, 14), OctetString()).setMaxAccess("notifyonly")
if mibBuilder.loadTexts:
ruckusSCGEventType.setDescription("The event's type.")
ruckusSCGEventNodeMgmtIp = MibScalar((1, 3, 6, 1, 4, 1, 25053, 2, 10, 2, 15), OctetString()).setMaxAccess("notifyonly")
if mibBuilder.loadTexts:
ruckusSCGEventNodeMgmtIp.setDescription("The SCG's management IP address.")
ruckusSCGEventNodeName = MibScalar((1, 3, 6, 1, 4, 1, 25053, 2, 10, 2, 16), OctetString()).setMaxAccess("notifyonly")
if mibBuilder.loadTexts:
ruckusSCGEventNodeName.setDescription("The SCG's node name.")
ruckusSCGCPUPerc = MibScalar((1, 3, 6, 1, 4, 1, 25053, 2, 10, 2, 17), OctetString()).setMaxAccess("notifyonly")
if mibBuilder.loadTexts:
ruckusSCGCPUPerc.setDescription("The SCG's CPU usage percent.")
ruckusSCGMemoryPerc = MibScalar((1, 3, 6, 1, 4, 1, 25053, 2, 10, 2, 18), OctetString()).setMaxAccess("notifyonly")
if mibBuilder.loadTexts:
ruckusSCGMemoryPerc.setDescription("The SCG's memory usage percent.")
ruckusSCGDiskPerc = MibScalar((1, 3, 6, 1, 4, 1, 25053, 2, 10, 2, 19), OctetString()).setMaxAccess("notifyonly")
if mibBuilder.loadTexts:
ruckusSCGDiskPerc.setDescription("The SCG's disk usage percent.")
ruckusSCGEventMacAddr = MibScalar((1, 3, 6, 1, 4, 1, 25053, 2, 10, 2, 20), OctetString()).setMaxAccess("notifyonly")
if mibBuilder.loadTexts:
ruckusSCGEventMacAddr.setDescription("The SCG's MAC address.")
ruckusSCGEventFirmwareVersion = MibScalar((1, 3, 6, 1, 4, 1, 25053, 2, 10, 2, 21), OctetString()).setMaxAccess("notifyonly")
if mibBuilder.loadTexts:
ruckusSCGEventFirmwareVersion.setDescription("The SCG's firmware version.")
ruckusSCGEventUpgradedFirmwareVersion = MibScalar((1, 3, 6, 1, 4, 1, 25053, 2, 10, 2, 22), OctetString()).setMaxAccess("notifyonly")
if mibBuilder.loadTexts:
ruckusSCGEventUpgradedFirmwareVersion.setDescription("The SCG's upgrade firmware version.")
ruckusSCGEventAPMacAddr = MibScalar((1, 3, 6, 1, 4, 1, 25053, 2, 10, 2, 23), OctetString()).setMaxAccess("notifyonly")
if mibBuilder.loadTexts:
ruckusSCGEventAPMacAddr.setDescription("The AP's MAC address.")
ruckusSCGEventReason = MibScalar((1, 3, 6, 1, 4, 1, 25053, 2, 10, 2, 24), OctetString()).setMaxAccess("notifyonly")
if mibBuilder.loadTexts:
ruckusSCGEventReason.setDescription("The event's reason.")
ruckusSCGEventAPName = MibScalar((1, 3, 6, 1, 4, 1, 25053, 2, 10, 2, 25), OctetString()).setMaxAccess("notifyonly")
if mibBuilder.loadTexts:
ruckusSCGEventAPName.setDescription("The AP's name.")
ruckusSCGEventAPIP = MibScalar((1, 3, 6, 1, 4, 1, 25053, 2, 10, 2, 26), OctetString()).setMaxAccess("notifyonly")
if mibBuilder.loadTexts:
ruckusSCGEventAPIP.setDescription("The AP's IP address.")
ruckusSCGEventAPLocation = MibScalar((1, 3, 6, 1, 4, 1, 25053, 2, 10, 2, 27), OctetString()).setMaxAccess("notifyonly")
if mibBuilder.loadTexts:
ruckusSCGEventAPLocation.setDescription("The AP's location.")
ruckusSCGEventAPGPSCoordinates = MibScalar((1, 3, 6, 1, 4, 1, 25053, 2, 10, 2, 28), OctetString()).setMaxAccess("notifyonly")
if mibBuilder.loadTexts:
ruckusSCGEventAPGPSCoordinates.setDescription("The AP's GPS coordinates.")
ruckusSCGEventAPDescription = MibScalar((1, 3, 6, 1, 4, 1, 25053, 2, 10, 2, 29), OctetString()).setMaxAccess("notifyonly")
if mibBuilder.loadTexts:
ruckusSCGEventAPDescription.setDescription("The AP's description.")
ruckusSCGEventZoneName = MibScalar((1, 3, 6, 1, 4, 1, 25053, 2, 10, 2, 30), OctetString()).setMaxAccess("notifyonly")
if mibBuilder.loadTexts:
ruckusSCGEventZoneName.setDescription("The zone name.")
ruckusSCGAPModel = MibScalar((1, 3, 6, 1, 4, 1, 25053, 2, 10, 2, 31), OctetString()).setMaxAccess("notifyonly")
if mibBuilder.loadTexts:
ruckusSCGAPModel.setDescription("The AP model")
ruckusSCGConfigAPModel = MibScalar((1, 3, 6, 1, 4, 1, 25053, 2, 10, 2, 32), OctetString()).setMaxAccess("notifyonly")
if mibBuilder.loadTexts:
ruckusSCGConfigAPModel.setDescription("The configured AP model")
ruckusSCGAPConfigID = MibScalar((1, 3, 6, 1, 4, 1, 25053, 2, 10, 2, 33), OctetString()).setMaxAccess("notifyonly")
if mibBuilder.loadTexts:
ruckusSCGAPConfigID.setDescription("The AP's configuration UUID")
ruckusSCGEventTargetZoneName = MibScalar((1, 3, 6, 1, 4, 1, 25053, 2, 10, 2, 34), OctetString()).setMaxAccess("notifyonly")
if mibBuilder.loadTexts:
ruckusSCGEventTargetZoneName.setDescription("The AP's target zone name")
ruckusSCGEventAPIPv6 = MibScalar((1, 3, 6, 1, 4, 1, 25053, 2, 10, 2, 35), OctetString()).setMaxAccess("notifyonly")
if mibBuilder.loadTexts:
ruckusSCGEventAPIPv6.setDescription("The AP's IPv6 address.")
ruckusSCGLBSURL = MibScalar((1, 3, 6, 1, 4, 1, 25053, 2, 10, 2, 38), OctetString()).setMaxAccess("notifyonly")
if mibBuilder.loadTexts:
ruckusSCGLBSURL.setDescription("The LBS server's URL")
ruckusSCGLBSPort = MibScalar((1, 3, 6, 1, 4, 1, 25053, 2, 10, 2, 39), OctetString()).setMaxAccess("notifyonly")
if mibBuilder.loadTexts:
ruckusSCGLBSPort.setDescription("The LBS server's port")
ruckusSCGEventSSID = MibScalar((1, 3, 6, 1, 4, 1, 25053, 2, 10, 2, 40), OctetString()).setMaxAccess("notifyonly")
if mibBuilder.loadTexts:
ruckusSCGEventSSID.setDescription("The WLAN ssid")
ruckusSCGEventRogueMac = MibScalar((1, 3, 6, 1, 4, 1, 25053, 2, 10, 2, 45), OctetString()).setMaxAccess("notifyonly")
if mibBuilder.loadTexts:
ruckusSCGEventRogueMac.setDescription("The rogue MAC Address")
ruckusPrimaryGRE = MibScalar((1, 3, 6, 1, 4, 1, 25053, 2, 10, 2, 46), OctetString()).setMaxAccess("notifyonly")
if mibBuilder.loadTexts:
ruckusPrimaryGRE.setDescription("The primary GRE gateway.")
ruckusSecondaryGRE = MibScalar((1, 3, 6, 1, 4, 1, 25053, 2, 10, 2, 47), OctetString()).setMaxAccess("notifyonly")
if mibBuilder.loadTexts:
ruckusSecondaryGRE.setDescription("The secondary GRE gateway.")
ruckusSoftGREGatewayList = MibScalar((1, 3, 6, 1, 4, 1, 25053, 2, 10, 2, 48), OctetString()).setMaxAccess("notifyonly")
if mibBuilder.loadTexts:
ruckusSoftGREGatewayList.setDescription("The softGRE gateway list. It could be IP address or FQDN and must have only two IPs/DNs separated by semicolon (;).")
ruckusSCGSoftGREGWAddress = MibScalar((1, 3, 6, 1, 4, 1, 25053, 2, 10, 2, 49), OctetString()).setMaxAccess("notifyonly")
if mibBuilder.loadTexts:
ruckusSCGSoftGREGWAddress.setDescription("The softGRE gateway IP address.")
ruckusSCGEventClientMacAddr = MibScalar((1, 3, 6, 1, 4, 1, 25053, 2, 10, 2, 50), OctetString()).setMaxAccess("notifyonly")
if mibBuilder.loadTexts:
ruckusSCGEventClientMacAddr.setDescription("The client's MAC address.")
ruckusSCGDPKey = MibScalar((1, 3, 6, 1, 4, 1, 25053, 2, 10, 2, 80), OctetString()).setMaxAccess("notifyonly")
if mibBuilder.loadTexts:
ruckusSCGDPKey.setDescription("The DP's identifier.")
ruckusSCGDPConfigID = MibScalar((1, 3, 6, 1, 4, 1, 25053, 2, 10, 2, 81), OctetString()).setMaxAccess("notifyonly")
if mibBuilder.loadTexts:
ruckusSCGDPConfigID.setDescription("The DP's configuration ID.")
ruckusSCGDPIP = MibScalar((1, 3, 6, 1, 4, 1, 25053, 2, 10, 2, 82), OctetString()).setMaxAccess("notifyonly")
if mibBuilder.loadTexts:
ruckusSCGDPIP.setDescription("The DP's IP address.")
ruckusSCGDPPacketPoolID = MibScalar((1, 3, 6, 1, 4, 1, 25053, 2, 10, 2, 83), OctetString()).setMaxAccess("notifyonly")
if mibBuilder.loadTexts:
ruckusSCGDPPacketPoolID.setDescription("The DP's packet pool ID.")
ruckusSCGNetworkPortID = MibScalar((1, 3, 6, 1, 4, 1, 25053, 2, 10, 2, 100), OctetString()).setMaxAccess("notifyonly")
if mibBuilder.loadTexts:
ruckusSCGNetworkPortID.setDescription("The network port ID.")
ruckusSCGNetworkInterface = MibScalar((1, 3, 6, 1, 4, 1, 25053, 2, 10, 2, 101), OctetString()).setMaxAccess("notifyonly")
if mibBuilder.loadTexts:
ruckusSCGNetworkInterface.setDescription("The network interface.")
ruckusSCGSwitchStatus = MibScalar((1, 3, 6, 1, 4, 1, 25053, 2, 10, 2, 102), OctetString()).setMaxAccess("notifyonly")
if mibBuilder.loadTexts:
ruckusSCGSwitchStatus.setDescription("The switch status.")
ruckusSCGTemperatureStatus = MibScalar((1, 3, 6, 1, 4, 1, 25053, 2, 10, 2, 120), OctetString()).setMaxAccess("notifyonly")
if mibBuilder.loadTexts:
ruckusSCGTemperatureStatus.setDescription("The temperature status.")
ruckusSCGProcessorId = MibScalar((1, 3, 6, 1, 4, 1, 25053, 2, 10, 2, 121), OctetString()).setMaxAccess("notifyonly")
if mibBuilder.loadTexts:
ruckusSCGProcessorId.setDescription("The processor ID.")
ruckusSCGFanId = MibScalar((1, 3, 6, 1, 4, 1, 25053, 2, 10, 2, 122), OctetString()).setMaxAccess("notifyonly")
if mibBuilder.loadTexts:
ruckusSCGFanId.setDescription("The fan module ID.")
ruckusSCGFanStatus = MibScalar((1, 3, 6, 1, 4, 1, 25053, 2, 10, 2, 123), OctetString()).setMaxAccess("notifyonly")
if mibBuilder.loadTexts:
ruckusSCGFanStatus.setDescription("The fan module status.")
ruckusSCGPsId = MibScalar((1, 3, 6, 1, 4, 1, 25053, 2, 10, 2, 124), OctetString()).setMaxAccess("notifyonly")
if mibBuilder.loadTexts:
ruckusSCGPsId.setDescription("The power supply ID.")
ruckusSCGPsStatus = MibScalar((1, 3, 6, 1, 4, 1, 25053, 2, 10, 2, 125), OctetString()).setMaxAccess("notifyonly")
if mibBuilder.loadTexts:
ruckusSCGPsStatus.setDescription("The power supply status.")
ruckusSCGDrvId = MibScalar((1, 3, 6, 1, 4, 1, 25053, 2, 10, 2, 126), OctetString()).setMaxAccess("notifyonly")
if mibBuilder.loadTexts:
ruckusSCGDrvId.setDescription("The drive ID.")
ruckusSCGDrvStatus = MibScalar((1, 3, 6, 1, 4, 1, 25053, 2, 10, 2, 127), OctetString()).setMaxAccess("notifyonly")
if mibBuilder.loadTexts:
ruckusSCGDrvStatus.setDescription("The drive status.")
ruckusSCGLicenseType = MibScalar((1, 3, 6, 1, 4, 1, 25053, 2, 10, 2, 150), OctetString()).setMaxAccess("notifyonly")
if mibBuilder.loadTexts:
ruckusSCGLicenseType.setDescription("The license type")
ruckusSCGLicenseUsagePerc = MibScalar((1, 3, 6, 1, 4, 1, 25053, 2, 10, 2, 151), OctetString()).setMaxAccess("notifyonly")
if mibBuilder.loadTexts:
ruckusSCGLicenseUsagePerc.setDescription("The license usage percent.")
ruckusSCGLicenseServerName = MibScalar((1, 3, 6, 1, 4, 1, 25053, 2, 10, 2, 152), OctetString()).setMaxAccess("notifyonly")
if mibBuilder.loadTexts:
ruckusSCGLicenseServerName.setDescription("The license server name.")
ruckusSCGIPSecGWAddress = MibScalar((1, 3, 6, 1, 4, 1, 25053, 2, 10, 2, 153), OctetString()).setMaxAccess("notifyonly")
if mibBuilder.loadTexts:
ruckusSCGIPSecGWAddress.setDescription("The secure gateway address.")
ruckusSCGSyslogServerAddress = MibScalar((1, 3, 6, 1, 4, 1, 25053, 2, 10, 2, 154), OctetString()).setMaxAccess("notifyonly")
if mibBuilder.loadTexts:
ruckusSCGSyslogServerAddress.setDescription("The syslog server address.")
ruckusSCGSrcSyslogServerAddress = MibScalar((1, 3, 6, 1, 4, 1, 25053, 2, 10, 2, 155), OctetString()).setMaxAccess("notifyonly")
if mibBuilder.loadTexts:
ruckusSCGSrcSyslogServerAddress.setDescription("The source syslog server address.")
ruckusSCGDestSyslogServerAddress = MibScalar((1, 3, 6, 1, 4, 1, 25053, 2, 10, 2, 156), OctetString()).setMaxAccess("notifyonly")
if mibBuilder.loadTexts:
ruckusSCGDestSyslogServerAddress.setDescription("The destination syslog server address.")
ruckusSCGFtpIp = MibScalar((1, 3, 6, 1, 4, 1, 25053, 2, 10, 2, 200), OctetString()).setMaxAccess("notifyonly")
if mibBuilder.loadTexts:
ruckusSCGFtpIp.setDescription("The FTP server IP address.")
ruckusSCGFtpPort = MibScalar((1, 3, 6, 1, 4, 1, 25053, 2, 10, 2, 201), OctetString()).setMaxAccess("notifyonly")
if mibBuilder.loadTexts:
ruckusSCGFtpPort.setDescription("The FTP server port.")
ruckusSCGSrcProcess = MibScalar((1, 3, 6, 1, 4, 1, 25053, 2, 10, 2, 301), OctetString()).setMaxAccess("notifyonly")
if mibBuilder.loadTexts:
ruckusSCGSrcProcess.setDescription("The source process name.")
ruckusSCGGgsnIp = MibScalar((1, 3, 6, 1, 4, 1, 25053, 2, 10, 2, 302), OctetString()).setMaxAccess("notifyonly")
if mibBuilder.loadTexts:
ruckusSCGGgsnIp.setDescription("The GGSN IP address.")
ruckusSCGGtpcIp = MibScalar((1, 3, 6, 1, 4, 1, 25053, 2, 10, 2, 303), OctetString()).setMaxAccess("notifyonly")
if mibBuilder.loadTexts:
ruckusSCGGtpcIp.setDescription("The GTP IP address.")
ruckusSCGApn = MibScalar((1, 3, 6, 1, 4, 1, 25053, 2, 10, 2, 304), OctetString()).setMaxAccess("notifyonly")
if mibBuilder.loadTexts:
ruckusSCGApn.setDescription("The APN name.")
ruckusSCGUEImsi = MibScalar((1, 3, 6, 1, 4, 1, 25053, 2, 10, 2, 305), OctetString()).setMaxAccess("notifyonly")
if mibBuilder.loadTexts:
ruckusSCGUEImsi.setDescription("The UE IMSI.")
ruckusSCGUEMsisdn = MibScalar((1, 3, 6, 1, 4, 1, 25053, 2, 10, 2, 306), OctetString()).setMaxAccess("notifyonly")
if mibBuilder.loadTexts:
ruckusSCGUEMsisdn.setDescription("The UE MSISDN.")
ruckusSCGAuthSrvrIp = MibScalar((1, 3, 6, 1, 4, 1, 25053, 2, 10, 2, 307), OctetString()).setMaxAccess("notifyonly")
if mibBuilder.loadTexts:
ruckusSCGAuthSrvrIp.setDescription("The authentication server IP address.")
ruckusSCGRadProxyIp = MibScalar((1, 3, 6, 1, 4, 1, 25053, 2, 10, 2, 308), OctetString()).setMaxAccess("notifyonly")
if mibBuilder.loadTexts:
ruckusSCGRadProxyIp.setDescription("The radius proxy IP address.")
ruckusSCGAccSrvrIp = MibScalar((1, 3, 6, 1, 4, 1, 25053, 2, 10, 2, 309), OctetString()).setMaxAccess("notifyonly")
if mibBuilder.loadTexts:
ruckusSCGAccSrvrIp.setDescription("The accounting server IP address.")
ruckusSCGRealm = MibScalar((1, 3, 6, 1, 4, 1, 25053, 2, 10, 2, 310), OctetString()).setMaxAccess("notifyonly")
if mibBuilder.loadTexts:
ruckusSCGRealm.setDescription("The Realm name.")
ruckusSCGCgfSrvrIp = MibScalar((1, 3, 6, 1, 4, 1, 25053, 2, 10, 2, 311), OctetString()).setMaxAccess("notifyonly")
if mibBuilder.loadTexts:
ruckusSCGCgfSrvrIp.setDescription("The CGF IP address.")
ruckusSCGRadSrvrIp = MibScalar((1, 3, 6, 1, 4, 1, 25053, 2, 10, 2, 312), OctetString()).setMaxAccess("notifyonly")
if mibBuilder.loadTexts:
ruckusSCGRadSrvrIp.setDescription("The radius server IP address.")
ruckusSCGCipIp = MibScalar((1, 3, 6, 1, 4, 1, 25053, 2, 10, 2, 313), OctetString()).setMaxAccess("notifyonly")
if mibBuilder.loadTexts:
ruckusSCGCipIp.setDescription("The CIP IP address.")
ruckusSCGPointCode = MibScalar((1, 3, 6, 1, 4, 1, 25053, 2, 10, 2, 314), OctetString()).setMaxAccess("notifyonly")
if mibBuilder.loadTexts:
ruckusSCGPointCode.setDescription("The point code.")
ruckusSCGCongLevel = MibScalar((1, 3, 6, 1, 4, 1, 25053, 2, 10, 2, 315), OctetString()).setMaxAccess("notifyonly")
if mibBuilder.loadTexts:
ruckusSCGCongLevel.setDescription("The level of congestion.")
ruckusSCGSSN = MibScalar((1, 3, 6, 1, 4, 1, 25053, 2, 10, 2, 316), OctetString()).setMaxAccess("notifyonly")
if mibBuilder.loadTexts:
ruckusSCGSSN.setDescription("The SSN.")
ruckusSCGRoutingContext = MibScalar((1, 3, 6, 1, 4, 1, 25053, 2, 10, 2, 317), OctetString()).setMaxAccess("notifyonly")
if mibBuilder.loadTexts:
ruckusSCGRoutingContext.setDescription("The routing context.")
ruckusSCGSrcIP = MibScalar((1, 3, 6, 1, 4, 1, 25053, 2, 10, 2, 318), OctetString()).setMaxAccess("notifyonly")
if mibBuilder.loadTexts:
ruckusSCGSrcIP.setDescription("The source IP address.")
ruckusSCGSrcPort = MibScalar((1, 3, 6, 1, 4, 1, 25053, 2, 10, 2, 319), OctetString()).setMaxAccess("notifyonly")
if mibBuilder.loadTexts:
ruckusSCGSrcPort.setDescription("The source port.")
ruckusSCGDestIP = MibScalar((1, 3, 6, 1, 4, 1, 25053, 2, 10, 2, 320), OctetString()).setMaxAccess("notifyonly")
if mibBuilder.loadTexts:
ruckusSCGDestIP.setDescription("The destination IP address.")
ruckusSCGDestPort = MibScalar((1, 3, 6, 1, 4, 1, 25053, 2, 10, 2, 321), OctetString()).setMaxAccess("notifyonly")
if mibBuilder.loadTexts:
ruckusSCGDestPort.setDescription("The destination port.")
ruckusSCGOperation = MibScalar((1, 3, 6, 1, 4, 1, 25053, 2, 10, 2, 322), OctetString()).setMaxAccess("notifyonly")
if mibBuilder.loadTexts:
ruckusSCGOperation.setDescription("The operation name.")
ruckusSCGHlrInstance = MibScalar((1, 3, 6, 1, 4, 1, 25053, 2, 10, 2, 323), OctetString()).setMaxAccess("notifyonly")
if mibBuilder.loadTexts:
ruckusSCGHlrInstance.setDescription("The HLR instance.")
ruckusSCGUserName = MibScalar((1, 3, 6, 1, 4, 1, 25053, 2, 10, 2, 324), OctetString()).setMaxAccess("notifyonly")
if mibBuilder.loadTexts:
ruckusSCGUserName.setDescription("The user name.")
ruckusSCGPgwIp = MibScalar((1, 3, 6, 1, 4, 1, 25053, 2, 10, 2, 325), OctetString()).setMaxAccess("notifyonly")
if mibBuilder.loadTexts:
ruckusSCGPgwIp.setDescription("The PGW IP address.")
ruckusSCGFileName = MibScalar((1, 3, 6, 1, 4, 1, 25053, 2, 10, 2, 326), OctetString()).setMaxAccess("notifyonly")
if mibBuilder.loadTexts:
ruckusSCGFileName.setDescription("The file name.")
ruckusSCGLDAPSrvrIp = MibScalar((1, 3, 6, 1, 4, 1, 25053, 2, 10, 2, 327), OctetString()).setMaxAccess("notifyonly")
if mibBuilder.loadTexts:
ruckusSCGLDAPSrvrIp.setDescription("The LDAP server IP address.")
ruckusSCGADSrvrIp = MibScalar((1, 3, 6, 1, 4, 1, 25053, 2, 10, 2, 328), OctetString()).setMaxAccess("notifyonly")
if mibBuilder.loadTexts:
ruckusSCGADSrvrIp.setDescription("The AD server IP address.")
ruckusSCGSoftwareName = MibScalar((1, 3, 6, 1, 4, 1, 25053, 2, 10, 2, 329), OctetString()).setMaxAccess("notifyonly")
if mibBuilder.loadTexts:
ruckusSCGSoftwareName.setDescription("The software name.")
ruckusSCGDomainName = MibScalar((1, 3, 6, 1, 4, 1, 25053, 2, 10, 2, 330), OctetString()).setMaxAccess("notifyonly")
if mibBuilder.loadTexts:
ruckusSCGDomainName.setDescription("The domain name.")
ruckusSCGDNATIp = MibScalar((1, 3, 6, 1, 4, 1, 25053, 2, 10, 2, 331), OctetString()).setMaxAccess("notifyonly")
if mibBuilder.loadTexts:
ruckusSCGDNATIp.setDescription("The DNAT server IP address.")
ruckusSCGLMAIp = MibScalar((1, 3, 6, 1, 4, 1, 25053, 2, 10, 2, 400), OctetString()).setMaxAccess("notifyonly")
if mibBuilder.loadTexts:
ruckusSCGLMAIp.setDescription("The LMA IP address.")
# Augmentions
# Notifications
ruckusSCGSystemMiscEventTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 1)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventDescription"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGSystemMiscEventTrap.setDescription("Generic trap triggered by admin specified miscellaneous event. \nThe event severity, event type, event description and event code are enclosed.")
ruckusSCGUpgradeSuccessTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 2)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventNodeName"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventFirmwareVersion"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventMacAddr"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventUpgradedFirmwareVersion"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventNodeMgmtIp"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGUpgradeSuccessTrap.setDescription("Trigger when there is a SCG upgrade success event.\nThe event severity, event type, node name, MAC address, management IP address, firmware version, upgraded firmware version and event code are enclosed.")
ruckusSCGUpgradeFailedTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 3)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventFirmwareVersion"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventUpgradedFirmwareVersion"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGUpgradeFailedTrap.setDescription("Trigger when there is a SCG upgrade failed event.\nThe event severity, event type, firmware version, upgraded firmware version and event code are enclosed.")
ruckusSCGNodeRestartedTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 4)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventMacAddr"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventReason"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventNodeName"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventNodeMgmtIp"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGNodeRestartedTrap.setDescription("Trigger when there is a SCG restarted event.\nThe event severity, event type, node name, MAC address, management IP address, restart reason and event code are enclosed.")
ruckusSCGNodeShutdownTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 5)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventMacAddr"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventNodeMgmtIp"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventNodeName"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGNodeShutdownTrap.setDescription("Trigger when there is a SCG shutdown event.\nThe event severity, event type, node name, MAC address, management IP address and event code are enclosed.")
ruckusSCGCPUUsageThresholdExceededTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 6)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGCPUPerc"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventMacAddr"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventNodeName"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGCPUUsageThresholdExceededTrap.setDescription("Trigger when there is a SCG CPU threshold exceeded event.\nThe event severity, event type, node name, MAC address, CPU usage percent and event code are enclosed.")
ruckusSCGMemoryUsageThresholdExceededTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 7)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGMemoryPerc"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventMacAddr"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventNodeName"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGMemoryUsageThresholdExceededTrap.setDescription("Trigger when there is a SCG memory threshold exceeded event.\nThe event severity, event type, node name, MAC address, memory usage percent and event code are enclosed.")
ruckusSCGDiskUsageThresholdExceededTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 8)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGDiskPerc"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventMacAddr"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventNodeName"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGDiskUsageThresholdExceededTrap.setDescription("Trigger when there is a SCG disk usage threshold exceeded event.\nThe event severity, event type, node name, MAC address, disk usage percent and event code are enclosed.")
ruckusSCGLicenseUsageThresholdExceededTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 19)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGLicenseUsagePerc"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGLicenseType"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGLicenseUsageThresholdExceededTrap.setDescription("Trigger when there is SCG license usage threshold exceeded event.\nThe event severity, event type, license type, license usage percent and event code are enclosed.")
ruckusSCGAPMiscEventTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 20)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPMacAddr"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPDescription"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPName"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventDescription"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPLocation"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPGPSCoordinates"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPIP"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventZoneName"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPIPv6"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGAPMiscEventTrap.setDescription("Generic trap triggered by AP related miscellaneous event. \nThe event severity, event type, AP name, AP MAC address, AP IP address, AP location, AP GPS coordinates, event description, AP description, zone name, event code and AP IPv6 address are enclosed.")
ruckusSCGAPConnectedTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 21)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPMacAddr"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPDescription"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPName"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventReason"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPLocation"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPGPSCoordinates"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPIP"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventZoneName"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPIPv6"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGAPConnectedTrap.setDescription("Trigger when there is an AP connected event.\nThe event severity, event type, AP name, AP MAC address, AP IP address, AP location, AP description, AP GPS coordinates, zone name, join reason, event code and AP IPv6 address are enclosed.")
ruckusSCGAPDeletedTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 22)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPMacAddr"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPDescription"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPName"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPLocation"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPGPSCoordinates"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPIP"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventZoneName"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPIPv6"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGAPDeletedTrap.setDescription("Trigger when there is an AP deleted event.\nThe event severity, event type, AP name, AP MAC address, AP IP address, AP location, AP description, AP GPS coordinates, zone name, event code and AP IPv6 address are enclosed.")
ruckusSCGAPDisconnectedTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 23)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPMacAddr"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPDescription"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPName"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPLocation"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPGPSCoordinates"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPIP"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventZoneName"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPIPv6"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGAPDisconnectedTrap.setDescription("Trigger when there is an AP connection lost event.\nThe event severity, event type, AP name, AP MAC address, AP IP address, AP location, AP description, AP GPS coordinates, zone name, event code and AP IPv6 address are enclosed.")
ruckusSCGAPLostHeartbeatTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 24)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPMacAddr"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPDescription"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPName"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPLocation"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPGPSCoordinates"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPIP"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventZoneName"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPIPv6"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGAPLostHeartbeatTrap.setDescription("Trigger when there is a SCG lost AP heart beat event.\nThe event severity, event type, AP name, AP MAC address, AP IP address, AP location, AP description, AP GPS coordinates, zone name, event code and AP IPv6 address are enclosed.")
ruckusSCGAPRebootTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 25)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPMacAddr"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPDescription"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPName"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventReason"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPLocation"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPGPSCoordinates"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPIP"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventZoneName"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPIPv6"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGAPRebootTrap.setDescription("Trigger when there is an AP reboot event.\nThe event severity, event type, AP name, AP MAC address, AP IP address, AP location, AP description, AP GPS coordinates, zone name, reboot reason, event code and AP IPv6 address are enclosed.")
ruckusSCGCriticalAPConnectedTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 26)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPMacAddr"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPDescription"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPName"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventReason"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPLocation"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPGPSCoordinates"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPIP"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventZoneName"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPIPv6"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGCriticalAPConnectedTrap.setDescription("Trigger when there is a critical AP connected event.\nThe event severity, event type, AP name, AP MAC address, AP IP address, AP location, AP description, AP GPS coordinates, zone name, join reason, event code and AP IPv6 address are enclosed.")
ruckusSCGCriticalAPDisconnectedTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 27)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPMacAddr"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPDescription"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPName"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPLocation"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPGPSCoordinates"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPIP"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventZoneName"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPIPv6"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGCriticalAPDisconnectedTrap.setDescription("Trigger when there is a critical AP connection lost event.\nThe event severity, event type, AP name, AP MAC address, AP IP address, AP location, AP description, AP GPS coordinates, zone name, event code and AP IPv6 address are enclosed.")
ruckusSCGAPRejectedTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 28)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPMacAddr"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPDescription"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPName"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventReason"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPLocation"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPGPSCoordinates"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCtrlIP"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPIP"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventZoneName"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPIPv6"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGAPRejectedTrap.setDescription("Trigger when there is an AP rejected event.\nThe event severity, event type, AP name, AP MAC address, AP IP address, AP location, AP description, AP GPS coordinates, zone name, SCG control IP address, reject reason, event code and AP IPv6 address are enclosed.")
ruckusSCGAPConfUpdateFailedTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 29)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPMacAddr"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGAPConfigID"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPDescription"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPName"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPLocation"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPGPSCoordinates"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPIP"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventZoneName"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPIPv6"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGAPConfUpdateFailedTrap.setDescription("Trigger when there is an AP configuration update failed event.\nThe event severity, event type, AP name, AP MAC address, AP IP address, AP location, AP description, AP GPS coordinates, zone name, configure ID, event code and AP IPv6 address are enclosed.")
ruckusSCGAPConfUpdatedTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 30)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPMacAddr"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGAPConfigID"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPDescription"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPName"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPLocation"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPGPSCoordinates"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPIP"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventZoneName"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPIPv6"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGAPConfUpdatedTrap.setDescription("Trigger when there is an AP configuration updated event. \nThe event severity, event type, AP name, AP MAC address, AP IP address, AP location, AP description, AP GPS coordinates, zone name, configure ID, event code and AP IPv6 address are enclosed.")
ruckusSCGAPSwapOutModelDiffTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 31)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPMacAddr"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPDescription"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGAPModel"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPName"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPLocation"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPGPSCoordinates"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPIP"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventZoneName"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGConfigAPModel"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPIPv6"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGAPSwapOutModelDiffTrap.setDescription("Trigger when there is an AP model is different from imported swap AP model.\nThe event severity, event type, AP name, AP MAC address, AP IP address, AP location, AP description, AP GPS coordinates, zone name,AP mode, configure AP model, event code and AP IPv6 address are enclosed.")
ruckusSCGAPPreProvisionModelDiffTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 32)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPMacAddr"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPDescription"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGAPModel"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPName"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPLocation"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPGPSCoordinates"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPIP"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventZoneName"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGConfigAPModel"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPIPv6"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGAPPreProvisionModelDiffTrap.setDescription("Trigger when there is an AP model is different from imported pre-provision AP model.\nThe event severity, event type, AP name, AP MAC address, AP IP address, AP location, AP description, AP GPS coordinates, zone name,AP mode, configure AP model, event code and AP IPv6 address are enclosed.")
ruckusSCGAPDiscoveryFailTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 33)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPMacAddr"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPDescription"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPName"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPLocation"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPGPSCoordinates"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCtrlIP"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPIP"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventZoneName"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPIPv6"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGAPDiscoveryFailTrap.setDescription("Trigger when there is an AP discovery failed event.\nThe event severity, event type, AP name, AP MAC address, AP IP address, AP location, AP description, AP GPS coordinates, zone name, SCG control IP address, event code and AP IPv6 address are enclosed.")
ruckusSCGAPFirmwareUpdateFailedTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 34)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPMacAddr"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPDescription"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPName"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPLocation"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPGPSCoordinates"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPIP"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventZoneName"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPIPv6"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGAPFirmwareUpdateFailedTrap.setDescription("Trigger when there is an AP firmware update failed event.\nThe event severity, event type, AP name, AP MAC address, AP IP address, AP location, AP description, AP GPS coordinates, zone name, event code and AP IPv6 address are enclosed.")
ruckusSCGAPFirmwareUpdatedTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 35)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPMacAddr"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPDescription"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPName"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPLocation"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPGPSCoordinates"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPIP"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventZoneName"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPIPv6"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGAPFirmwareUpdatedTrap.setDescription("Trigger when there is an AP firmware update success event.\nThe event severity, event type, AP name, AP MAC address, AP IP address, AP location, AP description, AP GPS coordinates, zone name, event code and AP IPv6 address are enclosed.")
ruckusSCGAPWlanOversubscribedTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 36)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPMacAddr"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventZoneName"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPLocation"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPGPSCoordinates"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPDescription"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPName"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPIP"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGAPWlanOversubscribedTrap.setDescription("Trigger when there is an AP WLAN oversubscribed event.\nThe event severity, event type, AP name, AP MAC address, AP IP address, AP location, AP description, AP GPS coordinates, zone name and event code are enclosed.")
ruckusSCGAPFactoryResetTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 37)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPMacAddr"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPDescription"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPName"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPLocation"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPGPSCoordinates"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPIP"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventZoneName"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPIPv6"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGAPFactoryResetTrap.setDescription("Trigger when there is an AP factory reset event.\nThe event severity, event type, AP name, AP MAC address, AP IP address, AP location, AP description, AP GPS coordinates, zone name, event code and AP IPv6 address are enclosed.")
ruckusSCGCableModemDownTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 38)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPMacAddr"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPDescription"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPName"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPLocation"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPGPSCoordinates"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPIP"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventZoneName"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPIPv6"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGCableModemDownTrap.setDescription("Trigger when there is an AP cable modem down event.\nThe event severity, event type, AP name, AP MAC address, AP IP address, AP location, AP description, AP GPS coordinates, zone name, event code and AP IPv6 address are enclosed.")
ruckusSCGCableModemRebootTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 39)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPMacAddr"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPDescription"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPName"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPLocation"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPGPSCoordinates"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPIP"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventZoneName"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPIPv6"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGCableModemRebootTrap.setDescription("Trigger when there is an AP cable modem reboot event.\nThe event severity, event type, AP name, AP MAC address, AP IP address, AP location, AP description, AP GPS coordinates, zone name, event code and AP IPv6 address are enclosed.")
ruckusSCGAPJoinZoneFailedTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 40)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPMacAddr"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPDescription"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPName"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventReason"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPLocation"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPGPSCoordinates"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPIP"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventZoneName"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventTargetZoneName"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPIPv6"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGAPJoinZoneFailedTrap.setDescription("Trigger when there is an AP failed to join to a specify zone event.\nThe event severity, event type, AP name, AP MAC address, AP IP address, AP location, AP description, AP GPS coordinates, zone name, target zone name, failure reason, event code and AP IPv6 address are enclosed.")
ruckusSCGAPManagedTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 41)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPMacAddr"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPDescription"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPName"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPLocation"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPGPSCoordinates"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCtrlIP"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPIP"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventZoneName"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGAPManagedTrap.setDescription("Trigger when there is an AP managed event.\nThe event severity, event type, AP name, AP MAC address, AP IP address, AP location, AP description, AP GPS coordinates, zone name, SCG control IP address and event code are enclosed.")
ruckusSCGCPUUsageThresholdBackToNormalTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 42)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGCPUPerc"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventMacAddr"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventNodeName"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGCPUUsageThresholdBackToNormalTrap.setDescription("Trigger when there is a SCG CPU threshold back to normal event.\nThe event severity, event type, node name, MAC address, CPU usage percent and event code are enclosed.")
ruckusSCGMemoryUsageThresholdBackToNormalTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 43)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGMemoryPerc"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventMacAddr"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventNodeName"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGMemoryUsageThresholdBackToNormalTrap.setDescription("Trigger when there is a SCG memory threshold back to normal event.\nThe event severity, event type, node name, MAC address, memory usage percent and event code are enclosed.")
ruckusSCGDiskUsageThresholdBackToNormalTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 44)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGDiskPerc"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventMacAddr"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventNodeName"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGDiskUsageThresholdBackToNormalTrap.setDescription("Trigger when there is a SCG disk threshold back to normal event.\nThe event severity, event type, node name, MAC address, disk usage percent and event code are enclosed.")
ruckusSCGCableModemUpTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 45)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPMacAddr"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPDescription"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPName"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPLocation"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPGPSCoordinates"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPIP"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventZoneName"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPIPv6"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGCableModemUpTrap.setDescription("Trigger when there is an AP cable modem up event.\nThe event severity, event type, AP name, AP MAC address, AP IP address, AP location, AP description, AP GPS coordinates, zone name, event code and AP IPv6 address are enclosed.")
ruckusSCGAPDiscoverySuccessTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 46)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPMacAddr"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPDescription"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPName"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPLocation"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPGPSCoordinates"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCtrlIP"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPIP"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventZoneName"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPIPv6"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGAPDiscoverySuccessTrap.setDescription("Trigger when there is an AP discovery success event.\nThe event severity, event type, AP name, AP MAC address, AP IP address, AP location, AP description, AP GPS coordinates, zone name, SCG control IP address, event code and AP IPv6 address are enclosed.")
ruckusSCGCMResetByUserTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 47)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPMacAddr"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPDescription"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPName"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventReason"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPLocation"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPGPSCoordinates"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPIP"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventZoneName"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPIPv6"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGCMResetByUserTrap.setDescription("Trigger when there is an AP cable modem soft-rebooted by user event.\nThe event severity, event type, AP name, AP MAC address, AP IP address, AP location, AP description, AP GPS coordinates, zone name, event reason, event code and AP IPv6 address are enclosed.")
ruckusSCGCMResetFactoryByUserTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 48)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPMacAddr"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPDescription"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPName"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventReason"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPLocation"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPGPSCoordinates"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPIP"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventZoneName"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPIPv6"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGCMResetFactoryByUserTrap.setDescription("Trigger when there is an AP cable modem set to factory default by user event.\nThe event severity, event type, AP name, AP MAC address, AP IP address, AP location, AP description, AP GPS coordinates, zone name, event reason, event code and AP IPv6 address are enclosed.")
ruckusSCGSSIDSpoofingRogueAPDetectedTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 50)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPMacAddr"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPGPSCoordinates"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPName"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPLocation"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPDescription"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPIP"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventZoneName"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSSID"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventRogueMac"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPIPv6"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGSSIDSpoofingRogueAPDetectedTrap.setDescription("Trigger when there is an AP detects a rogue AP event.\nThe event severity, event type, rogue AP MAC address, ssid, AP name, AP MAC address, AP IP address, AP location, AP description, AP GPS coordinates, zone name, event code and AP IPv6 address are enclosed.")
ruckusSCGMacSpoofingRogueAPDetectedTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 51)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPMacAddr"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPGPSCoordinates"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPName"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPLocation"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPDescription"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPIP"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventZoneName"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSSID"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventRogueMac"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPIPv6"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGMacSpoofingRogueAPDetectedTrap.setDescription("Trigger when there is an AP detects a rogue AP event.\nThe event severity, event type, rogue AP MAC address, ssid, AP name, AP MAC address, AP IP address, AP location, AP description, AP GPS coordinates, zone name, event code and AP IPv6 address are enclosed.")
ruckusSCGSameNetworkRogueAPDetectedTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 52)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPMacAddr"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPGPSCoordinates"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPName"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPLocation"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPDescription"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPIP"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventZoneName"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSSID"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventRogueMac"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPIPv6"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGSameNetworkRogueAPDetectedTrap.setDescription("Trigger when there is an AP detects a rogue AP which has the same bssid with detect AP event.\nThe event severity, event type, rogue AP MAC address, ssid, AP name, AP MAC address, AP IP address, AP location, AP description, AP GPS coordinates, zone name, event code and AP IPv6 address are enclosed.")
ruckusSCGADHocNetworkRogueAPDetectedTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 53)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPMacAddr"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPGPSCoordinates"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPName"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPLocation"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPDescription"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPIP"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventZoneName"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSSID"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventRogueMac"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPIPv6"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGADHocNetworkRogueAPDetectedTrap.setDescription("Trigger when there is an AP detects a rogue AP which has the same network detecting AP event.\nThe event severity, event type, rogue AP MAC address, ssid, AP name, AP MAC address, AP IP address, AP location, AP description, AP GPS coordinates, zone name and event code are enclosed.")
ruckusSCGMaliciousRogueAPTimeoutTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 54)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPMacAddr"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPDescription"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPName"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPLocation"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPGPSCoordinates"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPIP"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventZoneName"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventRogueMac"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPIPv6"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGMaliciousRogueAPTimeoutTrap.setDescription("Trigger when there is a rogue AP disappears event.\nThe event severity, event type, rogue AP MAC address, AP name, AP MAC address, AP IP address, AP location, AP description, AP GPS coordinates, zone name, event code and AP IPv6 address are enclosed.")
ruckusSCGAPLBSConnectSuccessTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 55)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPMacAddr"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPDescription"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPName"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPLocation"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPGPSCoordinates"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGLBSPort"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPIP"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGLBSURL"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventZoneName"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPIPv6"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGAPLBSConnectSuccessTrap.setDescription("Trigger when there is AP successfully connect to LS event.\nThe event severity, event type,AP name, AP MAC address, AP IP address, AP location, AP description, AP GPS coordinates, zone name, LBS server URL, LBS port, event code and AP IPv6 address are enclosed.")
ruckusSCGAPLBSNoResponsesTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 56)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPMacAddr"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPDescription"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPName"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPLocation"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPGPSCoordinates"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGLBSPort"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPIP"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGLBSURL"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventZoneName"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPIPv6"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGAPLBSNoResponsesTrap.setDescription("Trigger when there is an AP connect to LS no response event.\nThe event severity, event type,AP name, AP MAC address, AP IP address, AP location, AP description, AP GPS coordinates, zone name, LBS server URL, LBS port, event code and AP IPv6 address are enclosed.")
ruckusSCGAPLBSAuthFailedTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 57)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPMacAddr"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPDescription"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPName"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPLocation"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPGPSCoordinates"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGLBSPort"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPIP"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGLBSURL"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventZoneName"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPIPv6"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGAPLBSAuthFailedTrap.setDescription("Trigger when there is an AP connect LS authentication failure event.\nThe event severity, event type,AP name, AP MAC address, AP IP address, AP location, AP description, AP GPS coordinates, zone name, LBS server URL, LBS port, event code and AP IPv6 address are enclosed.")
ruckusSCGAPLBSConnectFailedTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 58)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPMacAddr"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPDescription"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPName"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPLocation"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPGPSCoordinates"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGLBSPort"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPIP"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGLBSURL"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventZoneName"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPIPv6"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGAPLBSConnectFailedTrap.setDescription("Trigger when there is an AP failed connect to LS event.\nThe event severity, event type,AP name, AP MAC address, AP IP address, AP location, AP description, AP GPS coordinates, zone name, LBS server URL, LBS port, event code and AP IPv6 address are enclosed.")
ruckusSCGAPTunnelBuildFailedTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 60)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPMacAddr"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPDescription"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPName"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventReason"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPLocation"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPGPSCoordinates"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPIP"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventZoneName"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGDPIP"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPIPv6"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGAPTunnelBuildFailedTrap.setDescription("Trigger when there is an AP build tunnel failed event.\nThe event severity, event type, AP name, AP MAC address, AP IP address, AP location, AP description, AP GPS coordinates, zone name, SCG DP IP address, failure reason, event code and AP IPv6 address are enclosed.")
ruckusSCGAPTunnelBuildSuccessTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 61)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPMacAddr"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPDescription"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPName"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPLocation"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPGPSCoordinates"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPIP"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventZoneName"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGDPIP"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPIPv6"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGAPTunnelBuildSuccessTrap.setDescription("Trigger when there is an AP build tunnel success event.\nThe event severity, event type, AP name, AP MAC address, AP IP address, AP location, AP description, AP GPS coordinates, zone name, SCG DP IP address, event code and AP IPv6 address are enclosed.")
ruckusSCGAPTunnelDisconnectedTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 62)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPMacAddr"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPDescription"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPName"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventReason"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPLocation"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPGPSCoordinates"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPIP"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventZoneName"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGDPIP"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPIPv6"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGAPTunnelDisconnectedTrap.setDescription("Trigger when there is an AP tunnel disconnected event.\nThe event severity, event type, AP name, AP MAC address, AP IP address, AP location, AP description, AP GPS coordinates, zone name, SCG DP IP address, failure reason, event code and AP IPv6 address are enclosed.")
ruckusSCGAPSoftGRETunnelFailoverPtoSTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 65)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPMacAddr"), ("RUCKUS-SCG-EVENT-MIB", "ruckusPrimaryGRE"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPDescription"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPName"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPLocation"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPGPSCoordinates"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPIP"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventZoneName"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPIPv6"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSecondaryGRE"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGAPSoftGRETunnelFailoverPtoSTrap.setDescription("Trigger when there is an AP softGRE tunnel fails over primary to secondary event.\nThe event severity, event type, AP name, AP MAC address, AP IP address, AP location, AP description, AP GPS coordinates, zone name, primary GRE gateway, secondary GRE gateway, event code and AP IPv6 address are enclosed.")
ruckusSCGAPSoftGRETunnelFailoverStoPTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 66)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPMacAddr"), ("RUCKUS-SCG-EVENT-MIB", "ruckusPrimaryGRE"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPDescription"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPName"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPLocation"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPGPSCoordinates"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPIP"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventZoneName"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPIPv6"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSecondaryGRE"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGAPSoftGRETunnelFailoverStoPTrap.setDescription("Trigger when there is an AP softGRE tunnel fails over secondary to primary event.\nThe event severity, event type, AP name, AP MAC address, AP IP address, AP location, AP description, AP GPS coordinates, zone name, primary GRE gateway, secondary GRE gateway, event code and AP IPv6 address are enclosed.")
ruckusSCGAPSoftGREGatewayNotReachableTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 67)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPMacAddr"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPDescription"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPName"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPLocation"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPGPSCoordinates"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPIP"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventZoneName"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPIPv6"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSoftGREGatewayList"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGAPSoftGREGatewayNotReachableTrap.setDescription("Trigger when there is an AP softGRE gateway not reachable event.\nThe event severity, event type, AP name, AP MAC address, AP IP address, AP location, AP description, AP GPS coordinates, zone name, soft GRE gateway list, event code and AP IPv6 address are enclosed.")
ruckusSCGAPSoftGREGatewayReachableTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 68)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPMacAddr"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPDescription"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPName"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPLocation"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGSoftGREGWAddress"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPGPSCoordinates"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPIP"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventZoneName"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGAPSoftGREGatewayReachableTrap.setDescription("Trigger when there is an AP softGRE gateway reachable event.\nThe event severity, event type, AP name, AP MAC address, AP IP address, AP location, AP description, AP GPS coordinates, zone name, soft GRE gateway IP address and event code are enclosed.")
ruckusSCGDPConfUpdateFailedTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 70)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGDPConfigID"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGDPKey"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGDPConfUpdateFailedTrap.setDescription("Trigger when there is DP configuration update failed event.\nThe event severity, event type, DP's identifier, configuration UUID and event code are enclosed.")
ruckusSCGDPLostHeartbeatTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 71)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGDPKey"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGDPLostHeartbeatTrap.setDescription("Trigger when there is DP lost heart beat event.\nThe event severity, event type, DP's identifier and event code are enclosed.")
ruckusSCGDPDisconnectedTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 72)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCtrlIP"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGDPKey"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGDPDisconnectedTrap.setDescription("Trigger when there is DP disconnected event.\nThe event severity, event code, event type , DP's identifier, SCG control IP address and event code are enclosed.")
ruckusSCGDPPhyInterfaceDownTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 73)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGNetworkPortID"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGDPKey"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGDPPhyInterfaceDownTrap.setDescription("Trigger when there is DP physical interface down event.\nThe event severity, event type, DP's identifier, network port ID and event code are enclosed.")
ruckusSCGDPStatusUpdateFailedTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 74)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGDPKey"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGDPStatusUpdateFailedTrap.setDescription("Trigger when there is DP update status failed event.\nThe event severity, event type, DP's identifier and event code are enclosed.")
ruckusSCGDPStatisticUpdateFaliedTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 75)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGDPKey"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGDPStatisticUpdateFaliedTrap.setDescription("Trigger when there is DP update statistical failed event.\nThe event severity, event type, DP's identifier and event code are enclosed.")
ruckusSCGDPConnectedTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 76)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCtrlIP"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGDPKey"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGDPConnectedTrap.setDescription("Trigger when there is DP connected event.\nThe event severity, event type, DP's identifier, SCG control IP and event code are enclosed.")
ruckusSCGDPPhyInterfaceUpTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 77)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGNetworkPortID"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGDPKey"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGDPPhyInterfaceUpTrap.setDescription("Trigger when there is DP physical interface up event.\nThe event severity, event type, DP's identifier, network port ID and event code are enclosed.")
ruckusSCGDPConfUpdatedTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 78)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGDPConfigID"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGDPKey"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGDPConfUpdatedTrap.setDescription("Trigger when there is DP configuration updated event.\nThe event severity, event type, DP's identifier, configuration UUID and event code are enclosed.")
ruckusSCGDPTunnelTearDownTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 79)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPMacAddr"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGDPKey"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventReason"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGDPTunnelTearDownTrap.setDescription("Trigger when there is DP tear down tunnel event.\nThe event severity, event type, DP's identifier, AP MAC address, event reason and event code are enclosed.")
ruckusSCGDPRebootTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 80)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGDPKey"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGDPRebootTrap.setDescription("Trigger when there is DP reboot event.\nThe event severity, event type, DP's identifier and event code are enclosed.")
ruckusSCGDPAcceptTunnelRequestTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 81)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPMacAddr"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGDPKey"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGDPAcceptTunnelRequestTrap.setDescription("Trigger when there is data plane accepts a tunnel request from the AP event.\nThe event severity, event type, DP's identifier, AP MAC address and event code are enclosed.")
ruckusSCGDPRejectTunnelRequestTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 82)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPMacAddr"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGDPKey"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventReason"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGDPRejectTunnelRequestTrap.setDescription("Trigger occurs where there is data plane rejects a tunnel request from the AP event.\nThe event severity, event type, DP's identifier, AP MAC address, event reason and event code are enclosed.")
ruckusSCGDPSgreGWUnreachableTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 83)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGDPKey"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGSoftGREGWAddress"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGDPSgreGWUnreachableTrap.setDescription("Trigger when there is data plane detects that a core network gateway is unreachable event.\nThe event severity, event type, DP's identifier, core gateway address and event code are enclosed.")
ruckusSCGDPSgreGWReachableTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 84)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGDPKey"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGSoftGREGWAddress"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGDPSgreGWReachableTrap.setDescription("Trigger when there is data plane detects that a core network gateway is reachable event.\nThe event severity, event type, DP's identifier, core gateway address and event code are enclosed.")
ruckusSCGDPTunnelSetUpTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 85)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPMacAddr"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGDPKey"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGDPTunnelSetUpTrap.setDescription("Trigger when there is DP set up tunnel event.\nThe event severity, event type, DP's identifier, AP MAC address and event code are enclosed.")
ruckusSCGDPDiscoverySuccessTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 86)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCtrlIP"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGDPKey"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGDPDiscoverySuccessTrap.setDescription("Trigger when there is a DP discovery success event.\nThe event severity, event type, DP's identifier, SCG control IP address and event code are enclosed.")
ruckusSCGDPDiscoveryFailTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 87)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCtrlIP"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGDPKey"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGDPDiscoveryFailTrap.setDescription("Trigger when there is a DP discovery failed event.\nThe event severity, event type, DP's identifier, SCG control IP address and event code are enclosed.")
ruckusSCGDPSgreGWInactTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 88)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGDPKey"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGSoftGREGWAddress"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGDPSgreGWInactTrap.setDescription("Trigger when there is data plane detects that a core network gateway is inactive event.\nThe event severity, event type, DP's identifier, core gateway address and event code are enclosed.")
ruckusSCGDPSgreGWActTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 89)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGDPKey"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGSoftGREGWAddress"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGDPSgreGWActTrap.setDescription("Trigger when there is data plane detects that a core network gateway is active event.\nThe event severity, event type, DP's identifier, core gateway address and event code are enclosed.")
ruckusSCGDPPktPoolLowTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 90)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGDPPacketPoolID"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGDPKey"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGDPPktPoolLowTrap.setDescription("Trigger when there is data core's packet pool in under low water mark event.\nThe event severity, event type, DP's identifier, DP's packet pool ID and event code are enclosed.")
ruckusSCGDPPktPoolCriticalLowTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 91)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGDPPacketPoolID"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGDPKey"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGDPPktPoolCriticalLowTrap.setDescription("Trigger when there is data core's packet pool in under critical low water mark event.\nThe event severity, event type, DP's identifier, DP's packet pool ID and event code are enclosed.")
ruckusSCGDPPktPoolRecoverTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 92)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGDPPacketPoolID"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGDPKey"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGDPPktPoolRecoverTrap.setDescription("Trigger when there is when data core's packet pool in above high water mark event.\nThe event severity, event type, DP's identifier, DP's packet pool ID and event code are enclosed.")
ruckusSCGDPCoreDeadTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 93)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGDPKey"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGDPCoreDeadTrap.setDescription("Trigger when there is one or more data core dead event.\nThe event severity, event type, DP's identifier and event code are enclosed.")
ruckusSCGDPDeletedTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 94)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGDPKey"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGDPDeletedTrap.setDescription("Trigger when there is a DP is deleted event.\nThe event severity, event type, DP's identifier and event code are enclosed.")
ruckusSCGDPUpgradeStartTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 95)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGDPKey"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGDPUpgradeStartTrap.setDescription("Trigger when there is DP started the upgrade process event.\nThe event severity, event type, DP's identifier and event code are enclosed.")
ruckusSCGDPUpgradingTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 96)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGDPKey"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGDPUpgradingTrap.setDescription("Trigger when there is DP has started to upgrade program and configuration event.\nThe event severity, event type, DP's identifier and event code are enclosed.")
ruckusSCGDPUpgradeSuccessTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 97)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGDPKey"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGDPUpgradeSuccessTrap.setDescription("Trigger when there is DP has been upgraded successfully event.\nThe event severity, event type, DP's identifier and event code are enclosed.")
ruckusSCGDPUpgradeFailedTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 98)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGDPKey"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGDPUpgradeFailedTrap.setDescription("Trigger when there is DP failed to upgrade event.\nThe event severity, event type, DP's identifier and event code are enclosed.")
ruckusSCGClientMiscEventTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 100)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventDescription"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventClientMacAddr"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGClientMiscEventTrap.setDescription("Generic trap triggered by specified client related miscellaneous event. \nThe event severity, event type, client MAC address, event description and event code are enclosed.")
ruckusSCGNodeJoinFailedTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 200)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventMacAddr"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGClusterName"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventNodeName"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGNodeJoinFailedTrap.setDescription("Trigger when there is new node join failed event.\nThe event severity, event type, node name, node MAC address, cluster name and event code are enclosed.")
ruckusSCGNodeRemoveFailedTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 201)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventMacAddr"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGClusterName"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventNodeName"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGNodeRemoveFailedTrap.setDescription("Trigger when there is remove node failed event.\nThe event severity, event type, node name,node MAC address, cluster name and event code are enclosed.")
ruckusSCGNodeOutOfServiceTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 202)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventMacAddr"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGClusterName"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventNodeName"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGNodeOutOfServiceTrap.setDescription("Trigger when there is node out of service event.\nThe event severity, event type, node name,node MAC address, cluster name and event code are enclosed.")
ruckusSCGClusterInMaintenanceStateTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 203)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGClusterName"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGClusterInMaintenanceStateTrap.setDescription("Trigger when there is cluster in maintenance state event.\nThe event severity, event type, cluster name and event code are enclosed.")
ruckusSCGClusterBackupFailedTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 204)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGClusterName"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGClusterBackupFailedTrap.setDescription("Trigger when there is backup cluster failed event.\nThe event severity, event type, cluster name and event code are enclosed.")
ruckusSCGClusterRestoreFailedTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 205)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGClusterName"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGClusterRestoreFailedTrap.setDescription("Trigger when there is restore cluster failed event.\nThe event severity, event type, cluster name and event code are enclosed.")
ruckusSCGClusterAppStoppedTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 206)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventMacAddr"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventNodeName"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGProcessName"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGClusterAppStoppedTrap.setDescription("Trigger when there is cluster application stop event.\nThe event severity, event type, application name, SCG node name, node MAC address and event code are enclosed.")
ruckusSCGNodeBondInterfaceDownTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 207)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventMacAddr"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGNetworkInterface"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventNodeName"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGNodeBondInterfaceDownTrap.setDescription("Trigger when there is node bond interface down event.\nThe event severity, event type, network interface, SCG node name, node MAC address and event code are enclosed.")
ruckusSCGNodePhyInterfaceDownTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 208)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventMacAddr"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGNetworkInterface"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventNodeName"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGNodePhyInterfaceDownTrap.setDescription("Trigger when there is node physical interface down event.\nThe event severity, event type, network interface, SCG node name, node MAC address and event code are enclosed.")
ruckusSCGClusterLeaderChangedTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 209)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventMacAddr"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGClusterName"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventNodeName"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGClusterLeaderChangedTrap.setDescription("Trigger when there is cluster leader changed event.\nThe event severity, event type, SCG node name, node MAC address, cluster name and event code are enclosed.")
ruckusSCGClusterUpgradeSuccessTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 210)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventUpgradedFirmwareVersion"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGClusterName"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventFirmwareVersion"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGClusterUpgradeSuccessTrap.setDescription("Trigger when there is upgrade entire cluster success event.\nThe event severity, event type, cluster name, firmware version, upgraded firmware version and event code are enclosed.")
ruckusSCGNodeBondInterfaceUpTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 211)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventMacAddr"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGNetworkInterface"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventNodeName"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGNodeBondInterfaceUpTrap.setDescription("Trigger when there is node bond interface up event.\nThe event severity, event type, network interface, SCG node name, SCG MAC address and event code are enclosed.")
ruckusSCGNodePhyInterfaceUpTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 212)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventMacAddr"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGNetworkInterface"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventNodeName"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGNodePhyInterfaceUpTrap.setDescription("Trigger when there is node physical interface up event.\nThe event severity, event type,network interface, SCG node name, SCG MAC address and event code are enclosed.")
ruckusSCGClusterBackToInServiceTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 216)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGClusterName"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGClusterBackToInServiceTrap.setDescription("Trigger when there is cluster back to in service event.\nThe event severity, event type, cluster name and event code are enclosed.")
ruckusSCGBackupClusterSuccessTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 217)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGClusterName"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGBackupClusterSuccessTrap.setDescription("Trigger when there is backup cluster success event.\nThe event severity, event type, cluster name and event code are enclosed.")
ruckusSCGNodeJoinSuccessTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 218)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventMacAddr"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGClusterName"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventNodeName"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGNodeJoinSuccessTrap.setDescription("Trigger when there is new node join success event.\nThe event severity, event type, SCG node name, node MAC address, cluster name and event code are enclosed.")
ruckusSCGClusterAppStartTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 219)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventMacAddr"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventNodeName"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGProcessName"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGClusterAppStartTrap.setDescription("Trigger when there is cluster application start event.\nThe event severity, event type, application name, SCG node name, node MAC address and event code are enclosed.")
ruckusSCGNodeRemoveSuccessTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 220)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventMacAddr"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGClusterName"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventNodeName"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGNodeRemoveSuccessTrap.setDescription("Trigger when there is remove node success event.\nThe event severity, event type, SCG node name, node MAC address, cluster name and event code are enclosed.")
ruckusSCGClusterRestoreSuccessTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 221)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventMacAddr"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGClusterName"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventNodeName"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGClusterRestoreSuccessTrap.setDescription("Trigger when there is restore cluster success event.\nThe event severity, event type, SCG node name, node MAC address, cluster name and event code are enclosed.")
ruckusSCGNodeBackToInServiceTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 222)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventMacAddr"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGClusterName"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventNodeName"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGNodeBackToInServiceTrap.setDescription("Trigger when there is node back to in service event.\nThe event severity, event type, SCG node name, node MAC address, cluster name and event code are enclosed.")
ruckusSCGSshTunnelSwitchedTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 223)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventMacAddr"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGClusterName"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventNodeName"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGSwitchStatus"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGSshTunnelSwitchedTrap.setDescription("Trigger when there is SSH tunnel switched event.\nThe event severity, event type, SCG node name, node MAC address, cluster name, switch status and event code are enclosed.")
ruckusSCGClusterCfgBackupStartTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 224)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGClusterName"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGClusterCfgBackupStartTrap.setDescription("Trigger when there is a configuration backup start event.\nThe event severity, event type, cluster name and event code are enclosed.")
ruckusSCGClusterCfgBackupSuccessTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 225)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGClusterName"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGClusterCfgBackupSuccessTrap.setDescription("Trigger when there is a configuration backup success event.\nThe event severity, event type, cluster name and event code are enclosed.")
ruckusSCGClusterCfgBackupFailedTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 226)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGClusterName"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGClusterCfgBackupFailedTrap.setDescription("Trigger when there is a configuration backup failed event.\nThe event severity, event type, cluster name and event code are enclosed.")
ruckusSCGClusterCfgRestoreSuccessTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 227)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGClusterName"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGClusterCfgRestoreSuccessTrap.setDescription("Trigger when there is a configuration restore success event.\nThe event severity, event type, cluster name and event code are enclosed.")
ruckusSCGClusterCfgRestoreFailedTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 228)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGClusterName"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGClusterCfgRestoreFailedTrap.setDescription("Trigger when there is a configuration restore failed event.\nThe event severity, event type, cluster name and event code are enclosed.")
ruckusSCGClusterUploadSuccessTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 229)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGClusterName"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGClusterUploadSuccessTrap.setDescription("Trigger when there is a cluster upload success event.\nThe event severity, event type, cluster name and event code are enclosed.")
ruckusSCGClusterUploadFailedTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 230)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGClusterName"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventReason"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGClusterUploadFailedTrap.setDescription("Trigger when there is a cluster upload failed event.\nThe event severity, event type, cluster name, failure reason and event code are enclosed.")
ruckusSCGClusterOutOfServiceTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 231)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGClusterName"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGClusterOutOfServiceTrap.setDescription("Trigger when there is a cluster out of service event.\nThe event severity, event type, cluster name and event code are enclosed.")
ruckusSCGClusterUploadVDPFirmwareStartTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 232)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGClusterName"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGClusterUploadVDPFirmwareStartTrap.setDescription("Trigger when there is a cluster upload vDP firmware process starts event.\nThe event severity, event type, cluster name and event code are enclosed.")
ruckusSCGClusterUploadVDPFirmwareSuccessTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 233)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGClusterName"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGClusterUploadVDPFirmwareSuccessTrap.setDescription("Trigger when there is a cluster uploaded vDP firmware successfully event.\nThe event severity, event type, cluster name and event code are enclosed.")
ruckusSCGClusterUploadVDPFirmwareFailedTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 234)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGClusterName"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventReason"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGClusterUploadVDPFirmwareFailedTrap.setDescription("Trigger when there is a cluster failed to upload vDP firmware event.\nThe event severity, event type, cluster name, failure reason and event code are enclosed.")
ruckusSCGIpmiVotageTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 250)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGTemperatureStatus"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventMacAddr"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGIpmiVotageTrap.setDescription("Trigger when there is baseboard voltage event.\nThe event severity, event type, temperature status, SCG node MAC address and event code are enclosed.")
ruckusSCGIpmiTempBBTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 251)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGTemperatureStatus"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventMacAddr"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGIpmiTempBBTrap.setDescription("Trigger when there is baseboard temperature event.\nThe event severity, event type, temperature status, SCG node MAC address and event code are enclosed.")
ruckusSCGIpmiTempFPTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 252)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGTemperatureStatus"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventMacAddr"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGIpmiTempFPTrap.setDescription("Trigger when there is front panel temperature event.\nThe event severity, event type, temperature status, SCG node MAC address and event code are enclosed.")
ruckusSCGIpmiTempIOHTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 253)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGTemperatureStatus"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventMacAddr"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGIpmiTempIOHTrap.setDescription("Trigger when there is chip set temperature event. \nThe event severity, event type, temperature status, SCG node MAC address and event code are enclosed.")
ruckusSCGIpmiTempMemPTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 254)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGTemperatureStatus"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGProcessorId"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventMacAddr"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGIpmiTempMemPTrap.setDescription("Trigger when there is processor memory temperature event.\nThe event severity, event type, processor id, temperature status, SCG node MAC address and event code are enclosed.")
ruckusSCGIpmiTempPSTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 255)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGTemperatureStatus"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventMacAddr"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGPsId"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGIpmiTempPSTrap.setDescription("Trigger when there is power supply temperature event.\nThe event severity, event type, SCG node name,power supply id, temperature status, SCG node MAC address and event code are enclosed.")
ruckusSCGIpmiTempPTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 256)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGTemperatureStatus"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGProcessorId"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventMacAddr"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGIpmiTempPTrap.setDescription("Trigger when there is processor temperature event.\nThe event severity, event type, processor id, temperature status, SCG node MAC address and event code are enclosed.")
ruckusSCGIpmiTempHSBPTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 257)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGTemperatureStatus"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventMacAddr"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGIpmiTempHSBPTrap.setDescription("Trigger when there is hot swap backplane temperature event.\nThe event severity, event type, temperature status, SCG node MAC address and event code are enclosed.")
ruckusSCGIpmiFanTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 258)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventMacAddr"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGFanStatus"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGFanId"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGIpmiFanTrap.setDescription("Trigger when there is system fan event.\nThe event severity, event type, fan id, fan status, SCG node MAC address and event code are enclosed.")
ruckusSCGIpmiPowerTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 259)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventMacAddr"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGPsStatus"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGPsId"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGIpmiPowerTrap.setDescription("Trigger when there is power supply input event.\nThe event severity, event type, power supply id, power supply status, SCG node MAC address and event code are enclosed.")
ruckusSCGIpmiCurrentTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 260)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventMacAddr"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGPsStatus"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGPsId"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGIpmiCurrentTrap.setDescription("Trigger when there is current power supply output event.\nThe event severity, event type, power supply id, power supply status, SCG node MAC address and event code are enclosed.")
ruckusSCGIpmiFanStatusTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 261)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventMacAddr"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGFanStatus"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGFanId"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGIpmiFanStatusTrap.setDescription("Trigger when there is fan module event.\nThe event severity, event type, fan id, fan status, SCG node MAC address and event code are enclosed.")
ruckusSCGIpmiPsStatusTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 262)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventMacAddr"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGPsStatus"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGPsId"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGIpmiPsStatusTrap.setDescription("Trigger when there is power supply event.\nThe event severity, event type, power supply id, power supply status, SCG node MAC address and event code are enclosed.")
ruckusSCGIpmiDrvStatusTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 263)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGDrvStatus"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventMacAddr"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGDrvId"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGIpmiDrvStatusTrap.setDescription("Trigger when there is disk drive event.\nThe event severity, event type, disk drive id, disk drive status, SCG node MAC address and event code are enclosed.")
ruckusSCGIpmiREVotageTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 264)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGTemperatureStatus"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventMacAddr"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGIpmiREVotageTrap.setDescription("Trigger when there is voltage status recover from abnormal condition event.\nThe event severity, event type, temperature status, SCG node MAC address and event code are enclosed.")
ruckusSCGIpmiRETempBBTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 265)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGTemperatureStatus"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventMacAddr"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGIpmiRETempBBTrap.setDescription("Trigger when there is baseboard temperature status recover from abnormal condition event.\nThe event severity, event type, temperature status, SCG node MAC address and event code are enclosed.")
ruckusSCGIpmiRETempFPTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 266)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGTemperatureStatus"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventMacAddr"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGIpmiRETempFPTrap.setDescription("Trigger when there is front panel temperature status recover from abnormal condition event.\nThe event severity, event type, temperature status, SCG node MAC address and event code are enclosed.")
ruckusSCGIpmiRETempIOHTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 267)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGTemperatureStatus"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventMacAddr"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGIpmiRETempIOHTrap.setDescription("Trigger when there is chip set temperature status recover from abnormal condition event. \nThe event severity, event type, temperature status, SCG node MAC address and event code are enclosed.")
ruckusSCGIpmiRETempMemPTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 268)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGTemperatureStatus"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGProcessorId"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventMacAddr"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGIpmiRETempMemPTrap.setDescription("Trigger when there is processor memory temperature status recover from abnormal condition event.\nThe event severity, event type, processor id, temperature status, SCG node MAC address and event code are enclosed.")
ruckusSCGIpmiRETempPSTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 269)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGTemperatureStatus"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventMacAddr"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGPsId"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGIpmiRETempPSTrap.setDescription("Trigger when there is power supply temperature status recover from abnormal condition event.\nThe event severity, event type, SCG node name,power supply id, temperature status, SCG node MAC address and event code are enclosed.")
ruckusSCGIpmiRETempPTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 270)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGTemperatureStatus"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGProcessorId"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventMacAddr"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGIpmiRETempPTrap.setDescription("Trigger when there is processor temperature status recover from abnormal condition event.\nThe event severity, event type, processor id, temperature status, SCG node MAC address and event code are enclosed.")
ruckusSCGIpmiRETempHSBPTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 271)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGTemperatureStatus"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventMacAddr"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGIpmiRETempHSBPTrap.setDescription("Trigger when there is hot swap backplane temperature status recover from abnormal condition event.\nThe event severity, event type, temperature status, SCG node MAC address and event code are enclosed.")
ruckusSCGIpmiREFanTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 272)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventMacAddr"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGFanStatus"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGFanId"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGIpmiREFanTrap.setDescription("Trigger when there is system fan module status recover from abnormal condition.\nThe event severity, event type, fan id, fan status, SCG node MAC address and event code are enclosed.")
ruckusSCGIpmiREPowerTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 273)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventMacAddr"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGPsStatus"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGPsId"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGIpmiREPowerTrap.setDescription("Trigger when there is power supply AC power input status recover from abnormal condition event.\nThe event severity, event type, power supply id, power supply status, SCG node MAC address and event code are enclosed.")
ruckusSCGIpmiRECurrentTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 274)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventMacAddr"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGPsStatus"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGPsId"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGIpmiRECurrentTrap.setDescription("Trigger when there is power supply and the maximum voltage output status recover from abnormal condition event.\nThe event severity, event type, power supply id, power supply status, SCG node MAC address and event code are enclosed.")
ruckusSCGIpmiREFanStatusTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 275)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventMacAddr"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGFanStatus"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGFanId"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGIpmiREFanStatusTrap.setDescription("Trigger when there is fan module status recover from abnormal condition event.\nThe event severity, event type, fan id, fan status, SCG node MAC address and event code are enclosed.")
ruckusSCGIpmiREPsStatusTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 276)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventMacAddr"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGPsStatus"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGPsId"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGIpmiREPsStatusTrap.setDescription("Trigger when there is power supply status recover from abnormal condition event.\nThe event severity, event type, power supply id, power supply status, SCG node MAC address and event code are enclosed.")
ruckusSCGIpmiREDrvStatusTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 277)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGDrvStatus"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventMacAddr"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGDrvId"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGIpmiREDrvStatusTrap.setDescription("Trigger when there is disk drive status recover from abnormal condition event.\nThe event severity, event type, disk drive id, disk drive status, SCG node MAC address and event code are enclosed.")
ruckusSCGFtpTransferErrorTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 280)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGFtpIp"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGFileName"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventMacAddr"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGFtpPort"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGFtpTransferErrorTrap.setDescription("Trigger when there is FTP transfer error event.\nThe event severity, event type, FTP server IP address, FTP server port, file name, SCG node MAC address and event code are enclosed.")
ruckusSCGSystemLBSConnectSuccessTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 290)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventMacAddr"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventNodeMgmtIp"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGLBSPort"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGLBSURL"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGSystemLBSConnectSuccessTrap.setDescription("Trigger when there is SCG successfully connect to LS event.\nThe event severity, event type, SCG node MAC address, management IP address, LBS server URL, LBS port and event code are enclosed.")
ruckusSCGSystemLBSNoResponseTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 291)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventMacAddr"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventNodeMgmtIp"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGLBSPort"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGLBSURL"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGSystemLBSNoResponseTrap.setDescription("Trigger when there is SCG connect to LS no response event.\nThe event severity, event type, SCG node MAC address, management IP address, LBS server URL, LBS port and event code are enclosed.")
ruckusSCGSystemLBSAuthFailedTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 292)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventMacAddr"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventNodeMgmtIp"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGLBSPort"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGLBSURL"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGSystemLBSAuthFailedTrap.setDescription("Trigger when there is SCG connect LS authentication failure event.\nThe event severity, event type, SCG node MAC address, management IP address, LBS server URL, LBS port and event code are enclosed.")
ruckusSCGSystemLBSConnectFailedTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 293)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventMacAddr"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventNodeMgmtIp"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGLBSPort"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGLBSURL"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGSystemLBSConnectFailedTrap.setDescription("Trigger when there is SCG failed connect to LS event.\nThe event severity, event type, SCG node MAC address, management IP address, LBS server URL, LBS port and event code are enclosed.")
ruckusSCGProcessRestartTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 300)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventMacAddr"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventNodeMgmtIp"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGProcessName"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGProcessRestartTrap.setDescription("Trigger when there is process restart event.\nThe event severity, event type, process name, SCG node MAC address, management IP address and event code are enclosed.")
ruckusSCGServiceUnavailableTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 301)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventMacAddr"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventNodeMgmtIp"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGProcessName"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGServiceUnavailableTrap.setDescription("Trigger when there is service unavailable event.\nThe event severity, event type, process name, SCG node MAC address, management IP address and event code are enclosed.")
ruckusSCGKeepAliveFailureTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 302)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventMacAddr"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventNodeMgmtIp"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGSrcProcess"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGProcessName"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGKeepAliveFailureTrap.setDescription("Trigger when there is service keep alive failure event.\nThe event severity, event type, source process name, process name, SCG node MAC address, management IP address and event code are enclosed.")
ruckusSCGResourceUnavailableTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 304)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventMacAddr"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventReason"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGSrcProcess"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventNodeMgmtIp"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGResourceUnavailableTrap.setDescription("Trigger when there is resource unavailable event.\nThe event severity, event type, source process name, SCG node MAC address, management IP address, reason and event code are enclosed.")
ruckusSCGSmfRegFailedTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 305)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventMacAddr"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventNodeMgmtIp"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGSrcProcess"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGSmfRegFailedTrap.setDescription("Trigger when there is SMF registration failed event.\nThe event severity, event type, source process name, SCG node MAC address, management IP address and event code are enclosed.")
ruckusSCGHipFailoverTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 306)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventMacAddr"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventNodeMgmtIp"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGSrcProcess"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGHipFailoverTrap.setDescription("Trigger when there is HIP failover event.\nThe event severity, event type, source process name, SCG node MAC address, management IP address and event code are enclosed.")
ruckusSCGConfUpdFailedTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 307)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventMacAddr"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventReason"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventNodeMgmtIp"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGProcessName"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGConfUpdFailedTrap.setDescription("Trigger when there is configuration update failed event.\nThe event severity, event type, process name, SCG node MAC address, management IP address, failure reason and event code are enclosed.")
ruckusSCGConfRcvFailedTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 308)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventMacAddr"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventReason"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventNodeMgmtIp"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGConfRcvFailedTrap.setDescription("Trigger when there is SCG configuration receive failed event.\nThe event severity, event type, SCG node MAC address, management IP address, failure reason and event code are enclosed.")
ruckusSCGLostCnxnToDbladeTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 309)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventMacAddr"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventNodeMgmtIp"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGDPIP"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCtrlIP"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGLostCnxnToDbladeTrap.setDescription("Trigger when there is lost connection to DP event.\nThe event severity, event type, SCG control IP address, DP IP address, SCG node MAC address, management IP address and event code are enclosed.")
ruckusSCGGgsnRestartedTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 310)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGGtpcIp"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventMacAddr"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventNodeMgmtIp"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGGgsnIp"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGGgsnRestartedTrap.setDescription("Trigger when there is GGSN restarted event.\nThe event severity, event type, GGSN IP address, GTP IP address, SCG node MAC address, management IP address and event code are enclosed.")
ruckusSCGGgsnNotReachableTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 311)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGGtpcIp"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventMacAddr"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGGgsnIp"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGGgsnNotReachableTrap.setDescription("Trigger when there is GGSN not reachable event.\nThe event severity, event type, GGSN IP address, GTP IP address, SCG node MAC address and event code are enclosed.")
ruckusSCGGgsnNotResolvedTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 312)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventMacAddr"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGUEImsi"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGUEMsisdn"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGApn"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGGgsnNotResolvedTrap.setDescription("Trigger when there is GGSN not resolved event.\nThe event severity, event type, APN, UE IMSI, UE msisdn, SCG node MAC address and event code are enclosed.")
ruckusSCGUnknownUETrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 313)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventMacAddr"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGUEMsisdn"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventNodeMgmtIp"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventClientMacAddr"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGUnknownUETrap.setDescription("Trigger when there is unknown UE event.\nThe event severity, event type, client MAC address, UE msisdn, SCG node MAC address, management IP address and event code are enclosed.")
ruckusSCGAuthSrvrNotReachableTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 314)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventMacAddr"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGAuthSrvrIp"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventNodeMgmtIp"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGRadProxyIp"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGAuthSrvrNotReachableTrap.setDescription("Trigger when there is authentication server not reachable event.\nThe event severity, event type, authentication server IP address, radius proxy IP address, SCG node MAC address, management IP address and event code are enclosed.")
ruckusSCGAccSrvrNotReachableTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 315)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGAccSrvrIp"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventMacAddr"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventNodeMgmtIp"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGRadProxyIp"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGAccSrvrNotReachableTrap.setDescription("Trigger when there is accounting server not reachable event.\nThe event severity, event type, accounting server IP address, radius proxy IP address, SCG node MAC address, management IP address and event code are enclosed.")
ruckusSCGUnknownRealmTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 316)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventMacAddr"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGRealm"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGUnknownRealmTrap.setDescription("Trigger when there is unknown realm.\nThe event severity, event type, realm name, SCG node MAC address and event code are enclosed.")
ruckusSCGAuthFailedNonPermanentIDTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 317)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventMacAddr"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventReason"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGUEImsi"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGUEMsisdn"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventNodeMgmtIp"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGAuthFailedNonPermanentIDTrap.setDescription("Trigger when there is non-permanent ID authentication failed event.\nThe event severity, event type, UE IMSI, UE msisdn, SCG node MAC address, management IP address, failure reason and event code are enclosed.")
ruckusSCGCnxnToCgfFailedTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 318)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGRadSrvrIp"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventMacAddr"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventNodeMgmtIp"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGCgfSrvrIp"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGCnxnToCgfFailedTrap.setDescription("Trigger when there is connection to CGF failed.\nThe event severity, event type, CGF sever IP address, radius server IP address, SCG node MAC address, management IP address and event code are enclosed.")
ruckusSCGCdrTransferFailedTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 319)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGRadSrvrIp"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventMacAddr"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventNodeMgmtIp"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGCgfSrvrIp"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGCdrTransferFailedTrap.setDescription("Trigger when there is CDR transfer failed event.\nThe event severity, event type, CGF sever IP address, radius server IP address, SCG node MAC address, management IP address and event code are enclosed.")
ruckusSCGCdrGenerateFailedTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 320)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGRadSrvrIp"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventMacAddr"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventNodeMgmtIp"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGCdrGenerateFailedTrap.setDescription("Trigger when there is CDR generation failed event.\nThe event severity, event type, radius server IP address,SCG node MAC address, management IP address and event code are enclosed.")
ruckusSCGDestNotRecheableTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 321)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventMacAddr"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGPointCode"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGDestNotRecheableTrap.setDescription("Trigger when there is destination not reachable.\nThe event severity, event type, point code, SCG node MAC address and event code are enclosed.")
ruckusSCGAppServerDownTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 324)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGPointCode"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGRoutingContext"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventMacAddr"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGSSN"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGAppServerDownTrap.setDescription("Trigger when there is application server down event.\nThe event severity, event type, routing context, local point code, local SSN, SCG node MAC address and event code are enclosed.")
ruckusSCGAppServerInactiveTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 325)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGPointCode"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGRoutingContext"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventMacAddr"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGSSN"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGAppServerInactiveTrap.setDescription("Trigger when there is application server inactive event.\nThe event severity, event type, routing context, local point code, local SSN, SCG node MAC address and event code are enclosed.")
ruckusSCGAssocCantStartTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 326)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGDestIP"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGSrcPort"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGSrcIP"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGDestPort"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventMacAddr"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGAssocCantStartTrap.setDescription("Trigger when there is association can not start event.\nThe event severity, event type, source IP address, source port, destination IP address, destination port, SCG node MAC address and event code are enclosed.")
ruckusSCGAssocDownTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 327)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGDestIP"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGSrcPort"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGSrcIP"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGDestPort"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventMacAddr"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGAssocDownTrap.setDescription("Trigger when there is association down event.\nThe event severity, event type, source IP address, source port, destination IP address, destination port, SCG node MAC address and event code are enclosed.")
ruckusSCGOutboundRoutingFailedTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 328)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGHlrInstance"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGUEImsi"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventMacAddr"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGOperation"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGOutboundRoutingFailedTrap.setDescription("Trigger when there is outbound routing failure event.\nThe event severity, event type, route operation, UE IMSI, HLR instance, SCG node MAC address and event code are enclosed.")
ruckusSCGDidAllocationFailureTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 329)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventMacAddr"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGDidAllocationFailureTrap.setDescription("Trigger when there is did allocation failure event.\nThe event severity, event type, node MAC address and event code are enclosed.")
ruckusSCGPdnGwUnresolvedTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 331)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGSrcProcess"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventMacAddr"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGApn"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGUEImsi"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGUEMsisdn"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventNodeMgmtIp"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGPdnGwUnresolvedTrap.setDescription("Trigger when there is PDN gateway could not be resolved.\nThe event severity, event type, source process name, APN, UE IMSI, UE msisdn, SCG node MAC address, management IP address and event code are enclosed.")
ruckusSCGPdnGwVersionUnsupportedTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 332)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGPgwIp"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventMacAddr"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventNodeMgmtIp"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGSrcProcess"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGPdnGwVersionUnsupportedTrap.setDescription("Trigger when there is PDN gateway version not supported event.\nThe event severity, event type, source process name, PGW IP adress, SCG node MAC address, management IP address and event code are enclosed.")
ruckusSCGPdnGwAssociationDownTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 333)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGPgwIp"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventMacAddr"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventNodeMgmtIp"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGSrcProcess"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGPdnGwAssociationDownTrap.setDescription("Trigger when there is association PDN gateway down.\nThe event severity, event type, source process name, PGW IP address, SCG node MAC address, management IP address and event code are enclosed.")
ruckusSCGCreateSessionResponseFailedTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 334)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGSrcProcess"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGPgwIp"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventReason"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGUEImsi"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventMacAddr"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGRealm"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventNodeMgmtIp"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGCreateSessionResponseFailedTrap.setDescription("Trigger when there is create session response failed event.\nThe event severity, event type, source process name, PGW IP address, UE IMSI, realm name, SCG node MAC address, management IP address, failure reason and event code are enclosed.")
ruckusSCGDecodeFailedTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 335)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGPgwIp"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventMacAddr"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventNodeMgmtIp"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGSrcProcess"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGDecodeFailedTrap.setDescription("Trigger when there is decode failed event.\nThe event severity, event type, source process name, PGW IP address, SCG node MAC address, management IP address and event code are enclosed.")
ruckusSCGModifyBearerResponseFailedTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 336)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGSrcProcess"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGPgwIp"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventReason"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGUEImsi"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventMacAddr"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGRealm"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventNodeMgmtIp"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGModifyBearerResponseFailedTrap.setDescription("Trigger when there is modify bearer response failed event.\nThe event severity, event type, source process name, PGW IP address, UE IMSI, realm name, SCG node MAC address, management IP address, failure reason and event code are enclosed.")
ruckusSCGDeleteSessionResponseFailedTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 337)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGSrcProcess"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGPgwIp"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventReason"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGUEImsi"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventMacAddr"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGRealm"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventNodeMgmtIp"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGDeleteSessionResponseFailedTrap.setDescription("Trigger when there is delete session response failed event.\nThe event severity, event type, source process name, PGW IP address, UE IMSI, realm name, SCG node MAC address, management IP address, failure reason and event code are enclosed.")
ruckusSCGDeleteBearerRequestFailedTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 338)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGSrcProcess"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGPgwIp"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventReason"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventMacAddr"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGRealm"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventNodeMgmtIp"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGDeleteBearerRequestFailedTrap.setDescription("Trigger when there is delete bearer request failed event.\nThe event severity, event type, source process name, PGW IP address, realm name, SCG node MAC address, management IP address, failure reason and event code are enclosed.")
ruckusSCGUpdateBearerRequestFailedTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 339)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGSrcProcess"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGPgwIp"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventReason"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventMacAddr"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGRealm"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventNodeMgmtIp"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGUpdateBearerRequestFailedTrap.setDescription("Trigger when there is update bearer request failed event.\nThe event severity, event type, source process name, PGW IP address, realm name, SCG node MAC address, management IP address, failure reason and event code are enclosed.")
ruckusSCGCgfServerNotConfiguredTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 340)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventMacAddr"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventNodeMgmtIp"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGGgsnIp"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGCgfSrvrIp"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGCgfServerNotConfiguredTrap.setDescription("Trigger when there is CGF server IP received from GGSN or PDN gateway not configured event.\nThe event severity, event type, CGF sever IP address, GGSN IP address, SCG node MAC address, management IP address and event code are enclosed.")
ruckusSCGTtgSessionCriticalThresholdTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 342)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventMacAddr"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGTtgSessionCriticalThresholdTrap.setDescription("Trigger when there is TTG session critical threshold event.\nThe event severity, event type, SCG node MAC address and event code are enclosed.")
ruckusSCGTtgSessionLicenseInsufficientTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 343)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventMacAddr"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGTtgSessionLicenseInsufficientTrap.setDescription("Trigger when there is TTG session license exhausted event.\nThe event severity, event type, SCG node MAC address and event code are enclosed.")
ruckusSCGAPAcctMsgMandatoryPrmMissingTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 344)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGSrcProcess"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPIPv6"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPIP"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventMacAddr"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventNodeMgmtIp"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGUserName"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGAPAcctMsgMandatoryPrmMissingTrap.setDescription("Trigger when there is AP accounting message mandatory parameter missing event.\nThe event severity, event type, source process name,AP IP address, user name, SCG node MAC address, management IP address, event code and AP IPv6 address are enclosed.")
ruckusSCGAcctUnknownRealmTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 345)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGSrcProcess"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPIPv6"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPIP"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventMacAddr"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventNodeMgmtIp"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGUserName"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGAcctUnknownRealmTrap.setDescription("Trigger when there is unknown realm accounting event.\nThe event severity, event type, source process name, AP IP address,user name, SCG node MAC address, management IP address, event code and AP IPv6 address are enclosed.")
ruckusSCGAPAcctMsgDecodeFailedTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 346)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGSrcProcess"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPIPv6"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPIP"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventMacAddr"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventNodeMgmtIp"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGAPAcctMsgDecodeFailedTrap.setDescription("Trigger when there is AP accounting message decode failed event.\nThe event severity, event type, source process name, AP IP address, SCG node MAC address, management IP address, event code and AP IPv6 address are enclosed.")
ruckusSCGAPAcctRespWhileInvalidConfigTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 347)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGSrcProcess"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPIPv6"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPIP"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventMacAddr"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventNodeMgmtIp"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGUserName"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGAPAcctRespWhileInvalidConfigTrap.setDescription("Trigger when there is SCG sends response to AP accounting message while configuration is incorrect in SCG to forward received message or to generate CDR event.\nThe event severity, event type, source process name, AP IP address, user Name, SCG node MAC address, management IP address, event code and AP IPv6 address are enclosed.")
ruckusSCGAPAcctMsgDropNoAcctStartMsgTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 348)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGSrcProcess"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPIPv6"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPIP"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventMacAddr"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventNodeMgmtIp"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGUserName"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGAPAcctMsgDropNoAcctStartMsgTrap.setDescription("Trigger when there is accounting message from AP dropped Acct Interim/Stop message as Account Start no received from AP event.\nThe event severity, event type, source process name, AP IP address, user Name, SCG node MAC address, management IP address, event code and AP IPv6 address are enclosed.")
ruckusSCGUnauthorizedCoaDmMessageDroppedTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 349)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGRadSrvrIp"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventMacAddr"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventNodeMgmtIp"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGSrcProcess"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGUnauthorizedCoaDmMessageDroppedTrap.setDescription("Trigger when there is received COA/DM from unauthorized AAA server event.\nThe event severity, event type, source process name, AAA server IP address, SCG node MAC address, management IP address and event code are enclosed.")
ruckusSCGConnectedToDbladeTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 350)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventMacAddr"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventNodeMgmtIp"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGDPIP"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCtrlIP"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGConnectedToDbladeTrap.setDescription("Trigger when there is successful connection to DP event.\nThe event severity, event type, SCG control IP address, DP IP address, SCG node MAC address, management IP address and event code are enclosed.")
ruckusSCGDestAvailableTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 351)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventMacAddr"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGPointCode"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGDestAvailableTrap.setDescription("Trigger when there is destination available event.\nThe event severity, event type, point code, SCG node MAC address and event code are enclosed.")
ruckusSCGAppServerActiveTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 352)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGPointCode"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGRoutingContext"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventMacAddr"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGSSN"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGAppServerActiveTrap.setDescription("Trigger when there is application server active event.\nThe event severity, event type, routing context, local point code, local SSN, SCG node MAC address and event code are enclosed.")
ruckusSCGAssocUpTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 353)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGDestIP"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGSrcPort"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGSrcIP"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGDestPort"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventMacAddr"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGAssocUpTrap.setDescription("Trigger when there is association up event.\nThe event severity, event type, source IP address, source port, destination IP address, destination port, SCG node MAC address and event code are enclosed.")
ruckusSCGSessUpdatedAtDbladeTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 354)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventMacAddr"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGDPIP"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGUEImsi"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCtrlIP"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGUEMsisdn"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventNodeMgmtIp"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGSessUpdatedAtDbladeTrap.setDescription("Trigger when there is session updates the request (C-D-SESS-UPD-REQ) successfully event.\nThe event severity, event type, SCG control IP address, SCG DP IP address, UE IMSI, UE msisdn, SCG node MAC address, management IP address and event code are enclosed.")
ruckusSCGSessUpdateErrAtDbladeTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 355)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventMacAddr"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGDPIP"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGUEImsi"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCtrlIP"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGUEMsisdn"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventNodeMgmtIp"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGSessUpdateErrAtDbladeTrap.setDescription("Trigger when there is session updates the request (C-D-SESS-UPD-REQ) failed event.\nThe event severity, event type, SCG control IP address, SCG DP IP address, UE IMSI, UE msisdn, SCG node MAC address, management IP address and event code are enclosed.")
ruckusSCGSessDeletedAtDbladeTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 356)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventMacAddr"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGDPIP"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGUEImsi"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCtrlIP"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGUEMsisdn"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventNodeMgmtIp"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGSessDeletedAtDbladeTrap.setDescription("Trigger when there is session deletes request (C-D-SESS-DEL-REQ) successfully event.\nThe event severity, event type, SCG control IP address, SCG DP IP address, UE IMSI, UE msisdn, SCG node MAC address, management IP address and event code are enclosed.")
ruckusSCGSessDeleteErrAtDbladeTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 357)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventMacAddr"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGDPIP"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGUEImsi"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCtrlIP"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGUEMsisdn"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventNodeMgmtIp"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGSessDeleteErrAtDbladeTrap.setDescription("Trigger when there is session deletes request (C-D-SESS-DEL-REQ) failed event.\nThe event severity, event type, SCG control IP address, SCG DP IP address, UE IMSI, UE msisdn, SCG node MAC address, management IP address and event code are enclosed.")
ruckusSCGLicenseSyncSuccessTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 358)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGLicenseServerName"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventNodeName"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGLicenseSyncSuccessTrap.setDescription("Trigger when there is license data syncs up with license server successfully event.\nThe event severity, event type, node name, license server name and event code are enclosed.")
ruckusSCGLicenseSyncFailedTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 359)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGLicenseServerName"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventNodeName"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGLicenseSyncFailedTrap.setDescription("Trigger when there is license data syncs up with license server failed event.\nThe event severity, event type, node name, license server name and event code are enclosed.")
ruckusSCGLicenseImportSuccessTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 360)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventNodeName"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGLicenseImportSuccessTrap.setDescription("Trigger when there is license data import successfully event.\nThe event severity, event type, node name and event code are enclosed.")
ruckusSCGLicenseImportFailedTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 361)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventNodeName"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGLicenseImportFailedTrap.setDescription("Trigger when there is license data import failed event.\nThe event severity, event type, node name and event code are enclosed.")
ruckusSCGSyslogServerReachableTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 370)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventMacAddr"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGSyslogServerAddress"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGSyslogServerReachableTrap.setDescription("Trigger when there is a syslog server reachable event.\nThe event severity, event type, syslog server address, SCG node MAC address and event code are enclosed.")
ruckusSCGSyslogServerUnreachableTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 371)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventMacAddr"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGSyslogServerAddress"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGSyslogServerUnreachableTrap.setDescription("Trigger when there is a syslog server unreachable event.\nThe event severity, event type, syslog server address, SCG node MAC address and event code are enclosed.")
ruckusSCGSyslogServerSwitchedTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 372)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGSrcSyslogServerAddress"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventMacAddr"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGDestSyslogServerAddress"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGSyslogServerSwitchedTrap.setDescription("Trigger when there is a syslog server switched event.\nThe event severity, event type, source syslog server address, destination syslog server address, SCG node MAC address and event code are enclosed.")
ruckusSCGAPRadiusServerReachableTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 400)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPMacAddr"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPDescription"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPName"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPLocation"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPGPSCoordinates"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPIP"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGRadSrvrIp"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventZoneName"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPIPv6"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGAPRadiusServerReachableTrap.setDescription("Trigger when there is an AP is able to reach radius server successfully event.\nThe event severity, event type, AP name, AP MAC address, AP IP address, AP location, AP description, AP GPS coordinates, zone name, radius server IP address, event code and AP IPv6 address are enclosed.")
ruckusSCGAPRadiusServerUnreachableTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 401)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPMacAddr"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPDescription"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPName"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPLocation"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPGPSCoordinates"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPIP"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGRadSrvrIp"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventZoneName"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPIPv6"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGAPRadiusServerUnreachableTrap.setDescription("Trigger when there is an AP is unable to reach radius server event.\nThe event severity, event type, AP name, AP MAC address, AP IP address, AP location, AP description, AP GPS coordinates, zone name, radius server IP address, event code and AP IPv6 address are enclosed.")
ruckusSCGAPLDAPServerReachableTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 402)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPMacAddr"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPDescription"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPName"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPLocation"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPGPSCoordinates"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPIP"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventZoneName"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPIPv6"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGLDAPSrvrIp"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGAPLDAPServerReachableTrap.setDescription("Trigger when there is an AP is able to reach LDAP server successfully event.\nThe event severity, event type, AP name, AP MAC address, AP IP address, AP location, AP description, AP GPS coordinates, zone name, LDAP server IP address, event code and AP IPv6 address are enclosed.")
ruckusSCGAPLDAPServerUnreachableTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 403)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPMacAddr"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPDescription"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPName"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPLocation"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPGPSCoordinates"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPIP"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventZoneName"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPIPv6"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGLDAPSrvrIp"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGAPLDAPServerUnreachableTrap.setDescription("Trigger when there is an AP is unable to reach LDAP server event.\nThe event severity, event type, AP name, AP MAC address, AP IP address, AP location, AP description, AP GPS coordinates, zone name, LDAP server IP address, event code and AP IPv6 address are enclosed.")
ruckusSCGAPADServerReachableTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 404)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPMacAddr"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPDescription"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPName"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPLocation"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPGPSCoordinates"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPIP"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventZoneName"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGADSrvrIp"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPIPv6"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGAPADServerReachableTrap.setDescription("Trigger when there is an AP is able to reach AD server successfully event.\nThe event severity, event type, AP name, AP MAC address, AP IP address, AP location, AP description, AP GPS coordinates, zone name, AD server IP address, event code and AP IPv6 address are enclosed.")
ruckusSCGAPADServerUnreachableTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 405)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPMacAddr"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPDescription"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPName"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPLocation"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPGPSCoordinates"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPIP"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventZoneName"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGADSrvrIp"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPIPv6"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGAPADServerUnreachableTrap.setDescription("Trigger when there is an AP is unable to reach AD server event.\nThe event severity, event type, AP name, AP MAC address, AP IP address, AP location, AP description, AP GPS coordinates, zone name, AD server IP address, event code and AP IPv6 address are enclosed.")
ruckusSCGAPUsbSoftwarePackageDownloadedTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 406)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPMacAddr"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPDescription"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPName"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPLocation"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPGPSCoordinates"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPIP"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventZoneName"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGSoftwareName"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPIPv6"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGAPUsbSoftwarePackageDownloadedTrap.setDescription("Trigger when there is an AP downloaded its USB software package successfully event.\nThe event severity, event type, AP name, AP MAC address, AP IP address, AP location, AP description, AP GPS coordinates, zone name, USB software name, event code and AP IPv6 address are enclosed.")
ruckusSCGAPUsbSoftwarePackageDownloadFailedTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 407)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPMacAddr"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPDescription"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPName"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPLocation"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPGPSCoordinates"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPIP"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventZoneName"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGSoftwareName"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPIPv6"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGAPUsbSoftwarePackageDownloadFailedTrap.setDescription("Trigger when there is an AP failed to download its USB software package event.\nThe event severity, event type, AP name, AP MAC address, AP IP address, AP location, AP description, AP GPS coordinates, zone name, USB software name, event code and AP IPv6 address are enclosed.")
ruckusSCGEspAuthServerReachableTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 408)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPMacAddr"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPDescription"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGAuthSrvrIp"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPName"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPLocation"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPGPSCoordinates"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPIP"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventZoneName"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPIPv6"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGEspAuthServerReachableTrap.setDescription("Trigger when there is an AP is able to reach WeChat ESP authentication server successfully event.\nThe event severity, event type, AP name, AP MAC address, AP IP address, AP location, AP description, AP GPS coordinates, zone name, authentication server IP address, event code and AP IPv6 address are enclosed.")
ruckusSCGEspAuthServerUnreachableTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 409)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPMacAddr"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPDescription"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGAuthSrvrIp"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPName"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPLocation"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPGPSCoordinates"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPIP"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventZoneName"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPIPv6"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGEspAuthServerUnreachableTrap.setDescription("Trigger when there is an AP is unable to reach WeChat ESP authentication server event.\nThe event severity, event type, AP name, AP MAC address, AP IP address, AP location, AP description, AP GPS coordinates, zone name, authentication server IP address, event code and AP IPv6 address are enclosed.")
ruckusSCGEspAuthServerResolvableTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 410)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPMacAddr"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPDescription"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPName"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPLocation"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPGPSCoordinates"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPIP"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGDomainName"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventZoneName"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPIPv6"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGEspAuthServerResolvableTrap.setDescription("Trigger when there is an AP is able to resolve WeChat ESP authentication server domain name successfully event.\nThe event severity, event type, AP name, AP MAC address, AP IP address, AP location, AP description, AP GPS coordinates, zone name, authentication server domain name, event code and AP IPv6 address are enclosed.")
ruckusSCGEspAuthServerUnResolvableTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 411)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPMacAddr"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPDescription"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPName"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPLocation"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPGPSCoordinates"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPIP"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGDomainName"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventZoneName"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPIPv6"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGEspAuthServerUnResolvableTrap.setDescription("Trigger when there is an AP is unable to resolve WeChat ESP authentication server domain name event.\nThe event severity, event type, AP name, AP MAC address, AP IP address, AP location, AP description, AP GPS coordinates, zone name, authentication server domain name, event code and AP IPv6 address are enclosed.")
ruckusSCGEspDNATServerReachableTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 412)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPMacAddr"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPDescription"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPName"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPLocation"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPGPSCoordinates"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPIP"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventZoneName"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGDNATIp"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPIPv6"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGEspDNATServerReachableTrap.setDescription("Trigger when there is an AP is able to reach WeChat ESP DNAT server successfully event.\nThe event severity, event type, AP name, AP MAC address, AP IP address, AP location, AP description, AP GPS coordinates, zone name, DNAT server IP address, event code and AP IPv6 address are enclosed.")
ruckusSCGEspDNATServerUnreachableTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 413)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPMacAddr"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPDescription"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPName"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPLocation"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPGPSCoordinates"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPIP"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventZoneName"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGDNATIp"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPIPv6"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGEspDNATServerUnreachableTrap.setDescription("Trigger when there is an AP is unable to reach WeChat ESP DNAT server event.\nThe event severity, event type, AP name, AP MAC address, AP IP address, AP location, AP description, AP GPS coordinates, zone name, DNAT server IP address, event code and AP IPv6 address are enclosed.")
ruckusSCGEspDNATServerResolvableTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 414)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPMacAddr"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPDescription"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPName"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPLocation"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPGPSCoordinates"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPIP"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGDomainName"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventZoneName"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPIPv6"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGEspDNATServerResolvableTrap.setDescription("Trigger when there is an AP is able to resolve WeChat ESP DNAT server domain name successfully event.\nThe event severity, event type, AP name, AP MAC address, AP IP address, AP location, AP description, AP GPS coordinates, zone name, authentication server domain name, event code and AP IPv6 address are enclosed.")
ruckusSCGEspDNATServerUnresolvableTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 415)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPMacAddr"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPDescription"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPName"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPLocation"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPGPSCoordinates"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPIP"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGDomainName"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventZoneName"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPIPv6"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGEspDNATServerUnresolvableTrap.setDescription("Trigger when there is an AP is unable to resolve WeChat ESP DNAT server domain name event.\nThe event severity, event type, AP name, AP MAC address, AP IP address, AP location, AP description, AP GPS coordinates, zone name, authentication server domain name, event code and AP IPv6 address are enclosed.")
ruckusRateLimitTORSurpassedTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 500)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGRadSrvrIp"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusRateLimitTORSurpassedTrap.setDescription("Trigger when there is received rate Limit for Total Outstanding Requests(TOR) Surpassed event.\nThe event severity, event type, AAA server IP address and event code are enclosed.")
ruckusSCGIPSecTunnelAssociatedTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 600)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPMacAddr"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPDescription"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPName"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGIPSecGWAddress"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPLocation"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPGPSCoordinates"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPIP"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventZoneName"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPIPv6"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGIPSecTunnelAssociatedTrap.setDescription("Trigger when there is an AP is able to reach secure gateway successfully event.\nThe event severity, event type, AP name, AP MAC address, AP IP address, AP location, AP description, AP GPS coordinates, zone name, secure gateway address, event code and AP IPv6 address are enclosed.")
ruckusSCGIPSecTunnelDisassociatedTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 601)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPMacAddr"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPDescription"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPName"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGIPSecGWAddress"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPLocation"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPGPSCoordinates"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPIP"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventZoneName"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPIPv6"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGIPSecTunnelDisassociatedTrap.setDescription("Trigger when there is an AP is disconnected from secure gateway event.\nThe event severity, event type, AP name, AP MAC address, AP IP address, AP location, AP description, AP GPS coordinates, zone name, secure gateway address, event code and AP IPv6 address are enclosed.")
ruckusSCGIPSecTunnelAssociateFailedTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 602)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPMacAddr"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPDescription"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPName"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGIPSecGWAddress"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPLocation"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPGPSCoordinates"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPIP"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventZoneName"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventAPIPv6"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGIPSecTunnelAssociateFailedTrap.setDescription("Trigger when there is an AP is not able to reach secure gateway successfully event.\nThe event severity, event type, AP name, AP MAC address, AP IP address, AP location, AP description, AP GPS coordinates, zone name, secure gateway address, event code and AP IPv6 address are enclosed.")
ruckusSCGPmipProcessInitTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 700)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventMacAddr"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventNodeMgmtIp"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGPmipProcessInitTrap.setDescription("Trigger when there is received PMIPv6 process crashed, is restarted event.\nThe event severity, event type, SCG node MAC address, management IP address and event code are enclosed.")
ruckusSCGPmipUnavailableTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 701)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventMacAddr"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventNodeMgmtIp"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGPmipUnavailableTrap.setDescription("Trigger when there is received PMIPv6 process repeatedly restarts, could not become stable event.\nThe event severity, event type, SCG node MAC address, management IP address and event code are enclosed.")
ruckusSCGPmipUnallocatedMemoryTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 702)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventMacAddr"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventNodeMgmtIp"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGPmipUnallocatedMemoryTrap.setDescription("Trigger when there is received memory allocation failed in PMIPv6 process event.\nThe event severity, event type, SCG node MAC address, management IP address and event code are enclosed.")
ruckusSCGPmipUpdateCgfFailedTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 703)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventMacAddr"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventNodeMgmtIp"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGPmipUpdateCgfFailedTrap.setDescription("Trigger when there is received PMIPv6 failed to apply configuration event.\nThe event severity, event type, SCG node MAC address, management IP address and event code are enclosed.")
ruckusSCGPmipLMAIcmpUnreachableTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 704)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGLMAIp"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventMacAddr"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventNodeMgmtIp"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGPmipLMAIcmpUnreachableTrap.setDescription("Trigger when there is received PMIPv6 daemon cannot reach the LMA server by ICMP packet event.\nThe event severity, event type, LMA IP address, SCG node MAC address, management IP address and event code are enclosed.")
ruckusSCGPmipLMAFailOverTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 705)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGLMAIp"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventMacAddr"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventNodeMgmtIp"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGPmipLMAFailOverTrap.setDescription("Trigger when there is received LMA failover event.\nThe event severity, event type, LMA IP address, SCG node MAC address, management IP address and event code are enclosed.")
ruckusSCGPmipBindingFailureTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 706)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventMacAddr"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventNodeMgmtIp"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGPmipBindingFailureTrap.setDescription("Trigger when there is received MN binding failure from LMA server event.\nThe event severity, event type, SCG node MAC address, management IP address and event code are enclosed.")
ruckusSCGPmiplostCnxnToDHCPTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 707)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventMacAddr"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventNodeMgmtIp"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGPmiplostCnxnToDHCPTrap.setDescription("Trigger when there is received PMIPv6 process cannot connect to DHCP server event.\nThe event severity, event type, SCG node MAC address, management IP address and event code are enclosed.")
ruckusSCGPmipLMAIcmpReachableTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 708)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGLMAIp"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventMacAddr"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventNodeMgmtIp"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGPmipLMAIcmpReachableTrap.setDescription("Trigger when there is received PMIPv6 daemon successfully reaches the LMA server by ICMP packet event.\nThe event severity, event type, LMA IP address, SCG node MAC address, management IP address and event code are enclosed.")
ruckusSCGPmipBindingSuccessTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 709)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventMacAddr"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventNodeMgmtIp"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGPmipBindingSuccessTrap.setDescription("Trigger when there is received MN binding success from LMA server event.\nThe event severity, event type, SCG node MAC address, management IP address and event code are enclosed.")
ruckusSCGPmipConnectedToDHCPTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 710)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventMacAddr"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventNodeMgmtIp"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGPmipConnectedToDHCPTrap.setDescription("Trigger when there is received PMIPv6 process successfully connects to DHCP server event.\nThe event severity, event type, SCG node MAC address, management IP address and event code are enclosed.")
ruckusSCGPmipProcessStoppedTrap = NotificationType((1, 3, 6, 1, 4, 1, 25053, 2, 10, 1, 711)).setObjects(*(("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventSeverity"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventMacAddr"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventType"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventNodeMgmtIp"), ("RUCKUS-SCG-EVENT-MIB", "ruckusSCGEventCode"), )) # pylint:disable=star-args
if mibBuilder.loadTexts:
ruckusSCGPmipProcessStoppedTrap.setDescription("Trigger when there is PMIPv6 process stopped event.\nThe event severity, event type, SCG node MAC address, management IP address and event code are enclosed.")
# Exports
# Module identity
mibBuilder.exportSymbols("RUCKUS-SCG-EVENT-MIB", PYSNMP_MODULE_ID=ruckusSCGEventMIB)
# Objects
mibBuilder.exportSymbols("RUCKUS-SCG-EVENT-MIB", ruckusSCGEventMIB=ruckusSCGEventMIB, ruckusSCGEventTraps=ruckusSCGEventTraps, ruckusSCGEventObjects=ruckusSCGEventObjects, ruckusSCGEventDescription=ruckusSCGEventDescription, ruckusSCGClusterName=ruckusSCGClusterName, ruckusSCGEventCode=ruckusSCGEventCode, ruckusSCGProcessName=ruckusSCGProcessName, ruckusSCGEventCtrlIP=ruckusSCGEventCtrlIP, ruckusSCGEventSeverity=ruckusSCGEventSeverity, ruckusSCGEventType=ruckusSCGEventType, ruckusSCGEventNodeMgmtIp=ruckusSCGEventNodeMgmtIp, ruckusSCGEventNodeName=ruckusSCGEventNodeName, ruckusSCGCPUPerc=ruckusSCGCPUPerc, ruckusSCGMemoryPerc=ruckusSCGMemoryPerc, ruckusSCGDiskPerc=ruckusSCGDiskPerc, ruckusSCGEventMacAddr=ruckusSCGEventMacAddr, ruckusSCGEventFirmwareVersion=ruckusSCGEventFirmwareVersion, ruckusSCGEventUpgradedFirmwareVersion=ruckusSCGEventUpgradedFirmwareVersion, ruckusSCGEventAPMacAddr=ruckusSCGEventAPMacAddr, ruckusSCGEventReason=ruckusSCGEventReason, ruckusSCGEventAPName=ruckusSCGEventAPName, ruckusSCGEventAPIP=ruckusSCGEventAPIP, ruckusSCGEventAPLocation=ruckusSCGEventAPLocation, ruckusSCGEventAPGPSCoordinates=ruckusSCGEventAPGPSCoordinates, ruckusSCGEventAPDescription=ruckusSCGEventAPDescription, ruckusSCGEventZoneName=ruckusSCGEventZoneName, ruckusSCGAPModel=ruckusSCGAPModel, ruckusSCGConfigAPModel=ruckusSCGConfigAPModel, ruckusSCGAPConfigID=ruckusSCGAPConfigID, ruckusSCGEventTargetZoneName=ruckusSCGEventTargetZoneName, ruckusSCGEventAPIPv6=ruckusSCGEventAPIPv6, ruckusSCGLBSURL=ruckusSCGLBSURL, ruckusSCGLBSPort=ruckusSCGLBSPort, ruckusSCGEventSSID=ruckusSCGEventSSID, ruckusSCGEventRogueMac=ruckusSCGEventRogueMac, ruckusPrimaryGRE=ruckusPrimaryGRE, ruckusSecondaryGRE=ruckusSecondaryGRE, ruckusSoftGREGatewayList=ruckusSoftGREGatewayList, ruckusSCGSoftGREGWAddress=ruckusSCGSoftGREGWAddress, ruckusSCGEventClientMacAddr=ruckusSCGEventClientMacAddr, ruckusSCGDPKey=ruckusSCGDPKey, ruckusSCGDPConfigID=ruckusSCGDPConfigID, ruckusSCGDPIP=ruckusSCGDPIP, ruckusSCGDPPacketPoolID=ruckusSCGDPPacketPoolID, ruckusSCGNetworkPortID=ruckusSCGNetworkPortID, ruckusSCGNetworkInterface=ruckusSCGNetworkInterface, ruckusSCGSwitchStatus=ruckusSCGSwitchStatus, ruckusSCGTemperatureStatus=ruckusSCGTemperatureStatus, ruckusSCGProcessorId=ruckusSCGProcessorId, ruckusSCGFanId=ruckusSCGFanId, ruckusSCGFanStatus=ruckusSCGFanStatus, ruckusSCGPsId=ruckusSCGPsId, ruckusSCGPsStatus=ruckusSCGPsStatus, ruckusSCGDrvId=ruckusSCGDrvId, ruckusSCGDrvStatus=ruckusSCGDrvStatus, ruckusSCGLicenseType=ruckusSCGLicenseType, ruckusSCGLicenseUsagePerc=ruckusSCGLicenseUsagePerc, ruckusSCGLicenseServerName=ruckusSCGLicenseServerName, ruckusSCGIPSecGWAddress=ruckusSCGIPSecGWAddress, ruckusSCGSyslogServerAddress=ruckusSCGSyslogServerAddress, ruckusSCGSrcSyslogServerAddress=ruckusSCGSrcSyslogServerAddress, ruckusSCGDestSyslogServerAddress=ruckusSCGDestSyslogServerAddress, ruckusSCGFtpIp=ruckusSCGFtpIp, ruckusSCGFtpPort=ruckusSCGFtpPort, ruckusSCGSrcProcess=ruckusSCGSrcProcess, ruckusSCGGgsnIp=ruckusSCGGgsnIp, ruckusSCGGtpcIp=ruckusSCGGtpcIp, ruckusSCGApn=ruckusSCGApn, ruckusSCGUEImsi=ruckusSCGUEImsi, ruckusSCGUEMsisdn=ruckusSCGUEMsisdn, ruckusSCGAuthSrvrIp=ruckusSCGAuthSrvrIp, ruckusSCGRadProxyIp=ruckusSCGRadProxyIp, ruckusSCGAccSrvrIp=ruckusSCGAccSrvrIp, ruckusSCGRealm=ruckusSCGRealm, ruckusSCGCgfSrvrIp=ruckusSCGCgfSrvrIp, ruckusSCGRadSrvrIp=ruckusSCGRadSrvrIp, ruckusSCGCipIp=ruckusSCGCipIp, ruckusSCGPointCode=ruckusSCGPointCode, ruckusSCGCongLevel=ruckusSCGCongLevel, ruckusSCGSSN=ruckusSCGSSN, ruckusSCGRoutingContext=ruckusSCGRoutingContext, ruckusSCGSrcIP=ruckusSCGSrcIP, ruckusSCGSrcPort=ruckusSCGSrcPort, ruckusSCGDestIP=ruckusSCGDestIP, ruckusSCGDestPort=ruckusSCGDestPort, ruckusSCGOperation=ruckusSCGOperation, ruckusSCGHlrInstance=ruckusSCGHlrInstance, ruckusSCGUserName=ruckusSCGUserName, ruckusSCGPgwIp=ruckusSCGPgwIp, ruckusSCGFileName=ruckusSCGFileName, ruckusSCGLDAPSrvrIp=ruckusSCGLDAPSrvrIp, ruckusSCGADSrvrIp=ruckusSCGADSrvrIp, ruckusSCGSoftwareName=ruckusSCGSoftwareName, ruckusSCGDomainName=ruckusSCGDomainName, ruckusSCGDNATIp=ruckusSCGDNATIp, ruckusSCGLMAIp=ruckusSCGLMAIp)
# Notifications
mibBuilder.exportSymbols("RUCKUS-SCG-EVENT-MIB", ruckusSCGSystemMiscEventTrap=ruckusSCGSystemMiscEventTrap, ruckusSCGUpgradeSuccessTrap=ruckusSCGUpgradeSuccessTrap, ruckusSCGUpgradeFailedTrap=ruckusSCGUpgradeFailedTrap, ruckusSCGNodeRestartedTrap=ruckusSCGNodeRestartedTrap, ruckusSCGNodeShutdownTrap=ruckusSCGNodeShutdownTrap, ruckusSCGCPUUsageThresholdExceededTrap=ruckusSCGCPUUsageThresholdExceededTrap, ruckusSCGMemoryUsageThresholdExceededTrap=ruckusSCGMemoryUsageThresholdExceededTrap, ruckusSCGDiskUsageThresholdExceededTrap=ruckusSCGDiskUsageThresholdExceededTrap, ruckusSCGLicenseUsageThresholdExceededTrap=ruckusSCGLicenseUsageThresholdExceededTrap, ruckusSCGAPMiscEventTrap=ruckusSCGAPMiscEventTrap, ruckusSCGAPConnectedTrap=ruckusSCGAPConnectedTrap, ruckusSCGAPDeletedTrap=ruckusSCGAPDeletedTrap, ruckusSCGAPDisconnectedTrap=ruckusSCGAPDisconnectedTrap, ruckusSCGAPLostHeartbeatTrap=ruckusSCGAPLostHeartbeatTrap, ruckusSCGAPRebootTrap=ruckusSCGAPRebootTrap, ruckusSCGCriticalAPConnectedTrap=ruckusSCGCriticalAPConnectedTrap, ruckusSCGCriticalAPDisconnectedTrap=ruckusSCGCriticalAPDisconnectedTrap, ruckusSCGAPRejectedTrap=ruckusSCGAPRejectedTrap, ruckusSCGAPConfUpdateFailedTrap=ruckusSCGAPConfUpdateFailedTrap, ruckusSCGAPConfUpdatedTrap=ruckusSCGAPConfUpdatedTrap, ruckusSCGAPSwapOutModelDiffTrap=ruckusSCGAPSwapOutModelDiffTrap, ruckusSCGAPPreProvisionModelDiffTrap=ruckusSCGAPPreProvisionModelDiffTrap, ruckusSCGAPDiscoveryFailTrap=ruckusSCGAPDiscoveryFailTrap, ruckusSCGAPFirmwareUpdateFailedTrap=ruckusSCGAPFirmwareUpdateFailedTrap, ruckusSCGAPFirmwareUpdatedTrap=ruckusSCGAPFirmwareUpdatedTrap, ruckusSCGAPWlanOversubscribedTrap=ruckusSCGAPWlanOversubscribedTrap, ruckusSCGAPFactoryResetTrap=ruckusSCGAPFactoryResetTrap, ruckusSCGCableModemDownTrap=ruckusSCGCableModemDownTrap, ruckusSCGCableModemRebootTrap=ruckusSCGCableModemRebootTrap, ruckusSCGAPJoinZoneFailedTrap=ruckusSCGAPJoinZoneFailedTrap, ruckusSCGAPManagedTrap=ruckusSCGAPManagedTrap, ruckusSCGCPUUsageThresholdBackToNormalTrap=ruckusSCGCPUUsageThresholdBackToNormalTrap, ruckusSCGMemoryUsageThresholdBackToNormalTrap=ruckusSCGMemoryUsageThresholdBackToNormalTrap, ruckusSCGDiskUsageThresholdBackToNormalTrap=ruckusSCGDiskUsageThresholdBackToNormalTrap, ruckusSCGCableModemUpTrap=ruckusSCGCableModemUpTrap, ruckusSCGAPDiscoverySuccessTrap=ruckusSCGAPDiscoverySuccessTrap, ruckusSCGCMResetByUserTrap=ruckusSCGCMResetByUserTrap, ruckusSCGCMResetFactoryByUserTrap=ruckusSCGCMResetFactoryByUserTrap, ruckusSCGSSIDSpoofingRogueAPDetectedTrap=ruckusSCGSSIDSpoofingRogueAPDetectedTrap, ruckusSCGMacSpoofingRogueAPDetectedTrap=ruckusSCGMacSpoofingRogueAPDetectedTrap, ruckusSCGSameNetworkRogueAPDetectedTrap=ruckusSCGSameNetworkRogueAPDetectedTrap, ruckusSCGADHocNetworkRogueAPDetectedTrap=ruckusSCGADHocNetworkRogueAPDetectedTrap, ruckusSCGMaliciousRogueAPTimeoutTrap=ruckusSCGMaliciousRogueAPTimeoutTrap, ruckusSCGAPLBSConnectSuccessTrap=ruckusSCGAPLBSConnectSuccessTrap, ruckusSCGAPLBSNoResponsesTrap=ruckusSCGAPLBSNoResponsesTrap, ruckusSCGAPLBSAuthFailedTrap=ruckusSCGAPLBSAuthFailedTrap, ruckusSCGAPLBSConnectFailedTrap=ruckusSCGAPLBSConnectFailedTrap, ruckusSCGAPTunnelBuildFailedTrap=ruckusSCGAPTunnelBuildFailedTrap, ruckusSCGAPTunnelBuildSuccessTrap=ruckusSCGAPTunnelBuildSuccessTrap, ruckusSCGAPTunnelDisconnectedTrap=ruckusSCGAPTunnelDisconnectedTrap, ruckusSCGAPSoftGRETunnelFailoverPtoSTrap=ruckusSCGAPSoftGRETunnelFailoverPtoSTrap, ruckusSCGAPSoftGRETunnelFailoverStoPTrap=ruckusSCGAPSoftGRETunnelFailoverStoPTrap, ruckusSCGAPSoftGREGatewayNotReachableTrap=ruckusSCGAPSoftGREGatewayNotReachableTrap, ruckusSCGAPSoftGREGatewayReachableTrap=ruckusSCGAPSoftGREGatewayReachableTrap, ruckusSCGDPConfUpdateFailedTrap=ruckusSCGDPConfUpdateFailedTrap, ruckusSCGDPLostHeartbeatTrap=ruckusSCGDPLostHeartbeatTrap, ruckusSCGDPDisconnectedTrap=ruckusSCGDPDisconnectedTrap, ruckusSCGDPPhyInterfaceDownTrap=ruckusSCGDPPhyInterfaceDownTrap, ruckusSCGDPStatusUpdateFailedTrap=ruckusSCGDPStatusUpdateFailedTrap, ruckusSCGDPStatisticUpdateFaliedTrap=ruckusSCGDPStatisticUpdateFaliedTrap, ruckusSCGDPConnectedTrap=ruckusSCGDPConnectedTrap, ruckusSCGDPPhyInterfaceUpTrap=ruckusSCGDPPhyInterfaceUpTrap, ruckusSCGDPConfUpdatedTrap=ruckusSCGDPConfUpdatedTrap, ruckusSCGDPTunnelTearDownTrap=ruckusSCGDPTunnelTearDownTrap, ruckusSCGDPRebootTrap=ruckusSCGDPRebootTrap, ruckusSCGDPAcceptTunnelRequestTrap=ruckusSCGDPAcceptTunnelRequestTrap, ruckusSCGDPRejectTunnelRequestTrap=ruckusSCGDPRejectTunnelRequestTrap, ruckusSCGDPSgreGWUnreachableTrap=ruckusSCGDPSgreGWUnreachableTrap, ruckusSCGDPSgreGWReachableTrap=ruckusSCGDPSgreGWReachableTrap, ruckusSCGDPTunnelSetUpTrap=ruckusSCGDPTunnelSetUpTrap, ruckusSCGDPDiscoverySuccessTrap=ruckusSCGDPDiscoverySuccessTrap, ruckusSCGDPDiscoveryFailTrap=ruckusSCGDPDiscoveryFailTrap, ruckusSCGDPSgreGWInactTrap=ruckusSCGDPSgreGWInactTrap, ruckusSCGDPSgreGWActTrap=ruckusSCGDPSgreGWActTrap, ruckusSCGDPPktPoolLowTrap=ruckusSCGDPPktPoolLowTrap, ruckusSCGDPPktPoolCriticalLowTrap=ruckusSCGDPPktPoolCriticalLowTrap, ruckusSCGDPPktPoolRecoverTrap=ruckusSCGDPPktPoolRecoverTrap, ruckusSCGDPCoreDeadTrap=ruckusSCGDPCoreDeadTrap, ruckusSCGDPDeletedTrap=ruckusSCGDPDeletedTrap, ruckusSCGDPUpgradeStartTrap=ruckusSCGDPUpgradeStartTrap, ruckusSCGDPUpgradingTrap=ruckusSCGDPUpgradingTrap, ruckusSCGDPUpgradeSuccessTrap=ruckusSCGDPUpgradeSuccessTrap, ruckusSCGDPUpgradeFailedTrap=ruckusSCGDPUpgradeFailedTrap, ruckusSCGClientMiscEventTrap=ruckusSCGClientMiscEventTrap, ruckusSCGNodeJoinFailedTrap=ruckusSCGNodeJoinFailedTrap, ruckusSCGNodeRemoveFailedTrap=ruckusSCGNodeRemoveFailedTrap, ruckusSCGNodeOutOfServiceTrap=ruckusSCGNodeOutOfServiceTrap, ruckusSCGClusterInMaintenanceStateTrap=ruckusSCGClusterInMaintenanceStateTrap, ruckusSCGClusterBackupFailedTrap=ruckusSCGClusterBackupFailedTrap, ruckusSCGClusterRestoreFailedTrap=ruckusSCGClusterRestoreFailedTrap, ruckusSCGClusterAppStoppedTrap=ruckusSCGClusterAppStoppedTrap, ruckusSCGNodeBondInterfaceDownTrap=ruckusSCGNodeBondInterfaceDownTrap, ruckusSCGNodePhyInterfaceDownTrap=ruckusSCGNodePhyInterfaceDownTrap, ruckusSCGClusterLeaderChangedTrap=ruckusSCGClusterLeaderChangedTrap, ruckusSCGClusterUpgradeSuccessTrap=ruckusSCGClusterUpgradeSuccessTrap, ruckusSCGNodeBondInterfaceUpTrap=ruckusSCGNodeBondInterfaceUpTrap, ruckusSCGNodePhyInterfaceUpTrap=ruckusSCGNodePhyInterfaceUpTrap, ruckusSCGClusterBackToInServiceTrap=ruckusSCGClusterBackToInServiceTrap, ruckusSCGBackupClusterSuccessTrap=ruckusSCGBackupClusterSuccessTrap, ruckusSCGNodeJoinSuccessTrap=ruckusSCGNodeJoinSuccessTrap, ruckusSCGClusterAppStartTrap=ruckusSCGClusterAppStartTrap, ruckusSCGNodeRemoveSuccessTrap=ruckusSCGNodeRemoveSuccessTrap, ruckusSCGClusterRestoreSuccessTrap=ruckusSCGClusterRestoreSuccessTrap, ruckusSCGNodeBackToInServiceTrap=ruckusSCGNodeBackToInServiceTrap, ruckusSCGSshTunnelSwitchedTrap=ruckusSCGSshTunnelSwitchedTrap, ruckusSCGClusterCfgBackupStartTrap=ruckusSCGClusterCfgBackupStartTrap, ruckusSCGClusterCfgBackupSuccessTrap=ruckusSCGClusterCfgBackupSuccessTrap, ruckusSCGClusterCfgBackupFailedTrap=ruckusSCGClusterCfgBackupFailedTrap, ruckusSCGClusterCfgRestoreSuccessTrap=ruckusSCGClusterCfgRestoreSuccessTrap, ruckusSCGClusterCfgRestoreFailedTrap=ruckusSCGClusterCfgRestoreFailedTrap, ruckusSCGClusterUploadSuccessTrap=ruckusSCGClusterUploadSuccessTrap, ruckusSCGClusterUploadFailedTrap=ruckusSCGClusterUploadFailedTrap, ruckusSCGClusterOutOfServiceTrap=ruckusSCGClusterOutOfServiceTrap, ruckusSCGClusterUploadVDPFirmwareStartTrap=ruckusSCGClusterUploadVDPFirmwareStartTrap, ruckusSCGClusterUploadVDPFirmwareSuccessTrap=ruckusSCGClusterUploadVDPFirmwareSuccessTrap, ruckusSCGClusterUploadVDPFirmwareFailedTrap=ruckusSCGClusterUploadVDPFirmwareFailedTrap, ruckusSCGIpmiVotageTrap=ruckusSCGIpmiVotageTrap, ruckusSCGIpmiTempBBTrap=ruckusSCGIpmiTempBBTrap, ruckusSCGIpmiTempFPTrap=ruckusSCGIpmiTempFPTrap, ruckusSCGIpmiTempIOHTrap=ruckusSCGIpmiTempIOHTrap, ruckusSCGIpmiTempMemPTrap=ruckusSCGIpmiTempMemPTrap, ruckusSCGIpmiTempPSTrap=ruckusSCGIpmiTempPSTrap, ruckusSCGIpmiTempPTrap=ruckusSCGIpmiTempPTrap, ruckusSCGIpmiTempHSBPTrap=ruckusSCGIpmiTempHSBPTrap, ruckusSCGIpmiFanTrap=ruckusSCGIpmiFanTrap, ruckusSCGIpmiPowerTrap=ruckusSCGIpmiPowerTrap)
mibBuilder.exportSymbols("RUCKUS-SCG-EVENT-MIB", ruckusSCGIpmiCurrentTrap=ruckusSCGIpmiCurrentTrap, ruckusSCGIpmiFanStatusTrap=ruckusSCGIpmiFanStatusTrap, ruckusSCGIpmiPsStatusTrap=ruckusSCGIpmiPsStatusTrap, ruckusSCGIpmiDrvStatusTrap=ruckusSCGIpmiDrvStatusTrap, ruckusSCGIpmiREVotageTrap=ruckusSCGIpmiREVotageTrap, ruckusSCGIpmiRETempBBTrap=ruckusSCGIpmiRETempBBTrap, ruckusSCGIpmiRETempFPTrap=ruckusSCGIpmiRETempFPTrap, ruckusSCGIpmiRETempIOHTrap=ruckusSCGIpmiRETempIOHTrap, ruckusSCGIpmiRETempMemPTrap=ruckusSCGIpmiRETempMemPTrap, ruckusSCGIpmiRETempPSTrap=ruckusSCGIpmiRETempPSTrap, ruckusSCGIpmiRETempPTrap=ruckusSCGIpmiRETempPTrap, ruckusSCGIpmiRETempHSBPTrap=ruckusSCGIpmiRETempHSBPTrap, ruckusSCGIpmiREFanTrap=ruckusSCGIpmiREFanTrap, ruckusSCGIpmiREPowerTrap=ruckusSCGIpmiREPowerTrap, ruckusSCGIpmiRECurrentTrap=ruckusSCGIpmiRECurrentTrap, ruckusSCGIpmiREFanStatusTrap=ruckusSCGIpmiREFanStatusTrap, ruckusSCGIpmiREPsStatusTrap=ruckusSCGIpmiREPsStatusTrap, ruckusSCGIpmiREDrvStatusTrap=ruckusSCGIpmiREDrvStatusTrap, ruckusSCGFtpTransferErrorTrap=ruckusSCGFtpTransferErrorTrap, ruckusSCGSystemLBSConnectSuccessTrap=ruckusSCGSystemLBSConnectSuccessTrap, ruckusSCGSystemLBSNoResponseTrap=ruckusSCGSystemLBSNoResponseTrap, ruckusSCGSystemLBSAuthFailedTrap=ruckusSCGSystemLBSAuthFailedTrap, ruckusSCGSystemLBSConnectFailedTrap=ruckusSCGSystemLBSConnectFailedTrap, ruckusSCGProcessRestartTrap=ruckusSCGProcessRestartTrap, ruckusSCGServiceUnavailableTrap=ruckusSCGServiceUnavailableTrap, ruckusSCGKeepAliveFailureTrap=ruckusSCGKeepAliveFailureTrap, ruckusSCGResourceUnavailableTrap=ruckusSCGResourceUnavailableTrap, ruckusSCGSmfRegFailedTrap=ruckusSCGSmfRegFailedTrap, ruckusSCGHipFailoverTrap=ruckusSCGHipFailoverTrap, ruckusSCGConfUpdFailedTrap=ruckusSCGConfUpdFailedTrap, ruckusSCGConfRcvFailedTrap=ruckusSCGConfRcvFailedTrap, ruckusSCGLostCnxnToDbladeTrap=ruckusSCGLostCnxnToDbladeTrap, ruckusSCGGgsnRestartedTrap=ruckusSCGGgsnRestartedTrap, ruckusSCGGgsnNotReachableTrap=ruckusSCGGgsnNotReachableTrap, ruckusSCGGgsnNotResolvedTrap=ruckusSCGGgsnNotResolvedTrap, ruckusSCGUnknownUETrap=ruckusSCGUnknownUETrap, ruckusSCGAuthSrvrNotReachableTrap=ruckusSCGAuthSrvrNotReachableTrap, ruckusSCGAccSrvrNotReachableTrap=ruckusSCGAccSrvrNotReachableTrap, ruckusSCGUnknownRealmTrap=ruckusSCGUnknownRealmTrap, ruckusSCGAuthFailedNonPermanentIDTrap=ruckusSCGAuthFailedNonPermanentIDTrap, ruckusSCGCnxnToCgfFailedTrap=ruckusSCGCnxnToCgfFailedTrap, ruckusSCGCdrTransferFailedTrap=ruckusSCGCdrTransferFailedTrap, ruckusSCGCdrGenerateFailedTrap=ruckusSCGCdrGenerateFailedTrap, ruckusSCGDestNotRecheableTrap=ruckusSCGDestNotRecheableTrap, ruckusSCGAppServerDownTrap=ruckusSCGAppServerDownTrap, ruckusSCGAppServerInactiveTrap=ruckusSCGAppServerInactiveTrap, ruckusSCGAssocCantStartTrap=ruckusSCGAssocCantStartTrap, ruckusSCGAssocDownTrap=ruckusSCGAssocDownTrap, ruckusSCGOutboundRoutingFailedTrap=ruckusSCGOutboundRoutingFailedTrap, ruckusSCGDidAllocationFailureTrap=ruckusSCGDidAllocationFailureTrap, ruckusSCGPdnGwUnresolvedTrap=ruckusSCGPdnGwUnresolvedTrap, ruckusSCGPdnGwVersionUnsupportedTrap=ruckusSCGPdnGwVersionUnsupportedTrap, ruckusSCGPdnGwAssociationDownTrap=ruckusSCGPdnGwAssociationDownTrap, ruckusSCGCreateSessionResponseFailedTrap=ruckusSCGCreateSessionResponseFailedTrap, ruckusSCGDecodeFailedTrap=ruckusSCGDecodeFailedTrap, ruckusSCGModifyBearerResponseFailedTrap=ruckusSCGModifyBearerResponseFailedTrap, ruckusSCGDeleteSessionResponseFailedTrap=ruckusSCGDeleteSessionResponseFailedTrap, ruckusSCGDeleteBearerRequestFailedTrap=ruckusSCGDeleteBearerRequestFailedTrap, ruckusSCGUpdateBearerRequestFailedTrap=ruckusSCGUpdateBearerRequestFailedTrap, ruckusSCGCgfServerNotConfiguredTrap=ruckusSCGCgfServerNotConfiguredTrap, ruckusSCGTtgSessionCriticalThresholdTrap=ruckusSCGTtgSessionCriticalThresholdTrap, ruckusSCGTtgSessionLicenseInsufficientTrap=ruckusSCGTtgSessionLicenseInsufficientTrap, ruckusSCGAPAcctMsgMandatoryPrmMissingTrap=ruckusSCGAPAcctMsgMandatoryPrmMissingTrap, ruckusSCGAcctUnknownRealmTrap=ruckusSCGAcctUnknownRealmTrap, ruckusSCGAPAcctMsgDecodeFailedTrap=ruckusSCGAPAcctMsgDecodeFailedTrap, ruckusSCGAPAcctRespWhileInvalidConfigTrap=ruckusSCGAPAcctRespWhileInvalidConfigTrap, ruckusSCGAPAcctMsgDropNoAcctStartMsgTrap=ruckusSCGAPAcctMsgDropNoAcctStartMsgTrap, ruckusSCGUnauthorizedCoaDmMessageDroppedTrap=ruckusSCGUnauthorizedCoaDmMessageDroppedTrap, ruckusSCGConnectedToDbladeTrap=ruckusSCGConnectedToDbladeTrap, ruckusSCGDestAvailableTrap=ruckusSCGDestAvailableTrap, ruckusSCGAppServerActiveTrap=ruckusSCGAppServerActiveTrap, ruckusSCGAssocUpTrap=ruckusSCGAssocUpTrap, ruckusSCGSessUpdatedAtDbladeTrap=ruckusSCGSessUpdatedAtDbladeTrap, ruckusSCGSessUpdateErrAtDbladeTrap=ruckusSCGSessUpdateErrAtDbladeTrap, ruckusSCGSessDeletedAtDbladeTrap=ruckusSCGSessDeletedAtDbladeTrap, ruckusSCGSessDeleteErrAtDbladeTrap=ruckusSCGSessDeleteErrAtDbladeTrap, ruckusSCGLicenseSyncSuccessTrap=ruckusSCGLicenseSyncSuccessTrap, ruckusSCGLicenseSyncFailedTrap=ruckusSCGLicenseSyncFailedTrap, ruckusSCGLicenseImportSuccessTrap=ruckusSCGLicenseImportSuccessTrap, ruckusSCGLicenseImportFailedTrap=ruckusSCGLicenseImportFailedTrap, ruckusSCGSyslogServerReachableTrap=ruckusSCGSyslogServerReachableTrap, ruckusSCGSyslogServerUnreachableTrap=ruckusSCGSyslogServerUnreachableTrap, ruckusSCGSyslogServerSwitchedTrap=ruckusSCGSyslogServerSwitchedTrap, ruckusSCGAPRadiusServerReachableTrap=ruckusSCGAPRadiusServerReachableTrap, ruckusSCGAPRadiusServerUnreachableTrap=ruckusSCGAPRadiusServerUnreachableTrap, ruckusSCGAPLDAPServerReachableTrap=ruckusSCGAPLDAPServerReachableTrap, ruckusSCGAPLDAPServerUnreachableTrap=ruckusSCGAPLDAPServerUnreachableTrap, ruckusSCGAPADServerReachableTrap=ruckusSCGAPADServerReachableTrap, ruckusSCGAPADServerUnreachableTrap=ruckusSCGAPADServerUnreachableTrap, ruckusSCGAPUsbSoftwarePackageDownloadedTrap=ruckusSCGAPUsbSoftwarePackageDownloadedTrap, ruckusSCGAPUsbSoftwarePackageDownloadFailedTrap=ruckusSCGAPUsbSoftwarePackageDownloadFailedTrap, ruckusSCGEspAuthServerReachableTrap=ruckusSCGEspAuthServerReachableTrap, ruckusSCGEspAuthServerUnreachableTrap=ruckusSCGEspAuthServerUnreachableTrap, ruckusSCGEspAuthServerResolvableTrap=ruckusSCGEspAuthServerResolvableTrap, ruckusSCGEspAuthServerUnResolvableTrap=ruckusSCGEspAuthServerUnResolvableTrap, ruckusSCGEspDNATServerReachableTrap=ruckusSCGEspDNATServerReachableTrap, ruckusSCGEspDNATServerUnreachableTrap=ruckusSCGEspDNATServerUnreachableTrap, ruckusSCGEspDNATServerResolvableTrap=ruckusSCGEspDNATServerResolvableTrap, ruckusSCGEspDNATServerUnresolvableTrap=ruckusSCGEspDNATServerUnresolvableTrap, ruckusRateLimitTORSurpassedTrap=ruckusRateLimitTORSurpassedTrap, ruckusSCGIPSecTunnelAssociatedTrap=ruckusSCGIPSecTunnelAssociatedTrap, ruckusSCGIPSecTunnelDisassociatedTrap=ruckusSCGIPSecTunnelDisassociatedTrap, ruckusSCGIPSecTunnelAssociateFailedTrap=ruckusSCGIPSecTunnelAssociateFailedTrap, ruckusSCGPmipProcessInitTrap=ruckusSCGPmipProcessInitTrap, ruckusSCGPmipUnavailableTrap=ruckusSCGPmipUnavailableTrap, ruckusSCGPmipUnallocatedMemoryTrap=ruckusSCGPmipUnallocatedMemoryTrap, ruckusSCGPmipUpdateCgfFailedTrap=ruckusSCGPmipUpdateCgfFailedTrap, ruckusSCGPmipLMAIcmpUnreachableTrap=ruckusSCGPmipLMAIcmpUnreachableTrap, ruckusSCGPmipLMAFailOverTrap=ruckusSCGPmipLMAFailOverTrap, ruckusSCGPmipBindingFailureTrap=ruckusSCGPmipBindingFailureTrap, ruckusSCGPmiplostCnxnToDHCPTrap=ruckusSCGPmiplostCnxnToDHCPTrap, ruckusSCGPmipLMAIcmpReachableTrap=ruckusSCGPmipLMAIcmpReachableTrap, ruckusSCGPmipBindingSuccessTrap=ruckusSCGPmipBindingSuccessTrap, ruckusSCGPmipConnectedToDHCPTrap=ruckusSCGPmipConnectedToDHCPTrap, ruckusSCGPmipProcessStoppedTrap=ruckusSCGPmipProcessStoppedTrap)
| 220.801147 | 8,176 | 0.776288 | 25,662 | 230,958 | 6.986478 | 0.042436 | 0.090107 | 0.140166 | 0.170107 | 0.750785 | 0.742664 | 0.703643 | 0.683546 | 0.668069 | 0.657934 | 0 | 0.028817 | 0.078967 | 230,958 | 1,045 | 8,177 | 221.01244 | 0.814014 | 0.027633 | 0 | 0.329423 | 1 | 0.237537 | 0.552824 | 0.086786 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | false | 0.002933 | 0.013685 | 0 | 0.013685 | 0 | 0 | 0 | 0 | null | 0 | 0 | 1 | 0 | 1 | 1 | 0 | 0 | 1 | 0 | 0 | 0 | 0 | 0 | 1 | 1 | 0 | 0 | 0 | 0 | 1 | 1 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 8 |
ddfe307894b3ac43e1d8e5311f6d8c87a7f40eb8 | 2,143 | py | Python | build/dynamixel_workbench_msgs/cmake/dynamixel_workbench_msgs-genmsg-context.py | sej0015/holonomic_turtle_bot | 4cc80bb27dfce0aa6f2bd975d79f6348acf40401 | [
"Apache-2.0"
] | null | null | null | build/dynamixel_workbench_msgs/cmake/dynamixel_workbench_msgs-genmsg-context.py | sej0015/holonomic_turtle_bot | 4cc80bb27dfce0aa6f2bd975d79f6348acf40401 | [
"Apache-2.0"
] | null | null | null | build/dynamixel_workbench_msgs/cmake/dynamixel_workbench_msgs-genmsg-context.py | sej0015/holonomic_turtle_bot | 4cc80bb27dfce0aa6f2bd975d79f6348acf40401 | [
"Apache-2.0"
] | null | null | null | # generated from genmsg/cmake/pkg-genmsg.context.in
messages_str = "/home/turtle/holonomic_turtle_bot/src/dynamixel_workbench_msgs/msg/AX.msg;/home/turtle/holonomic_turtle_bot/src/dynamixel_workbench_msgs/msg/EX.msg;/home/turtle/holonomic_turtle_bot/src/dynamixel_workbench_msgs/msg/MX.msg;/home/turtle/holonomic_turtle_bot/src/dynamixel_workbench_msgs/msg/MX2.msg;/home/turtle/holonomic_turtle_bot/src/dynamixel_workbench_msgs/msg/MX2Ext.msg;/home/turtle/holonomic_turtle_bot/src/dynamixel_workbench_msgs/msg/MXExt.msg;/home/turtle/holonomic_turtle_bot/src/dynamixel_workbench_msgs/msg/PRO.msg;/home/turtle/holonomic_turtle_bot/src/dynamixel_workbench_msgs/msg/PROExt.msg;/home/turtle/holonomic_turtle_bot/src/dynamixel_workbench_msgs/msg/RX.msg;/home/turtle/holonomic_turtle_bot/src/dynamixel_workbench_msgs/msg/XH.msg;/home/turtle/holonomic_turtle_bot/src/dynamixel_workbench_msgs/msg/XL.msg;/home/turtle/holonomic_turtle_bot/src/dynamixel_workbench_msgs/msg/XL320.msg;/home/turtle/holonomic_turtle_bot/src/dynamixel_workbench_msgs/msg/XM.msg;/home/turtle/holonomic_turtle_bot/src/dynamixel_workbench_msgs/msg/XMExt.msg;/home/turtle/holonomic_turtle_bot/src/dynamixel_workbench_msgs/msg/DynamixelState.msg;/home/turtle/holonomic_turtle_bot/src/dynamixel_workbench_msgs/msg/DynamixelStateList.msg;/home/turtle/holonomic_turtle_bot/src/dynamixel_workbench_msgs/msg/DynamixelInfo.msg;/home/turtle/holonomic_turtle_bot/src/dynamixel_workbench_msgs/msg/DynamixelLoadInfo.msg"
services_str = "/home/turtle/holonomic_turtle_bot/src/dynamixel_workbench_msgs/srv/GetDynamixelInfo.srv;/home/turtle/holonomic_turtle_bot/src/dynamixel_workbench_msgs/srv/DynamixelCommand.srv"
pkg_name = "dynamixel_workbench_msgs"
dependencies_str = "std_msgs"
langs = "gencpp;geneus;genlisp;gennodejs;genpy"
dep_include_paths_str = "dynamixel_workbench_msgs;/home/turtle/holonomic_turtle_bot/src/dynamixel_workbench_msgs/msg;std_msgs;/opt/ros/melodic/share/std_msgs/cmake/../msg"
PYTHON_EXECUTABLE = "/usr/bin/python2"
package_has_static_sources = '' == 'TRUE'
genmsg_check_deps_script = "/opt/ros/melodic/share/genmsg/cmake/../../../lib/genmsg/genmsg_check_deps.py"
| 178.583333 | 1,421 | 0.862809 | 320 | 2,143 | 5.44375 | 0.221875 | 0.237658 | 0.290471 | 0.301378 | 0.707807 | 0.707807 | 0.707807 | 0.707807 | 0.707807 | 0.707807 | 0 | 0.002845 | 0.015866 | 2,143 | 11 | 1,422 | 194.818182 | 0.823139 | 0.022865 | 0 | 0 | 1 | 0.333333 | 0.902964 | 0.889579 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | false | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | 1 | 1 | 1 | 0 | 1 | 1 | 1 | 1 | 1 | 0 | 0 | 0 | 0 | 0 | 1 | 1 | 0 | 0 | 0 | 0 | 1 | 1 | 1 | 1 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 14 |
fb207963532980a978ea889ac90a9448ab79cb1f | 3,132 | py | Python | main/migrations/0005_auto_20170523_2016.py | cweems/sendcertified | cc46c8aae8a4e7d0a41d8fd2f055021687b68fe2 | [
"MIT"
] | null | null | null | main/migrations/0005_auto_20170523_2016.py | cweems/sendcertified | cc46c8aae8a4e7d0a41d8fd2f055021687b68fe2 | [
"MIT"
] | null | null | null | main/migrations/0005_auto_20170523_2016.py | cweems/sendcertified | cc46c8aae8a4e7d0a41d8fd2f055021687b68fe2 | [
"MIT"
] | null | null | null | # -*- coding: utf-8 -*-
# Generated by Django 1.11.1 on 2017-05-23 20:16
from __future__ import unicode_literals
from django.db import migrations, models
class Migration(migrations.Migration):
dependencies = [
('main', '0004_auto_20170523_0817'),
]
operations = [
migrations.RenameField(
model_name='mailorder',
old_name='recipient_street',
new_name='recipient_country',
),
migrations.RemoveField(
model_name='mailorder',
name='recipient_zip',
),
migrations.RemoveField(
model_name='mailorder',
name='sender_street',
),
migrations.RemoveField(
model_name='mailorder',
name='sender_zip',
),
migrations.AddField(
model_name='mailorder',
name='recipient_locality',
field=models.CharField(default=1, max_length=200),
preserve_default=False,
),
migrations.AddField(
model_name='mailorder',
name='recipient_postal_code',
field=models.CharField(default=1, max_length=200),
preserve_default=False,
),
migrations.AddField(
model_name='mailorder',
name='recipient_route',
field=models.CharField(default=1, max_length=200),
preserve_default=False,
),
migrations.AddField(
model_name='mailorder',
name='recipient_state',
field=models.CharField(default=1, max_length=200),
preserve_default=False,
),
migrations.AddField(
model_name='mailorder',
name='recipient_street_number',
field=models.CharField(default=1, max_length=200),
preserve_default=False,
),
migrations.AddField(
model_name='mailorder',
name='sender_country',
field=models.CharField(default=1, max_length=200),
preserve_default=False,
),
migrations.AddField(
model_name='mailorder',
name='sender_locality',
field=models.CharField(default=1, max_length=200),
preserve_default=False,
),
migrations.AddField(
model_name='mailorder',
name='sender_postal_code',
field=models.CharField(default=1, max_length=200),
preserve_default=False,
),
migrations.AddField(
model_name='mailorder',
name='sender_route',
field=models.CharField(default=1, max_length=200),
preserve_default=False,
),
migrations.AddField(
model_name='mailorder',
name='sender_state',
field=models.CharField(default=1, max_length=200),
preserve_default=False,
),
migrations.AddField(
model_name='mailorder',
name='sender_street_number',
field=models.CharField(default=1, max_length=200),
preserve_default=False,
),
]
| 31.636364 | 62 | 0.565134 | 287 | 3,132 | 5.933798 | 0.202091 | 0.079272 | 0.158544 | 0.180857 | 0.832061 | 0.826776 | 0.798004 | 0.711685 | 0.711685 | 0.711685 | 0 | 0.036684 | 0.329821 | 3,132 | 98 | 63 | 31.959184 | 0.774655 | 0.021711 | 0 | 0.725275 | 1 | 0 | 0.13525 | 0.021888 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | false | 0 | 0.021978 | 0 | 0.054945 | 0 | 0 | 0 | 0 | null | 0 | 0 | 1 | 1 | 1 | 1 | 1 | 1 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 1 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 9 |
9b6cbf23f97be07cf974ff426459df027c4eebde | 4,153 | py | Python | tests/integration_test/test_feature_search_tickets.py | cooomma/mayday-ticketing-bot | 77377c19d9741e30416951e5d2364bbb66d762ad | [
"MIT"
] | 4 | 2019-08-17T05:21:37.000Z | 2019-08-30T03:24:32.000Z | tests/integration_test/test_feature_search_tickets.py | cooomma/mayday-ticketing-bot | 77377c19d9741e30416951e5d2364bbb66d762ad | [
"MIT"
] | 1 | 2021-04-30T20:45:10.000Z | 2021-04-30T20:45:10.000Z | tests/integration_test/test_feature_search_tickets.py | cooomma/mayday-ticketing-bot | 77377c19d9741e30416951e5d2364bbb66d762ad | [
"MIT"
] | 3 | 2019-03-03T16:40:25.000Z | 2019-08-17T08:01:19.000Z |
import pytest
from mayday.helpers.query_helper import QueryHelper
from mayday.objects.query import Query
@pytest.mark.usefixtures('database')
class Test:
@pytest.fixture(autouse=True)
def before_all(self, database: dict):
self.db = database['ticket_table']
def test_search_ticket_by_date(self):
helper = QueryHelper(self.db)
ticket = helper.search_by_date(505)[0]
assert ticket
assert ticket.category == 1
assert ticket.id
assert ticket.date == 505
assert ticket.price_id == 2
assert ticket.quantity == 1
assert ticket.section == 'C1'
assert ticket.row == ''
assert ticket.seat == ''
assert ticket.wish_dates == list()
assert ticket.wish_price_ids == list()
assert ticket.wish_quantities == list()
assert ticket.source_id == 1
assert ticket.remarks == ''
assert ticket.status == 1
assert ticket.username == 'test_account_1'
assert ticket.user_id == 8081
def test_search_ticket_by_section(self):
helper = QueryHelper(self.db)
ticket = helper.search_by_section('C1')[0]
assert ticket
assert ticket.category == 1
assert ticket.id
assert ticket.date == 505
assert ticket.price_id == 2
assert ticket.quantity == 1
assert ticket.section == 'C1'
assert ticket.row == ''
assert ticket.seat == ''
assert ticket.wish_dates == list()
assert ticket.wish_price_ids == list()
assert ticket.wish_quantities == list()
assert ticket.source_id == 1
assert ticket.remarks == ''
assert ticket.status == 1
assert ticket.username == 'test_account_1'
assert ticket.user_id == 8081
def test_search_ticket_by_query(self):
helper = QueryHelper(self.db)
ticket = helper.search_by_query(Query(category_id=1).to_obj(dict(prices=[2])))[0]
print(ticket.to_dict())
assert ticket
assert ticket.category == 1
assert ticket.id
assert ticket.date == 505
assert ticket.price_id == 2
assert ticket.quantity == 1
assert ticket.section == 'C1'
assert ticket.row == ''
assert ticket.seat == ''
assert ticket.wish_dates == list()
assert ticket.wish_price_ids == list()
assert ticket.wish_quantities == list()
assert ticket.source_id == 1
assert ticket.remarks == ''
assert ticket.status == 1
assert ticket.username == 'test_account_1'
assert ticket.user_id == 8081
def test_search_ticket_by_user_id(self):
helper = QueryHelper(self.db)
ticket = helper.search_by_user_id(8082)[0]
assert ticket
assert ticket.category == 2
assert ticket.id
assert ticket.date == 504
assert ticket.price_id == 1
assert ticket.quantity == 1
assert ticket.section == 'A1'
assert ticket.row == ''
assert ticket.seat == ''
assert ticket.wish_dates == [504, 505]
assert ticket.wish_price_ids == [1, 2]
assert ticket.wish_quantities == [1]
assert ticket.source_id == 1
assert ticket.remarks == ''
assert ticket.status == 1
assert ticket.username == 'test_account_2'
assert ticket.user_id == 8082
def test_search_ticket_by_ticket_id(self):
helper = QueryHelper(self.db)
ticket = helper.search_by_user_id(8082)[0]
assert ticket
assert ticket.category == 2
assert ticket.id
assert ticket.date == 504
assert ticket.price_id == 1
assert ticket.quantity == 1
assert ticket.section == 'A1'
assert ticket.row == ''
assert ticket.seat == ''
assert ticket.wish_dates == [504, 505]
assert ticket.wish_price_ids == [1, 2]
assert ticket.wish_quantities == [1]
assert ticket.source_id == 1
assert ticket.remarks == ''
assert ticket.status == 1
assert ticket.username == 'test_account_2'
assert ticket.user_id == 8082
| 33.491935 | 89 | 0.607753 | 501 | 4,153 | 4.868263 | 0.11976 | 0.418204 | 0.133251 | 0.04305 | 0.876179 | 0.858959 | 0.858959 | 0.858959 | 0.858959 | 0.801148 | 0 | 0.036283 | 0.289911 | 4,153 | 123 | 90 | 33.764228 | 0.790777 | 0 | 0 | 0.844037 | 0 | 0 | 0.024566 | 0 | 0 | 0 | 0 | 0 | 0.779817 | 1 | 0.055046 | false | 0 | 0.027523 | 0 | 0.091743 | 0.009174 | 0 | 0 | 0 | null | 1 | 0 | 0 | 1 | 1 | 1 | 1 | 1 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 9 |
9bb1576dfe661ead11e419794456fa07d204376a | 780 | py | Python | make_figures.py | nodonoughue/emitter-detection-python | ebff19acebcc1edfd941280e05f8ddf2ff20c974 | [
"MIT"
] | null | null | null | make_figures.py | nodonoughue/emitter-detection-python | ebff19acebcc1edfd941280e05f8ddf2ff20c974 | [
"MIT"
] | null | null | null | make_figures.py | nodonoughue/emitter-detection-python | ebff19acebcc1edfd941280e05f8ddf2ff20c974 | [
"MIT"
] | null | null | null | import make_figures
close_figs = True
force_recalc = True
# make_figures.chapter1.make_all_figures(close_figs=close_figs)
# make_figures.chapter2.make_all_figures(close_figs=close_figs)
# make_figures.chapter3.make_all_figures(close_figs=close_figs)
# make_figures.chapter4.make_all_figures(close_figs=close_figs)
# make_figures.chapter5.make_all_figures(close_figs=close_figs)
# make_figures.chapter6.make_all_figures(close_figs=close_figs)
# make_figures.chapter7.make_all_figures(close_figs=close_figs, force_recalc=force_recalc)
# make_figures.chapter8.make_all_figures(close_figs=close_figs, force_recalc=force_recalc)
# make_figures.chapter9.make_all_figures(close_figs=close_figs)
make_figures.chapter10.make_all_figures(close_figs=close_figs, force_recalc=force_recalc)
| 48.75 | 90 | 0.873077 | 121 | 780 | 5.140496 | 0.157025 | 0.303859 | 0.282958 | 0.305466 | 0.779743 | 0.779743 | 0.779743 | 0.779743 | 0.779743 | 0.29582 | 0 | 0.014706 | 0.041026 | 780 | 15 | 91 | 52 | 0.816845 | 0.783333 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | false | 0 | 0.25 | 0 | 0.25 | 0 | 0 | 0 | 0 | null | 1 | 1 | 1 | 0 | 1 | 1 | 1 | 1 | 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 | 7 |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.